Fixed some stats being added after send-off
This commit is contained in:
parent
0546c9e175
commit
7e7906865f
@ -1102,8 +1102,6 @@ public abstract class Game implements Listener
|
|||||||
past = _stats.get(player).get(stat);
|
past = _stats.get(player).get(stat);
|
||||||
|
|
||||||
_stats.get(player).put(stat, limitTo1 ? Math.min(1, past + amount) : past + amount);
|
_stats.get(player).put(stat, limitTo1 ? Math.min(1, past + amount) : past + amount);
|
||||||
|
|
||||||
System.out.println("Game Queued Stat: " + stat + " [" + amount + "]");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public abstract List<Player> getWinners();
|
public abstract List<Player> getWinners();
|
||||||
|
@ -127,9 +127,6 @@ public abstract class SoloGame extends Game
|
|||||||
@Override
|
@Override
|
||||||
public List<Player> getWinners()
|
public List<Player> getWinners()
|
||||||
{
|
{
|
||||||
if (!IsLive())
|
|
||||||
return null;
|
|
||||||
|
|
||||||
if (GetPlayers(true).size() <= 1)
|
if (GetPlayers(true).size() <= 1)
|
||||||
{
|
{
|
||||||
List<Player> places = _players.GetPlacements(true);
|
List<Player> places = _players.GetPlacements(true);
|
||||||
|
@ -274,7 +274,7 @@ public class GameManager implements Listener
|
|||||||
@EventHandler
|
@EventHandler
|
||||||
public void StatRegister(GameStateChangeEvent event)
|
public void StatRegister(GameStateChangeEvent event)
|
||||||
{
|
{
|
||||||
if (event.GetState() != GameState.End)
|
if (event.GetState() != GameState.Dead)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
for (Player player : event.GetGame().GetStats().keySet())
|
for (Player player : event.GetGame().GetStats().keySet())
|
||||||
|
Loading…
Reference in New Issue
Block a user