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
+4
View File
@@ -69,6 +69,8 @@
orbiter.orbiting.end_orbit(orbiter)
orbiter_list[orbiter] = TRUE
orbiter.orbiting = src
ADD_TRAIT(orbiter, TRAIT_NO_FLOATING_ANIM, ORBITING_TRAIT)
RegisterSignal(orbiter, COMSIG_MOVABLE_MOVED, .proc/orbiter_move_react)
SEND_SIGNAL(parent, COMSIG_ATOM_ORBIT_BEGIN, orbiter)
@@ -118,6 +120,8 @@
orbiter_mob.updating_glide_size = TRUE
orbiter_mob.glide_size = 8
REMOVE_TRAIT(orbiter, TRAIT_NO_FLOATING_ANIM, ORBITING_TRAIT)
if(!refreshing && !length(orbiter_list) && !QDELING(src))
qdel(src)