moves var/can_deconstruct to obj level

moves proc/deconstruct() and proc/take_damage() to obj level, moves a few obj damage procs in with it to new obj_defense.dm
moves plastic flaps to new plasticflaps.dm
This commit is contained in:
uraniummeltdown
2017-12-26 18:16:42 +05:00
parent d8001c1a6c
commit 73d7af2675
20 changed files with 229 additions and 211 deletions
@@ -24,7 +24,7 @@
if(prob(75))
take_damage(obj_integrity, BRUTE)
/obj/item/device/modular_computer/proc/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1)
/obj/item/device/modular_computer/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1)
. = ..()
var/component_probability = min(50, max(damage_amount*0.1, 1 - obj_integrity/max_integrity))
switch(damage_flag)