From 58b01021c162b3e56e9ca6cb12bf24a93ef9f9bc Mon Sep 17 00:00:00 2001 From: bm01 Date: Thu, 24 Jan 2013 15:28:18 +0100 Subject: [PATCH] Definitely fixed sideways logs issues ... Apparently --- .../java/com/gmail/nossr50/skills/woodcutting/TreeFeller.java | 3 ++- .../java/com/gmail/nossr50/skills/woodcutting/Woodcutting.java | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/com/gmail/nossr50/skills/woodcutting/TreeFeller.java b/src/main/java/com/gmail/nossr50/skills/woodcutting/TreeFeller.java index 6cfed6d21..4790fba8c 100644 --- a/src/main/java/com/gmail/nossr50/skills/woodcutting/TreeFeller.java +++ b/src/main/java/com/gmail/nossr50/skills/woodcutting/TreeFeller.java @@ -10,6 +10,7 @@ import org.bukkit.block.Block; import org.bukkit.entity.Player; import org.bukkit.event.block.BlockBreakEvent; import org.bukkit.inventory.ItemStack; +import org.bukkit.material.MaterialData; import com.gmail.nossr50.mcMMO; import com.gmail.nossr50.datatypes.mods.CustomBlock; @@ -184,7 +185,7 @@ public abstract class TreeFeller { // TODO: Nerf XP from jungle trees, as it was done previously - Misc.dropItem(block.getLocation(), new ItemStack(Material.LOG, 1, Woodcutting.extractLogItemData(block.getData()))); + Misc.dropItem(block.getLocation(), new MaterialData(Material.LOG, Woodcutting.extractLogItemData(block.getData())).toItemStack(1)); break; case LEAVES: Misc.randomDropItem(block.getLocation(), new ItemStack(Material.SAPLING, 1, Woodcutting.extractLogItemData(block.getData())), 10); diff --git a/src/main/java/com/gmail/nossr50/skills/woodcutting/Woodcutting.java b/src/main/java/com/gmail/nossr50/skills/woodcutting/Woodcutting.java index b93c59bad..ac2546d86 100644 --- a/src/main/java/com/gmail/nossr50/skills/woodcutting/Woodcutting.java +++ b/src/main/java/com/gmail/nossr50/skills/woodcutting/Woodcutting.java @@ -7,6 +7,7 @@ import org.bukkit.block.Block; import org.bukkit.entity.Player; import org.bukkit.event.block.BlockBreakEvent; import org.bukkit.inventory.ItemStack; +import org.bukkit.material.MaterialData; import org.getspout.spoutapi.sound.SoundEffect; import com.gmail.nossr50.mcMMO; @@ -145,7 +146,7 @@ public abstract class Woodcutting { else { byte blockData = block.getData(); Location location = block.getLocation(); - ItemStack item = new ItemStack(Material.LOG, 1, blockData); + ItemStack item = new MaterialData(Material.LOG, Woodcutting.extractLogItemData(block.getData())).toItemStack(1); switch (TreeSpecies.getByData(extractLogItemData(blockData))) { case GENERIC: