Guns in holsters/bags keep their safety icon (#8308)

This commit is contained in:
mikomyazaki
2020-02-19 17:28:09 +00:00
committed by GitHub
parent 8bcf5cd89d
commit cbb94e74f8
2 changed files with 7 additions and 1 deletions

View File

@@ -128,7 +128,7 @@
var/image/gun_overlay = I
if(gun_overlay.icon == gun_gui_icons && dd_hasprefix(gun_overlay.icon_state, "[safety_icon]"))
overlays -= gun_overlay
if(ismob(loc))
if(!isturf(loc)) // In a mob, holster or bag or something
overlays += image(gun_gui_icons,"[safety_icon][safety()]")
//Checks whether a given mob can use the gun