Sulphuric rock furnace, shaders, furnaces tag
|
@ -18,12 +18,16 @@ import net.minecraft.util.registry.Registry;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.entities.EFurnaceBlockEntity;
|
import ru.betterend.blocks.entities.EFurnaceBlockEntity;
|
||||||
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class EndFurnaceBlock extends FurnaceBlock implements BlockPatterned {
|
public class EndFurnaceBlock extends FurnaceBlock implements BlockPatterned, IRenderTypeable {
|
||||||
public EndFurnaceBlock(Block source) {
|
public EndFurnaceBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source));
|
super(FabricBlockSettings.copyOf(source).luminance((state) -> {
|
||||||
|
return state.get(LIT) ? 13 : 0;
|
||||||
|
}));
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -48,18 +52,28 @@ public class EndFurnaceBlock extends FurnaceBlock implements BlockPatterned {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String getModelPattern(String block) {
|
public String getModelPattern(String block) {
|
||||||
String add = block.contains("_on") ? "_on" : "";
|
|
||||||
Identifier blockId = Registry.BLOCK.getId(this);
|
Identifier blockId = Registry.BLOCK.getId(this);
|
||||||
Map<String, String> map = Maps.newHashMap();
|
Map<String, String> map = Maps.newHashMap();
|
||||||
map.put("%top%", blockId.getPath() + "_top");
|
map.put("%top%", blockId.getPath() + "_top");
|
||||||
map.put("%front%", blockId.getPath() + "_front" + add);
|
|
||||||
map.put("%side%", blockId.getPath() + "_side");
|
map.put("%side%", blockId.getPath() + "_side");
|
||||||
map.put("%bottom%", blockId.getPath() + "_bottom");
|
if (block.contains("_on")) {
|
||||||
return Patterns.createJson(Patterns.BLOCK_FURNACE, map);
|
map.put("%front%", blockId.getPath() + "_front_on");
|
||||||
|
map.put("%glow%", blockId.getPath() + "_glow");
|
||||||
|
return Patterns.createJson(Patterns.BLOCK_FURNACE_GLOW, map);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
map.put("%front%", blockId.getPath() + "_front");
|
||||||
|
return Patterns.createJson(Patterns.BLOCK_FURNACE, map);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Identifier statePatternId() {
|
public Identifier statePatternId() {
|
||||||
return Patterns.STATE_FURNACE;
|
return Patterns.STATE_FURNACE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public ERenderLayer getRenderLayer() {
|
||||||
|
return ERenderLayer.CUTOUT;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,6 +40,7 @@ import ru.betterend.recipe.builders.GridRecipe;
|
||||||
import ru.betterend.recipe.builders.SmithingTableRecipe;
|
import ru.betterend.recipe.builders.SmithingTableRecipe;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndItems;
|
import ru.betterend.registry.EndItems;
|
||||||
|
import ru.betterend.registry.EndTags;
|
||||||
import ru.betterend.util.TagHelper;
|
import ru.betterend.util.TagHelper;
|
||||||
|
|
||||||
public class MetalMaterial {
|
public class MetalMaterial {
|
||||||
|
@ -198,5 +199,6 @@ public class MetalMaterial {
|
||||||
GridRecipe.make(name + "_boots", boots).setShape("# #", "# #").addMaterial('#', ingot).setGroup("end_metal_boots").build();
|
GridRecipe.make(name + "_boots", boots).setShape("# #", "# #").addMaterial('#', ingot).setGroup("end_metal_boots").build();
|
||||||
|
|
||||||
TagHelper.addTag(BlockTags.ANVIL, anvil);
|
TagHelper.addTag(BlockTags.ANVIL, anvil);
|
||||||
|
TagHelper.addTag(EndTags.IRON_INGOTS, ingot);
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -90,6 +90,7 @@ public class StoneMaterial {
|
||||||
TagHelper.addTag(ItemTags.STONE_BRICKS, bricks);
|
TagHelper.addTag(ItemTags.STONE_BRICKS, bricks);
|
||||||
TagHelper.addTag(ItemTags.STONE_CRAFTING_MATERIALS, stone);
|
TagHelper.addTag(ItemTags.STONE_CRAFTING_MATERIALS, stone);
|
||||||
TagHelper.addTag(ItemTags.STONE_TOOL_MATERIALS, stone);
|
TagHelper.addTag(ItemTags.STONE_TOOL_MATERIALS, stone);
|
||||||
|
TagHelper.addTag(EndTags.FURNACES, furnace);
|
||||||
|
|
||||||
// Block Tags //
|
// Block Tags //
|
||||||
TagHelper.addTag(BlockTags.STONE_BRICKS, bricks);
|
TagHelper.addTag(BlockTags.STONE_BRICKS, bricks);
|
||||||
|
|
|
@ -99,6 +99,7 @@ public class Patterns {
|
||||||
public final static Identifier BLOCK_CHANDELIER_WALL = BetterEnd.makeID("patterns/block/chandelier_wall.json");
|
public final static Identifier BLOCK_CHANDELIER_WALL = BetterEnd.makeID("patterns/block/chandelier_wall.json");
|
||||||
public final static Identifier BLOCK_CHANDELIER_CEIL = BetterEnd.makeID("patterns/block/chandelier_ceil.json");
|
public final static Identifier BLOCK_CHANDELIER_CEIL = BetterEnd.makeID("patterns/block/chandelier_ceil.json");
|
||||||
public final static Identifier BLOCK_FURNACE = BetterEnd.makeID("patterns/block/furnace.json");
|
public final static Identifier BLOCK_FURNACE = BetterEnd.makeID("patterns/block/furnace.json");
|
||||||
|
public final static Identifier BLOCK_FURNACE_GLOW = BetterEnd.makeID("patterns/block/furnace_glow.json");
|
||||||
|
|
||||||
//Models Item
|
//Models Item
|
||||||
public final static Identifier ITEM_WALL = BetterEnd.makeID("patterns/item/pattern_wall.json");
|
public final static Identifier ITEM_WALL = BetterEnd.makeID("patterns/item/pattern_wall.json");
|
||||||
|
|
|
@ -40,7 +40,7 @@ public class CraftingRecipes {
|
||||||
.setShape("T#T", "V V", "T#T")
|
.setShape("T#T", "V V", "T#T")
|
||||||
.addMaterial('#', Blocks.END_STONE_BRICKS)
|
.addMaterial('#', Blocks.END_STONE_BRICKS)
|
||||||
.addMaterial('T', EndBlocks.THALLASIUM.ingot)
|
.addMaterial('T', EndBlocks.THALLASIUM.ingot)
|
||||||
.addMaterial('V', Items.BUCKET)
|
.addMaterial('V', EndTags.FURNACES)
|
||||||
.build();
|
.build();
|
||||||
|
|
||||||
registerPedestal("andesite_pedestal", EndBlocks.ANDESITE_PEDESTAL, Blocks.POLISHED_ANDESITE_SLAB, Blocks.POLISHED_ANDESITE);
|
registerPedestal("andesite_pedestal", EndBlocks.ANDESITE_PEDESTAL, Blocks.POLISHED_ANDESITE_SLAB, Blocks.POLISHED_ANDESITE);
|
||||||
|
|
|
@ -29,6 +29,9 @@ import ru.betterend.mixin.common.ComposterBlockAccessor;
|
||||||
import ru.betterend.util.TagHelper;
|
import ru.betterend.util.TagHelper;
|
||||||
|
|
||||||
public class EndTags {
|
public class EndTags {
|
||||||
|
// Table with common (c) tags:
|
||||||
|
// https://fabricmc.net/wiki/tutorial:tags
|
||||||
|
|
||||||
// Block Tags
|
// Block Tags
|
||||||
public static final Tag.Identified<Block> BOOKSHELVES = makeCommonBlockTag("bookshelves");
|
public static final Tag.Identified<Block> BOOKSHELVES = makeCommonBlockTag("bookshelves");
|
||||||
public static final Tag.Identified<Block> GEN_TERRAIN = makeBlockTag("gen_terrain");
|
public static final Tag.Identified<Block> GEN_TERRAIN = makeBlockTag("gen_terrain");
|
||||||
|
@ -39,6 +42,8 @@ public class EndTags {
|
||||||
|
|
||||||
// Item Tags
|
// Item Tags
|
||||||
public static final Tag.Identified<Item> ITEM_CHEST = makeCommonItemTag("chest");
|
public static final Tag.Identified<Item> ITEM_CHEST = makeCommonItemTag("chest");
|
||||||
|
public static final Tag.Identified<Item> IRON_INGOTS = makeCommonItemTag("iron_ingots");
|
||||||
|
public static final Tag.Identified<Item> FURNACES = makeCommonItemTag("furnaces");
|
||||||
public final static Tag<Item> HAMMERS = registerFabricItemTag("hammers");
|
public final static Tag<Item> HAMMERS = registerFabricItemTag("hammers");
|
||||||
|
|
||||||
public static Tag.Identified<Block> makeBlockTag(String name) {
|
public static Tag.Identified<Block> makeBlockTag(String name) {
|
||||||
|
@ -106,6 +111,8 @@ public class EndTags {
|
||||||
EndBlocks.TERMINITE.hammer
|
EndBlocks.TERMINITE.hammer
|
||||||
)
|
)
|
||||||
));
|
));
|
||||||
|
|
||||||
|
TagHelper.addTag(FURNACES, Blocks.FURNACE);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void addSurfaceBlock(Block block) {
|
public static void addSurfaceBlock(Block block) {
|
||||||
|
|
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
"defaultMap": {
|
||||||
|
"spriteMap": [
|
||||||
|
{
|
||||||
|
"sprite": "betterend:block/flavolite_furnace_glow",
|
||||||
|
"material": "betterend:glow_all"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
"defaultMap": {
|
||||||
|
"spriteMap": [
|
||||||
|
{
|
||||||
|
"sprite": "betterend:block/sulphuric_rock_furnace_glow",
|
||||||
|
"material": "betterend:glow_all"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
"defaultMap": {
|
||||||
|
"spriteMap": [
|
||||||
|
{
|
||||||
|
"sprite": "betterend:block/violecite_furnace_glow",
|
||||||
|
"material": "betterend:glow_all"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,38 @@
|
||||||
|
{
|
||||||
|
"parent": "block/block",
|
||||||
|
"textures": {
|
||||||
|
"top": "betterend:block/%top%",
|
||||||
|
"front": "betterend:block/%front%",
|
||||||
|
"side": "betterend:block/%side%",
|
||||||
|
"glow": "betterend:block/%glow%"
|
||||||
|
},
|
||||||
|
"display": {
|
||||||
|
"firstperson_righthand": {
|
||||||
|
"rotation": [ 0, 135, 0 ],
|
||||||
|
"translation": [ 0, 0, 0 ],
|
||||||
|
"scale": [ 0.40, 0.40, 0.40 ]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"elements": [
|
||||||
|
{
|
||||||
|
"from": [ 0, 0, 0 ],
|
||||||
|
"to": [ 16, 16, 16 ],
|
||||||
|
"faces": {
|
||||||
|
"down": { "texture": "#top", "cullface": "down" },
|
||||||
|
"up": { "texture": "#top", "cullface": "up" },
|
||||||
|
"north": { "texture": "#front", "cullface": "north" },
|
||||||
|
"south": { "texture": "#side", "cullface": "south" },
|
||||||
|
"west": { "texture": "#side", "cullface": "west" },
|
||||||
|
"east": { "texture": "#side", "cullface": "east" }
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"from": [ 0, 0, 0 ],
|
||||||
|
"to": [ 16, 16, 16 ],
|
||||||
|
"shade": false,
|
||||||
|
"faces": {
|
||||||
|
"north": { "texture": "#glow", "cullface": "north" }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 2.6 KiB |
After Width: | Height: | Size: 2 KiB |
After Width: | Height: | Size: 530 B |
After Width: | Height: | Size: 2 KiB |
After Width: | Height: | Size: 2 KiB |
After Width: | Height: | Size: 479 B |
After Width: | Height: | Size: 438 B |
Before Width: | Height: | Size: 2.2 KiB After Width: | Height: | Size: 2.4 KiB |
After Width: | Height: | Size: 2 KiB |
|
@ -0,0 +1,12 @@
|
||||||
|
{
|
||||||
|
"animation": {
|
||||||
|
"interpolate": true,
|
||||||
|
"frametime": 8,
|
||||||
|
"frames": [
|
||||||
|
0,
|
||||||
|
1,
|
||||||
|
2,
|
||||||
|
3
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|