Water_act system - for all your watery needs

This is the first commit of the Water_act system for monkey cubes,
showers, and mobs. The idea of the system is to outsource the effects of
water to the object/mob being affected instead of a bunch of snowflake
code.
This commit is contained in:
Tigercat2000
2015-05-09 05:43:47 -07:00
parent 3ff6339f04
commit e33e658178
6 changed files with 34 additions and 5 deletions
-1
View File
@@ -92,7 +92,6 @@ mob/living
return
return
/mob/living/carbon/electrocute_act(var/shock_damage, var/obj/source, var/siemens_coeff = 1.0, var/def_zone = null)
if(status_flags & GODMODE) //godmode
return 0
@@ -488,3 +488,8 @@ emp_act
..()
return
/mob/living/carbon/human/water_act(volume, temperature)
..()
if(temperature >= 330) bodytemperature = bodytemperature + (temperature - bodytemperature)
if(temperature <= 280) bodytemperature = bodytemperature - (bodytemperature - temperature)
@@ -238,6 +238,10 @@
//Mobs on Fire end
/mob/living/water_act(volume, temperature)
if(volume >= 20) fire_stacks -= 0.5
if(volume >= 50) fire_stacks -= 1
//This is called when the mob is thrown into a dense turf
/mob/living/proc/turf_collision(var/turf/T, var/speed)
src.take_organ_damage(speed*5)