Closed Athamex closed 1 year ago
Probably your teleport plugin doesn't trigger the teleport event for some reason.
I use towny plugin for /t spawn
Can you try other teleport commands to see if the bug happens anyway?
I try /spawn with essentials no problem
Towny's /t spawn command is ran with a TeleportCause.COMMAND, what is your teleport listener listening for @LoneDev6 ?
Also /n spawn is invisibility bug. I have a video https://clipchamp.com/watch/kxPtNokkvN0
Towny's /t spawn command is ran with a TeleportCause.COMMAND, what is your teleport listener listening for @LoneDev6 ?
Thanks for the info, I'll try to see if this could be the cause and keep you updated about my tests.
Towny's /t spawn command is ran with a TeleportCause.COMMAND, what is your teleport listener listening for @LoneDev6 ?
@EventHandler(ignoreCancelled = true, priority = EventPriority.MONITOR)
private void onPlayerTeleport(PlayerTeleportEvent e)
I only check this and cancel if true.
e.getCause() == PlayerTeleportEvent.TeleportCause.PLUGIN
PaperLib.teleportAsync(player, spawnLoc, TeleportCause.COMMAND);
https://github.com/PaperMC/PaperLib/blob/0621f6d90002bd7d873bc7a1b65b281e685d7063/src/main/java/io/papermc/lib/features/asyncteleport/AsyncTeleportPaper_13.java
It should actually trigger I think onPlayerTeleport. I have no idea why this doesn't work.
I would consider using PLUGIN and COMMAND causes for your setup. Some plugins use PLUGIN, some use COMMAND, some use both (like Towny.) Since you're wanting to track teleports I would listen to both.
I only check this and cancel if true.
I already do that
You are checking if the TeleportCause is PLUGIN, but are you also checking if e.getCause() == PlayerTeleportEvent.TeleportCause.COMMAND
?
It might be fixed in the upcoming update, please let me know as soon as I release the update.
Terms
Discord tag (optional)
Athame#4912
What happened?
If I type /t spawn while in the wardrobe, I become invisible.
Steps to reproduce the issue
Just bug
Server version
1.17.1
CosmeticsCore Version
1.0.5
ProtocolLib Version
4.8.0
LoneLibs Version
1.0.21
FULL server log
No response
Error (optional)
No response
CosmeticsCore config.yml
No response
Problematic items yml configuration file (optional)
No response
Other files, you can drag and drop them here to upload. (optional)
No response
Screenshots/Videos (you can drag and drop files or paste links)
No response