Merge pull request #15112 from Runa-Dacino/phorontanker

Adds new Debris Field POI: Phoron Tanker!
This commit is contained in:
Casey
2023-07-05 18:28:09 -04:00
committed by GitHub
5 changed files with 1553 additions and 0 deletions
+127
View File
@@ -114,3 +114,130 @@
catalogue_data = list(/datum/category_item/catalogue/information/objects/growthcanister)
anchored = FALSE
density = TRUE
/obj/item/poi/broken_drone_circuit
name = "Central Processing Strata" //Ideally we spawn this as loot for robotic enemies
desc = "The pinnacle of artifical intelligence which can be achieved using classical computer science. \n \
This one seems somewhat damaged. Perhaps a trained roboticist could extract its memories?"
catalogue_data = list(/datum/category_item/catalogue/technology/drone/drones)
icon = 'icons/obj/module.dmi'
icon_state = "mainboard"
w_class = ITEMSIZE_NORMAL
origin_tech = list(TECH_ENGINEERING = 4, TECH_MATERIAL = 3, TECH_DATA = 4)
var/drone_name = "" //Randomly picked unless pre-defined. Used by tool examines
var/examine_multitool = "TEST_multi - CONTACT DEV" //Read by attacking with multitool
var/examine_canalyzer = "TEST_canalyzer spoken - CONTACT DEV" //Read by attacking with cyborg analyzer. Define in New() if using vars
var/examine_canalyzer_printed = "" //If we want different formatting or more detals for printed. By default unused
var/wirecutted = FALSE
var/unscrewed = FALSE
var/unlocked = FALSE
var/fried = FALSE
var/has_paper = FALSE
/obj/item/poi/broken_drone_circuit/New()
drone_name = "[pick(list("ADA","DOS","GNU","MAC","WIN","NJS","SKS","DRD","IOS","CRM","IBM","TEX","LVM","BSD",))]-[rand(1000, 9999)]]"
var/new_canalyzer = "[drone_name] [examine_canalyzer]" //Only way I could think to dynamically insert drone name here
examine_canalyzer = new_canalyzer
/obj/item/poi/broken_drone_circuit/attackby(obj/item/I as obj, mob/living/user as mob)
if(!istype(user))
return FALSE
if(fried)
to_chat(user, span_warning("[src] is covered in black marks. You feel there's nothing more you can do..."))
return FALSE
var/turf/message_turf = get_turf(user) //We use this to ensure everyone can see it!
if(istype(I, /obj/item/weapon/tool/screwdriver))
unscrewed = !unscrewed
to_chat(user, "You screw the blackbox panel [unscrewed ? "off" : "on"]")
if(istype(I, /obj/item/weapon/tool/wirecutters))
wirecutted = !wirecutted
to_chat(user, "You [wirecutted ? "cut" : "mend"] the power wire to the blackbox")
if(istype(I, /obj/item/weapon/paper) && unscrewed)
if(!has_paper)
to_chat(user, "You feed the debug printer some paper")
has_paper = TRUE
qdel(I)
else
to_chat(user, span_notice("[src] cannot hold more than 1 sheet of paper."))
if(istype(I, /obj/item/device/multitool))
if(!unscrewed && !wirecutted)
to_chat(user, span_notice("You cannot access the debug interface with the panel screwed on!"))
else if(unscrewed && !wirecutted)
message_turf.audible_message(message = examine_multitool,
deaf_message = "<b>[src]</b> flashes red repeatedly", runemessage= "Beep! Beep!")
to_chat(user, span_warning("The components spark from the multitool's unregulated pulse. \
Perhaps it'd been better to use more sophisticated tools..."))
fried = TRUE
message_turf.visible_message(message = "<b>[src]</b> FLASHES VIOLENTLY!",
blind_message = "ZAP!", runemessage = "CRACKLE!")
var/used_hand = user.get_organ(user.get_active_hand())
user.electrocute_act(10,def_zone = used_hand)
else if(wirecutted) //The security circuit is accessible outside the special panel, so we don't care for screwdrivers
to_chat(user, span_notice("You modify the security settings."))
unlocked = TRUE
if(istype(I, /obj/item/device/robotanalyzer))
if(!unscrewed)
to_chat(user, span_notice("You cannot access the debug interface with the panel screwed on!"))
else if(wirecutted)
to_chat(user, span_notice("You only receive garbled data. Perhaps you should reconnect the wires?"))
else if(!unlocked)
to_chat(user, span_danger("Security protocols seemingly engage, purging and bricking the circuit!\n \
Perhaps, it would've been a good idea to disconnect some wires while pulsing the security circuit..."))
else
if(!has_paper)
message_turf.visible_message(message = "<b>[src]</b> displays, 'PAPER NOT BIN'",
blind_message = "you hear VERY ANGRY beeping.", runemessage = "BEEP BEEP!")
message_turf.audible_message(message = "<b>[src]</b> recites, \n '[examine_canalyzer]'",
deaf_message = "<b>[src]</b> flashes green!", runemessage= "Ping!")
else
message_turf.audible_message(message = "<b>[src]</b> rattles loudly as it prints",
deaf_message = "<b>[src]</b> flashes green!", runemessage= "RATTLE RATTLE")
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper(get_turf(src))
P.name = "[drone_name] blackbox transcript"
P.info = "[examine_canalyzer_printed ? examine_canalyzer_printed : examine_canalyzer]"
has_paper = FALSE
return ..()
/obj/item/poi/broken_drone_circuit/attack_self(mob/living/user as mob)
user.visible_message(message = "[user] is studiously examining [src]", self_message = "You take your time to analyze the circuit...")
var/message = ""
if(fried)
message += "Amidst the scorch mark, you barely make out [drone_name] stenciled on the board... \n"
to_chat(user, message)
return FALSE
else
message += "You see [drone_name] stenciled onto the board on close inspection! This looks like a secure drone intelligence strata. \n"
if(unlocked)
message += "The power logic to the blackbox is scorched. Whatever secrets lie in the blackbox are yours for taking! \n"
else if(wirecutted)
message += "The power wire to the blackbox has been cut. It's safe to pulse the circuit with power, the blackbox won't fry. \n"
else if(!unscrewed && !wirecutted)
message += "The blackbox is intact, it seems to have a direct wire into the PSU. Strange... \n"
else if(unscrewed && !wirecutted)
message += "Some manner of hardwired logic seems to connect the PSU into the databanks. There is no step-down circuit. \n \
It looks like a single pulse will fry this system for good\n"
if(unscrewed && !has_paper)
message += "Looks like there's a printer without any paper in it."
if(do_after(user, delay = 5 SECONDS))
to_chat(user, message)
..()