From e00f9850b39370fd8831c37c0549913b49e4609a Mon Sep 17 00:00:00 2001 From: Sollace Date: Sat, 2 Mar 2019 18:45:28 +0200 Subject: [PATCH] Added hanging cuccoons (WIP) --- .../unicopia/block/BlockGrowingCuccoon.java | 286 ++++++++++++++++++ .../unicopia/block/BlockHiveWall.java | 5 +- .../minelittlepony/unicopia/init/UBlocks.java | 4 +- .../minelittlepony/unicopia/init/UItems.java | 5 +- .../assets/unicopia/blockstates/cuccoon.json | 20 ++ .../models/block/cuccoon/bulb_stage0.json | 30 ++ .../models/block/cuccoon/bulb_stage1.json | 30 ++ .../models/block/cuccoon/bulb_stage2.json | 30 ++ .../models/block/cuccoon/bulb_stage3.json | 30 ++ .../models/block/cuccoon/string_stage0.json | 19 ++ .../models/block/cuccoon/string_stage1.json | 19 ++ .../models/block/cuccoon/string_stage2.json | 19 ++ .../models/block/cuccoon/string_stage3.json | 19 ++ .../assets/unicopia/models/item/cuccoon.json | 6 + .../unicopia/textures/blocks/cuccoon_bulb.png | Bin 0 -> 3436 bytes .../unicopia/textures/blocks/cuccoon_tail.png | Bin 0 -> 3279 bytes 16 files changed, 518 insertions(+), 4 deletions(-) create mode 100644 src/main/java/com/minelittlepony/unicopia/block/BlockGrowingCuccoon.java create mode 100644 src/main/resources/assets/unicopia/blockstates/cuccoon.json create mode 100644 src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage0.json create mode 100644 src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage1.json create mode 100644 src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage2.json create mode 100644 src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage3.json create mode 100644 src/main/resources/assets/unicopia/models/block/cuccoon/string_stage0.json create mode 100644 src/main/resources/assets/unicopia/models/block/cuccoon/string_stage1.json create mode 100644 src/main/resources/assets/unicopia/models/block/cuccoon/string_stage2.json create mode 100644 src/main/resources/assets/unicopia/models/block/cuccoon/string_stage3.json create mode 100644 src/main/resources/assets/unicopia/models/item/cuccoon.json create mode 100644 src/main/resources/assets/unicopia/textures/blocks/cuccoon_bulb.png create mode 100644 src/main/resources/assets/unicopia/textures/blocks/cuccoon_tail.png diff --git a/src/main/java/com/minelittlepony/unicopia/block/BlockGrowingCuccoon.java b/src/main/java/com/minelittlepony/unicopia/block/BlockGrowingCuccoon.java new file mode 100644 index 00000000..cc0a2b89 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/BlockGrowingCuccoon.java @@ -0,0 +1,286 @@ +package com.minelittlepony.unicopia.block; + +import java.util.List; +import java.util.Random; + +import javax.annotation.Nullable; + +import com.minelittlepony.unicopia.init.UBlocks; +import com.minelittlepony.unicopia.init.UMaterials; +import com.minelittlepony.unicopia.init.USounds; +import com.minelittlepony.util.PosHelper; + +import net.minecraft.block.Block; +import net.minecraft.block.SoundType; +import net.minecraft.block.properties.PropertyEnum; +import net.minecraft.block.properties.PropertyInteger; +import net.minecraft.block.state.BlockStateContainer; +import net.minecraft.block.state.IBlockState; +import net.minecraft.creativetab.CreativeTabs; +import net.minecraft.entity.Entity; +import net.minecraft.init.Items; +import net.minecraft.item.Item; +import net.minecraft.util.BlockRenderLayer; +import net.minecraft.util.EnumFacing; +import net.minecraft.util.IStringSerializable; +import net.minecraft.util.SoundCategory; +import net.minecraft.util.math.AxisAlignedBB; +import net.minecraft.util.math.BlockPos; +import net.minecraft.util.math.Vec3d; +import net.minecraft.world.IBlockAccess; +import net.minecraft.world.World; + +public class BlockGrowingCuccoon extends Block { + + public static final PropertyInteger AGE = PropertyInteger.create("age", 0, 7); + public static final PropertyEnum SHAPE = PropertyEnum.create("shape", Shape.class); + + public static final AxisAlignedBB[] SHAFTS = new AxisAlignedBB[] { + new AxisAlignedBB(7/16F, 0, 7/16F, 9/16F, 1, 7/16F), + new AxisAlignedBB(6/16F, 0, 6/16F, 10/16F, 1, 10/16F), + new AxisAlignedBB(5/16F, 0, 5/16F, 11/16F, 1, 11/16F), + new AxisAlignedBB(4/16F, 0, 4/16F, 12/16F, 1, 12/16F) + }; + public static final AxisAlignedBB[] BULBS = new AxisAlignedBB[] { + new AxisAlignedBB(6/16F, 1/16F, 6/16F, 10/16F, 8/16F, 10/16F), + new AxisAlignedBB(4/16F, 0, 4/16F, 12/16F, 9/16F, 12/16F), + new AxisAlignedBB(3/16F, 0, 3/16F, 13/16F, 10/16F, 13/16F), + new AxisAlignedBB(2/16F, 0, 2/16F, 14/16F, 12/16F, 14/16F), + }; + + public BlockGrowingCuccoon(String domain, String name) { + super(UMaterials.hive); + + setTranslationKey(name); + setRegistryName(domain, name); + setResistance(0); + setSoundType(SoundType.SLIME); + setCreativeTab(CreativeTabs.MATERIALS); + setDefaultSlipperiness(0.5F); + setHarvestLevel("shovel", 2); + setLightLevel(0.6F); + setLightOpacity(0); + + useNeighborBrightness = true; + + setDefaultState(getBlockState().getBaseState() + .withProperty(AGE, 0) + .withProperty(SHAPE, Shape.BULB)); + } + + @Override + public boolean isTranslucent(IBlockState state) { + return true; + } + + @Override + public boolean isOpaqueCube(IBlockState state) { + return false; + } + + @Override + //Push player out of block + public boolean isFullCube(IBlockState state) { + return false; + } + + @Override + public boolean isNormalCube(IBlockState state) { + return false; + } + + @Override + public BlockRenderLayer getRenderLayer() { + return BlockRenderLayer.TRANSLUCENT; + } + + @Deprecated + @Override + public AxisAlignedBB getCollisionBoundingBox(IBlockState state, IBlockAccess world, BlockPos pos) { + return getBoundingBox(state, world, pos); + } + + @Override + public Block.EnumOffsetType getOffsetType() { + return Block.EnumOffsetType.XZ; + } + + @Override + public void updateTick(World world, BlockPos pos, IBlockState state, Random rand) { + if (!checkSupport(world, pos)) { + world.destroyBlock(pos, true); + return; + } + + int age = state.getValue(AGE); + + BlockPos below = pos.down(); + + if (world.isBlockLoaded(below)) { + boolean spaceBelow = world.isAirBlock(below); + + Shape shape = state.getValue(SHAPE); + + if (shape == Shape.STRING && spaceBelow) { + world.setBlockState(pos, state.withProperty(SHAPE, Shape.BULB).withProperty(AGE, age / 2)); + } else if (shape == Shape.BULB && !spaceBelow) { + world.setBlockState(pos, state.withProperty(SHAPE, Shape.STRING).withProperty(AGE, age / 2)); + } else if (age >= 7) { + if (rand.nextInt(12) == 0 && spaceBelow) { + world.setBlockState(below, state.withProperty(AGE, age / 2)); + world.setBlockState(pos, getDefaultState().withProperty(AGE, age / 2).withProperty(SHAPE, Shape.STRING)); + world.playSound(null, pos, USounds.SLIME_ADVANCE, SoundCategory.BLOCKS, 1, 1); + } + } else { + if (age < getMaximumAge(world, pos, state, spaceBelow)) { + if (rand.nextInt(5 * (age + 1)) == 0) { + world.setBlockState(pos, state.cycleProperty(AGE)); + } + } + } + } + + world.scheduleUpdate(pos, this, tickRate(world)); + } + + protected int getMaximumAge(World world, BlockPos pos, IBlockState state, boolean spaceBelow) { + if (state.getValue(SHAPE) == Shape.STRING) { + IBlockState higher = world.getBlockState(pos.up()); + + if (higher.getBlock() != this) { + return 7; + } + + return ((BlockGrowingCuccoon)higher.getBlock()).getMaximumAge(world, pos.up(), higher, false) - 1; + } + + if (!spaceBelow) { + return 0; + } + + return 7; + } + + @Override + public Item getItemDropped(IBlockState state, Random rand, int fortune) { + return Items.SLIME_BALL; + } + + @Override + public void dropBlockAsItemWithChance(World world, BlockPos pos, IBlockState state, float chance, int fortune) { + if (state.getValue(AGE) == 7) { + super.dropBlockAsItemWithChance(world, pos, state, chance, fortune); + } + } + + @Override + public boolean canPlaceBlockAt(World world, BlockPos pos) { + return super.canPlaceBlockAt(world, pos) && checkSupport(world, pos); + } + + @Override + public void onNeighborChange(IBlockAccess world, BlockPos pos, BlockPos neighbor) { + if (world instanceof World && !checkSupport(world, pos)) { + ((World)world).destroyBlock(pos, true); + } + } + + @Override + public void breakBlock(World world, BlockPos pos, IBlockState state) { + world.notifyNeighborsOfStateChange(pos, this, true); + super.breakBlock(world, pos, state); + } + + @Override + public void onBlockAdded(World world, BlockPos pos, IBlockState state) { + world.scheduleUpdate(pos, this, 10); + } + + public boolean checkSupport(IBlockAccess world, BlockPos pos) { + + if (PosHelper.some(pos, p -> !world.isAirBlock(p), EnumFacing.HORIZONTALS)) { + return false; + } + + pos = pos.up(); + + IBlockState above = world.getBlockState(pos); + + if (above.getBlock() == this || above.getBlock() == UBlocks.hive) { + return true; + } + + switch (above.getBlockFaceShape(world, pos, EnumFacing.DOWN)) { + case SOLID: + case CENTER: + case CENTER_BIG: + case CENTER_SMALL: return true; + default: return false; + } + } + + @Deprecated + @Override + public void addCollisionBoxToList(IBlockState state, World world, BlockPos pos, AxisAlignedBB entityBox, List collidingBoxes, @Nullable Entity entity, boolean isActualState) { + if (!isActualState) { + state = state.getActualState(world, pos); + } + + int age = state.getValue(AGE) / 2; + + Vec3d offset = state.getOffset(world, pos); + + addCollisionBoxToList(pos, entityBox, collidingBoxes, SHAFTS[age % SHAFTS.length].offset(offset)); + + if (state.getValue(SHAPE) == Shape.BULB) { + addCollisionBoxToList(pos, entityBox, collidingBoxes, BULBS[age % BULBS.length].offset(offset)); + } + } + + @Deprecated + @Override + public AxisAlignedBB getBoundingBox(IBlockState state, IBlockAccess source, BlockPos pos) { + state = state.getActualState(source, pos); + + if (state.getValue(SHAPE) == Shape.BULB) { + return BULBS[state.getValue(AGE) / 2].offset(state.getOffset(source, pos)); + } + + return SHAFTS[state.getValue(AGE) / 2].offset(state.getOffset(source, pos)); + } + + @Override + public IBlockState getStateFromMeta(int meta) { + return getDefaultState() + .withProperty(AGE, meta % 8) + .withProperty(SHAPE, Shape.VALUES[(meta >> 3) % Shape.VALUES.length]); + } + + @Override + public int getMetaFromState(IBlockState state) { + return state.getValue(AGE) | (state.getValue(SHAPE).ordinal() << 3); + } + + @Override + protected BlockStateContainer createBlockState() { + return new BlockStateContainer(this, AGE, SHAPE); + } + + static enum Shape implements IStringSerializable { + BULB, + STRING; + + static final Shape[] VALUES = values(); + + @Override + public String toString() { + return getName(); + } + + @Override + public String getName() { + return name().toLowerCase(); + } + + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/block/BlockHiveWall.java b/src/main/java/com/minelittlepony/unicopia/block/BlockHiveWall.java index b0492ab8..39bee277 100644 --- a/src/main/java/com/minelittlepony/unicopia/block/BlockHiveWall.java +++ b/src/main/java/com/minelittlepony/unicopia/block/BlockHiveWall.java @@ -5,6 +5,7 @@ import java.util.Random; import com.google.common.collect.Maps; import com.minelittlepony.unicopia.Race; +import com.minelittlepony.unicopia.init.UBlocks; import com.minelittlepony.unicopia.init.UMaterials; import com.minelittlepony.unicopia.init.USounds; import com.minelittlepony.unicopia.player.IPlayer; @@ -103,7 +104,9 @@ public class BlockHiveWall extends BlockFalling { } } else { - if (!testForAxis(world, pos, axis)) { + if (pos.getX() % 3 == 0 && pos.getZ() % 4 == 0 && world.isAirBlock(pos.down()) && UBlocks.cuccoon.canPlaceBlockAt(world, pos.down())) { + world.setBlockState(pos.down(), UBlocks.cuccoon.getDefaultState()); + } else if (!testForAxis(world, pos, axis)) { world.setBlockState(pos, state.withProperty(STATE, State.GROWING)); } else if (matchedNeighbours >= 27) { world.setBlockState(pos, state.withProperty(STATE, State.DYING)); diff --git a/src/main/java/com/minelittlepony/unicopia/init/UBlocks.java b/src/main/java/com/minelittlepony/unicopia/init/UBlocks.java index 4f65a2e5..e3fd83aa 100644 --- a/src/main/java/com/minelittlepony/unicopia/init/UBlocks.java +++ b/src/main/java/com/minelittlepony/unicopia/init/UBlocks.java @@ -5,6 +5,7 @@ import com.minelittlepony.unicopia.Unicopia; import com.minelittlepony.unicopia.block.BlockAlfalfa; import com.minelittlepony.unicopia.block.BlockFruitLeaves; import com.minelittlepony.unicopia.block.BlockGlowingGem; +import com.minelittlepony.unicopia.block.BlockGrowingCuccoon; import com.minelittlepony.unicopia.block.BlockHiveWall; import com.minelittlepony.unicopia.block.BlockCloudAnvil; import com.minelittlepony.unicopia.block.BlockCloudBanister; @@ -71,6 +72,7 @@ public class UBlocks { public static final BlockCloudFarm cloud_farmland = new BlockCloudFarm(Unicopia.MODID, "cloud_farmland"); public static final BlockHiveWall hive = new BlockHiveWall(Unicopia.MODID, "hive"); + public static final BlockGrowingCuccoon cuccoon = new BlockGrowingCuccoon(Unicopia.MODID, "cuccoon"); public static final Block sugar_block = new BlockSugar(Unicopia.MODID, "sugar_block"); public static final UPot flower_pot = new UPot(Unicopia.MODID, "flower_pot"); @@ -91,7 +93,7 @@ public class UBlocks { packed_cloud_slab, packed_cloud_slab.doubleSlab, cloud_fence, cloud_banister, mist_door, library_door, bakery_door, - hive, + hive, cuccoon, anvil, cloud_farmland, sugar_block, flower_pot, alfalfa, diff --git a/src/main/java/com/minelittlepony/unicopia/init/UItems.java b/src/main/java/com/minelittlepony/unicopia/init/UItems.java index ccaaf23f..9dfa34b3 100644 --- a/src/main/java/com/minelittlepony/unicopia/init/UItems.java +++ b/src/main/java/com/minelittlepony/unicopia/init/UItems.java @@ -96,6 +96,7 @@ public class UItems { public static final Item anvil = new UItemBlock(UBlocks.anvil, INTERACT_WITH_CLOUDS).setTranslationKey("cloud_anvil"); public static final Item hive = new ItemBlock(UBlocks.hive).setRegistryName(Unicopia.MODID, "hive"); + public static final Item cuccoon = new ItemBlock(UBlocks.cuccoon).setRegistryName(Unicopia.MODID, "cuccoon"); public static final Item mist_door = new ItemDoor(UBlocks.mist_door) .setTranslationKey("mist_door") @@ -232,7 +233,7 @@ public class UItems { cloudsdale_tomato, tomato_seeds, tomato, moss, - hive, + hive, cuccoon, apple_seeds, apple_leaves, @@ -263,7 +264,7 @@ public class UItems { cereal, sugar_cereal, sugar_block, tomato_seeds, - hive, + hive, cuccoon, apple_seeds, apple_leaves, diff --git a/src/main/resources/assets/unicopia/blockstates/cuccoon.json b/src/main/resources/assets/unicopia/blockstates/cuccoon.json new file mode 100644 index 00000000..36c5f0cd --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/cuccoon.json @@ -0,0 +1,20 @@ +{ + "variants": { + "age=0,shape=bulb": { "model": "unicopia:cuccoon/bulb_stage0" }, + "age=1,shape=bulb": { "model": "unicopia:cuccoon/bulb_stage0" }, + "age=2,shape=bulb": { "model": "unicopia:cuccoon/bulb_stage1" }, + "age=3,shape=bulb": { "model": "unicopia:cuccoon/bulb_stage1" }, + "age=4,shape=bulb": { "model": "unicopia:cuccoon/bulb_stage2" }, + "age=5,shape=bulb": { "model": "unicopia:cuccoon/bulb_stage2" }, + "age=6,shape=bulb": { "model": "unicopia:cuccoon/bulb_stage3" }, + "age=7,shape=bulb": { "model": "unicopia:cuccoon/bulb_stage3" }, + "age=0,shape=string": { "model": "unicopia:cuccoon/string_stage0" }, + "age=1,shape=string": { "model": "unicopia:cuccoon/string_stage0" }, + "age=2,shape=string": { "model": "unicopia:cuccoon/string_stage1" }, + "age=3,shape=string": { "model": "unicopia:cuccoon/string_stage1" }, + "age=4,shape=string": { "model": "unicopia:cuccoon/string_stage2" }, + "age=5,shape=string": { "model": "unicopia:cuccoon/string_stage2" }, + "age=6,shape=string": { "model": "unicopia:cuccoon/string_stage3" }, + "age=7,shape=string": { "model": "unicopia:cuccoon/string_stage3" } + } +} diff --git a/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage0.json b/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage0.json new file mode 100644 index 00000000..1df558d4 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage0.json @@ -0,0 +1,30 @@ +{ + "textures": { + "bulb": "unicopia:blocks/cuccoon_bulb", + "tail": "unicopia:blocks/cuccoon_tail", + "particle": "unicopia:blocks/cuccoon_bulb" + }, + "elements": [ + { "from": [ 7, 8, 7 ], + "to": [ 9, 16, 9 ], + "faces": { + "up": { "uv": [ 7, 7, 9, 9 ], "texture": "#tail", "cullface": "up" }, + "north": { "uv": [ 7, 8, 9, 16 ], "texture": "#tail", "cullface": "north" }, + "south": { "uv": [ 7, 8, 9, 16 ], "texture": "#tail", "cullface": "south" }, + "west": { "uv": [ 7, 8, 9, 16 ], "texture": "#tail", "cullface": "west" }, + "east": { "uv": [ 7, 8, 9, 16 ], "texture": "#tail", "cullface": "east" } + } + }, + { "from": [ 6, 1, 6 ], + "to": [ 10, 8, 10 ], + "faces": { + "up": { "uv": [ 6, 6, 10, 10 ], "texture": "#bulb" }, + "down": { "uv": [ 6, 6, 10, 10 ], "texture": "#bulb" }, + "north": { "uv": [ 6, 1, 10, 8 ], "texture": "#bulb" }, + "south": { "uv": [ 6, 1, 10, 8 ], "texture": "#bulb" }, + "west": { "uv": [ 6, 1, 10, 8 ], "texture": "#bulb" }, + "east": { "uv": [ 6, 1, 10, 8 ], "texture": "#bulb" } + } + } + ] +} diff --git a/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage1.json b/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage1.json new file mode 100644 index 00000000..dda83343 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage1.json @@ -0,0 +1,30 @@ +{ + "textures": { + "bulb": "unicopia:blocks/cuccoon_bulb", + "tail": "unicopia:blocks/cuccoon_tail", + "particle": "unicopia:blocks/cuccoon_bulb" + }, + "elements": [ + { "from": [ 6, 8, 6 ], + "to": [ 10, 16, 10 ], + "faces": { + "up": { "uv": [ 6, 6, 10, 10 ], "texture": "#tail", "cullface": "up" }, + "north": { "uv": [ 6, 8, 10, 16 ], "texture": "#tail", "cullface": "north" }, + "south": { "uv": [ 6, 8, 10, 16 ], "texture": "#tail", "cullface": "south" }, + "west": { "uv": [ 6, 8, 10, 16 ], "texture": "#tail", "cullface": "west" }, + "east": { "uv": [ 6, 8, 10, 16 ], "texture": "#tail", "cullface": "east" } + } + }, + { "from": [ 4, 0, 4 ], + "to": [ 12, 9, 12 ], + "faces": { + "up": { "uv": [ 4, 4, 12, 12 ], "texture": "#bulb" }, + "down": { "uv": [ 4, 4, 12, 12 ], "texture": "#bulb" }, + "north": { "uv": [ 4, 0, 12, 9 ], "texture": "#bulb" }, + "south": { "uv": [ 4, 0, 12, 9 ], "texture": "#bulb" }, + "west": { "uv": [ 4, 0, 12, 9 ], "texture": "#bulb" }, + "east": { "uv": [ 4, 0, 12, 9 ], "texture": "#bulb" } + } + } + ] +} diff --git a/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage2.json b/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage2.json new file mode 100644 index 00000000..d2c76aea --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage2.json @@ -0,0 +1,30 @@ +{ + "textures": { + "bulb": "unicopia:blocks/cuccoon_bulb", + "tail": "unicopia:blocks/cuccoon_tail", + "particle": "unicopia:blocks/cuccoon_bulb" + }, + "elements": [ + { "from": [ 5, 8, 5 ], + "to": [ 11, 16, 11 ], + "faces": { + "up": { "uv": [ 5, 5, 11, 11 ], "texture": "#tail", "cullface": "up" }, + "north": { "uv": [ 5, 8, 11, 16 ], "texture": "#tail", "cullface": "north" }, + "south": { "uv": [ 5, 8, 11, 16 ], "texture": "#tail", "cullface": "south" }, + "west": { "uv": [ 5, 8, 11, 16 ], "texture": "#tail", "cullface": "west" }, + "east": { "uv": [ 5, 8, 11, 16 ], "texture": "#tail", "cullface": "east" } + } + }, + { "from": [ 3, 0, 3 ], + "to": [ 13, 10, 13 ], + "faces": { + "up": { "uv": [ 3, 3, 13, 13 ], "texture": "#bulb" }, + "down": { "uv": [ 3, 3, 13, 13 ], "texture": "#bulb" }, + "north": { "uv": [ 3, 0, 13, 10 ], "texture": "#bulb" }, + "south": { "uv": [ 3, 0, 13, 10 ], "texture": "#bulb" }, + "west": { "uv": [ 3, 0, 13, 10 ], "texture": "#bulb" }, + "east": { "uv": [ 3, 0, 13, 10 ], "texture": "#bulb" } + } + } + ] +} diff --git a/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage3.json b/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage3.json new file mode 100644 index 00000000..99b767c9 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cuccoon/bulb_stage3.json @@ -0,0 +1,30 @@ +{ + "textures": { + "bulb": "unicopia:blocks/cuccoon_bulb", + "tail": "unicopia:blocks/cuccoon_tail", + "particle": "unicopia:blocks/cuccoon_bulb" + }, + "elements": [ + { "from": [ 4, 8, 4 ], + "to": [ 12, 16, 12 ], + "faces": { + "up": { "uv": [ 4, 4, 12, 12 ], "texture": "#tail", "cullface": "up" }, + "north": { "uv": [ 4, 8, 12, 16 ], "texture": "#tail", "cullface": "north" }, + "south": { "uv": [ 4, 8, 12, 16 ], "texture": "#tail", "cullface": "south" }, + "west": { "uv": [ 4, 8, 12, 16 ], "texture": "#tail", "cullface": "west" }, + "east": { "uv": [ 4, 8, 12, 16 ], "texture": "#tail", "cullface": "east" } + } + }, + { "from": [ 2, 0, 2 ], + "to": [ 14, 12, 14 ], + "faces": { + "up": { "uv": [ 2, 2, 14, 14 ], "texture": "#bulb" }, + "down": { "uv": [ 2, 2, 14, 14 ], "texture": "#bulb" }, + "north": { "uv": [ 2, 0, 14, 12 ], "texture": "#bulb" }, + "south": { "uv": [ 2, 0, 14, 12 ], "texture": "#bulb" }, + "west": { "uv": [ 2, 0, 14, 12 ], "texture": "#bulb" }, + "east": { "uv": [ 2, 0, 14, 12 ], "texture": "#bulb" } + } + } + ] +} diff --git a/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage0.json b/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage0.json new file mode 100644 index 00000000..5834ec3d --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage0.json @@ -0,0 +1,19 @@ +{ + "textures": { + "tail": "unicopia:blocks/cuccoon_tail", + "particle": "unicopia:blocks/cuccoon_tail" + }, + "elements": [ + { "from": [ 7, 0, 7 ], + "to": [ 9, 16, 9 ], + "faces": { + "up": { "uv": [ 7, 7, 9, 9 ], "texture": "#tail", "cullface": "up" }, + "down": { "uv": [ 7, 7, 9, 9 ], "texture": "#tail", "cullface": "down" }, + "north": { "uv": [ 7, 0, 9, 16 ], "texture": "#tail", "cullface": "north" }, + "south": { "uv": [ 7, 0, 9, 16 ], "texture": "#tail", "cullface": "south" }, + "west": { "uv": [ 7, 0, 9, 16 ], "texture": "#tail", "cullface": "west" }, + "east": { "uv": [ 7, 0, 9, 16 ], "texture": "#tail", "cullface": "east" } + } + } + ] +} diff --git a/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage1.json b/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage1.json new file mode 100644 index 00000000..a2b5cf8e --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage1.json @@ -0,0 +1,19 @@ +{ + "textures": { + "tail": "unicopia:blocks/cuccoon_tail", + "particle": "unicopia:blocks/cuccoon_tail" + }, + "elements": [ + { "from": [ 6, 0, 6 ], + "to": [ 10, 16, 10 ], + "faces": { + "up": { "uv": [ 6, 6, 10, 10 ], "texture": "#tail", "cullface": "up" }, + "down": { "uv": [ 6, 6, 10, 10 ], "texture": "#tail", "cullface": "down" }, + "north": { "uv": [ 6, 0, 10, 16 ], "texture": "#tail", "cullface": "north" }, + "south": { "uv": [ 6, 0, 10, 16 ], "texture": "#tail", "cullface": "south" }, + "west": { "uv": [ 6, 0, 10, 16 ], "texture": "#tail", "cullface": "west" }, + "east": { "uv": [ 6, 0, 10, 16 ], "texture": "#tail", "cullface": "east" } + } + } + ] +} diff --git a/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage2.json b/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage2.json new file mode 100644 index 00000000..3f7ce072 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage2.json @@ -0,0 +1,19 @@ +{ + "textures": { + "tail": "unicopia:blocks/cuccoon_tail", + "particle": "unicopia:blocks/cuccoon_tail" + }, + "elements": [ + { "from": [ 5, 0, 5 ], + "to": [ 11, 16, 11 ], + "faces": { + "up": { "uv": [ 5, 5, 11, 11 ], "texture": "#tail", "cullface": "up" }, + "down": { "uv": [ 5, 5, 11, 11 ], "texture": "#tail", "cullface": "down" }, + "north": { "uv": [ 5, 0, 11, 16 ], "texture": "#tail", "cullface": "north" }, + "south": { "uv": [ 5, 0, 11, 16 ], "texture": "#tail", "cullface": "south" }, + "west": { "uv": [ 5, 0, 11, 16 ], "texture": "#tail", "cullface": "west" }, + "east": { "uv": [ 5, 0, 11, 16 ], "texture": "#tail", "cullface": "east" } + } + } + ] +} diff --git a/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage3.json b/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage3.json new file mode 100644 index 00000000..531f88d9 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/cuccoon/string_stage3.json @@ -0,0 +1,19 @@ +{ + "textures": { + "tail": "unicopia:blocks/cuccoon_tail", + "particle": "unicopia:blocks/cuccoon_tail" + }, + "elements": [ + { "from": [ 4, 0, 4 ], + "to": [ 12, 16, 12 ], + "faces": { + "up": { "uv": [ 4, 4, 12, 12 ], "texture": "#tail", "cullface": "up" }, + "down": { "uv": [ 4, 4, 12, 12 ], "texture": "#tail", "cullface": "down" }, + "north": { "uv": [ 4, 0, 12, 16 ], "texture": "#tail", "cullface": "north" }, + "south": { "uv": [ 4, 0, 12, 16 ], "texture": "#tail", "cullface": "south" }, + "west": { "uv": [ 4, 0, 12, 16 ], "texture": "#tail", "cullface": "west" }, + "east": { "uv": [ 4, 0, 12, 16 ], "texture": "#tail", "cullface": "east" } + } + } + ] +} diff --git a/src/main/resources/assets/unicopia/models/item/cuccoon.json b/src/main/resources/assets/unicopia/models/item/cuccoon.json new file mode 100644 index 00000000..490a104a --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/cuccoon.json @@ -0,0 +1,6 @@ +{ + "parent": "item/generated", + "textures": { + "layer0": "minecraft:items/apple" + } +} diff --git a/src/main/resources/assets/unicopia/textures/blocks/cuccoon_bulb.png b/src/main/resources/assets/unicopia/textures/blocks/cuccoon_bulb.png new file mode 100644 index 0000000000000000000000000000000000000000..4e894f1f302fe3be3fc73fedf23b86d5b1793e73 GIT binary patch literal 3436 zcmV-y4U_VTP)uJ@VVD_UC<6{NG_fI~0ue<-1QkJoA_k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