Skip to content

Commit

Permalink
Merge branch 'spiralhalo-1.20' into 1.20
Browse files Browse the repository at this point in the history
  • Loading branch information
FoundationGames committed Jun 26, 2023
2 parents 2e21b8f + 32f8ddc commit 87c16e5
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 30 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ public static void setupRRPSigns() {
ResourceUtil.addSignBlockStates("crimson_sign", "crimson_wall_sign", p);
ResourceUtil.addSignBlockStates("warped_sign", "warped_wall_sign", p);
ResourceUtil.addSignBlockStates("bamboo_sign", "bamboo_wall_sign", p);
ResourceUtil.addSignBlockStates("cherry_sign", "cherry_wall_sign", p);

ResourceUtil.addHangingSignBlockStates("oak_hanging_sign", "oak_wall_hanging_sign", p);
ResourceUtil.addHangingSignBlockStates("birch_hanging_sign", "birch_wall_hanging_sign", p);
Expand All @@ -93,7 +92,6 @@ public static void setupRRPSigns() {
ResourceUtil.addHangingSignBlockStates("crimson_hanging_sign", "crimson_wall_hanging_sign", p);
ResourceUtil.addHangingSignBlockStates("warped_hanging_sign", "warped_wall_hanging_sign", p);
ResourceUtil.addHangingSignBlockStates("bamboo_hanging_sign", "bamboo_wall_hanging_sign", p);
ResourceUtil.addHangingSignBlockStates("cherry_hanging_sign", "cherry_wall_hanging_sign", p);

p = ResourceUtil.getBasePack();

Expand All @@ -108,7 +106,6 @@ public static void setupRRPSigns() {
ResourceUtil.addSignTypeModels("crimson", p);
ResourceUtil.addSignTypeModels("warped", p);
ResourceUtil.addSignTypeModels("bamboo", p);
ResourceUtil.addSignTypeModels("cherry", p);

p.addDirBlockSprites("entity/signs", "entity/signs/");
p.addDirBlockSprites("entity/signs/hanging", "entity/signs/hanging/");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,8 @@
import net.minecraft.block.AbstractSignBlock;
import net.minecraft.block.entity.BlockEntity;
import net.minecraft.block.entity.SignBlockEntity;
import net.minecraft.client.MinecraftClient;
import net.minecraft.client.font.TextRenderer;
import net.minecraft.client.model.ModelPart;
import net.minecraft.client.render.VertexConsumerProvider;
import net.minecraft.client.render.block.entity.BlockEntityRenderer;
import net.minecraft.client.render.block.entity.BlockEntityRendererFactory;
import net.minecraft.client.render.block.entity.SignBlockEntityRenderer;
import net.minecraft.client.render.entity.model.EntityModelLayer;
import net.minecraft.client.render.entity.model.EntityModelLoader;
import net.minecraft.client.util.math.MatrixStack;

public class SignBlockEntityRendererOverride extends BlockEntityRendererOverride {
Expand All @@ -30,23 +23,4 @@ public void render(BlockEntityRenderer<BlockEntity> renderer, BlockEntity blockE
textRenderer.enhanced_bes$renderText(entity.getPos(), entity.getBackText(), matrices, vertexConsumers, light, entity.getTextLineHeight(), entity.getMaxTextWidth(), false);
}
}

public static class DummyRenderContext extends BlockEntityRendererFactory.Context {
private static final EntityModelLoader DUMMY_LOADER = new EntityModelLoader() {
@Override
public ModelPart getModelPart(EntityModelLayer layer) {
return SignBlockEntityRenderer.getTexturedModelData().createModel();
}
};

public DummyRenderContext() {
super(null, null, null, null,
DUMMY_LOADER, null);
}

@Override
public TextRenderer getTextRenderer() {
return MinecraftClient.getInstance().textRenderer;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@ public static void setupSigns(ResourceManager manager) throws IOException {
ResourceHacks.addSignParticleTexture("crimson", "entity/signs/crimson", manager, p);
ResourceHacks.addSignParticleTexture("warped", "entity/signs/warped", manager, p);
ResourceHacks.addSignParticleTexture("bamboo", "entity/signs/bamboo", manager, p);
ResourceHacks.addSignParticleTexture("cherry", "entity/signs/cherry", manager, p);
}

public static void cacheResources(ResourceManager resources) {
Expand Down

0 comments on commit 87c16e5

Please sign in to comment.