Make /lose available for all to use on QA testing

This commit is contained in:
Thanos Paravantis 2016-06-18 21:02:54 +03:00
parent fc50c90301
commit 0b5e409ab8
1 changed files with 16 additions and 20 deletions

View File

@ -200,7 +200,6 @@ public class BawkBawkBattles extends TeamGame implements IThrown
"Last player with lives wins.", "Last player with lives wins.",
}); });
// Damage = false;
DamagePvP = false; DamagePvP = false;
DamagePvE = false; DamagePvE = false;
DamageEvP = false; DamageEvP = false;
@ -394,10 +393,6 @@ public class BawkBawkBattles extends TeamGame implements IThrown
boolean criteria = participants >= minCount && participants <= maxCount; boolean criteria = participants >= minCount && participants <= maxCount;
System.out.println("Participants: " + participants);
System.out.println("Min: " + minCount);
System.out.println("Max: " + maxCount);
if (settings.isTeamBased()) if (settings.isTeamBased())
{ {
return criteria && getPlayersWithRemainingLives() % 2 == 0; return criteria && getPlayersWithRemainingLives() % 2 == 0;
@ -1457,23 +1452,24 @@ public class BawkBawkBattles extends TeamGame implements IThrown
event.setCancelled(true); event.setCancelled(true);
} }
else if (message.startsWith("/" + _loseCommand)) }
{
if (IsLive() && _challenge != null && IsAlive(player))
{
setLives(player, 0);
_challenge.getData().addLostPlayer(player);
_deathEffect.playDeath(player, player.getLocation());
GetScoreboard().ResetScore(player.getName());
_chickenAttack.start(player);
}
else
{
UtilPlayer.message(player, F.main("Game", "You cannot lose at this time."));
}
event.setCancelled(true); if (message.startsWith("/" + _loseCommand))
{
if (IsLive() && _challenge != null && IsAlive(player))
{
setLives(player, 0);
_challenge.getData().addLostPlayer(player);
_deathEffect.playDeath(player, player.getLocation());
GetScoreboard().ResetScore(player.getName());
_chickenAttack.start(player);
} }
else
{
UtilPlayer.message(player, F.main("Game", "You cannot lose at this time."));
}
event.setCancelled(true);
} }
} }