bridges volcano fix

minestrike npe fix
This commit is contained in:
Chiss 2014-09-05 21:35:26 +10:00
parent 4e94bcfd98
commit 4064c5238c
2 changed files with 5 additions and 3 deletions

View File

@ -41,8 +41,10 @@ import mineplex.core.common.util.C;
import mineplex.core.common.util.F; import mineplex.core.common.util.F;
import mineplex.core.common.util.UtilBlock; import mineplex.core.common.util.UtilBlock;
import mineplex.core.common.util.UtilEvent; import mineplex.core.common.util.UtilEvent;
import mineplex.core.common.util.UtilParticle;
import mineplex.core.common.util.UtilWorld; import mineplex.core.common.util.UtilWorld;
import mineplex.core.common.util.UtilEvent.ActionType; import mineplex.core.common.util.UtilEvent.ActionType;
import mineplex.core.common.util.UtilParticle.ParticleType;
import mineplex.core.common.util.UtilMath; import mineplex.core.common.util.UtilMath;
import mineplex.core.common.util.UtilPlayer; import mineplex.core.common.util.UtilPlayer;
import mineplex.core.common.util.UtilTime; import mineplex.core.common.util.UtilTime;
@ -77,7 +79,7 @@ public class Bridge extends TeamGame implements OreObsfucation
private static final Material[] PLAYER_DROP_DELAY_MATERIALS = new Material[] { Material.LOG, Material.LOG_2, Material.IRON_ORE, Material.DIAMOND_ORE, Material.COAL_ORE, Material.GOLD_ORE, Material.WORKBENCH, Material.FURNACE }; private static final Material[] PLAYER_DROP_DELAY_MATERIALS = new Material[] { Material.LOG, Material.LOG_2, Material.IRON_ORE, Material.DIAMOND_ORE, Material.COAL_ORE, Material.GOLD_ORE, Material.WORKBENCH, Material.FURNACE };
//Bridge Timer //Bridge Timer
private int _bridgeTime = 600000; private int _bridgeTime = 5000; //600000
private boolean _bridgesDown = false; private boolean _bridgesDown = false;
//Wood Bridge //Wood Bridge
@ -732,7 +734,7 @@ public class Bridge extends TeamGame implements OreObsfucation
// Create Part // Create Part
FallingBlock block = bestLoc.getWorld().spawnFallingBlock( FallingBlock block = bestLoc.getWorld().spawnFallingBlock(
source, 10, (byte) 0); source, 87, (byte) 0);
BridgePart part = new BridgePart(block, bestLoc, true); BridgePart part = new BridgePart(block, bestLoc, true);
_bridgeParts.add(part); _bridgeParts.add(part);

View File

@ -1997,7 +1997,7 @@ public class MineStrike extends TeamGame
continue; continue;
Gun gun = getGunInHand(player, null); Gun gun = getGunInHand(player, null);
if (!gun.hasScope() || !player.isSneaking()) if (gun == null || !gun.hasScope() || !player.isSneaking())
{ {
removeScope(player); removeScope(player);
} }