Эх сурвалжийг харах

several block drops / recipes, fixed bear / human renderer, simplified
human sync with client

Kajetan Johannes Hammerle 6 жил өмнө
parent
commit
377f034ed5
84 өөрчлөгдсөн 2090 нэмэгдсэн , 595 устгасан
  1. 0 2
      src/main/java/me/km/Client.java
  2. 111 0
      src/main/java/me/km/blocks/BlockGravelSlab.java
  3. 28 0
      src/main/java/me/km/blocks/BlockOre.java
  4. 13 13
      src/main/java/me/km/blocks/ModBlocks.java
  5. 0 65
      src/main/java/me/km/chatchannel/TextColor.java
  6. 48 92
      src/main/java/me/km/entities/EntityHuman.java
  7. 20 46
      src/main/java/me/km/entities/HumanSkinLoader.java
  8. 6 1
      src/main/java/me/km/entities/ModEntities.java
  9. 0 2
      src/main/java/me/km/entities/RenderBrownBear.java
  10. 0 1
      src/main/java/me/km/entities/RenderHuman.java
  11. 0 61
      src/main/java/me/km/networking/HumanScaleUpdate.java
  12. 0 61
      src/main/java/me/km/networking/HumanUpdate.java
  13. 0 17
      src/main/java/me/km/networking/ModPacketHandler.java
  14. 3 233
      src/main/java/me/km/recipes/ModRecipes.java
  15. 0 1
      src/main/java/me/km/snuviscript/MinecraftFunctions.java
  16. 185 0
      src/main/resources/data/km/loot_tables/blocks/apricot_leaves.json
  17. 20 0
      src/main/resources/data/km/loot_tables/blocks/apricot_sapling.json
  18. 20 0
      src/main/resources/data/km/loot_tables/blocks/artefact.json
  19. 20 0
      src/main/resources/data/km/loot_tables/blocks/bronze_block.json
  20. 130 0
      src/main/resources/data/km/loot_tables/blocks/cherry_leaves.json
  21. 20 0
      src/main/resources/data/km/loot_tables/blocks/cherry_sapling.json
  22. 20 0
      src/main/resources/data/km/loot_tables/blocks/cooking_pot_copper.json
  23. 20 0
      src/main/resources/data/km/loot_tables/blocks/copper_block.json
  24. 20 0
      src/main/resources/data/km/loot_tables/blocks/copper_ore.json
  25. 20 0
      src/main/resources/data/km/loot_tables/blocks/crate_acacia.json
  26. 20 0
      src/main/resources/data/km/loot_tables/blocks/crate_big_oak.json
  27. 20 0
      src/main/resources/data/km/loot_tables/blocks/crate_birch.json
  28. 20 0
      src/main/resources/data/km/loot_tables/blocks/crate_jungle.json
  29. 20 0
      src/main/resources/data/km/loot_tables/blocks/crate_oak.json
  30. 20 0
      src/main/resources/data/km/loot_tables/blocks/crate_spruce.json
  31. 119 0
      src/main/resources/data/km/loot_tables/blocks/gravel_slab.json
  32. 20 0
      src/main/resources/data/km/loot_tables/blocks/guild_block.json
  33. 185 0
      src/main/resources/data/km/loot_tables/blocks/pear_leaves.json
  34. 20 0
      src/main/resources/data/km/loot_tables/blocks/pear_sapling.json
  35. 185 0
      src/main/resources/data/km/loot_tables/blocks/plum_leaves.json
  36. 20 0
      src/main/resources/data/km/loot_tables/blocks/plum_sapling.json
  37. 51 0
      src/main/resources/data/km/loot_tables/blocks/rtall_grass.json
  38. 20 0
      src/main/resources/data/km/loot_tables/blocks/silver_block.json
  39. 20 0
      src/main/resources/data/km/loot_tables/blocks/silver_ore.json
  40. 20 0
      src/main/resources/data/km/loot_tables/blocks/spikes_bronze.json
  41. 20 0
      src/main/resources/data/km/loot_tables/blocks/spikes_copper.json
  42. 20 0
      src/main/resources/data/km/loot_tables/blocks/spikes_gold.json
  43. 20 0
      src/main/resources/data/km/loot_tables/blocks/spikes_iron.json
  44. 20 0
      src/main/resources/data/km/loot_tables/blocks/tin_block.json
  45. 20 0
      src/main/resources/data/km/loot_tables/blocks/tin_ore.json
  46. 16 0
      src/main/resources/data/km/recipes/bronze_block.json
  47. 36 0
      src/main/resources/data/km/recipes/bronze_ingot.json
  48. 13 0
      src/main/resources/data/km/recipes/bronze_ingot_from_bronze_block.json
  49. 17 0
      src/main/resources/data/km/recipes/bronze_ingot_from_nuggets.json
  50. 16 0
      src/main/resources/data/km/recipes/cooking_pot_copper.json
  51. 16 0
      src/main/resources/data/km/recipes/copper_block.json
  52. 9 0
      src/main/resources/data/km/recipes/copper_from_blasting.json
  53. 9 0
      src/main/resources/data/km/recipes/copper_ingot.json
  54. 13 0
      src/main/resources/data/km/recipes/copper_ingot_from_copper_block.json
  55. 17 0
      src/main/resources/data/km/recipes/copper_ingot_from_nuggets.json
  56. 16 0
      src/main/resources/data/km/recipes/crate_acacia.json
  57. 16 0
      src/main/resources/data/km/recipes/crate_big_oak.json
  58. 16 0
      src/main/resources/data/km/recipes/crate_birch.json
  59. 16 0
      src/main/resources/data/km/recipes/crate_jungle.json
  60. 16 0
      src/main/resources/data/km/recipes/crate_oak.json
  61. 16 0
      src/main/resources/data/km/recipes/crate_spruce.json
  62. 16 0
      src/main/resources/data/km/recipes/gravel_slab.json
  63. 16 0
      src/main/resources/data/km/recipes/silver_block.json
  64. 9 0
      src/main/resources/data/km/recipes/silver_ingot.json
  65. 9 0
      src/main/resources/data/km/recipes/silver_ingot_from_blasting.json
  66. 17 0
      src/main/resources/data/km/recipes/silver_ingot_from_nuggets.json
  67. 13 0
      src/main/resources/data/km/recipes/silver_ingot_from_silver_block.json
  68. 16 0
      src/main/resources/data/km/recipes/spikes_bronze.json
  69. 16 0
      src/main/resources/data/km/recipes/spikes_copper.json
  70. 16 0
      src/main/resources/data/km/recipes/spikes_gold.json
  71. 16 0
      src/main/resources/data/km/recipes/spikes_iron.json
  72. 16 0
      src/main/resources/data/km/recipes/tin_block.json
  73. 9 0
      src/main/resources/data/km/recipes/tin_ingot.json
  74. 9 0
      src/main/resources/data/km/recipes/tin_ingot_from_blasting.json
  75. 17 0
      src/main/resources/data/km/recipes/tin_ingot_from_nuggets.json
  76. 13 0
      src/main/resources/data/km/recipes/tin_ingot_from_tin_block.json
  77. 6 0
      src/main/resources/data/minecraft/tags/blocks/beds.json
  78. 9 0
      src/main/resources/data/minecraft/tags/blocks/leaves.json
  79. 9 0
      src/main/resources/data/minecraft/tags/blocks/saplings.json
  80. 6 0
      src/main/resources/data/minecraft/tags/blocks/slabs.json
  81. 6 0
      src/main/resources/data/minecraft/tags/items/beds.json
  82. 9 0
      src/main/resources/data/minecraft/tags/items/leaves.json
  83. 9 0
      src/main/resources/data/minecraft/tags/items/saplings.json
  84. 6 0
      src/main/resources/data/minecraft/tags/items/slabs.json

+ 0 - 2
src/main/java/me/km/Client.java

@@ -4,7 +4,6 @@ import java.awt.Color;
 import java.util.List;
 import me.km.blocks.ModBlocks;
 import me.km.blocks.cookingpot.TileEntityCookingPot;
-import me.km.entities.ModEntities;
 import me.km.items.ItemColoredSoup;
 import me.km.items.ItemGemStone;
 import me.km.items.ModItems;
@@ -46,7 +45,6 @@ public class Client
     
     public static void init() 
     {
-        ModEntities.initClient();
         MinecraftForge.EVENT_BUS.register(new Client());
         MinecraftForge.EVENT_BUS.register(new KeyManager());
         registerColors();

+ 111 - 0
src/main/java/me/km/blocks/BlockGravelSlab.java

@@ -0,0 +1,111 @@
+package me.km.blocks;
+
+import java.util.Random;
+import net.minecraft.block.Block;
+import net.minecraft.block.BlockState;
+import net.minecraft.block.FallingBlock;
+import net.minecraft.block.SlabBlock;
+import net.minecraft.block.material.Material;
+import net.minecraft.entity.item.FallingBlockEntity;
+import net.minecraft.particles.BlockParticleData;
+import net.minecraft.particles.ParticleTypes;
+import net.minecraft.state.properties.SlabType;
+import net.minecraft.util.Direction;
+import net.minecraft.util.math.BlockPos;
+import net.minecraft.world.IWorld;
+import net.minecraft.world.IWorldReader;
+import net.minecraft.world.World;
+import net.minecraftforge.api.distmarker.Dist;
+import net.minecraftforge.api.distmarker.OnlyIn;
+import net.minecraftforge.common.ToolType;
+
+public class BlockGravelSlab extends SlabBlock
+{
+    public BlockGravelSlab(Properties properties)
+    {
+        super(properties);
+    }
+
+    @Override
+    public ToolType getHarvestTool(BlockState state)
+    {
+        return ToolType.SHOVEL;
+    }
+
+    @Override
+    public void onBlockAdded(BlockState p_220082_1_, World w, BlockPos pos, BlockState p_220082_4_, boolean p_220082_5_)
+    {
+        w.getPendingBlockTicks().scheduleTick(pos, this, this.tickRate(w));
+    }
+
+    @Override
+    public BlockState updatePostPlacement(BlockState state, Direction facing, BlockState facingState, IWorld w, BlockPos currentPos, BlockPos facingPos)
+    {
+        w.getPendingBlockTicks().scheduleTick(currentPos, this, this.tickRate(w));
+        return super.updatePostPlacement(state, facing, facingState, w, currentPos, facingPos);
+    }
+
+    @Override
+    public void tick(BlockState state, World w, BlockPos pos, Random random)
+    {
+        if(!w.isRemote)
+        {
+            this.checkFallable(w, pos);
+        }
+    }
+
+    private void checkFallable(World w, BlockPos pos)
+    {
+        BlockState state = w.getBlockState(pos);
+        if((w.isAirBlock(pos.down()) || FallingBlock.canFallThrough(w.getBlockState(pos.down()))) && pos.getY() >= 0)
+        {
+            if(!w.isRemote)
+            {
+                FallingBlockEntity fbe = new FallingBlockEntity(w, pos.getX() + 0.5, pos.getY(), pos.getZ() + 0.5, state);
+                w.addEntity(fbe);
+            }
+
+        }
+        else if(state == getDefaultState().with(TYPE, SlabType.TOP) && pos.getY() >= 0)
+        {
+            if(!w.isRemote)
+            {
+                FallingBlockEntity fbe = new FallingBlockEntity(w, 
+                        pos.getX() + 0.5, pos.getY(), pos.getZ() + 0.5, 
+                        w.getBlockState(pos).with(TYPE, SlabType.BOTTOM));
+                w.addEntity(fbe);
+            }
+
+        }
+    }
+    
+    @Override
+    public int tickRate(IWorldReader w)
+    {
+        return 2;
+    }
+
+    @OnlyIn(Dist.CLIENT)
+    @Override
+    public void animateTick(BlockState state, World w, BlockPos pos, Random rand)
+    {
+        if(rand.nextInt(16) == 0)
+        {
+            BlockPos blockpos = pos.down();
+            if(w.isAirBlock(blockpos) || FallingBlock.canFallThrough(w.getBlockState(blockpos)))
+            {
+                double x = pos.getX() + rand.nextFloat();
+                double y = pos.getY() - 0.05;
+                double z = pos.getZ() + rand.nextFloat();
+                w.addParticle(new BlockParticleData(ParticleTypes.FALLING_DUST, state), x, y, z, 0.0, 0.0, 0.0);
+            }
+        }
+
+    }
+
+    @OnlyIn(Dist.CLIENT)
+    public int getDustColor(BlockState state)
+    {
+        return -8356741;
+    }
+}

+ 28 - 0
src/main/java/me/km/blocks/BlockOre.java

@@ -0,0 +1,28 @@
+package me.km.blocks;
+
+import net.minecraft.block.Block;
+import net.minecraft.block.BlockState;
+import net.minecraftforge.common.ToolType;
+
+public class BlockOre extends Block
+{
+    private final int harvestLevel;
+    
+    public BlockOre(Properties properties, int harvestLevel)
+    {
+        super(properties);
+        this.harvestLevel = harvestLevel;
+    }
+
+    @Override
+    public int getHarvestLevel(BlockState state)
+    {
+        return harvestLevel;
+    }
+
+    @Override
+    public ToolType getHarvestTool(BlockState state)
+    {
+        return ToolType.PICKAXE;
+    }
+}

+ 13 - 13
src/main/java/me/km/blocks/ModBlocks.java

@@ -87,23 +87,23 @@ public class ModBlocks
         return b;
     }
     
-    private static Block createOre(String registry)
+    private static Block createOre(String registry, int harvestLevel)
     {
-        Block b = new Block(Properties.create(Material.ROCK).hardnessAndResistance(3.0f, 3.0f));
+        Block b = new BlockOre(Properties.create(Material.ROCK).hardnessAndResistance(3.0f, 3.0f), harvestLevel);
         b.setRegistryName(registry);
         return b;
     }
     
-    private static Block createOreBlock(String registry, MaterialColor mc, float hardness, float resistance)
+    private static Block createOreBlock(String registry, MaterialColor mc, float hardness, float resistance, int harvestLevel)
     {
-        Block b = new Block(Properties.create(Material.IRON, mc).hardnessAndResistance(hardness, resistance));
+        Block b = new BlockOre(Properties.create(Material.IRON, mc).hardnessAndResistance(hardness, resistance), harvestLevel);
         b.setRegistryName(registry);
         return b;
     }
     
     private static Block createLeaves(String registry)
     {
-        Block b = new LeavesBlock(Block.Properties.create(Material.LEAVES).hardnessAndResistance(0.2F).tickRandomly().sound(SoundType.PLANT));
+        Block b = new LeavesBlock(Block.Properties.create(Material.LEAVES).hardnessAndResistance(0.2f).tickRandomly().sound(SoundType.PLANT));
         b.setRegistryName(registry);
         return b;
     }
@@ -118,14 +118,14 @@ public class ModBlocks
     public static void initBlocks(IForgeRegistry<Block> r) 
     {
         // ores + blocks
-        copperOre = register(r, createOre("copper_ore"));    
-        tinOre = register(r, createOre("tin_ore"));   
-        silverOre = register(r, createOre("silver_ore")); 
+        copperOre = register(r, createOre("copper_ore", 1));    
+        tinOre = register(r, createOre("tin_ore", 1));   
+        silverOre = register(r, createOre("silver_ore", 2)); 
         
-        copperBlock = register(r, createOreBlock("copper_block", MaterialColor.BROWN, 3.0f, 6.0f));   
-        tinBlock = register(r, createOreBlock("tin_block", MaterialColor.IRON, 3.0f, 6.0f));
-        silverBlock = register(r, createOreBlock("silver_block", MaterialColor.IRON, 5.0f, 6.0f));
-        bronzeBlock = register(r, createOreBlock("bronze_block", MaterialColor.YELLOW, 5.0f, 6.0f));
+        copperBlock = register(r, createOreBlock("copper_block", MaterialColor.BROWN, 3.0f, 6.0f, 1));   
+        tinBlock = register(r, createOreBlock("tin_block", MaterialColor.IRON, 3.0f, 6.0f, 1));
+        silverBlock = register(r, createOreBlock("silver_block", MaterialColor.IRON, 5.0f, 6.0f, 2));
+        bronzeBlock = register(r, createOreBlock("bronze_block", MaterialColor.YELLOW, 5.0f, 6.0f, 2));
         
         // misc
         guildblock = register(r, create("guild_block", Material.IRON, 50.0f, 2000.0f));
@@ -157,7 +157,7 @@ public class ModBlocks
         honey = register(r, create("honey", Material.WATER, 0.0f, 0.0f));
         
         // slabs
-        gravelSlab = register(r, new SlabBlock(Properties.create(Material.SAND, MaterialColor.STONE)
+        gravelSlab = register(r, new BlockGravelSlab(Properties.create(Material.SAND, MaterialColor.STONE)
                 .sound(SoundType.GROUND).hardnessAndResistance(0.6f)).setRegistryName("gravel_slab"));
         
         // leaves

+ 0 - 65
src/main/java/me/km/chatchannel/TextColor.java

@@ -1,65 +0,0 @@
-package me.km.chatchannel;
-
-import java.util.regex.Pattern;
-
-public enum TextColor
-{
-    // vanilla stuff
-    BLACK('0'),
-    DARK_BLUE('1'),
-    DARK_GREEN('2'),
-    DARK_AQUA('3'),
-    DARK_RED('4'),
-    DARK_PURPLE('5'),
-    GOLD('6'),
-    GRAY('7'),
-    DARK_GRAY('8'),
-    BLUE('9'),
-    GREEN('a'),
-    AQUA('b'),
-    RED('c'),
-    LIGHT_PURPLE('d'),
-    YELLOW('e'),
-    WHITE('f'),
-    OBFUSCATED('k'),
-    BOLD('l'),
-    STRIKETHROUGH('m'),
-    UNDERLINE('n'),
-    ITALIC('o'),
-    RESET('r'),
-    // http://chir.ag/projects/name-that-color/
-    // new colors
-    DARK_BROWN('g'),
-    LIGHT_BROWN('h'),
-    MIDNIGHT_BLUE('i'),
-    BAHAMA_BLUE('j'),
-    LIMEADE('p'),
-    PISTACHIO('q'),
-    AZURE_RADIANCE('s'),
-    MALIBU('t'),
-    OREGON('u'),
-    TENN('v'),
-    BUDDHA_GOLD('w'),
-    SUPERNOVA('x'),
-    POMPADOUR('y'),
-    ELECTRIC_VIOLET('z');
- 
-    private static final Pattern FORMATTING_CODE_PATTERN = Pattern.compile("(?i)\u00a7[0-9A-Za-z]");
-    private final String pattern;
-
-    private TextColor(char c)
-    {
-        this.pattern = "§" + c;
-    }
-
-    @Override
-    public String toString()
-    {
-        return pattern;
-    }
-
-    public static String getTextWithoutFormattingCodes(String text)
-    {
-        return FORMATTING_CODE_PATTERN.matcher(text).replaceAll("");
-    }
-}

+ 48 - 92
src/main/java/me/km/entities/EntityHuman.java

@@ -1,11 +1,7 @@
 package me.km.entities;
 
-import java.nio.charset.StandardCharsets;
-import me.km.KajetansMod;
 import me.km.Server;
-import me.km.networking.ModPacketHandler;
 import me.km.overrides.ModEntityPlayerMP;
-import me.km.snuviscript.ScriptEvents;
 import net.minecraft.entity.Entity;
 import net.minecraft.entity.CreatureEntity;
 import net.minecraft.entity.EntitySize;
@@ -17,7 +13,9 @@ import net.minecraft.entity.ai.goal.LookRandomlyGoal;
 import net.minecraft.entity.ai.goal.SwimGoal;
 import net.minecraft.entity.player.PlayerEntity;
 import net.minecraft.nbt.CompoundNBT;
-import net.minecraft.network.PacketBuffer;
+import net.minecraft.network.datasync.DataParameter;
+import net.minecraft.network.datasync.DataSerializers;
+import net.minecraft.network.datasync.EntityDataManager;
 import net.minecraft.util.DamageSource;
 import net.minecraft.util.ResourceLocation;
 import net.minecraft.util.SoundCategory;
@@ -26,75 +24,70 @@ import net.minecraft.util.text.ITextComponent;
 import net.minecraft.world.World;
 import net.minecraftforge.api.distmarker.Dist;
 import net.minecraftforge.api.distmarker.OnlyIn;
-import net.minecraftforge.fml.common.registry.IEntityAdditionalSpawnData;
 import net.minecraft.util.SoundEvents;
 
-public class EntityHuman extends CreatureEntity implements IEntityAdditionalSpawnData
+public class EntityHuman extends CreatureEntity
 {
-    private final static String STEVE = "Steve";
+    private static final DataParameter<String> SKIN_NAME = EntityDataManager.createKey(EntityHuman.class, DataSerializers.STRING);
+    private static final DataParameter<Float> SCALE = EntityDataManager.createKey(EntityHuman.class, DataSerializers.FLOAT);
+    private static final DataParameter<Boolean> SLIM = EntityDataManager.createKey(EntityHuman.class, DataSerializers.BOOLEAN);
     
-    @OnlyIn(Dist.CLIENT)
-    private ResourceLocation texture;
-    
-    private String name;
-    private float scale;
-    private byte slim;
     private final float originalWidth;
     private final float originalHeight;
     private EntitySize size;
+    private float lastScale = 1.0f;
     
     public EntityHuman(EntityType<EntityHuman> type, World w)
     {
         super(type, w);  
-        this.name = STEVE;
-        this.scale = 1;
         this.originalWidth = getWidth();
         this.originalHeight = getHeight();
-        this.slim = 0;
         size = ModEntities.HUMAN.getSize();
     }
+    
+    @Override
+    protected void registerData() 
+    {
+        super.registerData();
+        this.getDataManager().register(SKIN_NAME, "Steve");
+        this.getDataManager().register(SCALE, 1.0f);
+        this.getDataManager().register(SLIM, false);
+    }
 
     // -------------------------------------------------------------------------
     // size modifier
     // -------------------------------------------------------------------------
 
-    public byte getSlim()
+    public boolean isSlim()
     {
-        return slim;
+        return this.getDataManager().get(SLIM);
     }
     
-    public void setSlim(byte slim)
+    public void setSlim(boolean slim)
     {
-        this.slim = slim;
+        this.getDataManager().set(SLIM, slim);
     }
     
-    public void setSlim(boolean b)
+    public final float getScale()
     {
-        this.slim = (byte) (b ? 1 : 0);
-        if(!this.world.isRemote)
-        {
-            ModPacketHandler.sendHumanScaleUpdate(this);
-        }
+        return this.getDataManager().get(SCALE);
     }
     
-    public boolean isSlim()
+    public final void setScale(float scale)
     {
-        return this.slim == 1;
+        lastScale = scale;
+        this.getDataManager().set(SCALE, scale);
+        this.setSize(originalWidth * scale, originalHeight * scale);
     }
     
-    public final float getScale()
+    public void setSkinName(String name)
     {
-        return scale;
-    }
+        this.getDataManager().set(SKIN_NAME, name);
+    }   
     
-    public final void setScale(float scale)
+    public String getSkinName()
     {
-        this.scale = scale;
-        this.setSize(originalWidth * scale, originalHeight * scale);
-        if(!this.world.isRemote)
-        {
-            ModPacketHandler.sendHumanScaleUpdate(this);
-        }
+        return this.getDataManager().get(SKIN_NAME);
     }
     
     // -------------------------------------------------------------------------
@@ -104,13 +97,9 @@ public class EntityHuman extends CreatureEntity implements IEntityAdditionalSpaw
     @OnlyIn(Dist.CLIENT)
     public ResourceLocation getTexture()
     {
-        return texture;
-    }
-    
-    @OnlyIn(Dist.CLIENT)
-    public void setTexture(ResourceLocation texture)
-    {
-        this.texture = texture;
+        String name = getSkinName();
+        org.apache.logging.log4j.LogManager.getLogger().warn(name);
+        return HumanSkinLoader.INSTANCE.getTexture(name);
     }
     
     @Override
@@ -119,16 +108,15 @@ public class EntityHuman extends CreatureEntity implements IEntityAdditionalSpaw
         super.readAdditional(com);
         if(com.contains("HumanName"))
         {
-            this.name = com.getString("HumanName");
+            setSkinName(com.getString("HumanName"));
         }
         if(com.contains("Scale"))
         {
-            this.scale = com.getFloat("Scale");
-            setSize(originalWidth * scale, originalHeight * scale);
+            setScale(com.getFloat("Scale"));
         }
         if(com.contains("Slim"))
         {
-            this.slim = com.getByte("Slim");
+            setSlim(com.getBoolean("Slim"));
         }
     }
 
@@ -136,34 +124,11 @@ public class EntityHuman extends CreatureEntity implements IEntityAdditionalSpaw
     public void writeAdditional(CompoundNBT com)
     {
         super.writeAdditional(com);
-        com.putString("HumanName", name);
-        com.putFloat("Scale", scale);
-        com.putByte("Slim", slim);
-    }
-    
-    @Override
-    public void writeSpawnData(PacketBuffer buf) 
-    {
-        byte[] b = name.getBytes(StandardCharsets.UTF_8);
-        buf.writeInt(b.length);
-        buf.writeBytes(b);
-        buf.writeFloat(scale);
-        buf.writeByte(slim);
+        com.putString("HumanName", getSkinName());
+        com.putFloat("Scale", getScale());
+        com.putBoolean("Slim", isSlim());
     }
 
-    @Override
-    public void readSpawnData(PacketBuffer buf) 
-    {
-        int length = buf.readInt();
-        name = buf.readBytes(length).toString(StandardCharsets.UTF_8);
-        setTexture(HumanSkinLoader.INSTANCE.getTexture(name, loc -> setTexture(loc)));
-        scale = buf.readFloat();
-        setSize(originalWidth * scale, originalHeight * scale);
-        slim = buf.readByte();
-    }
-    
-    // -------------------------------------------------------------------------
-
     @Override
     public void addVelocity(double x, double y, double z)
     {
@@ -206,20 +171,6 @@ public class EntityHuman extends CreatureEntity implements IEntityAdditionalSpaw
         this.goalSelector.addGoal(2, new LookRandomlyGoal(this));
    }
     
-    public void setSkinName(String name)
-    {
-        this.name = name;
-        if(!this.world.isRemote)
-        {
-            ModPacketHandler.sendHumanUpdate(this);
-        }
-    }   
-    
-    public String getSkinName()
-    {
-        return name;
-    }
-
     @Override
     protected void registerAttributes()
     {
@@ -305,7 +256,7 @@ public class EntityHuman extends CreatureEntity implements IEntityAdditionalSpaw
         {
             f -= 0.08F;
         }
-        f *= scale;
+        f *= getScale();
         return f;
     }
 
@@ -323,10 +274,15 @@ public class EntityHuman extends CreatureEntity implements IEntityAdditionalSpaw
     @Override
     public EntitySize getSize(Pose poseIn)
     {
+        float scale = getScale();
+        if(scale != lastScale)
+        {
+            setScale(scale);
+        }
         return size;
     }
     
-    public void setSize(float w, float h)
+    private void setSize(float w, float h)
     {
         size = EntitySize.fixed(w, h);
     }

+ 20 - 46
src/main/java/me/km/entities/HumanSkinLoader.java

@@ -14,6 +14,7 @@ import net.minecraft.client.renderer.texture.TextureManager;
 import net.minecraft.util.ResourceLocation;
 import net.minecraftforge.api.distmarker.Dist;
 import net.minecraftforge.api.distmarker.OnlyIn;
+import org.apache.logging.log4j.LogManager;
 
 @OnlyIn(Dist.CLIENT)
 public class HumanSkinLoader
@@ -22,59 +23,33 @@ public class HumanSkinLoader
     
     private static final ResourceLocation TEXTURE_STEVE = new ResourceLocation("textures/entity/steve.png");
     
-    private final HashMap<String, ResourceLocation> skins;
-    private final HashSet<String> loading;
+    private final HashMap<String, ResourceLocation> skins = new HashMap<>();
+    private final HashSet<String> loading = new HashSet<>();
     
-    private final HashMap<String, ArrayList<Consumer<ResourceLocation>>> queue;
-    
-    private final TextureManager manager;
-    private final DownloadImageBuffer converter;
+    private final TextureManager manager = Minecraft.getInstance().getRenderManager().textureManager;
+    private final DownloadImageBuffer converter = new DownloadImageBuffer();
     
     public HumanSkinLoader()
     {
-        this.skins = new HashMap<>();
-        this.loading = new HashSet<>();
-        this.queue = new HashMap<>();
-        this.manager = Minecraft.getInstance().getRenderManager().textureManager;
-        this.converter = new DownloadImageBuffer();
     }
     
-    public ResourceLocation getTexture(String name, Consumer<ResourceLocation> delayed)
+    public ResourceLocation getTexture(String name)
     {
         ResourceLocation loc = skins.get(name);
-        if(loc == null)
+        if(loc != null)
         {
-            if(loading.add(name))
-            {
-                downloadSkin(name, image -> 
-                {
-                    ResourceLocation rloc = manager.getDynamicTextureLocation("skin_" + name, new DynamicTexture(image));
-                    skins.put(name, rloc);
-                    loading.remove(name);
-                    delayed.accept(rloc);
-                    
-                    ArrayList<Consumer<ResourceLocation>> list = queue.get(name);
-                    if(list != null)
-                    {
-                        list.forEach(c -> c.accept(rloc));
-                        list.clear();
-                        queue.remove(name);
-                    }
-                });
-            }
-            else
+            return loc;
+        }
+        if(loading.add(name))
+        {
+            downloadSkin(name, image -> 
             {
-                ArrayList<Consumer<ResourceLocation>> list = queue.get(name);
-                if(list == null)
-                {
-                    list = new ArrayList<>();
-                    queue.put(name, list);
-                }
-                list.add(delayed);
-            }
-            return TEXTURE_STEVE;
+                ResourceLocation rloc = manager.getDynamicTextureLocation("skin_" + name, new DynamicTexture(image));
+                skins.put(name, rloc);
+                loading.remove(name);
+            });
         }
-        return loc;
+        return TEXTURE_STEVE;
     }
     
     private void downloadSkin(String name, Consumer<NativeImage> delayed)
@@ -94,8 +69,7 @@ public class HumanSkinLoader
                 int code = httpurlconnection.getResponseCode();
                 if(code != 200)
                 {
-                    // Failed own server, trying mojangs
-                    //System.out.println("https://crafatar.com/skins/" + name + ".png");
+                    // Failed own server, trying crafatar
                     httpurlconnection.disconnect();
                     httpurlconnection = (HttpURLConnection) (new URL("https://crafatar.com/skins/" + name + ".png"))
                             .openConnection(Minecraft.getInstance().getProxy());
@@ -105,7 +79,7 @@ public class HumanSkinLoader
                     code = httpurlconnection.getResponseCode();
                     if(code != 200)
                     {
-                        System.out.println("Server response code did return " + code + ", skin servers might be down.");
+                        LogManager.getLogger().warn("Server response code did return " + code + ", skin servers might be down.");
                         return;
                     }
                 }
@@ -115,7 +89,7 @@ public class HumanSkinLoader
             }
             catch (Exception ex)
             {
-                System.out.println("Error occurred when downloading skin, however, skin servers seem to be up.");
+                LogManager.getLogger().warn("Error occurred when downloading skin, however, skin servers seem to be up.");
             }
             finally
             {

+ 6 - 1
src/main/java/me/km/entities/ModEntities.java

@@ -6,6 +6,7 @@ import net.minecraft.entity.EntityType;
 import net.minecraftforge.api.distmarker.Dist;
 import net.minecraftforge.api.distmarker.OnlyIn;
 import net.minecraftforge.fml.client.registry.RenderingRegistry;
+import net.minecraftforge.fml.loading.FMLEnvironment;
 import net.minecraftforge.registries.IForgeRegistry;
 
 public class ModEntities 
@@ -33,6 +34,10 @@ public class ModEntities
     
     public static void init(IForgeRegistry<EntityType<?>> r)
     {
+        if(FMLEnvironment.dist == Dist.CLIENT)
+        {
+            initClient();
+        }
         r.register(HUMAN);
         r.register(NOBODY);
         r.register(BROWN_BEAR);
@@ -40,7 +45,7 @@ public class ModEntities
     }
     
     @OnlyIn(Dist.CLIENT)
-    public static void initClient() 
+    private static void initClient() 
     {
         RenderingRegistry.registerEntityRenderingHandler(EntityBrownBear.class, (rm) -> 
         {

+ 0 - 2
src/main/java/me/km/entities/RenderBrownBear.java

@@ -8,7 +8,6 @@ import net.minecraft.client.renderer.entity.model.PolarBearModel;
 import net.minecraft.util.ResourceLocation;
 import net.minecraftforge.api.distmarker.Dist;
 import net.minecraftforge.api.distmarker.OnlyIn;
-import org.apache.logging.log4j.LogManager;
 
 @OnlyIn(Dist.CLIENT)
 public class RenderBrownBear extends MobRenderer<EntityBrownBear, PolarBearModel<EntityBrownBear>>
@@ -23,7 +22,6 @@ public class RenderBrownBear extends MobRenderer<EntityBrownBear, PolarBearModel
     @Override
     protected ResourceLocation getEntityTexture(EntityBrownBear entity)
     {
-        LogManager.getLogger().warn("HMM");
         return BLACK_BEAR_TEXTURE;
     }
 

+ 0 - 1
src/main/java/me/km/entities/RenderHuman.java

@@ -1,7 +1,6 @@
 package me.km.entities;
 
 import com.mojang.blaze3d.platform.GlStateManager;
-import net.minecraft.client.Minecraft;
 import net.minecraft.client.renderer.entity.EntityRendererManager;
 import net.minecraft.client.renderer.entity.LivingRenderer;
 import net.minecraft.client.renderer.entity.layers.ArrowLayer;

+ 0 - 61
src/main/java/me/km/networking/HumanScaleUpdate.java

@@ -1,61 +0,0 @@
-package me.km.networking;
-
-import java.util.function.Supplier;
-import me.km.entities.EntityHuman;
-import net.minecraft.client.Minecraft;
-import net.minecraft.entity.Entity;
-import net.minecraft.network.PacketBuffer;
-import net.minecraftforge.fml.network.NetworkEvent;
-
-public class HumanScaleUpdate
-{
-    private int humanId;
-    private float scale;
-    private byte slim;
-    
-    public HumanScaleUpdate() 
-    {
-        humanId = -1;
-        scale = 1;
-        slim = 0;
-    }
-    
-    public HumanScaleUpdate(EntityHuman h) 
-    {
-        humanId = h.getEntityId();
-        scale = h.getScale();
-        slim = h.getSlim();
-    }
-    
-    public static void writeBytes(HumanScaleUpdate hsu, PacketBuffer buf)
-    {
-        buf.writeInt(hsu.humanId);
-        buf.writeFloat(hsu.scale);
-        buf.writeByte(hsu.slim);
-    }
-    
-    public static HumanScaleUpdate fromBytes(PacketBuffer buf)
-    {
-        HumanScaleUpdate hsu = new HumanScaleUpdate();
-        hsu.humanId = buf.readInt();
-        hsu.scale = buf.readFloat();
-        hsu.slim = buf.readByte();
-        return hsu;
-    }
-    
-    public static void handle(HumanScaleUpdate hsu, Supplier<NetworkEvent.Context> context)
-    {
-        context.get().enqueueWork(() -> 
-        {
-            Entity ent = Minecraft.getInstance().world.getEntityByID(hsu.humanId);
-            if(ent == null || !(ent instanceof EntityHuman))
-            {
-                return;
-            }
-            EntityHuman h = (EntityHuman) ent;
-            h.setScale(hsu.scale);
-            h.setSlim(hsu.slim);
-        });
-        context.get().setPacketHandled(true);
-    }
-}

+ 0 - 61
src/main/java/me/km/networking/HumanUpdate.java

@@ -1,61 +0,0 @@
-package me.km.networking;
-
-import java.nio.charset.StandardCharsets;
-import java.util.function.Supplier;
-import me.km.entities.EntityHuman;
-import me.km.entities.HumanSkinLoader;
-import net.minecraft.client.Minecraft;
-import net.minecraft.entity.Entity;
-import net.minecraft.network.PacketBuffer;
-import net.minecraftforge.fml.network.NetworkEvent;
-
-public class HumanUpdate
-{
-    private int humanId;
-    private String name;
-    
-    public HumanUpdate() 
-    {
-        humanId = -1;
-        name = null;
-    }
-    
-    public HumanUpdate(EntityHuman h) 
-    {
-        humanId = h.getEntityId();
-        name = h.getSkinName();
-    }
-    
-    public static void writeBytes(HumanUpdate hu, PacketBuffer buf)
-    {
-        buf.writeInt(hu.humanId);
-        byte[] b = hu.name.getBytes(StandardCharsets.UTF_8);
-        buf.writeInt(b.length);
-        buf.writeBytes(b);
-    }
-    
-    public static HumanUpdate fromBytes(PacketBuffer buf)
-    {
-        HumanUpdate hu = new HumanUpdate();
-        hu.humanId = buf.readInt();
-        int length = buf.readInt();
-        hu.name = buf.readBytes(length).toString(StandardCharsets.UTF_8);
-        return hu;
-    }
-    
-    public static void handle(HumanUpdate hu, Supplier<NetworkEvent.Context> context)
-    {
-        context.get().enqueueWork(() -> 
-        {
-            Entity ent = Minecraft.getInstance().world.getEntityByID(hu.humanId);
-            if(ent == null || !(ent instanceof EntityHuman))
-            {
-                return;
-            }
-            EntityHuman h = (EntityHuman) ent;
-            h.setSkinName(hu.name);
-            h.setTexture(HumanSkinLoader.INSTANCE.getTexture(hu.name, loc -> h.setTexture(loc)));
-        });
-        context.get().setPacketHandled(true);
-    }
-}

+ 0 - 17
src/main/java/me/km/networking/ModPacketHandler.java

@@ -26,8 +26,6 @@ public class ModPacketHandler
         int id = 0;
         INSTANCE.registerMessage(id++, PlayerDisplay.class, PlayerDisplay::writeBytes, PlayerDisplay::fromBytes, PlayerDisplay::handle);
         INSTANCE.registerMessage(id++, FunctionKey.class, FunctionKey::writeBytes, FunctionKey::fromBytes, FunctionKey::handle);
-        INSTANCE.registerMessage(id++, HumanUpdate.class, HumanUpdate::writeBytes, HumanUpdate::fromBytes, HumanUpdate::handle);
-        INSTANCE.registerMessage(id++, HumanScaleUpdate.class, HumanScaleUpdate::writeBytes, HumanScaleUpdate::fromBytes, HumanScaleUpdate::handle);
         INSTANCE.registerMessage(id++, CustomInventory.class, CustomInventory::writeBytes, CustomInventory::fromBytes, CustomInventory::handle);
         INSTANCE.registerMessage(id++, StatusDisplay.class, StatusDisplay::writeBytes, StatusDisplay::fromBytes, StatusDisplay::handle);
         INSTANCE.registerMessage(id++, PlayerHead.class, PlayerHead::writeBytes, PlayerHead::fromBytes, PlayerHead::handle);
@@ -70,21 +68,6 @@ public class ModPacketHandler
         sendToServer(new FunctionKey(key));
     }
     
-    public static void sendHumanUpdate(ServerPlayerEntity p, EntityHuman human)
-    {
-        sendToPlayer(p, new HumanUpdate(human));
-    }
-    
-    public static void sendHumanUpdate(EntityHuman human)
-    {
-        sendToPlayers(new HumanUpdate(human));
-    }
-    
-    public static void sendHumanScaleUpdate(EntityHuman human)
-    {
-        sendToPlayers(new HumanScaleUpdate(human));
-    }
-    
     public static void sendCustomInventory(ServerPlayerEntity p, int id, ITextComponent title, InventoryBase inv)
     {
         sendToPlayer(p, new CustomInventory(id, title, inv));

+ 3 - 233
src/main/java/me/km/recipes/ModRecipes.java

@@ -24,19 +24,8 @@ public class ModRecipes
     // -----------------------------------------------------------------------------------
     
     /*private static int id = 0;
-    
-    public static void init(IForgeRegistry<IRecipe> r) 
-    {
-        id = 0;
-        FurnaceRecipes fr = FurnaceRecipes.instance();        
-        
+
         // misc
-        registerShapeless(r, "", new ItemStack(ModItems.bronzeIngot, 9), new Item[] 
-        {
-            ModItems.copperIngot, ModItems.copperIngot, ModItems.copperIngot,
-            ModItems.copperIngot, ModItems.copperIngot, ModItems.copperIngot,
-            ModItems.copperIngot, ModItems.copperIngot, ModItems.tinIngot
-        });
         registerShapeless(r, "", new ItemStack(Items.STRING, 4), new ItemStack[][] 
         {
             {new ItemStack(Blocks.WOOL)}
@@ -52,36 +41,7 @@ public class ModRecipes
                 new char[] {'X'}, new ItemStack[][] {{new ItemStack(Blocks.TALLGRASS, 1, 1), new ItemStack(Blocks.TALLGRASS, 1, 2)}});
         registerShaped(r, "", new String[] {" X ", "XXX"}, new ItemStack(ModItems.strawHat), 
                 new char[] {'X'}, new ItemStack[][] {{new ItemStack(Items.WHEAT)}});
-        registerShaped(r, "", new String[] {" S ", "SCS", "WWW"}, new ItemStack(ModItems.campFire), 
-                new char[] {'S', 'C', 'W'}, new ItemStack[][] 
-                {
-                    {
-                        new ItemStack(Items.STICK)
-                    },
-                    {
-                        new ItemStack(Items.COAL), new ItemStack(Items.COAL, 1, 1)
-                    },
-                    {
-                        new ItemStack(Blocks.LOG), new ItemStack(Blocks.LOG, 1, 1), new ItemStack(Blocks.LOG, 1, 2),
-                        new ItemStack(Blocks.LOG, 1, 3), new ItemStack(Blocks.LOG2, 1, 0), new ItemStack(Blocks.LOG2, 1, 1)
-                    }
-                });
-        registerShaped(r, "", new String[] {"XXX", "GCG", "XXX"}, new ItemStack(ModBlocks.lantern), 
-                new char[] {'X', 'G', 'C'}, new ItemStack[][] 
-                {
-                    {new ItemStack(Items.IRON_NUGGET)},
-                    {new ItemStack(Blocks.GLASS_PANE)},
-                    {new ItemStack(Blocks.TORCH)}
-                });
                 
-        // traps
-        addMetalRecipes(r, "", new String[] {" X ", "XXX"}, ModBlocks.spikes, 3);
-        
-        // furnace recipes
-        fr.addSmeltingRecipeForBlock(ModBlocks.copperOre, new ItemStack(ModItems.copperIngot), 0.5f);
-        fr.addSmeltingRecipeForBlock(ModBlocks.tinOre, new ItemStack(ModItems.tinIngot), 1);
-        fr.addSmeltingRecipeForBlock(ModBlocks.silverOre, new ItemStack(ModItems.silverIngot), 1);
-        
         // armor recipes
         Item[][] armorItems = new Item[][] 
         {
@@ -145,15 +105,10 @@ public class ModRecipes
         // block <-> parts <-> smaller parts recipes
         Object[][] ingotItems = new Object[][] 
         {
-            {ModBlocks.copperBlock, new ItemStack(ModItems.copperIngot, 9)}, 
             {ModItems.copperIngot, new ItemStack(ModItems.copperNugget, 9)}, 
-            {ModBlocks.tinBlock, new ItemStack(ModItems.tinIngot, 9)}, 
             {ModItems.tinIngot, new ItemStack(ModItems.tinNugget, 9)}, 
-            {ModBlocks.bronzeBlock, new ItemStack(ModItems.bronzeIngot, 9)}, 
             {ModItems.bronzeIngot, new ItemStack(ModItems.bronzeNugget, 9)}, 
-            {ModBlocks.silverBlock, new ItemStack(ModItems.silverIngot, 9)}, 
             {ModItems.silverIngot, new ItemStack(ModItems.silverNugget, 9)}, 
-            {ModBlocks.realHayBlock, new ItemStack(ModItems.hayBundle, 9)}, 
         };
         addIngotRecipes(r, ingotItems);
         
@@ -165,193 +120,8 @@ public class ModRecipes
             {ModItems.ironStick, ModItems.ironDagger, ModItems.ironHammer},
             {ModItems.goldStick, ModItems.goldDagger, ModItems.goldHammer}
         };
-        addToolNuggetRecipes(fr, toolItems, ModItems.copperNugget, ModItems.bronzeNugget, Items.IRON_NUGGET, Items.GOLD_NUGGET);
-        
-        addWoodRecipes(r);
-        
-        String[] pattern = new String[] {"X X", "X X", "XXX"};
-        registerShaped(r, "", pattern, new ItemStack(ModBlocks.cookingPotCopper), new char[] {'X'}, new ItemStack[][] {{new ItemStack(ModItems.copperIngot)}});
-    }
-
-    // -----------------------------------------------------------------------------------
-    // recipe helper
-    // -----------------------------------------------------------------------------------
-    
-    private static void addArmorRecipes(IForgeRegistry<IRecipe> r, Item[][] armorItems)
-    {
-        String[][] armorPatterns = new String[][] 
-        {
-            {"XXX", "X X"}, 
-            {"X X", "XXX", "XXX"}, 
-            {"XXX", "X X", "X X"}, 
-            {"X X", "X X"}
-        };
-        char[] chars = new char[] {'X'};
-        ItemStack[][] stacks = new ItemStack[][] {{ItemStack.EMPTY}};
-        
-        for (int i = 0; i < armorItems[0].length; ++i)
-        {
-            stacks[0][0] = new ItemStack(armorItems[0][i]);
-            for (int j = 0; j < armorItems.length - 1; ++j)
-            {
-                registerShaped(r, "", armorPatterns[j], new ItemStack(armorItems[j + 1][i]), chars, stacks);
-            }
-        }
-    }
-    
-    private static void addToolRecipes(IForgeRegistry<IRecipe> r, String[][] toolPatterns, Object[][] toolItems)
-    {       
-        char[] chars = new char[] {'#', 'X'};
-        ItemStack[][] stacks = new ItemStack[][] {{new ItemStack(Items.STICK)} , {ItemStack.EMPTY}};
-        
-        for(int i = 0; i < toolItems[0].length; ++i)
-        {
-            Object object = toolItems[0][i];
-            if(object instanceof Item)
-            {
-                stacks[1][0] = new ItemStack((Item) toolItems[0][i]);
-            }
-            else if(object instanceof Block)
-            {
-                Block b = (Block) toolItems[0][i];
-                NonNullList<ItemStack> list = NonNullList.<ItemStack>create();               
-                b.getSubBlocks(CreativeTabs.BUILDING_BLOCKS, list);
-                stacks[1] = new ItemStack[list.size()];
-                for(int k = 0; k < list.size(); k++)
-                {
-                    stacks[1][k] = list.get(k);
-                }
-            }
-            else if(object instanceof ItemStack)
-            {
-                stacks[1][0] = (ItemStack) toolItems[0][i];
-            }
-            else
-            {
-                throw new IllegalArgumentException("only blocks or items are allowed");
-            }
-            for(int j = 0; j < toolItems.length - 1; ++j)
-            {
-                registerShaped(r, "", toolPatterns[j], new ItemStack((Item) toolItems[j + 1][i]), chars, stacks);
-            }
-        }
+        addToolNuggetRecipes(fr, toolItems, ModItems.copperNugget, ModItems.bronzeNugget, Items.IRON_NUGGET, Items.GOLD_NUGGET);       
     }
 
-    private static void addIngotRecipes(IForgeRegistry<IRecipe> r, Object[][] ingotItems)
-    {
-        String[] blockPattern = new String[] {"###", "###", "###"};
-        String[] ingotPattern = new String[] {"#"};
-        char[] chars = new char[] {'#'};
-        ItemStack[][] stacks = new ItemStack[][] {{ItemStack.EMPTY}};
-        
-        for(Object[] aobject : ingotItems)
-        {
-            try
-            {
-                Item block = (Item) aobject[0];
-                ItemStack parts = (ItemStack) aobject[1];
-                ItemStack ingot = parts.copy();
-                ingot.setCount(1);
-                stacks[0][0] = ingot;
-                registerShaped(r, "",  blockPattern, new ItemStack(block), chars, stacks);
-                stacks[0][0] = new ItemStack(block);
-                registerShaped(r, "", ingotPattern, parts, chars, stacks);
-            }
-            catch(ClassCastException ex)
-            {
-                Block block = (Block) aobject[0];
-                ItemStack parts = (ItemStack) aobject[1];
-                ItemStack ingot = parts.copy();
-                ingot.setCount(1);
-                stacks[0][0] = ingot;
-                registerShaped(r, "", blockPattern, new ItemStack(block), chars, stacks);
-                stacks[0][0] = new ItemStack(block);
-                registerShaped(r, "", ingotPattern, parts, chars, stacks);
-            }
-        }
-    }
-    
-    private static void addArmorNuggetRecipes(FurnaceRecipes fr, Item[][] armorItems, Item... nuggets)
-    {
-        for(int i = 0; i < nuggets.length; i++)
-        {
-            for(int j = 1; j < armorItems.length; j++)
-            {
-                fr.addSmelting((Item) armorItems[j][i], new ItemStack(nuggets[i]), 0.1f);
-            }
-        }
-    }
-    
-    private static void addToolNuggetRecipes(FurnaceRecipes fr, Object[][] toolItems, Item... nuggets)
-    {
-        for(int i = 0; i < nuggets.length; i++)
-        {
-            for(Object toolItem : toolItems[i]) 
-            {
-                fr.addSmelting((Item) toolItem, new ItemStack(nuggets[i]), 0.1f);
-            }
-        }
-    }
-    
-    private static void addMetalRecipes(IForgeRegistry<IRecipe> r, String group, String[] pattern, Item output, int amount)
-    {
-        char[] chars = new char[] {'X'};
-        ItemStack[][] stacks = new ItemStack[][] {{ItemStack.EMPTY}};
-        
-        for(EnumMetals metal : EnumMetals.values())
-        {
-            stacks[0][0] = new ItemStack(metal.getMetalIngot());       
-            registerShaped(r, group, pattern, new ItemStack(output, amount, metal.getMetadata()), chars, stacks);
-        }
-    }
-    
-    private static void addMetalRecipes(IForgeRegistry<IRecipe> r, String group, String[] patterns, Block output, int amount)
-    {
-        addMetalRecipes(r, group, patterns, Item.getItemFromBlock(output), amount);
-    }
-    
-    private static void addPlankRecipe(IForgeRegistry<IRecipe> r, String[] pattern, Item item, ItemStack result)
-    {       
-        char[] chars = new char[] {'#', 'X'};
-        ItemStack[][] stacks = new ItemStack[][] {{} , {new ItemStack(item)}};
-        NonNullList<ItemStack> list = NonNullList.<ItemStack>create();               
-        Blocks.PLANKS.getSubBlocks(CreativeTabs.BUILDING_BLOCKS, list);
-        stacks[0] = new ItemStack[list.size()];
-        for(int k = 0; k < list.size(); k++)
-        {
-            stacks[0][k] = list.get(k);
-        }
-        registerShaped(r, "", pattern, result, chars, stacks);
-    }
-    
-    private static void addWoodRecipes(IForgeRegistry<IRecipe> r)
-    {
-        ItemStack[] planks = new ItemStack[] 
-        {
-            new ItemStack(Blocks.PLANKS, 1, 0), new ItemStack(Blocks.PLANKS, 1, 1), 
-            new ItemStack(Blocks.PLANKS, 1, 2), new ItemStack(Blocks.PLANKS, 1, 3), 
-            new ItemStack(Blocks.PLANKS, 1, 4), new ItemStack(Blocks.PLANKS, 1, 5) 
-        };
-        
-        ItemStack[] result = new ItemStack[] 
-        {
-            new ItemStack(ModBlocks.crateOak), new ItemStack(ModBlocks.crateSpruce), 
-            new ItemStack(ModBlocks.crateBirch), new ItemStack(ModBlocks.crateJungle), 
-            new ItemStack(ModBlocks.crateAcacia), new ItemStack(ModBlocks.crateBigOak) 
-        };
-        String[] pattern = new String[] {"XXX", "XXX", "XXX"};
-        for(int i = 0; i < planks.length; i++)
-        {
-            registerShaped(r, "", pattern, result[i], new char[] {'X'}, new ItemStack[][] {{planks[i]}});
-        }
-        
-        ItemStack[] slabs = new ItemStack[] 
-        {
-            new ItemStack(Blocks.WOODEN_SLAB, 1, 0), new ItemStack(Blocks.WOODEN_SLAB, 1, 1), 
-            new ItemStack(Blocks.WOODEN_SLAB, 1, 2), new ItemStack(Blocks.WOODEN_SLAB, 1, 3), 
-            new ItemStack(Blocks.WOODEN_SLAB, 1, 4), new ItemStack(Blocks.WOODEN_SLAB, 1, 5) 
-        };   
-        pattern = new String[] {"XSX", "X X", "XSX"};
-        registerShaped(r, "", pattern, new ItemStack(ModBlocks.barrel), new char[] {'X', 'S'}, new ItemStack[][] {planks, slabs});
-    }*/
+    */
 }

+ 0 - 1
src/main/java/me/km/snuviscript/MinecraftFunctions.java

@@ -5,7 +5,6 @@ import com.mojang.brigadier.StringReader;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
 import java.sql.SQLException;
-import me.km.KajetansMod;
 import java.util.ArrayList;
 import java.util.Date;
 import java.util.GregorianCalendar;

+ 185 - 0
src/main/resources/data/km/loot_tables/blocks/apricot_leaves.json

@@ -0,0 +1,185 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:alternatives",
+          "children": [
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:alternative",
+                  "terms": [
+                    {
+                      "condition": "minecraft:match_tool",
+                      "predicate": {
+                        "item": "minecraft:shears"
+                      }
+                    },
+                    {
+                      "condition": "minecraft:match_tool",
+                      "predicate": {
+                        "enchantments": [
+                          {
+                            "enchantment": "minecraft:silk_touch",
+                            "levels": {
+                              "min": 1
+                            }
+                          }
+                        ]
+                      }
+                    }
+                  ]
+                }
+              ],
+              "name": "km:apricot_leaves"
+            },
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:survives_explosion"
+                },
+                {
+                  "condition": "minecraft:table_bonus",
+                  "enchantment": "minecraft:fortune",
+                  "chances": [
+                    0.05,
+                    0.0625,
+                    0.083333336,
+                    0.1
+                  ]
+                }
+              ],
+              "name": "km:apricot_sapling"
+            }
+          ]
+        }
+      ]
+    },
+    {
+      "name": "sticks",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "conditions": [
+            {
+              "condition": "minecraft:table_bonus",
+              "enchantment": "minecraft:fortune",
+              "chances": [
+                0.02,
+                0.022222223,
+                0.025,
+                0.033333335,
+                0.1
+              ]
+            }
+          ],
+          "functions": [
+            {
+              "function": "minecraft:set_count",
+              "count": {
+                "min": 1.0,
+                "max": 2.0,
+                "type": "minecraft:uniform"
+              }
+            },
+            {
+              "function": "minecraft:explosion_decay"
+            }
+          ],
+          "name": "minecraft:stick"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:inverted",
+          "term": {
+            "condition": "minecraft:alternative",
+            "terms": [
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "item": "minecraft:shears"
+                }
+              },
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "enchantments": [
+                    {
+                      "enchantment": "minecraft:silk_touch",
+                      "levels": {
+                        "min": 1
+                      }
+                    }
+                  ]
+                }
+              }
+            ]
+          }
+        }
+      ]
+    },
+    {
+      "name": "fruit",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "conditions": [
+            {
+              "condition": "minecraft:survives_explosion"
+            },
+            {
+              "condition": "minecraft:table_bonus",
+              "enchantment": "minecraft:fortune",
+              "chances": [
+                0.005,
+                0.0055555557,
+                0.00625,
+                0.008333334,
+                0.025
+              ]
+            }
+          ],
+          "name": "km:apricot"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:inverted",
+          "term": {
+            "condition": "minecraft:alternative",
+            "terms": [
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "item": "minecraft:shears"
+                }
+              },
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "enchantments": [
+                    {
+                      "enchantment": "minecraft:silk_touch",
+                      "levels": {
+                        "min": 1
+                      }
+                    }
+                  ]
+                }
+              }
+            ]
+          }
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/apricot_sapling.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:apricot_sapling"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/artefact.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:artefact"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/bronze_block.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:bronze_block"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 130 - 0
src/main/resources/data/km/loot_tables/blocks/cherry_leaves.json

@@ -0,0 +1,130 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:alternatives",
+          "children": [
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:alternative",
+                  "terms": [
+                    {
+                      "condition": "minecraft:match_tool",
+                      "predicate": {
+                        "item": "minecraft:shears"
+                      }
+                    },
+                    {
+                      "condition": "minecraft:match_tool",
+                      "predicate": {
+                        "enchantments": [
+                          {
+                            "enchantment": "minecraft:silk_touch",
+                            "levels": {
+                              "min": 1
+                            }
+                          }
+                        ]
+                      }
+                    }
+                  ]
+                }
+              ],
+              "name": "km:cherry_leaves"
+            },
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:survives_explosion"
+                },
+                {
+                  "condition": "minecraft:table_bonus",
+                  "enchantment": "minecraft:fortune",
+                  "chances": [
+                    0.05,
+                    0.0625,
+                    0.083333336,
+                    0.1
+                  ]
+                }
+              ],
+              "name": "km:cherry_sapling"
+            }
+          ]
+        }
+      ]
+    },
+    {
+      "name": "sticks",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "conditions": [
+            {
+              "condition": "minecraft:table_bonus",
+              "enchantment": "minecraft:fortune",
+              "chances": [
+                0.02,
+                0.022222223,
+                0.025,
+                0.033333335,
+                0.1
+              ]
+            }
+          ],
+          "functions": [
+            {
+              "function": "minecraft:set_count",
+              "count": {
+                "min": 1.0,
+                "max": 2.0,
+                "type": "minecraft:uniform"
+              }
+            },
+            {
+              "function": "minecraft:explosion_decay"
+            }
+          ],
+          "name": "minecraft:stick"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:inverted",
+          "term": {
+            "condition": "minecraft:alternative",
+            "terms": [
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "item": "minecraft:shears"
+                }
+              },
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "enchantments": [
+                    {
+                      "enchantment": "minecraft:silk_touch",
+                      "levels": {
+                        "min": 1
+                      }
+                    }
+                  ]
+                }
+              }
+            ]
+          }
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/cherry_sapling.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:cherry_sapling"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/cooking_pot_copper.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:cooking_pot_copper"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/copper_block.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:copper_block"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/copper_ore.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:copper_ore"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/crate_acacia.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:crate_acacia"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/crate_big_oak.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:crate_big_oak"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/crate_birch.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:crate_birch"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/crate_jungle.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:crate_jungle"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/crate_oak.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:crate_oak"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/crate_spruce.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:crate_spruce"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 119 - 0
src/main/resources/data/km/loot_tables/blocks/gravel_slab.json

@@ -0,0 +1,119 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:alternatives",
+          "children": [
+            {
+              "type": "minecraft:item",
+              "functions": [
+                {
+                  "function": "minecraft:set_count",
+                  "conditions": [
+                    {
+                      "condition": "minecraft:block_state_property",
+                      "block": "km:gravel_slab",
+                      "properties": {
+                        "type": "double"
+                      }
+                    }
+                  ],
+                  "count": 2
+                },
+                {
+                  "function": "minecraft:explosion_decay"
+                }
+              ],
+              "conditions": [
+                {
+                  "condition": "minecraft:match_tool",
+                  "predicate": {
+                    "enchantments": [
+                      {
+                        "enchantment": "minecraft:silk_touch",
+                        "levels": {
+                          "min": 1
+                        }
+                      }
+                    ]
+                  }
+                }
+              ],
+              "name": "km:gravel_slab"
+            },
+            {
+              "type": "minecraft:alternatives",
+              "conditions": [
+                {
+                  "condition": "minecraft:survives_explosion"
+                }
+              ],
+              "children": [
+                {
+                  "type": "minecraft:item",
+                  "functions": [
+                    {
+                      "function": "minecraft:set_count",
+                      "conditions": [
+                        {
+                          "condition": "minecraft:block_state_property",
+                          "block": "km:gravel_slab",
+                          "properties": {
+                            "type": "double"
+                          }
+                        }
+                      ],
+                      "count": 2
+                    },
+                    {
+                      "function": "minecraft:explosion_decay"
+                    }
+                  ],
+                  "conditions": [
+                    {
+                      "condition": "minecraft:table_bonus",
+                      "enchantment": "minecraft:fortune",
+                      "chances": [
+                        0.1,
+                        0.14285715,
+                        0.25,
+                        1.0
+                      ]
+                    }
+                  ],
+                  "name": "minecraft:flint"
+                },
+                {
+                  "type": "minecraft:item",
+                  "functions": [
+                    {
+                      "function": "minecraft:set_count",
+                      "conditions": [
+                        {
+                          "condition": "minecraft:block_state_property",
+                          "block": "km:gravel_slab",
+                          "properties": {
+                            "type": "double"
+                          }
+                        }
+                      ],
+                      "count": 2
+                    },
+                    {
+                      "function": "minecraft:explosion_decay"
+                    }
+                  ],
+                  "name": "km:gravel_slab"
+                }
+              ]
+            }
+          ]
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/guild_block.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:guild_block"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 185 - 0
src/main/resources/data/km/loot_tables/blocks/pear_leaves.json

