Skip to content

Commit

Permalink
Fix extra Eucalyptus double slab
Browse files Browse the repository at this point in the history
  • Loading branch information
Ruling-0 committed Jan 17, 2025
1 parent ed7fb0a commit 10ddb67
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
16 changes: 8 additions & 8 deletions src/main/java/mods/natura/blocks/NSlabBase.java
Original file line number Diff line number Diff line change
Expand Up @@ -78,17 +78,17 @@ public boolean isFlammable(IBlockAccess world, int x, int y, int z, ForgeDirecti
@SideOnly(Side.CLIENT)
public void getSubBlocks(Item id, CreativeTabs tab, List list) {
if (group == 1) {
if (id != Item.getItemFromBlock(NContent.plankSlab1Double)) {
for (int iter = 0; iter < 8; iter++) {
list.add(new ItemStack(id, 1, iter));
}
//if (id != Item.getItemFromBlock(NContent.plankSlab1Double)) {
for (int iter = 0; iter < 8; iter++) {
list.add(new ItemStack(id, 1, iter));
}
//}
} else {
if (id != Item.getItemFromBlock(NContent.plankSlab2Double)) {
for (int iter = 0; iter < 5; iter++) {
list.add(new ItemStack(id, 1, iter));
}
//if (id != Item.getItemFromBlock(NContent.plankSlab2Double)) {
for (int iter = 0; iter < 5; iter++) {
list.add(new ItemStack(id, 1, iter));
}
//}
}
}

Expand Down
8 changes: 4 additions & 4 deletions src/main/java/mods/natura/common/NContent.java
Original file line number Diff line number Diff line change
Expand Up @@ -402,18 +402,18 @@ public void preInit() {

// Wooden Slabs
if (PHNatura.enableWoodenSlabs) {
NSlabBase sSlab = (NSlabBase) new NSlabBase(false, 1).setBlockName("plankSlab1");
NSlabBase dslab = (NSlabBase) new NSlabBase(true, 1).setBlockName("plankSlab1Double");
NSlabBase sSlab = (NSlabBase) new NSlabBase(false, 1).setBlockName("plankSlab1");
plankSlab1Double = GameRegistry.registerBlock(dslab, NSlabBaseItem.class, "plankSlab1Double", sSlab, dslab);
plankSlab1 = GameRegistry.registerBlock(sSlab, NSlabBaseItem.class, "plankSlab1", sSlab, dslab);
Blocks.fire.setFireInfo(plankSlab1, 5, 20);
plankSlab1Double = GameRegistry.registerBlock(dslab, NSlabBaseItem.class, "plankSlab1Double", sSlab, dslab);
Blocks.fire.setFireInfo(plankSlab1Double, 5, 20);

sSlab = (NSlabBase) new NSlabBase(false, 2).setBlockName("plankSlab2");
dslab = (NSlabBase) new NSlabBase(true, 2).setBlockName("plankSlab2Double");
sSlab = (NSlabBase) new NSlabBase(false, 2).setBlockName("plankSlab2");
plankSlab2Double = GameRegistry.registerBlock(dslab, NSlabBaseItem.class, "plankSlab2Double", sSlab, dslab);
plankSlab2 = GameRegistry.registerBlock(sSlab, NSlabBaseItem.class, "plankSlab2", sSlab, dslab);
Blocks.fire.setFireInfo(plankSlab2, 5, 20);
plankSlab2Double = GameRegistry.registerBlock(dslab, NSlabBaseItem.class, "plankSlab2Double", sSlab, dslab);
Blocks.fire.setFireInfo(plankSlab2Double, 5, 20);
}

Expand Down

0 comments on commit 10ddb67

Please sign in to comment.