Implement team check on challenge selection system
This commit is contained in:
parent
11aef273ba
commit
cb4561c561
@ -307,8 +307,14 @@ public class BawkBawkBattles extends TeamGame implements IThrown
|
||||
int minCount = settings.getMinPlayers();
|
||||
int maxCount = settings.getMaxPlayers();
|
||||
|
||||
// TODO: Add player team size check.
|
||||
return participants >= minCount && participants <= maxCount;
|
||||
boolean criteria = participants >= minCount && participants <= maxCount;
|
||||
|
||||
if (settings.isTeamBased())
|
||||
{
|
||||
return criteria && getPlayersWithRemainingLives() % 2 == 0;
|
||||
}
|
||||
|
||||
return criteria;
|
||||
}
|
||||
|
||||
private Challenge getChallengeInstance()
|
||||
|
@ -94,6 +94,7 @@ public abstract class Challenge implements Listener
|
||||
*/
|
||||
public void onStart()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@ -101,6 +102,7 @@ public abstract class Challenge implements Listener
|
||||
*/
|
||||
public void onEnd()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user