@@ -0,0 +1,185 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:alternatives",
+          "children": [
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:alternative",
+                  "terms": [
+                    {
+                      "condition": "minecraft:match_tool",
+                      "predicate": {
+                        "item": "minecraft:shears"
+                      }
+                    },
+                    {
+                      "condition": "minecraft:match_tool",
+                      "predicate": {
+                        "enchantments": [
+                          {
+                            "enchantment": "minecraft:silk_touch",
+                            "levels": {
+                              "min": 1
+                            }
+                          }
+                        ]
+                      }
+                    }
+                  ]
+                }
+              ],
+              "name": "km:pear_leaves"
+            },
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:survives_explosion"
+                },
+                {
+                  "condition": "minecraft:table_bonus",
+                  "enchantment": "minecraft:fortune",
+                  "chances": [
+                    0.05,
+                    0.0625,
+                    0.083333336,
+                    0.1
+                  ]
+                }
+              ],
+              "name": "km:pear_sapling"
+            }
+          ]
+        }
+      ]
+    },
+    {
+      "name": "sticks",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "conditions": [
+            {
+              "condition": "minecraft:table_bonus",
+              "enchantment": "minecraft:fortune",
+              "chances": [
+                0.02,
+                0.022222223,
+                0.025,
+                0.033333335,
+                0.1
+              ]
+            }
+          ],
+          "functions": [
+            {
+              "function": "minecraft:set_count",
+              "count": {
+                "min": 1.0,
+                "max": 2.0,
+                "type": "minecraft:uniform"
+              }
+            },
+            {
+              "function": "minecraft:explosion_decay"
+            }
+          ],
+          "name": "minecraft:stick"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:inverted",
+          "term": {
+            "condition": "minecraft:alternative",
+            "terms": [
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "item": "minecraft:shears"
+                }
+              },
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "enchantments": [
+                    {
+                      "enchantment": "minecraft:silk_touch",
+                      "levels": {
+                        "min": 1
+                      }
+                    }
+                  ]
+                }
+              }
+            ]
+          }
+        }
+      ]
+    },
+    {
+      "name": "fruit",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "conditions": [
+            {
+              "condition": "minecraft:survives_explosion"
+            },
+            {
+              "condition": "minecraft:table_bonus",
+              "enchantment": "minecraft:fortune",
+              "chances": [
+                0.005,
+                0.0055555557,
+                0.00625,
+                0.008333334,
+                0.025
+              ]
+            }
+          ],
+          "name": "km:pear"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:inverted",
+          "term": {
+            "condition": "minecraft:alternative",
+            "terms": [
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "item": "minecraft:shears"
+                }
+              },
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "enchantments": [
+                    {
+                      "enchantment": "minecraft:silk_touch",
+                      "levels": {
+                        "min": 1
+                      }
+                    }
+                  ]
+                }
+              }
+            ]
+          }
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/pear_sapling.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:pear_sapling"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 185 - 0
src/main/resources/data/km/loot_tables/blocks/plum_leaves.json

