Prevent game countdown if there is only one player, fix typo on Dog vs Cat challenge.
This commit is contained in:
parent
d38276d23d
commit
51c572bf44
@ -146,6 +146,20 @@ public class MineWare extends SoloGame implements IThrown
|
||||
new MinewarePinataMasterTracker(this), new MinewareTagMasterTracker(this),
|
||||
new MinewareKangarooAtHeart(this));
|
||||
}
|
||||
|
||||
@EventHandler
|
||||
public void onUpdate(UpdateEvent event)
|
||||
{
|
||||
if (event.getType() != UpdateType.FASTEST)
|
||||
return;
|
||||
|
||||
if (GetState() == GameState.Recruit && GetCountdown() >= 0 && GetPlayers(false).size() < 2)
|
||||
{
|
||||
UtilServer.broadcast(F.main("MineWare", C.cRed + "This game requires at least 2 players to start."));
|
||||
SetCountdown(-1);
|
||||
Manager.GetLobby().DisplayWaiting();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void EndCheck()
|
||||
@ -188,7 +202,7 @@ public class MineWare extends SoloGame implements IThrown
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
_challengeTime = System.currentTimeMillis();
|
||||
}
|
||||
|
||||
|
@ -44,7 +44,7 @@ public class ChallengeDogvsCat extends Challenge
|
||||
|
||||
public ChallengeDogvsCat(MineWare host)
|
||||
{
|
||||
super(host, ChallengeType.FirstComplete, "Dogs VS Cats", "If you are a dog, bark.", "If you are a dog, meow.", "Look up to bark or meow.", "First team to the end number wins!");
|
||||
super(host, ChallengeType.FirstComplete, "Dogs VS Cats", "If you are a dog, bark.", "If you are a cat, meow.", "Look up and punch to bark or meow.", "First team to the end number wins!");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
Loading…
Reference in New Issue
Block a user