Commit Graph

10 Commits

Author SHA1 Message Date
c18eaf9bee Only expose velocity relative tp flags to API (#11532)
Since 1.21.2, vanilla split relative teleportation flags into position
and delta/velocity flags into separate enum entries.
This highlighted a design flaw in the paper api addition for teleport
flags, which just simply mirrored internals while also only being able
to apply the delta/velocity part of a flag, given the teleport target is
always absolute in the API.

This patch proposes to simply no longer expose the non-velocity related
flags to the API, instead marking the entire Relative enum as being
purely velocity related, as non-velocity related flags are not useful to
callers. This was done over simply exposing all internal flags, as
another vanilla change to the internal enum would result in the same
breakage.

The newly proposed API *only* promises that the passed flags prevent the
loss of velocity in the specific axis/context, which should be
independent enough of vanillas specific implementation of this feature.
2024-10-31 17:25:52 +01:00
aba71147db Finish API 2023-12-05 18:33:18 +01:00
46f4547805 Prepare for 1.20.3 dev 2023-12-05 18:20:55 +01:00
a60f62506f Un-experimentalize Entity TP APIs (#9964) 2023-11-28 11:40:25 -08:00
2ba17103b9 Fix some NPE for EntityCompostItemEvent (#9169) 2023-05-03 13:07:51 +02:00
8b4edb6f19 fix more compile errors 2023-03-14 16:10:18 -07:00
7936e7a615 API 'done' 2023-03-14 18:21:11 +01:00
08ab8edb76 Start working on 1.19.4 2023-03-14 18:11:24 +01:00
2dd20a5904 Add TeleportFlags (#8855)
Abstracts relative teleport flags and instead makes a generic TeleportFlag option. This has the benefit of being able to easily add new flags in the future.
This adds a new flag, which allows you to keep inventories open when teleporting players (vanilla behavior).

These are breaking changes to the teleport api, however, it's still marked as experimental so I find this a fair change.
2023-03-04 17:07:23 -05:00
09a1be7aef Teleportation API (#6562) 2022-07-22 14:36:43 -05:00