@@ -0,0 +1,185 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:alternatives",
+          "children": [
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:alternative",
+                  "terms": [
+                    {
+                      "condition": "minecraft:match_tool",
+                      "predicate": {
+                        "item": "minecraft:shears"
+                      }
+                    },
+                    {
+                      "condition": "minecraft:match_tool",
+                      "predicate": {
+                        "enchantments": [
+                          {
+                            "enchantment": "minecraft:silk_touch",
+                            "levels": {
+                              "min": 1
+                            }
+                          }
+                        ]
+                      }
+                    }
+                  ]
+                }
+              ],
+              "name": "km:plum_leaves"
+            },
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:survives_explosion"
+                },
+                {
+                  "condition": "minecraft:table_bonus",
+                  "enchantment": "minecraft:fortune",
+                  "chances": [
+                    0.05,
+                    0.0625,
+                    0.083333336,
+                    0.1
+                  ]
+                }
+              ],
+              "name": "km:plum_sapling"
+            }
+          ]
+        }
+      ]
+    },
+    {
+      "name": "sticks",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "conditions": [
+            {
+              "condition": "minecraft:table_bonus",
+              "enchantment": "minecraft:fortune",
+              "chances": [
+                0.02,
+                0.022222223,
+                0.025,
+                0.033333335,
+                0.1
+              ]
+            }
+          ],
+          "functions": [
+            {
+              "function": "minecraft:set_count",
+              "count": {
+                "min": 1.0,
+                "max": 2.0,
+                "type": "minecraft:uniform"
+              }
+            },
+            {
+              "function": "minecraft:explosion_decay"
+            }
+          ],
+          "name": "minecraft:stick"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:inverted",
+          "term": {
+            "condition": "minecraft:alternative",
+            "terms": [
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "item": "minecraft:shears"
+                }
+              },
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "enchantments": [
+                    {
+                      "enchantment": "minecraft:silk_touch",
+                      "levels": {
+                        "min": 1
+                      }
+                    }
+                  ]
+                }
+              }
+            ]
+          }
+        }
+      ]
+    },
+    {
+      "name": "fruit",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "conditions": [
+            {
+              "condition": "minecraft:survives_explosion"
+            },
+            {
+              "condition": "minecraft:table_bonus",
+              "enchantment": "minecraft:fortune",
+              "chances": [
+                0.005,
+                0.0055555557,
+                0.00625,
+                0.008333334,
+                0.025
+              ]
+            }
+          ],
+          "name": "km:plum"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:inverted",
+          "term": {
+            "condition": "minecraft:alternative",
+            "terms": [
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "item": "minecraft:shears"
+                }
+              },
+              {
+                "condition": "minecraft:match_tool",
+                "predicate": {
+                  "enchantments": [
+                    {
+                      "enchantment": "minecraft:silk_touch",
+                      "levels": {
+                        "min": 1
+                      }
+                    }
+                  ]
+                }
+              }
+            ]
+          }
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/plum_sapling.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main", 
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:plum_sapling"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 51 - 0
src/main/resources/data/km/loot_tables/blocks/rtall_grass.json

@@ -0,0 +1,51 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:alternatives",
+          "children": [
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:match_tool",
+                  "predicate": {
+                    "item": "minecraft:shears"
+                  }
+                }
+              ],
+              "name": "km:rtall_grass"
+            },
+            {
+              "type": "minecraft:item",
+              "conditions": [
+                {
+                  "condition": "minecraft:random_chance",
+                  "chance": 0.125
+                }
+              ],
+              "functions": [
+                {
+                  "function": "minecraft:apply_bonus",
+                  "enchantment": "minecraft:fortune",
+                  "formula": "minecraft:uniform_bonus_count",
+                  "parameters": {
+                    "bonusMultiplier": 2
+                  }
+                },
+                {
+                  "function": "minecraft:explosion_decay"
+                }
+              ],
+              "name": "minecraft:wheat_seeds"
+            }
+          ]
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/silver_block.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:silver_block"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/silver_ore.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:silver_ore"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/spikes_bronze.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:spikes_bronze"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/spikes_copper.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:spikes_copper"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/spikes_gold.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:spikes_gold"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/spikes_iron.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:spikes_iron"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/tin_block.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:tin_block"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 20 - 0
src/main/resources/data/km/loot_tables/blocks/tin_ore.json

@@ -0,0 +1,20 @@
+{
+  "type": "minecraft:block",
+  "pools": [
+    {
+      "name": "main",
+      "rolls": 1,
+      "entries": [
+        {
+          "type": "minecraft:item",
+          "name": "km:tin_ore"
+        }
+      ],
+      "conditions": [
+        {
+          "condition": "minecraft:survives_explosion"
+        }
+      ]
+    }
+  ]
+}

+ 16 - 0
src/main/resources/data/km/recipes/bronze_block.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "###",
+    "###",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:bronze_ingot"
+    }
+  },
+  "result": {
+    "item": "km:bronze_block"
+  }
+}

+ 36 - 0
src/main/resources/data/km/recipes/bronze_ingot.json

@@ -0,0 +1,36 @@
+{
+  "type": "minecraft:crafting_shapeless",
+  "ingredients": [
+    {
+      "item": "km:tin_ingot"
+    },
+    {
+      "item": "km:copper_ingot"
+    },
+    {
+      "item": "km:copper_ingot"
+    },
+    {
+      "item": "km:copper_ingot"
+    },
+    {
+      "item": "km:copper_ingot"
+    },
+    {
+      "item": "km:copper_ingot"
+    },
+    {
+      "item": "km:copper_ingot"
+    },
+    {
+      "item": "km:copper_ingot"
+    },
+    {
+      "item": "km:copper_ingot"
+    }
+  ],
+  "result": {
+    "item": "km:bronze_ingot",
+    "count": 9
+  }
+}

+ 13 - 0
src/main/resources/data/km/recipes/bronze_ingot_from_bronze_block.json

@@ -0,0 +1,13 @@
+{
+  "type": "minecraft:crafting_shapeless",
+  "group": "bronze_ingot",
+  "ingredients": [
+    {
+      "item": "km:bronze_block"
+    }
+  ],
+  "result": {
+    "item": "km:bronze_ingot",
+    "count": 9
+  }
+}

+ 17 - 0
src/main/resources/data/km/recipes/bronze_ingot_from_nuggets.json

@@ -0,0 +1,17 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "group": "bronze_ingot",
+  "pattern": [
+    "###",
+    "###",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:bronze_nugget"
+    }
+  },
+  "result": {
+    "item": "km:bronze_ingot"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/cooking_pot_copper.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "# #",
+    "# #",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:copper_ingot"
+    }
+  },
+  "result": {
+    "item": "km:cooking_pot_copper"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/copper_block.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "###",
+    "###",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:copper_ingot"
+    }
+  },
+  "result": {
+    "item": "km:copper_block"
+  }
+}

+ 9 - 0
src/main/resources/data/km/recipes/copper_from_blasting.json

@@ -0,0 +1,9 @@
+{
+  "type": "minecraft:blasting",
+  "ingredient": {
+    "item": "km:copper_ore"
+  },
+  "result": "km:copper_ingot",
+  "experience": 0.6,
+  "cookingtime": 100
+}

+ 9 - 0
src/main/resources/data/km/recipes/copper_ingot.json

@@ -0,0 +1,9 @@
+{
+  "type": "minecraft:smelting",
+  "ingredient": {
+    "item": "km:copper_ore"
+  },
+  "result": "km:copper_ingot",
+  "experience": 0.6,
+  "cookingtime": 200
+}

+ 13 - 0
src/main/resources/data/km/recipes/copper_ingot_from_copper_block.json

@@ -0,0 +1,13 @@
+{
+  "type": "minecraft:crafting_shapeless",
+  "group": "copper_ingot",
+  "ingredients": [
+    {
+      "item": "km:copper_block"
+    }
+  ],
+  "result": {
+    "item": "km:copper_ingot",
+    "count": 9
+  }
+}

+ 17 - 0
src/main/resources/data/km/recipes/copper_ingot_from_nuggets.json

@@ -0,0 +1,17 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "group": "copper_ingot",
+  "pattern": [
+    "###",
+    "###",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:copper_nugget"
+    }
+  },
+  "result": {
+    "item": "km:copper_ingot"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/crate_acacia.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "XXX",
+    "XXX",
+    "XXX"
+  ],
+  "key": {
+    "X": {
+      "item": "minecraft:acacia_planks"
+    }
+  },
+  "result": {
+    "item": "km:crate_acacia"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/crate_big_oak.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "XXX",
+    "XXX",
+    "XXX"
+  ],
+  "key": {
+    "X": {
+      "item": "minecraft:dark_oak_planks"
+    }
+  },
+  "result": {
+    "item": "km:crate_big_oak"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/crate_birch.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "XXX",
+    "XXX",
+    "XXX"
+  ],
+  "key": {
+    "X": {
+      "item": "minecraft:birch_planks"
+    }
+  },
+  "result": {
+    "item": "km:crate_birch"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/crate_jungle.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "XXX",
+    "XXX",
+    "XXX"
+  ],
+  "key": {
+    "X": {
+      "item": "minecraft:jungle_planks"
+    }
+  },
+  "result": {
+    "item": "km:crate_jungle"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/crate_oak.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "XXX",
+    "XXX",
+    "XXX"
+  ],
+  "key": {
+    "X": {
+      "item": "minecraft:oak_planks"
+    }
+  },
+  "result": {
+    "item": "km:crate_oak"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/crate_spruce.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "XXX",
+    "XXX",
+    "XXX"
+  ],
+  "key": {
+    "X": {
+      "item": "minecraft:spruce_planks"
+    }
+  },
+  "result": {
+    "item": "km:crate_spruce"
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/gravel_slab.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "group": "gravel_slab",
+  "pattern": [
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "minecraft:gravel"
+    }
+  },
+  "result": {
+    "item": "km:gravel_slab",
+    "count": 6
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/silver_block.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "###",
+    "###",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:silver_ingot"
+    }
+  },
+  "result": {
+    "item": "km:silver_block"
+  }
+}

+ 9 - 0
src/main/resources/data/km/recipes/silver_ingot.json

@@ -0,0 +1,9 @@
+{
+  "type": "minecraft:smelting",
+  "ingredient": {
+    "item": "km:silver_ore"
+  },
+  "result": "km:silver_ingot",
+  "experience": 0.9,
+  "cookingtime": 200
+}

+ 9 - 0
src/main/resources/data/km/recipes/silver_ingot_from_blasting.json

@@ -0,0 +1,9 @@
+{
+  "type": "minecraft:blasting",
+  "ingredient": {
+    "item": "km:silver_ore"
+  },
+  "result": "km:silver_ingot",
+  "experience": 0.9,
+  "cookingtime": 100
+}

+ 17 - 0
src/main/resources/data/km/recipes/silver_ingot_from_nuggets.json

@@ -0,0 +1,17 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "group": "silver_ingot",
+  "pattern": [
+    "###",
+    "###",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:silver_nugget"
+    }
+  },
+  "result": {
+    "item": "km:silver_ingot"
+  }
+}

+ 13 - 0
src/main/resources/data/km/recipes/silver_ingot_from_silver_block.json

@@ -0,0 +1,13 @@
+{
+  "type": "minecraft:crafting_shapeless",
+  "group": "silver_ingot",
+  "ingredients": [
+    {
+      "item": "km:silver_block"
+    }
+  ],
+  "result": {
+    "item": "km:silver_ingot",
+    "count": 9
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/spikes_bronze.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    " # ",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:bronze_ingot"
+    }
+  },
+  "result": {
+    "item": "km:spikes_bronze",
+    "count": 3
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/spikes_copper.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    " # ",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:copper_ingot"
+    }
+  },
+  "result": {
+    "item": "km:spikes_copper",
+    "count": 3
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/spikes_gold.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    " # ",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "minecraft:gold_ingot"
+    }
+  },
+  "result": {
+    "item": "km:spikes_gold",
+    "count": 3
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/spikes_iron.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    " # ",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "minecraft:iron_ingot"
+    }
+  },
+  "result": {
+    "item": "km:spikes_iron",
+    "count": 3
+  }
+}

+ 16 - 0
src/main/resources/data/km/recipes/tin_block.json

@@ -0,0 +1,16 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "pattern": [
+    "###",
+    "###",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:tin_ingot"
+    }
+  },
+  "result": {
+    "item": "km:tin_block"
+  }
+}

+ 9 - 0
src/main/resources/data/km/recipes/tin_ingot.json

@@ -0,0 +1,9 @@
+{
+  "type": "minecraft:smelting",
+  "ingredient": {
+    "item": "km:tin_ore"
+  },
+  "result": "km:tin_ingot",
+  "experience": 0.8,
+  "cookingtime": 200
+}

+ 9 - 0
src/main/resources/data/km/recipes/tin_ingot_from_blasting.json

@@ -0,0 +1,9 @@
+{
+  "type": "minecraft:blasting",
+  "ingredient": {
+    "item": "km:tin_ore"
+  },
+  "result": "km:tin_ingot",
+  "experience": 0.8,
+  "cookingtime": 100
+}

+ 17 - 0
src/main/resources/data/km/recipes/tin_ingot_from_nuggets.json

@@ -0,0 +1,17 @@
+{
+  "type": "minecraft:crafting_shaped",
+  "group": "tin_ingot",
+  "pattern": [
+    "###",
+    "###",
+    "###"
+  ],
+  "key": {
+    "#": {
+      "item": "km:tin_nugget"
+    }
+  },
+  "result": {
+    "item": "km:tin_ingot"
+  }
+}

+ 13 - 0
src/main/resources/data/km/recipes/tin_ingot_from_tin_block.json

@@ -0,0 +1,13 @@
+{
+  "type": "minecraft:crafting_shapeless",
+  "group": "tin_ingot",
+  "ingredients": [
+    {
+      "item": "km:tin_block"
+    }
+  ],
+  "result": {
+    "item": "km:tin_ingot",
+    "count": 9
+  }
+}

+ 6 - 0
src/main/resources/data/minecraft/tags/blocks/beds.json

@@ -0,0 +1,6 @@
+{
+  "replace": false,
+  "values": [
+    "km:real_hay_bed"
+  ]
+}

+ 9 - 0
src/main/resources/data/minecraft/tags/blocks/leaves.json

@@ -0,0 +1,9 @@
+{
+  "replace": false,
+  "values": [
+    "km:cherry_leaves",
+    "km:apricot_leaves",
+    "km:pear_leaves",
+    "km:plum_leaves"
+  ]
+}

+ 9 - 0
src/main/resources/data/minecraft/tags/blocks/saplings.json

@@ -0,0 +1,9 @@
+{
+  "replace": false,
+  "values": [
+    "km:cherry_sapling",
+    "km:apricot_sapling",
+    "km:pear_sapling",
+    "km:plum_sapling"
+  ]
+}

+ 6 - 0
src/main/resources/data/minecraft/tags/blocks/slabs.json

@@ -0,0 +1,6 @@
+{
+  "replace": false,
+  "values": [
+    "km:gravel_slab"
+  ]
+}

+ 6 - 0
src/main/resources/data/minecraft/tags/items/beds.json

@@ -0,0 +1,6 @@
+{
+  "replace": false,
+  "values": [
+    "km:real_hay_bed"
+  ]
+}

+ 9 - 0
src/main/resources/data/minecraft/tags/items/leaves.json

@@ -0,0 +1,9 @@
+{
+  "replace": false,
+  "values": [
+    "km:cherry_leaves",
+    "km:apricot_leaves",
+    "km:pear_leaves",
+    "km:plum_leaves"
+  ]
+}

+ 9 - 0
src/main/resources/data/minecraft/tags/items/saplings.json

@@ -0,0 +1,9 @@
+{
+  "replace": false,
+  "values": [
+    "km:cherry_sapling",
+    "km:apricot_sapling",
+    "km:pear_sapling",
+    "km:plum_sapling"
+  ]
+}

+ 6 - 0
src/main/resources/data/minecraft/tags/items/slabs.json

@@ -0,0 +1,6 @@
+{
+  "replace": false,
+  "values": [
+    "km:gravel_slab"
+  ]
+}