mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-21 20:20:33 +01:00
Makes data huds passive.
This commit is contained in:
@@ -50,4 +50,11 @@
|
||||
#define STAGE_TWO 3
|
||||
#define STAGE_THREE 5
|
||||
#define STAGE_FOUR 7
|
||||
#define STAGE_FIVE 9
|
||||
#define STAGE_FIVE 9
|
||||
|
||||
//data HUD (medhud, sechud) defines
|
||||
#define DATA_HUD_MEDICAL 1
|
||||
#define DATA_HUD_SECURITY 2
|
||||
|
||||
#define DATA_HUD_BASIC 1
|
||||
#define DATA_HUD_ADVANCED 2
|
||||
|
||||
@@ -14,5 +14,3 @@ var/global/list/chemical_reactions_list //list of all /datum/chemical_reactio
|
||||
var/global/list/chemical_reagents_list //list of all /datum/reagent datums indexed by reagent id. Used by chemistry stuff
|
||||
var/global/list/surgeries_list = list() //list of all surgeries by name, associated with their path.
|
||||
var/global/list/table_recipes = list() //list of all table craft recipes
|
||||
var/global/list/med_hud_users = list() //list of all entities using a medical HUD.
|
||||
var/global/list/sec_hud_users = list() //list of all entities using a security HUD.
|
||||
@@ -37,8 +37,11 @@
|
||||
DD.affected_mob = src
|
||||
DD.holder = src
|
||||
if(DD.disease_flags & CAN_CARRY && prob(5))
|
||||
DD.carrier++
|
||||
DD.carrier = 1
|
||||
|
||||
/mob/living/carbon/human/AddDisease(var/datum/disease/D)
|
||||
..()
|
||||
med_hud_set_status()
|
||||
|
||||
/mob/living/carbon/ContractDisease(var/datum/disease/D)
|
||||
if(!CanContractDisease(D))
|
||||
@@ -122,4 +125,4 @@
|
||||
/mob/proc/ForceContractDisease(var/datum/disease/D)
|
||||
if(!CanContractDisease(D))
|
||||
return 0
|
||||
AddDisease(D)
|
||||
AddDisease(D)
|
||||
|
||||
@@ -153,7 +153,7 @@ var/list/diseases = typesof(/datum/disease) - /datum/disease
|
||||
if(disease_flags & CAN_RESIST)
|
||||
if(!(type in affected_mob.resistances))
|
||||
affected_mob.resistances += type
|
||||
affected_mob.viruses -= src
|
||||
remove_virus()
|
||||
del(src)
|
||||
|
||||
|
||||
@@ -193,3 +193,10 @@ var/list/diseases = typesof(/datum/disease) - /datum/disease
|
||||
if(spread_flags & CONTACT_FEET || spread_flags & CONTACT_HANDS || spread_flags & CONTACT_GENERAL)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
//don't use this proc directly. this should only ever be called by cure()
|
||||
/datum/disease/proc/remove_virus()
|
||||
affected_mob.viruses -= src //remove the datum from the list
|
||||
if(istype(affected_mob, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = affected_mob
|
||||
H.med_hud_set_status()
|
||||
|
||||
@@ -106,7 +106,7 @@ var/list/advance_cures = list(
|
||||
var/id = "[GetDiseaseID()]"
|
||||
if(resistance && !(id in affected_mob.resistances))
|
||||
affected_mob.resistances[id] = id
|
||||
affected_mob.viruses -= src //remove the datum from the list
|
||||
remove_virus()
|
||||
del(src) //delete the datum to stop it processing
|
||||
|
||||
// Returns the advance disease with a different reference memory.
|
||||
|
||||
+133
-115
@@ -1,21 +1,91 @@
|
||||
/* Using the HUD procs is simple. Call these procs in the life.dm of the intended mob.
|
||||
Use the regular_hud_updates() proc before process_med_hud(mob) or process_sec_hud(mob) so
|
||||
the HUD updates properly! */
|
||||
/*
|
||||
* Data HUDs are now passive in order to reduce lag.
|
||||
* Add then to a mob using add_data_hud.
|
||||
* Update them when needed with the appropriate proc. (see below)
|
||||
*/
|
||||
|
||||
//Deletes the current HUD images so they can be refreshed with new ones.
|
||||
mob/proc/regular_hud_updates() //Used in the life.dm of mobs that can use HUDs.
|
||||
var/list/basic_med_hud_users = list() //yes, this is, in fact, needed
|
||||
|
||||
/*
|
||||
* GENERIC HUD PROCS
|
||||
*/
|
||||
|
||||
//Deletes all current HUD images
|
||||
/mob/proc/reset_all_data_huds()
|
||||
if(client)
|
||||
for(var/image/hud in client.images)
|
||||
if(copytext(hud.icon_state,1,4) == "hud")
|
||||
if(findtext(hud.icon_state,"hud",1,4))
|
||||
client.images -= hud
|
||||
med_hud_users -= src
|
||||
sec_hud_users -= src
|
||||
basic_med_hud_users -= src
|
||||
|
||||
//Adds one set of data hud images
|
||||
/mob/proc/add_data_hud(var/hud_type, var/hud_mode)
|
||||
if(!client)
|
||||
return
|
||||
|
||||
for(var/mob/living/carbon/human/H in mob_list)
|
||||
switch(hud_type)
|
||||
if(DATA_HUD_MEDICAL)
|
||||
if(hud_mode == DATA_HUD_BASIC)
|
||||
basic_med_hud_users += src
|
||||
add_med_hud(hud_mode,H)
|
||||
if(DATA_HUD_SECURITY)
|
||||
add_sec_hud(hud_mode,H)
|
||||
|
||||
|
||||
//Medical HUD procs
|
||||
/***********************************************
|
||||
Medical HUD! Basic mode needs suit sensors on.
|
||||
************************************************/
|
||||
|
||||
proc/RoundHealth(health)
|
||||
/*
|
||||
* THESE SHOULD BE CALLED BY THE MOB SEEING THE HUD
|
||||
*/
|
||||
|
||||
/mob/proc/add_med_hud(var/mode, var/mob/living/carbon/human/patient)
|
||||
if(mode == DATA_HUD_BASIC) //Used for the AI's MedHUD, only works if the patient has activated suit sensors.
|
||||
if(!patient.w_uniform) return
|
||||
var/obj/item/clothing/under/U = patient.w_uniform
|
||||
if(U.sensor_mode <= 2) return
|
||||
add_single_med_hud(patient)
|
||||
|
||||
//Adds a single mob's med HUD to view
|
||||
/mob/proc/add_single_med_hud(var/mob/living/carbon/human/H)
|
||||
if(client)
|
||||
client.images += H.hud_list[HEALTH_HUD]
|
||||
client.images += H.hud_list[STATUS_HUD]
|
||||
|
||||
//Deletes a single mob's med HUD from view
|
||||
/mob/proc/remove_single_med_hud(var/mob/living/carbon/human/H)
|
||||
if(client)
|
||||
client.images -= H.hud_list[HEALTH_HUD]
|
||||
client.images -= H.hud_list[STATUS_HUD]
|
||||
|
||||
|
||||
/*
|
||||
* THESE SHOULD BE CALLED BY THE MOB SHOWING THE HUD
|
||||
*/
|
||||
|
||||
//called when a human changes suit sensors
|
||||
/mob/living/carbon/human/proc/update_suit_sensors(var/obj/item/clothing/under/w_uniform)
|
||||
var/sensor_level = 0
|
||||
if(w_uniform) sensor_level = w_uniform.sensor_mode
|
||||
update_med_hud_suit_sensors(sensor_level)
|
||||
..()
|
||||
|
||||
//called when a human changes suit sensors
|
||||
/mob/living/carbon/human/proc/update_med_hud_suit_sensors(sensor_level)
|
||||
for(var/mob/M in basic_med_hud_users)
|
||||
sensor_level > 2 ? M.add_single_med_hud(src) : M.remove_single_med_hud(src)
|
||||
|
||||
//called when a human changes virus
|
||||
/mob/living/carbon/human/proc/check_virus()
|
||||
for(var/datum/disease/D in viruses)
|
||||
if((!(D.visibility_flags & HIDDEN_SCANNER)) && (D.severity != NONTHREAT))
|
||||
return 1
|
||||
return 0
|
||||
|
||||
//helper for getting the appropriate health status
|
||||
/proc/RoundHealth(health)
|
||||
switch(health)
|
||||
if(100 to INFINITY)
|
||||
return "health100"
|
||||
@@ -37,146 +107,94 @@ proc/RoundHealth(health)
|
||||
return "health-100"
|
||||
return "0"
|
||||
|
||||
/*Called by the Life() proc of the mob using it, usually. Items can call it as well.
|
||||
Called with this syntax: (The user mob, the type of hud in use, the advanced or basic version of the hud,eye object in the case of an AI) */
|
||||
|
||||
proc/process_data_hud(var/mob/M, var/hud_type, var/hud_mode, var/mob/eye)
|
||||
#define DATA_HUD_MEDICAL 1
|
||||
#define DATA_HUD_SECURITY 2
|
||||
|
||||
#define DATA_HUD_BASIC 1
|
||||
#define DATA_HUD_ADVANCED 2
|
||||
|
||||
if(!M)
|
||||
return
|
||||
if(!M.client)
|
||||
return
|
||||
|
||||
var/turf/T
|
||||
if(eye)
|
||||
T = get_turf(eye)
|
||||
else
|
||||
T = get_turf(M)
|
||||
|
||||
|
||||
for(var/mob/living/carbon/human/H in mob_list)
|
||||
if(get_dist(H, T) > M.client.view) //Ignores any humans outside of the user's view distance.
|
||||
continue
|
||||
|
||||
switch(hud_type)
|
||||
if(DATA_HUD_MEDICAL)
|
||||
med_hud_users |= M
|
||||
process_med_hud(M,hud_mode,T,H)
|
||||
|
||||
if(DATA_HUD_SECURITY)
|
||||
sec_hud_users |= M //Used for Security HUD alerts.
|
||||
process_sec_hud(M,hud_mode,T,H)
|
||||
|
||||
/***********************************************
|
||||
Medical HUD outputs! Advanced mode ignores suit sensors.
|
||||
************************************************/
|
||||
proc/process_med_hud(var/mob/M, var/mode, var/turf/T, var/mob/living/carbon/human/patient)
|
||||
|
||||
var/client/C = M.client
|
||||
|
||||
if(mode == DATA_HUD_BASIC && !med_hud_suit_sensors(patient)) //Used for the AI's MedHUD, only works if the patient has activated suit sensors.
|
||||
return
|
||||
|
||||
|
||||
var/foundVirus = med_hud_find_virus(patient) //Detects non-hidden diseases in a patient, returns as a binary value.
|
||||
|
||||
C.images += med_hud_get_health(patient) //Generates a patient's health bar.
|
||||
C.images += med_hud_get_status(patient, foundVirus) //Determines the type of status icon to show.
|
||||
|
||||
|
||||
proc/med_hud_suit_sensors(var/mob/living/carbon/human/patient)
|
||||
if(istype(patient.w_uniform, /obj/item/clothing/under))
|
||||
var/obj/item/clothing/under/U = patient.w_uniform
|
||||
if(U.sensor_mode > 2)
|
||||
return 1
|
||||
else
|
||||
return 0
|
||||
|
||||
proc/med_hud_find_virus(var/mob/living/carbon/human/patient)
|
||||
for(var/datum/disease/D in patient.viruses)
|
||||
if(!(D.visibility_flags & HIDDEN_SCANNER))
|
||||
if(D.severity != NONTHREAT)
|
||||
return 1
|
||||
|
||||
proc/med_hud_get_health(var/mob/living/carbon/human/patient)
|
||||
var/image/holder = patient.hud_list[HEALTH_HUD]
|
||||
if(patient.stat == 2)
|
||||
//called when a human changes health
|
||||
/mob/living/carbon/human/proc/med_hud_set_health()
|
||||
var/image/holder = hud_list[HEALTH_HUD]
|
||||
if(stat == 2)
|
||||
holder.icon_state = "hudhealth-100"
|
||||
else
|
||||
holder.icon_state = "hud[RoundHealth(patient.health)]"
|
||||
return holder
|
||||
holder.icon_state = "hud[RoundHealth(health)]"
|
||||
|
||||
proc/med_hud_get_status(var/mob/living/carbon/human/patient, var/foundVirus)
|
||||
var/image/holder = patient.hud_list[STATUS_HUD]
|
||||
if(patient.stat == 2)
|
||||
//called when a human changes stat, virus or XENO_HOST
|
||||
/mob/living/carbon/human/proc/med_hud_set_status()
|
||||
var/image/holder = hud_list[STATUS_HUD]
|
||||
if(stat == 2)
|
||||
holder.icon_state = "huddead"
|
||||
else if(patient.status_flags & XENO_HOST)
|
||||
else if(status_flags & XENO_HOST)
|
||||
holder.icon_state = "hudxeno"
|
||||
else if(foundVirus)
|
||||
else if(check_virus())
|
||||
holder.icon_state = "hudill"
|
||||
else
|
||||
holder.icon_state = "hudhealthy"
|
||||
return holder
|
||||
|
||||
|
||||
/***********************************************
|
||||
Security HUDs.
|
||||
Pass a value for the second argument to enable implant viewing or other special features.
|
||||
Security HUDs! Basic mode shows only the job.
|
||||
************************************************/
|
||||
proc/process_sec_hud(var/mob/M, var/mode, var/turf/T, var/mob/living/carbon/human/perp)
|
||||
|
||||
var/client/C = M.client
|
||||
/*
|
||||
* THESE SHOULD BE CALLED BY THE MOB SEEING THE HUD
|
||||
*/
|
||||
|
||||
sec_hud_get_ID(C, perp) //Provides the perp's job icon.
|
||||
/mob/proc/add_sec_hud(var/mode, var/mob/living/carbon/human/perp)
|
||||
add_single_sec_hud_basic(perp)
|
||||
|
||||
if(mode == DATA_HUD_ADVANCED) //If not set to "DATA_HUD_ADVANCED, the Sec HUD will only display the job.
|
||||
sec_hud_get_implants(C, perp) //Returns the perp's implants, if any.
|
||||
sec_hud_get_security_status(C, perp) //Gives the perp's arrest record, if there is one.
|
||||
if(mode == DATA_HUD_ADVANCED) //If not set to DATA_HUD_ADVANCED, the Sec HUD will only display the job.
|
||||
add_single_sec_hud_advanced(perp)
|
||||
|
||||
//Adds a single mob's basic sec HUD to view
|
||||
/mob/proc/add_single_sec_hud_basic(var/mob/living/carbon/human/H)
|
||||
if(client)
|
||||
client.images += H.hud_list[ID_HUD]
|
||||
|
||||
proc/sec_hud_get_ID(var/client/C, var/mob/living/carbon/human/perp)
|
||||
var/image/holder
|
||||
holder = perp.hud_list[ID_HUD]
|
||||
//Adds a single mob's advanced sec HUD to view
|
||||
/mob/proc/add_single_sec_hud_advanced(var/mob/living/carbon/human/H)
|
||||
if(client)
|
||||
client.images += H.hud_list[IMPTRACK_HUD]
|
||||
client.images += H.hud_list[IMPLOYAL_HUD]
|
||||
client.images += H.hud_list[IMPCHEM_HUD]
|
||||
client.images += H.hud_list[WANTED_HUD]
|
||||
|
||||
/*
|
||||
* THESE SHOULD BE CALLED BY THE MOB SHOWING THE HUD
|
||||
*/
|
||||
|
||||
//These should only be called when necessary in order to reduce lag
|
||||
/mob/living/carbon/human/proc/sec_hud_set_ID()
|
||||
var/image/holder = hud_list[ID_HUD]
|
||||
holder.icon_state = "hudno_id"
|
||||
if(perp.wear_id)
|
||||
holder.icon_state = "hud[ckey(perp.wear_id.GetJobName())]"
|
||||
C.images += holder
|
||||
if(wear_id)
|
||||
holder.icon_state = "hud[ckey(wear_id.GetJobName())]"
|
||||
|
||||
proc/sec_hud_get_implants(var/client/C, var/mob/living/carbon/human/perp)
|
||||
/mob/living/carbon/human/proc/sec_hud_set_implants()
|
||||
var/image/holder
|
||||
for(var/obj/item/weapon/implant/I in perp)
|
||||
for(var/I in list(IMPTRACK_HUD, IMPLOYAL_HUD, IMPCHEM_HUD))
|
||||
holder = hud_list[I]
|
||||
holder.icon_state = null
|
||||
for(var/obj/item/weapon/implant/I in src)
|
||||
if(I.implanted)
|
||||
if(istype(I,/obj/item/weapon/implant/tracking))
|
||||
holder = perp.hud_list[IMPTRACK_HUD]
|
||||
holder = hud_list[IMPTRACK_HUD]
|
||||
holder.icon_state = "hud_imp_tracking"
|
||||
else if(istype(I,/obj/item/weapon/implant/loyalty))
|
||||
holder = perp.hud_list[IMPLOYAL_HUD]
|
||||
holder = hud_list[IMPLOYAL_HUD]
|
||||
holder.icon_state = "hud_imp_loyal"
|
||||
else if(istype(I,/obj/item/weapon/implant/chem))
|
||||
holder = perp.hud_list[IMPCHEM_HUD]
|
||||
holder = hud_list[IMPCHEM_HUD]
|
||||
holder.icon_state = "hud_imp_chem"
|
||||
else
|
||||
continue
|
||||
C.images += holder
|
||||
break
|
||||
|
||||
proc/sec_hud_get_security_status(var/client/C, var/mob/living/carbon/human/perp)
|
||||
/mob/living/carbon/human/proc/sec_hud_set_security_status()
|
||||
var/image/holder
|
||||
var/perpname = perp.get_face_name(perp.get_id_name(""))
|
||||
var/perpname = get_face_name(get_id_name(""))
|
||||
if(perpname)
|
||||
var/datum/data/record/R = find_record("name", perpname, data_core.security)
|
||||
if(R)
|
||||
holder = perp.hud_list[WANTED_HUD]
|
||||
holder = hud_list[WANTED_HUD]
|
||||
switch(R.fields["criminal"])
|
||||
if("*Arrest*") holder.icon_state = "hudwanted"
|
||||
if("Incarcerated") holder.icon_state = "hudincarcerated"
|
||||
if("Parolled") holder.icon_state = "hudparolled"
|
||||
if("Discharged") holder.icon_state = "huddischarged"
|
||||
else
|
||||
return
|
||||
C.images += holder
|
||||
if("Discharged") holder.icon_state = "huddischarged"
|
||||
else holder.icon_state = null
|
||||
|
||||
@@ -25,5 +25,9 @@
|
||||
user.status_flags &= ~(FAKEDEATH)
|
||||
user.update_canmove()
|
||||
user.mind.changeling.purchasedpowers -= src
|
||||
if(istype(user, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.med_hud_set_status()
|
||||
H.med_hud_set_health()
|
||||
feedback_add_details("changeling_powers","CR")
|
||||
return 1
|
||||
return 1
|
||||
|
||||
@@ -43,6 +43,7 @@ Captain
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
H.sec_hud_set_implants()
|
||||
|
||||
minor_announce("Captain [H.real_name] on deck!")
|
||||
|
||||
|
||||
@@ -53,6 +53,7 @@ Head of Security
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
H.sec_hud_set_implants()
|
||||
|
||||
/*
|
||||
Warden
|
||||
@@ -94,6 +95,7 @@ Warden
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
H.sec_hud_set_implants()
|
||||
|
||||
/datum/job/warden/get_access()
|
||||
var/list/L = list()
|
||||
@@ -143,6 +145,7 @@ Detective
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
H.sec_hud_set_implants()
|
||||
|
||||
/*
|
||||
Security Officer
|
||||
@@ -187,6 +190,7 @@ Security Officer
|
||||
var/obj/item/weapon/implant/loyalty/L = new/obj/item/weapon/implant/loyalty(H)
|
||||
L.imp_in = H
|
||||
L.implanted = 1
|
||||
H.sec_hud_set_implants()
|
||||
|
||||
/datum/job/officer/get_access()
|
||||
var/list/L = list()
|
||||
|
||||
@@ -628,7 +628,8 @@ What a mess.*/
|
||||
if("released")
|
||||
active2.fields["criminal"] = "Discharged"
|
||||
investigate_log("[active1.fields["name"]] has been set from [old_field] to [active2.fields["criminal"]] by [usr.name] ([usr.key]).", "records")
|
||||
|
||||
for(var/mob/living/carbon/human/H in mob_list) //thanks for forcing me to do this, whoever wrote this shitty records system
|
||||
H.sec_hud_set_security_status()
|
||||
if ("Delete Record (Security) Execute")
|
||||
investigate_log("[usr.name] ([usr.key]) has deleted the security records for [active1.fields["name"]].", "records")
|
||||
if (active2)
|
||||
|
||||
@@ -24,9 +24,10 @@
|
||||
var/id = null // id of door it controls.
|
||||
var/releasetime = 0 // when world.time reaches it - release the prisoneer
|
||||
var/timelength = 0 // the length of time this door will be set for
|
||||
var/timing = 1 // boolean, true/1 timer is on, false/0 means it's not timing
|
||||
var/timing = 0 // boolean, true/1 timer is on, false/0 means it's not timing
|
||||
var/picture_state // icon_state of alert picture, if not displaying text/numbers
|
||||
var/list/obj/machinery/targets = list()
|
||||
var/obj/item/device/radio/Radio //needed to send messages to sec radio
|
||||
|
||||
maptext_height = 26
|
||||
maptext_width = 32
|
||||
@@ -34,6 +35,9 @@
|
||||
/obj/machinery/door_timer/New()
|
||||
..()
|
||||
|
||||
Radio = new/obj/item/device/radio(src)
|
||||
Radio.listening = 0
|
||||
|
||||
pixel_x = ((src.dir & 3)? (0) : (src.dir == 4 ? 32 : -32))
|
||||
pixel_y = ((src.dir & 3)? (src.dir ==1 ? 24 : -32) : (0))
|
||||
|
||||
@@ -64,7 +68,8 @@
|
||||
if(stat & (NOPOWER|BROKEN)) return
|
||||
if(timing)
|
||||
if(world.time > src.releasetime)
|
||||
broadcast_hud_message("[src]'s timer has expired. Releasing prisoner.", src)
|
||||
Radio.set_frequency(SEC_FREQ)
|
||||
Radio.talk_into(src, "Timer has expired. Releasing prisoner.", SEC_FREQ)
|
||||
src.timer_end() // open doors, reset timer, clear status screen
|
||||
timing = 0
|
||||
timeset(0)
|
||||
|
||||
@@ -9,102 +9,23 @@
|
||||
internal_damage_threshold = 35
|
||||
deflect_chance = 15
|
||||
step_energy_drain = 6
|
||||
var/obj/item/clothing/glasses/hud/health/mech/hud
|
||||
|
||||
/obj/mecha/medical/odysseus/New()
|
||||
..()
|
||||
hud = new /obj/item/clothing/glasses/hud/health/mech(src)
|
||||
return
|
||||
var/builtin_hud_user = 0
|
||||
|
||||
/obj/mecha/medical/odysseus/moved_inside(var/mob/living/carbon/human/H as mob)
|
||||
if(..())
|
||||
if(H.glasses)
|
||||
occupant_message("<font color='red'>[H.glasses] prevent you from using [src] [hud]</font>")
|
||||
if(H.glasses && istype(H.glasses, /obj/item/clothing/glasses/hud))
|
||||
occupant_message("<span class='warning'>Your [H.glasses] prevent you from using the built-in medical hud.</span>")
|
||||
else
|
||||
H.glasses = hud
|
||||
H.add_data_hud(DATA_HUD_MEDICAL, DATA_HUD_ADVANCED)
|
||||
builtin_hud_user = 1
|
||||
return 1
|
||||
else
|
||||
return 0
|
||||
|
||||
/obj/mecha/medical/odysseus/go_out()
|
||||
if(ishuman(occupant))
|
||||
if(ishuman(occupant) && builtin_hud_user)
|
||||
var/mob/living/carbon/human/H = occupant
|
||||
if(H.glasses == hud)
|
||||
H.glasses = null
|
||||
H.reset_all_data_huds()
|
||||
..()
|
||||
return
|
||||
/*
|
||||
/obj/mecha/medical/odysseus/verb/set_perspective()
|
||||
set name = "Set client perspective."
|
||||
set category = "Exosuit Interface"
|
||||
set src = usr.loc
|
||||
var/perspective = input("Select a perspective type.",
|
||||
"Client perspective",
|
||||
occupant.client.perspective) in list(MOB_PERSPECTIVE,EYE_PERSPECTIVE)
|
||||
world << "[perspective]"
|
||||
occupant.client.perspective = perspective
|
||||
return
|
||||
|
||||
/obj/mecha/medical/odysseus/verb/toggle_eye()
|
||||
set name = "Toggle eye."
|
||||
set category = "Exosuit Interface"
|
||||
set src = usr.loc
|
||||
if(occupant.client.eye == occupant)
|
||||
occupant.client.eye = src
|
||||
else
|
||||
occupant.client.eye = occupant
|
||||
world << "[occupant.client.eye]"
|
||||
return
|
||||
*/
|
||||
|
||||
//TODO - Check documentation for client.eye and client.perspective...
|
||||
/obj/item/clothing/glasses/hud/health/mech
|
||||
name = "integrated medical Hud"
|
||||
|
||||
|
||||
/obj/item/clothing/glasses/hud/health/mech/process_hud(var/mob/M)
|
||||
/*
|
||||
world<< "view(M)"
|
||||
for(var/mob/mob in view(M))
|
||||
world << "[mob]"
|
||||
world<< "view(M.client)"
|
||||
for(var/mob/mob in view(M.client))
|
||||
world << "[mob]"
|
||||
world<< "view(M.loc)"
|
||||
for(var/mob/mob in view(M.loc))
|
||||
world << "[mob]"
|
||||
*/
|
||||
|
||||
if(!M || M.stat || !(M in view(M))) return
|
||||
if(!M.client) return
|
||||
var/client/C = M.client
|
||||
var/image/holder
|
||||
for(var/mob/living/carbon/human/patient in view(M.loc))
|
||||
if(M.see_invisible < patient.invisibility)
|
||||
continue
|
||||
var/foundVirus = 0
|
||||
for(var/datum/disease/D in patient.viruses)
|
||||
if(!(D.visibility_flags & HIDDEN_SCANNER))
|
||||
if(D.severity != NONTHREAT)
|
||||
foundVirus++
|
||||
//if(patient.virus2)
|
||||
// foundVirus++
|
||||
|
||||
holder = patient.hud_list[HEALTH_HUD]
|
||||
if(patient.stat == 2)
|
||||
holder.icon_state = "hudhealth-100"
|
||||
C.images += holder
|
||||
else
|
||||
holder.icon_state = "hud[RoundHealth(patient.health)]"
|
||||
C.images += holder
|
||||
|
||||
holder = patient.hud_list[STATUS_HUD]
|
||||
if(patient.stat == 2)
|
||||
holder.icon_state = "huddead"
|
||||
else if(patient.status_flags & XENO_HOST)
|
||||
holder.icon_state = "hudxeno"
|
||||
else if(foundVirus)
|
||||
holder.icon_state = "hudill"
|
||||
else
|
||||
holder.icon_state = "hudhealthy"
|
||||
C.images += holder
|
||||
|
||||
@@ -221,9 +221,6 @@
|
||||
/obj/item/proc/talk_into(mob/M as mob, text)
|
||||
return
|
||||
|
||||
/obj/item/proc/moved(mob/user as mob, old_loc as turf)
|
||||
return
|
||||
|
||||
/obj/item/proc/dropped(mob/user as mob)
|
||||
..()
|
||||
|
||||
|
||||
@@ -27,6 +27,9 @@
|
||||
/obj/item/weapon/implant/proc/implanted(var/mob/source)
|
||||
if(activated)
|
||||
action_button_name = "Activate [src.name]"
|
||||
if(istype(source, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = source
|
||||
H.sec_hud_set_implants()
|
||||
return 1
|
||||
|
||||
|
||||
@@ -205,4 +208,4 @@
|
||||
/obj/item/weapon/implant/emp/activate()
|
||||
if (src.uses < 1) return 0
|
||||
src.uses--
|
||||
empulse(imp_in, 3, 5)
|
||||
empulse(imp_in, 3, 5)
|
||||
|
||||
@@ -33,14 +33,10 @@
|
||||
var/darkness_view = 2//Base human is 2
|
||||
var/invis_view = SEE_INVISIBLE_LIVING
|
||||
var/emagged = 0
|
||||
var/hud = null
|
||||
var/list/icon/current = list() //the current hud icons
|
||||
strip_delay = 20
|
||||
put_on_delay = 25
|
||||
|
||||
/obj/item/clothing/glasses/proc/process_hud(var/mob/M)
|
||||
return
|
||||
|
||||
/*
|
||||
SEE_SELF // can see self, no matter what
|
||||
SEE_MOBS // can see all mobs, no matter what
|
||||
@@ -268,7 +264,7 @@ atom/proc/generate_female_clothing(index,t_color,icon)
|
||||
var/mob/M = usr
|
||||
if (istype(M, /mob/dead/))
|
||||
return
|
||||
if (!can_use(usr))
|
||||
if (!can_use(M))
|
||||
return
|
||||
if(src.has_sensor >= 2)
|
||||
usr << "The controls are locked."
|
||||
@@ -281,13 +277,17 @@ atom/proc/generate_female_clothing(index,t_color,icon)
|
||||
src.sensor_mode = 0
|
||||
switch(src.sensor_mode)
|
||||
if(0)
|
||||
usr << "You disable your suit's remote sensing equipment."
|
||||
M << "You disable your suit's remote sensing equipment."
|
||||
if(1)
|
||||
usr << "Your suit will now report whether you are live or dead."
|
||||
M << "Your suit will now report whether you are live or dead."
|
||||
if(2)
|
||||
usr << "Your suit will now report your vital lifesigns."
|
||||
M << "Your suit will now report your vital lifesigns."
|
||||
if(3)
|
||||
usr << "Your suit will now report your vital lifesigns as well as your coordinate position."
|
||||
M << "Your suit will now report your vital lifesigns as well as your coordinate position."
|
||||
if(istype(M,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = M
|
||||
if(H.w_uniform == src)
|
||||
H.update_suit_sensors(src)
|
||||
..()
|
||||
|
||||
/obj/item/clothing/under/verb/rolldown()
|
||||
|
||||
@@ -3,7 +3,23 @@
|
||||
desc = "A heads-up display that provides important info in (almost) real time."
|
||||
flags = null //doesn't protect eyes because it's a monocle, duh
|
||||
origin_tech = "magnets=3;biotech=2"
|
||||
hud = 1
|
||||
action_button_name = "Enable HUD"
|
||||
var/hud_type = null
|
||||
var/hud_on = 0
|
||||
|
||||
/obj/item/clothing/glasses/hud/attack_self(mob/user)
|
||||
if(istype(user, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(H.glasses == src)
|
||||
hud_on = !hud_on
|
||||
hud_on ? user.add_data_hud(hud_type,DATA_HUD_ADVANCED) : user.reset_all_data_huds()
|
||||
H << "<span class=notice>You [hud_on ? "enable" : "disable"] the HUD glasses.</span>"
|
||||
else
|
||||
H << "<span class=notice>You are not wearing the HUD glasses.</span>"
|
||||
|
||||
/obj/item/clothing/glasses/hud/dropped(mob/user)
|
||||
user.reset_all_data_huds()
|
||||
hud_on = 0
|
||||
|
||||
/* /obj/item/clothing/glasses/hud/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
..()
|
||||
@@ -25,11 +41,7 @@
|
||||
name = "Health Scanner HUD"
|
||||
desc = "A heads-up display that scans the humans in view and provides accurate data about their health status."
|
||||
icon_state = "healthhud"
|
||||
|
||||
|
||||
/obj/item/clothing/glasses/hud/health/process_hud(var/mob/M)
|
||||
process_data_hud(M,DATA_HUD_MEDICAL,DATA_HUD_ADVANCED)
|
||||
|
||||
hud_type = DATA_HUD_MEDICAL
|
||||
|
||||
/obj/item/clothing/glasses/hud/health/night
|
||||
name = "Night Vision Health Scanner HUD"
|
||||
@@ -43,6 +55,7 @@
|
||||
name = "Security HUD"
|
||||
desc = "A heads-up display that scans the humans in view and provides accurate data about their ID status and security records."
|
||||
icon_state = "securityhud"
|
||||
hud_type = DATA_HUD_SECURITY
|
||||
|
||||
/obj/item/clothing/glasses/hud/security/eyepatch
|
||||
name = "Eyepatch HUD"
|
||||
@@ -68,5 +81,3 @@
|
||||
emagged = 1
|
||||
desc = desc + " The display flickers slightly."
|
||||
|
||||
/obj/item/clothing/glasses/hud/security/process_hud(var/mob/M)
|
||||
process_data_hud(M,DATA_HUD_SECURITY,DATA_HUD_ADVANCED)
|
||||
|
||||
@@ -45,7 +45,5 @@
|
||||
else
|
||||
D = new virus_type()
|
||||
D.carrier = 1
|
||||
D.holder = H
|
||||
D.affected_mob = H
|
||||
H.viruses += D
|
||||
H.AddDisease(D)
|
||||
break
|
||||
@@ -14,7 +14,5 @@
|
||||
continue
|
||||
|
||||
var/datum/disease/D = new /datum/disease/appendicitis
|
||||
D.holder = H
|
||||
D.affected_mob = H
|
||||
H.viruses += D
|
||||
H.AddDisease(D)
|
||||
break
|
||||
@@ -12,9 +12,13 @@
|
||||
var/obj/item/weapon/card/id/prisoner/inserted_id
|
||||
var/obj/machinery/door/airlock/release_door
|
||||
var/door_tag = "prisonshuttle"
|
||||
var/obj/item/device/radio/Radio //needed to send messages to sec radio
|
||||
|
||||
|
||||
/obj/machinery/mineral/labor_claim_console/New()
|
||||
..()
|
||||
Radio = new/obj/item/device/radio(src)
|
||||
Radio.listening = 0
|
||||
spawn(7)
|
||||
src.machine = locate(/obj/machinery/mineral/stacking_machine, get_step(src, machinedir))
|
||||
var/t
|
||||
@@ -93,7 +97,8 @@
|
||||
if(s.location == /area/shuttle/laborcamp/outpost)
|
||||
if(alone_in_area(get_area(loc), usr))
|
||||
if (s.move_shuttle(0)) // No delay, to stop people from getting on while it is departing.
|
||||
broadcast_hud_message("<B>[inserted_id.registered_name]</B> has met their quota and has returned to the station. Minerals and Prisoner ID card ready for retrieval.", src)
|
||||
Radio.set_frequency(SEC_FREQ)
|
||||
Radio.talk_into(src, "[inserted_id.registered_name] has returned to the station. Minerals and Prisoner ID card ready for retrieval.", SEC_FREQ)
|
||||
usr << "<span class='notice'>Shuttle recieved message and will be sent shortly.</span>"
|
||||
else
|
||||
usr << "<span class='notice'>Shuttle is already moving.</span>"
|
||||
@@ -162,4 +167,4 @@
|
||||
else
|
||||
user << "<span class='warning'>Error: Invalid ID</span>"
|
||||
return
|
||||
..()
|
||||
..()
|
||||
|
||||
@@ -14,6 +14,9 @@ var/const/ALIEN_AFK_BRACKET = 450 // 45 seconds
|
||||
if(istype(loc, /mob/living))
|
||||
affected_mob = loc
|
||||
affected_mob.status_flags |= XENO_HOST
|
||||
if(istype(affected_mob,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = affected_mob
|
||||
H.med_hud_set_status()
|
||||
processing_objects.Add(src)
|
||||
spawn(0)
|
||||
AddInfectionImages(affected_mob)
|
||||
@@ -23,6 +26,9 @@ var/const/ALIEN_AFK_BRACKET = 450 // 45 seconds
|
||||
/obj/item/alien_embryo/Destroy()
|
||||
if(affected_mob)
|
||||
affected_mob.status_flags &= ~(XENO_HOST)
|
||||
if(istype(affected_mob,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = affected_mob
|
||||
H.med_hud_set_status()
|
||||
spawn(0)
|
||||
RemoveInfectionImages(affected_mob)
|
||||
..()
|
||||
@@ -31,6 +37,9 @@ var/const/ALIEN_AFK_BRACKET = 450 // 45 seconds
|
||||
if(!affected_mob) return
|
||||
if(loc != affected_mob)
|
||||
affected_mob.status_flags &= ~(XENO_HOST)
|
||||
if(istype(affected_mob,/mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = affected_mob
|
||||
H.med_hud_set_status()
|
||||
processing_objects.Remove(src)
|
||||
spawn(0)
|
||||
RemoveInfectionImages(affected_mob)
|
||||
@@ -132,4 +141,4 @@ Des: Removes all images from the mob infected by this embryo
|
||||
if(alien.client)
|
||||
for(var/image/I in alien.client.images)
|
||||
if(dd_hasprefix_case(I.icon_state, "infected") && I.loc == affected_mob)
|
||||
qdel(I)
|
||||
qdel(I)
|
||||
|
||||
@@ -36,6 +36,8 @@
|
||||
|
||||
if(dna)
|
||||
dna.species.spec_death(gibbed,src)
|
||||
med_hud_set_health()
|
||||
med_hud_set_status()
|
||||
|
||||
tod = worldtime2text() //weasellos time of death patch
|
||||
if(mind) mind.store_memory("Time of death: [tod]", 0)
|
||||
@@ -66,4 +68,4 @@
|
||||
/mob/living/carbon/proc/Drain()
|
||||
ChangeToHusk()
|
||||
mutations |= NOCLONE
|
||||
return 1
|
||||
return 1
|
||||
|
||||
@@ -28,7 +28,13 @@
|
||||
internal_organs += new /obj/item/organ/brain
|
||||
|
||||
for(var/i=0;i<7;i++) // 2 for medHUDs and 5 for secHUDs
|
||||
hud_list += image('icons/mob/hud.dmi', src, "hudunknown")
|
||||
hud_list += image('icons/mob/hud.dmi', src, "")
|
||||
|
||||
med_hud_set_health()
|
||||
med_hud_set_status()
|
||||
sec_hud_set_ID()
|
||||
sec_hud_set_implants()
|
||||
sec_hud_set_security_status()
|
||||
|
||||
// for spawned humans; overwritten by other code
|
||||
create_dna(src)
|
||||
@@ -400,9 +406,7 @@
|
||||
if(setcriminal != "Cancel")
|
||||
investigate_log("[src.key] has been set from [R.fields["criminal"]] to [setcriminal] by [usr.name] ([usr.key]).", "records")
|
||||
R.fields["criminal"] = setcriminal
|
||||
|
||||
spawn()
|
||||
H.handle_regular_hud_updates()
|
||||
sec_hud_set_security_status()
|
||||
return
|
||||
|
||||
if(href_list["view"])
|
||||
|
||||
@@ -13,6 +13,8 @@
|
||||
//TODO: fix husking
|
||||
if( ((maxHealth - total_burn) < config.health_threshold_dead) && stat == DEAD )
|
||||
ChangeToHusk()
|
||||
med_hud_set_health()
|
||||
med_hud_set_status()
|
||||
return
|
||||
|
||||
|
||||
|
||||
@@ -260,6 +260,7 @@
|
||||
if(belt)
|
||||
unEquip(belt)
|
||||
w_uniform = null
|
||||
update_suit_sensors(w_uniform)
|
||||
update_inv_w_uniform(0)
|
||||
else if(I == gloves)
|
||||
gloves = null
|
||||
@@ -289,9 +290,11 @@
|
||||
if(internals)
|
||||
internals.icon_state = "internal0"
|
||||
internal = null
|
||||
sec_hud_set_ID()
|
||||
update_inv_wear_mask(0)
|
||||
else if(I == wear_id)
|
||||
wear_id = null
|
||||
sec_hud_set_ID()
|
||||
update_inv_wear_id(0)
|
||||
else if(I == r_store)
|
||||
r_store = null
|
||||
@@ -330,6 +333,7 @@
|
||||
wear_mask = I
|
||||
if(wear_mask.flags & BLOCKHAIR)
|
||||
update_hair(redraw_mob) //rebuild hair
|
||||
sec_hud_set_ID()
|
||||
update_inv_wear_mask(redraw_mob)
|
||||
if(slot_handcuffed)
|
||||
handcuffed = I
|
||||
@@ -348,6 +352,7 @@
|
||||
update_inv_belt(redraw_mob)
|
||||
if(slot_wear_id)
|
||||
wear_id = I
|
||||
sec_hud_set_ID()
|
||||
update_inv_wear_id(redraw_mob)
|
||||
if(slot_ears)
|
||||
ears = I
|
||||
@@ -373,6 +378,7 @@
|
||||
update_inv_wear_suit(redraw_mob)
|
||||
if(slot_w_uniform)
|
||||
w_uniform = I
|
||||
update_suit_sensors(w_uniform)
|
||||
update_inv_w_uniform(redraw_mob)
|
||||
if(slot_l_store)
|
||||
l_store = I
|
||||
@@ -387,7 +393,8 @@
|
||||
if(get_active_hand() == I)
|
||||
unEquip(I)
|
||||
I.loc = back
|
||||
return
|
||||
else
|
||||
src << "<span class='danger'>You are trying to equip this item to an unsupported inventory slot. Report this to a coder!</span>"
|
||||
return
|
||||
return
|
||||
update_action_buttons()
|
||||
|
||||
|
||||
@@ -97,7 +97,6 @@
|
||||
//Update our name based on whether our face is obscured/disfigured
|
||||
name = get_visible_name()
|
||||
|
||||
handle_regular_hud_updates()
|
||||
|
||||
if(dna)
|
||||
dna.species.spec_life(src) // for mutantraces
|
||||
@@ -583,8 +582,6 @@
|
||||
/mob/living/carbon/human/proc/handle_regular_hud_updates()
|
||||
if(!client) return 0
|
||||
|
||||
regular_hud_updates() //For MED/SEC HUD icon deletion
|
||||
|
||||
client.screen.Remove(global_hud.blurry, global_hud.druggy, global_hud.vimpaired, global_hud.darkMask)
|
||||
|
||||
update_action_buttons()
|
||||
|
||||
@@ -457,9 +457,6 @@
|
||||
H.sight |= G.vision_flags
|
||||
H.see_in_dark = G.darkness_view
|
||||
H.see_invisible = G.invis_view
|
||||
if(G.hud)
|
||||
G.process_hud(H)
|
||||
|
||||
if(H.druggy) //Override for druggy
|
||||
H.see_invisible = see_temp
|
||||
|
||||
|
||||
@@ -1,2 +0,0 @@
|
||||
/mob/living/carbon/slime/regular_hud_updates()
|
||||
return
|
||||
@@ -35,8 +35,6 @@
|
||||
//to find it.
|
||||
src.blinded = null
|
||||
|
||||
regular_hud_updates() // Basically just deletes any screen objects :<
|
||||
|
||||
if(environment)
|
||||
handle_environment(environment) // Handle temperature/pressure differences between body and environment
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@ var/list/ai_list = list()
|
||||
density = 1
|
||||
status_flags = CANSTUN|CANPARALYSE|CANPUSH
|
||||
force_compose = 1 //This ensures that the AI always composes it's own hear message. Needed for hrefs and job display.
|
||||
sensor_level = DATA_HUD_BASIC
|
||||
var/list/network = list("SS13")
|
||||
var/obj/machinery/camera/current = null
|
||||
var/list/connected_robots = list()
|
||||
|
||||
@@ -163,11 +163,6 @@
|
||||
sleep(50)
|
||||
theAPC = null
|
||||
|
||||
regular_hud_updates()
|
||||
|
||||
if(sensor_mode) //Data HUDs, such as Security or Medical HUDS. Passes the AI's eye since it seems from that instead of itself.
|
||||
process_data_hud(src,sensor_mode,DATA_HUD_BASIC,src.eyeobj)
|
||||
|
||||
/mob/living/silicon/ai/updatehealth()
|
||||
if(status_flags & GODMODE)
|
||||
health = maxHealth
|
||||
@@ -175,4 +170,4 @@
|
||||
return
|
||||
health = maxHealth - getOxyLoss() - getToxLoss() - getBruteLoss()
|
||||
if(!fire_res_on_core)
|
||||
health -= getFireLoss()
|
||||
health -= getFireLoss()
|
||||
|
||||
@@ -8,12 +8,6 @@
|
||||
M.show_message("<span class='danger'>[src.cable] rapidly retracts back into its spool.</span>", 3, "<span class='danger'>You hear a click and the sound of wire spooling rapidly.</span>", 2)
|
||||
qdel(src.cable)
|
||||
cable = null
|
||||
|
||||
regular_hud_updates()
|
||||
if(secHUD == 1)
|
||||
process_data_hud(src, DATA_HUD_SECURITY,DATA_HUD_ADVANCED)
|
||||
if(medHUD == 1)
|
||||
process_data_hud(src, DATA_HUD_MEDICAL,DATA_HUD_ADVANCED)
|
||||
if(silence_time)
|
||||
if(world.timeofday >= silence_time)
|
||||
silence_time = null
|
||||
|
||||
@@ -238,10 +238,18 @@
|
||||
temp = "Unable to locate requested security record. Record may have been deleted, or never have existed."
|
||||
if("securityhud")
|
||||
if(href_list["toggle"])
|
||||
src.secHUD = !src.secHUD
|
||||
if(secHUD)
|
||||
reset_all_data_huds()
|
||||
else
|
||||
add_data_hud(DATA_HUD_SECURITY,sensor_level)
|
||||
secHUD = !secHUD
|
||||
if("medicalhud")
|
||||
if(href_list["toggle"])
|
||||
src.medHUD = !src.medHUD
|
||||
if(medHUD)
|
||||
reset_all_data_huds()
|
||||
else
|
||||
add_data_hud(DATA_HUD_MEDICAL,sensor_level)
|
||||
medHUD = !medHUD
|
||||
if("translator")
|
||||
if(href_list["toggle"])
|
||||
languages = languages == ALL ? HUMAN & ROBOT : ALL
|
||||
|
||||
@@ -166,11 +166,6 @@
|
||||
if(see_override)
|
||||
see_invisible = see_override
|
||||
|
||||
regular_hud_updates() //Handles MED/SEC HUDs for borgs.
|
||||
|
||||
if(sensor_mode)
|
||||
process_data_hud(src,sensor_mode,DATA_HUD_ADVANCED)
|
||||
|
||||
if (src.healths)
|
||||
if (src.stat != 2)
|
||||
switch(health)
|
||||
@@ -310,4 +305,4 @@
|
||||
/mob/living/silicon/robot/update_canmove()
|
||||
if(paralysis || stunned || weakened || buckled || lockcharge) canmove = 0
|
||||
else canmove = 1
|
||||
return canmove
|
||||
return canmove
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
var/lawcheck[1]
|
||||
var/ioncheck[1]
|
||||
|
||||
var/sensor_mode = 0 //Determines the current HUD.
|
||||
var/sensor_level = DATA_HUD_ADVANCED //Determines the sensor level to use
|
||||
|
||||
/mob/living/silicon/proc/cancelAlarm()
|
||||
return
|
||||
@@ -320,15 +320,15 @@
|
||||
/mob/living/silicon/verb/sensor_mode()
|
||||
set name = "Set Sensor Augmentation"
|
||||
var/sensor_type = input("Please select sensor type.", "Sensor Integration", null) in list("Security", "Medical","Disable")
|
||||
reset_all_data_huds()
|
||||
switch(sensor_type)
|
||||
if ("Security")
|
||||
sensor_mode = DATA_HUD_SECURITY
|
||||
add_data_hud(DATA_HUD_SECURITY,sensor_level)
|
||||
src << "<span class='notice'>Security records overlay enabled.</span>"
|
||||
if ("Medical")
|
||||
sensor_mode = DATA_HUD_MEDICAL
|
||||
add_data_hud(DATA_HUD_MEDICAL,sensor_level)
|
||||
src << "<span class='notice'>Life signs monitor overlay enabled.</span>"
|
||||
if ("Disable")
|
||||
sensor_mode = 0
|
||||
src << "Sensor augmentations disabled."
|
||||
|
||||
|
||||
|
||||
@@ -463,11 +463,3 @@ proc/is_special_character(mob/M) // returns 1 for special characters and 2 for h
|
||||
else
|
||||
return
|
||||
|
||||
/proc/broadcast_hud_message(var/message, var/broadcast_source)
|
||||
var/turf/sourceturf = get_turf(broadcast_source)
|
||||
var/user_list = sec_hud_users //A local var is used for easy addition of other HUD types.
|
||||
var/hud_icon = /obj/item/weapon/restraints/handcuffs //Icon displayed when the HUD triggered. Handcuffs for Sec HUDs.
|
||||
for(var/mob/hud_user in user_list)
|
||||
var/turf/userturf = get_turf(hud_user)
|
||||
if(userturf.z == sourceturf.z) //Must have same z-level.
|
||||
hud_user.show_message("<span class='info'>\icon[hud_icon] [message]</span>", 1)
|
||||
|
||||
@@ -163,6 +163,7 @@
|
||||
viruses = list()
|
||||
for(var/datum/disease/D in O.viruses)
|
||||
D.affected_mob = O
|
||||
O.med_hud_set_status()
|
||||
|
||||
//keep damage?
|
||||
if (tr_flags & TR_KEEPDAMAGE)
|
||||
@@ -175,6 +176,7 @@
|
||||
for(var/obj/item/weapon/implant/I in implants)
|
||||
I.loc = O
|
||||
I.implanted = O
|
||||
O.sec_hud_set_implants()
|
||||
|
||||
if(mind)
|
||||
mind.transfer_to(O)
|
||||
|
||||
@@ -29,6 +29,9 @@
|
||||
if(istype(I, /obj/item/weapon/implant/loyalty))
|
||||
target << "<span class='notice'>You feel a sense of liberation as Nanotrasen's grip on your mind fades away.</span>"
|
||||
qdel(I)
|
||||
if(istype(user, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = user
|
||||
H.sec_hud_set_implants()
|
||||
else
|
||||
user.visible_message("<span class='notice'>[user] can't find anything in [target]'s [target_zone].</span>")
|
||||
return 1
|
||||
return 1
|
||||
|
||||
@@ -1068,7 +1068,6 @@
|
||||
#include "code\modules\mob\living\carbon\slime\death.dm"
|
||||
#include "code\modules\mob\living\carbon\slime\emote.dm"
|
||||
#include "code\modules\mob\living\carbon\slime\examine.dm"
|
||||
#include "code\modules\mob\living\carbon\slime\hud.dm"
|
||||
#include "code\modules\mob\living\carbon\slime\life.dm"
|
||||
#include "code\modules\mob\living\carbon\slime\login.dm"
|
||||
#include "code\modules\mob\living\carbon\slime\powers.dm"
|
||||
|
||||
Reference in New Issue
Block a user