From 52bb8ef4aaa8cf6c48d40ff6dd1f4b7a3e9e4bf3 Mon Sep 17 00:00:00 2001 From: i509VCB Date: Thu, 9 Jul 2020 03:00:39 -0700 Subject: [PATCH] Thinking with portals (part 1) (#1569) * Thinking with portals (part 1) * match the method name to return type --- mappings/net/minecraft/entity/Entity.mapping | 13 ++++++++++++- .../server/network/ServerPlayerEntity.mapping | 6 +++++- mappings/net/minecraft/world/TeleportTarget.mapping | 10 ++++++++++ 3 files changed, 27 insertions(+), 2 deletions(-) create mode 100644 mappings/net/minecraft/world/TeleportTarget.mapping diff --git a/mappings/net/minecraft/entity/Entity.mapping b/mappings/net/minecraft/entity/Entity.mapping index 772c21462e..4aa652f2e6 100644 --- a/mappings/net/minecraft/entity/Entity.mapping +++ b/mappings/net/minecraft/entity/Entity.mapping @@ -227,6 +227,12 @@ CLASS net/minecraft/class_1297 net/minecraft/entity/Entity ARG 1 onGround METHOD method_25936 getLandingBlockState ()Lnet/minecraft/class_2680; METHOD method_27298 shouldSpawnSprintingParticles ()Z + METHOD method_30329 getTeleportTarget (Lnet/minecraft/class_3218;)Lnet/minecraft/class_5454; + ARG 1 destination + METHOD method_30333 getTeleportationScale (Lnet/minecraft/class_2874;Lnet/minecraft/class_2874;)D + COMMENT Gets the teleportation scale between two dimensions. + ARG 0 origin + ARG 1 destination METHOD method_5621 getMountedHeightOffset ()D METHOD method_5622 onBlockCollision (Lnet/minecraft/class_2680;)V ARG 1 state @@ -428,7 +434,12 @@ CLASS net/minecraft/class_1297 net/minecraft/entity/Entity ARG 1 index ARG 2 value METHOD method_5730 setOnFireFromLava ()V - METHOD method_5731 changeDimension (Lnet/minecraft/class_3218;)Lnet/minecraft/class_1297; + METHOD method_5731 moveToWorld (Lnet/minecraft/class_3218;)Lnet/minecraft/class_1297; + COMMENT Moves this entity to another world. + COMMENT + COMMENT

Note all entities except server player entities are completely recreated at the destination. + COMMENT + COMMENT @return the entity in the other world ARG 1 destination METHOD method_5732 isAttackable ()Z METHOD method_5733 shouldRenderName ()Z diff --git a/mappings/net/minecraft/server/network/ServerPlayerEntity.mapping b/mappings/net/minecraft/server/network/ServerPlayerEntity.mapping index 84d54c6cd4..aedf5eeeac 100644 --- a/mappings/net/minecraft/server/network/ServerPlayerEntity.mapping +++ b/mappings/net/minecraft/server/network/ServerPlayerEntity.mapping @@ -112,7 +112,7 @@ CLASS net/minecraft/class_3222 net/minecraft/server/network/ServerPlayerEntity ARG 2 hash METHOD method_17668 setCameraPosition (Lnet/minecraft/class_4076;)V ARG 1 cameraPosition - METHOD method_18783 dimensionChanged (Lnet/minecraft/class_3218;)V + METHOD method_18783 worldChanged (Lnet/minecraft/class_3218;)V ARG 1 targetWorld METHOD method_26280 getSpawnPointPosition ()Lnet/minecraft/class_2338; METHOD method_26281 getSpawnPointDimension ()Lnet/minecraft/class_5321; @@ -130,3 +130,7 @@ CLASS net/minecraft/class_3222 net/minecraft/server/network/ServerPlayerEntity METHOD method_26287 isBedTooFarAway (Lnet/minecraft/class_2338;)Z ARG 1 pos METHOD method_29779 forgiveMobAnger ()V + METHOD method_30313 createEndSpawnPlatform (Lnet/minecraft/class_3218;Lnet/minecraft/class_2338;)V + ARG 1 world + ARG 2 centerPos + METHOD method_5731 moveToWorld (Lnet/minecraft/class_3218;)Lnet/minecraft/class_1297; diff --git a/mappings/net/minecraft/world/TeleportTarget.mapping b/mappings/net/minecraft/world/TeleportTarget.mapping new file mode 100644 index 0000000000..b13a89d16f --- /dev/null +++ b/mappings/net/minecraft/world/TeleportTarget.mapping @@ -0,0 +1,10 @@ +CLASS net/minecraft/class_5454 net/minecraft/world/TeleportTarget + FIELD field_25879 position Lnet/minecraft/class_243; + FIELD field_25880 velocity Lnet/minecraft/class_243; + FIELD field_25881 yaw F + FIELD field_25882 pitch F + METHOD (Lnet/minecraft/class_243;Lnet/minecraft/class_243;FF)V + ARG 1 position + ARG 2 velocity + ARG 3 yaw + ARG 4 pitch