Game folder
This commit is contained in:
@@ -257,6 +257,7 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
dat += "<h4>Quartermaster Functions:</h4>"
|
||||
dat += "<ul>"
|
||||
dat += "<li><a href='byond://?src=[REF(src)];choice=47'>[PDAIMG(crate)]Supply Records</A></li>"
|
||||
dat += "<li><a href='byond://?src=[REF(src)];choice=48'>[PDAIMG(crate)]Ore Silo Logs</a></li>"
|
||||
dat += "</ul>"
|
||||
dat += "</ul>"
|
||||
|
||||
@@ -451,13 +452,7 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
//MAIN FUNCTIONS===================================
|
||||
|
||||
if("Light")
|
||||
if(fon)
|
||||
fon = FALSE
|
||||
set_light(0)
|
||||
else if(f_lum)
|
||||
fon = TRUE
|
||||
set_light(f_lum)
|
||||
update_icon()
|
||||
toggle_light()
|
||||
if("Medical Scan")
|
||||
if(scanmode == PDA_SCANNER_MEDICAL)
|
||||
scanmode = PDA_SCANNER_NONE
|
||||
@@ -654,7 +649,7 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
if(isobserver(M) && M.client && (M.client.prefs.chat_toggles & CHAT_GHOSTPDA))
|
||||
to_chat(M, "[FOLLOW_LINK(M, user)] [ghost_message]")
|
||||
// Log in the talk log
|
||||
log_talk(user, "[key_name(user)] (PDA: [initial(name)]) sent \"[message]\" to [target_text]", LOGPDA)
|
||||
user.log_talk(message, LOG_PDA, tag="PDA: [initial(name)] to [target_text]")
|
||||
to_chat(user, "<span class='info'>Message sent to [target_text]: \"[message]\"</span>")
|
||||
// Reset the photo
|
||||
picture = null
|
||||
@@ -713,6 +708,12 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
|
||||
remove_pen()
|
||||
|
||||
/obj/item/pda/verb/verb_toggle_light()
|
||||
set category = "Object"
|
||||
set name = "Toggle Flashlight"
|
||||
|
||||
toggle_light()
|
||||
|
||||
/obj/item/pda/verb/verb_remove_id()
|
||||
set category = "Object"
|
||||
set name = "Eject ID"
|
||||
@@ -730,6 +731,15 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
|
||||
remove_pen()
|
||||
|
||||
/obj/item/pda/proc/toggle_light()
|
||||
if(fon)
|
||||
fon = FALSE
|
||||
set_light(0)
|
||||
else if(f_lum)
|
||||
fon = TRUE
|
||||
set_light(f_lum)
|
||||
update_icon()
|
||||
|
||||
/obj/item/pda/proc/remove_pen()
|
||||
|
||||
if(issilicon(usr) || !usr.canUseTopic(src, BE_CLOSE))
|
||||
@@ -746,7 +756,7 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
//trying to insert or remove an id
|
||||
/obj/item/pda/proc/id_check(mob/user, obj/item/card/id/I)
|
||||
if(!I)
|
||||
if(id)
|
||||
if(id && (src in user.contents))
|
||||
remove_id()
|
||||
return TRUE
|
||||
else
|
||||
@@ -835,6 +845,7 @@ GLOBAL_LIST_EMPTY(PDAs)
|
||||
user.show_message("<span class='notice'>No radiation detected.</span>")
|
||||
|
||||
/obj/item/pda/afterattack(atom/A as mob|obj|turf|area, mob/user, proximity)
|
||||
. = ..()
|
||||
if(!proximity)
|
||||
return
|
||||
switch(scanmode)
|
||||
|
||||
@@ -454,6 +454,24 @@ Code:
|
||||
menu += "<li>#[SO.id] - [SO.pack.name] requested by [SO.orderer]</li>"
|
||||
menu += "</ol><font size=\"-3\">Upgrade NOW to Space Parts & Space Vendors PLUS for full remote order control and inventory management."
|
||||
|
||||
if (48) // quartermaster ore logs
|
||||
menu = list("<h4>[PDAIMG(crate)] Ore Silo Logs</h4>")
|
||||
if (GLOB.ore_silo_default)
|
||||
var/list/logs = GLOB.silo_access_logs[REF(GLOB.ore_silo_default)]
|
||||
var/len = LAZYLEN(logs)
|
||||
var/i = 0
|
||||
for(var/M in logs)
|
||||
if (++i > 30)
|
||||
menu += "(... older logs not shown ...)"
|
||||
break
|
||||
var/datum/ore_silo_log/entry = M
|
||||
menu += "[len - i]. [entry.formatted]<br><br>"
|
||||
if(i == 0)
|
||||
menu += "Nothing!"
|
||||
else
|
||||
menu += "<b>No ore silo detected!</b>"
|
||||
menu = jointext(menu, "")
|
||||
|
||||
if (49) //janitorial locator
|
||||
menu = "<h4>[PDAIMG(bucket)] Persistent Custodial Object Locator</h4>"
|
||||
|
||||
|
||||
@@ -76,10 +76,8 @@
|
||||
U.show_message("<span class='danger'>An error flashes on your [src].</span>", 1)
|
||||
else
|
||||
message_admins("[!is_special_character(U) ? "Non-antag " : ""][ADMIN_LOOKUPFLW(U)] triggered a PDA explosion on [target.name] at [ADMIN_VERBOSEJMP(target)].")
|
||||
var/message_log = "triggered a PDA explosion on [target.name] at at [AREACOORD(target)]."
|
||||
U.log_message(message_log, INDIVIDUAL_ATTACK_LOG)
|
||||
log_game("[key_name(U)] [message_log]")
|
||||
log_attack("[key_name(U)] [message_log]")
|
||||
var/message_log = "triggered a PDA explosion on [target.name] at [AREACOORD(target)]."
|
||||
U.log_message(message_log, LOG_ATTACK)
|
||||
U.show_message("<span class='notice'>Success!</span>", 1)
|
||||
target.explode()
|
||||
else
|
||||
|
||||
@@ -12,17 +12,22 @@
|
||||
var/flush = FALSE
|
||||
var/mob/living/silicon/ai/AI
|
||||
|
||||
/obj/item/aicard/aitater
|
||||
name = "intelliTater"
|
||||
desc = "A stylish upgrade (?) to the intelliCard."
|
||||
icon_state = "aitater"
|
||||
|
||||
/obj/item/aicard/suicide_act(mob/living/user)
|
||||
user.visible_message("<span class='suicide'>[user] is trying to upload [user.p_them()]self into [src]! That's not going to work out well!</span>")
|
||||
return BRUTELOSS
|
||||
|
||||
/obj/item/aicard/afterattack(atom/target, mob/user, proximity)
|
||||
..()
|
||||
. = ..()
|
||||
if(!proximity || !target)
|
||||
return
|
||||
if(AI) //AI is on the card, implies user wants to upload it.
|
||||
target.transfer_ai(AI_TRANS_FROM_CARD, user, AI, src)
|
||||
add_logs(user, AI, "carded", src)
|
||||
log_combat(user, AI, "carded", src)
|
||||
else //No AI on the card, therefore the user wants to download one.
|
||||
target.transfer_ai(AI_TRANS_TO_CARD, user, null, src)
|
||||
update_icon() //Whatever happened, update the card's state (icon, name) to match.
|
||||
@@ -32,11 +37,11 @@
|
||||
if(AI)
|
||||
name = "[initial(name)]- [AI.name]"
|
||||
if(AI.stat == DEAD)
|
||||
icon_state = "aicard-404"
|
||||
icon_state = "[initial(icon_state)]-404"
|
||||
else
|
||||
icon_state = "aicard-full"
|
||||
icon_state = "[initial(icon_state)]-full"
|
||||
if(!AI.control_disabled)
|
||||
add_overlay("aicard-on")
|
||||
add_overlay("[initial(icon_state)]-on")
|
||||
AI.cancel_camera()
|
||||
else
|
||||
name = initial(name)
|
||||
|
||||
@@ -63,8 +63,9 @@
|
||||
if ( loc != user || user.incapacitated() || user.eye_blind || !current )
|
||||
user.unset_machine()
|
||||
return 0
|
||||
var/turf/T = get_turf(user.loc)
|
||||
if(T.z != current.z || !current.can_use())
|
||||
var/turf/T_user = get_turf(user.loc)
|
||||
var/turf/T_current = get_turf(current)
|
||||
if(T_user.z != T_current.z || !current.can_use())
|
||||
to_chat(user, "<span class='danger'>[src] has lost the signal.</span>")
|
||||
current = null
|
||||
user.unset_machine()
|
||||
@@ -79,10 +80,9 @@
|
||||
for(var/obj/machinery/camera/camera in GLOB.cameranet.cameras)
|
||||
if(camera.stat || !camera.can_use())
|
||||
continue
|
||||
if(length(list("ss13","mine")&camera.network))
|
||||
if(length(list("ss13","mine", "rd", "labor", "toxins", "minisat")&camera.network))
|
||||
bugged_cameras[camera.c_tag] = camera
|
||||
sortList(bugged_cameras)
|
||||
return bugged_cameras
|
||||
return sortList(bugged_cameras)
|
||||
|
||||
|
||||
/obj/item/camera_bug/proc/menu(list/cameras)
|
||||
@@ -296,8 +296,9 @@
|
||||
src.updateSelfDialog()
|
||||
|
||||
/obj/item/camera_bug/proc/same_z_level(var/obj/machinery/camera/C)
|
||||
var/turf/T = get_turf(loc)
|
||||
if(!T || C.z != T.z)
|
||||
var/turf/T_cam = get_turf(C)
|
||||
var/turf/T_bug = get_turf(loc)
|
||||
if(!T_bug || T_cam.z != T_bug.z)
|
||||
to_chat(usr, "<span class='warning'>You can't get a signal!</span>")
|
||||
return FALSE
|
||||
return TRUE
|
||||
|
||||
@@ -36,6 +36,7 @@
|
||||
to_chat(user, "<span class='warning'>You can't use [src] while inside something!</span>")
|
||||
|
||||
/obj/item/chameleon/afterattack(atom/target, mob/user , proximity)
|
||||
. = ..()
|
||||
if(!proximity)
|
||||
return
|
||||
if(!check_sprite(target))
|
||||
@@ -76,7 +77,7 @@
|
||||
new /obj/effect/temp_visual/emp/pulse(get_turf(src))
|
||||
else
|
||||
playsound(get_turf(src), 'sound/effects/pop.ogg', 100, 1, -6)
|
||||
var/obj/effect/dummy/chameleon/C = new/obj/effect/dummy/chameleon(get_turf(user))
|
||||
var/obj/effect/dummy/chameleon/C = new/obj/effect/dummy/chameleon(user.drop_location())
|
||||
C.activate(user, saved_appearance, src)
|
||||
to_chat(user, "<span class='notice'>You activate \the [src].</span>")
|
||||
new /obj/effect/temp_visual/emp/pulse(get_turf(src))
|
||||
|
||||
@@ -47,6 +47,7 @@
|
||||
return TRUE //The actual circuit magic itself is done on a per-object basis
|
||||
|
||||
/obj/item/electroadaptive_pseudocircuit/afterattack(atom/target, mob/living/user, proximity)
|
||||
. = ..()
|
||||
if(!proximity)
|
||||
return
|
||||
if(!is_type_in_typecache(target, recycleable_circuits))
|
||||
|
||||
@@ -168,6 +168,7 @@
|
||||
var/holo_cooldown = 0
|
||||
|
||||
/obj/item/flashlight/pen/afterattack(atom/target, mob/user, proximity_flag)
|
||||
. = ..()
|
||||
if(!proximity_flag)
|
||||
if(holo_cooldown > world.time)
|
||||
to_chat(user, "<span class='warning'>[src] is not ready yet!</span>")
|
||||
@@ -177,7 +178,6 @@
|
||||
new /obj/effect/temp_visual/medical_holosign(T,user) //produce a holographic glow
|
||||
holo_cooldown = world.time + 100
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/effect/temp_visual/medical_holosign
|
||||
name = "medical holosign"
|
||||
@@ -380,6 +380,7 @@
|
||||
return
|
||||
|
||||
/obj/item/flashlight/emp/afterattack(atom/movable/A, mob/user, proximity)
|
||||
. = ..()
|
||||
if(!proximity)
|
||||
return
|
||||
|
||||
@@ -388,7 +389,7 @@
|
||||
|
||||
if(ismob(A))
|
||||
var/mob/M = A
|
||||
add_logs(user, M, "attacked", "EMP-light")
|
||||
log_combat(user, M, "attacked", "EMP-light")
|
||||
M.visible_message("<span class='danger'>[user] blinks \the [src] at \the [A].", \
|
||||
"<span class='userdanger'>[user] blinks \the [src] at you.")
|
||||
else
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/forcefield
|
||||
/obj/item/forcefield_projector
|
||||
name = "forcefield projector"
|
||||
desc = "An experimental device that can create several forcefields at a distance."
|
||||
icon = 'icons/obj/device.dmi'
|
||||
@@ -16,7 +16,8 @@
|
||||
var/list/current_fields
|
||||
var/field_distance_limit = 7
|
||||
|
||||
/obj/item/forcefield/afterattack(atom/target, mob/user, proximity_flag)
|
||||
/obj/item/forcefield_projector/afterattack(atom/target, mob/user, proximity_flag)
|
||||
. = ..()
|
||||
if(!check_allowed_items(target, 1))
|
||||
return
|
||||
if(istype(target, /obj/structure/projected_forcefield))
|
||||
@@ -40,27 +41,27 @@
|
||||
current_fields += F
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
|
||||
/obj/item/forcefield/attack_self(mob/user)
|
||||
/obj/item/forcefield_projector/attack_self(mob/user)
|
||||
if(LAZYLEN(current_fields))
|
||||
to_chat(user, "<span class='notice'>You deactivate [src], disabling all active forcefields.</span>")
|
||||
for(var/obj/structure/projected_forcefield/F in current_fields)
|
||||
qdel(F)
|
||||
|
||||
/obj/item/forcefield/examine(mob/user)
|
||||
/obj/item/forcefield_projector/examine(mob/user)
|
||||
..()
|
||||
var/percent_charge = round((shield_integrity/max_shield_integrity)*100)
|
||||
to_chat(user, "<span class='notice'>It is currently sustaining [LAZYLEN(current_fields)]/[max_fields] fields, and it's [percent_charge]% charged.</span>")
|
||||
|
||||
/obj/item/forcefield/Initialize(mapload)
|
||||
..()
|
||||
/obj/item/forcefield_projector/Initialize(mapload)
|
||||
. = ..()
|
||||
current_fields = list()
|
||||
START_PROCESSING(SSobj, src)
|
||||
|
||||
/obj/item/forcefield/Destroy()
|
||||
/obj/item/forcefield_projector/Destroy()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
return ..()
|
||||
|
||||
/obj/item/forcefield/process()
|
||||
/obj/item/forcefield_projector/process()
|
||||
if(!LAZYLEN(current_fields))
|
||||
shield_integrity = min(shield_integrity + 4, max_shield_integrity)
|
||||
else
|
||||
@@ -81,9 +82,9 @@
|
||||
resistance_flags = INDESTRUCTIBLE
|
||||
CanAtmosPass = ATMOS_PASS_DENSITY
|
||||
armor = list("melee" = 0, "bullet" = 25, "laser" = 50, "energy" = 50, "bomb" = 25, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 100)
|
||||
var/obj/item/forcefield/generator
|
||||
var/obj/item/forcefield_projector/generator
|
||||
|
||||
/obj/structure/projected_forcefield/Initialize(mapload, obj/item/forcefield/origin)
|
||||
/obj/structure/projected_forcefield/Initialize(mapload, obj/item/forcefield_projector/origin)
|
||||
. = ..()
|
||||
generator = origin
|
||||
|
||||
|
||||
@@ -132,6 +132,7 @@
|
||||
to_chat(user, "<span class='notice'>[icon2html(src, user)] You switch [scanning ? "on" : "off"] [src].</span>")
|
||||
|
||||
/obj/item/geiger_counter/afterattack(atom/target, mob/user)
|
||||
. = ..()
|
||||
if(user.a_intent == INTENT_HELP)
|
||||
if(!(obj_flags & EMAGGED))
|
||||
user.visible_message("<span class='notice'>[user] scans [target] with [src].</span>", "<span class='notice'>You scan [target]'s radiation levels with [src]...</span>")
|
||||
@@ -141,7 +142,6 @@
|
||||
target.rad_act(radiation_count)
|
||||
radiation_count = 0
|
||||
return TRUE
|
||||
return ..()
|
||||
|
||||
/obj/item/geiger_counter/proc/scan(atom/A, mob/user)
|
||||
var/rad_strength = 0
|
||||
@@ -208,7 +208,10 @@
|
||||
if (mobhook && mobhook.parent != user)
|
||||
QDEL_NULL(mobhook)
|
||||
if (!mobhook)
|
||||
mobhook = user.AddComponent(/datum/component/redirect, list(COMSIG_ATOM_RAD_ACT), CALLBACK(src, /atom.proc/rad_act))
|
||||
mobhook = user.AddComponent(/datum/component/redirect, list(COMSIG_ATOM_RAD_ACT = CALLBACK(src, .proc/redirect_rad_act)))
|
||||
|
||||
/obj/item/geiger_counter/cyborg/proc/redirect_rad_act(datum/source, amount)
|
||||
rad_act(amount)
|
||||
|
||||
/obj/item/geiger_counter/cyborg/dropped()
|
||||
. = ..()
|
||||
|
||||
@@ -10,12 +10,15 @@
|
||||
var/datum/song/handheld/song
|
||||
var/instrumentId = "generic"
|
||||
var/instrumentExt = "mid"
|
||||
var/tune_time = 0
|
||||
|
||||
/obj/item/instrument/Initialize()
|
||||
. = ..()
|
||||
song = new(instrumentId, src, instrumentExt)
|
||||
|
||||
/obj/item/instrument/Destroy()
|
||||
if (tune_time)
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
qdel(song)
|
||||
song = null
|
||||
return ..()
|
||||
@@ -48,6 +51,34 @@
|
||||
user.set_machine(src)
|
||||
song.interact(user)
|
||||
|
||||
/obj/item/instrument/attackby(obj/item/W, mob/user, params)
|
||||
if(istype(W, /obj/item/musicaltuner))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if (H.has_trait(TRAIT_MUSICIAN))
|
||||
if (!tune_time)
|
||||
H.visible_message("[H] tunes the [src] to perfection!", "<span class='notice'>You tune the [src] to perfection!</span>")
|
||||
tune_time = 300
|
||||
START_PROCESSING(SSobj, src)
|
||||
else
|
||||
to_chat(H, "<span class='notice'>[src] is already well tuned!</span>")
|
||||
else
|
||||
to_chat(H, "<span class='warning'>You have no idea how to use this.</span>")
|
||||
|
||||
/obj/item/instrument/process()
|
||||
if (tune_time)
|
||||
if (song.playing)
|
||||
for (var/mob/living/M in song.hearing_mobs)
|
||||
M.dizziness = max(0,M.dizziness-2)
|
||||
M.jitteriness = max(0,M.jitteriness-2)
|
||||
M.confused = max(M.confused-1)
|
||||
SEND_SIGNAL(M, COMSIG_ADD_MOOD_EVENT, "goodmusic", /datum/mood_event/goodmusic)
|
||||
tune_time--
|
||||
else
|
||||
if (!tune_time)
|
||||
if (song.playing)
|
||||
loc.visible_message("<span class='warning'>[src] starts sounding a little off...</span>")
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
|
||||
/obj/item/instrument/violin
|
||||
name = "space violin"
|
||||
desc = "A wooden musical instrument with four strings and a bow. \"The devil went down to space, he was looking for an assistant to grief.\""
|
||||
@@ -224,3 +255,16 @@
|
||||
throw_speed = 3
|
||||
throw_range = 15
|
||||
hitsound = 'sound/items/bikehorn.ogg'
|
||||
|
||||
///
|
||||
|
||||
/obj/item/musicaltuner
|
||||
name = "musical tuner"
|
||||
desc = "A device for tuning musical instruments both manual and electronic alike."
|
||||
icon = 'icons/obj/device.dmi'
|
||||
icon_state = "musicaltuner"
|
||||
slot_flags = ITEM_SLOT_BELT
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
item_state = "electronic"
|
||||
lefthand_file = 'icons/mob/inhands/misc/devices_lefthand.dmi'
|
||||
righthand_file = 'icons/mob/inhands/misc/devices_righthand.dmi'
|
||||
|
||||
@@ -57,6 +57,7 @@
|
||||
return ..()
|
||||
|
||||
/obj/item/laser_pointer/afterattack(atom/target, mob/living/user, flag, params)
|
||||
. = ..()
|
||||
laser_act(target, user, params)
|
||||
|
||||
/obj/item/laser_pointer/proc/laser_act(atom/target, mob/living/user, params)
|
||||
@@ -91,7 +92,7 @@
|
||||
if(iscarbon(target))
|
||||
var/mob/living/carbon/C = target
|
||||
if(user.zone_selected == BODY_ZONE_PRECISE_EYES)
|
||||
add_logs(user, C, "shone in the eyes", src)
|
||||
log_combat(user, C, "shone in the eyes", src)
|
||||
|
||||
var/severity = 1
|
||||
if(prob(33))
|
||||
@@ -108,7 +109,7 @@
|
||||
//robots
|
||||
else if(iscyborg(target))
|
||||
var/mob/living/silicon/S = target
|
||||
add_logs(user, S, "shone in the sensors", src)
|
||||
log_combat(user, S, "shone in the sensors", src)
|
||||
//chance to actually hit the eyes depends on internal component
|
||||
if(prob(effectchance * diode.rating))
|
||||
S.flash_act(affect_silicon = 1)
|
||||
@@ -124,7 +125,7 @@
|
||||
if(prob(effectchance * diode.rating))
|
||||
C.emp_act(EMP_HEAVY)
|
||||
outmsg = "<span class='notice'>You hit the lens of [C] with [src], temporarily disabling the camera!</span>"
|
||||
add_logs(user, C, "EMPed", src)
|
||||
log_combat(user, C, "EMPed", src)
|
||||
else
|
||||
outmsg = "<span class='warning'>You miss the lens of [C] with [src]!</span>"
|
||||
|
||||
@@ -137,7 +138,7 @@
|
||||
if(prob(effectchance))
|
||||
H.visible_message("<span class='warning'>[H] makes a grab for the light!</span>","<span class='userdanger'>LIGHT!</span>")
|
||||
H.Move(targloc)
|
||||
add_logs(user, H, "moved with a laser pointer",src)
|
||||
log_combat(user, H, "moved with a laser pointer",src)
|
||||
else
|
||||
H.visible_message("<span class='notice'>[H] looks briefly distracted by the light.</span>","<span class = 'warning'> You're briefly tempted by the shiny light... </span>")
|
||||
else
|
||||
|
||||
@@ -239,6 +239,7 @@
|
||||
return 0
|
||||
|
||||
/obj/item/lightreplacer/afterattack(atom/T, mob/U, proximity)
|
||||
. = ..()
|
||||
if(!proximity)
|
||||
return
|
||||
if(!isturf(T))
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
/obj/item/megaphone/suicide_act(mob/living/carbon/user)
|
||||
user.visible_message("<span class='suicide'>[user] is uttering [user.p_their()] last words into \the [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
||||
spamcheck = 0//so they dont have to worry about recharging
|
||||
user.say("AAAAAAAAAAAARGHHHHH")//he must have died while coding this
|
||||
user.say("AAAAAAAAAAAARGHHHHH", forced="megaphone suicide")//he must have died while coding this
|
||||
return OXYLOSS
|
||||
|
||||
/obj/item/megaphone/get_held_item_speechspans(mob/living/carbon/user)
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
desc = "Used for pulsing wires to test which to cut. Not recommended by doctors."
|
||||
icon = 'icons/obj/device.dmi'
|
||||
icon_state = "multitool"
|
||||
item_state = "multitool"
|
||||
lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi'
|
||||
righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi'
|
||||
force = 5
|
||||
@@ -25,13 +26,19 @@
|
||||
throw_speed = 3
|
||||
materials = list(MAT_METAL=50, MAT_GLASS=20)
|
||||
var/obj/machinery/buffer // simple machine buffer for device linkage
|
||||
hitsound = 'sound/weapons/tap.ogg'
|
||||
toolspeed = 1
|
||||
tool_behaviour = TOOL_MULTITOOL
|
||||
usesound = 'sound/weapons/empty.ogg'
|
||||
var/datum/integrated_io/selected_io = null //functional for integrated circuits.
|
||||
var/mode = 0
|
||||
|
||||
/obj/item/multitool/examine(mob/user)
|
||||
..()
|
||||
if(selected_io)
|
||||
to_chat(user, "<span class='notice'>Activate [src] to detach the data wire.</span>")
|
||||
if(buffer)
|
||||
to_chat(user, "<span class='notice'>Its buffer contains [buffer].</span>")
|
||||
|
||||
/obj/item/multitool/suicide_act(mob/living/carbon/user)
|
||||
user.visible_message("<span class='suicide'>[user] puts the [src] to [user.p_their()] chest. It looks like [user.p_theyre()] trying to pulse [user.p_their()] heart off!</span>")
|
||||
return OXYLOSS//theres a reason it wasnt recommended by doctors
|
||||
@@ -40,8 +47,6 @@
|
||||
if(selected_io)
|
||||
selected_io = null
|
||||
to_chat(user, "<span class='notice'>You clear the wired connection from the multitool.</span>")
|
||||
else
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
/obj/item/multitool/update_icon()
|
||||
@@ -98,30 +103,89 @@
|
||||
|
||||
// Syndicate device disguised as a multitool; it will turn red when an AI camera is nearby.
|
||||
|
||||
|
||||
/obj/item/multitool/ai_detect
|
||||
var/track_cooldown = 0
|
||||
var/track_delay = 10 //How often it checks for proximity
|
||||
var/detect_state = PROXIMITY_NONE
|
||||
var/rangealert = 8 //Glows red when inside
|
||||
var/rangewarning = 20 //Glows yellow when inside
|
||||
var/hud_type = DATA_HUD_AI_DETECT
|
||||
var/hud_on = FALSE
|
||||
var/mob/camera/aiEye/remote/ai_detector/eye
|
||||
var/datum/action/item_action/toggle_multitool/toggle_action
|
||||
|
||||
/obj/item/multitool/ai_detect/New()
|
||||
..()
|
||||
/obj/item/multitool/ai_detect/Initialize()
|
||||
. = ..()
|
||||
START_PROCESSING(SSobj, src)
|
||||
eye = new /mob/camera/aiEye/remote/ai_detector()
|
||||
toggle_action = new /datum/action/item_action/toggle_multitool(src)
|
||||
|
||||
/obj/item/multitool/ai_detect/Destroy()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
if(hud_on && ismob(loc))
|
||||
remove_hud(loc)
|
||||
QDEL_NULL(toggle_action)
|
||||
QDEL_NULL(eye)
|
||||
return ..()
|
||||
|
||||
/obj/item/multitool/ai_detect/ui_action_click()
|
||||
return
|
||||
|
||||
/obj/item/multitool/ai_detect/update_icon()
|
||||
if(selected_io)
|
||||
icon_state = "multitool_red"
|
||||
else
|
||||
icon_state = "[initial(icon_state)][detect_state]"
|
||||
|
||||
/obj/item/multitool/ai_detect/equipped(mob/living/carbon/human/user, slot)
|
||||
..()
|
||||
if(hud_on)
|
||||
show_hud(user)
|
||||
|
||||
/obj/item/multitool/ai_detect/dropped(mob/living/carbon/human/user)
|
||||
..()
|
||||
if(hud_on)
|
||||
remove_hud(user)
|
||||
|
||||
/obj/item/multitool/ai_detect/process()
|
||||
if(track_cooldown > world.time)
|
||||
return
|
||||
detect_state = PROXIMITY_NONE
|
||||
if(eye.eye_user)
|
||||
eye.setLoc(get_turf(src))
|
||||
multitool_detect()
|
||||
icon_state = "[initial(icon_state)][detect_state]"
|
||||
update_icon()
|
||||
track_cooldown = world.time + track_delay
|
||||
|
||||
/obj/item/multitool/ai_detect/proc/toggle_hud(mob/user)
|
||||
hud_on = !hud_on
|
||||
if(user)
|
||||
to_chat(user, "<span class='notice'>You toggle the ai detection HUD on [src] [hud_on ? "on" : "off"].</span>")
|
||||
if(hud_on)
|
||||
show_hud(user)
|
||||
else
|
||||
remove_hud(user)
|
||||
|
||||
/obj/item/multitool/ai_detect/proc/show_hud(mob/user)
|
||||
if(user && hud_type)
|
||||
var/obj/screen/plane_master/camera_static/PM = user.hud_used.plane_masters["[CAMERA_STATIC_PLANE]"]
|
||||
PM.alpha = 150
|
||||
var/datum/atom_hud/H = GLOB.huds[hud_type]
|
||||
if(!H.hudusers[user])
|
||||
H.add_hud_to(user)
|
||||
eye.eye_user = user
|
||||
eye.setLoc(get_turf(src))
|
||||
|
||||
/obj/item/multitool/ai_detect/proc/remove_hud(mob/user)
|
||||
if(user && hud_type)
|
||||
var/obj/screen/plane_master/camera_static/PM = user.hud_used.plane_masters["[CAMERA_STATIC_PLANE]"]
|
||||
PM.alpha = 255
|
||||
var/datum/atom_hud/H = GLOB.huds[hud_type]
|
||||
H.remove_hud_from(user)
|
||||
if(eye)
|
||||
eye.setLoc(null)
|
||||
eye.eye_user = null
|
||||
|
||||
/obj/item/multitool/ai_detect/proc/multitool_detect()
|
||||
var/turf/our_turf = get_turf(src)
|
||||
for(var/mob/living/silicon/ai/AI in GLOB.ai_list)
|
||||
@@ -134,6 +198,8 @@
|
||||
var/datum/camerachunk/chunk = GLOB.cameranet.chunkGenerated(our_turf.x, our_turf.y, our_turf.z)
|
||||
if(chunk && chunk.seenby.len)
|
||||
for(var/mob/camera/aiEye/A in chunk.seenby)
|
||||
if(!A.ai_detector_visible)
|
||||
continue
|
||||
var/turf/detect_turf = get_turf(A)
|
||||
if(get_dist(our_turf, detect_turf) < rangealert)
|
||||
detect_state = PROXIMITY_ON_SCREEN
|
||||
@@ -142,6 +208,24 @@
|
||||
detect_state = PROXIMITY_NEAR
|
||||
break
|
||||
|
||||
/mob/camera/aiEye/remote/ai_detector
|
||||
name = "AI detector eye"
|
||||
ai_detector_visible = FALSE
|
||||
use_static = USE_STATIC_TRANSPARENT
|
||||
visible_icon = FALSE
|
||||
|
||||
/datum/action/item_action/toggle_multitool
|
||||
name = "Toggle AI detector HUD"
|
||||
check_flags = NONE
|
||||
|
||||
/datum/action/item_action/toggle_multitool/Trigger()
|
||||
if(!..())
|
||||
return 0
|
||||
if(target)
|
||||
var/obj/item/multitool/ai_detect/M = target
|
||||
M.toggle_hud(owner)
|
||||
return 1
|
||||
|
||||
/obj/item/multitool/cyborg
|
||||
name = "multitool"
|
||||
desc = "Optimised and stripped-down version of a regular multitool."
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
materials = list(MAT_METAL=5000, MAT_GLASS=2000)
|
||||
|
||||
/obj/item/pipe_painter/afterattack(atom/A, mob/user, proximity_flag)
|
||||
. = ..()
|
||||
//Make sure we only paint adjacent items
|
||||
if(!proximity_flag)
|
||||
return
|
||||
|
||||
@@ -119,6 +119,7 @@
|
||||
return // Avoid hearing the same thing twice
|
||||
if(!anyai && !(speaker in ai))
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/item/radio/intercom/process()
|
||||
if(((world.timeofday - last_tick) > 30) || ((world.timeofday - last_tick) < 0))
|
||||
|
||||
@@ -132,9 +132,9 @@ SLIME SCANNER
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
if(H.undergoing_cardiac_arrest() && H.stat != DEAD)
|
||||
to_chat(user, "<span class='danger'>Subject suffering from heart attack: apply defibrillator immediately!</span>")
|
||||
to_chat(user, "<span class='danger'>Subject suffering from heart attack: Apply defibrillation or other electric shock immediately!</span>")
|
||||
if(H.undergoing_liver_failure() && H.stat != DEAD)
|
||||
to_chat(user, "<span class='danger'>Subject suffering from liver failure: apply corazone and begin a liver transplant immediately!</span>")
|
||||
to_chat(user, "<span class='danger'>Subject is suffering from liver failure: Apply Corazone and begin a liver transplant immediately!</span>")
|
||||
|
||||
to_chat(user, "<span class='info'>Analyzing results for [M]:\n\tOverall status: [mob_status]</span>")
|
||||
|
||||
@@ -152,11 +152,11 @@ SLIME SCANNER
|
||||
if(advanced)
|
||||
to_chat(user, "\t<span class='info'>Fatigue Level: [M.getStaminaLoss()]%.</span>")
|
||||
if (M.getCloneLoss())
|
||||
to_chat(user, "\t<span class='alert'>Subject appears to have [M.getCloneLoss() > 30 ? "severe" : "minor"] cellular damage.</span>")
|
||||
to_chat(user, "\t<span class='alert'>Subject appears to have [M.getCloneLoss() > 30 ? "Severe" : "Minor"] cellular damage.</span>")
|
||||
if(advanced)
|
||||
to_chat(user, "\t<span class='info'>Cellular Damage Level: [M.getCloneLoss()].</span>")
|
||||
if (M.getBrainLoss() >= 200 || !M.getorgan(/obj/item/organ/brain))
|
||||
to_chat(user, "\t<span class='alert'>Subject brain function is non-existent.</span>")
|
||||
to_chat(user, "\t<span class='alert'>Subject's brain function is non-existent.</span>")
|
||||
else if (M.getBrainLoss() >= 120)
|
||||
to_chat(user, "\t<span class='alert'>Severe brain damage detected. Subject likely to have mental traumas.</span>")
|
||||
else if (M.getBrainLoss() >= 45)
|
||||
@@ -176,7 +176,7 @@ SLIME SCANNER
|
||||
trauma_desc += "permanent "
|
||||
trauma_desc += B.scan_desc
|
||||
trauma_text += trauma_desc
|
||||
to_chat(user, "\t<span class='alert'>Cerebral traumas detected: subjects appears to be suffering from [english_list(trauma_text)].</span>")
|
||||
to_chat(user, "\t<span class='alert'>Cerebral traumas detected: subject appears to be suffering from [english_list(trauma_text)].</span>")
|
||||
if(C.roundstart_quirks.len)
|
||||
to_chat(user, "\t<span class='info'>Subject has the following physiological traits: [C.get_trait_string()].</span>")
|
||||
if(advanced)
|
||||
@@ -243,7 +243,7 @@ SLIME SCANNER
|
||||
var/mob/living/carbon/human/H = M
|
||||
var/ldamage = H.return_liver_damage()
|
||||
if(ldamage > 10)
|
||||
to_chat(user, "\t<span class='alert'>[ldamage > 45 ? "severe" : "minor"] liver damage detected.</span>")
|
||||
to_chat(user, "\t<span class='alert'>[ldamage > 45 ? "Severe" : "Minor"] liver damage detected.</span>")
|
||||
|
||||
// Body part damage report
|
||||
if(iscarbon(M) && mode == 1)
|
||||
@@ -388,6 +388,10 @@ SLIME SCANNER
|
||||
var/cooldown_time = 250
|
||||
var/accuracy // 0 is the best accuracy.
|
||||
|
||||
/obj/item/analyzer/examine(mob/user)
|
||||
. = ..()
|
||||
to_chat(user, "<span class='notice'>Alt-click [src] to activate the barometer function.</span>")
|
||||
|
||||
/obj/item/analyzer/suicide_act(mob/living/carbon/user)
|
||||
user.visible_message("<span class='suicide'>[user] begins to analyze [user.p_them()]self with [src]! The display shows that [user.p_theyre()] dead!</span>")
|
||||
return BRUTELOSS
|
||||
@@ -612,6 +616,7 @@ SLIME SCANNER
|
||||
to_chat(user, "<span_class = 'notice'>Progress in core mutation: [T.applied] / [SLIME_EXTRACT_CROSSING_REQUIRED]</span>")
|
||||
to_chat(user, "========================")
|
||||
|
||||
|
||||
/obj/item/nanite_scanner
|
||||
name = "nanite scanner"
|
||||
icon = 'icons/obj/device.dmi'
|
||||
|
||||
@@ -121,9 +121,7 @@
|
||||
mytape.storedinfo += "\[[time2text(mytape.used_capacity * 10,"mm:ss")]\] Recording started."
|
||||
var/used = mytape.used_capacity //to stop runtimes when you eject the tape
|
||||
var/max = mytape.max_capacity
|
||||
for(used, used < max)
|
||||
if(recording == 0)
|
||||
break
|
||||
while(recording && used < max)
|
||||
mytape.used_capacity++
|
||||
used++
|
||||
sleep(10)
|
||||
|
||||
@@ -39,7 +39,7 @@ effective or pretty fucking useless.
|
||||
to_chat(user, "<span class='danger'>The mind batterer has been burnt out!</span>")
|
||||
return
|
||||
|
||||
add_logs(user, null, "knocked down people in the area", src)
|
||||
log_combat(user, null, "knocked down people in the area", src)
|
||||
|
||||
for(var/mob/living/carbon/human/M in urange(10, user, 1))
|
||||
if(prob(50))
|
||||
@@ -82,7 +82,7 @@ effective or pretty fucking useless.
|
||||
if(!irradiate)
|
||||
return
|
||||
if(!used)
|
||||
add_logs(user, M, "irradiated", src)
|
||||
log_combat(user, M, "irradiated", src)
|
||||
var/cooldown = GetCooldown()
|
||||
used = 1
|
||||
icon_state = "health1"
|
||||
|
||||
Reference in New Issue
Block a user