This commit is contained in:
iie 2017-05-31 01:10:00 +02:00 committed by
parent d5edd0cfe6
commit 442c32f17b

View file

@ -108,35 +108,41 @@ public class Main extends JavaPlugin
westHeadMaterial = world.getBlockAt( westX , westY +1 , z ).getType(); westHeadMaterial = world.getBlockAt( westX , westY +1 , z ).getType();
//CONFIRM THAT ALL FIVE POSITIONS ARE ON SOLID GROUND WITH AIR AT HEAD HEIGHT //CONFIRM THAT ALL FIVE POSITIONS ARE ON SOLID GROUND WITH AIR AT HEAD HEIGHT
if (centerHeadMaterial == Material.AIR && if (centerHeadMaterial .equals(Material.AIR) &&
northHeadMaterial == Material.AIR && northHeadMaterial .equals(Material.AIR) &&
southHeadMaterial == Material.AIR && southHeadMaterial .equals(Material.AIR) &&
eastHeadMaterial == Material.AIR && eastHeadMaterial .equals(Material.AIR) &&
westHeadMaterial == Material.AIR && westHeadMaterial .equals(Material.AIR) &&
centerGroundMaterial != Material.STATIONARY_WATER && !centerGroundMaterial.equals(Material.STATIONARY_WATER) &&
northGroundMaterial != Material.STATIONARY_WATER && !northGroundMaterial .equals(Material.STATIONARY_WATER) &&
southGroundMaterial != Material.STATIONARY_WATER && !southGroundMaterial .equals(Material.STATIONARY_WATER) &&
eastGroundMaterial != Material.STATIONARY_WATER && !eastGroundMaterial .equals(Material.STATIONARY_WATER) &&
westGroundMaterial != Material.STATIONARY_WATER && !westGroundMaterial .equals(Material.STATIONARY_WATER) &&
centerGroundMaterial != Material.WATER && !centerGroundMaterial.equals(Material.WATER) &&
northGroundMaterial != Material.WATER && !northGroundMaterial .equals(Material.WATER) &&
southGroundMaterial != Material.WATER && !southGroundMaterial .equals(Material.WATER) &&
eastGroundMaterial != Material.WATER && !eastGroundMaterial .equals(Material.WATER) &&
westGroundMaterial != Material.WATER && !westGroundMaterial .equals(Material.WATER) &&
centerGroundMaterial != Material.STATIONARY_LAVA && !centerGroundMaterial.equals(Material.STATIONARY_LAVA) &&
northGroundMaterial != Material.STATIONARY_LAVA && !northGroundMaterial .equals(Material.STATIONARY_LAVA) &&
southGroundMaterial != Material.STATIONARY_LAVA && !southGroundMaterial .equals(Material.STATIONARY_LAVA) &&
eastGroundMaterial != Material.STATIONARY_LAVA && !eastGroundMaterial .equals(Material.STATIONARY_LAVA) &&
westGroundMaterial != Material.STATIONARY_LAVA && !westGroundMaterial .equals(Material.STATIONARY_LAVA) &&
centerGroundMaterial != Material.LAVA && !centerGroundMaterial.equals(Material.LAVA) &&
northGroundMaterial != Material.LAVA && !northGroundMaterial .equals(Material.LAVA) &&
southGroundMaterial != Material.LAVA && !southGroundMaterial .equals(Material.LAVA) &&
eastGroundMaterial != Material.LAVA && !eastGroundMaterial .equals(Material.LAVA) &&
westGroundMaterial != Material.LAVA) !westGroundMaterial .equals(Material.LAVA) &&
!centerGroundMaterial.equals(Material.AIR) &&
!northGroundMaterial .equals(Material.AIR) &&
!southGroundMaterial .equals(Material.AIR) &&
!eastGroundMaterial .equals(Material.AIR) &&
!westGroundMaterial .equals(Material.AIR))
{ {
//IF LOCATION VALID, SET NEW POSITIONS AND RESET TRACKING VARIABLES //IF LOCATION VALID, SET NEW POSITIONS AND RESET TRACKING VARIABLES
center = world.getBlockAt( x , centerY , z ).getLocation(); center = world.getBlockAt( x , centerY , z ).getLocation();