Creating a follower after using `setPosition` lags the worldSee original GitHub issue
I’ve currently got followers added in my game world. Followers can be added and removed with no problem.
However, when I attempt to use
setPosition before spawning a follower – everything functions well until said follower is spawned in. When the follower is spawned in, the world begins to lag uncontrollably.
Here is the bug in action:
I attempted to show you the bug occurring after spawning a follower and then using
setPosition, as well as using
setPosition prior to any follower spawning.
Note that my follower creation code is simply adding a character and using
.follow(). Remove is a bit more complicated than that, but the bug occurs prior to removing a follower.
This video also displays the bug occurring in #273.
- Created a year ago
- Comments:12 (7 by maintainers)
Top GitHub Comments
I was thinking of handling this locally, in the meantime, by setting a subscription to follower movements and determining the delta between playerPos and followerPos. If the delta was something like +5 or +10 tiles away, I would despawn the follower.