Repository navigation
Add PlayerPreTeleportEvent - #12879
RandomTomato wants to merge 8 commits into
Conversation
|
The goal really is to align with the vanilla teleport logic rather than the CB logic and having a bunch of hacks Really iffy on these sorts of events. Adding in early mutation points for stuff they don't really need, like the Location, is kinda bleh. Nor should we really be returning mutable location objects in the API There is zero info on whether a teleport will succeed or not, which feels like it kinda misses the bar in terms of what it's trying to solve |
hello 👋🏻 Thank you for your reply! I understand that the goal is to align with the vanilla logic. This was mentioned by Malfrador in #12093 a feature request that I made a while ago and we both spoke in. I also agree with not having a bunch of hacks/work arounds, but if there is no intention of implementing/aligning with the vanilla teleport logic (as its been nearly two years since the last pull request #10173 with a similar goal was created). Is it possible to be implemented and then deprecated when moved over? Also if the |
|
It's also questionable if such an event should be cancellable. But yeah, when working on #10173 I more and more realised that such an event doesn't really make much sense in a way to justify adding it. However, as stated and discussed in my PR a |
I am personally happy with either approach. 🤷🏻♂️ EDIT: If its decided to go down the path of |
…yerPreTeleportEvent
|
Closed because I messed up rebasing and duplicated my commits 😔😭 |
Adds
PlayerPreTeleportEventto address various issues with teleporting mentioned in #12093, #10168 & #10173.Currently there is no way to handle teleporting players cross-worlds with vehicles and passengers as the
PlayerTeleportEventfires after the checks for vehicles and passengers.Implementing this event would allow for intercepting teleports before vehicle/passenger checks occur allowing for the correct handling of the vehicle/passengers when teleporting (specifically cross worlds) as there is currently no way to know if a teleport failed because of this.
Hopefully this event can be added as its been a while since the last discussion about this and it seemed like a lot of people wanted this. 😁 (I can also add EntityPreTeleportEvent if needed!)