Battle improvements (MP system, cure)

This commit is contained in:
Daniel Odendahl Jr
2018-10-10 14:56:04 +00:00
parent 7c9bf3842d
commit b52f698498
4 changed files with 42 additions and 9 deletions
+3 -1
View File
@@ -5,6 +5,7 @@ module.exports = class Battle {
this.user = new Battler(this, user);
this.opponent = new Battler(this, opponent);
this.userTurn = false;
this.turn = 1;
}
get attacker() {
@@ -19,7 +20,8 @@ module.exports = class Battle {
if (changeGuard && this.user.guard) this.user.changeGuard();
if (changeGuard && this.opponent.guard) this.opponent.changeGuard();
this.userTurn = !this.userTurn;
return null;
this.turn++;
return this.turn;
}
get winner() {