|
1 |
| -package com.minecrafttas.tasmod.mixin.events; |
2 |
| - |
3 |
| -import org.spongepowered.asm.mixin.Mixin; |
4 |
| -import org.spongepowered.asm.mixin.injection.At; |
5 |
| -import org.spongepowered.asm.mixin.injection.Inject; |
6 |
| -import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; |
7 |
| - |
8 |
| -import com.minecrafttas.mctcommon.events.EventClient.EventDoneLoadingPlayer; |
9 |
| -import com.minecrafttas.mctcommon.events.EventListenerRegistry; |
10 |
| - |
11 |
| -import net.minecraft.client.network.NetHandlerPlayClient; |
12 |
| - |
13 |
| -@Mixin(NetHandlerPlayClient.class) |
14 |
| -public class MixinNetHandlerPlayClient { |
15 |
| - |
16 |
| - @Inject(method = "handlePlayerPosLook", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/Minecraft;displayGuiScreen(Lnet/minecraft/client/gui/GuiScreen;)V")) |
17 |
| - public void event_handlePlayerPosLook(CallbackInfo ci) { |
18 |
| - EventListenerRegistry.fireEvent(EventDoneLoadingPlayer.class); |
19 |
| - } |
20 |
| -} |
| 1 | +package com.minecrafttas.tasmod.mixin.events; |
| 2 | + |
| 3 | +import org.spongepowered.asm.mixin.Mixin; |
| 4 | +import org.spongepowered.asm.mixin.injection.At; |
| 5 | +import org.spongepowered.asm.mixin.injection.Inject; |
| 6 | +import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; |
| 7 | + |
| 8 | +import com.minecrafttas.mctcommon.events.EventClient.EventDoneLoadingPlayer; |
| 9 | +import com.minecrafttas.mctcommon.events.EventListenerRegistry; |
| 10 | + |
| 11 | +import net.minecraft.client.network.NetHandlerPlayClient; |
| 12 | + |
| 13 | +@Mixin(NetHandlerPlayClient.class) |
| 14 | +public class MixinNetHandlerPlayClient { |
| 15 | + |
| 16 | + @Inject(method = "handlePlayerPosLook", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/Minecraft;displayGuiScreen(Lnet/minecraft/client/gui/GuiScreen;)V")) |
| 17 | + public void event_handlePlayerPosLook(CallbackInfo ci) { |
| 18 | + EventListenerRegistry.fireEvent(EventDoneLoadingPlayer.class); |
| 19 | + } |
| 20 | +} |
0 commit comments