From d9487f8ef3396056de7c5e4e79f062773e7c5918 Mon Sep 17 00:00:00 2001 From: Ellpeck Date: Mon, 13 Feb 2017 23:17:08 +0100 Subject: [PATCH] added crystal clusters --- .../mod/blocks/BlockCrystalCluster.java | 144 ++++++++++++ .../mod/blocks/InitBlocks.java | 13 ++ .../mod/crafting/MiscCrafting.java | 10 + .../mod/creative/CreativeTab.java | 7 + .../mod/gen/WorldGenLushCaves.java | 49 ++++- .../mod/items/InitItems.java | 2 + .../mod/items/ItemAllToolAA.java | 2 +- .../mod/items/ItemCrystalShard.java | 82 +++++++ .../actuallyadditions/mod/items/ItemDust.java | 2 +- .../actuallyadditions/mod/items/ItemJams.java | 2 +- .../mod/items/ItemPotionRing.java | 2 +- .../mod/items/metalists/TheCrystals.java | 16 +- .../mod/proxy/ClientProxy.java | 18 +- .../actuallyadditions/mod/proxy/IProxy.java | 4 + .../mod/proxy/ServerProxy.java | 6 + .../mod/util/IColorProvidingBlock.java | 22 ++ .../mod/util/IColorProvidingItem.java | 2 +- .../actuallyadditions/mod/util/ItemUtil.java | 4 + .../block_crystal_cluster_coal.json | 22 ++ .../block_crystal_cluster_diamond.json | 22 ++ .../block_crystal_cluster_emerald.json | 22 ++ .../block_crystal_cluster_iron.json | 22 ++ .../block_crystal_cluster_lapis.json | 22 ++ .../block_crystal_cluster_redstone.json | 22 ++ .../assets/actuallyadditions/lang/en_US.lang | 12 + .../models/block/block_crystal_cluster.json | 207 ++++++++++++++++++ .../models/item/item_crystal_shard.json | 6 + .../textures/blocks/block_crystal_cluster.png | Bin 0 -> 3071 bytes .../textures/items/item_crystal_shard.png | Bin 0 -> 311 bytes 29 files changed, 721 insertions(+), 23 deletions(-) create mode 100644 src/main/java/de/ellpeck/actuallyadditions/mod/blocks/BlockCrystalCluster.java create mode 100644 src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrystalShard.java create mode 100644 src/main/java/de/ellpeck/actuallyadditions/mod/util/IColorProvidingBlock.java create mode 100644 src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_coal.json create mode 100644 src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_diamond.json create mode 100644 src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_emerald.json create mode 100644 src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_iron.json create mode 100644 src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_lapis.json create mode 100644 src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_redstone.json create mode 100644 src/main/resources/assets/actuallyadditions/models/block/block_crystal_cluster.json create mode 100644 src/main/resources/assets/actuallyadditions/models/item/item_crystal_shard.json create mode 100644 src/main/resources/assets/actuallyadditions/textures/blocks/block_crystal_cluster.png create mode 100644 src/main/resources/assets/actuallyadditions/textures/items/item_crystal_shard.png diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/BlockCrystalCluster.java b/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/BlockCrystalCluster.java new file mode 100644 index 000000000..f8c7f6945 --- /dev/null +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/BlockCrystalCluster.java @@ -0,0 +1,144 @@ +/* + * This file ("BlockCrystalCluster.java") is part of the Actually Additions mod for Minecraft. + * It is created and owned by Ellpeck and distributed + * under the Actually Additions License to be found at + * http://ellpeck.de/actaddlicense + * View the source code at https://github.com/Ellpeck/ActuallyAdditions + * + * © 2015-2017 Ellpeck + */ + +package de.ellpeck.actuallyadditions.mod.blocks; + +import de.ellpeck.actuallyadditions.mod.blocks.base.BlockBase; +import de.ellpeck.actuallyadditions.mod.gen.WorldGenLushCaves; +import de.ellpeck.actuallyadditions.mod.items.InitItems; +import de.ellpeck.actuallyadditions.mod.items.metalists.TheCrystals; +import de.ellpeck.actuallyadditions.mod.util.IColorProvidingBlock; +import de.ellpeck.actuallyadditions.mod.util.IColorProvidingItem; +import net.minecraft.block.BlockDirectional; +import net.minecraft.block.SoundType; +import net.minecraft.block.material.Material; +import net.minecraft.block.state.BlockStateContainer; +import net.minecraft.block.state.IBlockState; +import net.minecraft.client.renderer.color.IBlockColor; +import net.minecraft.client.renderer.color.IItemColor; +import net.minecraft.entity.EntityLivingBase; +import net.minecraft.item.EnumRarity; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.util.BlockRenderLayer; +import net.minecraft.util.EnumFacing; +import net.minecraft.util.Mirror; +import net.minecraft.util.Rotation; +import net.minecraft.util.math.BlockPos; +import net.minecraft.world.IBlockAccess; +import net.minecraft.world.World; +import net.minecraftforge.fml.relauncher.Side; +import net.minecraftforge.fml.relauncher.SideOnly; +import org.apache.commons.lang3.ArrayUtils; + +import java.util.Random; + +public class BlockCrystalCluster extends BlockBase implements IColorProvidingBlock, IColorProvidingItem{ + + private final TheCrystals crystal; + + public BlockCrystalCluster(String name, TheCrystals crystal){ + super(Material.GLASS, name); + this.crystal = crystal; + + this.setHardness(0.25F); + this.setResistance(1.0F); + this.setSoundType(SoundType.GLASS); + this.setLightOpacity(1); + this.setLightLevel(0.7F); + } + + @Override + public boolean isFullCube(IBlockState state){ + return false; + } + + @Override + public boolean isOpaqueCube(IBlockState state){ + return false; + } + + @Override + public IBlockState getStateForPlacement(World world, BlockPos pos, EnumFacing side, float hitX, float hitY, float hitZ, int meta, EntityLivingBase base){ + return this.getStateFromMeta(side.ordinal()); + } + + @Override + public EnumRarity getRarity(ItemStack stack){ + return EnumRarity.EPIC; + } + + @Override + public IBlockState getStateFromMeta(int meta){ + return this.getDefaultState().withProperty(BlockDirectional.FACING, EnumFacing.getFront(meta)); + } + + @Override + public int getMetaFromState(IBlockState state){ + return state.getValue(BlockDirectional.FACING).getIndex(); + } + + @Override + protected BlockStateContainer createBlockState(){ + return new BlockStateContainer(this, BlockDirectional.FACING); + } + + @Override + public IBlockState withRotation(IBlockState state, Rotation rot){ + return state.withProperty(BlockDirectional.FACING, rot.rotate(state.getValue(BlockDirectional.FACING))); + } + + @Override + public IBlockState withMirror(IBlockState state, Mirror mirror){ + return this.withRotation(state, mirror.toRotation(state.getValue(BlockDirectional.FACING))); + } + + @Override + @SideOnly(Side.CLIENT) + public IBlockColor getBlockColor(){ + return new IBlockColor(){ + @Override + public int colorMultiplier(IBlockState state, IBlockAccess world, BlockPos pos, int tintIndex){ + return BlockCrystalCluster.this.crystal.clusterColor; + } + }; + } + + @Override + @SideOnly(Side.CLIENT) + public BlockRenderLayer getBlockLayer(){ + return BlockRenderLayer.TRANSLUCENT; + } + + @Override + public IItemColor getItemColor(){ + return new IItemColor(){ + @Override + public int getColorFromItemstack(ItemStack stack, int tintIndex){ + return BlockCrystalCluster.this.crystal.clusterColor; + } + }; + } + + @Override + public Item getItemDropped(IBlockState state, Random rand, int fortune){ + return InitItems.itemCrystalShard; + } + + @Override + public int damageDropped(IBlockState state){ + return ArrayUtils.indexOf(WorldGenLushCaves.CRYSTAL_CLUSTERS, this); + } + + @Override + public int quantityDropped(Random random){ + return random.nextInt(5)+2; + } +} \ No newline at end of file diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/InitBlocks.java b/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/InitBlocks.java index f1e7a54d4..a3301a8b9 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/InitBlocks.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/blocks/InitBlocks.java @@ -14,6 +14,7 @@ import de.ellpeck.actuallyadditions.mod.blocks.BlockLaserRelay.Type; import de.ellpeck.actuallyadditions.mod.blocks.base.BlockPlant; import de.ellpeck.actuallyadditions.mod.blocks.base.BlockStair; import de.ellpeck.actuallyadditions.mod.blocks.metalists.TheMiscBlocks; +import de.ellpeck.actuallyadditions.mod.items.metalists.TheCrystals; import de.ellpeck.actuallyadditions.mod.util.ModUtil; import de.ellpeck.actuallyadditions.mod.util.compat.CompatUtil; import net.minecraft.block.Block; @@ -109,10 +110,22 @@ public final class InitBlocks{ public static Block blockTinyTorch; public static Block blockFarmer; public static Block blockBatteryBox; + public static Block blockCrystalClusterRedstone; + public static Block blockCrystalClusterLapis; + public static Block blockCrystalClusterDiamond; + public static Block blockCrystalClusterCoal; + public static Block blockCrystalClusterEmerald; + public static Block blockCrystalClusterIron; public static void init(){ ModUtil.LOGGER.info("Initializing Blocks..."); + blockCrystalClusterRedstone = new BlockCrystalCluster("block_crystal_cluster_redstone", TheCrystals.REDSTONE); + blockCrystalClusterLapis = new BlockCrystalCluster("block_crystal_cluster_lapis", TheCrystals.LAPIS); + blockCrystalClusterDiamond = new BlockCrystalCluster("block_crystal_cluster_diamond", TheCrystals.DIAMOND); + blockCrystalClusterCoal = new BlockCrystalCluster("block_crystal_cluster_coal", TheCrystals.COAL); + blockCrystalClusterEmerald = new BlockCrystalCluster("block_crystal_cluster_emerald", TheCrystals.EMERALD); + blockCrystalClusterIron = new BlockCrystalCluster("block_crystal_cluster_iron", TheCrystals.IRON); blockBatteryBox = new BlockBatteryBox("block_battery_box"); blockItemViewerHopping = new BlockItemViewerHopping("block_item_viewer_hopping"); blockFarmer = new BlockFarmer("block_farmer"); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/crafting/MiscCrafting.java b/src/main/java/de/ellpeck/actuallyadditions/mod/crafting/MiscCrafting.java index e9da7483e..fa4b02da3 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/crafting/MiscCrafting.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/crafting/MiscCrafting.java @@ -25,6 +25,9 @@ import net.minecraftforge.oredict.ShapelessOreRecipe; public final class MiscCrafting{ + public static final IRecipe[] RECIPES_CRYSTAL_SHARDS = new IRecipe[TheCrystals.values().length]; + public static final IRecipe[] RECIPES_CRYSTAL_SHARDS_BACK = new IRecipe[TheCrystals.values().length]; + public static final IRecipe[] RECIPES_CRYSTALS = new IRecipe[TheCrystals.values().length]; public static final IRecipe[] RECIPES_CRYSTAL_BLOCKS = new IRecipe[TheCrystals.values().length]; @@ -52,6 +55,13 @@ public final class MiscCrafting{ RECIPES_EMPOWERED_CRYSTAL_BLOCKS[i] = RecipeUtil.lastIRecipe(); GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(InitItems.itemCrystalEmpowered, 9, i), new ItemStack(InitBlocks.blockCrystalEmpowered, 1, i))); RECIPES_EMPOWERED_CRYSTALS[i] = RecipeUtil.lastIRecipe(); + + GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(InitItems.itemCrystal, 1, i), + "XXX", "XXX", "XXX", + 'X', new ItemStack(InitItems.itemCrystalShard, 1, i))); + RECIPES_CRYSTAL_SHARDS[i] = RecipeUtil.lastIRecipe(); + GameRegistry.addRecipe(new ShapelessOreRecipe(new ItemStack(InitItems.itemCrystalShard, 9, i), new ItemStack(InitItems.itemCrystal, 1, i))); + RECIPES_CRYSTAL_SHARDS_BACK[i] = RecipeUtil.lastIRecipe(); } //Dough diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/creative/CreativeTab.java b/src/main/java/de/ellpeck/actuallyadditions/mod/creative/CreativeTab.java index c14140bee..0bd231dab 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/creative/CreativeTab.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/creative/CreativeTab.java @@ -236,10 +236,17 @@ public class CreativeTab extends CreativeTabs{ this.add(InitItems.itemPaxelCrystalGreen); this.add(InitItems.itemPaxelCrystalWhite); + this.add(InitBlocks.blockCrystalClusterRedstone); + this.add(InitBlocks.blockCrystalClusterLapis); + this.add(InitBlocks.blockCrystalClusterDiamond); + this.add(InitBlocks.blockCrystalClusterCoal); + this.add(InitBlocks.blockCrystalClusterEmerald); + this.add(InitBlocks.blockCrystalClusterIron); this.add(InitBlocks.blockCrystal); this.add(InitBlocks.blockCrystalEmpowered); this.add(InitItems.itemCrystal); this.add(InitItems.itemCrystalEmpowered); + this.add(InitItems.itemCrystalShard); this.add(InitItems.itemJams); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/gen/WorldGenLushCaves.java b/src/main/java/de/ellpeck/actuallyadditions/mod/gen/WorldGenLushCaves.java index d3451093e..ce8ff6c7b 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/gen/WorldGenLushCaves.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/gen/WorldGenLushCaves.java @@ -15,9 +15,11 @@ import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues; import de.ellpeck.actuallyadditions.mod.misc.DungeonLoot; import de.ellpeck.actuallyadditions.mod.tile.TileEntityGiantChest; import net.minecraft.block.Block; +import net.minecraft.block.BlockDirectional; import net.minecraft.block.state.IBlockState; import net.minecraft.init.Blocks; import net.minecraft.tileentity.TileEntity; +import net.minecraft.util.EnumFacing; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.MathHelper; import net.minecraft.world.World; @@ -35,6 +37,15 @@ import java.util.Random; public class WorldGenLushCaves{ + public static final Block[] CRYSTAL_CLUSTERS = new Block[]{ + InitBlocks.blockCrystalClusterRedstone, + InitBlocks.blockCrystalClusterLapis, + InitBlocks.blockCrystalClusterDiamond, + InitBlocks.blockCrystalClusterCoal, + InitBlocks.blockCrystalClusterEmerald, + InitBlocks.blockCrystalClusterIron + }; + public boolean generate(World world, Random rand, BlockPos position, StructureBoundingBox blockRegion){ this.generateCave(world, position, rand, blockRegion); return true; @@ -50,10 +61,10 @@ public class WorldGenLushCaves{ spheresBox.maxZ += 7; for(int i = 0; i <= spheres; i++){ //center already is random value within population area - this.makeSphereWithGrassFloor(world, center.add(rand.nextInt(11)-5, rand.nextInt(7)-3, rand.nextInt(11)-5), rand.nextInt(3)+5, spheresBox); + this.makeSphereWithGrassFloor(world, center.add(rand.nextInt(11)-5, rand.nextInt(7)-3, rand.nextInt(11)-5), rand.nextInt(3)+5, spheresBox, rand); } - this.genTreesAndTallGrass(world, center, 11, spheres*3, rand, chunkRegion); + this.genTreesAndTallGrass(world, center, 11, spheres*2, rand, chunkRegion); } private void genTreesAndTallGrass(World world, BlockPos center, int radius, int amount, Random rand, StructureBoundingBox box){ @@ -61,10 +72,27 @@ public class WorldGenLushCaves{ for(double x = -radius; x < radius; x++){ for(double y = -radius; y < radius; y++){ for(double z = -radius; z < radius; z++){ - if(rand.nextDouble() >= 0.5D){ - BlockPos pos = center.add(x, y, z); - if(box.isVecInside(pos) && world.getBlockState(pos).getBlock() == Blocks.GRASS){ - possiblePoses.add(pos); + BlockPos pos = center.add(x, y, z); + if(box.isVecInside(pos)){ + if(rand.nextDouble() >= 0.5D){ + if(world.getBlockState(pos).getBlock() == Blocks.GRASS){ + possiblePoses.add(pos); + } + } + else if(rand.nextInt(20) == 0){ + EnumFacing[] values = EnumFacing.values(); + EnumFacing side = values[rand.nextInt(values.length)]; + BlockPos posSide = pos.offset(side); + + if(!this.checkIndestructable(world, posSide)){ + IBlockState state = world.getBlockState(pos); + IBlockState stateSide = world.getBlockState(posSide); + + if(state.getBlock().isAir(state, world, pos) && stateSide.getBlock().isSideSolid(stateSide, world, posSide, side.getOpposite())){ + Block block = CRYSTAL_CLUSTERS[rand.nextInt(CRYSTAL_CLUSTERS.length)]; + world.setBlockState(pos, block.getDefaultState().withProperty(BlockDirectional.FACING, side.getOpposite()), 2); + } + } } } } @@ -118,7 +146,7 @@ public class WorldGenLushCaves{ } } - private void makeSphereWithGrassFloor(World world, BlockPos center, int radius, StructureBoundingBox boundingBox){ + private void makeSphereWithGrassFloor(World world, BlockPos center, int radius, StructureBoundingBox boundingBox, Random rand){ for(double x = -radius; x < radius; x++){ for(double y = -radius; y < radius; y++){ for(double z = -radius; z < radius; z++){ @@ -137,11 +165,12 @@ public class WorldGenLushCaves{ for(double z = -radius; z < radius; z++){ for(double y = -radius; y <= -3; y++){ BlockPos pos = center.add(x, y, z); - if(boundingBox.isVecInside(pos)){ + if(boundingBox.isVecInside(pos) && !this.checkIndestructable(world, pos)){ IBlockState state = world.getBlockState(pos); BlockPos posUp = pos.up(); - IBlockState stateUp = world.getBlockState(posUp); - if(!this.checkIndestructable(world, pos) && !this.checkIndestructable(world, posUp)){ + + if(!this.checkIndestructable(world, posUp)){ + IBlockState stateUp = world.getBlockState(posUp); if(!state.getBlock().isAir(state, world, pos) && stateUp.getBlock().isAir(stateUp, world, posUp)){ world.setBlockState(pos, Blocks.GRASS.getDefaultState()); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/InitItems.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/InitItems.java index 9a19695b3..9e054e316 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/InitItems.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/InitItems.java @@ -196,10 +196,12 @@ public final class InitItems{ public static Item itemLaserUpgradeInvisibility; public static Item itemLaserUpgradeRange; public static Item itemInfraredGoggles; + public static Item itemCrystalShard; public static void init(){ ModUtil.LOGGER.info("Initializing Items..."); + itemCrystalShard = new ItemCrystalShard("item_crystal_shard"); itemInfraredGoggles = new ItemInfraredGoggles("item_infrared_goggles"); itemLaserUpgradeRange = new ItemLaserRelayUpgrade("item_laser_upgrade_range"); itemLaserUpgradeInvisibility = new ItemLaserRelayUpgrade("item_laser_upgrade_invisibility"); diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemAllToolAA.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemAllToolAA.java index e90e77b26..d7ba6c9cf 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemAllToolAA.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemAllToolAA.java @@ -113,7 +113,7 @@ public class ItemAllToolAA extends ItemToolAA implements IColorProvidingItem{ @SideOnly(Side.CLIENT) @Override - public IItemColor getColor(){ + public IItemColor getItemColor(){ return new IItemColor(){ @Override public int getColorFromItemstack(ItemStack stack, int pass){ diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrystalShard.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrystalShard.java new file mode 100644 index 000000000..c3729f0d8 --- /dev/null +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemCrystalShard.java @@ -0,0 +1,82 @@ +/* + * This file ("ItemCrystalShard.java") is part of the Actually Additions mod for Minecraft. + * It is created and owned by Ellpeck and distributed + * under the Actually Additions License to be found at + * http://ellpeck.de/actaddlicense + * View the source code at https://github.com/Ellpeck/ActuallyAdditions + * + * © 2015-2017 Ellpeck + */ + +package de.ellpeck.actuallyadditions.mod.items; + +import de.ellpeck.actuallyadditions.mod.ActuallyAdditions; +import de.ellpeck.actuallyadditions.mod.blocks.BlockCrystal; +import de.ellpeck.actuallyadditions.mod.items.base.ItemBase; +import de.ellpeck.actuallyadditions.mod.util.IColorProvidingItem; +import de.ellpeck.actuallyadditions.mod.util.StringUtil; +import net.minecraft.client.renderer.color.IItemColor; +import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.item.EnumRarity; +import net.minecraft.item.Item; +import net.minecraft.item.ItemStack; +import net.minecraft.util.NonNullList; +import net.minecraftforge.fml.relauncher.Side; +import net.minecraftforge.fml.relauncher.SideOnly; + +public class ItemCrystalShard extends ItemBase implements IColorProvidingItem{ + + public ItemCrystalShard(String name){ + super(name); + this.setHasSubtypes(true); + this.setMaxDamage(0); + } + + @Override + public int getMetadata(int damage){ + return damage; + } + + @Override + public String getUnlocalizedName(ItemStack stack){ + return stack.getItemDamage() >= BlockCrystal.ALL_CRYSTALS.length ? StringUtil.BUGGED_ITEM_NAME : this.getUnlocalizedName()+"_"+BlockCrystal.ALL_CRYSTALS[stack.getItemDamage()].name; + } + + + @Override + public EnumRarity getRarity(ItemStack stack){ + return stack.getItemDamage() >= BlockCrystal.ALL_CRYSTALS.length ? EnumRarity.COMMON : BlockCrystal.ALL_CRYSTALS[stack.getItemDamage()].rarity; + } + + @Override + @SideOnly(Side.CLIENT) + public void getSubItems(Item item, CreativeTabs tab, NonNullList list){ + for(int j = 0; j < BlockCrystal.ALL_CRYSTALS.length; j++){ + list.add(new ItemStack(this, 1, j)); + } + } + + @Override + protected void registerRendering(){ + for(int i = 0; i < BlockCrystal.ALL_CRYSTALS.length; i++){ + ActuallyAdditions.proxy.addRenderRegister(new ItemStack(this, 1, i), this.getRegistryName(), "inventory"); + } + } + + @Override + @SideOnly(Side.CLIENT) + public IItemColor getItemColor(){ + return new IItemColor(){ + @Override + public int getColorFromItemstack(ItemStack stack, int tintIndex){ + int damage = stack.getItemDamage(); + if(damage >= 0 && damage < BlockCrystal.ALL_CRYSTALS.length){ + return BlockCrystal.ALL_CRYSTALS[damage].clusterColor; + } + else{ + return 0; + } + } + }; + } +} \ No newline at end of file diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDust.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDust.java index 87d909eda..1f2b067f2 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDust.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemDust.java @@ -67,7 +67,7 @@ public class ItemDust extends ItemBase implements IColorProvidingItem{ @SideOnly(Side.CLIENT) @Override - public IItemColor getColor(){ + public IItemColor getItemColor(){ return new IItemColor(){ @Override public int getColorFromItemstack(ItemStack stack, int pass){ diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemJams.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemJams.java index 96f4982ed..6281a0c53 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemJams.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemJams.java @@ -107,7 +107,7 @@ public class ItemJams extends ItemFoodBase implements IColorProvidingItem{ @Override @SideOnly(Side.CLIENT) - public IItemColor getColor(){ + public IItemColor getItemColor(){ return new IItemColor(){ @Override public int getColorFromItemstack(ItemStack stack, int pass){ diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPotionRing.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPotionRing.java index 9c5fb69c1..57c4683cf 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPotionRing.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/ItemPotionRing.java @@ -162,7 +162,7 @@ public class ItemPotionRing extends ItemBase implements IColorProvidingItem, IDi @Override @SideOnly(Side.CLIENT) - public IItemColor getColor(){ + public IItemColor getItemColor(){ return new IItemColor(){ @Override public int getColorFromItemstack(ItemStack stack, int tintIndex){ diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheCrystals.java b/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheCrystals.java index 43d6c9fb4..76fa05979 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheCrystals.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/items/metalists/TheCrystals.java @@ -16,21 +16,23 @@ import net.minecraft.util.IStringSerializable; public enum TheCrystals implements IStringSerializable{ - REDSTONE("red", Util.CRYSTAL_RED_RARITY, 158F/255F, 43F/255F, 39F/255F), - LAPIS("blue", Util.CRYSTAL_BLUE_RARITY, 37F/255F, 49F/255F, 147F/255F), - DIAMOND("light_blue", Util.CRYSTAL_LIGHT_BLUE_RARITY, 99F/255F, 135F/255F, 210F/255F), - COAL("black", Util.CRYSTAL_BLACK_RARITY, 0.2F, 0.2F, 0.2F), - EMERALD("green", Util.CRYSTAL_GREEN_RARITY, 54F/255F, 75F/255F, 24F/255F), - IRON("white", Util.CRYSTAL_WHITE_RARITY, 0.8F, 0.8F, 0.8F); + REDSTONE("red", Util.CRYSTAL_RED_RARITY, 0xFF2F21, 158F/255F, 43F/255F, 39F/255F), + LAPIS("blue", Util.CRYSTAL_BLUE_RARITY, 0x5171FF, 37F/255F, 49F/255F, 147F/255F), + DIAMOND("light_blue", Util.CRYSTAL_LIGHT_BLUE_RARITY, 0x35F1FF, 99F/255F, 135F/255F, 210F/255F), + COAL("black", Util.CRYSTAL_BLACK_RARITY, 0x434442, 0.2F, 0.2F, 0.2F), + EMERALD("green", Util.CRYSTAL_GREEN_RARITY, 0x44E033, 54F/255F, 75F/255F, 24F/255F), + IRON("white", Util.CRYSTAL_WHITE_RARITY, 0xCEDDD4, 0.8F, 0.8F, 0.8F); public final String name; public final EnumRarity rarity; public final float[] conversionColorParticles; + public final int clusterColor; - TheCrystals(String name, EnumRarity rarity, float... conversionColorParticles){ + TheCrystals(String name, EnumRarity rarity, int clusterColor, float... conversionColorParticles){ this.name = name; this.rarity = rarity; this.conversionColorParticles = conversionColorParticles; + this.clusterColor = clusterColor; } @Override diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/ClientProxy.java b/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/ClientProxy.java index 1f5de5337..1684789c8 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/ClientProxy.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/ClientProxy.java @@ -18,6 +18,7 @@ import de.ellpeck.actuallyadditions.mod.fluids.InitFluids; import de.ellpeck.actuallyadditions.mod.misc.special.SpecialRenderInit; import de.ellpeck.actuallyadditions.mod.tile.*; import de.ellpeck.actuallyadditions.mod.util.FluidStateMapper; +import de.ellpeck.actuallyadditions.mod.util.IColorProvidingBlock; import de.ellpeck.actuallyadditions.mod.util.IColorProvidingItem; import de.ellpeck.actuallyadditions.mod.util.ModUtil; import net.minecraft.block.Block; @@ -43,6 +44,7 @@ import java.util.Map; public class ClientProxy implements IProxy{ private static final List COLOR_PRODIVIDING_ITEMS_FOR_REGISTERING = new ArrayList(); + private static final List COLOR_PRODIVIDING_BLOCKS_FOR_REGISTERING = new ArrayList(); private static final Map MODEL_LOCATIONS_FOR_REGISTERING = new HashMap(); @Override @@ -98,7 +100,16 @@ public class ClientProxy implements IProxy{ for(Item item : COLOR_PRODIVIDING_ITEMS_FOR_REGISTERING){ if(item instanceof IColorProvidingItem){ - Minecraft.getMinecraft().getItemColors().registerItemColorHandler(((IColorProvidingItem)item).getColor(), item); + Minecraft.getMinecraft().getItemColors().registerItemColorHandler(((IColorProvidingItem)item).getItemColor(), item); + } + } + + for(Block block : COLOR_PRODIVIDING_BLOCKS_FOR_REGISTERING){ + if(block instanceof IColorProvidingBlock){ + Minecraft.getMinecraft().getBlockColors().registerBlockColorHandler(((IColorProvidingBlock)block).getBlockColor(), block); + } + if(block instanceof IColorProvidingItem){ + Minecraft.getMinecraft().getItemColors().registerItemColorHandler(((IColorProvidingItem)block).getItemColor(), block); } } } @@ -120,6 +131,11 @@ public class ClientProxy implements IProxy{ COLOR_PRODIVIDING_ITEMS_FOR_REGISTERING.add(item); } + @Override + public void addColoredBlock(Block block){ + COLOR_PRODIVIDING_BLOCKS_FOR_REGISTERING.add(block); + } + @Override public EntityPlayer getCurrentPlayer(){ return Minecraft.getMinecraft().player; diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/IProxy.java b/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/IProxy.java index 54bfb57b8..1aa2ec9e3 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/IProxy.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/IProxy.java @@ -10,6 +10,7 @@ package de.ellpeck.actuallyadditions.mod.proxy; +import net.minecraft.block.Block; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; @@ -30,5 +31,8 @@ public interface IProxy{ void addColoredItem(Item item); + void addColoredBlock(Block block); + EntityPlayer getCurrentPlayer(); + } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/ServerProxy.java b/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/ServerProxy.java index d05353f97..6a47c631b 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/ServerProxy.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/proxy/ServerProxy.java @@ -11,6 +11,7 @@ package de.ellpeck.actuallyadditions.mod.proxy; import de.ellpeck.actuallyadditions.mod.util.ModUtil; +import net.minecraft.block.Block; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.item.Item; import net.minecraft.item.ItemStack; @@ -46,6 +47,11 @@ public class ServerProxy implements IProxy{ } + @Override + public void addColoredBlock(Block block){ + + } + @Override public EntityPlayer getCurrentPlayer(){ return null; diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/util/IColorProvidingBlock.java b/src/main/java/de/ellpeck/actuallyadditions/mod/util/IColorProvidingBlock.java new file mode 100644 index 000000000..eb3dada13 --- /dev/null +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/util/IColorProvidingBlock.java @@ -0,0 +1,22 @@ +/* + * This file ("IColorProvidingBlock.java") is part of the Actually Additions mod for Minecraft. + * It is created and owned by Ellpeck and distributed + * under the Actually Additions License to be found at + * http://ellpeck.de/actaddlicense + * View the source code at https://github.com/Ellpeck/ActuallyAdditions + * + * © 2015-2017 Ellpeck + */ + +package de.ellpeck.actuallyadditions.mod.util; + +import net.minecraft.client.renderer.color.IBlockColor; +import net.minecraftforge.fml.relauncher.Side; +import net.minecraftforge.fml.relauncher.SideOnly; + +public interface IColorProvidingBlock{ + + @SideOnly(Side.CLIENT) + IBlockColor getBlockColor(); + +} diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/util/IColorProvidingItem.java b/src/main/java/de/ellpeck/actuallyadditions/mod/util/IColorProvidingItem.java index 0a89b0064..080f9d0de 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/util/IColorProvidingItem.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/util/IColorProvidingItem.java @@ -17,6 +17,6 @@ import net.minecraftforge.fml.relauncher.SideOnly; public interface IColorProvidingItem{ @SideOnly(Side.CLIENT) - IItemColor getColor(); + IItemColor getItemColor(); } diff --git a/src/main/java/de/ellpeck/actuallyadditions/mod/util/ItemUtil.java b/src/main/java/de/ellpeck/actuallyadditions/mod/util/ItemUtil.java index e904b9bab..e8f570e36 100644 --- a/src/main/java/de/ellpeck/actuallyadditions/mod/util/ItemUtil.java +++ b/src/main/java/de/ellpeck/actuallyadditions/mod/util/ItemUtil.java @@ -55,6 +55,10 @@ public final class ItemUtil{ IMCHandler.doBlockIMC(block); + if(block instanceof IColorProvidingBlock){ + ActuallyAdditions.proxy.addColoredBlock(block); + } + addUnderscoreNameToMapUnderscorelessName(block.getRegistryName()); } diff --git a/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_coal.json b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_coal.json new file mode 100644 index 000000000..1378a5f87 --- /dev/null +++ b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_coal.json @@ -0,0 +1,22 @@ +{ + "forge_marker": 1, + "defaults": { + "model": "actuallyadditions:block_crystal_cluster", + "textures": { + "particle": "actuallyadditions:blocks/block_crystal_cluster" + }, + "transform": "forge:default-block" + }, + "variants": { + "normal": [{}], + "inventory": [{}], + "facing": { + "down": { "x": 180 }, + "up": {}, + "north": { "x": 90 }, + "south": { "x": 270 }, + "west": { "x": 90, "y": 270 }, + "east": { "x": 270, "y": 270 } + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_diamond.json b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_diamond.json new file mode 100644 index 000000000..1378a5f87 --- /dev/null +++ b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_diamond.json @@ -0,0 +1,22 @@ +{ + "forge_marker": 1, + "defaults": { + "model": "actuallyadditions:block_crystal_cluster", + "textures": { + "particle": "actuallyadditions:blocks/block_crystal_cluster" + }, + "transform": "forge:default-block" + }, + "variants": { + "normal": [{}], + "inventory": [{}], + "facing": { + "down": { "x": 180 }, + "up": {}, + "north": { "x": 90 }, + "south": { "x": 270 }, + "west": { "x": 90, "y": 270 }, + "east": { "x": 270, "y": 270 } + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_emerald.json b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_emerald.json new file mode 100644 index 000000000..1378a5f87 --- /dev/null +++ b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_emerald.json @@ -0,0 +1,22 @@ +{ + "forge_marker": 1, + "defaults": { + "model": "actuallyadditions:block_crystal_cluster", + "textures": { + "particle": "actuallyadditions:blocks/block_crystal_cluster" + }, + "transform": "forge:default-block" + }, + "variants": { + "normal": [{}], + "inventory": [{}], + "facing": { + "down": { "x": 180 }, + "up": {}, + "north": { "x": 90 }, + "south": { "x": 270 }, + "west": { "x": 90, "y": 270 }, + "east": { "x": 270, "y": 270 } + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_iron.json b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_iron.json new file mode 100644 index 000000000..1378a5f87 --- /dev/null +++ b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_iron.json @@ -0,0 +1,22 @@ +{ + "forge_marker": 1, + "defaults": { + "model": "actuallyadditions:block_crystal_cluster", + "textures": { + "particle": "actuallyadditions:blocks/block_crystal_cluster" + }, + "transform": "forge:default-block" + }, + "variants": { + "normal": [{}], + "inventory": [{}], + "facing": { + "down": { "x": 180 }, + "up": {}, + "north": { "x": 90 }, + "south": { "x": 270 }, + "west": { "x": 90, "y": 270 }, + "east": { "x": 270, "y": 270 } + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_lapis.json b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_lapis.json new file mode 100644 index 000000000..1378a5f87 --- /dev/null +++ b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_lapis.json @@ -0,0 +1,22 @@ +{ + "forge_marker": 1, + "defaults": { + "model": "actuallyadditions:block_crystal_cluster", + "textures": { + "particle": "actuallyadditions:blocks/block_crystal_cluster" + }, + "transform": "forge:default-block" + }, + "variants": { + "normal": [{}], + "inventory": [{}], + "facing": { + "down": { "x": 180 }, + "up": {}, + "north": { "x": 90 }, + "south": { "x": 270 }, + "west": { "x": 90, "y": 270 }, + "east": { "x": 270, "y": 270 } + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_redstone.json b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_redstone.json new file mode 100644 index 000000000..1378a5f87 --- /dev/null +++ b/src/main/resources/assets/actuallyadditions/blockstates/block_crystal_cluster_redstone.json @@ -0,0 +1,22 @@ +{ + "forge_marker": 1, + "defaults": { + "model": "actuallyadditions:block_crystal_cluster", + "textures": { + "particle": "actuallyadditions:blocks/block_crystal_cluster" + }, + "transform": "forge:default-block" + }, + "variants": { + "normal": [{}], + "inventory": [{}], + "facing": { + "down": { "x": 180 }, + "up": {}, + "north": { "x": 90 }, + "south": { "x": 270 }, + "west": { "x": 90, "y": 270 }, + "east": { "x": 270, "y": 270 } + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/actuallyadditions/lang/en_US.lang b/src/main/resources/assets/actuallyadditions/lang/en_US.lang index 55ee4907d..421a3c9e3 100644 --- a/src/main/resources/assets/actuallyadditions/lang/en_US.lang +++ b/src/main/resources/assets/actuallyadditions/lang/en_US.lang @@ -239,6 +239,12 @@ tile.actuallyadditions.block_distributor_item.name=Item Distributor tile.actuallyadditions.block_bio_reactor.name=Bio Reactor tile.actuallyadditions.block_farmer.name=Farmer tile.actuallyadditions.block_battery_box.name=Battery Box +tile.actuallyadditions.block_crystal_cluster_redstone.name=Red Crystal Cluster +tile.actuallyadditions.block_crystal_cluster_lapis.name=Blue Crystal Cluster +tile.actuallyadditions.block_crystal_cluster_diamond.name=Light Blue Crystal Cluster +tile.actuallyadditions.block_crystal_cluster_coal.name=Black Crystal Cluster +tile.actuallyadditions.block_crystal_cluster_emerald.name=Green Crystal Cluster +tile.actuallyadditions.block_crystal_cluster_iron.name=White Crystal Cluster #ESD tile.actuallyadditions.block_inputter.name=ESD @@ -523,6 +529,12 @@ item.actuallyadditions.item_filling_wand.name=Handheld Filler item.actuallyadditions.item_laser_upgrade_invisibility.name=Laser Relay Modifier: Invisibility item.actuallyadditions.item_infrared_goggles.name=Infrared Goggles item.actuallyadditions.item_laser_upgrade_range.name=Laser Relay Modifier: Range +item.actuallyadditions.item_crystal_shard_red.name=Red Crystal Shard +item.actuallyadditions.item_crystal_shard_blue.name=Blue Crystal Shard +item.actuallyadditions.item_crystal_shard_light_blue.name=Light Blue Crystal Shard +item.actuallyadditions.item_crystal_shard_black.name=Black Crystal Shard +item.actuallyadditions.item_crystal_shard_green.name=Green Crystal Shard +item.actuallyadditions.item_crystal_shard_white.name=White Crystal Shard #Tooltips tooltip.actuallyadditions.onSuffix.desc=On diff --git a/src/main/resources/assets/actuallyadditions/models/block/block_crystal_cluster.json b/src/main/resources/assets/actuallyadditions/models/block/block_crystal_cluster.json new file mode 100644 index 000000000..500bbf9d4 --- /dev/null +++ b/src/main/resources/assets/actuallyadditions/models/block/block_crystal_cluster.json @@ -0,0 +1,207 @@ +{ + "__comment": "Model generated using MrCrayfish's Model Creator (http://mrcrayfish.com/modelcreator/)", + "textures": { + "0": "actuallyadditions:blocks/block_crystal_cluster" + }, + "elements": [ + { + "name": "Cube", + "from": [ 4.0, 1.0, 0.0 ], + "to": [ 7.0, 7.0, 7.0 ], + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 6.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 7.0, 6.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 7.0 ], "tintindex": 0 }, + "down": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 7.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 11.0, 0.0, 0.0 ], + "to": [ 18.0, 4.0, 9.0 ], + "rotation": { "origin": [ 11.0, 6.0, 0.0 ], "axis": "y", "angle": -45.0 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 7.0, 4.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 9.0, 4.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 7.0, 9.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 7.900000013411045, 0.0, 7.899999998509884 ], + "to": [ 13.900000013411045, 8.0, 13.899999998509884 ], + "rotation": { "origin": [ 13.0, 8.0, 8.0 ], "axis": "y", "angle": -22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 6.0, 8.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 6.0, 8.0 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 6.0, 8.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 6.0, 8.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 6.0, 6.0 ], "tintindex": 0 }, + "down": { "texture": "#0", "uv": [ 0.0, 0.0, 6.0, 6.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 1.0, 2.0, 8.0 ], + "to": [ 10.700000010430813, 6.0, 13.899999998509884 ], + "rotation": { "origin": [ 4.0, 6.0, 8.0 ], "axis": "x", "angle": 22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 9.700000010430813, 4.0 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 9.700000010430813, 4.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 5.899999998509884, 4.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 9.700000010430813, 5.899999998509884 ], "tintindex": 0 }, + "down": { "texture": "#0", "uv": [ 0.0, 0.0, 9.700000010430813, 5.899999998509884 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 1.0, 0.0, 8.0 ], + "to": [ 13.0, 3.0, 16.600000008940697 ], + "rotation": { "origin": [ 1.0, 6.0, 8.0 ], "axis": "y", "angle": 22.5 }, + "faces": { + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 8.600000008940697, 3.0 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 12.0, 3.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 8.600000008940697, 3.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 12.0, 8.600000008940697 ], "tintindex": 0}, + "down": { "texture": "#0", "uv": [ 0.0, 0.0, 12.0, 8.600000008940697 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 5.799999997019768, 4.899999983608723, -2.0 ], + "to": [ 9.799999997019768, 19.899999983608723, 2.0 ], + "rotation": { "origin": [ 1.0, 6.0, 1.0 ], "axis": "y", "angle": -22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 4.0, 15.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 4.0, 15.0 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 4.0, 15.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 4.0, 15.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 4.0, 4.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 1.5000000670552254, 0.9000000134110451, 0.0 ], + "to": [ 4.000000059604645, 7.0, 8.0 ], + "rotation": { "origin": [ 4.0, 7.0, 8.0 ], "axis": "z", "angle": 22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 2.4999999925494194, 6.099999986588955 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 8.0, 6.099999986588955 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 2.4999999925494194, 8.0 ], "tintindex": 0 }, + "down": { "texture": "#0", "uv": [ 0.0, 0.0, 2.4999999925494194, 8.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 1.0000000149011612, 0.0, 4.0 ], + "to": [ 3.299999989569187, 4.099999986588955, 8.0 ], + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 2.299999974668026, 4.099999986588955 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 4.0, 4.099999986588955 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 2.299999974668026, 4.0 ], "tintindex": 0 }, + "down": { "texture": "#0", "uv": [ 0.0, 0.0, 2.299999974668026, 4.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 5.0, 4.0, 4.399999991059303 ], + "to": [ 8.0, 14.0, 7.399999991059303 ], + "rotation": { "origin": [ 6.799999997019768, 7.000000014901161, 0.9000000134110451 ], "axis": "z", "angle": 45.0 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 3.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 8.100000001490116, 7.999999985098839, 9.0 ], + "to": [ 11.100000001490116, 19.49999999254942, 12.0 ], + "rotation": { "origin": [ 8.099999986588955, 8.000000014901161, 11.000000014901161 ], "axis": "z", "angle": -22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 11.50000000745058 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 11.50000000745058 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 11.50000000745058 ], "tintindex": 0}, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 11.50000000745058 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 3.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 5.900000013411045, 4.0, 6.799999997019768 ], + "to": [ 8.900000013411045, 14.0, 9.799999997019768 ], + "rotation": { "origin": [ 8.0, 7.100000016391277, 4.900000013411045 ], "axis": "x", "angle": 22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 3.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 10.0, 3.0, 3.0 ], + "to": [ 13.0, 11.0, 8.0 ], + "rotation": { "origin": [ 13.0, 4.0, 4.0 ], "axis": "z", "angle": -22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 8.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 5.0, 8.0 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 8.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 5.0, 8.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 5.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 1.4901161193847656E-8, 0.0, -1.5999999940395355 ], + "to": [ 5.799999997019768, 2.099999986588955, 4.000000029802322 ], + "rotation": { "origin": [ 0.0, 8.0, 4.0 ], "axis": "y", "angle": -45.0 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 5.799999982118607, 2.099999986588955 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 5.799999982118607, 2.099999986588955 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 5.600000023841858, 2.099999986588955 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 5.799999982118607, 5.600000023841858 ], "tintindex": 0 }, + "down": { "texture": "#0", "uv": [ 0.0, 0.0, 5.799999982118607, 5.600000023841858 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 4.0, 0.0, 0.8999999985098839 ], + "to": [ 7.0, 6.0, 7.899999998509884 ], + "rotation": { "origin": [ 7.200000002980232, 8.0, -1.0 ], "axis": "y", "angle": 22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 6.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 7.0, 6.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 7.0 ], "tintindex": 0 }, + "down": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 7.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 7.300000004470348, 0.0, 0.0 ], + "to": [ 11.300000004470348, 5.0, 7.0 ], + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 4.0, 5.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 7.0, 5.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 7.0, 5.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 4.0, 7.0 ], "tintindex": 0 } + } + }, + { + "name": "Cube", + "from": [ 1.900000013411045, 5.0, 10.799999997019768 ], + "to": [ 4.900000013411045, 15.0, 13.799999997019768 ], + "rotation": { "origin": [ 13.0, 18.100000016391277, -0.3999999910593033 ], "axis": "x", "angle": 22.5 }, + "faces": { + "north": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "east": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "south": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "west": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 10.0 ], "tintindex": 0 }, + "up": { "texture": "#0", "uv": [ 0.0, 0.0, 3.0, 3.0 ], "tintindex": 0 } + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/actuallyadditions/models/item/item_crystal_shard.json b/src/main/resources/assets/actuallyadditions/models/item/item_crystal_shard.json new file mode 100644 index 000000000..c668106f6 --- /dev/null +++ b/src/main/resources/assets/actuallyadditions/models/item/item_crystal_shard.json @@ -0,0 +1,6 @@ +{ + "parent": "actuallyadditions:item/standard_item", + "textures": { + "layer0": "actuallyadditions:items/item_crystal_shard" + } +} diff --git a/src/main/resources/assets/actuallyadditions/textures/blocks/block_crystal_cluster.png b/src/main/resources/assets/actuallyadditions/textures/blocks/block_crystal_cluster.png new file mode 100644 index 0000000000000000000000000000000000000000..5a3d50ce07c2aba4fc5475183a615a303594b440 GIT binary patch literal 3071 zcmV004&%004{+008|`004nN004b?008NW002DY000@xb3BE2000U( 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 Bbans$ literal 0 HcmV?d00001