mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-16 17:43:35 +01:00
Ghosts now don't call moved twice (#20751)
This commit is contained in:
@@ -8,14 +8,14 @@
|
||||
update_z(null)
|
||||
return ..()
|
||||
|
||||
/mob/dead/forceMove(atom/destination)
|
||||
/mob/dead/forceMove(atom/destination, direction = NONE)
|
||||
var/turf/old_turf = get_turf(src)
|
||||
var/turf/new_turf = get_turf(destination)
|
||||
if (old_turf?.z != new_turf?.z)
|
||||
onTransitZ(old_turf?.z, new_turf?.z)
|
||||
var/oldloc = loc
|
||||
loc = destination
|
||||
Moved(oldloc, NONE)
|
||||
Moved(oldloc, direction)
|
||||
|
||||
/mob/dead/onTransitZ(old_z,new_z)
|
||||
..()
|
||||
|
||||
@@ -260,12 +260,10 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
setDir(direct)
|
||||
ghostimage.setDir(dir)
|
||||
|
||||
var/oldloc = loc
|
||||
|
||||
if(NewLoc)
|
||||
forceMove(NewLoc)
|
||||
forceMove(NewLoc, direct)
|
||||
else
|
||||
forceMove(get_turf(src)) //Get out of closets and such as a ghost
|
||||
forceMove(get_turf(src), direct) //Get out of closets and such as a ghost
|
||||
if((direct & NORTH) && y < world.maxy)
|
||||
y++
|
||||
else if((direct & SOUTH) && y > 1)
|
||||
@@ -275,8 +273,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
else if((direct & WEST) && x > 1)
|
||||
x--
|
||||
|
||||
Moved(oldloc, direct)
|
||||
|
||||
/mob/dead/observer/can_use_hands() return 0
|
||||
|
||||
/mob/dead/observer/Stat()
|
||||
|
||||
Reference in New Issue
Block a user