From 7e0e5cf8c1e2b8d8c32aa0a8fcacbef3536729e8 Mon Sep 17 00:00:00 2001 From: Sollace Date: Sat, 9 Mar 2019 19:41:37 +0200 Subject: [PATCH] Added chiseled chitin --- .../unicopia/block/BlockDirected.java | 53 ++++++++++++++++++ .../minelittlepony/unicopia/init/UBlocks.java | 9 ++- .../minelittlepony/unicopia/init/UItems.java | 6 +- .../unicopia/blockstates/chissled_chitin.json | 10 ++++ .../resources/assets/unicopia/lang/en_US.lang | 1 + .../models/block/chissled_chitin.json | 22 ++++++++ .../unicopia/models/item/chissled_chitin.json | 3 + .../unicopia/recipes/chissled_chitin.json | 14 +++++ .../blocks/chitin_block_chissled_full.png | Bin 0 -> 3365 bytes .../blocks/chitin_block_chissled_half.png | Bin 0 -> 3368 bytes 10 files changed, 115 insertions(+), 3 deletions(-) create mode 100644 src/main/java/com/minelittlepony/unicopia/block/BlockDirected.java create mode 100644 src/main/resources/assets/unicopia/blockstates/chissled_chitin.json create mode 100644 src/main/resources/assets/unicopia/models/block/chissled_chitin.json create mode 100644 src/main/resources/assets/unicopia/models/item/chissled_chitin.json create mode 100644 src/main/resources/assets/unicopia/recipes/chissled_chitin.json create mode 100644 src/main/resources/assets/unicopia/textures/blocks/chitin_block_chissled_full.png create mode 100644 src/main/resources/assets/unicopia/textures/blocks/chitin_block_chissled_half.png diff --git a/src/main/java/com/minelittlepony/unicopia/block/BlockDirected.java b/src/main/java/com/minelittlepony/unicopia/block/BlockDirected.java new file mode 100644 index 00000000..1215c1c9 --- /dev/null +++ b/src/main/java/com/minelittlepony/unicopia/block/BlockDirected.java @@ -0,0 +1,53 @@ +package com.minelittlepony.unicopia.block; + +import net.minecraft.block.BlockDirectional; +import net.minecraft.block.material.Material; +import net.minecraft.block.state.BlockStateContainer; +import net.minecraft.block.state.IBlockState; +import net.minecraft.entity.EntityLivingBase; +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.World; + +public class BlockDirected extends BlockDirectional { + + public BlockDirected(Material material, String domain, String name) { + super(material); + setTranslationKey(name); + setRegistryName(domain, name); + + setDefaultState(blockState.getBaseState().withProperty(FACING, EnumFacing.UP)); + } + + @Override + public IBlockState withRotation(IBlockState state, Rotation rot) { + return state.withProperty(FACING, rot.rotate(state.getValue(FACING))); + } + + @Override + public IBlockState withMirror(IBlockState state, Mirror mirror) { + return state.withProperty(FACING, mirror.mirror(state.getValue(FACING))); + } + + @Override + public IBlockState getStateForPlacement(World worldIn, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer) { + return getDefaultState().withProperty(FACING, facing); + } + + @Override + public IBlockState getStateFromMeta(int meta) { + return getDefaultState().withProperty(FACING, EnumFacing.byIndex(meta)); + } + + @Override + public int getMetaFromState(IBlockState state) { + return state.getValue(FACING).getIndex(); + } + + @Override + protected BlockStateContainer createBlockState() { + return new BlockStateContainer(this, FACING); + } +} diff --git a/src/main/java/com/minelittlepony/unicopia/init/UBlocks.java b/src/main/java/com/minelittlepony/unicopia/init/UBlocks.java index 0b5b1c15..815c7561 100644 --- a/src/main/java/com/minelittlepony/unicopia/init/UBlocks.java +++ b/src/main/java/com/minelittlepony/unicopia/init/UBlocks.java @@ -13,6 +13,7 @@ import com.minelittlepony.unicopia.block.BlockCloudAnvil; import com.minelittlepony.unicopia.block.BlockCloudBanister; import com.minelittlepony.unicopia.block.BlockCloudSlab; import com.minelittlepony.unicopia.block.BlockCloudStairs; +import com.minelittlepony.unicopia.block.BlockDirected; import com.minelittlepony.unicopia.block.BlockDutchDoor; import com.minelittlepony.unicopia.block.BlockSugar; import com.minelittlepony.unicopia.block.BlockTomatoPlant; @@ -31,6 +32,7 @@ import net.minecraft.block.material.Material; import net.minecraft.block.state.IBlockState; import net.minecraft.client.renderer.color.BlockColors; import net.minecraft.client.renderer.color.ItemColors; +import net.minecraft.creativetab.CreativeTabs; import net.minecraft.init.Blocks; import net.minecraft.item.ItemBlock; import net.minecraft.item.ItemStack; @@ -75,6 +77,11 @@ public class UBlocks { public static final BlockHiveWall hive = new BlockHiveWall(Unicopia.MODID, "hive"); public static final BlockChitin chitin = new BlockChitin(Unicopia.MODID, "chitin_block"); + public static final Block chissled_chitin = new BlockDirected(UMaterials.hive, Unicopia.MODID, "chissled_chitin") + .setCreativeTab(CreativeTabs.BUILDING_BLOCKS) + .setHardness(50) + .setResistance(2000); + public static final BlockGrowingCuccoon cuccoon = new BlockGrowingCuccoon(Unicopia.MODID, "cuccoon"); public static final BlockSlimeLayer slime_layer = new BlockSlimeLayer(Unicopia.MODID, "slime_layer"); @@ -97,7 +104,7 @@ public class UBlocks { packed_cloud_slab, packed_cloud_slab.doubleSlab, cloud_fence, cloud_banister, mist_door, library_door, bakery_door, - hive, chitin, cuccoon, slime_layer, + hive, chitin, chissled_chitin, cuccoon, slime_layer, 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 1eb34600..15e737f9 100644 --- a/src/main/java/com/minelittlepony/unicopia/init/UItems.java +++ b/src/main/java/com/minelittlepony/unicopia/init/UItems.java @@ -109,6 +109,8 @@ public class UItems { .setRegistryName(Unicopia.MODID, "chitin_shell"); public static final Item chitin = new ItemBlock(UBlocks.chitin) .setRegistryName(Unicopia.MODID, "chitin_block"); + public static final Item chissled_chitin = new ItemBlock(UBlocks.chissled_chitin) + .setRegistryName(Unicopia.MODID, "chissled_chitin"); public static final Item cuccoon = new ItemBlock(UBlocks.cuccoon) .setRegistryName(Unicopia.MODID, "cuccoon"); public static final Item slime_layer = new UnFuckedItemSnow(UBlocks.slime_layer) @@ -249,7 +251,7 @@ public class UItems { cloudsdale_tomato, tomato_seeds, tomato, moss, - hive, chitin_shell, chitin, cuccoon, slime_layer, + hive, chitin_shell, chitin, chissled_chitin, cuccoon, slime_layer, apple_seeds, apple_leaves, @@ -282,7 +284,7 @@ public class UItems { cereal, sugar_cereal, sugar_block, tomato_seeds, - hive, chitin_shell, chitin, cuccoon, slime_layer, + hive, chitin_shell, chitin, chissled_chitin, cuccoon, slime_layer, apple_seeds, apple_leaves, diff --git a/src/main/resources/assets/unicopia/blockstates/chissled_chitin.json b/src/main/resources/assets/unicopia/blockstates/chissled_chitin.json new file mode 100644 index 00000000..81a3c03a --- /dev/null +++ b/src/main/resources/assets/unicopia/blockstates/chissled_chitin.json @@ -0,0 +1,10 @@ +{ + "variants": { + "facing=up": { "model": "unicopia:chissled_chitin" }, + "facing=down": { "model": "unicopia:chissled_chitin", "x": 180 }, + "facing=north": { "model": "unicopia:chissled_chitin", "x": 90 }, + "facing=south": { "model": "unicopia:chissled_chitin", "x": -90 }, + "facing=east": { "model": "unicopia:chissled_chitin", "x": 90, "y": 90 }, + "facing=west": { "model": "unicopia:chissled_chitin", "x": 90, "y": -90 } + } +} diff --git a/src/main/resources/assets/unicopia/lang/en_US.lang b/src/main/resources/assets/unicopia/lang/en_US.lang index 51b7594f..cb61a11c 100644 --- a/src/main/resources/assets/unicopia/lang/en_US.lang +++ b/src/main/resources/assets/unicopia/lang/en_US.lang @@ -16,6 +16,7 @@ tile.cloud_farmland.name=Tilled Clouds tile.hive.name=Hive Wall tile.chitin_block.name=Chitin Block +tile.chissled_chitin.name=Chiseled Chitin Block tile.chitin_shell.name=Chitin Shell tile.cuccoon.name=Cocoon tile.slime_layer.name=Slime diff --git a/src/main/resources/assets/unicopia/models/block/chissled_chitin.json b/src/main/resources/assets/unicopia/models/block/chissled_chitin.json new file mode 100644 index 00000000..8b2206ab --- /dev/null +++ b/src/main/resources/assets/unicopia/models/block/chissled_chitin.json @@ -0,0 +1,22 @@ +{ + "parent": "block/cube_all", + "textures": { + "bottom": "unicopia:blocks/chitin_block_covered", + "particle": "unicopia:blocks/chitin_block_uncovered", + "top": "unicopia:blocks/chitin_block_chissled_full", + "side": "unicopia:blocks/chitin_block_chissled_half" + }, + "elements": [ + { "from": [ 0, 0, 0 ], + "to": [ 16, 16, 16 ], + "faces": { + "down": { "texture": "#bottom", "cullface": "down" }, + "up": { "texture": "#top", "cullface": "up" }, + "north": { "texture": "#side", "cullface": "north" }, + "south": { "texture": "#side", "cullface": "south" }, + "west": { "texture": "#side", "cullface": "west" }, + "east": { "texture": "#side", "cullface": "east" } + } + } + ] +} \ No newline at end of file diff --git a/src/main/resources/assets/unicopia/models/item/chissled_chitin.json b/src/main/resources/assets/unicopia/models/item/chissled_chitin.json new file mode 100644 index 00000000..344120f8 --- /dev/null +++ b/src/main/resources/assets/unicopia/models/item/chissled_chitin.json @@ -0,0 +1,3 @@ +{ + "parent": "unicopia:block/chissled_chitin" +} diff --git a/src/main/resources/assets/unicopia/recipes/chissled_chitin.json b/src/main/resources/assets/unicopia/recipes/chissled_chitin.json new file mode 100644 index 00000000..6edc05fe --- /dev/null +++ b/src/main/resources/assets/unicopia/recipes/chissled_chitin.json @@ -0,0 +1,14 @@ +{ + "type": "minecraft:crafting_shaped", + + "pattern": [ + "##", + "##" + ], + "key": { + "#": [ + { "item": "unicopia:chitin_block" } + ] + }, + "result": { "item": "unicopia:chissled_chitin", "count": 4 } +} diff --git a/src/main/resources/assets/unicopia/textures/blocks/chitin_block_chissled_full.png b/src/main/resources/assets/unicopia/textures/blocks/chitin_block_chissled_full.png new file mode 100644 index 0000000000000000000000000000000000000000..737bdd4632566ea70677ce6f9dfe61d5497f20c0 GIT binary patch literal 3365 zcmV+=4chXFP)uJ@VVD_UC<6{NG_fI~0ue<-1QkJoA_k0xBC#Thg@9ne9*`iQ#9$Or zQF$}6R&?d%y_c8YA7_1QpS|}zXYYO1x&V;8{kgn!SPFnNo`4_X6{c}T{8k*B#$jdxfFg<9uYy1K45IaYvHg`_dOZM)Sy63ve6hvv z1)yUy0P^?0*fb9UASvow`@mQCp^4`uNg&9uGcn1|&Nk+9SjOUl{-OWr@Hh0;_l(8q z{wNRKos+;6rV8ldy0Owz(}jF`W(JeRp&R{qi2rfmU!T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src/main/resources/assets/unicopia/textures/blocks/chitin_block_chissled_half.png b/src/main/resources/assets/unicopia/textures/blocks/chitin_block_chissled_half.png new file mode 100644 index 0000000000000000000000000000000000000000..d76f25f8334709656e74e1b8ebc3f2ec9c5d8ad0 GIT binary patch literal 3368 zcmV+@4cGFCP)uJ@VVD_UC<6{NG_fI~0ue<-1QkJoA_k0xBC#Thg@9ne9*`iQ#9$Or zQF$}6R&?d%y_c8YA7_1QpS|}zXYYO1x&V;8{kgn!SPFnNo`4_X6{c}T{8k*B#$jdxfFg<9uYy1K45IaYvHg`_dOZM)Sy63ve6hvv z1)yUy0P^?0*fb9UASvow`@mQCp^4`uNg&9uGcn1|&Nk+9SjOUl{-OWr@Hh0;_l(8q z{wNRKos+;6rV8ldy0Owz(}jF`W(JeRp&R{qi2rfmU!TJ;gp(Kmm5I1s5m_f-n#TRsj}B0%?E`vOzxB2#P=n*a3EfYETOrKoe*ICqM@{4K9Go;5xVgZi5G4 z1dM~{UdP6d+Yd3o?MrAqM0Kc|iV92owdyL5UC#5<>aVCa44|hpM4E zs0sQWIt5*Tu0n&*J!lk~f_{hI!w5`*sjxDv4V%CW*ah~3!{C*0BD@;TgA3v9a1~q+ zAA{TB3-ERLHar49hi4Ih5D^-ph8Q6X#0?2VqLBoIkE}zAkxHZUgRb+f=nat zP#6>iMMoK->`~sRLq)(kHo*Vn{;LcG6+edD1=7D>9j^O?D{Qg|tCDK{ym)H7&wDr6*;uGTJg8GHjVbnL{!cWyUB7MT6o-VNo_w8Yq`2<5Ub)hw4L3rj}5@qxMs0 zWMyP6Wy582WNT#4$d1qunl{acmP#w5ouJ*Jy_Zv#bCKi7ZIf$}8d zZdVy&)LYdbX%I9R8VMQ|8r>Q*nyQ)sn)#Z|n)kKvS`4iu ztvy=3T65Yu+7a4Yv^%sXb>ww?bn(=Yu(!=O6^iuTp>)p_Y^{w=i z^lS773}6Fm1Fpe-gF!>Ip{*g$u-szvGhed;vo5pW&GpS$<~8QGEXWp~7V9lKEn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