Skip to content

Commit

Permalink
more gameifed hud (#5450)
Browse files Browse the repository at this point in the history
* more gameifed hud

* genetic wounds and more icons

* sinkly red
  • Loading branch information
Trilbyspaceclone authored Jun 20, 2024
1 parent 59f41dd commit 443b7b4
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions code/modules/mob/living/carbon/human/life.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1030,6 +1030,7 @@
if(stat == DEAD)
holder.icon_state = "hudhealth-100" // X_X
else
holder.cut_overlays()
var/organ_health
var/organ_damage
var/limb_health
Expand All @@ -1040,6 +1041,22 @@
organ_damage += E.severity_internal_wounds
limb_health += E.max_damage
limb_damage += max(E.brute_dam, E.burn_dam)
if(E.status & ORGAN_BROKEN)
holder.add_overlay("hud_broken_bone")
if(E.status & ORGAN_BLEEDING)
holder.add_overlay("hud_bleeding")
if(E.status & ORGAN_INFECTED)
holder.add_overlay("hud_infection")
if(E.status & ORGAN_WOUNDED)
holder.add_overlay("hud_generic_wound")



if(vessel)
var/blood_volume = vessel.get_reagent_amount("blood")
var/blood_percent = round((blood_volume / species.blood_volume)*100)
if(blood_percent * effective_blood_volume <= total_blood_req + BLOOD_VOLUME_BAD_MODIFIER)
holder.add_overlay("hud_low_blood")

var/crit_health = (health / maxHealth) * 100
var/external_health = (1 - (limb_health ? limb_damage / limb_health : 0)) * 100
Expand Down
Binary file modified icons/mob/hud.dmi
Binary file not shown.

0 comments on commit 443b7b4

Please sign in to comment.