[DNM][DNM][WIP] Projectile backend code port and update

Ports#54924,  #65061, #59804 from /tg.
adds auxiliary code from /tg to make code work.
This commit is contained in:
Solaris-Shade
2022-03-06 15:20:23 -05:00
parent 8b77ee159f
commit 2fdb70b2b9
84 changed files with 597 additions and 503 deletions
+5 -8
View File
@@ -5,6 +5,7 @@
icon_state = "grille"
density = TRUE
anchored = TRUE
pass_flags_self = PASSGRILLE
flags_1 = CONDUCT_1
pressure_resistance = 5*ONE_ATMOSPHERE
layer = BELOW_OBJ_LAYER
@@ -124,14 +125,10 @@
if(!shock(user, 70))
take_damage(20, BRUTE, "melee", 1)
/obj/structure/grille/CanPass(atom/movable/mover, turf/target)
if(istype(mover) && (mover.pass_flags & PASSGRILLE))
return TRUE
else
if(istype(mover, /obj/item/projectile) && density)
return prob(30)
else
return !density
/obj/structure/grille/CanAllowThrough(atom/movable/mover, turf/target)
. = ..()
if(!. && istype(mover, /obj/projectile))
return prob(30)
/obj/structure/grille/CanAStarPass(ID, dir, caller)
. = !density