fixed cases where negative stats were being uploaded

This commit is contained in:
Mini-Chiss 2015-08-05 08:56:52 +02:00
parent 88fe5b3ec6
commit 5d7cc59909
2 changed files with 5 additions and 1 deletions

View File

@ -68,6 +68,10 @@ public class GameStatManager implements Listener
for (String stat : event.GetGame().GetStats().get(player).keySet())
{
int value = event.GetGame().GetStats().get(player).get(stat);
if (value <= 0)
continue;
Manager.GetStatsManager().incrementStat(player, stat, value);
// Leaderboard hook for logging appropriate stat events

View File

@ -42,7 +42,7 @@ public class ExperienceStatTracker extends StatTracker<Game>
if (!event.GetGame().Manager.IsRewardStats() || !event.GetGame().Manager.IsRewardAchievements())
return;
if (_startTime == -1)
if (_startTime <= 0)
return;
if (event.GetState() == Game.GameState.End)