Whoops. Can't initialize something that doesn't exist.

This commit is contained in:
GJ 2012-05-18 14:40:48 -04:00
parent f3074461ed
commit 7d05d53f9e

View File

@ -41,8 +41,6 @@ import org.getspout.spoutapi.sound.SoundEffect;
public class BlockListener implements Listener {
private final mcMMO plugin;
private static Config configInstance = Config.getInstance();
private static Permissions permInstance = Permissions.getInstance();
public BlockListener(final mcMMO plugin) {
this.plugin = plugin;
@ -95,6 +93,8 @@ public class BlockListener implements Listener {
*/
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
public void onBlockPlace(BlockPlaceEvent event) {
Config configInstance = Config.getInstance();
Block block = event.getBlock();
Player player = event.getPlayer();
int id = block.getTypeId();
@ -136,6 +136,9 @@ public class BlockListener implements Listener {
Block block = event.getBlock();
ItemStack inHand = player.getItemInHand();
Config configInstance = Config.getInstance();
Permissions permInstance = Permissions.getInstance();
if (event instanceof FakeBlockBreakEvent) {
return;
}
@ -225,6 +228,9 @@ public class BlockListener implements Listener {
Block block = event.getBlock();
Material material = block.getType();
Config configInstance = Config.getInstance();
Permissions permInstance = Permissions.getInstance();
/*
* ABILITY PREPARATION CHECKS
*/