2015-11-27 15:34:19 +01:00
|
|
|
package com.gamingmesh.jobs.nmsUtil;
|
|
|
|
|
|
|
|
import java.util.ArrayList;
|
|
|
|
import java.util.List;
|
|
|
|
import org.bukkit.block.Block;
|
|
|
|
import org.bukkit.entity.Entity;
|
2016-03-30 15:42:36 +02:00
|
|
|
import org.bukkit.entity.Player;
|
2015-11-27 15:34:19 +01:00
|
|
|
import org.bukkit.event.block.BlockPistonRetractEvent;
|
2016-03-30 15:42:36 +02:00
|
|
|
import org.bukkit.inventory.ItemStack;
|
2015-11-27 15:34:19 +01:00
|
|
|
|
|
|
|
import com.gamingmesh.jobs.NMS;
|
|
|
|
|
|
|
|
public class v1_7 implements NMS {
|
|
|
|
@Override
|
|
|
|
public List<Block> getPistonRetractBlocks(BlockPistonRetractEvent event) {
|
|
|
|
List<Block> blocks = new ArrayList<Block>();
|
|
|
|
blocks.add(event.getBlock());
|
|
|
|
return blocks;
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
|
|
public boolean isElderGuardian(Entity entity) {
|
|
|
|
return false;
|
|
|
|
}
|
2016-03-30 15:42:36 +02:00
|
|
|
|
|
|
|
@SuppressWarnings("deprecation")
|
|
|
|
@Override
|
|
|
|
public ItemStack getItemInMainHand(Player player) {
|
|
|
|
return player.getInventory().getItemInHand();
|
|
|
|
}
|
2015-11-27 15:34:19 +01:00
|
|
|
}
|