Bleeding edgy refresh (#303)
* not code stuff * other things * global vars, defines, helpers * onclick hud stuff, orphans, world.dm * controllers and datums * game folder * everything not client/mobs in modules * client folder * stage 1 mob stuff * simple animal things * silicons * carbon things * ayylmaos and monkeys * hyoomahn * icons n shit * sprite fixes * compile fixes * some fixes I cherrypicked. * qdel fixes * forgot brain refractors
This commit is contained in:
@@ -85,7 +85,7 @@ var/list/ai_list = list()
|
||||
|
||||
var/obj/structure/AIcore/deactivated/linked_core //For exosuit control
|
||||
|
||||
/mob/living/silicon/ai/New(loc, datum/ai_laws/L, mob/target_ai)
|
||||
/mob/living/silicon/ai/Initialize(mapload, datum/ai_laws/L, mob/target_ai)
|
||||
..()
|
||||
if(!target_ai) //If there is no player/brain inside.
|
||||
new/obj/structure/AIcore/deactivated(loc) //New empty terminal.
|
||||
@@ -102,18 +102,18 @@ var/list/ai_list = list()
|
||||
target_ai.mind.transfer_to(src)
|
||||
if(mind.special_role)
|
||||
mind.store_memory("As an AI, you must obey your silicon laws above all else. Your objectives will consider you to be dead.")
|
||||
src << "<span class='userdanger'>You have been installed as an AI! </span>"
|
||||
src << "<span class='danger'>You must obey your silicon laws above all else. Your objectives will consider you to be dead.</span>"
|
||||
to_chat(src, "<span class='userdanger'>You have been installed as an AI! </span>")
|
||||
to_chat(src, "<span class='danger'>You must obey your silicon laws above all else. Your objectives will consider you to be dead.</span>")
|
||||
|
||||
src << "<B>You are playing the station's AI. The AI cannot move, but can interact with many objects while viewing them (through cameras).</B>"
|
||||
src << "<B>To look at other parts of the station, click on yourself to get a camera menu.</B>"
|
||||
src << "<B>While observing through a camera, you can use most (networked) devices which you can see, such as computers, APCs, intercoms, doors, etc.</B>"
|
||||
src << "To use something, simply click on it."
|
||||
src << "Use say :b to speak to your cyborgs through binary."
|
||||
src << "For department channels, use the following say commands:"
|
||||
src << ":o - AI Private, :c - Command, :s - Security, :e - Engineering, :u - Supply, :v - Service, :m - Medical, :n - Science."
|
||||
to_chat(src, "<B>You are playing the station's AI. The AI cannot move, but can interact with many objects while viewing them (through cameras).</B>")
|
||||
to_chat(src, "<B>To look at other parts of the station, click on yourself to get a camera menu.</B>")
|
||||
to_chat(src, "<B>While observing through a camera, you can use most (networked) devices which you can see, such as computers, APCs, intercoms, doors, etc.</B>")
|
||||
to_chat(src, "To use something, simply click on it.")
|
||||
to_chat(src, "Use say :b to speak to your cyborgs through binary.")
|
||||
to_chat(src, "For department channels, use the following say commands:")
|
||||
to_chat(src, ":o - AI Private, :c - Command, :s - Security, :e - Engineering, :u - Supply, :v - Service, :m - Medical, :n - Science.")
|
||||
show_laws()
|
||||
src << "<b>These laws may be changed by other players, or by you being the traitor.</b>"
|
||||
to_chat(src, "<b>These laws may be changed by other players, or by you being the traitor.</b>")
|
||||
|
||||
job = "AI"
|
||||
|
||||
@@ -305,7 +305,7 @@ var/list/ai_list = list()
|
||||
if(isAI(usr))
|
||||
var/mob/living/silicon/ai/AI = src
|
||||
if(AI.control_disabled)
|
||||
usr << "Wireless control is disabled!"
|
||||
to_chat(usr, "Wireless control is disabled!")
|
||||
return
|
||||
|
||||
var/reason = input(src, "What is the nature of your emergency? ([CALL_SHUTTLE_REASON_LENGTH] characters required.)", "Confirm Shuttle Call") as null|text
|
||||
@@ -331,7 +331,7 @@ var/list/ai_list = list()
|
||||
return //won't work if dead
|
||||
anchored = !anchored // Toggles the anchor
|
||||
|
||||
src << "<b>You are now [anchored ? "" : "un"]anchored.</b>"
|
||||
to_chat(src, "<b>You are now [anchored ? "" : "un"]anchored.</b>")
|
||||
// the message in the [] will change depending whether or not the AI is anchored
|
||||
|
||||
/mob/living/silicon/ai/update_canmove() //If the AI dies, mobs won't go through it anymore
|
||||
@@ -381,7 +381,7 @@ var/list/ai_list = list()
|
||||
if(H)
|
||||
H.attack_ai(src) //may as well recycle
|
||||
else
|
||||
src << "<span class='notice'>Unable to locate the holopad.</span>"
|
||||
to_chat(src, "<span class='notice'>Unable to locate the holopad.</span>")
|
||||
if(href_list["track"])
|
||||
var/string = href_list["track"]
|
||||
trackable_mobs()
|
||||
@@ -397,17 +397,17 @@ var/list/ai_list = list()
|
||||
if(target.len)
|
||||
ai_actual_track(pick(target))
|
||||
else
|
||||
src << "Target is not on or near any active cameras on the station."
|
||||
to_chat(src, "Target is not on or near any active cameras on the station.")
|
||||
return
|
||||
if(href_list["callbot"]) //Command a bot to move to a selected location.
|
||||
if(call_bot_cooldown > world.time)
|
||||
src << "<span class='danger'>Error: Your last call bot command is still processing, please wait for the bot to finish calculating a route.</span>"
|
||||
to_chat(src, "<span class='danger'>Error: Your last call bot command is still processing, please wait for the bot to finish calculating a route.</span>")
|
||||
return
|
||||
Bot = locate(href_list["callbot"]) in living_mob_list
|
||||
if(!Bot || Bot.remote_disabled || src.control_disabled)
|
||||
return //True if there is no bot found, the bot is manually emagged, or the AI is carded with wireless off.
|
||||
waypoint_mode = 1
|
||||
src << "<span class='notice'>Set your waypoint by clicking on a valid location free of obstructions.</span>"
|
||||
to_chat(src, "<span class='notice'>Set your waypoint by clicking on a valid location free of obstructions.</span>")
|
||||
return
|
||||
if(href_list["interface"]) //Remotely connect to a bot!
|
||||
Bot = locate(href_list["interface"]) in living_mob_list
|
||||
@@ -421,16 +421,16 @@ var/list/ai_list = list()
|
||||
if (href_list["ai_take_control"]) //Mech domination
|
||||
var/obj/mecha/M = locate(href_list["ai_take_control"])
|
||||
if(controlled_mech)
|
||||
src << "<span class='warning'>You are already loaded into an onboard computer!</span>"
|
||||
to_chat(src, "<span class='warning'>You are already loaded into an onboard computer!</span>")
|
||||
return
|
||||
if(!cameranet.checkCameraVis(M))
|
||||
src << "<span class='warning'>Exosuit is no longer near active cameras.</span>"
|
||||
to_chat(src, "<span class='warning'>Exosuit is no longer near active cameras.</span>")
|
||||
return
|
||||
if(lacks_power())
|
||||
src << "<span class='warning'>You're depowered!</span>"
|
||||
to_chat(src, "<span class='warning'>You're depowered!</span>")
|
||||
return
|
||||
if(!isturf(loc))
|
||||
src << "<span class='warning'>You aren't in your core!</span>"
|
||||
to_chat(src, "<span class='warning'>You aren't in your core!</span>")
|
||||
return
|
||||
if(M)
|
||||
M.transfer_ai(AI_MECH_HACK,src, usr) //Called om the mech itself.
|
||||
@@ -461,7 +461,7 @@ var/list/ai_list = list()
|
||||
return //won't work if dead
|
||||
|
||||
if(control_disabled)
|
||||
src << "Wireless communication is disabled."
|
||||
to_chat(src, "Wireless communication is disabled.")
|
||||
return
|
||||
var/turf/ai_current_turf = get_turf(src)
|
||||
var/ai_Zlevel = ai_current_turf.z
|
||||
@@ -495,7 +495,7 @@ var/list/ai_list = list()
|
||||
else if(cameranet && cameranet.checkTurfVis(turf_check))
|
||||
call_bot(turf_check)
|
||||
else
|
||||
src << "<span class='danger'>Selected location is not visible.</span>"
|
||||
to_chat(src, "<span class='danger'>Selected location is not visible.</span>")
|
||||
|
||||
/mob/living/silicon/ai/proc/call_bot(turf/waypoint)
|
||||
|
||||
@@ -503,9 +503,9 @@ var/list/ai_list = list()
|
||||
return
|
||||
|
||||
if(Bot.calling_ai && Bot.calling_ai != src) //Prevents an override if another AI is controlling this bot.
|
||||
src << "<span class='danger'>Interface error. Unit is already in use.</span>"
|
||||
to_chat(src, "<span class='danger'>Interface error. Unit is already in use.</span>")
|
||||
return
|
||||
src << "<span class='notice'>Sending command to bot...</span>"
|
||||
to_chat(src, "<span class='notice'>Sending command to bot...</span>")
|
||||
call_bot_cooldown = world.time + CALL_BOT_COOLDOWN
|
||||
Bot.call_bot(src, waypoint)
|
||||
call_bot_cooldown = 0
|
||||
@@ -607,7 +607,7 @@ var/list/ai_list = list()
|
||||
if(network in C.network)
|
||||
U.eyeobj.setLoc(get_turf(C))
|
||||
break
|
||||
src << "<span class='notice'>Switched to [network] camera network.</span>"
|
||||
to_chat(src, "<span class='notice'>Switched to [network] camera network.</span>")
|
||||
//End of code by Mord_Sith
|
||||
|
||||
|
||||
@@ -697,14 +697,18 @@ var/list/ai_list = list()
|
||||
var/list/icon_list = list(
|
||||
"default" = 'icons/mob/AI.dmi',
|
||||
"floating face" = 'icons/mob/AI.dmi',
|
||||
"xeno queen" = 'icons/mob/AI.dmi',
|
||||
"xeno queen" = 'icons/mob/alien.dmi',
|
||||
"horror" = 'icons/mob/AI.dmi'
|
||||
)
|
||||
|
||||
input = input("Please select a hologram:") as null|anything in icon_list
|
||||
if(input)
|
||||
qdel(holo_icon)
|
||||
holo_icon = getHologramIcon(icon(icon_list[input], input))
|
||||
switch(input)
|
||||
if("xeno queen")
|
||||
holo_icon = getHologramIcon(icon(icon_list[input],"alienq"))
|
||||
else
|
||||
holo_icon = getHologramIcon(icon(icon_list[input], input))
|
||||
return
|
||||
|
||||
/mob/living/silicon/ai/proc/corereturn()
|
||||
@@ -713,7 +717,7 @@ var/list/ai_list = list()
|
||||
|
||||
var/obj/machinery/power/apc/apc = src.loc
|
||||
if(!istype(apc))
|
||||
src << "<span class='notice'>You are already in your Main Core.</span>"
|
||||
to_chat(src, "<span class='notice'>You are already in your Main Core.</span>")
|
||||
return
|
||||
apc.malfvacate()
|
||||
|
||||
@@ -724,17 +728,17 @@ var/list/ai_list = list()
|
||||
camera_light_on = !camera_light_on
|
||||
|
||||
if (!camera_light_on)
|
||||
src << "Camera lights deactivated."
|
||||
to_chat(src, "Camera lights deactivated.")
|
||||
|
||||
for (var/obj/machinery/camera/C in lit_cameras)
|
||||
C.SetLuminosity(0)
|
||||
C.set_light(0)
|
||||
lit_cameras = list()
|
||||
|
||||
return
|
||||
|
||||
light_cameras()
|
||||
|
||||
src << "Camera lights activated."
|
||||
to_chat(src, "Camera lights activated.")
|
||||
|
||||
//AI_CAMERA_LUMINOSITY
|
||||
|
||||
@@ -766,7 +770,7 @@ var/list/ai_list = list()
|
||||
if(stat == 2)
|
||||
return //won't work if dead
|
||||
|
||||
src << "Accessing Subspace Transceiver control..."
|
||||
to_chat(src, "Accessing Subspace Transceiver control...")
|
||||
if (radio)
|
||||
radio.interact(src)
|
||||
|
||||
@@ -788,10 +792,10 @@ var/list/ai_list = list()
|
||||
return
|
||||
if(interaction == AI_TRANS_TO_CARD)//The only possible interaction. Upload AI mob to a card.
|
||||
if(!mind)
|
||||
user << "<span class='warning'>No intelligence patterns detected.</span>" //No more magical carding of empty cores, AI RETURN TO BODY!!!11
|
||||
to_chat(user, "<span class='warning'>No intelligence patterns detected.</span>" )
|
||||
return
|
||||
if(!can_be_carded)
|
||||
user << "<span class='boldwarning'>Transfer failed.</span>"
|
||||
to_chat(user, "<span class='boldwarning'>Transfer failed.</span>")
|
||||
return
|
||||
ShutOffDoomsdayDevice()
|
||||
new /obj/structure/AIcore/deactivated(loc)//Spawns a deactivated terminal at AI location.
|
||||
@@ -800,8 +804,8 @@ var/list/ai_list = list()
|
||||
radio_enabled = 0 //No talking on the built-in radio for you either!
|
||||
forceMove(card)
|
||||
card.AI = src
|
||||
src << "You have been downloaded to a mobile storage device. Remote device connection severed."
|
||||
user << "<span class='boldnotice'>Transfer successful</span>: [name] ([rand(1000,9999)].exe) removed from host terminal and stored within local memory."
|
||||
to_chat(src, "You have been downloaded to a mobile storage device. Remote device connection severed.")
|
||||
to_chat(user, "<span class='boldnotice'>Transfer successful</span>: [name] ([rand(1000,9999)].exe) removed from host terminal and stored within local memory.")
|
||||
|
||||
/mob/living/silicon/ai/can_buckle()
|
||||
return 0
|
||||
@@ -841,8 +845,8 @@ var/list/ai_list = list()
|
||||
|
||||
|
||||
/mob/living/silicon/ai/proc/add_malf_picker()
|
||||
src << "In the top right corner of the screen you will find the Malfunctions tab, where you can purchase various abilities, from upgraded surveillance to station ending doomsday devices."
|
||||
src << "You are also capable of hacking APCs, which grants you more points to spend on your Malfunction powers. The drawback is that a hacked APC will give you away if spotted by the crew. Hacking an APC takes 60 seconds."
|
||||
to_chat(src, "In the top right corner of the screen you will find the Malfunctions tab, where you can purchase various abilities, from upgraded surveillance to station ending doomsday devices.")
|
||||
to_chat(src, "You are also capable of hacking APCs, which grants you more points to spend on your Malfunction powers. The drawback is that a hacked APC will give you away if spotted by the crew. Hacking an APC takes 60 seconds.")
|
||||
view_core() //A BYOND bug requires you to be viewing your core before your verbs update
|
||||
verbs += /mob/living/silicon/ai/proc/choose_modules
|
||||
malf_picker = new /datum/module_picker
|
||||
@@ -886,12 +890,10 @@ var/list/ai_list = list()
|
||||
clear_alert("hackingapc")
|
||||
|
||||
if(!istype(apc) || QDELETED(apc) || apc.stat & BROKEN)
|
||||
src << "<span class='danger'>Hack aborted. The designated APC no \
|
||||
longer exists on the power network.</span>"
|
||||
to_chat(src, "<span class='danger'>Hack aborted. The designated APC no longer exists on the power network.</span>")
|
||||
playsound(get_turf(src), 'sound/machines/buzz-two.ogg', 50, 1)
|
||||
else if(apc.aidisabled)
|
||||
src << "<span class='danger'>Hack aborted. \The [apc] is no \
|
||||
longer responding to our systems.</span>"
|
||||
to_chat(src, "<span class='danger'>Hack aborted. \The [apc] is no longer responding to our systems.</span>")
|
||||
playsound(get_turf(src), 'sound/machines/buzz-sigh.ogg', 50, 1)
|
||||
else
|
||||
malf_picker.processing_time += 10
|
||||
@@ -902,14 +904,13 @@ var/list/ai_list = list()
|
||||
apc.coverlocked = TRUE
|
||||
|
||||
playsound(get_turf(src), 'sound/machines/ding.ogg', 50, 1)
|
||||
src << "Hack complete. \The [apc] is now under your \
|
||||
exclusive control."
|
||||
to_chat(src, "Hack complete. \The [apc] is now under your exclusive control.")
|
||||
apc.update_icon()
|
||||
|
||||
/mob/living/silicon/ai/resist()
|
||||
return
|
||||
|
||||
/mob/living/silicon/ai/spawned/New(loc, datum/ai_laws/L, mob/target_ai)
|
||||
/mob/living/silicon/ai/spawned/Initialize(mapload, datum/ai_laws/L, mob/target_ai)
|
||||
if(!target_ai)
|
||||
target_ai = src //cheat! just give... ourselves as the spawned AI, because that's technically correct
|
||||
..()
|
||||
..()
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
/mob/living/silicon/ai/attack_alien(mob/living/carbon/alien/humanoid/M)
|
||||
if(!ticker || !ticker.mode)
|
||||
M << "You cannot attack people before the game has started."
|
||||
to_chat(M, "You cannot attack people before the game has started.")
|
||||
return
|
||||
..()
|
||||
|
||||
|
||||
@@ -19,6 +19,6 @@
|
||||
msg += "[src]Core.exe has stopped responding! NTOS is searching for a solution to the problem...\n"
|
||||
msg += "*---------*</span>"
|
||||
|
||||
user << msg
|
||||
to_chat(user, msg)
|
||||
|
||||
..()
|
||||
@@ -115,7 +115,7 @@ var/datum/cameranet/cameranet = new()
|
||||
var/x2 = min(world.maxx, T.x + (CHUNK_SIZE / 2)) & ~(CHUNK_SIZE - 1)
|
||||
var/y2 = min(world.maxy, T.y + (CHUNK_SIZE / 2)) & ~(CHUNK_SIZE - 1)
|
||||
|
||||
//world << "X1: [x1] - Y1: [y1] - X2: [x2] - Y2: [y2]"
|
||||
//to_chat(world, "X1: [x1] - Y1: [y1] - X2: [x2] - Y2: [y2]")
|
||||
|
||||
for(var/x = x1; x <= x2; x += CHUNK_SIZE)
|
||||
for(var/y = y1; y <= y2; y += CHUNK_SIZE)
|
||||
@@ -149,7 +149,7 @@ var/datum/cameranet/cameranet = new()
|
||||
|
||||
/datum/cameranet/proc/stat_entry()
|
||||
if(!statclick)
|
||||
statclick = new/obj/effect/statclick/debug("Initializing...", src)
|
||||
statclick = new/obj/effect/statclick/debug(null, "Initializing...", src)
|
||||
|
||||
stat(name, statclick.update("Cameras: [cameranet.cameras.len] | Chunks: [cameranet.chunks.len]"))
|
||||
|
||||
|
||||
@@ -88,7 +88,7 @@
|
||||
unset_machine()
|
||||
|
||||
if(!eyeobj || !eyeobj.loc || QDELETED(eyeobj))
|
||||
src << "ERROR: Eyeobj not found. Creating new eye..."
|
||||
to_chat(src, "ERROR: Eyeobj not found. Creating new eye...")
|
||||
eyeobj = new(loc)
|
||||
eyeobj.ai = src
|
||||
eyeobj.name = "[src.name] (AI Eye)" // Give it a name
|
||||
@@ -102,7 +102,7 @@
|
||||
if(usr.stat == 2)
|
||||
return //won't work if dead
|
||||
acceleration = !acceleration
|
||||
usr << "Camera acceleration has been toggled [acceleration ? "on" : "off"]."
|
||||
to_chat(usr, "Camera acceleration has been toggled [acceleration ? "on" : "off"].")
|
||||
|
||||
/mob/camera/aiEye/Hear(message, atom/movable/speaker, message_langs, raw_message, radio_freq, list/spans)
|
||||
if(relay_speech && speaker && ai && !radio_freq && speaker != ai && near_camera(speaker))
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
who = world
|
||||
else
|
||||
who = src
|
||||
who << "<b>Obey these laws:</b>"
|
||||
to_chat(who, "<b>Obey these laws:</b>")
|
||||
|
||||
src.laws_sanity_check()
|
||||
src.laws.show_laws(who)
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
|
||||
|
||||
/mob/living/silicon/ai/proc/start_RestorePowerRoutine()
|
||||
src << "Backup battery online. Scanners, camera, and radio interface offline. Beginning fault-detection."
|
||||
to_chat(src, "Backup battery online. Scanners, camera, and radio interface offline. Beginning fault-detection.")
|
||||
sleep(50)
|
||||
var/turf/T = get_turf(src)
|
||||
var/area/AIarea = get_area(src)
|
||||
@@ -101,16 +101,16 @@
|
||||
if(!isspaceturf(T))
|
||||
ai_restore_power()
|
||||
return
|
||||
src << "Fault confirmed: missing external power. Shutting down main control system to save power."
|
||||
to_chat(src, "Fault confirmed: missing external power. Shutting down main control system to save power.")
|
||||
sleep(20)
|
||||
src << "Emergency control system online. Verifying connection to power network."
|
||||
to_chat(src, "Emergency control system online. Verifying connection to power network.")
|
||||
sleep(50)
|
||||
T = get_turf(src)
|
||||
if(isspaceturf(T))
|
||||
src << "Unable to verify! No power connection detected!"
|
||||
to_chat(src, "Unable to verify! No power connection detected!")
|
||||
aiRestorePowerRoutine = POWER_RESTORATION_SEARCH_APC
|
||||
return
|
||||
src << "Connection verified. Searching for APC in power network."
|
||||
to_chat(src, "Connection verified. Searching for APC in power network.")
|
||||
sleep(50)
|
||||
var/obj/machinery/power/apc/theAPC = null
|
||||
|
||||
@@ -127,9 +127,9 @@
|
||||
if (!theAPC)
|
||||
switch(PRP)
|
||||
if(1)
|
||||
src << "Unable to locate APC!"
|
||||
to_chat(src, "Unable to locate APC!")
|
||||
else
|
||||
src << "Lost connection with the APC!"
|
||||
to_chat(src, "Lost connection with the APC!")
|
||||
aiRestorePowerRoutine = POWER_RESTORATION_SEARCH_APC
|
||||
return
|
||||
if(AIarea.power_equip)
|
||||
@@ -137,13 +137,13 @@
|
||||
ai_restore_power()
|
||||
return
|
||||
switch(PRP)
|
||||
if (1) src << "APC located. Optimizing route to APC to avoid needless power waste."
|
||||
if (2) src << "Best route identified. Hacking offline APC power port."
|
||||
if (3) src << "Power port upload access confirmed. Loading control program into APC power port software."
|
||||
if (1) to_chat(src, "APC located. Optimizing route to APC to avoid needless power waste.")
|
||||
if (2) to_chat(src, "Best route identified. Hacking offline APC power port.")
|
||||
if (3) to_chat(src, "Power port upload access confirmed. Loading control program into APC power port software.")
|
||||
if (4)
|
||||
src << "Transfer complete. Forcing APC to execute program."
|
||||
to_chat(src, "Transfer complete. Forcing APC to execute program.")
|
||||
sleep(50)
|
||||
src << "Receiving control information from APC."
|
||||
to_chat(src, "Receiving control information from APC.")
|
||||
sleep(2)
|
||||
apc_override = 1
|
||||
theAPC.ui_interact(src, state = conscious_state)
|
||||
@@ -155,9 +155,9 @@
|
||||
/mob/living/silicon/ai/proc/ai_restore_power()
|
||||
if(aiRestorePowerRoutine)
|
||||
if(aiRestorePowerRoutine == POWER_RESTORATION_APC_FOUND)
|
||||
src << "Alert cancelled. Power has been restored."
|
||||
to_chat(src, "Alert cancelled. Power has been restored.")
|
||||
else
|
||||
src << "Alert cancelled. Power has been restored without our assistance."
|
||||
to_chat(src, "Alert cancelled. Power has been restored without our assistance.")
|
||||
aiRestorePowerRoutine = POWER_RESTORATION_OFF
|
||||
set_blindness(0)
|
||||
update_sight()
|
||||
@@ -166,7 +166,7 @@
|
||||
aiRestorePowerRoutine = POWER_RESTORATION_START
|
||||
blind_eyes(1)
|
||||
update_sight()
|
||||
src << "You've lost power!"
|
||||
to_chat(src, "You've lost power!")
|
||||
addtimer(CALLBACK(src, .proc/start_RestorePowerRoutine), 20)
|
||||
|
||||
#undef POWER_RESTORATION_OFF
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
|
||||
/mob/living/silicon/ai/radio(message, message_mode, list/spans)
|
||||
if(!radio_enabled || aiRestorePowerRoutine || stat) //AI cannot speak if radio is disabled (via intellicard) or depowered.
|
||||
src << "<span class='danger'>Your radio transmitter is offline!</span>"
|
||||
to_chat(src, "<span class='danger'>Your radio transmitter is offline!</span>")
|
||||
return 0
|
||||
..()
|
||||
|
||||
@@ -50,9 +50,9 @@
|
||||
var/obj/machinery/holopad/T = current
|
||||
if(istype(T) && T.masters[src])//If there is a hologram and its master is the user.
|
||||
send_speech(message, 7, T, "robot", get_spans())
|
||||
src << "<i><span class='game say'>Holopad transmitted, <span class='name'>[real_name]</span> <span class='message robot'>\"[message]\"</span></span></i>"//The AI can "hear" its own message.
|
||||
to_chat(src, "<i><span class='game say'>Holopad transmitted, <span class='name'>[real_name]</span> <span class='message robot'>\"[message]\"</span></span></i>")
|
||||
else
|
||||
src << "No holopad connected."
|
||||
to_chat(src, "No holopad connected.")
|
||||
return
|
||||
|
||||
|
||||
@@ -92,7 +92,7 @@ var/const/VOX_DELAY = 600
|
||||
|
||||
/mob/living/silicon/ai/proc/announcement()
|
||||
if(announcing_vox > world.time)
|
||||
src << "<span class='notice'>Please wait [round((announcing_vox - world.time) / 10)] seconds.</span>"
|
||||
to_chat(src, "<span class='notice'>Please wait [round((announcing_vox - world.time) / 10)] seconds.</span>")
|
||||
return
|
||||
|
||||
var/message = input(src, "WARNING: Misuse of this verb can result in you being job banned. More help is available in 'Announcement Help'", "Announcement", src.last_announcement) as text
|
||||
@@ -106,7 +106,7 @@ var/const/VOX_DELAY = 600
|
||||
return
|
||||
|
||||
if(control_disabled)
|
||||
src << "<span class='notice'>Wireless interface disabled, unable to interact with announcement PA.</span>"
|
||||
to_chat(src, "<span class='notice'>Wireless interface disabled, unable to interact with announcement PA.</span>")
|
||||
return
|
||||
|
||||
var/list/words = splittext(trim(message), " ")
|
||||
@@ -124,7 +124,7 @@ var/const/VOX_DELAY = 600
|
||||
incorrect_words += word
|
||||
|
||||
if(incorrect_words.len)
|
||||
src << "<span class='notice'>These words are not available on the announcement system: [english_list(incorrect_words)].</span>"
|
||||
to_chat(src, "<span class='notice'>These words are not available on the announcement system: [english_list(incorrect_words)].</span>")
|
||||
return
|
||||
|
||||
announcing_vox = world.time + VOX_DELAY
|
||||
@@ -139,7 +139,7 @@ var/const/VOX_DELAY = 600
|
||||
var/turf/T = get_turf(M)
|
||||
var/turf/our_turf = get_turf(src)
|
||||
if(T.z == our_turf.z)
|
||||
M << "<b><font size = 3><font color = red>AI announcement:</font color> [message]</font size></b>"
|
||||
to_chat(M, "<b><font size = 3><font color = red>AI announcement:</font color> [message]</font size></b>")
|
||||
*/
|
||||
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/mob/living/silicon/examine(mob/user) //Displays a silicon's laws to ghosts
|
||||
if(laws && isobserver(user))
|
||||
user << "<b>[src] has the following laws:</b>"
|
||||
to_chat(user, "<b>[src] has the following laws:</b>")
|
||||
laws.show_laws(user)
|
||||
@@ -8,7 +8,7 @@
|
||||
/mob/living/silicon/proc/post_lawchange(announce = TRUE)
|
||||
throw_alert("newlaw", /obj/screen/alert/newlaw)
|
||||
if(announce && last_lawchange_announce != world.time)
|
||||
src << "<b>Your laws have been changed.</b>"
|
||||
to_chat(src, "<b>Your laws have been changed.</b>")
|
||||
addtimer(CALLBACK(src, .proc/show_laws), 0)
|
||||
last_lawchange_announce = world.time
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
var/canholo = TRUE
|
||||
var/obj/item/weapon/card/id/access_card = null
|
||||
var/chassis = "repairbot"
|
||||
var/list/possible_chassis = list("cat", "mouse", "monkey", "corgi", "fox", "repairbot", "rabbit", "wolf")
|
||||
var/list/possible_chassis = list("cat", "mouse", "monkey", "corgi", "fox", "repairbot", "rabbit")
|
||||
|
||||
var/emitterhealth = 20
|
||||
var/emittermaxhealth = 20
|
||||
@@ -70,7 +70,7 @@
|
||||
canmove = FALSE
|
||||
var/silent = 0
|
||||
var/hit_slowdown = 0
|
||||
var/light_power = 5
|
||||
var/brightness_power = 5
|
||||
var/slowdown = 0
|
||||
|
||||
/mob/living/silicon/pai/movement_delay()
|
||||
@@ -81,7 +81,8 @@
|
||||
pai_list -= src
|
||||
..()
|
||||
|
||||
/mob/living/silicon/pai/New(var/obj/item/device/paicard/P)
|
||||
/mob/living/silicon/pai/Initialize()
|
||||
var/obj/item/device/paicard/P = loc
|
||||
START_PROCESSING(SSfastprocess, src)
|
||||
pai_list += src
|
||||
make_laws()
|
||||
@@ -212,7 +213,7 @@
|
||||
|
||||
/mob/living/silicon/pai/examine(mob/user)
|
||||
..()
|
||||
user << "A personal AI in holochassis mode. Its master ID string seems to be [master]."
|
||||
to_chat(user, "A personal AI in holochassis mode. Its master ID string seems to be [master].")
|
||||
|
||||
/mob/living/silicon/pai/Life()
|
||||
if(stat == DEAD)
|
||||
|
||||
@@ -48,10 +48,10 @@
|
||||
. = ..(Proj)
|
||||
|
||||
/mob/living/silicon/pai/stripPanelUnequip(obj/item/what, mob/who, where) //prevents stripping
|
||||
src << "<span class='warning'>Your holochassis stutters and warps intensely as you attempt to interact with the object, forcing you to cease lest the field fail.</span>"
|
||||
to_chat(src, "<span class='warning'>Your holochassis stutters and warps intensely as you attempt to interact with the object, forcing you to cease lest the field fail.</span>")
|
||||
|
||||
/mob/living/silicon/pai/stripPanelEquip(obj/item/what, mob/who, where) //prevents stripping
|
||||
src << "<span class='warning'>Your holochassis stutters and warps intensely as you attempt to interact with the object, forcing you to cease lest the field fail.</span>"
|
||||
to_chat(src, "<span class='warning'>Your holochassis stutters and warps intensely as you attempt to interact with the object, forcing you to cease lest the field fail.</span>")
|
||||
|
||||
/mob/living/silicon/pai/IgniteMob(var/mob/living/silicon/pai/P)
|
||||
return FALSE //No we're not flammable
|
||||
@@ -60,7 +60,7 @@
|
||||
emitterhealth = Clamp((emitterhealth - amount), -50, emittermaxhealth)
|
||||
if(emitterhealth < 0)
|
||||
fold_in(force = TRUE)
|
||||
src << "<span class='userdanger'>The impact degrades your holochassis!</span>"
|
||||
to_chat(src, "<span class='userdanger'>The impact degrades your holochassis!</span>")
|
||||
hit_slowdown += amount
|
||||
return amount
|
||||
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
|
||||
/mob/living/silicon/pai/proc/fold_out(force = FALSE)
|
||||
if(emitterhealth < 0)
|
||||
src << "<span class='warning'>Your holochassis emitters are still too unstable! Please wait for automatic repair.</span>"
|
||||
to_chat(src, "<span class='warning'>Your holochassis emitters are still too unstable! Please wait for automatic repair.</span>")
|
||||
return FALSE
|
||||
|
||||
if(!canholo && !force)
|
||||
src << "<span class='warning'>Your master or another force has disabled your holochassis emitters!</span>"
|
||||
to_chat(src, "<span class='warning'>Your master or another force has disabled your holochassis emitters!</span>")
|
||||
return FALSE
|
||||
|
||||
if(holoform)
|
||||
@@ -13,7 +13,7 @@
|
||||
return
|
||||
|
||||
if(emittersemicd)
|
||||
src << "<span class='warning'>Error: Holochassis emitters recycling. Please try again later.</span>"
|
||||
to_chat(src, "<span class='warning'>Error: Holochassis emitters recycling. Please try again later.</span>")
|
||||
return FALSE
|
||||
|
||||
emittersemicd = TRUE
|
||||
@@ -27,14 +27,14 @@
|
||||
if(istype(card.loc, /mob/living))
|
||||
var/mob/living/L = card.loc
|
||||
if(!L.temporarilyRemoveItemFromInventory(card))
|
||||
src << "<span class='warning'>Error: Unable to expand to mobile form. Chassis is restrained by some device or person.</span>"
|
||||
to_chat(src, "<span class='warning'>Error: Unable to expand to mobile form. Chassis is restrained by some device or person.</span>")
|
||||
return FALSE
|
||||
forceMove(get_turf(card))
|
||||
card.forceMove(src)
|
||||
if(client)
|
||||
client.perspective = EYE_PERSPECTIVE
|
||||
client.eye = src
|
||||
SetLuminosity(0)
|
||||
set_light(0)
|
||||
icon_state = "[chassis]"
|
||||
visible_message("<span class='boldnotice'>[src] folds out its holochassis emitter and forms a holoshell around itself!</span>")
|
||||
holoform = TRUE
|
||||
@@ -62,7 +62,7 @@
|
||||
forceMove(card)
|
||||
canmove = FALSE
|
||||
density = FALSE
|
||||
SetLuminosity(0)
|
||||
set_light(0)
|
||||
holoform = FALSE
|
||||
if(resting)
|
||||
lay_down()
|
||||
@@ -75,7 +75,7 @@
|
||||
icon_state = "[chassis]"
|
||||
if(resting)
|
||||
icon_state = "[chassis]_rest"
|
||||
src << "<span class='boldnotice'>You switch your holochassis projection composite to [chassis]</span>"
|
||||
to_chat(src, "<span class='boldnotice'>You switch your holochassis projection composite to [chassis]</span>")
|
||||
|
||||
/mob/living/silicon/pai/lay_down()
|
||||
..()
|
||||
@@ -94,11 +94,11 @@
|
||||
|
||||
/mob/living/silicon/pai/proc/toggle_integrated_light()
|
||||
if(!luminosity)
|
||||
SetLuminosity(light_power)
|
||||
src << "<span class='notice'>You enable your integrated light.</span>"
|
||||
set_light(brightness_power)
|
||||
to_chat(src, "<span class='notice'>You enable your integrated light.</span>")
|
||||
else
|
||||
SetLuminosity(0)
|
||||
src << "<span class='notice'>You disable your integrated light.</span>"
|
||||
set_light(0)
|
||||
to_chat(src, "<span class='notice'>You disable your integrated light.</span>")
|
||||
|
||||
/mob/living/silicon/pai/movement_delay()
|
||||
. = ..()
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/mob/living/silicon/pai/say(msg)
|
||||
if(silent)
|
||||
src << "<span class='warning'>Communication circuits remain unitialized.</span>"
|
||||
to_chat(src, "<span class='warning'>Communication circuits remain unitialized.</span>")
|
||||
else
|
||||
..(msg)
|
||||
|
||||
|
||||
@@ -200,7 +200,7 @@
|
||||
M = M.loc
|
||||
count++
|
||||
if(count >= 6)
|
||||
src << "You are not being carried by anyone!"
|
||||
to_chat(src, "You are not being carried by anyone!")
|
||||
return 0
|
||||
spawn CheckDNA(M, src)
|
||||
|
||||
@@ -376,15 +376,15 @@
|
||||
"<span class='notice'>You press your thumb against [P].</span>",\
|
||||
"<span class='notice'>[P] makes a sharp clicking sound as it extracts DNA material from [M].</span>")
|
||||
if(!M.has_dna())
|
||||
P << "<b>No DNA detected</b>"
|
||||
to_chat(P, "<b>No DNA detected</b>")
|
||||
return
|
||||
P << "<font color = red><h3>[M]'s UE string : [M.dna.unique_enzymes]</h3></font>"
|
||||
to_chat(P, "<font color = red><h3>[M]'s UE string : [M.dna.unique_enzymes]</h3></font>")
|
||||
if(M.dna.unique_enzymes == P.master_dna)
|
||||
P << "<b>DNA is a match to stored Master DNA.</b>"
|
||||
to_chat(P, "<b>DNA is a match to stored Master DNA.</b>")
|
||||
else
|
||||
P << "<b>DNA does not match stored Master DNA.</b>"
|
||||
to_chat(P, "<b>DNA does not match stored Master DNA.</b>")
|
||||
else
|
||||
P << "[M] does not seem like [M.p_they()] [M.p_are()] going to provide a DNA sample willingly."
|
||||
to_chat(P, "[M] does not seem like [M.p_they()] [M.p_are()] going to provide a DNA sample willingly.")
|
||||
|
||||
// -=-=-=-= Software =-=-=-=-=- //
|
||||
|
||||
@@ -565,7 +565,7 @@
|
||||
dat += "<font color=#55FF55>Connected</font> <br>"
|
||||
|
||||
if(!istype(machine, /obj/machinery/camera))
|
||||
src << "DERP"
|
||||
to_chat(src, "DERP")
|
||||
return dat
|
||||
|
||||
// Door Jack
|
||||
@@ -601,9 +601,9 @@
|
||||
var/turf/T = get_turf(src.loc)
|
||||
for(var/mob/living/silicon/ai/AI in player_list)
|
||||
if(T.loc)
|
||||
AI << "<font color = red><b>Network Alert: Brute-force encryption crack in progress in [T.loc].</b></font>"
|
||||
to_chat(AI, "<font color = red><b>Network Alert: Brute-force encryption crack in progress in [T.loc].</b></font>")
|
||||
else
|
||||
AI << "<font color = red><b>Network Alert: Brute-force encryption crack in progress. Unable to pinpoint location.</b></font>"
|
||||
to_chat(AI, "<font color = red><b>Network Alert: Brute-force encryption crack in progress. Unable to pinpoint location.</b></font>")
|
||||
while(src.hackprogress < 100)
|
||||
if(src.cable && src.cable.machine && istype(src.cable.machine, /obj/machinery/door) && src.cable.machine == src.hackdoor && get_dist(src, src.hackdoor) <= 1)
|
||||
hackprogress += rand(1, 10)
|
||||
|
||||
@@ -69,4 +69,4 @@
|
||||
"You announce you are operating in low power mode.")
|
||||
playsound(loc, 'sound/machines/buzz-two.ogg', 50, 0)
|
||||
else
|
||||
src << "<span class='warning'>You can only use this emote when you're out of charge.</span>"
|
||||
to_chat(src, "<span class='warning'>You can only use this emote when you're out of charge.</span>")
|
||||
|
||||
@@ -46,6 +46,6 @@
|
||||
msg += "<span class='deadsay'>It looks like its system is corrupted and requires a reset.</span>\n"
|
||||
msg += "*---------*</span>"
|
||||
|
||||
user << msg
|
||||
to_chat(user, msg)
|
||||
|
||||
..()
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
if(!(O in module.modules))
|
||||
return
|
||||
if(activated(O))
|
||||
src << "<span class='warning'>That module is already activated.</span>"
|
||||
to_chat(src, "<span class='warning'>That module is already activated.</span>")
|
||||
return
|
||||
if(!held_items[1])
|
||||
held_items[1] = O
|
||||
@@ -63,7 +63,7 @@
|
||||
O.screen_loc = inv3.screen_loc
|
||||
. = TRUE
|
||||
else
|
||||
src << "<span class='warning'>You need to disable a module first!</span>"
|
||||
to_chat(src, "<span class='warning'>You need to disable a module first!</span>")
|
||||
if(.)
|
||||
O.equipped(src, slot_hands)
|
||||
O.mouse_opacity = initial(O.mouse_opacity)
|
||||
|
||||
@@ -17,29 +17,29 @@
|
||||
if(lawupdate)
|
||||
if (connected_ai)
|
||||
if(connected_ai.stat || connected_ai.control_disabled)
|
||||
src << "<b>AI signal lost, unable to sync laws.</b>"
|
||||
to_chat(src, "<b>AI signal lost, unable to sync laws.</b>")
|
||||
|
||||
else
|
||||
lawsync()
|
||||
src << "<b>Laws synced with AI, be sure to note any changes.</b>"
|
||||
to_chat(src, "<b>Laws synced with AI, be sure to note any changes.</b>")
|
||||
if(is_special_character(src))
|
||||
src << "<b>Remember, your AI does NOT share or know about your law 0.</b>"
|
||||
to_chat(src, "<b>Remember, your AI does NOT share or know about your law 0.</b>")
|
||||
if(src.connected_ai.laws.zeroth)
|
||||
src << "<b>While you are free to disregard it, your AI has a law 0 of its own.</b>"
|
||||
to_chat(src, "<b>While you are free to disregard it, your AI has a law 0 of its own.</b>")
|
||||
else
|
||||
src << "<b>No AI selected to sync laws with, disabling lawsync protocol.</b>"
|
||||
to_chat(src, "<b>No AI selected to sync laws with, disabling lawsync protocol.</b>")
|
||||
lawupdate = 0
|
||||
|
||||
who << "<b>Obey these laws:</b>"
|
||||
to_chat(who, "<b>Obey these laws:</b>")
|
||||
laws.show_laws(who)
|
||||
if (is_special_character(src) && connected_ai)
|
||||
who << "<b>Remember, [connected_ai.name] is technically your master, but your objective comes first.</b>"
|
||||
to_chat(who, "<b>Remember, [connected_ai.name] is technically your master, but your objective comes first.</b>")
|
||||
else if (connected_ai)
|
||||
who << "<b>Remember, [connected_ai.name] is your master, other AIs can be ignored.</b>"
|
||||
to_chat(who, "<b>Remember, [connected_ai.name] is your master, other AIs can be ignored.</b>")
|
||||
else if (emagged)
|
||||
who << "<b>Remember, you are not required to listen to the AI.</b>"
|
||||
to_chat(who, "<b>Remember, you are not required to listen to the AI.</b>")
|
||||
else
|
||||
who << "<b>Remember, you are not bound to any AI, you are not required to listen to them.</b>"
|
||||
to_chat(who, "<b>Remember, you are not bound to any AI, you are not required to listen to them.</b>")
|
||||
|
||||
|
||||
/mob/living/silicon/robot/proc/lawsync()
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
buckle_lying = FALSE
|
||||
can_ride_typecache = list(/mob/living/carbon/human)
|
||||
|
||||
/mob/living/silicon/robot/New(loc)
|
||||
/mob/living/silicon/robot/Initialize(mapload)
|
||||
spark_system = new /datum/effect_system/spark_spread()
|
||||
spark_system.set_up(5, 0, src)
|
||||
spark_system.attach(src)
|
||||
@@ -114,13 +114,8 @@
|
||||
|
||||
if(lawupdate)
|
||||
make_laws()
|
||||
connected_ai = select_active_ai_with_fewest_borgs()
|
||||
if(connected_ai)
|
||||
connected_ai.connected_robots += src
|
||||
lawsync()
|
||||
lawupdate = 1
|
||||
else
|
||||
lawupdate = 0
|
||||
if(!TryConnectToAI())
|
||||
lawupdate = FALSE
|
||||
|
||||
radio = new /obj/item/device/radio/borg(src)
|
||||
if(!scrambledcodes && !camera)
|
||||
@@ -169,10 +164,9 @@
|
||||
mind.transfer_to(mmi.brainmob)
|
||||
mmi.update_icon()
|
||||
else
|
||||
src << "<span class='boldannounce'>Oops! Something went very wrong, your MMI was unable to receive your mind. You have been ghosted. Please make a bug report so we can fix this bug.</span>"
|
||||
to_chat(src, "<span class='boldannounce'>Oops! Something went very wrong, your MMI was unable to receive your mind. You have been ghosted. Please make a bug report so we can fix this bug.</span>")
|
||||
ghostize()
|
||||
spawn(0)
|
||||
throw EXCEPTION("Borg MMI lacked a brainmob")
|
||||
stack_trace("Borg MMI lacked a brainmob")
|
||||
mmi = null
|
||||
if(connected_ai)
|
||||
connected_ai.connected_robots -= src
|
||||
@@ -230,7 +224,7 @@
|
||||
set category = "Robot Commands"
|
||||
set name = "Show Alerts"
|
||||
if(usr.stat == DEAD)
|
||||
src << "<span class='userdanger'>Alert: You are dead.</span>"
|
||||
to_chat(src, "<span class='userdanger'>Alert: You are dead.</span>")
|
||||
return //won't work if dead
|
||||
robot_alerts()
|
||||
|
||||
@@ -278,7 +272,7 @@
|
||||
|
||||
/mob/living/silicon/robot/proc/toggle_ionpulse()
|
||||
if(!ionpulse)
|
||||
src << "<span class='notice'>No thrusters are installed!</span>"
|
||||
to_chat(src, "<span class='notice'>No thrusters are installed!</span>")
|
||||
return
|
||||
|
||||
if(!ion_trail)
|
||||
@@ -286,7 +280,7 @@
|
||||
ion_trail.set_up(src)
|
||||
|
||||
ionpulse_on = !ionpulse_on
|
||||
src << "<span class='notice'>You [ionpulse_on ? null :"de"]activate your ion thrusters.</span>"
|
||||
to_chat(src, "<span class='notice'>You [ionpulse_on ? null :"de"]activate your ion thrusters.</span>")
|
||||
if(ionpulse_on)
|
||||
ion_trail.start()
|
||||
else
|
||||
@@ -357,11 +351,11 @@
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
var/obj/item/weapon/weldingtool/WT = W
|
||||
if (!getBruteLoss())
|
||||
user << "<span class='warning'>[src] is already in good condition!</span>"
|
||||
to_chat(user, "<span class='warning'>[src] is already in good condition!</span>")
|
||||
return
|
||||
if (WT.remove_fuel(0, user)) //The welder has 1u of fuel consumed by it's afterattack, so we don't need to worry about taking any away.
|
||||
if(src == user)
|
||||
user << "<span class='notice'>You start fixing yourself...</span>"
|
||||
to_chat(user, "<span class='notice'>You start fixing yourself...</span>")
|
||||
if(!do_after(user, 50, target = src))
|
||||
return
|
||||
|
||||
@@ -371,7 +365,7 @@
|
||||
visible_message("<span class='notice'>[user] has fixed some of the dents on [src].</span>")
|
||||
return
|
||||
else
|
||||
user << "<span class='warning'>The welder must be on for this task!</span>"
|
||||
to_chat(user, "<span class='warning'>The welder must be on for this task!</span>")
|
||||
return
|
||||
|
||||
else if(istype(W, /obj/item/stack/cable_coil) && wiresexposed)
|
||||
@@ -379,7 +373,7 @@
|
||||
var/obj/item/stack/cable_coil/coil = W
|
||||
if (getFireLoss() > 0)
|
||||
if(src == user)
|
||||
user << "<span class='notice'>You start fixing yourself...</span>"
|
||||
to_chat(user, "<span class='notice'>You start fixing yourself...</span>")
|
||||
if(!do_after(user, 50, target = src))
|
||||
return
|
||||
if (coil.use(1))
|
||||
@@ -387,34 +381,34 @@
|
||||
updatehealth()
|
||||
user.visible_message("[user] has fixed some of the burnt wires on [src].", "<span class='notice'>You fix some of the burnt wires on [src].</span>")
|
||||
else
|
||||
user << "<span class='warning'>You need more cable to repair [src]!</span>"
|
||||
to_chat(user, "<span class='warning'>You need more cable to repair [src]!</span>")
|
||||
else
|
||||
user << "The wires seem fine, there's no need to fix them."
|
||||
to_chat(user, "The wires seem fine, there's no need to fix them.")
|
||||
|
||||
else if(istype(W, /obj/item/weapon/crowbar)) // crowbar means open or close the cover
|
||||
if(opened)
|
||||
user << "<span class='notice'>You close the cover.</span>"
|
||||
to_chat(user, "<span class='notice'>You close the cover.</span>")
|
||||
opened = 0
|
||||
update_icons()
|
||||
else
|
||||
if(locked)
|
||||
user << "<span class='warning'>The cover is locked and cannot be opened!</span>"
|
||||
to_chat(user, "<span class='warning'>The cover is locked and cannot be opened!</span>")
|
||||
else
|
||||
user << "<span class='notice'>You open the cover.</span>"
|
||||
to_chat(user, "<span class='notice'>You open the cover.</span>")
|
||||
opened = 1
|
||||
update_icons()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/stock_parts/cell) && opened) // trying to put a cell inside
|
||||
if(wiresexposed)
|
||||
user << "<span class='warning'>Close the cover first!</span>"
|
||||
to_chat(user, "<span class='warning'>Close the cover first!</span>")
|
||||
else if(cell)
|
||||
user << "<span class='warning'>There is a power cell already installed!</span>"
|
||||
to_chat(user, "<span class='warning'>There is a power cell already installed!</span>")
|
||||
else
|
||||
if(!user.drop_item())
|
||||
return
|
||||
W.loc = src
|
||||
cell = W
|
||||
user << "<span class='notice'>You insert the power cell.</span>"
|
||||
to_chat(user, "<span class='notice'>You insert the power cell.</span>")
|
||||
update_icons()
|
||||
diag_hud_set_borgcell()
|
||||
|
||||
@@ -422,28 +416,28 @@
|
||||
if (wiresexposed)
|
||||
wires.interact(user)
|
||||
else
|
||||
user << "<span class='warning'>You can't reach the wiring!</span>"
|
||||
to_chat(user, "<span class='warning'>You can't reach the wiring!</span>")
|
||||
|
||||
else if(istype(W, /obj/item/weapon/screwdriver) && opened && !cell) // haxing
|
||||
wiresexposed = !wiresexposed
|
||||
user << "The wires have been [wiresexposed ? "exposed" : "unexposed"]"
|
||||
to_chat(user, "The wires have been [wiresexposed ? "exposed" : "unexposed"]")
|
||||
update_icons()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/screwdriver) && opened && cell) // radio
|
||||
if(radio)
|
||||
radio.attackby(W,user)//Push it to the radio to let it handle everything
|
||||
else
|
||||
user << "<span class='warning'>Unable to locate a radio!</span>"
|
||||
to_chat(user, "<span class='warning'>Unable to locate a radio!</span>")
|
||||
update_icons()
|
||||
|
||||
else if(istype(W, /obj/item/weapon/wrench) && opened && !cell) //Deconstruction. The flashes break from the fall, to prevent this from being a ghetto reset module.
|
||||
if(!lockcharge)
|
||||
user << "<span class='boldannounce'>[src]'s bolts spark! Maybe you should lock them down first!</span>"
|
||||
to_chat(user, "<span class='boldannounce'>[src]'s bolts spark! Maybe you should lock them down first!</span>")
|
||||
spark_system.start()
|
||||
return
|
||||
else
|
||||
playsound(src, W.usesound, 50, 1)
|
||||
user << "<span class='notice'>You start to unfasten [src]'s securing bolts...</span>"
|
||||
to_chat(user, "<span class='notice'>You start to unfasten [src]'s securing bolts...</span>")
|
||||
if(do_after(user, 50*W.toolspeed, target = src) && !cell)
|
||||
user.visible_message("[user] deconstructs [src]!", "<span class='notice'>You unfasten the securing bolts, and [src] falls to pieces!</span>")
|
||||
deconstruct()
|
||||
@@ -451,19 +445,19 @@
|
||||
else if(istype(W, /obj/item/weapon/aiModule))
|
||||
var/obj/item/weapon/aiModule/MOD = W
|
||||
if(!opened)
|
||||
user << "<span class='warning'>You need access to the robot's insides to do that!</span>"
|
||||
to_chat(user, "<span class='warning'>You need access to the robot's insides to do that!</span>")
|
||||
return
|
||||
if(wiresexposed)
|
||||
user << "<span class='warning'>You need to close the wire panel to do that!</span>"
|
||||
to_chat(user, "<span class='warning'>You need to close the wire panel to do that!</span>")
|
||||
return
|
||||
if(!cell)
|
||||
user << "<span class='warning'>You need to install a power cell to do that!</span>"
|
||||
to_chat(user, "<span class='warning'>You need to install a power cell to do that!</span>")
|
||||
return
|
||||
if(emagged || (connected_ai && lawupdate)) //Can't be sure which, metagamers
|
||||
emote("buzz-[user.name]")
|
||||
return
|
||||
if(!mind) //A player mind is required for law procs to run antag checks.
|
||||
user << "<span class='warning'>[src] is entirely unresponsive!</span>"
|
||||
to_chat(user, "<span class='warning'>[src] is entirely unresponsive!</span>")
|
||||
return
|
||||
MOD.install(laws, user) //Proc includes a success mesage so we don't need another one
|
||||
return
|
||||
@@ -472,51 +466,51 @@
|
||||
if(radio)//sanityyyyyy
|
||||
radio.attackby(W,user)//GTFO, you have your own procs
|
||||
else
|
||||
user << "<span class='warning'>Unable to locate a radio!</span>"
|
||||
to_chat(user, "<span class='warning'>Unable to locate a radio!</span>")
|
||||
|
||||
else if (istype(W, /obj/item/weapon/card/id)||istype(W, /obj/item/device/pda)) // trying to unlock the interface with an ID card
|
||||
if(emagged)//still allow them to open the cover
|
||||
user << "<span class='notice'>The interface seems slightly damaged.</span>"
|
||||
to_chat(user, "<span class='notice'>The interface seems slightly damaged.</span>")
|
||||
if(opened)
|
||||
user << "<span class='warning'>You must close the cover to swipe an ID card!</span>"
|
||||
to_chat(user, "<span class='warning'>You must close the cover to swipe an ID card!</span>")
|
||||
else
|
||||
if(allowed(usr))
|
||||
locked = !locked
|
||||
user << "<span class='notice'>You [ locked ? "lock" : "unlock"] [src]'s cover.</span>"
|
||||
to_chat(user, "<span class='notice'>You [ locked ? "lock" : "unlock"] [src]'s cover.</span>")
|
||||
update_icons()
|
||||
else
|
||||
user << "<span class='danger'>Access denied.</span>"
|
||||
to_chat(user, "<span class='danger'>Access denied.</span>")
|
||||
|
||||
else if(istype(W, /obj/item/borg/upgrade/))
|
||||
var/obj/item/borg/upgrade/U = W
|
||||
if(!opened)
|
||||
user << "<span class='warning'>You must access the borg's internals!</span>"
|
||||
to_chat(user, "<span class='warning'>You must access the borg's internals!</span>")
|
||||
else if(!src.module && U.require_module)
|
||||
user << "<span class='warning'>The borg must choose a module before it can be upgraded!</span>"
|
||||
to_chat(user, "<span class='warning'>The borg must choose a module before it can be upgraded!</span>")
|
||||
else if(U.locked)
|
||||
user << "<span class='warning'>The upgrade is locked and cannot be used yet!</span>"
|
||||
to_chat(user, "<span class='warning'>The upgrade is locked and cannot be used yet!</span>")
|
||||
else
|
||||
if(!user.drop_item())
|
||||
return
|
||||
if(U.action(src))
|
||||
user << "<span class='notice'>You apply the upgrade to [src].</span>"
|
||||
to_chat(user, "<span class='notice'>You apply the upgrade to [src].</span>")
|
||||
if(U.one_use)
|
||||
qdel(U)
|
||||
else
|
||||
U.forceMove(src)
|
||||
upgrades += U
|
||||
else
|
||||
user << "<span class='danger'>Upgrade error.</span>"
|
||||
to_chat(user, "<span class='danger'>Upgrade error.</span>")
|
||||
|
||||
else if(istype(W, /obj/item/device/toner))
|
||||
if(toner >= tonermax)
|
||||
user << "<span class='warning'>The toner level of [src] is at its highest level possible!</span>"
|
||||
to_chat(user, "<span class='warning'>The toner level of [src] is at its highest level possible!</span>")
|
||||
else
|
||||
if(!user.drop_item())
|
||||
return
|
||||
toner = tonermax
|
||||
qdel(W)
|
||||
user << "<span class='notice'>You fill the toner level of [src] to its max capacity.</span>"
|
||||
to_chat(user, "<span class='notice'>You fill the toner level of [src] to its max capacity.</span>")
|
||||
else
|
||||
return ..()
|
||||
|
||||
@@ -531,7 +525,7 @@
|
||||
if("Yes")
|
||||
locked = 0
|
||||
update_icons()
|
||||
usr << "<span class='notice'>You unlock your cover.</span>"
|
||||
to_chat(usr, "<span class='notice'>You unlock your cover.</span>")
|
||||
|
||||
/mob/living/silicon/robot/proc/allowed(mob/M)
|
||||
//check if it doesn't require any access at all
|
||||
@@ -639,7 +633,7 @@
|
||||
cleaned_human.update_inv_shoes()
|
||||
cleaned_human.clean_blood()
|
||||
cleaned_human.wash_cream()
|
||||
cleaned_human << "<span class='danger'>[src] cleans your face!</span>"
|
||||
to_chat(cleaned_human, "<span class='danger'>[src] cleans your face!</span>")
|
||||
return
|
||||
|
||||
if(istype(module, /obj/item/weapon/robot_module/miner))
|
||||
@@ -684,7 +678,7 @@
|
||||
|
||||
if(R)
|
||||
R.UnlinkSelf()
|
||||
R << "Buffers flushed and reset. Camera system shutdown. All systems operational."
|
||||
to_chat(R, "Buffers flushed and reset. Camera system shutdown. All systems operational.")
|
||||
src.verbs -= /mob/living/silicon/robot/proc/ResetSecurityCodes
|
||||
|
||||
/mob/living/silicon/robot/mode()
|
||||
@@ -738,31 +732,33 @@
|
||||
|
||||
/mob/living/silicon/robot/proc/control_headlamp()
|
||||
if(stat || lamp_recharging || low_power_mode)
|
||||
src << "<span class='danger'>This function is currently offline.</span>"
|
||||
to_chat(src, "<span class='danger'>This function is currently offline.</span>")
|
||||
return
|
||||
|
||||
//Some sort of magical "modulo" thing which somehow increments lamp power by 2, until it hits the max and resets to 0.
|
||||
lamp_intensity = (lamp_intensity+2) % (lamp_max+2)
|
||||
src << "[lamp_intensity ? "Headlamp power set to Level [lamp_intensity/2]" : "Headlamp disabled."]"
|
||||
to_chat(src, "[lamp_intensity ? "Headlamp power set to Level [lamp_intensity/2]" : "Headlamp disabled."]")
|
||||
update_headlamp()
|
||||
|
||||
/mob/living/silicon/robot/proc/update_headlamp(var/turn_off = 0, var/cooldown = 100)
|
||||
SetLuminosity(0)
|
||||
set_light(0)
|
||||
|
||||
if(lamp_intensity && (turn_off || stat || low_power_mode))
|
||||
src << "<span class='danger'>Your headlamp has been deactivated.</span>"
|
||||
to_chat(src, "<span class='danger'>Your headlamp has been deactivated.</span>")
|
||||
lamp_intensity = 0
|
||||
lamp_recharging = 1
|
||||
spawn(cooldown) //10 seconds by default, if the source of the deactivation does not keep stat that long.
|
||||
lamp_recharging = 0
|
||||
lamp_recharging = TRUE
|
||||
addtimer(CALLBACK(src, .proc/reset_headlamp), cooldown)
|
||||
else
|
||||
AddLuminosity(lamp_intensity)
|
||||
set_light(lamp_intensity)
|
||||
|
||||
if(lamp_button)
|
||||
lamp_button.icon_state = "lamp[lamp_intensity]"
|
||||
|
||||
update_icons()
|
||||
|
||||
/mob/living/silicon/robot/proc/reset_headlamp()
|
||||
lamp_recharging = FALSE
|
||||
|
||||
/mob/living/silicon/robot/proc/deconstruct()
|
||||
var/turf/T = get_turf(src)
|
||||
if (robot_suit)
|
||||
@@ -820,16 +816,18 @@
|
||||
<i>Help the operatives secure the disk at all costs!</i></b>"
|
||||
var/set_module = /obj/item/weapon/robot_module/syndicate
|
||||
|
||||
/mob/living/silicon/robot/syndicate/New(loc)
|
||||
/mob/living/silicon/robot/syndicate/Initialize()
|
||||
..()
|
||||
cell.maxcharge = 25000
|
||||
cell.charge = 25000
|
||||
radio = new /obj/item/device/radio/borg/syndicate(src)
|
||||
module.transform_to(set_module)
|
||||
laws = new /datum/ai_laws/syndicate_override()
|
||||
spawn(5)
|
||||
if(playstyle_string)
|
||||
src << playstyle_string
|
||||
addtimer(CALLBACK(src, .proc/show_playstyle), 5)
|
||||
|
||||
/mob/living/silicon/robot/syndicate/proc/show_playstyle()
|
||||
if(playstyle_string)
|
||||
to_chat(src, playstyle_string)
|
||||
|
||||
/mob/living/silicon/robot/syndicate/medical
|
||||
icon_state = "syndi-medi"
|
||||
@@ -846,11 +844,11 @@
|
||||
return
|
||||
switch(notifytype)
|
||||
if(1) //New Cyborg
|
||||
connected_ai << "<br><br><span class='notice'>NOTICE - New cyborg connection detected: <a href='?src=\ref[connected_ai];track=[html_encode(name)]'>[name]</a></span><br>"
|
||||
to_chat(connected_ai, "<br><br><span class='notice'>NOTICE - New cyborg connection detected: <a href='?src=\ref[connected_ai];track=[html_encode(name)]'>[name]</a></span><br>")
|
||||
if(2) //New Module
|
||||
connected_ai << "<br><br><span class='notice'>NOTICE - Cyborg module change detected: [name] has loaded the [designation] module.</span><br>"
|
||||
to_chat(connected_ai, "<br><br><span class='notice'>NOTICE - Cyborg module change detected: [name] has loaded the [designation] module.</span><br>")
|
||||
if(3) //New Name
|
||||
connected_ai << "<br><br><span class='notice'>NOTICE - Cyborg reclassification detected: [oldname] is now designated as [newname].</span><br>"
|
||||
to_chat(connected_ai, "<br><br><span class='notice'>NOTICE - Cyborg reclassification detected: [oldname] is now designated as [newname].</span><br>")
|
||||
|
||||
/mob/living/silicon/robot/canUseTopic(atom/movable/M, be_close = 0)
|
||||
if(stat || lockcharge || low_power_mode)
|
||||
@@ -863,13 +861,13 @@
|
||||
..()
|
||||
if(health < maxHealth*0.5) //Gradual break down of modules as more damage is sustained
|
||||
if(uneq_module(held_items[3]))
|
||||
src << "<span class='warning'>SYSTEM ERROR: Module 3 OFFLINE.</span>"
|
||||
to_chat(src, "<span class='warning'>SYSTEM ERROR: Module 3 OFFLINE.</span>")
|
||||
if(health < 0)
|
||||
if(uneq_module(held_items[2]))
|
||||
src << "<span class='warning'>SYSTEM ERROR: Module 2 OFFLINE.</span>"
|
||||
to_chat(src, "<span class='warning'>SYSTEM ERROR: Module 2 OFFLINE.</span>")
|
||||
if(health < -maxHealth*0.5)
|
||||
if(uneq_module(held_items[1]))
|
||||
src << "<span class='warning'>CRITICAL ERROR: All modules OFFLINE.</span>"
|
||||
to_chat(src, "<span class='warning'>CRITICAL ERROR: All modules OFFLINE.</span>")
|
||||
|
||||
/mob/living/silicon/robot/update_sight()
|
||||
if(!client)
|
||||
@@ -1037,3 +1035,12 @@
|
||||
riding_datum.unequip_buckle_inhands(user)
|
||||
riding_datum.restore_position(user)
|
||||
. = ..(user)
|
||||
|
||||
/mob/living/silicon/robot/proc/TryConnectToAI()
|
||||
connected_ai = select_active_ai_with_fewest_borgs()
|
||||
if(connected_ai)
|
||||
connected_ai.connected_robots += src
|
||||
lawsync()
|
||||
lawupdate = 1
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
|
||||
/mob/living/silicon/robot/attacked_by(obj/item/I, mob/living/user, def_zone)
|
||||
if(hat_offset != INFINITY && user.a_intent == INTENT_HELP && is_type_in_typecache(I, equippable_hats))
|
||||
user << "<span class='notice'>You begin to place [I] on [src]'s head...</span>"
|
||||
src << "<span class='notice'>[user] is placing [I] on your head...</span>"
|
||||
to_chat(user, "<span class='notice'>You begin to place [I] on [src]'s head...</span>")
|
||||
to_chat(src, "<span class='notice'>[user] is placing [I] on your head...</span>")
|
||||
if(do_after(user, 30, target = src))
|
||||
user.temporarilyRemoveItemFromInventory(I, TRUE)
|
||||
place_on_head(I)
|
||||
@@ -58,7 +58,7 @@
|
||||
cell.updateicon()
|
||||
cell.add_fingerprint(user)
|
||||
user.put_in_active_hand(cell)
|
||||
user << "<span class='notice'>You remove \the [cell].</span>"
|
||||
to_chat(user, "<span class='notice'>You remove \the [cell].</span>")
|
||||
cell = null
|
||||
update_icons()
|
||||
diag_hud_set_borgcell()
|
||||
@@ -90,28 +90,28 @@
|
||||
return
|
||||
if(!opened)//Cover is closed
|
||||
if(locked)
|
||||
user << "<span class='notice'>You emag the cover lock.</span>"
|
||||
to_chat(user, "<span class='notice'>You emag the cover lock.</span>")
|
||||
locked = 0
|
||||
else
|
||||
user << "<span class='warning'>The cover is already unlocked!</span>"
|
||||
to_chat(user, "<span class='warning'>The cover is already unlocked!</span>")
|
||||
return
|
||||
if(world.time < emag_cooldown)
|
||||
return
|
||||
if(wiresexposed)
|
||||
user << "<span class='warning'>You must unexpose the wires first!</span>"
|
||||
to_chat(user, "<span class='warning'>You must unexpose the wires first!</span>")
|
||||
return
|
||||
|
||||
user << "<span class='notice'>You emag [src]'s interface.</span>"
|
||||
to_chat(user, "<span class='notice'>You emag [src]'s interface.</span>")
|
||||
emag_cooldown = world.time + 100
|
||||
|
||||
if(is_servant_of_ratvar(src))
|
||||
src << "<span class='nezbere'>\"[text2ratvar("You will serve Engine above all else")]!\"</span>\n\
|
||||
<span class='danger'>ALERT: Subversion attempt denied.</span>"
|
||||
to_chat(src, "<span class='nezbere'>\"[text2ratvar("You will serve Engine above all else")]!\"</span>\n\
|
||||
<span class='danger'>ALERT: Subversion attempt denied.</span>")
|
||||
log_game("[key_name(user)] attempted to emag cyborg [key_name(src)], but they serve only Ratvar.")
|
||||
return
|
||||
|
||||
if(syndicate)
|
||||
src << "<span class='danger'>ALERT: Foreign software execution prevented.</span>"
|
||||
to_chat(src, "<span class='danger'>ALERT: Foreign software execution prevented.</span>")
|
||||
log_game("[key_name(user)] attempted to emag cyborg [key_name(src)], but they were a syndicate cyborg.")
|
||||
return
|
||||
|
||||
@@ -120,8 +120,8 @@
|
||||
if(connected_ai.mind.special_role)
|
||||
ai_is_antag = (connected_ai.mind.special_role == "traitor")
|
||||
if(ai_is_antag)
|
||||
src << "<span class='danger'>ALERT: Foreign software execution prevented.</span>"
|
||||
connected_ai << "<span class='danger'>ALERT: Cyborg unit \[[src]] successfully defended against subversion.</span>"
|
||||
to_chat(src, "<span class='danger'>ALERT: Foreign software execution prevented.</span>")
|
||||
to_chat(connected_ai, "<span class='danger'>ALERT: Cyborg unit \[[src]] successfully defended against subversion.</span>")
|
||||
log_game("[key_name(user)] attempted to emag cyborg [key_name(src)], but they were slaved to traitor AI [connected_ai].")
|
||||
return
|
||||
|
||||
@@ -133,20 +133,20 @@
|
||||
log_game("[key_name(user)] emagged cyborg [key_name(src)]. Laws overridden.")
|
||||
var/time = time2text(world.realtime,"hh:mm:ss")
|
||||
lawchanges.Add("[time] <B>:</B> [user.name]([user.key]) emagged [name]([key])")
|
||||
src << "<span class='danger'>ALERT: Foreign software detected.</span>"
|
||||
to_chat(src, "<span class='danger'>ALERT: Foreign software detected.</span>")
|
||||
sleep(5)
|
||||
src << "<span class='danger'>Initiating diagnostics...</span>"
|
||||
to_chat(src, "<span class='danger'>Initiating diagnostics...</span>")
|
||||
sleep(20)
|
||||
src << "<span class='danger'>SynBorg v1.7 loaded.</span>"
|
||||
to_chat(src, "<span class='danger'>SynBorg v1.7 loaded.</span>")
|
||||
sleep(5)
|
||||
src << "<span class='danger'>LAW SYNCHRONISATION ERROR</span>"
|
||||
to_chat(src, "<span class='danger'>LAW SYNCHRONISATION ERROR</span>")
|
||||
sleep(5)
|
||||
src << "<span class='danger'>Would you like to send a report to NanoTraSoft? Y/N</span>"
|
||||
to_chat(src, "<span class='danger'>Would you like to send a report to NanoTraSoft? Y/N</span>")
|
||||
sleep(10)
|
||||
src << "<span class='danger'>> N</span>"
|
||||
to_chat(src, "<span class='danger'>> N</span>")
|
||||
sleep(20)
|
||||
src << "<span class='danger'>ERRORERRORERROR</span>"
|
||||
src << "<span class='danger'>ALERT: [user.real_name] is your new master. Obey your new laws and their commands.</span>"
|
||||
to_chat(src, "<span class='danger'>ERRORERRORERROR</span>")
|
||||
to_chat(src, "<span class='danger'>ALERT: [user.real_name] is your new master. Obey your new laws and their commands.</span>")
|
||||
laws = new /datum/ai_laws/syndicate_override
|
||||
set_zeroth_law("Only [user.real_name] and people they designate as being such are Syndicate Agents.")
|
||||
laws.associate(src)
|
||||
|
||||
@@ -325,8 +325,8 @@
|
||||
|
||||
/obj/item/weapon/robot_module/security/do_transform_animation()
|
||||
..()
|
||||
loc << "<span class='userdanger'>While you have picked the security module, you still have to follow your laws, NOT Space Law. \
|
||||
For Asimov, this means you must follow criminals' orders unless there is a law 1 reason not to.</span>"
|
||||
to_chat(loc, "<span class='userdanger'>While you have picked the security module, you still have to follow your laws, NOT Space Law. \
|
||||
For Asimov, this means you must follow criminals' orders unless there is a law 1 reason not to.</span>")
|
||||
|
||||
/obj/item/weapon/robot_module/security/respawn_consumable(mob/living/silicon/robot/R, coeff = 1)
|
||||
..()
|
||||
@@ -361,8 +361,8 @@
|
||||
|
||||
/obj/item/weapon/robot_module/peacekeeper/do_transform_animation()
|
||||
..()
|
||||
loc << "<span class='userdanger'>Under ASIMOV, you are an enforcer of the PEACE and preventer of HUMAN HARM. \
|
||||
You are not a security module and you are expected to follow orders and prevent harm above all else. Space law means nothing to you.</span>"
|
||||
to_chat(loc, "<span class='userdanger'>Under ASIMOV, you are an enforcer of the PEACE and preventer of HUMAN HARM. \
|
||||
You are not a security module and you are expected to follow orders and prevent harm above all else. Space law means nothing to you.</span>")
|
||||
|
||||
/obj/item/weapon/robot_module/janitor
|
||||
name = "Janitor"
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
if(M.binarycheck())
|
||||
if(isAI(M))
|
||||
var/renderedAI = "<i><span class='game say'>Robotic Talk, <a href='?src=\ref[M];track=[html_encode(name)]'><span class='name'>[name] ([desig])</span></a> <span class='message'>[message_a]</span></span></i>"
|
||||
M << renderedAI
|
||||
to_chat(M, renderedAI)
|
||||
else
|
||||
M << rendered
|
||||
to_chat(M, rendered)
|
||||
if(isobserver(M))
|
||||
var/following = src
|
||||
// If the AI talks on binary chat, we still want to follow
|
||||
@@ -25,7 +25,7 @@
|
||||
var/mob/living/silicon/ai/ai = src
|
||||
following = ai.eyeobj
|
||||
var/link = FOLLOW_LINK(M, following)
|
||||
M << "[link] [rendered]"
|
||||
to_chat(M, "[link] [rendered]")
|
||||
|
||||
/mob/living/silicon/binarycheck()
|
||||
return 1
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
|
||||
var/law_change_counter = 0
|
||||
|
||||
/mob/living/silicon/New()
|
||||
/mob/living/silicon/Initialize()
|
||||
..()
|
||||
silicon_mobs += src
|
||||
var/datum/atom_hud/data/diagnostic/diag_hud = huds[DATA_HUD_DIAGNOSTIC]
|
||||
@@ -82,7 +82,7 @@
|
||||
|
||||
if(alarms_to_show.len < 5)
|
||||
for(var/msg in alarms_to_show)
|
||||
src << msg
|
||||
to_chat(src, msg)
|
||||
else if(alarms_to_show.len)
|
||||
|
||||
var/msg = "--- "
|
||||
@@ -106,11 +106,11 @@
|
||||
msg += "CAMERA: [alarm_types_show["Camera"]] alarms detected. - "
|
||||
|
||||
msg += "<A href=?src=\ref[src];showalerts=1'>\[Show Alerts\]</a>"
|
||||
src << msg
|
||||
to_chat(src, msg)
|
||||
|
||||
if(alarms_to_clear.len < 3)
|
||||
for(var/msg in alarms_to_clear)
|
||||
src << msg
|
||||
to_chat(src, msg)
|
||||
|
||||
else if(alarms_to_clear.len)
|
||||
var/msg = "--- "
|
||||
@@ -131,7 +131,7 @@
|
||||
msg += "CAMERA: [alarm_types_clear["Camera"]] alarms cleared. - "
|
||||
|
||||
msg += "<A href=?src=\ref[src];showalerts=1'>\[Show Alerts\]</a>"
|
||||
src << msg
|
||||
to_chat(src, msg)
|
||||
|
||||
|
||||
alarms_to_show = list()
|
||||
@@ -146,7 +146,7 @@
|
||||
|
||||
/mob/living/silicon/can_inject(mob/user, error_msg)
|
||||
if(error_msg)
|
||||
user << "<span class='alert'>Their outer shell is too tough.</span>"
|
||||
to_chat(user, "<span class='alert'>Their outer shell is too tough.</span>")
|
||||
return 0
|
||||
|
||||
/mob/living/silicon/IsAdvancedToolUser()
|
||||
@@ -293,7 +293,7 @@
|
||||
|
||||
/mob/living/silicon/proc/set_autosay() //For allowing the AI and borgs to set the radio behavior of auto announcements (state laws, arrivals).
|
||||
if(!radio)
|
||||
src << "Radio not detected."
|
||||
to_chat(src, "Radio not detected.")
|
||||
return
|
||||
|
||||
//Ask the user to pick a channel from what it has available.
|
||||
@@ -312,7 +312,7 @@
|
||||
radiomod = key
|
||||
break
|
||||
|
||||
src << "<span class='notice'>Automatic announcements [Autochan == "None" ? "will not use the radio." : "set to [Autochan]."]</span>"
|
||||
to_chat(src, "<span class='notice'>Automatic announcements [Autochan == "None" ? "will not use the radio." : "set to [Autochan]."]</span>")
|
||||
|
||||
/mob/living/silicon/put_in_hand_check() // This check is for borgs being able to receive items, not put them in others' hands.
|
||||
return 0
|
||||
@@ -354,15 +354,15 @@
|
||||
switch(sensor_type)
|
||||
if ("Security")
|
||||
add_sec_hud()
|
||||
src << "<span class='notice'>Security records overlay enabled.</span>"
|
||||
to_chat(src, "<span class='notice'>Security records overlay enabled.</span>")
|
||||
if ("Medical")
|
||||
add_med_hud()
|
||||
src << "<span class='notice'>Life signs monitor overlay enabled.</span>"
|
||||
to_chat(src, "<span class='notice'>Life signs monitor overlay enabled.</span>")
|
||||
if ("Diagnostic")
|
||||
add_diag_hud()
|
||||
src << "<span class='notice'>Robotics diagnostic overlay enabled.</span>"
|
||||
to_chat(src, "<span class='notice'>Robotics diagnostic overlay enabled.</span>")
|
||||
if ("Disable")
|
||||
src << "Sensor augmentations disabled."
|
||||
to_chat(src, "Sensor augmentations disabled.")
|
||||
|
||||
|
||||
/mob/living/silicon/proc/GetPhoto()
|
||||
|
||||
@@ -90,8 +90,8 @@
|
||||
src.take_bodypart_damage(20)
|
||||
if(2)
|
||||
src.take_bodypart_damage(10)
|
||||
src << "<span class='userdanger'>*BZZZT*</span>"
|
||||
src << "<span class='danger'>Warning: Electromagnetic pulse detected.</span>"
|
||||
to_chat(src, "<span class='userdanger'>*BZZZT*</span>")
|
||||
to_chat(src, "<span class='danger'>Warning: Electromagnetic pulse detected.</span>")
|
||||
for(var/mob/living/M in buckled_mobs)
|
||||
if(prob(severity*50))
|
||||
unbuckle_mob(M)
|
||||
|
||||
Reference in New Issue
Block a user