Skip to content

Commit

Permalink
fix: ETF crash
Browse files Browse the repository at this point in the history
  • Loading branch information
IMB11 committed Jul 2, 2024
1 parent c34a33b commit f4599a2
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 1 deletion.
1 change: 1 addition & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ dependencies {
modImplementation "net.fabricmc.fabric-api:fabric-api:${property('deps.fabric_api')}"

modLocalRuntime modCompileOnly("maven.modrinth:modmenu:${property('runtime.modmenu')}")
modLocalRuntime modCompileOnly("maven.modrinth:entitytexturefeatures:${property('runtime.etf')}")

include implementation('com.konghq:unirest-java:3.11.09:standalone')

Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
org.gradle.jvmargs=-Xmx1G

deps.loader=0.15.11
mod.version=2.0.0
mod.version=2.0.1
mod.name=SkinShuffle
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@

package com.mineblock11.skinshuffle.client.gui.cursed;

import com.mineblock11.skinshuffle.compat.ETFCompat;
import com.mojang.blaze3d.systems.RenderSystem;
import net.fabricmc.loader.api.FabricLoader;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.render.DiffuseLighting;
import net.minecraft.client.render.VertexConsumerProvider;
Expand Down Expand Up @@ -75,6 +77,10 @@ public static void drawEntity(MatrixStack matrices, int x, int y, int size, floa
}
dispatcher.setRenderShadows(false);

if(FabricLoader.getInstance().isModLoaded("entity_texture_features")) {
ETFCompat.preventRenderLayerIssue();
}

VertexConsumerProvider.Immediate vertexConsumers = MinecraftClient.getInstance().getBufferBuilders().getEntityVertexConsumers();
dispatcher.render(entity, 0.0, 0.0, 0.0, 0.0f, 1.0f, matrices, vertexConsumers, 0xF000F0);
vertexConsumers.draw();
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
package com.mineblock11.skinshuffle.compat;

import traben.entity_texture_features.features.ETFRenderContext;

public class ETFCompat {
public static void preventRenderLayerIssue() {
ETFRenderContext.preventRenderLayerTextureModify();
}
}
1 change: 1 addition & 0 deletions versions/1.20.1/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
runtime.modmenu=7.2.2
runtime.etf=Iqpdkpj4

mod.target=>=1.20 <=1.20.1

Expand Down
1 change: 1 addition & 0 deletions versions/1.20.4/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
runtime.modmenu=9.2.0
runtime.etf=A9d30Vws

mod.target=>=1.20.3 <=1.20.4

Expand Down
1 change: 1 addition & 0 deletions versions/1.20.6/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
runtime.modmenu=10.0.0
runtime.etf=aUpC497W

mod.target=>=1.20.5 <=1.20.6

Expand Down
1 change: 1 addition & 0 deletions versions/1.21/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
runtime.modmenu=11.0.1
runtime.etf=8czGsT2L

mod.target=1.21

Expand Down

0 comments on commit f4599a2

Please sign in to comment.