mirror of
https://github.com/bloodmc/GriefDefender.git
synced 2024-11-12 10:44:42 +01:00
Fix investigation tool.
* Fix NPE during entity move.
This commit is contained in:
parent
557f09a4de
commit
3f430645e4
@ -331,9 +331,11 @@ public boolean onEntityMove(MoveEntityEvent event, Location<World> fromLocation,
|
||||
user.getInternalPlayerData().inTown = false;
|
||||
}
|
||||
|
||||
if (player != null) {
|
||||
checkPlayerFlight(player, user.getInternalPlayerData(), fromClaim, toClaim);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
GDTimings.ENTITY_MOVE_EVENT.stopTimingIfSync();
|
||||
return true;
|
||||
|
@ -980,13 +980,12 @@ private void onPlayerHandleClaimCreateAction(InteractEvent event, BlockSnapshot
|
||||
return;
|
||||
}
|
||||
|
||||
/*if (!playerData.claimMode) {
|
||||
if (!playerData.claimMode) {
|
||||
GriefDefenderConfig<?> activeConfig = GriefDefenderPlugin.getActiveConfig(player.getWorld().getProperties());
|
||||
ItemType materialInHand = player.getItemInHand(handType).get().getType();
|
||||
if (!materialInHand.getId().equals(activeConfig.getConfig().claim.modificationTool)) {
|
||||
if (!itemInHand.getType().getId().equals(activeConfig.getConfig().claim.modificationTool)) {
|
||||
return;
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
GDTimings.PLAYER_HANDLE_SHOVEL_ACTION.startTimingIfSync();
|
||||
BlockSnapshot clickedBlock = targetBlock;
|
||||
|
Loading…
Reference in New Issue
Block a user