Skip to content

Commit

Permalink
Fixed a bug with the battle timer not cancelling
Browse files Browse the repository at this point in the history
If the Pokémon were evolving in an online battle, the timer would
continue until the battle finished.
  • Loading branch information
varkor committed Apr 22, 2016
1 parent f0480c1 commit 183d808
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions battle/scripts/objects/unique/Supervisor.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ let Supervisor = {
teamB.type = data.data.teamB.type;
var callback = function (flags, trainers) {
Supervisor.countdown(identifier, true);
var timer = Supervisor.processes[identifier].timer;
data.callback(flags, trainers, Supervisor.record(identifier));
battle.destroy();
delete Supervisor.processes[identifier];
Expand Down Expand Up @@ -261,7 +260,7 @@ let Supervisor = {
foreach(process.parties, function (party) {
Supervisor.send(party, "actions", actionsToSend, identifier);
});
Supervisor.countdown(identifier);
Supervisor.countdown(identifier, process.battle.finished);
process.relayed = process.relay.length;
}
} else {
Expand Down

0 comments on commit 183d808

Please sign in to comment.