Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #279: Add spectate check to stop_follow #285

Conversation

Cooldude2606
Copy link
Member

Fixes the issue of spawning a new character when spectate is stopped while follow is active. This was caused by the following logic path:

  1. stop_spectate would return you to your orginal body.
  2. on_tick for follow would see you had a character and attempt to stop itself with stop_follow
  3. Because start_spectate was successful in start_follow it assumes that stop_spectate needs to be called.
  4. However, because it has already been called once it now has no reference to your character, this triggers a respawn.
  5. Respawning disconnects your orginal body and gives you a new one.

@Cooldude2606 Cooldude2606 mentioned this pull request Feb 5, 2024
@Cooldude2606 Cooldude2606 linked an issue Feb 5, 2024 that may be closed by this pull request
@Cooldude2606 Cooldude2606 merged commit 65e254e into explosivegaming:dev Feb 11, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Spectate after Follow embodies you
1 participant