[MIRROR] some istype to macros (#9802)

Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
CHOMPStation2StaffMirrorBot
2025-01-05 15:01:49 -07:00
committed by GitHub
parent 73486c399b
commit ed79946ade
409 changed files with 750 additions and 751 deletions

View File

@@ -56,7 +56,7 @@
data["path_name"] = M.name
data["desc"] = M.desc
data["flavor_text"] = M.flavor_text
if(istype(M, /mob/living))
if(isliving(M))
var/mob/living/L = M
// AI Stuff
@@ -67,7 +67,7 @@
data["max_health"] = L.maxHealth
data["health"] = L.health
if(istype(L, /mob/living/simple_mob))
if(isanimal(L))
var/mob/living/simple_mob/S = L
data["melee_damage_lower"] = S.melee_damage_lower ? S.melee_damage_lower : 0
data["melee_damage_upper"] = S.melee_damage_upper ? S.melee_damage_upper : 0
@@ -142,13 +142,13 @@
M.name = sanitize(name)
M.desc = sanitize(params["desc"])
M.flavor_text = sanitize(params["flavor_text"])
if(istype(M, /mob/living))
if(isliving(M))
var/mob/living/L = M
if(isnum(params["max_health"]))
L.maxHealth = params["max_health"]
if(isnum(params["health"]))
L.health = params["health"]
if(istype(M, /mob/living/simple_mob))
if(isanimal(M))
var/mob/living/simple_mob/S = L
if(isnum(params["melee_damage_lower"]))
S.melee_damage_lower = params["melee_damage_lower"]