Fix improper chomp edit and change it to cached icon states (#11449)

This commit is contained in:
Drathek
2025-08-16 19:56:14 -05:00
committed by GitHub
parent c33c747a9c
commit c5d5f8702f
2 changed files with 5 additions and 3 deletions

View File

@@ -31,9 +31,6 @@
/obj/item/gun/energy/Initialize(mapload)
. = ..()
var/static/list/gun_icons = icon_states('icons/obj/gun_ch.dmi')
if (icon == 'icons/obj/gun_ch.dmi' && !(icon_state in gun_icons))
icon = 'icons/obj/gun.dmi'
if(self_recharge)
power_supply = new /obj/item/cell/device/weapon(src)
START_PROCESSING(SSobj, src)

View File

@@ -47,3 +47,8 @@
//damage = 5
mob_bonus_damage = 35
armor_penetration = 0
/obj/item/gun/energy/Initialize(mapload)
if(icon == 'icons/obj/gun_ch.dmi' && !(icon_state in cached_icon_states('icons/obj/gun_ch.dmi')))
icon = 'icons/obj/gun.dmi'
return ..()