mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-23 03:57:13 +01:00
Added a getBruteLoss() proc to mob.dm and then replaced all calls of bruteloss with it. Except for the ones commented out.
git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2505 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
@@ -1,36 +1,18 @@
|
||||
//TODO: Move cyber organs active/inactive stats to vars.
|
||||
|
||||
//flags for organType
|
||||
#define CYBER 1
|
||||
#define SPELL 2
|
||||
|
||||
/obj/effect/organstructure //used obj for the "contents" var
|
||||
/obj/organstructure //used obj for the "contents" var
|
||||
name = "organs"
|
||||
|
||||
var/obj/item/weapon/cell/mainPowerCell = null //for ease of refernce for installed c. implants
|
||||
var/species = "mob" //for speaking in unknown languages purposes
|
||||
|
||||
var/obj/effect/organ/limb/arms/arms = null
|
||||
var/obj/effect/organ/limb/legs/legs = null
|
||||
var/obj/effect/organ/chest/chest = null
|
||||
var/obj/organ/limb/arms/arms = null
|
||||
var/obj/organ/limb/legs/legs = null
|
||||
var/obj/organ/torso/torso = null
|
||||
var/obj/organ/head/head = null
|
||||
|
||||
proc/FindMainPowercell()
|
||||
if(chest) //priority goes to chest implant, if there is one
|
||||
if((chest.organType & CYBER) && chest.canExportPower && chest.cell)
|
||||
mainPowerCell = chest.cell
|
||||
return
|
||||
var/list/organs = GetAllContents()
|
||||
for(var/obj/effect/organ/otherOrgan in organs) //otherwise, maybe some other organ fits the criteria?
|
||||
if((otherOrgan.organType & CYBER) && otherOrgan.canExportPower && otherOrgan.cell)
|
||||
mainPowerCell = otherOrgan:cell
|
||||
return
|
||||
mainPowerCell = null //otherwise, seems there's no main cell
|
||||
return
|
||||
|
||||
proc/GetSpeciesName()
|
||||
var/list/speciesPresent = list()
|
||||
|
||||
for(var/obj/effect/organ/organ in src) //only external organs count, since it's judging by the appearance
|
||||
for(var/obj/organ/organ in src) //only external organs count, since it's judging by the appearance
|
||||
if(speciesPresent[organ.species])
|
||||
speciesPresent[organ.species]++
|
||||
else
|
||||
@@ -52,17 +34,17 @@
|
||||
else
|
||||
species = pick(dominantSpecies)
|
||||
|
||||
return
|
||||
return species
|
||||
|
||||
proc/RecalculateStructure()
|
||||
var/list/organs = GetAllContents()
|
||||
|
||||
arms = locate(/obj/effect/organ/limb/arms) in organs
|
||||
legs = locate(/obj/effect/organ/limb/legs) in organs
|
||||
chest = locate(/obj/effect/organ/chest) in organs
|
||||
arms = locate(/obj/organ/limb/arms) in organs
|
||||
legs = locate(/obj/organ/limb/legs) in organs
|
||||
torso = locate(/obj/organ/torso) in organs
|
||||
head = locate(/obj/organ/head) in organs
|
||||
|
||||
GetSpeciesName()
|
||||
FindMainPowercell()
|
||||
|
||||
return
|
||||
|
||||
@@ -70,7 +52,7 @@
|
||||
set background = 1
|
||||
|
||||
var/list/organs = GetAllContents()
|
||||
for(var/obj/effect/organ/organ in organs)
|
||||
for(var/obj/organ/organ in organs)
|
||||
organ.ProcessOrgan()
|
||||
|
||||
return
|
||||
@@ -79,31 +61,27 @@
|
||||
..()
|
||||
RecalculateStructure()
|
||||
|
||||
/obj/effect/organstructure/human
|
||||
/obj/organstructure/human
|
||||
name = "human organs"
|
||||
|
||||
New()
|
||||
//new /obj/effect/organ/limb/arms/human(src)
|
||||
//new /obj/effect/organ/limb/legs/human(src)
|
||||
new /obj/effect/organ/chest/human(src)
|
||||
new /obj/organ/torso/human(src)
|
||||
..()
|
||||
|
||||
/obj/effect/organstructure/cyber
|
||||
name = "cyborg organs"
|
||||
/obj/organstructure/alien
|
||||
name = "alien organs"
|
||||
|
||||
New()
|
||||
//new /obj/effect/organ/limb/arms/cyber(src)
|
||||
//new /obj/effect/organ/limb/legs/cyber(src)
|
||||
new /obj/effect/organ/chest/cyber(src)
|
||||
new /obj/organ/torso/alien(src)
|
||||
..()
|
||||
|
||||
/obj/effect/organ
|
||||
/obj/organ
|
||||
name = "organ"
|
||||
|
||||
//All types
|
||||
var/organType = 0 //CYBER and SPELL go here
|
||||
var/species = "mob"
|
||||
var/obj/effect/organstructure/rootOrganStructure = null
|
||||
var/obj/organstructure/rootOrganStructure = null
|
||||
|
||||
New(location)
|
||||
..()
|
||||
@@ -111,155 +89,376 @@
|
||||
rootOrganStructure = FindRootStructure()
|
||||
|
||||
proc/FindRootStructure()
|
||||
if(istype(loc,/obj/effect/organ))
|
||||
var/obj/effect/organ/parent = loc
|
||||
if(istype(loc,/obj/organ))
|
||||
var/obj/organ/parent = loc
|
||||
return parent.FindRootStructure()
|
||||
else if(istype(loc,/obj/effect/organstructure))
|
||||
else if(istype(loc,/obj/organstructure))
|
||||
return loc
|
||||
return null
|
||||
|
||||
proc/ProcessOrgan()
|
||||
set background = 1
|
||||
|
||||
if(organType & CYBER)
|
||||
var/hasPower = DrainPower()
|
||||
if(!hasPower && active)
|
||||
Deactivate()
|
||||
else if(hasPower && !active)
|
||||
Activate()
|
||||
|
||||
//CYBORG type
|
||||
var/obj/item/weapon/cell/cell = null
|
||||
var/canExportPower = 0 //only comes in play if it has a cell
|
||||
var/active = 0
|
||||
var/powerDrainPerTick = 0
|
||||
|
||||
proc/DrainPower()
|
||||
set background = 1
|
||||
|
||||
if(!powerDrainPerTick)
|
||||
return 1
|
||||
if(cell)
|
||||
if(cell.charge >= powerDrainPerTick)
|
||||
cell.charge -= powerDrainPerTick
|
||||
return 1
|
||||
if(rootOrganStructure.mainPowerCell)
|
||||
if(rootOrganStructure.mainPowerCell.charge >= powerDrainPerTick)
|
||||
rootOrganStructure.mainPowerCell.charge -= powerDrainPerTick
|
||||
return 1
|
||||
return 0
|
||||
|
||||
proc/Activate() //depends on the organ, involves setting active to 1 and changing the organ's vars to reflect its "activated" state
|
||||
rootOrganStructure.loc << "\blue Your [name] powers up!"
|
||||
active = 1
|
||||
return
|
||||
|
||||
proc/Deactivate() //depends on the organ, involves setting active to 0 and changing the organ's vars to reflect its "deactivated" state
|
||||
rootOrganStructure.loc << "\red Your [name] powers down."
|
||||
active = 0
|
||||
return
|
||||
/obj/organ/torso
|
||||
name = "torso"
|
||||
var/maxHealth = 50 //right now, the mob's (only humans for now) health depends only on it. Will be fixed later
|
||||
var/ear_damage = null//Carbon
|
||||
var/cloneloss = 0//Carbon
|
||||
var/nodamage = 0
|
||||
// flags = NOREACT //uncomment this out later
|
||||
var/viruses = list() // replaces var/datum/disease/virus
|
||||
var/list/resistances = list()
|
||||
var/datum/disease/virus = null
|
||||
var/emote_allowed = 1
|
||||
var/sdisabilities = 0//Carbon
|
||||
var/disabilities = 0//Carbon
|
||||
var/monkeyizing = null//Carbon
|
||||
var/lying = 0.0
|
||||
var/resting = 0.0//Carbon
|
||||
var/sleeping = 0.0//Carbon
|
||||
var/oxyloss = 0.0//Living
|
||||
var/toxloss = 0.0//Living
|
||||
var/fireloss = 0.0//Living
|
||||
var/bruteloss = 0.0//Living
|
||||
var/timeofdeath = 0.0//Living
|
||||
var/rejuv = null
|
||||
var/antitoxs = null
|
||||
var/plasma = null
|
||||
var/cpr_time = 1.0//Carbon
|
||||
var/health = 100//Living
|
||||
var/bodytemperature = 310.055 //98.7 F
|
||||
var/bhunger = 0//Carbon
|
||||
var/nutrition = 400.0//Carbon
|
||||
var/overeatduration = 0 // How long this guy is overeating //Carbon
|
||||
var/paralysis = 0.0
|
||||
var/stunned = 0.0
|
||||
var/weakened = 0.0
|
||||
var/losebreath = 0.0//Carbon
|
||||
|
||||
/obj/effect/organ/limb
|
||||
var/obj/item/weapon/storage/s_active = null//Carbon
|
||||
var/inertia_dir = 0
|
||||
var/datum/dna/dna = null//Carbon
|
||||
var/radiation = 0.0//Carbon
|
||||
var/mutations = 0//Carbon
|
||||
//telekinesis = 1
|
||||
//firemut = 2
|
||||
//xray = 4
|
||||
//hulk = 8
|
||||
//clumsy = 16
|
||||
//obese = 32
|
||||
//husk = 64
|
||||
/*For ninjas and others. This variable is checked when a mob moves and I guess it was supposed to allow the mob to move
|
||||
through dense areas, such as walls. Setting density to 0 does the same thing. The difference here is that
|
||||
the mob is also allowed to move without any sort of restriction. For instance, in space or out of holder objects.*/
|
||||
//0 is off, 1 is normal, 2 is for ninjas.
|
||||
var/incorporeal_move = 0
|
||||
//The last mob/living/carbon to push/drag/grab this mob (mostly used by Metroids friend recognition)
|
||||
var/mob/living/carbon/LAssailant = null
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/obj/organ/torso/human
|
||||
name = "human torso"
|
||||
species = "human"
|
||||
maxHealth = 100
|
||||
var/underwear = 1//Human
|
||||
var/obj/item/weapon/back = null//Human/Monkey
|
||||
var/obj/item/weapon/tank/internal = null//Human/Monkey
|
||||
var/alien_egg_flag = 0//Have you been infected?
|
||||
var/last_special = 0
|
||||
|
||||
New()
|
||||
..()
|
||||
new /obj/organ/limb/arms/human(src)
|
||||
new /obj/organ/limb/legs/human(src)
|
||||
new /obj/organ/head/human(src)
|
||||
/obj/organ/torso/alien
|
||||
name = "alien torso"
|
||||
species = "alien"
|
||||
maxHealth = 100
|
||||
|
||||
New()
|
||||
..()
|
||||
new /obj/organ/limb/arms/alien(src)
|
||||
new /obj/organ/limb/legs/alien(src)
|
||||
new /obj/organ/head/alien(src)
|
||||
|
||||
|
||||
/obj/organ/limb
|
||||
name = "limb"
|
||||
|
||||
/obj/effect/organ/limb/arms
|
||||
/obj/organ/limb/arms
|
||||
name = "arms"
|
||||
|
||||
var/minDamage = 5 //punching damage
|
||||
var/maxDamage = 5
|
||||
|
||||
var/atom/movable/pulling = null
|
||||
var/hand = null
|
||||
var/obj/item/weapon/handcuffs/handcuffed = null//Living
|
||||
var/obj/item/l_hand = null//Living
|
||||
var/obj/item/r_hand = null//Living
|
||||
var/in_throw_mode = 0
|
||||
// var/strangleDelay = 1 //The code is a bit too complicated for that right now
|
||||
|
||||
/obj/effect/organ/limb/arms/human
|
||||
/obj/organ/limb/arms/alien
|
||||
name = "alien arms"
|
||||
species = "alien"
|
||||
minDamage = 5
|
||||
maxDamage = 15
|
||||
|
||||
|
||||
/obj/organ/limb/arms/human
|
||||
name = "human arms"
|
||||
species = "human"
|
||||
minDamage = 1
|
||||
maxDamage = 9
|
||||
|
||||
/obj/effect/organ/limb/arms/cyber
|
||||
name = "cyborg arms"
|
||||
species = "cyborg"
|
||||
organType = CYBER
|
||||
powerDrainPerTick = 5
|
||||
|
||||
Activate()
|
||||
..()
|
||||
minDamage = 3
|
||||
maxDamage = 14
|
||||
|
||||
Deactivate()
|
||||
..()
|
||||
minDamage = 0
|
||||
maxDamage = 3
|
||||
|
||||
|
||||
/obj/effect/organ/limb/legs
|
||||
/obj/organ/limb/legs
|
||||
name = "legs"
|
||||
|
||||
var/moveRunDelay = 1 //not sure about how that works
|
||||
var/moveWalkDelay = 7
|
||||
//var/knockdownResist = 0
|
||||
var/next_move = null
|
||||
var/prev_move = null
|
||||
var/canmove = 1.0
|
||||
var/obj/structure/stool/buckled = null//Living
|
||||
var/footstep = 1
|
||||
|
||||
/obj/effect/organ/limb/legs/human
|
||||
/obj/organ/limb/legs/human
|
||||
name = "human legs"
|
||||
species = "human"
|
||||
|
||||
/obj/effect/organ/limb/legs/cyber
|
||||
name = "cyborg legs"
|
||||
species = "cyborg"
|
||||
organType = CYBER
|
||||
powerDrainPerTick = 5
|
||||
|
||||
Activate()
|
||||
..()
|
||||
moveRunDelay = 0
|
||||
moveWalkDelay = 3
|
||||
|
||||
Deactivate()
|
||||
..()
|
||||
moveRunDelay = 2
|
||||
moveWalkDelay = 10
|
||||
/obj/organ/limb/legs/alien
|
||||
name = "alien legs"
|
||||
species = "alien"
|
||||
|
||||
|
||||
/obj/effect/organ/chest
|
||||
name = "chest"
|
||||
var/maxHealth = 50 //right now, the mob's (only humans for now) health depends only on it. Will be fixed later
|
||||
/obj/organ/head
|
||||
name = "head"
|
||||
|
||||
/obj/effect/organ/chest/human
|
||||
name = "human chest"
|
||||
var/stuttering = null//Carbon
|
||||
var/druggy = 0//Carbon
|
||||
var/confused = 0//Carbon
|
||||
var/drowsyness = 0.0//Carbon
|
||||
var/dizziness = 0//Carbon
|
||||
var/is_dizzy = 0
|
||||
var/is_jittery = 0
|
||||
var/jitteriness = 0//Carbon
|
||||
var/r_epil = 0
|
||||
var/r_ch_cou = 0
|
||||
var/r_Tourette = 0//Carbon
|
||||
var/miming = null //checks if the guy is a mime//Human
|
||||
var/silent = null //Can't talk. Value goes down every life proc.//Human
|
||||
var/voice_name = "unidentifiable voice"
|
||||
var/voice_message = null // When you are not understood by others (replaced with just screeches, hisses, chimpers etc.)
|
||||
var/say_message = null // When you are understood by others. Currently only used by aliens and monkeys in their say_quote procs
|
||||
var/coughedtime = null
|
||||
var/job = null//Living
|
||||
var/const/blindness = 1//Carbon
|
||||
var/const/deafness = 2//Carbon
|
||||
var/const/muteness = 4//Carbon
|
||||
var/brainloss = 0//Carbon
|
||||
var/robot_talk_understand = 0
|
||||
var/alien_talk_understand = 0
|
||||
var/universal_speak = 0 // Set to 1 to enable the mob to speak to everyone -- TLE
|
||||
var/ear_deaf = null//Carbon
|
||||
var/eye_blind = null//Carbon
|
||||
var/eye_blurry = null//Carbon
|
||||
var/eye_stat = null//Living, potentially Carbon
|
||||
var/blinded = null
|
||||
var/shakecamera = 0
|
||||
//Wizard mode, but can be used in other modes thanks to the brand new "Give Spell" badmin button
|
||||
var/obj/proc_holder/spell/list/spell_list = list()
|
||||
|
||||
|
||||
|
||||
/obj/organ/head/human
|
||||
name = "human head"
|
||||
species = "human"
|
||||
var/obj/item/clothing/mask/wear_mask = null//Carbon
|
||||
|
||||
/obj/organ/head/alien
|
||||
name = "alien head"
|
||||
species = "alien"
|
||||
|
||||
/obj/organ/limb/arms/alien
|
||||
name = "alien arms"
|
||||
species = "alien"
|
||||
minDamage = 5
|
||||
maxDamage = 15
|
||||
|
||||
/obj/organ/limb/legs/alien
|
||||
name = "alien legs"
|
||||
species = "alien"
|
||||
|
||||
/obj/organ/head/alien
|
||||
name = "alien head"
|
||||
species = "alien"
|
||||
|
||||
// ++++STUB ORGAN STRUCTURE. THIS IS THE DEFAULT STRUCTURE. USED TO PREVENT EXCEPTIONS++++
|
||||
/obj/organstructure/stub
|
||||
name = "stub organs"
|
||||
|
||||
New()
|
||||
new /obj/organ/torso/stub(src)
|
||||
..()
|
||||
|
||||
/obj/organ/torso/stub
|
||||
name = "stub torso"
|
||||
species = "stub"
|
||||
maxHealth = 100
|
||||
|
||||
New()
|
||||
..()
|
||||
new /obj/effect/organ/limb/arms/human(src)
|
||||
new /obj/effect/organ/limb/legs/human(src)
|
||||
new /obj/organ/limb/arms/stub(src)
|
||||
new /obj/organ/limb/legs/stub(src)
|
||||
new /obj/organ/head/stub(src)
|
||||
|
||||
/obj/effect/organ/chest/cyber
|
||||
name = "cyborg chest"
|
||||
species = "cyborg"
|
||||
organType = CYBER
|
||||
canExportPower = 1
|
||||
maxHealth = 150
|
||||
/obj/organ/limb/arms/stub
|
||||
name = "stub arms"
|
||||
species = "stub"
|
||||
|
||||
/obj/organ/limb/legs/stub
|
||||
name = "stub legs"
|
||||
species = "stub"
|
||||
|
||||
/obj/organ/head/stub
|
||||
name = "stub head"
|
||||
species = "stub"
|
||||
|
||||
// ++++STUB ORGAN STRUCTURE. END++++
|
||||
|
||||
|
||||
// ++++MONKEY++++
|
||||
|
||||
/obj/organstructure/monkey
|
||||
name = "monkey organs"
|
||||
|
||||
New()
|
||||
new /obj/organ/torso/monkey(src)
|
||||
..()
|
||||
|
||||
/obj/organ/torso/monkey
|
||||
name = "monkey torso"
|
||||
species = "monkey"
|
||||
maxHealth = 100
|
||||
|
||||
New()
|
||||
..()
|
||||
cell = new /obj/item/weapon/cell/high(src)
|
||||
cell.charge = cell.maxcharge
|
||||
new /obj/effect/organ/limb/arms/cyber(src)
|
||||
new /obj/effect/organ/limb/legs/cyber(src)
|
||||
new /obj/organ/limb/arms/monkey(src)
|
||||
new /obj/organ/limb/legs/monkey(src)
|
||||
new /obj/organ/head/monkey(src)
|
||||
|
||||
Activate()
|
||||
..()
|
||||
canExportPower = 1
|
||||
maxHealth = 150
|
||||
if(rootOrganStructure.loc && istype(rootOrganStructure.loc,/mob/living))
|
||||
var/mob/living/holder = rootOrganStructure.loc
|
||||
holder.updatehealth()
|
||||
/obj/organ/limb/arms/monkey
|
||||
name = "monkey arms"
|
||||
species = "monkey"
|
||||
|
||||
Deactivate()
|
||||
/obj/organ/limb/legs/monkey
|
||||
name = "monkey legs"
|
||||
species = "monkey"
|
||||
|
||||
/obj/organ/head/monkey
|
||||
name = "monkey head"
|
||||
species = "monkey"
|
||||
|
||||
|
||||
// +++++CYBORG+++++
|
||||
/obj/organstructure/cyborg
|
||||
name = "cyborg organs"
|
||||
|
||||
New()
|
||||
new /obj/organ/torso/cyborg(src)
|
||||
..()
|
||||
canExportPower = 0
|
||||
maxHealth = 120
|
||||
if(rootOrganStructure.loc && istype(rootOrganStructure.loc,/mob/living))
|
||||
var/mob/living/holder = rootOrganStructure.loc
|
||||
holder.updatehealth()
|
||||
|
||||
/obj/organ/torso/cyborg
|
||||
name = "cyborg torso"
|
||||
species = "cyborg"
|
||||
maxHealth = 100
|
||||
|
||||
New()
|
||||
..()
|
||||
new /obj/organ/limb/arms/cyborg(src)
|
||||
new /obj/organ/limb/legs/cyborg(src)
|
||||
new /obj/organ/head/cyborg(src)
|
||||
|
||||
/obj/organ/limb/arms/cyborg
|
||||
name = "cyborg arms"
|
||||
species = "cyborg"
|
||||
|
||||
/obj/organ/limb/legs/cyborg
|
||||
name = "cyborg legs"
|
||||
species = "cyborg"
|
||||
|
||||
/obj/organ/head/cyborg
|
||||
name = "cyborg head"
|
||||
species = "cyborg"
|
||||
|
||||
// +++++AI++++++
|
||||
/obj/organstructure/AI
|
||||
name = "AI organs"
|
||||
|
||||
New()
|
||||
new /obj/organ/torso/AI(src)
|
||||
..()
|
||||
|
||||
/obj/organ/torso/AI
|
||||
name = "AI torso"
|
||||
species = "AI"
|
||||
maxHealth = 100
|
||||
|
||||
New()
|
||||
..()
|
||||
new /obj/organ/limb/arms/AI(src)
|
||||
new /obj/organ/limb/legs/AI(src)
|
||||
new /obj/organ/head/AI(src)
|
||||
|
||||
/obj/organ/limb/arms/AI
|
||||
name = "AI arms"
|
||||
species = "AI"
|
||||
|
||||
/obj/organ/limb/legs/AI
|
||||
name = "AI legs"
|
||||
species = "AI"
|
||||
|
||||
/obj/organ/head/AI
|
||||
name = "AI head"
|
||||
species = "AI"
|
||||
|
||||
/* New organ structure template
|
||||
|
||||
|
||||
/obj/organstructure/template
|
||||
name = "template organs"
|
||||
|
||||
New()
|
||||
new /obj/organ/torso/template(src)
|
||||
..()
|
||||
|
||||
/obj/organ/torso/template
|
||||
name = "template torso"
|
||||
species = "template"
|
||||
maxHealth = 100
|
||||
|
||||
New()
|
||||
..()
|
||||
new /obj/organ/limb/arms/template(src)
|
||||
new /obj/organ/limb/legs/template(src)
|
||||
new /obj/organ/head/template(src)
|
||||
|
||||
/obj/organ/limb/arms/template
|
||||
name = "template arms"
|
||||
species = "template"
|
||||
|
||||
/obj/organ/limb/legs/template
|
||||
name = "template legs"
|
||||
species = "template"
|
||||
|
||||
/obj/organ/head/template
|
||||
name = "template head"
|
||||
species = "template"
|
||||
|
||||
*/
|
||||
@@ -288,7 +288,7 @@
|
||||
mob.suiciding = 1
|
||||
//instead of killing them instantly, just put them at -175 health and let 'em gasp for a while
|
||||
viewers(mob) << "\red <b>[mob.name] is attempting to bite off \his tongue. It looks like \he's trying to commit suicide.</b>"
|
||||
mob.oxyloss = max(175 - mob.toxloss - mob.fireloss - mob.bruteloss, mob.oxyloss)
|
||||
mob.oxyloss = max(175 - mob.toxloss - mob.fireloss - mob.getBruteLoss(), mob.oxyloss)
|
||||
mob.updatehealth()
|
||||
spawn(200) //in case they get revived by cryo chamber or something stupid like that, let them suicide again in 20 seconds
|
||||
mob.suiciding = 0
|
||||
|
||||
+88
-3
@@ -5,7 +5,18 @@
|
||||
flags = NOREACT
|
||||
var/datum/mind/mind
|
||||
|
||||
var/uses_hud = 0
|
||||
|
||||
|
||||
|
||||
//MOB overhaul
|
||||
var/obj/organstructure/organStructure = null
|
||||
|
||||
//Vars that have been relocated.
|
||||
|
||||
// var/uses_hud = 0
|
||||
var/bruteloss = 0.0//Living
|
||||
|
||||
|
||||
var/obj/screen/flash = null
|
||||
var/obj/screen/blind = null
|
||||
var/obj/screen/hands = null
|
||||
@@ -79,7 +90,7 @@
|
||||
var/oxyloss = 0.0//Living
|
||||
var/toxloss = 0.0//Living
|
||||
var/fireloss = 0.0//Living
|
||||
var/bruteloss = 0.0//Living
|
||||
|
||||
var/timeofdeath = 0.0//Living
|
||||
var/cpr_time = 1.0//Carbon
|
||||
var/health = 100//Living
|
||||
@@ -411,4 +422,78 @@ the mob is also allowed to move without any sort of restriction. For instance, i
|
||||
if(prob(5))
|
||||
v.carrier = 1
|
||||
return
|
||||
return
|
||||
return
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
// ++++ROCKDTBEN++++ MOB PROCS
|
||||
|
||||
|
||||
|
||||
/mob/proc/getBruteLoss()
|
||||
return bruteloss
|
||||
|
||||
// Standard for setting hasn't been agreed upon yet.
|
||||
|
||||
/*
|
||||
|
||||
/mob/proc/setBruteLoss(var/T)
|
||||
bruteloss = T
|
||||
|
||||
/mob/proc/setOxyLoss(var/T)
|
||||
oxyloss = T
|
||||
|
||||
/mob/proc/getOxyLoss()
|
||||
return oxyloss
|
||||
|
||||
/mob/proc/setToxLoss(var/T)
|
||||
toxloss = T
|
||||
|
||||
/mob/proc/getToxLoss()
|
||||
return toxloss
|
||||
|
||||
/mob/proc/setFireLoss(var/T)
|
||||
fireloss = T
|
||||
|
||||
/mob/proc/getFireLoss()
|
||||
return fireloss
|
||||
|
||||
/mob/proc/setCloneLoss(var/T)
|
||||
cloneloss = T
|
||||
|
||||
/mob/proc/getCloneLoss()
|
||||
return cloneloss
|
||||
|
||||
*/
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -176,6 +176,18 @@
|
||||
else
|
||||
..()
|
||||
|
||||
|
||||
/mob/living/simple_animal/corgi/attack_animal(var/mob/M)
|
||||
health = health - 8
|
||||
if(health > 0)
|
||||
for(var/mob/O in viewers(src, null))
|
||||
if ((O.client && !( O.blinded )))
|
||||
O.show_message(text("\red <B>[] has bitten []!</B>", M, src), 1)
|
||||
else
|
||||
for(var/mob/O in viewers(src, null))
|
||||
if ((O.client && !( O.blinded )))
|
||||
O.show_message(text("\red <B>[] is gnawing on []'s bones!</B>", M, src), 1)
|
||||
|
||||
//IAN! SQUEEEEEEEEE~
|
||||
/mob/living/simple_animal/corgi/Ian
|
||||
name = "Ian"
|
||||
@@ -190,6 +202,78 @@
|
||||
/mob/living/simple_animal/corgi/Ian/Life()
|
||||
..()
|
||||
|
||||
//Feeding, chasing food, FOOOOODDDD
|
||||
if(alive && !resting && !buckled)
|
||||
turns_since_scan++
|
||||
if(turns_since_scan > 5)
|
||||
turns_since_scan = 0
|
||||
if((movement_target) && !(isturf(movement_target.loc) || ishuman(movement_target.loc) ))
|
||||
movement_target = null
|
||||
stop_automated_movement = 0
|
||||
if( !movement_target || !(movement_target.loc in oview(src, 5)) )
|
||||
movement_target = null
|
||||
stop_automated_movement = 0
|
||||
for(var/obj/item/weapon/reagent_containers/food/snacks/S in oview(src,5))
|
||||
if(isturf(S.loc) || ishuman(S.loc))
|
||||
movement_target = S
|
||||
break
|
||||
if(movement_target)
|
||||
stop_automated_movement = 1
|
||||
step_to(src,movement_target,1)
|
||||
sleep(3)
|
||||
step_to(src,movement_target,1)
|
||||
sleep(3)
|
||||
step_to(src,movement_target,1)
|
||||
|
||||
if(movement_target) //Not redundant due to sleeps, Item can be gone in 6 decisecomds
|
||||
if (movement_target.loc.x < src.x)
|
||||
dir = WEST
|
||||
else if (movement_target.loc.x > src.x)
|
||||
dir = EAST
|
||||
else if (movement_target.loc.y < src.y)
|
||||
dir = SOUTH
|
||||
else if (movement_target.loc.y > src.y)
|
||||
dir = NORTH
|
||||
else
|
||||
dir = SOUTH
|
||||
|
||||
if(isturf(movement_target.loc) )
|
||||
movement_target.attack_animal(src)
|
||||
else if(ishuman(movement_target.loc) )
|
||||
if(prob(20))
|
||||
emote("stares at the [movement_target] that [movement_target.loc] has with an angry dog-face")
|
||||
|
||||
if(prob(1))
|
||||
emote("dances around")
|
||||
spawn(0)
|
||||
for(var/i in list(1,2,4,8,4,2,1,2,4,8,4,2,1,2,4,8,4,2))
|
||||
dir = i
|
||||
sleep(1)
|
||||
|
||||
/mob/living/simple_animal/corgi/AdmiralPoof
|
||||
name = "Poof"
|
||||
real_name = "Poof" //Intended to hold the name without altering it.
|
||||
desc = "It's Poof, what else do you need to know?"
|
||||
var/turns_since_scan = 0
|
||||
var/obj/movement_target
|
||||
response_help = "pets"
|
||||
response_disarm = "gently pushes aside"
|
||||
response_harm = "kicks"
|
||||
icon_state = "poof"
|
||||
icon_living = "poof"
|
||||
icon_dead = "poof_dead"
|
||||
speak = list("YAP","Woof!","Bark!","AUUUUUU")
|
||||
speak_emote = list("barks", "woofs", "growls")
|
||||
emote_hear = list("barks","woofs","yaps")
|
||||
emote_see = list("shakes it's head", "shivers")
|
||||
speak_chance = 1
|
||||
turns_per_move = 5
|
||||
meat_type = /obj/item/weapon/reagent_containers/food/snacks/meat/corgi/poof
|
||||
meat_amount = 2
|
||||
|
||||
/mob/living/simple_animal/corgi/AdmiralPoof/Life()
|
||||
..()
|
||||
|
||||
//Feeding, chasing food, FOOOOODDDD
|
||||
if(alive && !resting && !buckled)
|
||||
turns_since_scan++
|
||||
@@ -201,9 +285,9 @@
|
||||
if( !movement_target || !(movement_target.loc in oview(src, 3)) )
|
||||
movement_target = null
|
||||
stop_automated_movement = 0
|
||||
for(var/obj/item/weapon/reagent_containers/food/snacks/S in oview(src,3))
|
||||
if(isturf(S.loc) || ishuman(S.loc))
|
||||
movement_target = S
|
||||
for(var/mob/living/simple_animal/corgi/Ian/I in oview(src,3))
|
||||
if(isturf(I.loc) || ishuman(I.loc))
|
||||
movement_target = I
|
||||
break
|
||||
if(movement_target)
|
||||
stop_automated_movement = 1
|
||||
@@ -232,7 +316,7 @@
|
||||
emote("stares at the [movement_target] that [movement_target.loc] has with a sad puppy-face")
|
||||
|
||||
if(prob(1))
|
||||
emote("dances around")
|
||||
emote("dances around authoritatively")
|
||||
spawn(0)
|
||||
for(var/i in list(1,2,4,8,4,2,1,2,4,8,4,2,1,2,4,8,4,2))
|
||||
dir = i
|
||||
@@ -240,4 +324,7 @@
|
||||
|
||||
/obj/item/weapon/reagent_containers/food/snacks/meat/corgi
|
||||
name = "Corgi meat"
|
||||
desc = "Tastes like... well you know..."
|
||||
/obj/item/weapon/reagent_containers/food/snacks/meat/corgi/poof
|
||||
name = "Dachshund meat"
|
||||
desc = "Tastes like... well you know..."
|
||||
@@ -139,13 +139,13 @@ proc/sql_report_death(var/mob/living/carbon/human/H)
|
||||
lakey = dd_replacetext(H.lastattacker:key, "'", "''")
|
||||
var/sqltime = time2text(world.realtime, "YYYY-MM-DD hh:mm:ss")
|
||||
var/coord = "[H.x], [H.y], [H.z]"
|
||||
//world << "INSERT INTO death (name, byondkey, job, special, pod, tod, laname, lakey, gender, bruteloss, fireloss, brainloss, oxyloss) VALUES ('[sqlname]', '[sqlkey]', '[sqljob]', '[sqlspecial]', '[sqlpod]', '[sqltime]', '[laname]', '[lakey]', '[H.gender]', [H.bruteloss], [H.fireloss], [H.brainloss], [H.oxyloss])"
|
||||
//world << "INSERT INTO death (name, byondkey, job, special, pod, tod, laname, lakey, gender, getBruteLoss(), fireloss, brainloss, oxyloss) VALUES ('[sqlname]', '[sqlkey]', '[sqljob]', '[sqlspecial]', '[sqlpod]', '[sqltime]', '[laname]', '[lakey]', '[H.gender]', [H.bruteloss], [H.fireloss], [H.brainloss], [H.oxyloss])"
|
||||
var/DBConnection/dbcon = new()
|
||||
dbcon.Connect("dbi:mysql:[sqldb]:[sqladdress]:[sqlport]","[sqllogin]","[sqlpass]")
|
||||
if(!dbcon.IsConnected())
|
||||
log_game("SQL ERROR during death reporting. Failed to connect.")
|
||||
else
|
||||
var/DBQuery/query = dbcon.NewQuery("INSERT INTO death (name, byondkey, job, special, pod, tod, laname, lakey, gender, bruteloss, fireloss, brainloss, oxyloss, coord) VALUES ('[sqlname]', '[sqlkey]', '[sqljob]', '[sqlspecial]', '[sqlpod]', '[sqltime]', '[laname]', '[lakey]', '[H.gender]', [H.bruteloss], [H.fireloss], [H.brainloss], [H.oxyloss], '[coord]')")
|
||||
var/DBQuery/query = dbcon.NewQuery("INSERT INTO death (name, byondkey, job, special, pod, tod, laname, lakey, gender, bruteloss, fireloss, brainloss, oxyloss, coord) VALUES ('[sqlname]', '[sqlkey]', '[sqljob]', '[sqlspecial]', '[sqlpod]', '[sqltime]', '[laname]', '[lakey]', '[H.gender]', [H.getBruteLoss()], [H.fireloss], [H.brainloss], [H.oxyloss], '[coord]')")
|
||||
if(!query.Execute())
|
||||
var/err = query.ErrorMsg()
|
||||
log_game("SQL ERROR during death reporting. Error : \[[err]\]\n")
|
||||
@@ -182,7 +182,7 @@ proc/sql_report_cyborg_death(var/mob/living/silicon/robot/H)
|
||||
if(!dbcon.IsConnected())
|
||||
log_game("SQL ERROR during death reporting. Failed to connect.")
|
||||
else
|
||||
var/DBQuery/query = dbcon.NewQuery("INSERT INTO death (name, byondkey, job, special, pod, tod, laname, lakey, gender, bruteloss, fireloss, brainloss, oxyloss, coord) VALUES ('[sqlname]', '[sqlkey]', '[sqljob]', '[sqlspecial]', '[sqlpod]', '[sqltime]', '[laname]', '[lakey]', '[H.gender]', [H.bruteloss], [H.fireloss], [H.brainloss], [H.oxyloss], '[coord]')")
|
||||
var/DBQuery/query = dbcon.NewQuery("INSERT INTO death (name, byondkey, job, special, pod, tod, laname, lakey, gender, bruteloss, fireloss, brainloss, oxyloss, coord) VALUES ('[sqlname]', '[sqlkey]', '[sqljob]', '[sqlspecial]', '[sqlpod]', '[sqltime]', '[laname]', '[lakey]', '[H.gender]', [H.getBruteLoss()], [H.fireloss], [H.brainloss], [H.oxyloss], '[coord]')")
|
||||
if(!query.Execute())
|
||||
var/err = query.ErrorMsg()
|
||||
log_game("SQL ERROR during death reporting. Error : \[[err]\]\n")
|
||||
|
||||
+2
-2
@@ -391,7 +391,7 @@
|
||||
C.occupant = O
|
||||
connected = null
|
||||
O.name = text("monkey ([])",copytext(md5(M.real_name), 2, 6))
|
||||
O.take_overall_damage(M.bruteloss + 40, M.fireloss)
|
||||
O.take_overall_damage(M.getBruteLoss() + 40, M.fireloss)
|
||||
O.toxloss += (M.toxloss + 20)
|
||||
O.oxyloss += M.oxyloss
|
||||
O.stat = M.stat
|
||||
@@ -466,7 +466,7 @@
|
||||
O.real_name = randomname
|
||||
i++
|
||||
updateappearance(O,O.dna.uni_identity)
|
||||
O.take_overall_damage(M.bruteloss, M.fireloss)
|
||||
O.take_overall_damage(M.getBruteLoss(), M.fireloss)
|
||||
O.toxloss += M.toxloss
|
||||
O.oxyloss += M.oxyloss
|
||||
O.stat = M.stat
|
||||
|
||||
@@ -233,7 +233,7 @@
|
||||
|
||||
O.name = text("monkey ([])",copytext(md5(usr.real_name), 2, 6))
|
||||
O.toxloss = usr.toxloss
|
||||
O.bruteloss = usr.bruteloss
|
||||
O.bruteloss = usr.getBruteLoss()
|
||||
O.oxyloss = usr.oxyloss
|
||||
O.fireloss = usr.fireloss
|
||||
O.stat = usr.stat
|
||||
@@ -328,7 +328,7 @@
|
||||
updateappearance(O,O.dna.uni_identity)
|
||||
domutcheck(O, null)
|
||||
O.toxloss = usr.toxloss
|
||||
O.bruteloss = usr.bruteloss
|
||||
O.bruteloss = usr.getBruteLoss()
|
||||
O.oxyloss = usr.oxyloss
|
||||
O.fireloss = usr.fireloss
|
||||
O.stat = usr.stat
|
||||
|
||||
@@ -290,7 +290,7 @@ ________________________________________________________________________________
|
||||
dat += "Oxygen loss: [U.oxyloss]"
|
||||
dat += " | Toxin levels: [U.toxloss]<br>"
|
||||
dat += "Burn severity: [U.fireloss]"
|
||||
dat += " | Brute trauma: [U.bruteloss]<br>"
|
||||
dat += " | Brute trauma: [U.getBruteLoss()]<br>"
|
||||
dat += "Radiation Level: [U.radiation] rad<br>"
|
||||
dat += "Body Temperature: [U.bodytemperature-T0C]°C ([U.bodytemperature*1.8-459.67]°F)<br>"
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@
|
||||
t1 = "<font color='red'>*dead*</font>"
|
||||
else
|
||||
dat += text("[]\tHealth %: [] ([])</FONT><BR>", (occupant.health > 50 ? "<font color='blue'>" : "<font color='red'>"), occupant.health, t1)
|
||||
dat += text("[]\t-Brute Damage %: []</FONT><BR>", (occupant.bruteloss < 60 ? "<font color='blue'>" : "<font color='red'>"), occupant.bruteloss)
|
||||
dat += text("[]\t-Brute Damage %: []</FONT><BR>", (occupant.getBruteLoss() < 60 ? "<font color='blue'>" : "<font color='red'>"), occupant.getBruteLoss())
|
||||
dat += text("[]\t-Respiratory Damage %: []</FONT><BR>", (occupant.oxyloss < 60 ? "<font color='blue'>" : "<font color='red'>"), occupant.oxyloss)
|
||||
dat += text("[]\t-Toxin Content %: []</FONT><BR>", (occupant.toxloss < 60 ? "<font color='blue'>" : "<font color='red'>"), occupant.toxloss)
|
||||
dat += text("[]\t-Burn Severity %: []</FONT><BR>", (occupant.fireloss < 60 ? "<font color='blue'>" : "<font color='red'>"), occupant.fireloss)
|
||||
@@ -331,7 +331,7 @@
|
||||
else
|
||||
user << text("[]\t Health %: [] ([])", (src.occupant.health > 50 ? "\blue " : "\red "), src.occupant.health, t1)
|
||||
user << text("[]\t -Core Temperature: []°C ([]°F)</FONT><BR>", (src.occupant.bodytemperature > 50 ? "<font color='blue'>" : "<font color='red'>"), src.occupant.bodytemperature-T0C, src.occupant.bodytemperature*1.8-459.67)
|
||||
user << text("[]\t -Brute Damage %: []", (src.occupant.bruteloss < 60 ? "\blue " : "\red "), src.occupant.bruteloss)
|
||||
user << text("[]\t -Brute Damage %: []", (src.occupant.getBruteLoss() < 60 ? "\blue " : "\red "), src.occupant.getBruteLoss())
|
||||
user << text("[]\t -Respiratory Damage %: []", (src.occupant.oxyloss < 60 ? "\blue " : "\red "), src.occupant.oxyloss)
|
||||
user << text("[]\t -Toxin Content %: []", (src.occupant.toxloss < 60 ? "\blue " : "\red "), src.occupant.toxloss)
|
||||
user << text("[]\t -Burn Severity %: []", (src.occupant.fireloss < 60 ? "\blue " : "\red "), src.occupant.fireloss)
|
||||
|
||||
@@ -326,14 +326,14 @@
|
||||
return 1
|
||||
|
||||
//If they're injured, we're using a beaker, and don't have one of our WONDERCHEMS.
|
||||
if((src.reagent_glass) && (src.use_beaker) && ((C.bruteloss >= heal_threshold) || (C.toxloss >= heal_threshold) || (C.toxloss >= heal_threshold) || (C.oxyloss >= (heal_threshold + 15))))
|
||||
if((src.reagent_glass) && (src.use_beaker) && ((C.getBruteLoss() >= heal_threshold) || (C.toxloss >= heal_threshold) || (C.toxloss >= heal_threshold) || (C.oxyloss >= (heal_threshold + 15))))
|
||||
for(var/datum/reagent/R in src.reagent_glass.reagents.reagent_list)
|
||||
if(!C.reagents.has_reagent(R))
|
||||
return 1
|
||||
continue
|
||||
|
||||
//They're injured enough for it!
|
||||
if((C.bruteloss >= heal_threshold) && (!C.reagents.has_reagent(src.treatment_brute)))
|
||||
if((C.getBruteLoss() >= heal_threshold) && (!C.reagents.has_reagent(src.treatment_brute)))
|
||||
return 1 //If they're already medicated don't bother!
|
||||
|
||||
if((C.oxyloss >= (15 + heal_threshold)) && (!C.reagents.has_reagent(src.treatment_oxy)))
|
||||
@@ -391,7 +391,7 @@
|
||||
if(!C.reagents.has_reagent(src.treatment_virus))
|
||||
reagent_id = src.treatment_virus
|
||||
|
||||
if (!reagent_id && (C.bruteloss >= heal_threshold))
|
||||
if (!reagent_id && (C.getBruteLoss() >= heal_threshold))
|
||||
if(!C.reagents.has_reagent(src.treatment_brute))
|
||||
reagent_id = src.treatment_brute
|
||||
|
||||
|
||||
@@ -415,7 +415,7 @@
|
||||
if (!src.implanted)
|
||||
return "ERROR"
|
||||
else
|
||||
src.healthstring = "[round(src.implanted:oxyloss)] - [round(src.implanted:fireloss)] - [round(src.implanted:toxloss)] - [round(src.implanted:bruteloss)]"
|
||||
src.healthstring = "[round(src.implanted:oxyloss)] - [round(src.implanted:fireloss)] - [round(src.implanted:toxloss)] - [round(src.implanted:getBruteLoss())]"
|
||||
if (!src.healthstring)
|
||||
src.healthstring = "ERROR"
|
||||
return src.healthstring
|
||||
@@ -457,7 +457,7 @@
|
||||
src.occupant.paralysis += 4
|
||||
|
||||
//Here let's calculate their health so the pod doesn't immediately eject them!!!
|
||||
src.occupant.health = (src.occupant.bruteloss + src.occupant.toxloss + src.occupant.oxyloss + src.occupant.cloneloss)
|
||||
src.occupant.health = (src.occupant.getBruteLoss() + src.occupant.toxloss + src.occupant.oxyloss + src.occupant.cloneloss)
|
||||
|
||||
src.occupant << "\blue <b>Clone generation process initiated.</b>"
|
||||
src.occupant << "\blue This will take a moment, please hold."
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
<B>Blood Type:</B> [src.victim.b_type]<BR>
|
||||
<BR>
|
||||
<B>Health:</B> [src.victim.health]<BR>
|
||||
<B>Brute Damage:</B> [src.victim.bruteloss]<BR>
|
||||
<B>Brute Damage:</B> [src.victim.getBruteLoss()]<BR>
|
||||
<B>Toxins Damage:</B> [src.victim.toxloss]<BR>
|
||||
<B>Fire Damage:</B> [src.victim.fireloss]<BR>
|
||||
<B>Suffocation Damage:</B> [src.victim.oxyloss]<BR>
|
||||
|
||||
@@ -125,7 +125,7 @@
|
||||
src.occupant.oxyloss = max (src.occupant.oxyloss-1, 0)
|
||||
src.occupant.fireloss = max (src.occupant.fireloss-1, 0)
|
||||
src.occupant.toxloss = max (src.occupant.toxloss-1, 0)
|
||||
src.occupant.bruteloss = max (src.occupant.bruteloss-1, 0)
|
||||
src.occupant.bruteloss = max (src.occupant.getBruteLoss()-1, 0)
|
||||
src.occupant.updatehealth()
|
||||
if (src.occupant.health >= 0 && src.occupant.stat == 2)
|
||||
src.occupant.stat = 0
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
var/dam1 = round(H.oxyloss,1)
|
||||
var/dam2 = round(H.toxloss,1)
|
||||
var/dam3 = round(H.fireloss,1)
|
||||
var/dam4 = round(H.bruteloss,1)
|
||||
var/dam4 = round(H.getBruteLoss(),1)
|
||||
switch(C.sensor_mode)
|
||||
if(1)
|
||||
if(H.wear_id)
|
||||
|
||||
@@ -90,7 +90,7 @@
|
||||
<B>Current cell temperature:</B> [temp_text]K<BR>
|
||||
<B>Cryo status:</B> [ src.on ? "<A href='?src=\ref[src];start=1'>Off</A> <B>On</B>" : "<B>Off</B> <A href='?src=\ref[src];start=1'>On</A>"]<BR>
|
||||
[beaker_text]<BR><BR>
|
||||
<B>Current occupant:</B> [src.occupant ? "<BR>Name: [src.occupant]<BR>Health: [health_text]<BR>Oxygen deprivation: [round(src.occupant.oxyloss,0.1)]<BR>Brute damage: [round(src.occupant.bruteloss,0.1)]<BR>Fire damage: [round(src.occupant.fireloss,0.1)]<BR>Toxin damage: [round(src.occupant.toxloss,0.1)]<BR>Body temperature: [src.occupant.bodytemperature]" : "<FONT color=red>None</FONT>"]<BR>
|
||||
<B>Current occupant:</B> [src.occupant ? "<BR>Name: [src.occupant]<BR>Health: [health_text]<BR>Oxygen deprivation: [round(src.occupant.oxyloss,0.1)]<BR>Brute damage: [round(src.occupant.getBruteLoss(),0.1)]<BR>Fire damage: [round(src.occupant.fireloss,0.1)]<BR>Toxin damage: [round(src.occupant.toxloss,0.1)]<BR>Body temperature: [src.occupant.bodytemperature]" : "<FONT color=red>None</FONT>"]<BR>
|
||||
|
||||
"}
|
||||
user.machine = src
|
||||
@@ -175,7 +175,7 @@
|
||||
if(occupant.bodytemperature < 225)
|
||||
if (occupant.toxloss)
|
||||
occupant.toxloss = max(0, occupant.toxloss - min(1, 20/occupant.toxloss))
|
||||
var/heal_brute = occupant.bruteloss ? min(1, 20/occupant.bruteloss) : 0
|
||||
var/heal_brute = occupant.getBruteLoss() ? min(1, 20/occupant.getBruteLoss()) : 0
|
||||
var/heal_fire = occupant.fireloss ? min(1, 20/occupant.fireloss) : 0
|
||||
occupant.heal_organ_damage(heal_brute,heal_fire)
|
||||
if(beaker && (next_trans == 0))
|
||||
|
||||
@@ -1296,7 +1296,7 @@
|
||||
O.stat = AI.stat
|
||||
O.oxyloss = AI.oxyloss
|
||||
O.fireloss = AI.fireloss
|
||||
O.bruteloss = AI.bruteloss
|
||||
O.bruteloss = AI.getBruteLoss()
|
||||
O.toxloss = AI.toxloss
|
||||
O.updatehealth()
|
||||
src.occupant = O
|
||||
@@ -1314,7 +1314,7 @@
|
||||
AI.laws = O.laws
|
||||
AI.oxyloss = O.oxyloss
|
||||
AI.fireloss = O.fireloss
|
||||
AI.bruteloss = O.bruteloss
|
||||
AI.bruteloss = O.getBruteLoss()
|
||||
AI.toxloss = O.toxloss
|
||||
AI.updatehealth()
|
||||
del(O)
|
||||
|
||||
@@ -721,7 +721,7 @@
|
||||
|
||||
user.show_message("\blue Analyzing Results for [C]:")
|
||||
user.show_message("\blue \t Overall Status: [C.stat > 1 ? "dead" : "[C.health]% healthy"]", 1)
|
||||
user.show_message("\blue \t Damage Specifics: [C.oxyloss > 50 ? "\red" : "\blue"][C.oxyloss]-[C.toxloss > 50 ? "\red" : "\blue"][C.toxloss]-[C.fireloss > 50 ? "\red" : "\blue"][C.fireloss]-[C.bruteloss > 50 ? "\red" : "\blue"][C.bruteloss]", 1)
|
||||
user.show_message("\blue \t Damage Specifics: [C.oxyloss > 50 ? "\red" : "\blue"][C.oxyloss]-[C.toxloss > 50 ? "\red" : "\blue"][C.toxloss]-[C.fireloss > 50 ? "\red" : "\blue"][C.fireloss]-[C.getBruteLoss() > 50 ? "\red" : "\blue"][C.getBruteLoss()]", 1)
|
||||
user.show_message("\blue \t Key: Suffocation/Toxin/Burns/Brute", 1)
|
||||
user.show_message("\blue \t Body Temperature: [C.bodytemperature-T0C]°C ([C.bodytemperature*1.8-459.67]°F)", 1)
|
||||
for(var/datum/disease/D in C.viruses)
|
||||
|
||||
@@ -195,19 +195,19 @@ MASS SPECTROMETER
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("\red [] has analyzed []'s vitals!", user, M), 1)
|
||||
//Foreach goto(67)
|
||||
var/fake_oxy = max(rand(1,40), M.oxyloss, (300 - (M.toxloss + M.fireloss + M.bruteloss)))
|
||||
var/fake_oxy = max(rand(1,40), M.oxyloss, (300 - (M.toxloss + M.fireloss + M.getBruteLoss())))
|
||||
if((M.reagents && M.reagents.has_reagent("zombiepowder")) || (M.changeling && M.changeling.changeling_fakedeath))
|
||||
user.show_message(text("\blue Analyzing Results for []:\n\t Overall Status: []", M, "dead"), 1)
|
||||
user.show_message(text("\blue \t Damage Specifics: []-[]-[]-[]", fake_oxy < 50 ? "\red [fake_oxy]" : fake_oxy , M.toxloss > 50 ? "\red [M.toxloss]" : M.toxloss, M.fireloss > 50 ? "\red[M.fireloss]" : M.fireloss, M.bruteloss > 50 ? "\red[M.bruteloss]" : M.bruteloss), 1)
|
||||
user.show_message(text("\blue \t Damage Specifics: []-[]-[]-[]", fake_oxy < 50 ? "\red [fake_oxy]" : fake_oxy , M.toxloss > 50 ? "\red [M.toxloss]" : M.toxloss, M.fireloss > 50 ? "\red[M.fireloss]" : M.fireloss, M.getBruteLoss() > 50 ? "\red[M.getBruteLoss()]" : M.getBruteLoss()), 1)
|
||||
else
|
||||
user.show_message(text("\blue Analyzing Results for []:\n\t Overall Status: []", M, (M.stat > 1 ? "dead" : text("[]% healthy", M.health))), 1)
|
||||
user.show_message(text("\blue \t Damage Specifics: []-[]-[]-[]", M.oxyloss > 50 ? "\red [M.oxyloss]" : M.oxyloss, M.toxloss > 50 ? "\red [M.toxloss]" : M.toxloss, M.fireloss > 50 ? "\red[M.fireloss]" : M.fireloss, M.bruteloss > 50 ? "\red[M.bruteloss]" : M.bruteloss), 1)
|
||||
user.show_message(text("\blue \t Damage Specifics: []-[]-[]-[]", M.oxyloss > 50 ? "\red [M.oxyloss]" : M.oxyloss, M.toxloss > 50 ? "\red [M.toxloss]" : M.toxloss, M.fireloss > 50 ? "\red[M.fireloss]" : M.fireloss, M.getBruteLoss() > 50 ? "\red[M.getBruteLoss()]" : M.getBruteLoss()), 1)
|
||||
user.show_message("\blue Key: Suffocation/Toxin/Burns/Brute", 1)
|
||||
user.show_message("\blue Body Temperature: [M.bodytemperature-T0C]°C ([M.bodytemperature*1.8-459.67]°F)", 1)
|
||||
if((M.changeling && M.changeling.changeling_fakedeath) || (M.reagents && M.reagents.has_reagent("zombiepowder")))
|
||||
user.show_message(text("\blue [] | [] | [] | []", fake_oxy > 50 ? "\red Severe oxygen deprivation detected\blue" : "Subject bloodstream oxygen level normal", M.toxloss > 50 ? "\red Dangerous amount of toxins detected\blue" : "Subject bloodstream toxin level minimal", M.fireloss > 50 ? "\red Severe burn damage detected\blue" : "Subject burn injury status O.K", M.bruteloss > 50 ? "\red Severe anatomical damage detected\blue" : "Subject brute-force injury status O.K"), 1)
|
||||
user.show_message(text("\blue [] | [] | [] | []", fake_oxy > 50 ? "\red Severe oxygen deprivation detected\blue" : "Subject bloodstream oxygen level normal", M.toxloss > 50 ? "\red Dangerous amount of toxins detected\blue" : "Subject bloodstream toxin level minimal", M.fireloss > 50 ? "\red Severe burn damage detected\blue" : "Subject burn injury status O.K", M.getBruteLoss() > 50 ? "\red Severe anatomical damage detected\blue" : "Subject brute-force injury status O.K"), 1)
|
||||
else
|
||||
user.show_message(text("\blue [] | [] | [] | []", M.oxyloss > 50 ? "\red Severe oxygen deprivation detected\blue" : "Subject bloodstream oxygen level normal", M.toxloss > 50 ? "\red Dangerous amount of toxins detected\blue" : "Subject bloodstream toxin level minimal", M.fireloss > 50 ? "\red Severe burn damage detected\blue" : "Subject burn injury status O.K", M.bruteloss > 50 ? "\red Severe anatomical damage detected\blue" : "Subject brute-force injury status O.K"), 1)
|
||||
user.show_message(text("\blue [] | [] | [] | []", M.oxyloss > 50 ? "\red Severe oxygen deprivation detected\blue" : "Subject bloodstream oxygen level normal", M.toxloss > 50 ? "\red Dangerous amount of toxins detected\blue" : "Subject bloodstream toxin level minimal", M.fireloss > 50 ? "\red Severe burn damage detected\blue" : "Subject burn injury status O.K", M.getBruteLoss() > 50 ? "\red Severe anatomical damage detected\blue" : "Subject brute-force injury status O.K"), 1)
|
||||
if (M.cloneloss)
|
||||
user.show_message(text("\red Subject appears to have been imperfectly cloned."), 1)
|
||||
for(var/datum/disease/D in M.viruses)
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
suiciding = 1
|
||||
//instead of killing them instantly, just put them at -175 health and let 'em gasp for a while
|
||||
viewers(src) << "\red <b>[src] is attempting to bite \his tongue. It looks like \he's trying to commit suicide.</b>"
|
||||
oxyloss = max(175 - toxloss - fireloss - bruteloss, oxyloss)
|
||||
oxyloss = max(175 - toxloss - fireloss - getBruteLoss(), oxyloss)
|
||||
updatehealth()
|
||||
|
||||
/mob/living/carbon/brain/verb/suicide()
|
||||
@@ -48,7 +48,7 @@
|
||||
if(confirm == "Yes")
|
||||
suiciding = 1
|
||||
viewers(loc) << "\red <b>[src]'s brain is growing dull and lifeless. It looks like it's trying to commit suicide. Somehow.</b>"
|
||||
oxyloss = max(175 - toxloss - fireloss - bruteloss, oxyloss)
|
||||
oxyloss = max(175 - toxloss - fireloss - getBruteLoss(), oxyloss)
|
||||
updatehealth()
|
||||
spawn(200)
|
||||
suiciding = 0
|
||||
@@ -74,7 +74,7 @@
|
||||
suiciding = 1
|
||||
//instead of killing them instantly, just put them at -175 health and let 'em gasp for a while
|
||||
viewers(src) << "\red <b>[src] is attempting to bite \his tongue. It looks like \he's trying to commit suicide.</b>"
|
||||
oxyloss = max(175 - toxloss - fireloss - bruteloss, oxyloss)
|
||||
oxyloss = max(175 - toxloss - fireloss - getBruteLoss(), oxyloss)
|
||||
updatehealth()
|
||||
|
||||
/mob/living/silicon/ai/verb/suicide()
|
||||
@@ -94,7 +94,7 @@
|
||||
suiciding = 1
|
||||
viewers(src) << "\red <b>[src] is powering down. It looks like \he's trying to commit suicide.</b>"
|
||||
//put em at -175
|
||||
oxyloss = max(175 - toxloss - fireloss - bruteloss, oxyloss)
|
||||
oxyloss = max(175 - toxloss - fireloss - getBruteLoss(), oxyloss)
|
||||
updatehealth()
|
||||
|
||||
/mob/living/silicon/robot/verb/suicide()
|
||||
@@ -114,7 +114,7 @@
|
||||
suiciding = 1
|
||||
viewers(src) << "\red <b>[src] is powering down. It looks like \he's trying to commit suicide.</b>"
|
||||
//put em at -175
|
||||
oxyloss = max(475 - toxloss - fireloss - bruteloss, oxyloss)
|
||||
oxyloss = max(475 - toxloss - fireloss - getBruteLoss(), oxyloss)
|
||||
updatehealth()
|
||||
|
||||
/mob/living/silicon/pai/verb/suicide()
|
||||
@@ -149,7 +149,7 @@
|
||||
suiciding = 1
|
||||
viewers(src) << "\red <b>[src] is thrashing wildly! It looks like \he's trying to commit suicide.</b>"
|
||||
//put em at -175
|
||||
oxyloss = max(100 - fireloss - bruteloss, oxyloss)
|
||||
oxyloss = max(100 - fireloss - getBruteLoss(), oxyloss)
|
||||
updatehealth()
|
||||
|
||||
|
||||
|
||||
@@ -1200,7 +1200,7 @@ datum
|
||||
return
|
||||
if(!M) M = holder.my_atom
|
||||
if(M:oxyloss && prob(40)) M:oxyloss--
|
||||
if(M:bruteloss && prob(40)) M:heal_organ_damage(1,0)
|
||||
if(M:getBruteLoss() && prob(40)) M:heal_organ_damage(1,0)
|
||||
if(M:fireloss && prob(40)) M:heal_organ_damage(0,1)
|
||||
if(M:toxloss && prob(40)) M:toxloss--
|
||||
..()
|
||||
@@ -2103,7 +2103,7 @@ datum
|
||||
|
||||
on_mob_life(var/mob/living/M as mob)
|
||||
if(!M) M = holder.my_atom
|
||||
if(M:bruteloss && prob(20)) M:heal_organ_damage(1,0)
|
||||
if(M:getBruteLoss() && prob(20)) M:heal_organ_damage(1,0)
|
||||
M:nutrition++
|
||||
..()
|
||||
return
|
||||
@@ -2117,7 +2117,7 @@ datum
|
||||
|
||||
on_mob_life(var/mob/living/M as mob)
|
||||
if(!M) M = holder.my_atom
|
||||
if(M:bruteloss && prob(20)) M:heal_organ_damage(1,0)
|
||||
if(M:getBruteLoss() && prob(20)) M:heal_organ_damage(1,0)
|
||||
M:nutrition++
|
||||
..()
|
||||
return
|
||||
@@ -2132,7 +2132,7 @@ datum
|
||||
|
||||
on_mob_life(var/mob/living/M as mob)
|
||||
M:nutrition += nutriment_factor
|
||||
if(M:bruteloss && prob(20)) M:heal_organ_damage(1,0)
|
||||
if(M:getBruteLoss() && prob(20)) M:heal_organ_damage(1,0)
|
||||
..()
|
||||
return
|
||||
|
||||
@@ -2656,7 +2656,7 @@ datum
|
||||
color = "#895C4C" // rgb: 137, 92, 76
|
||||
|
||||
on_mob_life(var/mob/living/M as mob)
|
||||
if(M:bruteloss && prob(10)) M:heal_organ_damage(1,0)
|
||||
if(M:getBruteLoss() && prob(10)) M:heal_organ_damage(1,0)
|
||||
M:nutrition += 2
|
||||
if(!data) data = 1
|
||||
data++
|
||||
@@ -3031,7 +3031,7 @@ datum
|
||||
on_mob_life(var/mob/living/M as mob)
|
||||
if(!M) M = holder.my_atom
|
||||
if(M:oxyloss && prob(50)) M:oxyloss -= 2
|
||||
if(M:bruteloss && prob(60)) M:heal_organ_damage(2,0)
|
||||
if(M:getBruteLoss() && prob(60)) M:heal_organ_damage(2,0)
|
||||
if(M:fireloss && prob(50)) M:heal_organ_damage(0,2)
|
||||
if(M:toxloss && prob(50)) M:toxloss -= 2
|
||||
if(M.dizziness !=0) M.dizziness = max(0,M.dizziness-15)
|
||||
|
||||
@@ -40,7 +40,7 @@
|
||||
paralysis = 0
|
||||
weakened = 0
|
||||
sleeping = 0
|
||||
bruteloss = max(bruteloss, 0)
|
||||
bruteloss = max(getBruteLoss(), 0)
|
||||
toxloss = max(toxloss, 0)
|
||||
oxyloss = max(oxyloss, 0)
|
||||
fireloss = max(fireloss, 0)
|
||||
@@ -50,7 +50,7 @@
|
||||
|
||||
|
||||
proc/UpdateDamage()
|
||||
health = 60 - (oxyloss + toxloss + fireloss + bruteloss + cloneloss)
|
||||
health = 60 - (oxyloss + toxloss + fireloss + getBruteLoss() + cloneloss)
|
||||
return
|
||||
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
if (src.nodamage == 0)
|
||||
//oxyloss is only used for suicide
|
||||
//toxloss isn't used for aliens, its actually used as alien powers!!
|
||||
src.health = 150 - src.oxyloss - src.fireloss - src.bruteloss
|
||||
src.health = 150 - src.oxyloss - src.fireloss - src.getBruteLoss()
|
||||
else
|
||||
src.health = 150
|
||||
src.stat = 0
|
||||
@@ -76,7 +76,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = 150 - (oxyloss + fireloss + bruteloss + cloneloss)
|
||||
health = 150 - (oxyloss + fireloss + getBruteLoss() + cloneloss)
|
||||
|
||||
if(oxyloss > 50) paralysis = max(paralysis, 3)
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
if (src.nodamage == 0)
|
||||
//oxyloss is only used for suicide
|
||||
//toxloss isn't used for aliens, its actually used as alien powers!!
|
||||
src.health = 125 - src.oxyloss - src.fireloss - src.bruteloss
|
||||
src.health = 125 - src.oxyloss - src.fireloss - src.getBruteLoss()
|
||||
else
|
||||
src.health = 125
|
||||
src.stat = 0
|
||||
@@ -77,7 +77,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = 150 - (oxyloss + fireloss + bruteloss + cloneloss)
|
||||
health = 150 - (oxyloss + fireloss + getBruteLoss() + cloneloss)
|
||||
|
||||
if(oxyloss > 50) paralysis = max(paralysis, 3)
|
||||
|
||||
|
||||
@@ -755,7 +755,7 @@ In all, this is a lot like the monkey code. /N
|
||||
if (nodamage == 0)
|
||||
//oxyloss is only used for suicide
|
||||
//toxloss isn't used for aliens, its actually used as alien powers!!
|
||||
health = 100 - oxyloss - fireloss - bruteloss
|
||||
health = 100 - oxyloss - fireloss - getBruteLoss()
|
||||
else
|
||||
health = 100
|
||||
stat = 0
|
||||
|
||||
@@ -84,7 +84,7 @@
|
||||
paralysis = max(min(paralysis, 20), 0)
|
||||
weakened = max(min(weakened, 20), 0)
|
||||
sleeping = max(min(sleeping, 20), 0)
|
||||
bruteloss = max(bruteloss, 0)
|
||||
bruteloss = max(getBruteLoss(), 0)
|
||||
toxloss = max(toxloss, 0)
|
||||
oxyloss = max(oxyloss, 0)
|
||||
fireloss = max(fireloss, 0)
|
||||
@@ -396,7 +396,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = 100 - (oxyloss + fireloss + bruteloss + cloneloss)
|
||||
health = 100 - (oxyloss + fireloss + getBruteLoss() + cloneloss)
|
||||
|
||||
if(oxyloss > 50) paralysis = max(paralysis, 3)
|
||||
|
||||
|
||||
@@ -23,7 +23,7 @@
|
||||
if (src.nodamage == 0)
|
||||
//oxyloss is only used for suicide
|
||||
//toxloss isn't used for aliens, its actually used as alien powers!!
|
||||
src.health = 250 - src.oxyloss - src.fireloss - src.bruteloss
|
||||
src.health = 250 - src.oxyloss - src.fireloss - src.getBruteLoss()
|
||||
else
|
||||
src.health = 250
|
||||
src.stat = 0
|
||||
@@ -78,7 +78,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = 250 - (oxyloss + fireloss + bruteloss + cloneloss)
|
||||
health = 250 - (oxyloss + fireloss + getBruteLoss() + cloneloss)
|
||||
|
||||
if(oxyloss > 50) paralysis = max(paralysis, 3)
|
||||
|
||||
|
||||
@@ -503,7 +503,7 @@
|
||||
if (nodamage == 0)
|
||||
//oxyloss is only used for suicide
|
||||
//toxloss isn't used for aliens, its actually used as alien powers!!
|
||||
health = 25 - oxyloss - fireloss - bruteloss
|
||||
health = 25 - oxyloss - fireloss - getBruteLoss()
|
||||
else
|
||||
health = 25
|
||||
stat = 0
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
paralysis = max(min(paralysis, 20), 0)
|
||||
weakened = max(min(weakened, 20), 0)
|
||||
sleeping = max(min(sleeping, 20), 0)
|
||||
bruteloss = max(bruteloss, 0)
|
||||
bruteloss = max(getBruteLoss(), 0)
|
||||
toxloss = max(toxloss, 0)
|
||||
oxyloss = max(oxyloss, 0)
|
||||
fireloss = max(fireloss, 0)
|
||||
@@ -323,7 +323,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = 25 - (oxyloss + fireloss + bruteloss + cloneloss)
|
||||
health = 25 - (oxyloss + fireloss + getBruteLoss() + cloneloss)
|
||||
|
||||
if(oxyloss > 50) paralysis = max(paralysis, 3)
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = 200 - (oxyloss + fireloss + bruteloss)
|
||||
health = 200 - (oxyloss + fireloss + getBruteLoss())
|
||||
|
||||
weakened = 0
|
||||
stunned = 0
|
||||
@@ -43,7 +43,7 @@
|
||||
return 1
|
||||
|
||||
updatehealth()
|
||||
src.health = 200 - src.oxyloss - src.fireloss - src.bruteloss
|
||||
src.health = 200 - src.oxyloss - src.fireloss - src.getBruteLoss()
|
||||
|
||||
xcom_attack(mob/living/carbon/human/target as mob)
|
||||
if(!ishuman(target))
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
stunned = max(stunned,0)
|
||||
paralysis = max(paralysis, 0)
|
||||
weakened = max(weakened, 0)
|
||||
bruteloss = max(bruteloss, 0)
|
||||
bruteloss = max(getBruteLoss(), 0)
|
||||
fireloss = max(fireloss, 0)
|
||||
oxyloss = max(oxyloss, 0)
|
||||
toxloss = max(toxloss, 0)
|
||||
@@ -144,7 +144,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = 100 - (oxyloss + toxloss + fireloss + bruteloss + cloneloss)
|
||||
health = 100 - (oxyloss + toxloss + fireloss + getBruteLoss() + cloneloss)
|
||||
|
||||
if(oxyloss > 25) paralysis = max(paralysis, 3)
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
M.show_message(text("\red <B>[user] attacks [src]'s stomach wall with the [I.name]!"), 2)
|
||||
playsound(user.loc, 'attackblob.ogg', 50, 1)
|
||||
|
||||
if(prob(src.bruteloss - 50))
|
||||
if(prob(src.getBruteLoss() - 50))
|
||||
src.gib()
|
||||
|
||||
/mob/living/carbon/gib(give_medal)
|
||||
|
||||
@@ -115,8 +115,8 @@
|
||||
if (src.stat == 2 || (changeling && changeling.changeling_fakedeath == 1))
|
||||
usr << "\red [src] is limp and unresponsive, a dull lifeless look in [t_his] eyes."
|
||||
else
|
||||
if (src.bruteloss)
|
||||
if (src.bruteloss < 30)
|
||||
if (src.getBruteLoss())
|
||||
if (src.getBruteLoss() < 30)
|
||||
usr << "\red [src.name] looks slightly injured!"
|
||||
else
|
||||
usr << "\red <B>[src.name] looks severely injured!</B>"
|
||||
|
||||
@@ -688,7 +688,7 @@
|
||||
M.pulling = null
|
||||
|
||||
//this is the gay blood on floor shit -- Added back -- Skie
|
||||
if (M.lying && (prob(M.bruteloss / 6)))
|
||||
if (M.lying && (prob(M.getBruteLoss() / 6)))
|
||||
var/turf/location = M.loc
|
||||
if (istype(location, /turf/simulated))
|
||||
location.add_blood(M)
|
||||
@@ -2195,7 +2195,7 @@ It can still be worn/put on as normal.
|
||||
for(var/datum/organ/external/O in organs)
|
||||
src.bruteloss += O.brute_dam
|
||||
src.fireloss += O.burn_dam
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.bruteloss - src.cloneloss
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.getBruteLoss() - src.cloneloss
|
||||
|
||||
|
||||
/mob/living/carbon/human/abiotic(var/full_body = 0)
|
||||
|
||||
@@ -102,7 +102,7 @@
|
||||
paralysis = max(min(paralysis, 20), 0)
|
||||
weakened = max(min(weakened, 20), 0)
|
||||
sleeping = max(min(sleeping, 20), 0)
|
||||
bruteloss = max(bruteloss, 0)
|
||||
bruteloss = max(getBruteLoss(), 0)
|
||||
toxloss = max(toxloss, 0)
|
||||
oxyloss = max(oxyloss, 0)
|
||||
fireloss = max(fireloss, 0)
|
||||
@@ -603,7 +603,7 @@
|
||||
if(light_amount > 0) //if there's enough light, heal
|
||||
if(fireloss)
|
||||
heal_overall_damage(0,1)
|
||||
if(bruteloss)
|
||||
if(getBruteLoss())
|
||||
heal_overall_damage(1,0)
|
||||
if(toxloss)
|
||||
toxloss--
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
if (src.stat == 2)
|
||||
usr << text("\red [] is limp and unresponsive.", src.name)
|
||||
else
|
||||
if (src.bruteloss)
|
||||
if (src.bruteloss < 40)
|
||||
if (src.getBruteLoss())
|
||||
if (src.getBruteLoss() < 40)
|
||||
usr << text("\red [] has some punctures in its flesh!", src.name)
|
||||
else
|
||||
usr << text("\red <B>[] has a lot of punctures and tears in its flesh!</B>", src.name)
|
||||
|
||||
@@ -396,9 +396,9 @@
|
||||
handle_regular_status_updates()
|
||||
|
||||
if(istype(src, /mob/living/carbon/metroid/adult))
|
||||
health = 200 - (oxyloss + toxloss + fireloss + bruteloss + cloneloss)
|
||||
health = 200 - (oxyloss + toxloss + fireloss + getBruteLoss() + cloneloss)
|
||||
else
|
||||
health = 150 - (oxyloss + toxloss + fireloss + bruteloss + cloneloss)
|
||||
health = 150 - (oxyloss + toxloss + fireloss + getBruteLoss() + cloneloss)
|
||||
|
||||
|
||||
|
||||
@@ -420,7 +420,7 @@
|
||||
if(toxloss>0) toxloss = max(toxloss-1, 0)
|
||||
if(fireloss>0) fireloss = max(fireloss-1,0)
|
||||
if(cloneloss>0) cloneloss = max(cloneloss-1,0)
|
||||
if(bruteloss>0) bruteloss = max(bruteloss-1,0)
|
||||
if(getBruteLoss()>0) bruteloss = max(getBruteLoss()-1,0)
|
||||
|
||||
|
||||
if (src.stat == 2)
|
||||
|
||||
@@ -648,9 +648,9 @@ mob/living/carbon/metroid/var/temperature_resistance = T0C+75
|
||||
if (nodamage == 0)
|
||||
// metroids can't suffocate unless they suicide. They are also not harmed by fire
|
||||
if(istype(src, /mob/living/carbon/metroid/adult))
|
||||
health = 200 - (oxyloss + toxloss + fireloss + bruteloss + cloneloss)
|
||||
health = 200 - (oxyloss + toxloss + fireloss + getBruteLoss() + cloneloss)
|
||||
else
|
||||
health = 150 - (oxyloss + toxloss + fireloss + bruteloss + cloneloss)
|
||||
health = 150 - (oxyloss + toxloss + fireloss + getBruteLoss() + cloneloss)
|
||||
else
|
||||
if(istype(src, /mob/living/carbon/metroid/adult))
|
||||
health = 200
|
||||
|
||||
@@ -82,8 +82,8 @@
|
||||
if(oxyloss > 0)
|
||||
oxyloss = max(0, oxyloss-10)
|
||||
|
||||
if(bruteloss > 0)
|
||||
bruteloss = max(0, bruteloss-10)
|
||||
if(getBruteLoss() > 0)
|
||||
bruteloss = max(0, getBruteLoss()-10)
|
||||
|
||||
if(fireloss > 0)
|
||||
fireloss = max(0, fireloss-10)
|
||||
@@ -98,7 +98,7 @@
|
||||
|
||||
if(toxloss<0) toxloss = 0
|
||||
if(oxyloss<0) oxyloss = 0
|
||||
if(bruteloss<0) bruteloss = 0
|
||||
if(getBruteLoss()<0) bruteloss = 0
|
||||
if(fireloss<0) fireloss = 0
|
||||
if(cloneloss<0) cloneloss = 0
|
||||
|
||||
|
||||
@@ -16,8 +16,8 @@
|
||||
if (src.stat == 2)
|
||||
usr << text("\red [] is limp and unresponsive, a dull lifeless look in their eyes.", src.name)
|
||||
else
|
||||
if (src.bruteloss)
|
||||
if (src.bruteloss < 30)
|
||||
if (src.getBruteLoss())
|
||||
if (src.getBruteLoss() < 30)
|
||||
usr << text("\red [] looks slightly bruised!", src.name)
|
||||
else
|
||||
usr << text("\red <B>[] looks severely bruised!</B>", src.name)
|
||||
|
||||
@@ -397,7 +397,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = 100 - (oxyloss + toxloss + fireloss + bruteloss + cloneloss)
|
||||
health = 100 - (oxyloss + toxloss + fireloss + getBruteLoss() + cloneloss)
|
||||
|
||||
if(oxyloss > 25) paralysis = max(paralysis, 3)
|
||||
|
||||
|
||||
@@ -103,7 +103,7 @@
|
||||
bruteloss += 30
|
||||
if ((O.icon_state == "flaming" && !( shielded )))
|
||||
fireloss += 40
|
||||
health = 100 - oxyloss - toxloss - fireloss - bruteloss
|
||||
health = 100 - oxyloss - toxloss - fireloss - getBruteLoss()
|
||||
return
|
||||
|
||||
//mob/living/carbon/monkey/bullet_act(var/obj/item/projectile/Proj)taken care of in living
|
||||
@@ -139,7 +139,7 @@
|
||||
O.show_message("\red <B>[M.name] has bit [name]!</B>", 1)
|
||||
var/damage = rand(1, 5)
|
||||
bruteloss += damage
|
||||
health = 100 - oxyloss - toxloss - fireloss - bruteloss
|
||||
health = 100 - oxyloss - toxloss - fireloss - getBruteLoss()
|
||||
for(var/datum/disease/D in M.viruses)
|
||||
if(istype(D, /datum/disease/jungle_fever))
|
||||
contract_disease(D,1,0)
|
||||
@@ -536,16 +536,16 @@
|
||||
if(1.0)
|
||||
if (stat != 2)
|
||||
bruteloss += 200
|
||||
health = 100 - oxyloss - toxloss - fireloss - bruteloss
|
||||
health = 100 - oxyloss - toxloss - fireloss - getBruteLoss()
|
||||
if(2.0)
|
||||
if (stat != 2)
|
||||
bruteloss += 60
|
||||
fireloss += 60
|
||||
health = 100 - oxyloss - toxloss - fireloss - bruteloss
|
||||
health = 100 - oxyloss - toxloss - fireloss - getBruteLoss()
|
||||
if(3.0)
|
||||
if (stat != 2)
|
||||
bruteloss += 30
|
||||
health = 100 - oxyloss - toxloss - fireloss - bruteloss
|
||||
health = 100 - oxyloss - toxloss - fireloss - getBruteLoss()
|
||||
if (prob(50))
|
||||
paralysis += 10
|
||||
else
|
||||
@@ -554,7 +554,7 @@
|
||||
/mob/living/carbon/monkey/blob_act()
|
||||
if (stat != 2)
|
||||
fireloss += 60
|
||||
health = 100 - oxyloss - toxloss - fireloss - bruteloss
|
||||
health = 100 - oxyloss - toxloss - fireloss - getBruteLoss()
|
||||
if (prob(50))
|
||||
paralysis += 10
|
||||
|
||||
|
||||
@@ -2,13 +2,13 @@
|
||||
set hidden = 1
|
||||
if ((src.health < 0 && src.health > -95.0))
|
||||
src.oxyloss += src.health + 200
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.bruteloss
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.getBruteLoss()
|
||||
src << "\blue You have given up life and succumbed to death."
|
||||
|
||||
|
||||
/mob/living/proc/updatehealth()
|
||||
if(!src.nodamage)
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.bruteloss - src.cloneloss
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.getBruteLoss() - src.cloneloss
|
||||
else
|
||||
src.health = 100
|
||||
src.stat = 0
|
||||
@@ -111,7 +111,7 @@
|
||||
|
||||
// heal ONE external organ, organ gets randomly selected from damaged ones.
|
||||
/mob/living/proc/heal_organ_damage(var/brute, var/burn)
|
||||
bruteloss = max(0, bruteloss-brute)
|
||||
bruteloss = max(0, getBruteLoss()-brute)
|
||||
fireloss = max(0, fireloss-burn)
|
||||
src.updatehealth()
|
||||
|
||||
@@ -123,7 +123,7 @@
|
||||
|
||||
// heal MANY external organs, in random order
|
||||
/mob/living/proc/heal_overall_damage(var/brute, var/burn)
|
||||
bruteloss = max(0, bruteloss-brute)
|
||||
bruteloss = max(0, getBruteLoss()-brute)
|
||||
fireloss = max(0, fireloss-burn)
|
||||
src.updatehealth()
|
||||
|
||||
|
||||
@@ -210,7 +210,7 @@
|
||||
/mob/living/silicon/ai/ex_act(severity)
|
||||
flick("flash", flash)
|
||||
|
||||
var/b_loss = bruteloss
|
||||
var/b_loss = getBruteLoss()
|
||||
var/f_loss = fireloss
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
if (src.stat == 2)
|
||||
usr << text("\red [] is powered-down.", src.name)
|
||||
else
|
||||
if (src.bruteloss)
|
||||
if (src.bruteloss < 30)
|
||||
if (src.getBruteLoss())
|
||||
if (src.getBruteLoss() < 30)
|
||||
usr << text("\red [] looks slightly dented", src.name)
|
||||
else
|
||||
usr << text("\red <B>[] looks severely dented!</B>", src.name)
|
||||
|
||||
@@ -239,9 +239,9 @@
|
||||
/mob/living/silicon/ai/updatehealth()
|
||||
if (src.nodamage == 0)
|
||||
if(src.fire_res_on_core)
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.bruteloss
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.getBruteLoss()
|
||||
else
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.bruteloss
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.getBruteLoss()
|
||||
else
|
||||
src.health = 100
|
||||
src.stat = 0
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
/mob/living/silicon/decoy/updatehealth()
|
||||
if (src.nodamage == 0)
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.bruteloss
|
||||
src.health = 100 - src.oxyloss - src.toxloss - src.fireloss - src.getBruteLoss()
|
||||
else
|
||||
src.health = 100
|
||||
src.stat = 0
|
||||
@@ -6,8 +6,8 @@
|
||||
if (src.stat == 2)
|
||||
usr << text("\red [] appears disabled.", src.name)
|
||||
else
|
||||
if (src.bruteloss)
|
||||
if (src.bruteloss < 30)
|
||||
if (src.getBruteLoss())
|
||||
if (src.getBruteLoss() < 30)
|
||||
usr << text("\red [] looks slightly dented", src.name)
|
||||
else
|
||||
usr << text("\red <B>[]'s casing appears cracked and broken!</B>", src.name)
|
||||
|
||||
@@ -23,4 +23,4 @@
|
||||
src.health = 100
|
||||
src.stat = 0
|
||||
else
|
||||
src.health = 100 - src.bruteloss - src.fireloss
|
||||
src.health = 100 - src.getBruteLoss() - src.fireloss
|
||||
@@ -83,7 +83,7 @@
|
||||
/mob/living/silicon/pai/ex_act(severity)
|
||||
flick("flash", src.flash)
|
||||
|
||||
var/b_loss = src.bruteloss
|
||||
var/b_loss = src.getBruteLoss()
|
||||
var/f_loss = src.fireloss
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
|
||||
@@ -472,7 +472,7 @@
|
||||
Respiratory: [M.oxyloss > 50 ? "<font color=#FF5555>" : "<font color=#55FF55>"][M.oxyloss]</font><br>
|
||||
Toxicology: [M.toxloss > 50 ? "<font color=#FF5555>" : "<font color=#55FF55>"][M.toxloss]</font><br>
|
||||
Burns: [M.fireloss > 50 ? "<font color=#FF5555>" : "<font color=#55FF55>"][M.fireloss]</font><br>
|
||||
Structural Integrity: [M.bruteloss > 50 ? "<font color=#FF5555>" : "<font color=#55FF55>"][M.bruteloss]</font><br>
|
||||
Structural Integrity: [M.getBruteLoss() > 50 ? "<font color=#FF5555>" : "<font color=#55FF55>"][M.getBruteLoss()]</font><br>
|
||||
Body Temperature: [M.bodytemperature-T0C]°C ([M.bodytemperature*1.8-459.67]°F)<br>
|
||||
"}
|
||||
for(var/datum/disease/D in M.viruses)
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
usr << text("\blue This is \icon[src] <B>[src.name]</B>!")
|
||||
if (src.stat == 2)
|
||||
usr << text("\red [src.name] is powered-down.")
|
||||
if (src.bruteloss)
|
||||
if (src.bruteloss < 75)
|
||||
if (src.getBruteLoss())
|
||||
if (src.getBruteLoss() < 75)
|
||||
usr << text("\red [src.name] looks slightly dented")
|
||||
else
|
||||
usr << text("\red <B>[src.name] looks severely dented!</B>")
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
paralysis = max(min(paralysis, 30), 0)
|
||||
weakened = max(min(weakened, 20), 0)
|
||||
sleeping = 0
|
||||
bruteloss = max(bruteloss, 0)
|
||||
bruteloss = max(getBruteLoss(), 0)
|
||||
toxloss = max(toxloss, 0)
|
||||
oxyloss = max(oxyloss, 0)
|
||||
fireloss = max(fireloss, 0)
|
||||
@@ -87,7 +87,7 @@
|
||||
if(src.stat)
|
||||
src.camera.status = 0
|
||||
|
||||
health = 200 - (oxyloss + fireloss + bruteloss)
|
||||
health = 200 - (oxyloss + fireloss + getBruteLoss())
|
||||
|
||||
if(oxyloss > 50) paralysis = max(paralysis, 3)
|
||||
|
||||
|
||||
@@ -217,7 +217,7 @@
|
||||
del(src)
|
||||
return
|
||||
|
||||
var/b_loss = bruteloss
|
||||
var/b_loss = getBruteLoss()
|
||||
var/f_loss = fireloss
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
@@ -338,7 +338,7 @@
|
||||
if (istype(W, /obj/item/weapon/weldingtool) && W:welding)
|
||||
if (W:remove_fuel(0))
|
||||
bruteloss -= 30
|
||||
if(bruteloss < 0) bruteloss = 0
|
||||
if(getBruteLoss() < 0) bruteloss = 0
|
||||
updatehealth()
|
||||
add_fingerprint(user)
|
||||
for(var/mob/O in viewers(user, null))
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
usr << text("\blue This is \icon[src] <B>[src.name]</B>!")
|
||||
if (src.stat == 2)
|
||||
usr << text("\red [src.name] is powered-down.")
|
||||
if (src.bruteloss)
|
||||
if (src.bruteloss < 75)
|
||||
if (src.getBruteLoss())
|
||||
if (src.getBruteLoss() < 75)
|
||||
usr << text("\red [src.name] looks slightly dented")
|
||||
else
|
||||
usr << text("\red <B>[src.name] looks severely dented!</B>")
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
del(src)
|
||||
return
|
||||
|
||||
var/b_loss = src.bruteloss
|
||||
var/b_loss = src.getBruteLoss()
|
||||
var/f_loss = src.fireloss
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
@@ -187,7 +187,7 @@
|
||||
if (istype(W, /obj/item/weapon/weldingtool) && W:welding)
|
||||
if (W:remove_fuel(0))
|
||||
src.bruteloss -= 30
|
||||
if(src.bruteloss < 0) src.bruteloss = 0
|
||||
if(src.getBruteLoss() < 0) src.bruteloss = 0
|
||||
src.updatehealth()
|
||||
src.add_fingerprint(user)
|
||||
for(var/mob/O in viewers(user, null))
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
paralysis = max(min(paralysis, 1), 0)
|
||||
weakened = max(min(weakened, 15), 0)
|
||||
sleeping = max(min(sleeping, 1), 0)
|
||||
bruteloss = max(bruteloss, 0)
|
||||
bruteloss = max(getBruteLoss(), 0)
|
||||
toxloss = 0
|
||||
oxyloss = 0
|
||||
fireloss = max(fireloss, 0)
|
||||
@@ -70,7 +70,7 @@
|
||||
|
||||
handle_regular_status_updates()
|
||||
|
||||
health = src.health_max - (fireloss + bruteloss)
|
||||
health = src.health_max - (fireloss + getBruteLoss())
|
||||
|
||||
if(health <= 0)
|
||||
death()
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
|
||||
/mob/living/silicon/hive_mainframe/updatehealth()
|
||||
if (src.nodamage == 0)
|
||||
src.health = 100 - src.fireloss - src.bruteloss
|
||||
src.health = 100 - src.fireloss - src.getBruteLoss()
|
||||
else
|
||||
src.health = 100
|
||||
src.stat = 0
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
|
||||
var/dat = "\blue Analyzing Results for [C]:\n"
|
||||
dat += "\blue \t Overall Status: [C.stat > 1 ? "dead" : "[C.health]% healthy"]\n"
|
||||
dat += "\blue \t Damage Specifics: [C.oxyloss > 50 ? "\red" : "\blue"][C.oxyloss]-[C.toxloss > 50 ? "\red" : "\blue"][C.toxloss]-[C.fireloss > 50 ? "\red" : "\blue"][C.fireloss]-[C.bruteloss > 50 ? "\red" : "\blue"][C.bruteloss]\n"
|
||||
dat += "\blue \t Damage Specifics: [C.oxyloss > 50 ? "\red" : "\blue"][C.oxyloss]-[C.toxloss > 50 ? "\red" : "\blue"][C.toxloss]-[C.fireloss > 50 ? "\red" : "\blue"][C.fireloss]-[C.getBruteLoss() > 50 ? "\red" : "\blue"][C.getBruteLoss()]\n"
|
||||
dat += "\blue \t Key: Suffocation/Toxin/Burns/Brute\n"
|
||||
dat += "\blue \t Body Temperature: [C.bodytemperature-T0C]°C ([C.bodytemperature*1.8-459.67]°F)"
|
||||
if(C.virus)
|
||||
|
||||
Reference in New Issue
Block a user