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: Teleporting Players to Spawn on Login with teleportUnAuthedToSpawn=true #2823

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Subu19
Copy link

@Subu19 Subu19 commented May 20, 2024

Issue: When changing the config option teleportUnAuthedToSpawn=true during midgame, players were teleported to spawn on their next login. It only happens once after the update.

Patch: AuthMe now checks the player's last logout location from Essentials if it is not found in the AuthMe database. This ensures players are teleported to their last known location instead of the spawn point when the configuration is changed mid-game.

Subu19 added 2 commits May 20, 2024 17:04
…wn=true

Issue: When changing the config option teleportUnAuthedToSpawn=true during gameplay, players were teleported to spawn on their next login. It only happens for the first time after the update.

Patch: AuthMe now checks the player's last logout location from Essentials if it is not found in the AuthMe database. This ensures players are teleported to their last known location instead of the spawn point when the configuration is changed mid-game.
@ghost
Copy link

ghost commented May 20, 2024

if there are no essentials

@Subu19
Copy link
Author

Subu19 commented May 21, 2024

if there are no essentials

You are right, this solution only works if Essentials is installed.
The original code looks okay, it does try to teleport to LimboPlayer's original location after logging in if the last location is not found in the authme's database. I don't know if this was intentional or not, LamboPlayer is initiated after teleporting the player. We could fix this issue if we store the original location of the player in LimboPlayer.

@ghost
Copy link

ghost commented May 21, 2024

https://github.com/F3F5/SpawnAuth my solution

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant