Get rid of all the ATs in favor of Mixins
This commit is contained in:
@@ -10,6 +10,7 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||
//#if MC>=11400
|
||||
//$$ import com.replaymod.core.events.PreRenderHandCallback;
|
||||
//#else
|
||||
import com.replaymod.core.versions.MCVer;
|
||||
import net.minecraftforge.client.ForgeHooksClient;
|
||||
//#endif
|
||||
|
||||
@@ -20,15 +21,15 @@ import net.minecraftforge.client.ForgeHooksClient;
|
||||
}, remap = false)
|
||||
public abstract class MixinShadersRender {
|
||||
|
||||
@Inject(method = "renderHand0", at = @At("HEAD"), cancellable = true)
|
||||
@Inject(method = "renderHand0", at = @At("HEAD"), cancellable = true, remap = false)
|
||||
private static void replayModCompat_disableRenderHand0(GameRenderer er, float partialTicks, int renderPass, CallbackInfo ci) {
|
||||
//#if MC>=11400
|
||||
//$$ if (PreRenderHandCallback.EVENT.invoker().preRenderHand()) {
|
||||
//#else
|
||||
//#if MC>=11300
|
||||
if (ForgeHooksClient.renderFirstPersonHand(er.getMinecraft().renderGlobal, partialTicks)) {
|
||||
if (ForgeHooksClient.renderFirstPersonHand(MCVer.getMinecraft().renderGlobal, partialTicks)) {
|
||||
//#else
|
||||
//$$ if (ForgeHooksClient.renderFirstPersonHand(er.mc.renderGlobal, partialTicks, renderPass)) {
|
||||
//$$ if (ForgeHooksClient.renderFirstPersonHand(MCVer.getMinecraft().renderGlobal, partialTicks, renderPass)) {
|
||||
//#endif
|
||||
//#endif
|
||||
ci.cancel();
|
||||
|
||||
Reference in New Issue
Block a user