Definitely fixed sideways logs issues

... Apparently
This commit is contained in:
bm01 2013-01-24 15:28:18 +01:00
parent 5a6dc8511f
commit 58b01021c1
2 changed files with 4 additions and 2 deletions

View File

@ -10,6 +10,7 @@ import org.bukkit.block.Block;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.event.block.BlockBreakEvent; import org.bukkit.event.block.BlockBreakEvent;
import org.bukkit.inventory.ItemStack; import org.bukkit.inventory.ItemStack;
import org.bukkit.material.MaterialData;
import com.gmail.nossr50.mcMMO; import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.datatypes.mods.CustomBlock; 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 // 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; break;
case LEAVES: case LEAVES:
Misc.randomDropItem(block.getLocation(), new ItemStack(Material.SAPLING, 1, Woodcutting.extractLogItemData(block.getData())), 10); Misc.randomDropItem(block.getLocation(), new ItemStack(Material.SAPLING, 1, Woodcutting.extractLogItemData(block.getData())), 10);

View File

@ -7,6 +7,7 @@ import org.bukkit.block.Block;
import org.bukkit.entity.Player; import org.bukkit.entity.Player;
import org.bukkit.event.block.BlockBreakEvent; import org.bukkit.event.block.BlockBreakEvent;
import org.bukkit.inventory.ItemStack; import org.bukkit.inventory.ItemStack;
import org.bukkit.material.MaterialData;
import org.getspout.spoutapi.sound.SoundEffect; import org.getspout.spoutapi.sound.SoundEffect;
import com.gmail.nossr50.mcMMO; import com.gmail.nossr50.mcMMO;
@ -145,7 +146,7 @@ public abstract class Woodcutting {
else { else {
byte blockData = block.getData(); byte blockData = block.getData();
Location location = block.getLocation(); 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))) { switch (TreeSpecies.getByData(extractLogItemData(blockData))) {
case GENERIC: case GENERIC: