Finishes seperating ZAS logic from CanPass().

This commit is contained in:
Neerti
2019-02-10 01:46:38 -05:00
parent d880379bbf
commit 76b077af4a
47 changed files with 153 additions and 260 deletions

View File

@@ -53,10 +53,8 @@
projector = null
return ..()
/obj/effect/directional_shield/CanPass(atom/movable/mover, turf/target, height=0, air_group=0)
if(air_group || (height==0))
return TRUE
else if(istype(mover, /obj/item/projectile))
/obj/effect/directional_shield/CanPass(atom/movable/mover, turf/target)
if(istype(mover, /obj/item/projectile))
var/obj/item/projectile/P = mover
if(istype(P, /obj/item/projectile/test)) // Turrets need to try to kill the shield and so their test bullet needs to penetrate.
return TRUE
@@ -64,8 +62,6 @@
var/bad_arc = reverse_direction(dir) // Arc of directions from which we cannot block.
if(check_shield_arc(src, bad_arc, P)) // This is actually for mobs but it will work for our purposes as well.
return FALSE
else
return TRUE
return TRUE
/obj/effect/directional_shield/bullet_act(var/obj/item/projectile/P)