Ling nerfs, ear protection cleanup, and ling bugfixes.

This commit is contained in:
Neerti
2016-02-14 19:46:38 -05:00
parent 2f0d10a336
commit b7a3a98ef0
12 changed files with 73 additions and 18 deletions
+2
View File
@@ -11,6 +11,7 @@
while sprite_sheets should be used for "flexible" clothing items that do not need to be refitted (e.g. vox wearing jumpsuits).
*/
var/list/sprite_sheets_refit = null
var/ear_protection = 0
//Updates the icons of the mob wearing the clothing item, if any.
/obj/item/clothing/proc/update_clothing_icon()
@@ -162,6 +163,7 @@
icon_state = "earmuffs"
item_state = "earmuffs"
slot_flags = SLOT_EARS | SLOT_TWOEARS
ear_protection = 2
/obj/item/clothing/ears/earmuffs/headphones
name = "headphones"
+1
View File
@@ -15,6 +15,7 @@
max_heat_protection_temperature = HELMET_MAX_HEAT_PROTECTION_TEMPERATURE
siemens_coefficient = 0.7
w_class = 3
ear_protection = 1
/obj/item/clothing/head/helmet/riot
name = "riot helmet"
@@ -116,7 +116,7 @@
b_loss = b_loss/1.5
f_loss = f_loss/1.5
if (!istype(l_ear, /obj/item/clothing/ears/earmuffs) && !istype(r_ear, /obj/item/clothing/ears/earmuffs))
if (!get_ear_protection() >= 2)
ear_damage += 30
ear_deaf += 120
if (prob(70) && !shielded)
@@ -126,7 +126,7 @@
b_loss += 30
if (prob(getarmor(null, "bomb")))
b_loss = b_loss/2
if (!istype(l_ear, /obj/item/clothing/ears/earmuffs) && !istype(r_ear, /obj/item/clothing/ears/earmuffs))
if (!get_ear_protection() >= 2)
ear_damage += 15
ear_deaf += 60
if (prob(50) && !shielded)
@@ -18,7 +18,7 @@
if(!temp || !temp.is_usable())
H << "\red You can't use your hand."
return
break_cloak()
..()
// Should this all be in Touch()?
@@ -32,6 +32,30 @@
return list(HUMAN_EATING_BLOCKED_MOUTH, blocked)
return list(HUMAN_EATING_NO_ISSUE)
//This is called when we want different types of 'cloaks' to stop working, e.g. when attacking.
/mob/living/carbon/human/break_cloak()
if(mind && mind.changeling) //Changeling visible camo
mind.changeling.cloaked = 0
if(istype(back, /obj/item/weapon/rig)) //Ninja cloak
var/obj/item/weapon/rig/suit = back
for(var/obj/item/rig_module/stealth_field/cloaker in suit.installed_modules)
if(cloaker.active)
cloaker.deactivate()
/mob/living/carbon/human/get_ear_protection()
var/sum = 0
if(istype(l_ear, /obj/item/clothing/ears))
var/obj/item/clothing/ears/L = l_ear
sum += L.ear_protection
if(istype(r_ear, /obj/item/clothing/ears))
var/obj/item/clothing/ears/R = r_ear
sum += R.ear_protection
if(istype(head, /obj/item/clothing/head))
var/obj/item/clothing/head/H = head
sum += H.ear_protection
return sum
#undef HUMAN_EATING_NO_ISSUE
#undef HUMAN_EATING_NO_MOUTH
#undef HUMAN_EATING_BLOCKED_MOUTH
+1 -1
View File
@@ -1041,7 +1041,7 @@
ear_deaf = max(ear_deaf, 1)
else if(ear_deaf) //deafness, heals slowly over time
ear_deaf = max(ear_deaf-1, 0)
else if(istype(l_ear, /obj/item/clothing/ears/earmuffs) || istype(r_ear, /obj/item/clothing/ears/earmuffs)) //resting your ears with earmuffs heals ear damage faster
else if(get_ear_protection() >= 2) //resting your ears with earmuffs heals ear damage faster
ear_damage = max(ear_damage-0.15, 0)
ear_deaf = max(ear_deaf, 1)
else if(ear_damage < 25) //ear damage heals slowly under this threshold. otherwise you'll need earmuffs
+6
View File
@@ -37,6 +37,12 @@ proc/isdeaf(A)
return (M.sdisabilities & DEAF) || M.ear_deaf
return 0
/mob/proc/get_ear_protection()
return 0
/mob/proc/break_cloak()
return
proc/hasorgans(A) // Fucking really??
return ishuman(A)