Fixes ghosts orbit animations not being reliable for the no floating trait (#65051)

Moved all the logic of adding the TRAIT_NO_FLOATING_ANIM to the orbiter component.
This commit is contained in:
GoldenAlpharex
2022-02-21 20:12:44 -06:00
committed by GitHub
parent 396a065b47
commit 686e29cf29
3 changed files with 6 additions and 4 deletions
@@ -493,14 +493,12 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
/mob/dead/observer/orbit()
setDir(2)//reset dir so the right directional sprites show up
ADD_TRAIT(src, TRAIT_NO_FLOATING_ANIM, GHOST_ORBITING_TRAIT)
return ..()
/mob/dead/observer/stop_orbit(datum/component/orbiter/orbits)
. = ..()
//restart our floating animation after orbit is done.
pixel_y = base_pixel_y
REMOVE_TRAIT(src, TRAIT_NO_FLOATING_ANIM, GHOST_ORBITING_TRAIT)
/mob/dead/observer/verb/jumptomob() //Moves the ghost instead of just changing the ghosts's eye -Nodrak
set category = "Ghost"