mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-30 23:48:28 +01:00
Standardized Robotic Organ Checking--Removes Mechassited Organs
This commit is contained in:
@@ -342,7 +342,7 @@
|
||||
AdjustEyeBlurry(damage * rand(3, 6))
|
||||
|
||||
if(E.damage > (E.min_bruised_damage + E.min_broken_damage) / 2)
|
||||
if(!(E.status & ORGAN_ROBOT))
|
||||
if(!E.is_robotic())
|
||||
to_chat(src, "<span class='warning'>Your eyes start to burn badly!</span>")
|
||||
else //snowflake conditions piss me off for the record
|
||||
to_chat(src, "<span class='warning'>The flash blinds you!</span>")
|
||||
|
||||
@@ -129,7 +129,7 @@
|
||||
|
||||
/mob/living/carbon/human/proc/change_alt_head(var/alternate_head)
|
||||
var/obj/item/organ/external/head/H = get_organ("head")
|
||||
if(!H || H.alt_head == alternate_head || (H.status & ORGAN_ROBOT) || (!(species.bodyflags & HAS_ALT_HEADS) && alternate_head != "None") || !(alternate_head in alt_heads_list))
|
||||
if(!H || H.alt_head == alternate_head || H.is_robotic() || (!(species.bodyflags & HAS_ALT_HEADS) && alternate_head != "None") || !(alternate_head in alt_heads_list))
|
||||
return
|
||||
|
||||
H.alt_head = alternate_head
|
||||
|
||||
@@ -210,7 +210,7 @@
|
||||
wound_flavor_text["[organ_tag]"] = "<B>[p_they(TRUE)] [p_are()] missing [p_their()] [organ_descriptor].</B>\n"
|
||||
else
|
||||
if(!isSynthetic())
|
||||
if(E.status & ORGAN_ROBOT)
|
||||
if(E.is_robotic())
|
||||
wound_flavor_text["[E.limb_name]"] = "[p_they(TRUE)] [p_have()] a robotic [E.name]!\n"
|
||||
|
||||
else if(E.status & ORGAN_SPLINTED)
|
||||
|
||||
@@ -1065,7 +1065,7 @@
|
||||
if(!affecting)
|
||||
. = 0
|
||||
fail_msg = "[p_they(TRUE)] [p_are()] missing that limb."
|
||||
else if(affecting.status & ORGAN_ROBOT)
|
||||
else if(affecting.is_robotic())
|
||||
. = 0
|
||||
fail_msg = "That limb is robotic."
|
||||
else
|
||||
|
||||
@@ -115,7 +115,7 @@
|
||||
O.receive_damage(amount, 0, sharp=is_sharp(damage_source), used_weapon=damage_source)
|
||||
else
|
||||
//if you don't want to heal robot organs, they you will have to check that yourself before using this proc.
|
||||
O.heal_damage(-amount, 0, internal=0, robo_repair=(O.status & ORGAN_ROBOT))
|
||||
O.heal_damage(-amount, 0, internal = 0, robo_repair = O.is_robotic())
|
||||
|
||||
|
||||
/mob/living/carbon/human/proc/adjustFireLossByPart(amount, organ_name, obj/damage_source = null)
|
||||
@@ -129,7 +129,7 @@
|
||||
O.receive_damage(0, amount, sharp=is_sharp(damage_source), used_weapon=damage_source)
|
||||
else
|
||||
//if you don't want to heal robot organs, they you will have to check that yourself before using this proc.
|
||||
O.heal_damage(0, -amount, internal=0, robo_repair=(O.status & ORGAN_ROBOT))
|
||||
O.heal_damage(0, -amount, internal = 0, robo_repair = O.is_robotic())
|
||||
|
||||
|
||||
/mob/living/carbon/human/Paralyse(amount)
|
||||
@@ -149,7 +149,7 @@
|
||||
if(prob(mut_prob))
|
||||
var/list/obj/item/organ/external/candidates = list() //TYPECASTED LISTS ARE NOT A FUCKING THING WHAT THE FUCK
|
||||
for(var/obj/item/organ/external/O in bodyparts)
|
||||
if(O.status & ORGAN_ROBOT)
|
||||
if(O.is_robotic())
|
||||
continue
|
||||
if(!(O.status & ORGAN_MUTATED))
|
||||
candidates |= O
|
||||
@@ -205,9 +205,9 @@
|
||||
var/list/obj/item/organ/external/parts = list()
|
||||
for(var/obj/item/organ/external/O in bodyparts)
|
||||
if((brute && O.brute_dam) || (burn && O.burn_dam))
|
||||
if(!(flags & AFFECT_ROBOTIC_ORGAN) && O.status & ORGAN_ROBOT)
|
||||
if(!(flags & AFFECT_ROBOTIC_ORGAN) && O.is_robotic())
|
||||
continue
|
||||
if(!(flags & AFFECT_ORGANIC_ORGAN) && !(O.status & ORGAN_ROBOT))
|
||||
if(!(flags & AFFECT_ORGANIC_ORGAN) && !O.is_robotic())
|
||||
continue
|
||||
parts += O
|
||||
return parts
|
||||
|
||||
@@ -165,7 +165,7 @@ emp_act
|
||||
/mob/living/carbon/human/emag_act(user as mob, var/obj/item/organ/external/affecting)
|
||||
if(!istype(affecting))
|
||||
return
|
||||
if(!(affecting.status & ORGAN_ROBOT))
|
||||
if(!affecting.is_robotic())
|
||||
to_chat(user, "<span class='warning'>That limb isn't robotic.</span>")
|
||||
return
|
||||
if(affecting.sabotaged)
|
||||
|
||||
@@ -178,7 +178,7 @@ I use this to standardize shadowling dethrall code
|
||||
/mob/living/carbon/human/has_organic_damage()
|
||||
var/odmg = 0
|
||||
for(var/obj/item/organ/external/O in bodyparts)
|
||||
if(O.status & ORGAN_ROBOT)
|
||||
if(O.is_robotic())
|
||||
odmg += O.brute_dam
|
||||
odmg += O.burn_dam
|
||||
return (health < (100 - odmg))
|
||||
|
||||
@@ -993,7 +993,7 @@
|
||||
if(!H) //H.status will runtime if there is no H (obviously)
|
||||
return
|
||||
|
||||
if(H.status & ORGAN_ROBOT) //Handle robotic hearts specially with a wuuuubb. This also applies to machine-people.
|
||||
if(H.is_robotic()) //Handle robotic hearts specially with a wuuuubb. This also applies to machine-people.
|
||||
if(shock_stage >= 10 || istype(get_turf(src), /turf/space))
|
||||
//PULSE_THREADY - maximum value for pulse, currently it 5.
|
||||
//High pulse value corresponds to a fast rate of heartbeat.
|
||||
@@ -1020,10 +1020,7 @@
|
||||
|
||||
if(heartbeat >= rate)
|
||||
heartbeat = 0
|
||||
if(H.status & ORGAN_ASSISTED)
|
||||
src << sound('sound/effects/pacemakebeat.ogg',0,0,CHANNEL_HEARTBEAT,50)
|
||||
else
|
||||
src << sound('sound/effects/singlebeat.ogg',0,0,CHANNEL_HEARTBEAT,50)
|
||||
src << sound('sound/effects/singlebeat.ogg',0,0,CHANNEL_HEARTBEAT,50)
|
||||
else
|
||||
heartbeat++
|
||||
|
||||
|
||||
@@ -241,7 +241,7 @@ var/global/list/damage_icon_parts = list()
|
||||
var/obj/item/organ/external/part = bodyparts_by_name[organ_tag]
|
||||
if(isnull(part))
|
||||
icon_key += "0"
|
||||
else if(part.status & ORGAN_ROBOT)
|
||||
else if(part.is_robotic())
|
||||
icon_key += "2[part.model ? "-[part.model]": ""]"
|
||||
else if(part.status & ORGAN_DEAD)
|
||||
icon_key += "3"
|
||||
|
||||
@@ -234,7 +234,7 @@
|
||||
var/organ_found
|
||||
if(H.internal_organs.len)
|
||||
for(var/obj/item/organ/external/E in H.bodyparts)
|
||||
if(!(E.status & ORGAN_ROBOT))
|
||||
if(!E.is_robotic())
|
||||
continue
|
||||
organ_found = 1
|
||||
to_chat(user, "[E.name]: <font color='red'>[round(E.brute_dam)]</font> <font color='#FFA500'>[round(E.burn_dam)]</font>")
|
||||
@@ -245,7 +245,7 @@
|
||||
organ_found = null
|
||||
if(H.internal_organs.len)
|
||||
for(var/obj/item/organ/internal/O in H.internal_organs)
|
||||
if(!(O.status & ORGAN_ROBOT))
|
||||
if(!O.is_robotic())
|
||||
continue
|
||||
organ_found = 1
|
||||
to_chat(user, "[capitalize(O.name)]: <font color='red'>[O.damage]</font>")
|
||||
|
||||
Reference in New Issue
Block a user