mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-24 05:23:22 +01:00
Merge remote-tracking branch 'Aurorastation/master' into you_have_ligma
This commit is contained in:
@@ -248,8 +248,8 @@ proc/blood_incompatible(donor,receiver,donor_species,receiver_species)
|
||||
if(donor_species != receiver_species)
|
||||
return 1
|
||||
|
||||
var/donor_antigen = copytext(donor,1,lentext(donor))
|
||||
var/receiver_antigen = copytext(receiver,1,lentext(receiver))
|
||||
var/donor_antigen = copytext(donor,1,length(donor))
|
||||
var/receiver_antigen = copytext(receiver,1,length(receiver))
|
||||
var/donor_rh = (findtext(donor,"+")>0)
|
||||
var/receiver_rh = (findtext(receiver,"+")>0)
|
||||
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
#define PUKE_ACTION_NAME "Empty Stomach"
|
||||
|
||||
/obj/item/organ/internal/stomach
|
||||
name = "stomach"
|
||||
desc = "Gross. This is hard to stomach."
|
||||
@@ -18,6 +20,8 @@
|
||||
ingested = new /datum/reagents/metabolism(240, owner, CHEM_INGEST)
|
||||
if(!ingested.my_atom)
|
||||
ingested.my_atom = src
|
||||
if(species.gluttonous)
|
||||
action_button_name = PUKE_ACTION_NAME
|
||||
|
||||
/obj/item/organ/internal/stomach/removed()
|
||||
. = ..()
|
||||
@@ -29,6 +33,18 @@
|
||||
ingested.my_atom = owner
|
||||
ingested.parent = owner
|
||||
|
||||
/obj/item/organ/internal/stomach/refresh_action_button()
|
||||
. = ..()
|
||||
if(.)
|
||||
action.button_icon_state = "puke"
|
||||
if(action.button) action.button.UpdateIcon()
|
||||
|
||||
/obj/item/organ/internal/stomach/attack_self(mob/user)
|
||||
. = ..()
|
||||
if(. && action_button_name == PUKE_ACTION_NAME && owner && !owner.incapacitated())
|
||||
owner.vomit(deliberate = TRUE)
|
||||
refresh_action_button()
|
||||
|
||||
/obj/item/organ/internal/stomach/proc/can_eat_atom(var/atom/movable/food)
|
||||
return !isnull(get_devour_time(food))
|
||||
|
||||
@@ -113,4 +129,5 @@
|
||||
if(prob(vomit_probability))
|
||||
owner.vomit()
|
||||
|
||||
#undef STOMACH_VOLUME
|
||||
#undef STOMACH_VOLUME
|
||||
#undef PUKE_ACTION_NAME
|
||||
@@ -305,12 +305,8 @@
|
||||
|
||||
/obj/item/organ/proc/robotize() //Being used to make robutt hearts, etc
|
||||
robotic = 2
|
||||
src.status &= ~ORGAN_BROKEN
|
||||
src.status &= ~ORGAN_BLEEDING
|
||||
src.status &= ~ORGAN_SPLINTED
|
||||
src.status &= ~ORGAN_CUT_AWAY
|
||||
src.status |= ORGAN_ROBOT
|
||||
src.status |= ORGAN_ASSISTED
|
||||
status = ORGAN_ROBOT
|
||||
status |= ORGAN_ASSISTED
|
||||
if(robotic_name)
|
||||
name = robotic_name
|
||||
if(robotic_sprite)
|
||||
@@ -318,10 +314,8 @@
|
||||
|
||||
/obj/item/organ/proc/mechassist() //Used to add things like pacemakers, etc
|
||||
robotize()
|
||||
src.status &= ~ORGAN_ROBOT
|
||||
status = ORGAN_ASSISTED
|
||||
robotic = 1
|
||||
min_bruised_damage = 15
|
||||
min_broken_damage = 35
|
||||
if(!robotize_type)
|
||||
name = initial(name)
|
||||
icon_state = initial(icon_state)
|
||||
|
||||
@@ -252,6 +252,8 @@
|
||||
brute *= brute_mod
|
||||
burn *= burn_mod
|
||||
|
||||
var/laser = (damage_flags & DAM_LASER)
|
||||
|
||||
add_pain(0.6*burn + 0.4*brute)
|
||||
|
||||
if(status & ORGAN_BROKEN && prob(40) && brute)
|
||||
@@ -305,7 +307,10 @@
|
||||
|
||||
if(burn > 0 && can_inflict)
|
||||
//Inflict all burn damage we can
|
||||
createwound(BURN, min(burn,can_inflict))
|
||||
if(laser)
|
||||
createwound(LASER, min(burn, can_inflict))
|
||||
else
|
||||
createwound(BURN, min(burn,can_inflict))
|
||||
//How much burn damage is left to inflict
|
||||
spillover += max(0, burn - can_inflict)
|
||||
|
||||
@@ -466,7 +471,8 @@ This function completely restores a damaged organ to perfect condition.
|
||||
|
||||
|
||||
/obj/item/organ/external/proc/createwound(var/type = CUT, var/damage)
|
||||
if(damage == 0) return
|
||||
|
||||
if(damage <= 0) return
|
||||
|
||||
//moved this before the open_wound check so that having many small wounds for example doesn't somehow protect you from taking internal damage (because of the return)
|
||||
//Possibly trigger an internal wound, too.
|
||||
@@ -480,6 +486,15 @@ This function completely restores a damaged organ to perfect condition.
|
||||
if(internal_damage)
|
||||
owner.custom_pain("You feel something rip in your [name]!", 25)
|
||||
|
||||
//Burn damage can cause fluid loss due to blistering and cook-off
|
||||
if((type in list(BURN, LASER)) && (damage > 5 || damage + burn_dam >= 15) && !BP_IS_ROBOTIC(src))
|
||||
var/fluid_loss_severity
|
||||
switch(type)
|
||||
if(BURN) fluid_loss_severity = FLUIDLOSS_WIDE_BURN
|
||||
if(LASER) fluid_loss_severity = FLUIDLOSS_CONC_BURN
|
||||
var/fluid_loss = (damage/(owner.maxHealth - config.health_threshold_dead)) * DEFAULT_BLOOD_AMOUNT * fluid_loss_severity
|
||||
owner.remove_blood_simple(fluid_loss)
|
||||
|
||||
// first check whether we can widen an existing wound
|
||||
if(wounds.len > 0 && prob(max(50+(number_wounds-1)*10,90)))
|
||||
if((type == CUT || type == BRUISE) && damage >= 5)
|
||||
@@ -983,7 +998,7 @@ Note that amputating the affected organ does in fact remove the infection from t
|
||||
W.germ_level = 0
|
||||
return rval
|
||||
|
||||
/obj/item/organ/external/proc/clamp()
|
||||
/obj/item/organ/external/proc/clamp_organ()
|
||||
var/rval = 0
|
||||
src.status &= ~ORGAN_BLEEDING
|
||||
for(var/datum/wound/W in wounds)
|
||||
|
||||
Reference in New Issue
Block a user