More hud stuff

This commit is contained in:
Aurorablade
2017-11-28 23:17:50 -05:00
parent 64c4883cc2
commit dc6bb34b38
16 changed files with 126 additions and 71 deletions
-15
View File
@@ -2,20 +2,6 @@
var/canEnterVentWith = "/obj/item/weapon/implant=0&/obj/item/clothing/mask/facehugger=0&/obj/item/device/radio/borg=0&/obj/machinery/camera=0"
var/datum/middleClickOverride/middleClickOverride = null
/mob/living/carbon/prepare_huds()
..()
prepare_data_huds()
/mob/living/carbon/proc/prepare_data_huds()
..()
med_hud_set_health()
med_hud_set_status()
/mob/living/carbon/updatehealth()
..()
med_hud_set_health()
med_hud_set_status()
/mob/living/carbon/Destroy()
QDEL_LIST(internal_organs)
QDEL_LIST(stomach_contents)
@@ -23,7 +9,6 @@
if(B)
B.leave_host()
qdel(B)
remove_from_all_data_huds()
return ..()
/mob/living/carbon/blob_act()
@@ -1,6 +1,5 @@
/mob/living/carbon
gender = MALE
hud_possible = list(HEALTH_HUD,STATUS_HUD,SPECIALROLE_HUD)
var/list/stomach_contents = list()
var/list/internal_organs = list()
var/list/internal_organs_slot = list() //Same as above, but stores "slot ID" - "organ" pairs for easy access.
+3
View File
@@ -14,4 +14,7 @@
var/datum/soullink/S = s
S.sharerDies(gibbed, src)
med_hud_set_health()
med_hud_set_status()
..(gibbed)
+16
View File
@@ -1,7 +1,22 @@
/mob/living/New()
. = ..()
var/datum/atom_hud/data/human/medical/advanced/medhud = huds[DATA_HUD_MEDICAL_ADVANCED]
medhud.add_to_hud(src)
/mob/living/prepare_huds()
..()
prepare_data_huds()
/mob/living/proc/prepare_data_huds()
..()
med_hud_set_health()
med_hud_set_status()
/mob/living/Destroy()
if(ranged_ability)
ranged_ability.remove_ranged_ability(src)
remove_from_all_data_huds()
return ..()
/mob/living/ghostize(can_reenter_corpse = 1)
@@ -214,6 +229,7 @@
stat = CONSCIOUS
return
health = maxHealth - getOxyLoss() - getToxLoss() - getFireLoss() - getBruteLoss() - getCloneLoss()
med_hud_set_health()
//This proc is used for mobs which are affected by pressure to calculate the amount of pressure that actually
@@ -64,3 +64,4 @@
var/list/recent_tastes = list()
var/blood_volume = 0 //how much blood the mob has
hud_possible = list(HEALTH_HUD,STATUS_HUD,SPECIALROLE_HUD)
@@ -44,6 +44,12 @@
add_language("Galactic Common")
init_subsystems()
/mob/living/silicon/med_hud_set_health()
return //we use a different hud
/mob/living/silicon/med_hud_set_status()
return //we use a different hud
/mob/living/silicon/Destroy()
silicon_mob_list -= src
for(var/datum/alarm_handler/AH in alarm_handlers)
@@ -75,6 +75,7 @@
var/control_freq = BOT_FREQ // bot control frequency
var/bot_filter // The radio filter the bot uses to identify itself on the network.
var/bot_type = 0 //The type of bot it is, for radio control.
var/data_hud_type = DATA_HUD_DIAGNOSTIC //The type of data HUD the bot uses. Diagnostic by default.
//This holds text for what the bot is mode doing, reported on the remote bot control interface.
var/list/mode_name = list("In Pursuit","Preparing to Arrest", "Arresting", \
"Beginning Patrol", "Patrolling", "Summoned by PDA", \
@@ -170,6 +171,13 @@
path_hud.add_to_hud(src)
path_hud.add_hud_to(src)
/mob/living/simple_animal/bot/med_hud_set_health()
return //we use a different hud
/mob/living/simple_animal/bot/med_hud_set_status()
return //we use a different hud
/mob/living/simple_animal/bot/update_canmove(delay_action_updates = 0)
. = ..()
if(!on)
@@ -21,6 +21,7 @@
window_id = "autoed209"
window_name = "Automatic Security Unit v2.6"
path_image_color = "#FF0000"
data_hud_type = DATA_HUD_SECURITY_ADVANCED
var/lastfired = 0
var/shot_delay = 3 //.3 seconds between shots
@@ -20,6 +20,7 @@
window_id = "automed"
window_name = "Automatic Medical Unit v1.1"
path_image_color = "#DDDDFF"
data_hud_type = DATA_HUD_MEDICAL_ADVANCED
var/obj/item/weapon/reagent_containers/glass/reagent_glass = null //Can be set to draw from this for reagents.
var/skin = null //Set to "tox", "ointment" or "o2" for the other two firstaid kits.
@@ -19,6 +19,7 @@
window_id = "autosec"
window_name = "Automatic Security Unit v1.6"
path_image_color = "#FF0000"
data_hud_type = DATA_HUD_SECURITY_ADVANCED
var/base_icon = "secbot"
var/mob/living/carbon/target
@@ -109,6 +109,7 @@
/mob/living/simple_animal/updatehealth()
..()
health = Clamp(health, 0, maxHealth)
med_hud_set_status()
/mob/living/simple_animal/handle_hud_icons_health()
..()