Fixes a runtime with armor checks

This commit is contained in:
Anewbe
2018-05-24 18:38:57 -05:00
parent 418af6376d
commit beb88f7b7d

View File

@@ -152,7 +152,7 @@ emp_act
for(var/obj/item/clothing/gear in protective_gear)
if(gear.body_parts_covered & def_zone.body_part)
protection += gear.armor[type]
if(gear.accessories.len)
if(LAZYLEN(gear.accessories))
for(var/obj/item/clothing/accessory/bling in gear.accessories)
if(bling.body_parts_covered & def_zone.body_part)
protection += bling.armor[type]
@@ -165,7 +165,7 @@ emp_act
for(var/obj/item/clothing/gear in protective_gear)
if(gear.body_parts_covered & def_zone.body_part)
soaked += gear.armorsoak[type]
if(gear.accessories.len)
if(LAZYLEN(gear.accessories))
for(var/obj/item/clothing/accessory/bling in gear.accessories)
if(bling.body_parts_covered & def_zone.body_part)
soaked += bling.armorsoak[type]