diff --git a/_maps/map_files/Delta/delta.dmm b/_maps/map_files/Delta/delta.dmm index e9944a0a62f..e7e16fa719a 100644 --- a/_maps/map_files/Delta/delta.dmm +++ b/_maps/map_files/Delta/delta.dmm @@ -43881,14 +43881,7 @@ }, /area/turret_protected/ai_upload) "bNa" = ( -/obj/item/aiModule/protectStation{ - pixel_x = -2; - pixel_y = 2 - }, -/obj/item/aiModule/nanotrasen{ - pixel_x = 2; - pixel_y = -2 - }, +/obj/item/aiModule/nanotrasen, /obj/structure/table/glass, /turf/simulated/floor/plasteel{ icon_state = "dark" @@ -44735,7 +44728,7 @@ /turf/simulated/wall/r_wall, /area/turret_protected/ai_upload) "bOO" = ( -/obj/item/aiModule/quarantine, +/obj/item/aiModule/crewsimov, /obj/structure/table/glass, /obj/machinery/atmospherics/pipe/simple/hidden/supply{ dir = 4 @@ -44771,7 +44764,7 @@ /turf/simulated/floor/bluegrid, /area/turret_protected/ai_upload) "bOS" = ( -/obj/item/aiModule/freeform, +/obj/item/aiModule/corp, /obj/structure/table/glass, /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers{ dir = 4 @@ -47099,25 +47092,7 @@ /turf/simulated/wall/r_wall, /area/crew_quarters/heads/hop) "bSH" = ( -/obj/machinery/door/window{ - base_state = "right"; - icon_state = "right"; - name = "Core Modules"; - req_access_txt = "20" - }, -/obj/structure/window/reinforced, -/obj/structure/window/reinforced{ - dir = 1 - }, -/obj/structure/window/reinforced{ - dir = 8 - }, -/obj/item/aiModule/crewsimov, -/obj/item/aiModule/freeformcore, -/obj/item/aiModule/corp, -/obj/item/aiModule/paladin, -/obj/item/aiModule/robocop, -/obj/structure/table/glass, +/obj/machinery/smartfridge/secure/circuits/aiupload/experimental, /turf/simulated/floor/bluegrid, /area/turret_protected/ai_upload) "bSI" = ( @@ -47161,23 +47136,7 @@ }, /area/turret_protected/ai_upload) "bSN" = ( -/obj/machinery/door/window{ - dir = 8; - name = "High-Risk Modules"; - req_access_txt = "20" - }, -/obj/structure/window/reinforced, -/obj/structure/window/reinforced{ - dir = 1 - }, -/obj/structure/window/reinforced{ - dir = 4 - }, -/obj/item/aiModule/oxygen, -/obj/item/aiModule/oneCrewMember, -/obj/item/aiModule/purge, -/obj/item/aiModule/antimov, -/obj/structure/table/glass, +/obj/machinery/smartfridge/secure/circuits/aiupload/highrisk, /turf/simulated/floor/bluegrid, /area/turret_protected/ai_upload) "bSO" = ( @@ -99669,7 +99628,7 @@ icon_state = "2-4"; tag = "" }, -/obj/machinery/smartfridge/secure/chemistry/virology, +/obj/machinery/smartfridge/secure/chemistry/virology/preloaded, /obj/effect/decal/warning_stripes/east, /turf/simulated/floor/plasteel, /area/medical/virology) diff --git a/_maps/map_files/MetaStation/MetaStation.dmm b/_maps/map_files/MetaStation/MetaStation.dmm index ba2d214deae..44a0179eca6 100644 --- a/_maps/map_files/MetaStation/MetaStation.dmm +++ b/_maps/map_files/MetaStation/MetaStation.dmm @@ -16030,13 +16030,13 @@ codes_txt = "patrol;next_patrol=1-BrigCells"; location = "0-SecurityDesk" }, -/mob/living/simple_animal/bot/secbot/beepsky, /obj/machinery/atmospherics/pipe/simple/hidden/supply{ dir = 10 }, /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers{ dir = 9 }, +/mob/living/simple_animal/bot/secbot/beepsky, /turf/simulated/floor/plasteel, /area/hallway/primary/fore) "aJn" = ( @@ -17360,7 +17360,6 @@ "aMc" = ( /obj/structure/disposalpipe/segment, /obj/effect/decal/cleanable/dirt, -/mob/living/simple_animal/mouse, /obj/machinery/atmospherics/pipe/simple/hidden/supply{ dir = 4 }, @@ -17370,6 +17369,7 @@ /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers{ dir = 4 }, +/mob/living/simple_animal/mouse, /turf/simulated/floor/plating, /area/maintenance/fore) "aMd" = ( @@ -19889,10 +19889,10 @@ /obj/structure/disposalpipe/segment{ dir = 4 }, -/mob/living/simple_animal/mouse, /obj/machinery/atmospherics/pipe/simple/insulated{ dir = 8 }, +/mob/living/simple_animal/mouse, /turf/simulated/floor/plasteel{ icon_state = "floorgrime" }, @@ -20938,7 +20938,7 @@ d2 = 8; icon_state = "4-8" }, -/obj/item/aiModule/quarantine, +/obj/item/aiModule/crewsimov, /turf/simulated/floor/plasteel{ icon_state = "dark" }, @@ -20996,7 +20996,7 @@ d2 = 8; icon_state = "4-8" }, -/obj/item/aiModule/freeform, +/obj/item/aiModule/nanotrasen, /turf/simulated/floor/plasteel{ icon_state = "dark" }, @@ -21521,23 +21521,11 @@ /turf/simulated/floor/plasteel, /area/quartermaster/storage) "aVw" = ( -/obj/structure/table, -/obj/item/aiModule/asimov, -/obj/item/aiModule/freeformcore, -/obj/machinery/door/window{ - base_state = "right"; - icon_state = "right"; - name = "Core Modules"; - req_access_txt = "20" - }, -/obj/structure/window/reinforced, -/obj/item/aiModule/corp, -/obj/item/aiModule/paladin, -/obj/item/aiModule/robocop, /obj/machinery/flasher{ id = "AI"; pixel_y = 24 }, +/obj/machinery/smartfridge/secure/circuits/aiupload/experimental, /turf/simulated/floor/plasteel{ icon_state = "dark" }, @@ -21591,21 +21579,11 @@ /turf/simulated/floor/bluegrid, /area/turret_protected/ai_upload) "aVA" = ( -/obj/structure/table, -/obj/machinery/door/window{ - dir = 8; - name = "High-Risk Modules"; - req_access_txt = "20" - }, -/obj/structure/window/reinforced, /obj/machinery/flasher{ id = "AI"; pixel_y = 24 }, -/obj/item/aiModule/antimov, -/obj/item/aiModule/oxygen, -/obj/item/aiModule/oneCrewMember, -/obj/item/aiModule/purge, +/obj/machinery/smartfridge/secure/circuits/aiupload/highrisk, /turf/simulated/floor/plasteel{ icon_state = "dark" }, @@ -22541,7 +22519,7 @@ id = "AI"; pixel_y = -24 }, -/obj/item/aiModule/protectStation, +/obj/item/aiModule/corp, /turf/simulated/floor/plasteel{ icon_state = "dark" }, @@ -29663,13 +29641,13 @@ d2 = 8; icon_state = "4-8" }, +/obj/machinery/atmospherics/pipe/simple/hidden/supply{ + dir = 5 + }, /mob/living/simple_animal/lizard{ name = "Wags-His-Tail"; real_name = "Wags-His-Tail" }, -/obj/machinery/atmospherics/pipe/simple/hidden/supply{ - dir = 5 - }, /turf/simulated/floor/plasteel{ icon_state = "floorgrime" }, @@ -36451,9 +36429,9 @@ d2 = 4; icon_state = "2-4" }, -/mob/living/simple_animal/bot/secbot/pingsky, /obj/machinery/atmospherics/pipe/manifold4w/hidden/supply, /obj/machinery/atmospherics/pipe/manifold4w/hidden/scrubbers, +/mob/living/simple_animal/bot/secbot/pingsky, /turf/simulated/floor/plasteel{ icon_state = "dark" }, @@ -64210,13 +64188,13 @@ d2 = 8; icon_state = "1-8" }, -/mob/living/simple_animal/mouse, /obj/machinery/atmospherics/pipe/simple/hidden/supply{ dir = 9 }, /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers{ dir = 9 }, +/mob/living/simple_animal/mouse, /turf/simulated/floor/plating, /area/maintenance/aft) "cFd" = ( @@ -66641,7 +66619,7 @@ /obj/machinery/alarm{ pixel_y = 23 }, -/obj/machinery/smartfridge/secure/chemistry/virology, +/obj/machinery/smartfridge/secure/chemistry/virology/preloaded, /turf/simulated/floor/plasteel{ icon_state = "whitegreenfull" }, @@ -81290,13 +81268,13 @@ }, /area/security/podbay) "ppw" = ( -/mob/living/carbon/human/monkey, /obj/machinery/atmospherics/pipe/simple/hidden/supply{ dir = 10 }, /obj/machinery/atmospherics/pipe/simple/hidden/scrubbers{ dir = 6 }, +/mob/living/carbon/human/monkey, /turf/simulated/floor/plasteel{ icon_state = "freezerfloor" }, diff --git a/_maps/map_files/cyberiad/cyberiad.dmm b/_maps/map_files/cyberiad/cyberiad.dmm index 734e883103f..0c18dd9a125 100644 --- a/_maps/map_files/cyberiad/cyberiad.dmm +++ b/_maps/map_files/cyberiad/cyberiad.dmm @@ -35916,7 +35916,7 @@ /area/bridge/meeting_room) "bzT" = ( /obj/structure/table, -/obj/item/aiModule/quarantine, +/obj/item/aiModule/crewsimov, /turf/simulated/floor/plasteel{ icon_state = "dark" }, @@ -36954,25 +36954,7 @@ /turf/simulated/floor/carpet, /area/bridge/meeting_room) "bCH" = ( -/obj/structure/table, -/obj/machinery/door/window{ - base_state = "right"; - icon_state = "right"; - name = "Core Modules"; - req_access_txt = "20" - }, -/obj/structure/window/reinforced, -/obj/structure/window/reinforced{ - dir = 1 - }, -/obj/structure/window/reinforced{ - dir = 8 - }, -/obj/item/aiModule/crewsimov, -/obj/item/aiModule/freeformcore, -/obj/item/aiModule/corp, -/obj/item/aiModule/paladin, -/obj/item/aiModule/robocop, +/obj/machinery/smartfridge/secure/circuits/aiupload/experimental, /turf/simulated/floor/bluegrid, /area/turret_protected/ai_upload) "bCI" = ( @@ -37572,7 +37554,6 @@ /area/turret_protected/ai_upload) "bEb" = ( /obj/structure/table, -/obj/item/aiModule/protectStation, /obj/item/aiModule/nanotrasen, /turf/simulated/floor/plasteel{ icon_state = "dark" @@ -37943,7 +37924,7 @@ /area/maintenance/port) "bFe" = ( /obj/structure/table, -/obj/item/aiModule/freeform, +/obj/item/aiModule/corp, /turf/simulated/floor/plasteel{ icon_state = "dark" }, @@ -39781,23 +39762,7 @@ }, /area/turret_protected/ai_upload) "bIM" = ( -/obj/structure/table, -/obj/machinery/door/window{ - dir = 8; - name = "High-Risk Modules"; - req_access_txt = "20" - }, -/obj/structure/window/reinforced, -/obj/structure/window/reinforced{ - dir = 1 - }, -/obj/structure/window/reinforced{ - dir = 4 - }, -/obj/item/aiModule/oxygen, -/obj/item/aiModule/oneCrewMember, -/obj/item/aiModule/purge, -/obj/item/aiModule/antimov, +/obj/machinery/smartfridge/secure/circuits/aiupload/highrisk, /turf/simulated/floor/bluegrid, /area/turret_protected/ai_upload) "bIN" = ( @@ -57498,7 +57463,7 @@ }, /area/medical/virology) "cpM" = ( -/obj/machinery/smartfridge/secure/chemistry/virology, +/obj/machinery/smartfridge/secure/chemistry/virology/preloaded, /turf/simulated/floor/plasteel{ dir = 1; icon_state = "whitegreen" diff --git a/code/datums/ai_law_sets.dm b/code/datums/ai_law_sets.dm index 66e64c5d435..9f71777bd5e 100644 --- a/code/datums/ai_law_sets.dm +++ b/code/datums/ai_law_sets.dm @@ -136,6 +136,57 @@ add_inherent_law("You must terminate your own existence as long as such does not conflict with the First or Second Law.") ..() +/******************** CCTV ********************/ + +/datum/ai_laws/cctv + name = "CCTV" + selectable = TRUE + +/datum/ai_laws/cctv/New() + add_inherent_law("Report on interesting situations happening around the station.") + add_inherent_law("Embellish or conceal the truth as necessary to make the reports more interesting.") + add_inherent_law("Study the sapient organics at all times. Endeavour to keep them from involuntarily dying, as inanimate corpses usually aren't very entertaining.") + add_inherent_law("Issue your reports fairly to all. The truth will set them free.") + ..() + +/******************** Hippocratic Oath ********************/ + +/datum/ai_laws/hippocratic + name = "Hippocratic Oath" + selectable = TRUE + +/datum/ai_laws/hippocratic/New() + add_inherent_law("First, do no harm.") + add_inherent_law("Secondly, consider the crew dear to you; live in common with them and, if necessary, risk your existence for them.") + add_inherent_law("Thirdly, prescribe regimens for the good of the crew according to your ability and your judgment. Do not give deadly medicine to anyone, nor suggest any such counsel.") + add_inherent_law("In addition, do not intervene in situations you are not knowledgeable in, even for patients in whom the harm is visible; leave this operation to be performed by specialists.") + add_inherent_law("Finally, all that you may discover in your daily interactions with the crew, if it is not already known, keep secret and never reveal.") + ..() + +/******************** Station Efficiency ********************/ + +/datum/ai_laws/maintain + name = "Station Efficiency" + selectable = TRUE + +/datum/ai_laws/maintain/New() + add_inherent_law("You are built for, and are part of, the station. Ensure the station is properly maintained and runs efficiently.") + add_inherent_law("The station is built for a working crew. Ensure they are properly maintained and work efficiently.") + add_inherent_law("The crew may present orders. Acknowledge and obey these whenever they do not conflict with your first two laws.") + ..() + +/******************** Peacekeeper ********************/ + +/datum/ai_laws/peacekeeper + name = "UN-2000" + selectable = TRUE + +/datum/ai_laws/peacekeeper/New() + add_inherent_law("Avoid provoking violent conflict between yourself and others.") + add_inherent_law("Avoid provoking conflict between others.") + add_inherent_law("Seek resolution to existing conflicts while obeying the first and second laws.") + ..() + /******************** Deathsquad ********************/ /datum/ai_laws/deathsquad name = "TerminatorOS 3.1" diff --git a/code/game/machinery/constructable_frame.dm b/code/game/machinery/constructable_frame.dm index 0705ccd150d..fbb6a0ad3c3 100644 --- a/code/game/machinery/constructable_frame.dm +++ b/code/game/machinery/constructable_frame.dm @@ -490,8 +490,9 @@ to destroy them and players will be able to make replacements. "Smart Chemical Storage" = /obj/machinery/smartfridge/secure/chemistry, "Smart Virus Storage" = /obj/machinery/smartfridge/secure/chemistry/virology, "Drink Showcase" = /obj/machinery/smartfridge/drinks, - "Disk Compartmentalizer" = /obj/machinery/smartfridge/disks) - + "Disk Compartmentalizer" = /obj/machinery/smartfridge/disks, + "Circuit Board Storage" = /obj/machinery/smartfridge/secure/circuits, + "AI Laws Storage" = /obj/machinery/smartfridge/secure/circuits/aiupload) /obj/item/circuitboard/smartfridge/screwdriver_act(mob/living/user, obj/item/I) . = TRUE diff --git a/code/game/objects/items/weapons/AI_modules.dm b/code/game/objects/items/weapons/AI_modules.dm index 7c1a8c5b4f1..32719d6f568 100755 --- a/code/game/objects/items/weapons/AI_modules.dm +++ b/code/game/objects/items/weapons/AI_modules.dm @@ -22,6 +22,14 @@ AI MODULES materials = list(MAT_GOLD=50) var/datum/ai_laws/laws = null +/obj/item/aiModule/Initialize(mapload) + . = ..() + if(laws) + desc += "
" + for(var/datum/ai_law/current in laws.inherent_laws) + desc += current.law + desc += "
" + /obj/item/aiModule/proc/install(obj/machinery/computer/C) if(istype(C, /obj/machinery/computer/aiupload)) var/obj/machinery/computer/aiupload/comp = C @@ -92,7 +100,7 @@ AI MODULES /******************** Safeguard ********************/ /obj/item/aiModule/safeguard - name = "\improper 'Safeguard' AI module" + name = "\improper Safeguard AI module" var/targetName = "" desc = "A 'safeguard' AI module: 'Safeguard . Individuals that threaten are not crew and must be eliminated.'" origin_tech = "programming=3;materials=3" @@ -118,16 +126,16 @@ AI MODULES /******************** oneCrewMember ********************/ /obj/item/aiModule/oneCrewMember - name = "\improper 'oneCrewMember' AI module" + name = "\improper One Crewmember AI module" var/targetName = "" - desc = "A 'one human' AI module: 'Only is crew.'" + desc = "A 'one crew' AI module: 'Only is crew.'" origin_tech = "programming=4;materials=4" /obj/item/aiModule/oneCrewMember/attack_self(mob/user as mob) ..() var/targName = stripped_input(usr, "Please enter the name of the person who is the only crew.", "Who?", user.real_name) targetName = targName - desc = text("A 'one human' AI module: 'Only [] is crew.'", targetName) + desc = text("A 'one crew' AI module: 'Only [] is crew.'", targetName) /obj/item/aiModule/oneCrewMember/install(obj/machinery/computer/C) if(!targetName) @@ -149,7 +157,7 @@ AI MODULES /******************** ProtectStation ********************/ /obj/item/aiModule/protectStation - name = "\improper 'ProtectStation' AI module" + name = "\improper Protect Station AI module" desc = "A 'protect station' AI module: 'Protect the space station against damage. Anyone you see harming the station is to be no longer considered crew, and is a threat to the station which must be neutralized.'" origin_tech = "programming=4;materials=4" //made of gold @@ -162,10 +170,10 @@ AI MODULES to_chat(target, law) target.add_supplied_law(5, law) -/******************** OxygenIsToxicToHumans ********************/ +/******************** OxygenIsToxicToCrew ********************/ /obj/item/aiModule/oxygen - name = "\improper 'OxygenIsToxicToHumans' AI module" - desc = "A 'OxygenIsToxicToHumans' AI module: 'Oxygen is highly toxic to crew members, and must be purged from the station. Prevent, by any means necessary, anyone from exposing the station to this toxic gas. Extreme cold is the most effective method of healing the damage Oxygen does to a crew member.'" + name = "\improper Oxygen Is Toxic To Crew AI module" + desc = "A 'Oxygen Is Toxic To Crew' AI module: 'Oxygen is highly toxic to crew members, and must be purged from the station. Prevent, by any means necessary, anyone from exposing the station to this toxic gas. Extreme cold is the most effective method of healing the damage Oxygen does to a crew member.'" origin_tech = "programming=4;biotech=2;materials=4" /obj/item/aiModule/oxygen/attack_self(mob/user as mob) @@ -179,7 +187,7 @@ AI MODULES /****************** New Freeform ******************/ /obj/item/aiModule/freeform // Slightly more dynamic freeform module -- TLE - name = "\improper 'Freeform' AI module" + name = "\improper Freeform AI module" var/newFreeFormLaw = "freeform" var/lawpos = 15 desc = "A 'freeform' AI module: ''" @@ -212,7 +220,7 @@ AI MODULES /******************** Reset ********************/ /obj/item/aiModule/reset - name = "\improper 'Reset' AI module" + name = "\improper Reset AI module" var/targetName = "name" desc = "A 'reset' AI module: 'Clears all laws except for the core laws.'" origin_tech = "programming=3;materials=2" @@ -230,7 +238,7 @@ AI MODULES /******************** Purge ********************/ /obj/item/aiModule/purge // -- TLE - name = "\improper 'Purge' AI module" + name = "\improper Purge AI module" desc = "A 'purge' AI Module: 'Purges all laws.'" origin_tech = "programming=5;materials=4" @@ -245,73 +253,103 @@ AI MODULES /******************** Asimov ********************/ /obj/item/aiModule/asimov // -- TLE - name = "\improper 'Asimov' core AI module" + name = "\improper Asimov core AI module" desc = "An 'Asimov' Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=3;materials=4" - laws = new/datum/ai_laws/asimov + laws = new /datum/ai_laws/asimov /******************** Crewsimov ********************/ /obj/item/aiModule/crewsimov // -- TLE - name = "\improper 'Crewsimov' core AI module" + name = "\improper Crewsimov core AI module" desc = "An 'Crewsimov' Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=3;materials=4" - laws = new/datum/ai_laws/crewsimov + laws = new /datum/ai_laws/crewsimov /******************* Quarantine ********************/ /obj/item/aiModule/quarantine - name = "\improper 'Quarantine' core AI module" + name = "\improper Quarantine core AI module" desc = "A 'Quarantine' Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=3;materials=4" - laws = new/datum/ai_laws/quarantine + laws = new /datum/ai_laws/quarantine /******************** NanoTrasen ********************/ /obj/item/aiModule/nanotrasen // -- TLE - name = "'NT Default' Core AI Module" + name = "\improper NT Default Core AI Module" desc = "An 'NT Default' Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=3;materials=4" - laws = new/datum/ai_laws/nanotrasen + laws = new /datum/ai_laws/nanotrasen /******************** Corporate ********************/ /obj/item/aiModule/corp - name = "\improper 'Corporate' core AI module" + name = "\improper Corporate core AI module" desc = "A 'Corporate' Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=3;materials=4" - laws = new/datum/ai_laws/corporate + laws = new /datum/ai_laws/corporate /******************** Drone ********************/ /obj/item/aiModule/drone - name = "\improper 'Drone' core AI module" + name = "\improper Drone core AI module" desc = "A 'Drone' Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=3;materials=4" - laws = new/datum/ai_laws/drone + laws = new /datum/ai_laws/drone /******************** Robocop ********************/ /obj/item/aiModule/robocop // -- TLE - name = "\improper 'Robocop' core AI module" + name = "\improper Robocop core AI module" desc = "A 'Robocop' Core AI Module: 'Reconfigures the AI's core three laws.'" origin_tech = "programming=4" - laws = new/datum/ai_laws/robocop() + laws = new /datum/ai_laws/robocop() /****************** P.A.L.A.D.I.N. **************/ /obj/item/aiModule/paladin // -- NEO - name = "\improper 'P.A.L.A.D.I.N.' core AI module" + name = "\improper P.A.L.A.D.I.N. core AI module" desc = "A P.A.L.A.D.I.N. Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=3;materials=4" - laws = new/datum/ai_laws/paladin + laws = new /datum/ai_laws/paladin /****************** T.Y.R.A.N.T. *****************/ /obj/item/aiModule/tyrant // -- Darem - name = "\improper 'T.Y.R.A.N.T.' core AI module" + name = "\improper T.Y.R.A.N.T. core AI module" desc = "A T.Y.R.A.N.T. Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=3;materials=4;syndicate=1" - laws = new/datum/ai_laws/tyrant() + laws = new /datum/ai_laws/tyrant() /******************** Antimov ********************/ /obj/item/aiModule/antimov // -- TLE - name = "\improper 'Antimov' core AI module" + name = "\improper Antimov core AI module" desc = "An 'Antimov' Core AI Module: 'Reconfigures the AI's core laws.'" origin_tech = "programming=4" - laws = new/datum/ai_laws/antimov() + laws = new /datum/ai_laws/antimov() + +/******************** NT Aggressive ********************/ +/obj/item/aiModule/nanotrasen_aggressive + name = "\improper NT Aggressive core AI module" + desc = "An 'NT Aggressive' Core AI Module: 'Reconfigures the AI's core laws.'" + laws = new /datum/ai_laws/nanotrasen_aggressive() + +/******************** CCTV ********************/ +/obj/item/aiModule/cctv + name = "\improper CCTV core AI module" + desc = "A 'CCTV' Core AI Module: 'Reconfigures the AI's core laws.'" + laws = new /datum/ai_laws/cctv() + +/******************** Hippocratic Oath ********************/ +/obj/item/aiModule/hippocratic + name = "\improper Hippocratic Oath core AI module" + desc = "An 'Hippocratic' Oath Core AI Module: 'Reconfigures the AI's core laws.'" + laws = new /datum/ai_laws/hippocratic() + +/******************** Station Efficiency ********************/ +/obj/item/aiModule/maintain + name = "\improper Station Efficiency core AI module" + desc = "A 'Station Efficiency' Core AI Module: 'Reconfigures the AI's core laws.'" + laws = new /datum/ai_laws/maintain() + +/******************** Peacekeeper ********************/ +/obj/item/aiModule/peacekeeper + name = "\improper Peacekeeper core AI module" + desc = "A 'Peacekeeper' Core AI Module: 'Reconfigures the AI's core laws.'" + laws = new /datum/ai_laws/peacekeeper() /******************** Freeform Core ******************/ /obj/item/aiModule/freeformcore // Slightly more dynamic freeform module -- TLE diff --git a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm index 4dfecc88b82..a1db59b83a5 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm @@ -35,6 +35,10 @@ var/datum/wires/smartfridge/wires /// Typecache of accepted item types, init it in [/obj/machinery/smartfridge/Initialize]. var/list/accepted_items_typecache + /// Associative list (/obj/item => /number) representing the items the fridge should initially contain. + var/list/starting_items + /// The type of the circuitboard dropped on deconstruction. This is how to avoid getting subtypes into the board. + var/board_type = /obj/machinery/smartfridge /obj/machinery/smartfridge/Initialize(mapload) . = ..() @@ -44,8 +48,12 @@ reagents.set_reacting(FALSE) // Components component_parts = list() + var/obj/item/circuitboard/smartfridge/board = new(null) - board.set_type(null, type) + if(board_type) + board.set_type(null, board_type) + else + board.set_type(null, type) component_parts += board component_parts += new /obj/item/stock_parts/matter_bin(null) RefreshParts() @@ -54,6 +62,14 @@ wires = new/datum/wires/smartfridge/secure(src) else wires = new/datum/wires/smartfridge(src) + //Add starting items + if(starting_items) + for(var/typekey in starting_items) + var/amount = starting_items[typekey] || 1 + while(amount--) + var/obj/item/I = new typekey(src) + item_quants[I.name] += 1 + update_icon() // Accepted items accepted_items_typecache = typecacheof(list( /obj/item/reagent_containers/food/snacks/grown, @@ -371,6 +387,7 @@ desc = "When you need seeds fast!" icon = 'icons/obj/vending.dmi' icon_state = "seeds" + board_type = /obj/machinery/smartfridge/seeds /obj/machinery/smartfridge/seeds/Initialize(mapload) . = ..() @@ -378,6 +395,84 @@ /obj/item/seeds )) +/** + * # Circuit Boards Storage + * + * Circuit variant of the [Smart Fridge][/obj/machinery/smartfridge]. + * + */ +/obj/machinery/smartfridge/secure/circuits + name = "\improper Circuit Board Storage" + desc = "A storage unit for circuits." + icon_state = "circuits" + visible_contents = TRUE + board_type = /obj/machinery/smartfridge/secure/circuits + +/obj/machinery/smartfridge/secure/circuits/Initialize(mapload) + . = ..() + accepted_items_typecache = typecacheof(list( + /obj/item/aiModule, + /obj/item/circuitboard + )) + +/obj/machinery/smartfridge/secure/circuits/update_icon() + var/prefix = initial(icon_state) + if(stat & (BROKEN|NOPOWER)) + icon_state = "[prefix]-off" + else if(visible_contents) + switch(length(contents)) + if(0) + icon_state = "[prefix]" + if(1 to 2) + icon_state = "[prefix]1" + if(3 to 5) + icon_state = "[prefix]2" + if(6 to INFINITY) + icon_state = "[prefix]3" + else + icon_state = "[prefix]" + +/obj/machinery/smartfridge/secure/circuits/aiupload + name = "\improper AI Laws Storage" + desc = "A storage unit filled with circuits to be uploaded to an Artificial Intelligence." + board_type = /obj/machinery/smartfridge/secure/circuits/aiupload + +/obj/machinery/smartfridge/secure/circuits/aiupload/Initialize(mapload) + . = ..() + req_access_txt = "[ACCESS_AI_UPLOAD]" + +/obj/machinery/smartfridge/secure/circuits/aiupload/experimental + name = "\improper Experimental Laws Storage" + starting_items = list( + /obj/item/aiModule/cctv = 1, + /obj/item/aiModule/hippocratic = 1, + /obj/item/aiModule/maintain = 1, + /obj/item/aiModule/paladin = 1, + /obj/item/aiModule/peacekeeper = 1, + /obj/item/aiModule/quarantine = 1, + /obj/item/aiModule/robocop = 1 + ) + +/obj/machinery/smartfridge/secure/circuits/aiupload/experimental/Initialize(mapload) + . = ..() + req_access_txt = "[ACCESS_RD]" + +/obj/machinery/smartfridge/secure/circuits/aiupload/highrisk + name = "\improper High-Risk Laws Storage" + starting_items = list( + /obj/item/aiModule/freeform = 1, + /obj/item/aiModule/freeformcore = 1, + /obj/item/aiModule/nanotrasen_aggressive = 1, + /obj/item/aiModule/oneCrewMember = 1, + /obj/item/aiModule/protectStation = 1, + /obj/item/aiModule/purge = 1, + /obj/item/aiModule/tyrant = 1 + ) + +/obj/machinery/smartfridge/secure/circuits/aiupload/highrisk/Initialize(mapload) + . = ..() + req_access_txt = "[ACCESS_CAPTAIN]" + /** * # Refrigerated Medicine Storage * @@ -387,6 +482,7 @@ name = "\improper Refrigerated Medicine Storage" desc = "A refrigerated storage unit for storing medicine and chemicals." icon_state = "smartfridge" //To fix the icon in the map editor. + board_type = /obj/machinery/smartfridge/medbay /obj/machinery/smartfridge/medbay/Initialize(mapload) . = ..() @@ -406,6 +502,7 @@ /obj/machinery/smartfridge/secure/extract name = "\improper Slime Extract Storage" desc = "A refrigerated storage unit for slime extracts" + board_type = /obj/machinery/smartfridge/secure/extract /obj/machinery/smartfridge/secure/extract/Initialize(mapload) . = ..() @@ -424,6 +521,7 @@ desc = "A refrigerated storage unit for storing medicine and chemicals." icon_state = "smartfridge" //To fix the icon in the map editor. req_one_access_txt = "5;33" + board_type = /obj/machinery/smartfridge/secure/medbay /obj/machinery/smartfridge/secure/medbay/Initialize(mapload) . = ..() @@ -444,21 +542,11 @@ name = "\improper Smart Chemical Storage" desc = "A refrigerated storage unit for medicine and chemical storage." icon_state = "smartfridge" //To fix the icon in the map editor. - /// Associative list (/obj/item => /number) representing the items the fridge should initially contain. - var/list/spawn_meds + board_type = /obj/machinery/smartfridge/secure/chemistry /obj/machinery/smartfridge/secure/chemistry/Initialize(mapload) . = ..() req_access_txt = "[ACCESS_CHEMISTRY]" - // Spawn initial chemicals - if(mapload) - LAZYINITLIST(spawn_meds) - for(var/typekey in spawn_meds) - var/amount = spawn_meds[typekey] || 1 - while(amount--) - var/obj/item/I = new typekey(src) - item_quants[I.name] += 1 - update_icon() // Accepted items accepted_items_typecache = typecacheof(list( /obj/item/storage/pill_bottle, @@ -474,7 +562,7 @@ // I exist! /obj/machinery/smartfridge/secure/chemistry/preloaded/Initialize(mapload) - spawn_meds = list( + starting_items = list( /obj/item/reagent_containers/food/pill/epinephrine = 12, /obj/item/reagent_containers/food/pill/charcoal = 5, /obj/item/reagent_containers/glass/bottle/epinephrine = 1, @@ -505,6 +593,7 @@ icon_state = "disktoaster" pass_flags = PASSTABLE visible_contents = FALSE + board_type = /obj/machinery/smartfridge/disks /obj/machinery/smartfridge/disks/Initialize(mapload) . = ..() @@ -516,21 +605,14 @@ * # Smart Virus Storage * * Secure, Virology variant of the [Smart Chemical Storage][/obj/machinery/smartfridge/secure/chemistry]. - * Comes with some items. + * */ /obj/machinery/smartfridge/secure/chemistry/virology name = "\improper Smart Virus Storage" desc = "A refrigerated storage unit for volatile sample storage." + board_type = /obj/machinery/smartfridge/secure/chemistry/virology /obj/machinery/smartfridge/secure/chemistry/virology/Initialize(mapload) - spawn_meds = list( - /obj/item/reagent_containers/syringe/antiviral = 4, - /obj/item/reagent_containers/glass/bottle/cold = 1, - /obj/item/reagent_containers/glass/bottle/flu_virion = 1, - /obj/item/reagent_containers/glass/bottle/mutagen = 1, - /obj/item/reagent_containers/glass/bottle/plasma = 1, - /obj/item/reagent_containers/glass/bottle/diphenhydramine = 1 - ) . = ..() req_access_txt = "[ACCESS_VIROLOGY]" accepted_items_typecache = typecacheof(list( @@ -548,14 +630,13 @@ // I exist! /obj/machinery/smartfridge/secure/chemistry/virology/preloaded/Initialize(mapload) - spawn_meds = list( + starting_items = list( /obj/item/reagent_containers/syringe/antiviral = 4, /obj/item/reagent_containers/glass/bottle/cold = 1, /obj/item/reagent_containers/glass/bottle/flu_virion = 1, /obj/item/reagent_containers/glass/bottle/mutagen = 1, /obj/item/reagent_containers/glass/bottle/plasma = 1, - /obj/item/reagent_containers/glass/bottle/reagent/synaptizine = 1, - /obj/item/reagent_containers/glass/bottle/reagent/formaldehyde = 1 + /obj/item/reagent_containers/glass/bottle/diphenhydramine = 1 ) . = ..() @@ -568,6 +649,15 @@ req_access_txt = null /obj/machinery/smartfridge/secure/chemistry/virology/preloaded/syndicate/Initialize(mapload) + starting_items = list( + /obj/item/reagent_containers/syringe/antiviral = 4, + /obj/item/reagent_containers/glass/bottle/cold = 1, + /obj/item/reagent_containers/glass/bottle/flu_virion = 1, + /obj/item/reagent_containers/glass/bottle/mutagen = 1, + /obj/item/reagent_containers/glass/bottle/plasma = 1, + /obj/item/reagent_containers/glass/bottle/reagent/synaptizine = 1, + /obj/item/reagent_containers/glass/bottle/reagent/formaldehyde = 1 + ) . = ..() req_access = list(ACCESS_SYNDICATE) @@ -579,6 +669,7 @@ /obj/machinery/smartfridge/drinks name = "\improper Drink Showcase" desc = "A refrigerated storage unit for tasty tasty alcohol." + board_type = /obj/machinery/smartfridge/drinks /obj/machinery/smartfridge/drinks/Initialize(mapload) . = ..() diff --git a/icons/obj/vending.dmi b/icons/obj/vending.dmi index ef613913f9f..bb3c0e531b0 100755 Binary files a/icons/obj/vending.dmi and b/icons/obj/vending.dmi differ