Merge pull request #3473 from Citadel-Station-13/upstream-merge-31809

[MIRROR] Cleans up some istypes not using helpers
This commit is contained in:
LetterJay
2017-10-18 07:37:43 -04:00
committed by GitHub
18 changed files with 26 additions and 24 deletions
+1 -1
View File
@@ -509,7 +509,7 @@
if(wall_pierce++ < wall_pierce_amount)
loc = target
if(prob(wall_devastate))
if(istype(target, /turf/closed/wall))
if(iswallturf(target))
var/turf/closed/wall/W = target
W.dismantle_wall(TRUE, TRUE)
else
+1 -1
View File
@@ -101,7 +101,7 @@
/obj/item/projectile/proc/on_hit(atom/target, blocked = FALSE)
var/turf/target_loca = get_turf(target)
if(!nodamage && (damage_type == BRUTE || damage_type == BURN) && istype(target_loca, /turf/closed/wall) && prob(75))
if(!nodamage && (damage_type == BRUTE || damage_type == BURN) && iswallturf(target_loca) && prob(75))
var/turf/closed/wall/W = target_loca
var/mutable_appearance/decal = mutable_appearance('icons/effects/effects.dmi', "bullet_hole", TURF_DECAL_LAYER)
if(target == original)
+1 -1
View File
@@ -76,7 +76,7 @@
OpenDoor(target)
else
var/turf/T = get_turf(target)
if(isclosedturf(T) && !istype(T, /turf/closed/indestructible))
if(isclosedturf(T) && !isindestructiblewall(T))
CreateDoor(T)
/obj/item/projectile/magic/door/proc/CreateDoor(turf/T)