fixes telegun (#25835)

* fixes telegun

* fully fixes matts messup :^)

* Update special_projectiles.dm
This commit is contained in:
Qwertytoforty
2024-06-08 00:04:35 -04:00
committed by GitHub
parent 0a9ab427a1
commit 6d8d449d10
@@ -297,12 +297,13 @@
/obj/item/projectile/energy/teleport/on_hit(atom/target, blocked = 0)
var/turf/target_turf = get_turf(teleport_target)
if(isliving(target) && istype(target_turf))
if(target_turf.z == target.z || teleport_target.emagged)
if(isliving(target))
if(istype(target_turf) && (target_turf.z == target.z || teleport_target.emagged))
do_teleport(target, teleport_target, 0)//teleport what's in the tile to the beacon
else
do_teleport(target, target, 15) //Otherwise it just warps you off somewhere.
add_attack_logs(firer, target, "Shot with a [type] [teleport_target ? "(Destination: [teleport_target])" : ""]")
return ..()
/obj/item/projectile/snowball
name = "snowball"