mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-30 16:38:22 +01:00
Fixes add_armor runtime. (#8290)
add_armor runtimes when you're wearing any clothing without armor due to not handling armor = null, which is the default state. This fixes that.
This commit is contained in:
@@ -133,10 +133,10 @@ emp_act
|
||||
var/protection = 0
|
||||
var/list/protective_gear = list(head, wear_mask, wear_suit, w_uniform, gloves, shoes)
|
||||
for(var/obj/item/clothing/gear in protective_gear)
|
||||
if(gear.body_parts_covered & def_zone.body_part)
|
||||
if(!isnull(gear.armor) && gear.body_parts_covered & def_zone.body_part)
|
||||
protection = add_armor(protection, gear.armor[type])
|
||||
for(var/obj/item/clothing/accessory/A in gear.accessories)
|
||||
if(A.body_parts_covered & def_zone.body_part)
|
||||
if(!isnull(A.armor) && A.body_parts_covered & def_zone.body_part)
|
||||
protection = add_armor(protection, A.armor[type])
|
||||
|
||||
return protection
|
||||
|
||||
Reference in New Issue
Block a user