diff options
author | Linnea Gräf <nea@nea.moe> | 2024-04-02 02:38:25 +0200 |
---|---|---|
committer | Linnea Gräf <nea@nea.moe> | 2024-04-02 02:38:25 +0200 |
commit | 856d3242f34f7a787f02b086c0cb4b5b97eb34ca (patch) | |
tree | cca84191a5ba58090f88a4d3de6b83dcc991e589 /src/main/java/moe/nea | |
parent | ab30c1128b42eed24d0decf9ecf9e6a2c98a79e2 (diff) | |
download | potato-crimes-856d3242f34f7a787f02b086c0cb4b5b97eb34ca.tar.gz potato-crimes-856d3242f34f7a787f02b086c0cb4b5b97eb34ca.tar.bz2 potato-crimes-856d3242f34f7a787f02b086c0cb4b5b97eb34ca.zip |
Improve texture
Diffstat (limited to 'src/main/java/moe/nea')
-rw-r--r-- | src/main/java/moe/nea/potatocrime/mixin/OnEnterPotatoWorldPatch.java | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/main/java/moe/nea/potatocrime/mixin/OnEnterPotatoWorldPatch.java b/src/main/java/moe/nea/potatocrime/mixin/OnEnterPotatoWorldPatch.java new file mode 100644 index 0000000..7d41687 --- /dev/null +++ b/src/main/java/moe/nea/potatocrime/mixin/OnEnterPotatoWorldPatch.java @@ -0,0 +1,20 @@ +package moe.nea.potatocrime.mixin; + +import moe.nea.potatocrime.events.OnEnterPotatoWorld; +import net.minecraft.entity.Entity; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.injection.At; +import org.spongepowered.asm.mixin.injection.Inject; +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; + +@Mixin(Entity.class) +public class OnEnterPotatoWorldPatch { + @Inject(method = "tickPortal", at = @At( + value = "INVOKE", + target = "Lnet/minecraft/entity/Entity;moveToWorld(Lnet/minecraft/server/world/ServerWorld;Z)Lnet/minecraft/entity/Entity;", + shift = At.Shift.AFTER + )) + private void onMoveToWorld(CallbackInfo ci) { + OnEnterPotatoWorld.Companion.getEVENT().invoker().onEnterPotatoWorld((Entity) (Object) this); + } +} |