Fastcraft compat

#165
This commit is contained in:
FalsePattern committed 2025-06-09 18:41:34 +02:00
1 parent 76fdd16906
commit 7a6dd9adaa
8 files changed
+166

No files matched your search

@@ -0,0 +1,44 @@
/*
* EndlessIDs
*
* Copyright (C) 2022-2025 FalsePattern, The MEGA Team
* All Rights Reserved
*
* The above copyright notice, this permission notice and the word "MEGA"
* shall be included in all copies or substantial portions of the Software.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, only version 3 of the License.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
package com.falsepattern.endlessids.mixin.mixins.client.blockitem.fastcraft;
import org.spongepowered.asm.mixin.Dynamic;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Redirect;
import net.minecraft.client.renderer.EntityRenderer;
import net.minecraft.client.renderer.RenderGlobal;
import net.minecraft.entity.EntityLivingBase;
@Mixin(EntityRenderer.class)
public class EntityRendererMixin {
@Dynamic
@Redirect(method = "renderWorld",
at = @At(value = "INVOKE",
target = "Lfastcraft/HC;t(Lnet/minecraft/client/renderer/RenderGlobal;Lnet/minecraft/entity/EntityLivingBase;Z)Z",
remap = false))
private boolean killHook2(RenderGlobal rg, EntityLivingBase entity, boolean doUpdates) {
return rg.updateRenderers(entity, doUpdates);
}
}
@@ -54,6 +54,7 @@ import static com.falsepattern.endlessids.mixin.plugin.TargetedMod.EXTENDEDPLANE
import static com.falsepattern.endlessids.mixin.plugin.TargetedMod.EXTRAPLANETS;
import static com.falsepattern.endlessids.mixin.plugin.TargetedMod.EXTRAUTILITIES;
import static com.falsepattern.endlessids.mixin.plugin.TargetedMod.FACTORIZATION;
import static com.falsepattern.endlessids.mixin.plugin.TargetedMod.FASTCRAFT;
import static com.falsepattern.endlessids.mixin.plugin.TargetedMod.FUTUREPACK;
import static com.falsepattern.endlessids.mixin.plugin.TargetedMod.GADOMANCY;
import static com.falsepattern.endlessids.mixin.plugin.TargetedMod.GALACTICRAFTCORE;
@@ -353,6 +354,8 @@ public class Mixin {
blockitem_vanilla_NetHandlerPlayClientMixin(EXT_BLOCK_ITEM),
blockitem_vanilla_PlayerControllerMPMixin(EXT_BLOCK_ITEM),
blockitem_vanilla_RenderGlobalMixin(EXT_BLOCK_ITEM),
blockitem_fastcraft_EntityRendererMixin(EXT_BLOCK_ITEM, require(FASTCRAFT)),
//endregion
//region potion
@@ -55,6 +55,7 @@ public enum TargetedMod implements ITargetedMod {
EXTRAPLANETS("Extra Planets", false, contains("extraplanets-")),
EXTRAUTILITIES("Extra Utilities", false, contains("extrautilities-")),
FACTORIZATION("Factorization", false, contains("factorization-")),
FASTCRAFT("Fastcraft", false, contains("fastcraft-")),
FUTUREPACK("Futurepack", false, contains("futurepack")),
GADOMANCY("Gadomancy", false, contains("gadomancy-")),
GALACTICRAFTCORE("GalactiCraftCore", false, contains("galacticraftcore")),