Skip to content

Commit

Permalink
Add loser fields in provided match classes; bump version number
Browse files Browse the repository at this point in the history
  • Loading branch information
happy5214 committed Jan 16, 2016
1 parent 2c2c8a3 commit 2be9291
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions competitions/match/default/SimpleMatch.py
Expand Up @@ -93,10 +93,13 @@ def play(self):
score2 += 1
if score1 > score2:
self.winner = self.team1
self.loser = self.team2
elif score2 > score1:
self.winner = self.team2
self.loser = self.team1
else:
self.winner = None
self.loser = None
self.score1 = score1
self.score2 = score2
return self.winner
1 change: 1 addition & 0 deletions competitions/match/default/TestMatch.py
Expand Up @@ -78,4 +78,5 @@ def play(self):
self.score1 = 5
self.score2 = 0
self.winner = self.team1
self.loser = self.team2
return self.winner
2 changes: 1 addition & 1 deletion setup.py
Expand Up @@ -13,7 +13,7 @@

setup(
name='competitions-match',
version='0.1.2',
version='0.1.3',

description='competitions support library for matches',
long_description=long_description,
Expand Down

0 comments on commit 2be9291

Please sign in to comment.