From 156a401bd7ce954fadc018307231d21f538100aa Mon Sep 17 00:00:00 2001 From: xzeldon Date: Thu, 11 Aug 2022 10:51:02 +0300 Subject: [PATCH] More blocks! * - Refactoring - Add black, blue, cyan, purple, red, white and yellow chroma blocks - Rename mod --- README.md | 9 +- gradle.properties | 6 +- .../ru/xzeldon/chromablocks/ChromaBlocks.java | 16 +++ .../ChromaBlocksClient.java} | 8 +- .../block/ChromaBlocksBlockRegister.java | 117 +++++++++++++++++ .../block/custom/ChromaBlock.java} | 8 +- .../block/custom/ChromaBlockDim.java | 7 ++ .../item/ChromaBlocksItemsGroup.java | 13 ++ .../model/ChromaBlockModel.java} | 11 +- .../model/ChromaBlockModelProvider.java | 119 ++++++++++++++++++ .../model/custom/BlackChromaBlockModel.java | 9 ++ .../model/custom/BlueChromaBlockModel.java | 9 ++ .../model/custom/CyanChromaBlockModel.java | 9 ++ .../model/custom/GreenChromaBlockModel.java | 9 ++ .../model/custom/PurpleChromaBlockModel.java | 9 ++ .../model/custom/RedChromaBlockModel.java | 9 ++ .../model/custom/WhiteChromaBlockModel.java | 9 ++ .../model/custom/YellowChromaBlockModel.java | 9 ++ .../greenscreenmod/GreenScreenMod.java | 16 --- .../block/GreenScreenBlocks.java | 39 ------ .../block/custom/GreenScreenBlockDim.java | 7 -- .../model/GreenScreenModelProvider.java | 34 ----- .../blockstates/chroma_black.json | 7 ++ .../blockstates/chroma_black_dim.json | 7 ++ .../chromablocks/blockstates/chroma_blue.json | 7 ++ .../blockstates/chroma_blue_dim.json | 7 ++ .../chromablocks/blockstates/chroma_cyan.json | 7 ++ .../blockstates/chroma_cyan_dim.json | 7 ++ .../blockstates/chroma_green.json | 7 ++ .../blockstates/chroma_green_dim.json | 7 ++ .../blockstates/chroma_purple.json | 7 ++ .../blockstates/chroma_purple_dim.json | 7 ++ .../chromablocks/blockstates/chroma_red.json | 7 ++ .../blockstates/chroma_red_dim.json | 7 ++ .../blockstates/chroma_white.json | 7 ++ .../blockstates/chroma_white_dim.json | 7 ++ .../blockstates/chroma_yellow.json | 7 ++ .../blockstates/chroma_yellow_dim.json | 7 ++ .../{greenscreenmod => chromablocks}/icon.png | Bin .../assets/chromablocks/lang/en_us.json | 20 +++ .../chromablocks/textures/block/black.png | Bin 0 -> 946 bytes .../chromablocks/textures/block/blue.png | Bin 0 -> 959 bytes .../chromablocks/textures/block/cyan.png | Bin 0 -> 960 bytes .../textures/block/green.png} | Bin .../chromablocks/textures/block/purple.png | Bin 0 -> 957 bytes .../chromablocks/textures/block/red.png | Bin 0 -> 956 bytes .../chromablocks/textures/block/white.png | Bin 0 -> 953 bytes .../chromablocks/textures/block/yellow.png | Bin 0 -> 958 bytes .../blockstates/green_screen_block.json | 7 -- .../blockstates/green_screen_block_dim.json | 7 -- .../assets/greenscreenmod/lang/en_us.json | 5 - .../textures/block/green_screen_block_dim.png | Bin 162 -> 0 bytes src/main/resources/fabric.mod.json | 14 +-- 53 files changed, 506 insertions(+), 141 deletions(-) create mode 100644 src/main/java/ru/xzeldon/chromablocks/ChromaBlocks.java rename src/main/java/ru/xzeldon/{greenscreenmod/GreenScreenModClient.java => chromablocks/ChromaBlocksClient.java} (53%) create mode 100644 src/main/java/ru/xzeldon/chromablocks/block/ChromaBlocksBlockRegister.java rename src/main/java/ru/xzeldon/{greenscreenmod/block/custom/GreenScreenBlock.java => chromablocks/block/custom/ChromaBlock.java} (56%) create mode 100644 src/main/java/ru/xzeldon/chromablocks/block/custom/ChromaBlockDim.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/item/ChromaBlocksItemsGroup.java rename src/main/java/ru/xzeldon/{greenscreenmod/model/GreenScreenBlockModel.java => chromablocks/model/ChromaBlockModel.java} (91%) create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/ChromaBlockModelProvider.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/custom/BlackChromaBlockModel.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/custom/BlueChromaBlockModel.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/custom/CyanChromaBlockModel.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/custom/GreenChromaBlockModel.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/custom/PurpleChromaBlockModel.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/custom/RedChromaBlockModel.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/custom/WhiteChromaBlockModel.java create mode 100644 src/main/java/ru/xzeldon/chromablocks/model/custom/YellowChromaBlockModel.java delete mode 100644 src/main/java/ru/xzeldon/greenscreenmod/GreenScreenMod.java delete mode 100644 src/main/java/ru/xzeldon/greenscreenmod/block/GreenScreenBlocks.java delete mode 100644 src/main/java/ru/xzeldon/greenscreenmod/block/custom/GreenScreenBlockDim.java delete mode 100644 src/main/java/ru/xzeldon/greenscreenmod/model/GreenScreenModelProvider.java create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_black.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_black_dim.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_blue.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_blue_dim.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_cyan.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_cyan_dim.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_green.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_green_dim.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_purple.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_purple_dim.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_red.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_red_dim.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_white.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_white_dim.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_yellow.json create mode 100644 src/main/resources/assets/chromablocks/blockstates/chroma_yellow_dim.json rename src/main/resources/assets/{greenscreenmod => chromablocks}/icon.png (100%) create mode 100644 src/main/resources/assets/chromablocks/lang/en_us.json create mode 100644 src/main/resources/assets/chromablocks/textures/block/black.png create mode 100644 src/main/resources/assets/chromablocks/textures/block/blue.png create mode 100644 src/main/resources/assets/chromablocks/textures/block/cyan.png rename src/main/resources/assets/{greenscreenmod/textures/block/green_screen_block.png => chromablocks/textures/block/green.png} (100%) create mode 100644 src/main/resources/assets/chromablocks/textures/block/purple.png create mode 100644 src/main/resources/assets/chromablocks/textures/block/red.png create mode 100644 src/main/resources/assets/chromablocks/textures/block/white.png create mode 100644 src/main/resources/assets/chromablocks/textures/block/yellow.png delete mode 100644 src/main/resources/assets/greenscreenmod/blockstates/green_screen_block.json delete mode 100644 src/main/resources/assets/greenscreenmod/blockstates/green_screen_block_dim.json delete mode 100644 src/main/resources/assets/greenscreenmod/lang/en_us.json delete mode 100644 src/main/resources/assets/greenscreenmod/textures/block/green_screen_block_dim.png diff --git a/README.md b/README.md index 18c4406..0e454aa 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,11 @@ -# Green Screen Mod +# ChromaBlocks -This mod just adds a green block to the miscellaneous tab. +![img](https://i.imgur.com/WmOq3tm.png) +ChromaBlocks is a mod for Minecraft that adds a various chroma key blocks. # Download -Download last version from [releases](https://github.com/xzeldon/GreenScreenMod/releases). +Download last version from [releases](https://github.com/xzeldon/chromablocks/releases). # Install Download and install [Fabric](https://fabricmc.net/use/installer/) then place `.jar` file to the `mods` folder. -> For compability with [Sodium](https://www.curseforge.com/minecraft/mc-mods/sodium) install [Indium](https://www.curseforge.com/minecraft/mc-mods/indium) +> For compability with [Sodium](https://modrinth.com/mod/sodium) install [Indium](https://modrinth.com/mod/indium) diff --git a/gradle.properties b/gradle.properties index 70c825b..3eb7fca 100644 --- a/gradle.properties +++ b/gradle.properties @@ -8,9 +8,9 @@ org.gradle.jvmargs=-Xmx1G loader_version=0.14.9 # Mod Properties - mod_version = 1.1.0-1.19.2 - maven_group = ru.xzeldon.greenscreenmod - archives_base_name = greenscreenmod + mod_version = 2.0.0-1.19.2 + maven_group = ru.xzeldon.chromablocks + archives_base_name = chromablocks # Dependencies fabric_version=0.59.0+1.19.2 diff --git a/src/main/java/ru/xzeldon/chromablocks/ChromaBlocks.java b/src/main/java/ru/xzeldon/chromablocks/ChromaBlocks.java new file mode 100644 index 0000000..ca0f6fc --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/ChromaBlocks.java @@ -0,0 +1,16 @@ +package ru.xzeldon.chromablocks; + +import net.fabricmc.api.ModInitializer; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; +import ru.xzeldon.chromablocks.block.ChromaBlocksBlockRegister; + +public class ChromaBlocks implements ModInitializer { + public static final String MOD_ID = "chromablocks"; + public static final Logger LOGGER = LoggerFactory.getLogger("chromablocks"); + + @Override + public void onInitialize() { + ChromaBlocksBlockRegister.registerBlocks(); + } +} diff --git a/src/main/java/ru/xzeldon/greenscreenmod/GreenScreenModClient.java b/src/main/java/ru/xzeldon/chromablocks/ChromaBlocksClient.java similarity index 53% rename from src/main/java/ru/xzeldon/greenscreenmod/GreenScreenModClient.java rename to src/main/java/ru/xzeldon/chromablocks/ChromaBlocksClient.java index 1aa312c..339593a 100644 --- a/src/main/java/ru/xzeldon/greenscreenmod/GreenScreenModClient.java +++ b/src/main/java/ru/xzeldon/chromablocks/ChromaBlocksClient.java @@ -1,12 +1,12 @@ -package ru.xzeldon.greenscreenmod; +package ru.xzeldon.chromablocks; import net.fabricmc.api.ClientModInitializer; import net.fabricmc.fabric.api.client.model.ModelLoadingRegistry; -import ru.xzeldon.greenscreenmod.model.GreenScreenModelProvider; +import ru.xzeldon.chromablocks.model.ChromaBlockModelProvider; -public class GreenScreenModClient implements ClientModInitializer { +public class ChromaBlocksClient implements ClientModInitializer { @Override public void onInitializeClient() { - ModelLoadingRegistry.INSTANCE.registerResourceProvider(rm -> new GreenScreenModelProvider()); + ModelLoadingRegistry.INSTANCE.registerResourceProvider(rm -> new ChromaBlockModelProvider()); } } diff --git a/src/main/java/ru/xzeldon/chromablocks/block/ChromaBlocksBlockRegister.java b/src/main/java/ru/xzeldon/chromablocks/block/ChromaBlocksBlockRegister.java new file mode 100644 index 0000000..b7652b2 --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/block/ChromaBlocksBlockRegister.java @@ -0,0 +1,117 @@ +package ru.xzeldon.chromablocks.block; + +import net.fabricmc.fabric.api.item.v1.FabricItemSettings; +import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; +import net.minecraft.block.Block; +import net.minecraft.block.Material; +import net.minecraft.item.BlockItem; +import net.minecraft.item.Item; +import net.minecraft.item.ItemGroup; +import net.minecraft.util.Identifier; +import net.minecraft.util.registry.Registry; +import ru.xzeldon.chromablocks.ChromaBlocks; +import ru.xzeldon.chromablocks.item.ChromaBlocksItemsGroup; + +public class ChromaBlocksBlockRegister { + public static final Block CHROMA_GREEN = registerBlock("chroma_green", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + .luminance(15) + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_GREEN_DIM = registerBlock("chroma_green_dim", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_BLACK = registerBlock("chroma_black", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + .luminance(15) + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_BLACK_DIM = registerBlock("chroma_black_dim", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_BLUE = registerBlock("chroma_blue", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + .luminance(15) + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_BLUE_DIM = registerBlock("chroma_blue_dim", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_CYAN = registerBlock("chroma_cyan", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + .luminance(15) + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_CYAN_DIM = registerBlock("chroma_cyan_dim", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_PURPLE = registerBlock("chroma_purple", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + .luminance(15) + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_PURPLE_DIM = registerBlock("chroma_purple_dim", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_RED = registerBlock("chroma_red", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + .luminance(15) + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_RED_DIM = registerBlock("chroma_red_dim", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_WHITE = registerBlock("chroma_white", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + .luminance(15) + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_WHITE_DIM = registerBlock("chroma_white_dim", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_YELLOW = registerBlock("chroma_yellow", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + .luminance(15) + ), ChromaBlocksItemsGroup.GREENSCREEN); + + public static final Block CHROMA_YELLOW_DIM = registerBlock("chroma_yellow_dim", + new Block(FabricBlockSettings.of(Material.METAL) + .breakInstantly() + ), ChromaBlocksItemsGroup.GREENSCREEN); + + private static Block registerBlock(String name, Block block, ItemGroup group) { + registerBlockItem(name, block, group); + return Registry.register(Registry.BLOCK, new Identifier(ChromaBlocks.MOD_ID, name), block); + } + + private static Item registerBlockItem(String name, Block block, ItemGroup group) { + return Registry.register(Registry.ITEM, new Identifier(ChromaBlocks.MOD_ID, name), + new BlockItem(block, new FabricItemSettings().group(group))); + } + + public static void registerBlocks() { + ChromaBlocks.LOGGER.info("Registering ModBlocks for " + ChromaBlocks.MOD_ID); + } +} diff --git a/src/main/java/ru/xzeldon/greenscreenmod/block/custom/GreenScreenBlock.java b/src/main/java/ru/xzeldon/chromablocks/block/custom/ChromaBlock.java similarity index 56% rename from src/main/java/ru/xzeldon/greenscreenmod/block/custom/GreenScreenBlock.java rename to src/main/java/ru/xzeldon/chromablocks/block/custom/ChromaBlock.java index 6e95a09..3162b39 100644 --- a/src/main/java/ru/xzeldon/greenscreenmod/block/custom/GreenScreenBlock.java +++ b/src/main/java/ru/xzeldon/chromablocks/block/custom/ChromaBlock.java @@ -1,14 +1,12 @@ -package ru.xzeldon.greenscreenmod.block.custom; +package ru.xzeldon.chromablocks.block.custom; -import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; import net.minecraft.block.Block; import net.minecraft.block.BlockState; -import net.minecraft.block.Material; import net.minecraft.util.math.BlockPos; import net.minecraft.world.BlockView; -public class GreenScreenBlock extends Block { - public GreenScreenBlock(Settings settings) { +public class ChromaBlock extends Block { + public ChromaBlock(Settings settings) { super(settings); } diff --git a/src/main/java/ru/xzeldon/chromablocks/block/custom/ChromaBlockDim.java b/src/main/java/ru/xzeldon/chromablocks/block/custom/ChromaBlockDim.java new file mode 100644 index 0000000..30f67e5 --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/block/custom/ChromaBlockDim.java @@ -0,0 +1,7 @@ +package ru.xzeldon.chromablocks.block.custom; + +public class ChromaBlockDim extends ChromaBlock { + public ChromaBlockDim(Settings settings) { + super(settings); + } +} diff --git a/src/main/java/ru/xzeldon/chromablocks/item/ChromaBlocksItemsGroup.java b/src/main/java/ru/xzeldon/chromablocks/item/ChromaBlocksItemsGroup.java new file mode 100644 index 0000000..d5f244b --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/item/ChromaBlocksItemsGroup.java @@ -0,0 +1,13 @@ +package ru.xzeldon.chromablocks.item; + +import net.fabricmc.fabric.api.client.itemgroup.FabricItemGroupBuilder; +import net.minecraft.item.ItemGroup; +import net.minecraft.item.ItemStack; +import net.minecraft.util.Identifier; +import ru.xzeldon.chromablocks.ChromaBlocks; +import ru.xzeldon.chromablocks.block.ChromaBlocksBlockRegister; + +public class ChromaBlocksItemsGroup { + public static final ItemGroup GREENSCREEN = FabricItemGroupBuilder.build(new Identifier(ChromaBlocks.MOD_ID, "chroma_blocks"), + ()-> new ItemStack(ChromaBlocksBlockRegister.CHROMA_GREEN)); +} diff --git a/src/main/java/ru/xzeldon/greenscreenmod/model/GreenScreenBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/ChromaBlockModel.java similarity index 91% rename from src/main/java/ru/xzeldon/greenscreenmod/model/GreenScreenBlockModel.java rename to src/main/java/ru/xzeldon/chromablocks/model/ChromaBlockModel.java index b9d24d9..c50d787 100644 --- a/src/main/java/ru/xzeldon/greenscreenmod/model/GreenScreenBlockModel.java +++ b/src/main/java/ru/xzeldon/chromablocks/model/ChromaBlockModel.java @@ -1,4 +1,4 @@ -package ru.xzeldon.greenscreenmod.model; +package ru.xzeldon.chromablocks.model; import com.mojang.datafixers.util.Pair; import net.fabricmc.fabric.api.renderer.v1.Renderer; @@ -25,19 +25,24 @@ import net.minecraft.util.math.Direction; import net.minecraft.util.math.random.Random; import net.minecraft.world.BlockRenderView; import org.jetbrains.annotations.Nullable; +import ru.xzeldon.chromablocks.ChromaBlocks; import java.util.*; import java.util.function.Function; import java.util.function.Supplier; -public class GreenScreenBlockModel implements UnbakedModel, BakedModel, FabricBakedModel { - private static final SpriteIdentifier SPRITE_ID = new SpriteIdentifier(SpriteAtlasTexture.BLOCK_ATLAS_TEXTURE, new Identifier("greenscreenmod:block/green_screen_block")); +public class ChromaBlockModel implements UnbakedModel, BakedModel, FabricBakedModel { + protected final SpriteIdentifier SPRITE_ID; private static final Identifier DEFAULT_BLOCK_MODEL = new Identifier("minecraft:block/block"); private final Sprite[] SPRITES = new Sprite[1]; private static final Renderer renderer = RendererAccess.INSTANCE.getRenderer(); private ModelTransformation transformation; private Mesh mesh; + public ChromaBlockModel(String color) { + this.SPRITE_ID = new SpriteIdentifier(SpriteAtlasTexture.BLOCK_ATLAS_TEXTURE, new Identifier(ChromaBlocks.MOD_ID + ":block/" + color)); + } + @Override public boolean isVanillaAdapter() { return false; diff --git a/src/main/java/ru/xzeldon/chromablocks/model/ChromaBlockModelProvider.java b/src/main/java/ru/xzeldon/chromablocks/model/ChromaBlockModelProvider.java new file mode 100644 index 0000000..8a2a0ed --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/ChromaBlockModelProvider.java @@ -0,0 +1,119 @@ +package ru.xzeldon.chromablocks.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.fabricmc.fabric.api.client.model.ModelProviderContext; +import net.fabricmc.fabric.api.client.model.ModelProviderException; +import net.fabricmc.fabric.api.client.model.ModelResourceProvider; +import net.minecraft.client.render.model.UnbakedModel; +import net.minecraft.util.Identifier; +import org.jetbrains.annotations.Nullable; +import ru.xzeldon.chromablocks.ChromaBlocks; +import ru.xzeldon.chromablocks.model.custom.*; + +@Environment(EnvType.CLIENT) +public class ChromaBlockModelProvider implements ModelResourceProvider { + public static final Identifier CHROMA_MODEL_GREEN = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_green"); + public static final Identifier CHROMA_MODEL_GREEN_DIM = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_green_dim"); + public static final Identifier CHROMA_MODEL_GREEN_ITEM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_green"); + public static final Identifier CHROMA_MODEL_GREEN_ITEM_DIM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_green_dim"); + + public static final Identifier CHROMA_MODEL_BLACK = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_black"); + public static final Identifier CHROMA_MODEL_BLACK_DIM = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_black_dim"); + public static final Identifier CHROMA_MODEL_BLACK_ITEM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_black"); + public static final Identifier CHROMA_MODEL_BLACK_ITEM_DIM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_black_dim"); + + public static final Identifier CHROMA_MODEL_BLUE = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_blue"); + public static final Identifier CHROMA_MODEL_BLUE_DIM = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_blue_dim"); + public static final Identifier CHROMA_MODEL_BLUE_ITEM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_blue"); + public static final Identifier CHROMA_MODEL_BLUE_ITEM_DIM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_blue_dim"); + + public static final Identifier CHROMA_MODEL_CYAN = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_cyan"); + public static final Identifier CHROMA_MODEL_CYAN_DIM = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_cyan_dim"); + public static final Identifier CHROMA_MODEL_CYAN_ITEM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_cyan"); + public static final Identifier CHROMA_MODEL_CYAN_ITEM_DIM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_cyan_dim"); + + public static final Identifier CHROMA_MODEL_PURPLE = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_purple"); + public static final Identifier CHROMA_MODEL_PURPLE_DIM = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_purple_dim"); + public static final Identifier CHROMA_MODEL_PURPLE_ITEM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_purple"); + public static final Identifier CHROMA_MODEL_PURPLE_ITEM_DIM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_purple_dim"); + + public static final Identifier CHROMA_MODEL_RED = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_red"); + public static final Identifier CHROMA_MODEL_RED_DIM = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_red_dim"); + public static final Identifier CHROMA_MODEL_RED_ITEM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_red"); + public static final Identifier CHROMA_MODEL_RED_ITEM_DIM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_red_dim"); + + public static final Identifier CHROMA_MODEL_WHITE = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_white"); + public static final Identifier CHROMA_MODEL_WHITE_DIM = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_white_dim"); + public static final Identifier CHROMA_MODEL_WHITE_ITEM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_white"); + public static final Identifier CHROMA_MODEL_WHITE_ITEM_DIM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_white_dim"); + + public static final Identifier CHROMA_MODEL_YELLOW = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_yellow"); + public static final Identifier CHROMA_MODEL_YELLOW_DIM = new Identifier(ChromaBlocks.MOD_ID + ":block/chroma_yellow_dim"); + public static final Identifier CHROMA_MODEL_YELLOW_ITEM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_yellow"); + public static final Identifier CHROMA_MODEL_YELLOW_ITEM_DIM = new Identifier(ChromaBlocks.MOD_ID + ":item/chroma_yellow_dim"); + + + @Override + public @Nullable UnbakedModel loadModelResource(Identifier resourceId, ModelProviderContext context) throws ModelProviderException { + if ( + resourceId.equals(CHROMA_MODEL_GREEN) || + resourceId.equals(CHROMA_MODEL_GREEN_DIM) || + resourceId.equals(CHROMA_MODEL_GREEN_ITEM) || + resourceId.equals(CHROMA_MODEL_GREEN_ITEM_DIM) + ) { + return new GreenChromaBlockModel(); + } else if ( + resourceId.equals(CHROMA_MODEL_BLACK) || + resourceId.equals(CHROMA_MODEL_BLACK_DIM) || + resourceId.equals(CHROMA_MODEL_BLACK_ITEM) || + resourceId.equals(CHROMA_MODEL_BLACK_ITEM_DIM) + ) { + return new BlackChromaBlockModel(); + } else if ( + resourceId.equals(CHROMA_MODEL_BLUE) || + resourceId.equals(CHROMA_MODEL_BLUE_DIM) || + resourceId.equals(CHROMA_MODEL_BLUE_ITEM) || + resourceId.equals(CHROMA_MODEL_BLUE_ITEM_DIM) + ) { + return new BlueChromaBlockModel(); + } else if ( + resourceId.equals(CHROMA_MODEL_CYAN) || + resourceId.equals(CHROMA_MODEL_CYAN_DIM) || + resourceId.equals(CHROMA_MODEL_CYAN_ITEM) || + resourceId.equals(CHROMA_MODEL_CYAN_ITEM_DIM) + ) { + return new CyanChromaBlockModel(); + } else if ( + resourceId.equals(CHROMA_MODEL_PURPLE) || + resourceId.equals(CHROMA_MODEL_PURPLE_DIM) || + resourceId.equals(CHROMA_MODEL_PURPLE_ITEM) || + resourceId.equals(CHROMA_MODEL_PURPLE_ITEM_DIM) + ) { + return new PurpleChromaBlockModel(); + } else if ( + resourceId.equals(CHROMA_MODEL_RED) || + resourceId.equals(CHROMA_MODEL_RED_DIM) || + resourceId.equals(CHROMA_MODEL_RED_ITEM) || + resourceId.equals(CHROMA_MODEL_RED_ITEM_DIM) + ) { + return new RedChromaBlockModel(); + } else if ( + resourceId.equals(CHROMA_MODEL_WHITE) || + resourceId.equals(CHROMA_MODEL_WHITE_DIM) || + resourceId.equals(CHROMA_MODEL_WHITE_ITEM) || + resourceId.equals(CHROMA_MODEL_WHITE_ITEM_DIM) + ) { + return new WhiteChromaBlockModel(); + } else if ( + resourceId.equals(CHROMA_MODEL_YELLOW) || + resourceId.equals(CHROMA_MODEL_YELLOW_DIM) || + resourceId.equals(CHROMA_MODEL_YELLOW_ITEM) || + resourceId.equals(CHROMA_MODEL_YELLOW_ITEM_DIM) + ) { + return new YellowChromaBlockModel(); + } else { + return null; + } + } +} diff --git a/src/main/java/ru/xzeldon/chromablocks/model/custom/BlackChromaBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/custom/BlackChromaBlockModel.java new file mode 100644 index 0000000..d996186 --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/custom/BlackChromaBlockModel.java @@ -0,0 +1,9 @@ +package ru.xzeldon.chromablocks.model.custom; + +import ru.xzeldon.chromablocks.model.ChromaBlockModel; + +public class BlackChromaBlockModel extends ChromaBlockModel { + public BlackChromaBlockModel() { + super("black"); + } +} \ No newline at end of file diff --git a/src/main/java/ru/xzeldon/chromablocks/model/custom/BlueChromaBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/custom/BlueChromaBlockModel.java new file mode 100644 index 0000000..5df7153 --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/custom/BlueChromaBlockModel.java @@ -0,0 +1,9 @@ +package ru.xzeldon.chromablocks.model.custom; + +import ru.xzeldon.chromablocks.model.ChromaBlockModel; + +public class BlueChromaBlockModel extends ChromaBlockModel { + public BlueChromaBlockModel() { + super("blue"); + } +} \ No newline at end of file diff --git a/src/main/java/ru/xzeldon/chromablocks/model/custom/CyanChromaBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/custom/CyanChromaBlockModel.java new file mode 100644 index 0000000..31bae0d --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/custom/CyanChromaBlockModel.java @@ -0,0 +1,9 @@ +package ru.xzeldon.chromablocks.model.custom; + +import ru.xzeldon.chromablocks.model.ChromaBlockModel; + +public class CyanChromaBlockModel extends ChromaBlockModel { + public CyanChromaBlockModel() { + super("cyan"); + } +} \ No newline at end of file diff --git a/src/main/java/ru/xzeldon/chromablocks/model/custom/GreenChromaBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/custom/GreenChromaBlockModel.java new file mode 100644 index 0000000..063f302 --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/custom/GreenChromaBlockModel.java @@ -0,0 +1,9 @@ +package ru.xzeldon.chromablocks.model.custom; + +import ru.xzeldon.chromablocks.model.ChromaBlockModel; + +public class GreenChromaBlockModel extends ChromaBlockModel { + public GreenChromaBlockModel() { + super("green"); + } +} \ No newline at end of file diff --git a/src/main/java/ru/xzeldon/chromablocks/model/custom/PurpleChromaBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/custom/PurpleChromaBlockModel.java new file mode 100644 index 0000000..ff1d41c --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/custom/PurpleChromaBlockModel.java @@ -0,0 +1,9 @@ +package ru.xzeldon.chromablocks.model.custom; + +import ru.xzeldon.chromablocks.model.ChromaBlockModel; + +public class PurpleChromaBlockModel extends ChromaBlockModel { + public PurpleChromaBlockModel() { + super("purple"); + } +} \ No newline at end of file diff --git a/src/main/java/ru/xzeldon/chromablocks/model/custom/RedChromaBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/custom/RedChromaBlockModel.java new file mode 100644 index 0000000..827e117 --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/custom/RedChromaBlockModel.java @@ -0,0 +1,9 @@ +package ru.xzeldon.chromablocks.model.custom; + +import ru.xzeldon.chromablocks.model.ChromaBlockModel; + +public class RedChromaBlockModel extends ChromaBlockModel { + public RedChromaBlockModel() { + super("red"); + } +} \ No newline at end of file diff --git a/src/main/java/ru/xzeldon/chromablocks/model/custom/WhiteChromaBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/custom/WhiteChromaBlockModel.java new file mode 100644 index 0000000..ccd2300 --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/custom/WhiteChromaBlockModel.java @@ -0,0 +1,9 @@ +package ru.xzeldon.chromablocks.model.custom; + +import ru.xzeldon.chromablocks.model.ChromaBlockModel; + +public class WhiteChromaBlockModel extends ChromaBlockModel { + public WhiteChromaBlockModel() { + super("white"); + } +} \ No newline at end of file diff --git a/src/main/java/ru/xzeldon/chromablocks/model/custom/YellowChromaBlockModel.java b/src/main/java/ru/xzeldon/chromablocks/model/custom/YellowChromaBlockModel.java new file mode 100644 index 0000000..47306e4 --- /dev/null +++ b/src/main/java/ru/xzeldon/chromablocks/model/custom/YellowChromaBlockModel.java @@ -0,0 +1,9 @@ +package ru.xzeldon.chromablocks.model.custom; + +import ru.xzeldon.chromablocks.model.ChromaBlockModel; + +public class YellowChromaBlockModel extends ChromaBlockModel { + public YellowChromaBlockModel() { + super("yellow"); + } +} \ No newline at end of file diff --git a/src/main/java/ru/xzeldon/greenscreenmod/GreenScreenMod.java b/src/main/java/ru/xzeldon/greenscreenmod/GreenScreenMod.java deleted file mode 100644 index ee6c7af..0000000 --- a/src/main/java/ru/xzeldon/greenscreenmod/GreenScreenMod.java +++ /dev/null @@ -1,16 +0,0 @@ -package ru.xzeldon.greenscreenmod; - -import net.fabricmc.api.ModInitializer; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; -import ru.xzeldon.greenscreenmod.block.GreenScreenBlocks; - -public class GreenScreenMod implements ModInitializer { - public static final String MOD_ID = "greenscreenmod"; - public static final Logger LOGGER = LoggerFactory.getLogger("greenscreenmod"); - - @Override - public void onInitialize() { - GreenScreenBlocks.registerBlocks(); - } -} diff --git a/src/main/java/ru/xzeldon/greenscreenmod/block/GreenScreenBlocks.java b/src/main/java/ru/xzeldon/greenscreenmod/block/GreenScreenBlocks.java deleted file mode 100644 index c3e84c5..0000000 --- a/src/main/java/ru/xzeldon/greenscreenmod/block/GreenScreenBlocks.java +++ /dev/null @@ -1,39 +0,0 @@ -package ru.xzeldon.greenscreenmod.block; - -import net.fabricmc.fabric.api.item.v1.FabricItemSettings; -import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings; -import net.minecraft.block.Block; -import net.minecraft.block.Material; -import net.minecraft.item.BlockItem; -import net.minecraft.item.Item; -import net.minecraft.item.ItemGroup; -import net.minecraft.util.Identifier; -import net.minecraft.util.registry.Registry; -import ru.xzeldon.greenscreenmod.GreenScreenMod; - -public class GreenScreenBlocks { - public static final Block GREEN_SCREEN_BLOCK = registerBlock("green_screen_block", - new Block(FabricBlockSettings.of(Material.METAL) - .breakInstantly() - ), ItemGroup.MISC); - - public static final Block GREEN_SCREEN_BLOCK_DIM = registerBlock("green_screen_block_dim", - new Block(FabricBlockSettings.of(Material.METAL) - .breakInstantly() - .luminance(15) - ), ItemGroup.MISC); - - private static Block registerBlock(String name, Block block, ItemGroup group) { - registerBlockItem(name, block, group); - return Registry.register(Registry.BLOCK, new Identifier(GreenScreenMod.MOD_ID, name), block); - } - - private static Item registerBlockItem(String name, Block block, ItemGroup group) { - return Registry.register(Registry.ITEM, new Identifier(GreenScreenMod.MOD_ID, name), - new BlockItem(block, new FabricItemSettings().group(group))); - } - - public static void registerBlocks() { - GreenScreenMod.LOGGER.info("Registering ModBlocks for " + GreenScreenMod.MOD_ID); - } -} diff --git a/src/main/java/ru/xzeldon/greenscreenmod/block/custom/GreenScreenBlockDim.java b/src/main/java/ru/xzeldon/greenscreenmod/block/custom/GreenScreenBlockDim.java deleted file mode 100644 index 967d4e2..0000000 --- a/src/main/java/ru/xzeldon/greenscreenmod/block/custom/GreenScreenBlockDim.java +++ /dev/null @@ -1,7 +0,0 @@ -package ru.xzeldon.greenscreenmod.block.custom; - -public class GreenScreenBlockDim extends GreenScreenBlock { - public GreenScreenBlockDim(Settings settings) { - super(settings); - } -} diff --git a/src/main/java/ru/xzeldon/greenscreenmod/model/GreenScreenModelProvider.java b/src/main/java/ru/xzeldon/greenscreenmod/model/GreenScreenModelProvider.java deleted file mode 100644 index 63c4645..0000000 --- a/src/main/java/ru/xzeldon/greenscreenmod/model/GreenScreenModelProvider.java +++ /dev/null @@ -1,34 +0,0 @@ -package ru.xzeldon.greenscreenmod.model; - -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.fabricmc.fabric.api.client.model.ModelProviderContext; -import net.fabricmc.fabric.api.client.model.ModelProviderException; -import net.fabricmc.fabric.api.client.model.ModelResourceProvider; -import net.minecraft.client.render.model.UnbakedModel; -import net.minecraft.util.Identifier; -import org.jetbrains.annotations.Nullable; -import ru.xzeldon.greenscreenmod.GreenScreenMod; - -@Environment(EnvType.CLIENT) -public class GreenScreenModelProvider implements ModelResourceProvider { - public static final Identifier GREEN_SCREEN_MODEL = new Identifier("greenscreenmod:block/green_screen_block"); - public static final Identifier GREEN_SCREEN_MODEL_DIM = new Identifier("greenscreenmod:block/green_screen_block_dim"); - public static final Identifier GREEN_SCREEN_MODEL_ITEM = new Identifier("greenscreenmod:item/green_screen_block"); - public static final Identifier GREEN_SCREEN_MODEL_ITEM_DIM = new Identifier("greenscreenmod:item/green_screen_block_dim"); - - - @Override - public @Nullable UnbakedModel loadModelResource(Identifier resourceId, ModelProviderContext context) throws ModelProviderException { - if ( - resourceId.equals(GREEN_SCREEN_MODEL) || - resourceId.equals(GREEN_SCREEN_MODEL_ITEM) || - resourceId.equals(GREEN_SCREEN_MODEL_DIM) || - resourceId.equals(GREEN_SCREEN_MODEL_ITEM_DIM) - ) { - return new GreenScreenBlockModel(); - } else { - return null; - } - } -} diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_black.json b/src/main/resources/assets/chromablocks/blockstates/chroma_black.json new file mode 100644 index 0000000..83da5d5 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_black.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_black" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_black_dim.json b/src/main/resources/assets/chromablocks/blockstates/chroma_black_dim.json new file mode 100644 index 0000000..83da5d5 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_black_dim.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_black" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_blue.json b/src/main/resources/assets/chromablocks/blockstates/chroma_blue.json new file mode 100644 index 0000000..a905644 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_blue.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_blue" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_blue_dim.json b/src/main/resources/assets/chromablocks/blockstates/chroma_blue_dim.json new file mode 100644 index 0000000..a905644 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_blue_dim.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_blue" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_cyan.json b/src/main/resources/assets/chromablocks/blockstates/chroma_cyan.json new file mode 100644 index 0000000..39b2038 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_cyan.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_cyan" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_cyan_dim.json b/src/main/resources/assets/chromablocks/blockstates/chroma_cyan_dim.json new file mode 100644 index 0000000..39b2038 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_cyan_dim.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_cyan" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_green.json b/src/main/resources/assets/chromablocks/blockstates/chroma_green.json new file mode 100644 index 0000000..55f5515 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_green.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_green" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_green_dim.json b/src/main/resources/assets/chromablocks/blockstates/chroma_green_dim.json new file mode 100644 index 0000000..55f5515 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_green_dim.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_green" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_purple.json b/src/main/resources/assets/chromablocks/blockstates/chroma_purple.json new file mode 100644 index 0000000..c4842d9 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_purple.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_purple" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_purple_dim.json b/src/main/resources/assets/chromablocks/blockstates/chroma_purple_dim.json new file mode 100644 index 0000000..c4842d9 --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_purple_dim.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_purple" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_red.json b/src/main/resources/assets/chromablocks/blockstates/chroma_red.json new file mode 100644 index 0000000..4e8068a --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_red.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_red" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_red_dim.json b/src/main/resources/assets/chromablocks/blockstates/chroma_red_dim.json new file mode 100644 index 0000000..4e8068a --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_red_dim.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_red" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_white.json b/src/main/resources/assets/chromablocks/blockstates/chroma_white.json new file mode 100644 index 0000000..c83e40a --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_white.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_white" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_white_dim.json b/src/main/resources/assets/chromablocks/blockstates/chroma_white_dim.json new file mode 100644 index 0000000..c83e40a --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_white_dim.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_white" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_yellow.json b/src/main/resources/assets/chromablocks/blockstates/chroma_yellow.json new file mode 100644 index 0000000..534a7fa --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_yellow.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_yellow" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/blockstates/chroma_yellow_dim.json b/src/main/resources/assets/chromablocks/blockstates/chroma_yellow_dim.json new file mode 100644 index 0000000..534a7fa --- /dev/null +++ b/src/main/resources/assets/chromablocks/blockstates/chroma_yellow_dim.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "chromablocks:block/chroma_yellow" + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/greenscreenmod/icon.png b/src/main/resources/assets/chromablocks/icon.png similarity index 100% rename from src/main/resources/assets/greenscreenmod/icon.png rename to src/main/resources/assets/chromablocks/icon.png diff --git a/src/main/resources/assets/chromablocks/lang/en_us.json b/src/main/resources/assets/chromablocks/lang/en_us.json new file mode 100644 index 0000000..6016156 --- /dev/null +++ b/src/main/resources/assets/chromablocks/lang/en_us.json @@ -0,0 +1,20 @@ +{ + "block.chromablocks.chroma_green": "Green Chroma Block", + "block.chromablocks.chroma_green_dim": "Green Chroma Block Dim", + "block.chromablocks.chroma_black": "Black Chroma Block", + "block.chromablocks.chroma_black_dim": "Black Chroma Block Dim", + "block.chromablocks.chroma_blue": "Blue Chroma Block", + "block.chromablocks.chroma_blue_dim": "Blue Chroma Block Dim", + "block.chromablocks.chroma_cyan": "Cyan Chroma Block", + "block.chromablocks.chroma_cyan_dim": "Cyan Chroma Block Dim", + "block.chromablocks.chroma_purple": "Purple Chroma Block", + "block.chromablocks.chroma_purple_dim": "Purple Chroma Block Dim", + "block.chromablocks.chroma_red": "Red Chroma Block", + "block.chromablocks.chroma_red_dim": "Red Chroma Block Dim", + "block.chromablocks.chroma_white": "White Chroma Block", + "block.chromablocks.chroma_white_dim": "White Chroma Block Dim", + "block.chromablocks.chroma_yellow": "Yellow Chroma Block", + "block.chromablocks.chroma_yellow_dim": "Yellow Chroma Block Dim", + "itemGroup.chromablocks.chroma_blocks": "Chroma blocks" + +} \ No newline at end of file diff --git a/src/main/resources/assets/chromablocks/textures/block/black.png b/src/main/resources/assets/chromablocks/textures/block/black.png new file mode 100644 index 0000000000000000000000000000000000000000..6de4ccdbd9dea6d3fedb7ea934b0e370b4d61152 GIT binary patch literal 946 zcmV;j15NyiP) zaB^>EX>4U6ba`-PAZ2)IW&i+q+U=K7lH4c^hTl0wj({YD#Bnf~s=dJ;KR-0~^h}b; zq&5%x(54!&kR_oHxx2&p?>{4a!^M$uNNS!-&JkBCsc^-_)9PbzEHpIRiTpqV0p@)OG4Tri732)Eoaeq9v z6?1WW-a^~@W3R6?;1gz-#5ijvOXw3vvs^HDj>(X>J_8k7{%=Pg@580ah>1@jiRjae zP!PVjREz~Z3xbA3F;_`T!jDKni$gTb%azy9ug@Y6SLhr0JEZrFej$G%9aciG1^GZI z-{Vi^q;K-@jC65(@|^SS`JLS4c5#yn7rrsNk8wVBS5wB8^WN08l{JIjF|)Ov%4mj< zMxV)^t)Mwdq5)^eAv@3-6=GlWW&hZSf~XE9WV;Fg*(kggAK?# z;IlLw2Z5CDSZKK|%UvUf<4zuMdI-j7o{Im{!dH~Wm<2@?{mvEQ;&~hq#Uw`*B0&vA zXzZlwO7PV_UX!bUpsqAKHdx~^Edc+a^me#pffgt##z!5I^=$wtLIjFnNI)QFR19T` z#vF_YiF5#}2%RPI0W74-9YJyu$$*0@fNwlwv{YI7A;yakAXIV?0~-`2V5OuuKb9P4 zsH$jE)vTtjMQfHkD=cTr^Nm_fESXw1Gq++jxOj5)?B?#pYvCez<7z=Y7B8jL3a1s8 zE1s@UsP*7Oj&$ge4?FxQM{OLMwA8faX3bk^wR4w_I_|k!_g;EE>BLbw)2U}Z?ew#p zb>OHC8ENRq!-kI%M!l(RtUt6rphlY-FH%#{ZfcO4T_$M0PINK@F-`>FHVKdf=E*EN zrNoomWEKlvhoX!ib;9X1iGg4`iFMG;?v0!V$$y7i00{mYF6XU=+Xr00R&J U0ceqJ!vFvP07*qoM6N<$g7M;*G5`Po literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/chromablocks/textures/block/blue.png b/src/main/resources/assets/chromablocks/textures/block/blue.png new file mode 100644 index 0000000000000000000000000000000000000000..cc529336784b1bbebb174886b18d773d46de825d GIT binary patch literal 959 zcmV;w13>(VP) zaB^>EX>4U6ba`-PAZ2)IW&i+q+U=G>lH4E+MfaQ{M?exn;y4&gRc?^u=R;#p&t#HH zDp_RFPz_jMN$4Tm;r#Y>gfA!@$wN}}Tyl;msieXc1CNhVS4%Oic0a^x@J=4?38;;N zULKF0xBP^hv7WcQZ9NroeNt4;J#oCBs9O>HHgH+ohJ+pl;#M5$RwTSFr^oa0*jCKN z?Rg7ruOEAUg#o`XnVM*a@zJ))n;pGb!l&}%|I5XyJ| zshspp9-fgdZcmnTzAe9#o8BgFa^b=^M)xt!$L?y%*mB;Ry0)@LSa-~5t+z6&;iu7O zuxBl(j+AJ?*>T7Y)JBCE7zZWlRB6z;`bG^dCO+BFGdC7$0YV3i!foMBv(jJ#@(%bc z4aY$s<=YopX3H|y$YHo6X>oc8$_TIgRSmzhXpEUqMA7e9!7rXC8(vIuL?IHEfe4Kq zR9ykS>c=v<3JB^7vtxrb9#aGGA4+eBOBQIsLPh_`BeK2~AVly$;S31~#EgugOwpKw z5h0KcKozdDBtC$JRJp@RP9hm_kOi=fcZ}9jR(^B!@ryLIoS*ON{hr8Av+=F?6;%UK7G z+K`ckjy!DmC}Gr_+Q#}r{R3*WsqrE;7urn?QnO11&Fe%bGZ5oM0B(~2NnoDLqEkvd z$xUXl;5rm#IH?m(r%4P1(@Cs@Zgy|vG)Vq8+yX%GzaSSTy5Au8Be&0}^}0TEvIxyI zoI#C(>^nJoWv`>>Ht>mBG+^{_CX>@2HM@dakSAh-}0000QNklYL@cGX`3SeR& h5sYdW)i884001Uu0c)mch|mB4002ovPDHLkV1fqnr2+r| literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/chromablocks/textures/block/cyan.png b/src/main/resources/assets/chromablocks/textures/block/cyan.png new file mode 100644 index 0000000000000000000000000000000000000000..4395f48cc279e8b62a819e32bc60f78993ab7944 GIT binary patch literal 960 zcmV;x13&zUP) zaB^>EX>4U6ba`-PAZ2)IW&i+q+U=K7j@%#&hTl0wkAQ8A&2b0>sW<5H`@@jz>~34N zY9IPApaEitZTw-P3Fo)3BYZ*ONFI`!=aO?oNhKAo7|~9wfiAngLm?9Pe5%H z^zwN0yyYk4jP<yx5#?uq05MBR$mw}H#zHYD^g5Vzt`w<6(fIX#|_$F^cF zZqHk2d;Qq+D-8IB*(5Q}n#mH{#L+AljGbdL#H~+9#g_fs(8uR+EoJz`r;tRnX?iGd zUtB8sf|dnNL!ua~2-+!Fo`M#KXc(6(uD>q7@;qFwZ{+Wg-Xr>n{E2i}0lg;V1EGBP zKa`Wc$-^_!#qG&*&bQ@va?{(yO)gyc#^^rA`Pf}e8C%YKQ`c732 zFd_uf0jR=tmc$3JkScdL$w?#w4zd8Y@s812%E}KhE<%7%$w3Tkkd%OxlH&YWa-5;6 zqDfV=nz|OPS@O)VoGs5AwVGHmwQOc?#cFWz=>Q`=ZS)jyy{n;I`tbD`bTAT_&G(7aA`G6OMA1mHFakObz*EIOsc zliXw$3$8;^hLbwsbehCKFrCCY=w|muPJ`rs!z};={|j7=j2L400009a7bBm000XU000XU0RWnu7ytkO2XskIMF-*u7Y;Qcvq0jU0000P zbVXQnLvL+uWo~o;Lvm$dbY)~9cWHEJAV*0}P*;Ht7XSbN8c9S!R4C75WcYN7ffT^R iKq45`FsfnbXaE3z*#X>%yGVBc0000 zaB^>EX>4U6ba`-PAZ2)IW&i+q+U=K7j@%#&hTl0wkAQ8A&2b0>sW<5H`@@jz>~>qV zY9IPApaEitZTw-P3Fo)3BYZ*ONFI`!=aO?oNhKAo7|~9wfiAngLm?9Pe5%H z^zwN0yyYk4jP<yx5#?uq05MBR$mw}H#zHYD^g5Vzt`w<6(fIX#|_$F^cF zZqHk2d;Qq+D-8IB*(5Q}n#mH{#L+AljGbdL#H~+9#g_fs(8uR+EoJz`r;tRnX?iGd zUtB8sf|dnNL!ua~$ZEHzpv55?#^s9ZugkAI50~p3`8%Zdh<+k}A{|yhuL=1;DBu03 za?&?>ct*OoJz38Aw){?RdYib(g$v&p-N!f|yQ?W<%Xx3=+R7SX-7%xJ-pZ(kpGKd- zp0%JlQlbH8$00jV8x>+;9F(Y2r9tQF8#TC?_+&%R+*qgu2pupAw}m^+N`no^JK(c4 z90!4vZ(nGcEz4XZhvAN-#pxj^BfRogHT=$^F=j#$MZaSOzj&T(crnQlg-BQiA~beT zbp`mUAIsz_AgC+Mjt$m$Obx()D7_snS)c_A75yWR$of`*5Wxe5GbA7oGctxUMPm*| zgg`m~Rk+TQ_y87C4KAKsJ-fMk@mjbDZd@(M$Ks`wT4A(8bH&>g z3u-<1kRu&>%26AKCM`8>xmoj8TJ7AWBaeIT*1eZrPdagw&UEUTPdoiAXB{|d zLq-}p^048fgi&v58|x4C52(?m#*5TkXg4)T%`O!*uM?fjK#UUsxJ?2ifq62EPATyu zH<`tP>rj;8q)s@UCNU69C$SE?*}aj|Ao<^L3jo3Yf?SyBeuLbP+&-h$>-x~iA~e%* z1~tlV!Z8FWQh zbVF}#ZDnqB07G(RVRU6=Aa`kWXdp*PO;A^X4i^9b02)a|K~yNuWBkN$i-8ot#6Th# f)iA1I=x6`{v6}(x^Q9d%00000NkvXXu0mjf1{ zaB^>EX>4U6ba`-PAZ2)IW&i+q+U=K1avUKHhWDHzM?exn;y5%kRk=ZqpC5*9j~yqK zRIs_w&s%;%&REY|-nO0!xjrc>=bkv;Pt>i5eH*weZbL#3192-3bt@9ymeXT=JdPD} zaeF>O+v~@kUtz#6%qod-)=ZXACyr*hpzj=$A#Qy-Dz@z3hCYtNwUpr#pF$E*r|F@< zeQ~L13u+cP4T++!7*+JQr=Z0l8v5mm>#x6Gc^)p;H}ZE#?;ia`{zN*gfL;^wfl$8N zPvxX<^6-pwaeK0y^KJQ^-1IhalM5HVF}ja&K2BFt#*yuaFQ>8)YY8y4UnD}Hv%iLI~1qdB53b%zj%|e3>$UES( zG+YOPly6^XnJvp)BZuLRq{ZzaC?jn7s}g=^(HJwKh@#)If?qsuHoTbRh(aVR0}&cK zsJa4tm5<-#Dj=vU%#H)rcuWnze<;0OE?J-j3l;4nkI4E~fDpk0g)<}|5Hm7{GDTw! zMub2*09ClolK21?QsoXOIf-PzK^DL^_86_Dto#t;Ap{7O9K^r|NeNgfDejLY#~rFF znp8EbscX@iCC?1Y+46i*tBEC3%Vy?QtOgfPuAbf8y?8BL1TU@@B!@ryLIoS*ON|Mr8Av+=F?6;%UK7m z+K`ckjy!DmC}Gr_+Q#}r`2%XSsqrE;7urn?QnO11&F4fXGZ5oM0B(~2NnoDLqEkvd z$xUXl;5ig!IH?m(r%4P1(@Cs@Zgy|vG)Vq8+yX%GzaSSTy5Au8Be&0}^}7Dh$s#n< za0WFBvJV@*ve!{aM#h81a~MBq!_OxEw0$XhDS9b-DS9b-DS9dT{}ss?q2s^D@EuBY zwgKbE1VjJ;010qNS#tmY3ljhU3ljkVnw%H_000McNliru;t3ZHG!J%--Vy)+02y>e zSad^gZEa<4bO1wgWnpw>WFU8GbZ8()Nlj2!fese{000A#Xu5ZVqh56 eFsfm=Y5)L_ngKa%ypP%d0000 zaB^>EX>4U6ba`-PAZ2)IW&i+q+U=K7a^xrshTl2G905rPiQ`}}Rda(q{`}C`=_IqM zY|XrERhu+mS(b!8M0djZ&(9Hl;NnO*BsI?^=ZGtnRJdZ|@p0AFQ%tMhH}RUhlZX2O z%tpZ|k6X`MenQUB=PhsBPK8{b43%>~INm>~+YtM9aCzL0gdPs!HXQ0UB)mPR$NlkG zR?Nlic?oUnkNte50iQ6tB*s}YSwf#Un&pDIb4-T3^%T1eZa^8!&ma=BhJ7%`lTN%yp z(daYTvlTQ)Ni^W>*klJ?I4iy9SbeDWw~qQaNNlQb`QZA;gvsX;X6uW%z`3{e&-5t@!Z*nVv-{Yk)Q@5 zG&7J&aydfQyGKnoNVO2$dYfzy?JLSScy?k0r+* zsw$dPHLIy>(V8XC3d`B@JW;EOB~#00=2ol*7f-I9-Q2x+EnEaAt`^i|@lr~ya9Uxx z;_V8BS`R+tNQWNzu)~jX)W)GnOHEsD*1VNgJ9p`*9@1@t1PHd$!oqFcePCv_8 z2e#Ufk%o>uZ1^Z))SKGI`lNq{6UPiE06 zC7$FavsiE(iZX)K38&K}27>7%)P3lrTp$bIJaJ8HeIFFIL- zW*N?;MnUyKsj}k_-a b(9r+@Rc!+upDq=m00000NkvXXu0mjf1|FuY literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/chromablocks/textures/block/yellow.png b/src/main/resources/assets/chromablocks/textures/block/yellow.png new file mode 100644 index 0000000000000000000000000000000000000000..765c1242644d298ec32275aac69be28eee4db9f3 GIT binary patch literal 958 zcmV;v13~ zaB^>EX>4U6ba`-PAZ2)IW&i+q+U=K1lH4E+hWDHzM?exn;y4&gRc?^u=ZD6go|z<- zRITrJhI>Hw`9LYmc^IUR{cv4A)D>@z@PhB;|wCX*GSLdBP+!Ih6 z1+6@Wp11sjoUxv_ylp)da(z-%&OLFwpQu|A`!;Y{+=hf62I5v6>Q*GYEvLu$cx)@? z;`Y3Sw%3n6zruiDm{k(vteGsKP8`j0LEkwhL)`jwRBYM54SgJkYbnDgK7}NrPSZny z`{Gj37St?o8WKfcF{&c6Jq0Ze(a9Oe=VNy@Wo$X`Oe3g&SOIi6L#zhDaDmjRO4U!VDQc|2BOO7*C zRWzw;R#VraHA|iumb2w~qgE43rk2gjtym2%o?JbrIcD>v_f;m z+Z79HJ@}9#9eU)$4nN9K8;2$>HEp?B^Hy5z+@&Lrd+ye~mtIdgag@$<>X}bF{VZo4 zIBG*i8anc@;iH66Z)zLsr}78XXj9`wYA&>!8l+~I3Yyo6PG%s+i2&Rt0g}KxnMJ3R zc#@mUV!?GN%5YLAoKBM%2&R)*2i@%6$Z3%LZ@2}3;D13bOmx3N?lZR^QR{Vm=wuO^ zX*h!#1=%<7&0w#53{vSWt^uyW&u#eG#Gke=MK47!MK47!MK47!MgPAd86$N3dko(J zFnzWhSIQGY00009a7bBm000XU000XU0RWnu7ytkO2XskIMF-*u7Y;Nftu`0L0000P zbVXQnLvL+uWo~o;Lvm$dbY)~9cWHEJAV*0}P*;Ht7XSbN7)eAyR4C75{Qr!BB*4VL gFsflx!*JCA0RG?t1@^jTk^lez07*qoM6N<$f&dwq9smFU literal 0 HcmV?d00001 diff --git a/src/main/resources/assets/greenscreenmod/blockstates/green_screen_block.json b/src/main/resources/assets/greenscreenmod/blockstates/green_screen_block.json deleted file mode 100644 index a25acdf..0000000 --- a/src/main/resources/assets/greenscreenmod/blockstates/green_screen_block.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "variants": { - "": { - "model": "greenscreenmod:block/green_screen_block" - } - } -} \ No newline at end of file diff --git a/src/main/resources/assets/greenscreenmod/blockstates/green_screen_block_dim.json b/src/main/resources/assets/greenscreenmod/blockstates/green_screen_block_dim.json deleted file mode 100644 index a25acdf..0000000 --- a/src/main/resources/assets/greenscreenmod/blockstates/green_screen_block_dim.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "variants": { - "": { - "model": "greenscreenmod:block/green_screen_block" - } - } -} \ No newline at end of file diff --git a/src/main/resources/assets/greenscreenmod/lang/en_us.json b/src/main/resources/assets/greenscreenmod/lang/en_us.json deleted file mode 100644 index 6f0a0f8..0000000 --- a/src/main/resources/assets/greenscreenmod/lang/en_us.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "block.greenscreenmod.green_screen_block": "Green Screen Block", - "block.greenscreenmod.green_screen_block_dim": "Green Screen Block Dim" - -} \ No newline at end of file diff --git a/src/main/resources/assets/greenscreenmod/textures/block/green_screen_block_dim.png b/src/main/resources/assets/greenscreenmod/textures/block/green_screen_block_dim.png deleted file mode 100644 index de180ddf84d0a851f2e0cb9e3ebe91b6c1d012b0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 162 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61SBU+%rFB|oCO|{#S9GG!XV7ZFl&wkP>{XE z)7O>#5j!gfr_9Z=uB|{J+02lL66gHf+|;}hAeVu`xhOTUBsE2$JhLQ2!QIn0AVn{g z9Vjm0>EaloaXvZa$9V^#gro$Cs|KqQcVsaz*y}UO%jI&kgEV`(`njxgN@xNAX>TS} diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index 67e5d81..1c811fe 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -1,29 +1,29 @@ { "schemaVersion": 1, - "id": "greenscreenmod", + "id": "chromablocks", "version": "${version}", - "name": "Green Screen Mod", - "description": "This mod add green screen block to Minecraft", + "name": "Chroma Blocks", + "description": "Chroma key in Minecraft!", "authors": [ "xzeldon" ], "contact": { "homepage": "https://zeldon.ru/", - "sources": "https://github.com/xzeldon/GreenScreenMod" + "sources": "https://github.com/xzeldon/chromablocks" }, "license": "MIT", - "icon": "assets/greenscreenmod/icon.png", + "icon": "assets/chromablocks/icon.png", "environment": "*", "entrypoints": { "main": [ - "ru.xzeldon.greenscreenmod.GreenScreenMod" + "ru.xzeldon.chromablocks.ChromaBlocks" ], "client": [ - "ru.xzeldon.greenscreenmod.GreenScreenModClient" + "ru.xzeldon.chromablocks.ChromaBlocksClient" ] }, "mixins": [],