Skip to content

Commit

Permalink
remaining turns fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
erfanfi79 committed Feb 12, 2020
1 parent 76a3590 commit d61257d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions world.py
Original file line number Diff line number Diff line change
Expand Up @@ -493,11 +493,11 @@ def _is_unit_targeted(self, unit, spell_target):

# every once in a while you can upgrade, this returns the remaining time for upgrade
def get_remaining_turns_to_upgrade(self):
return self.game_constants.turns_to_upgrade
return self.game_constants.turns_to_upgrade - self.current_turn

# every once in a while a spell is given this remains the remaining time to get new spell
def get_remaining_turns_to_get_spell(self):
return self.game_constants.turns_to_spell
return (self.game_constants.turns_to_spell - self.current_turn) % self.game_constants.turns_to_spell

# returns a list of spells casted on a cell
def get_range_upgrade_number(self, player_id):
Expand Down

0 comments on commit d61257d

Please sign in to comment.