Mercurial > sypikslang
diff gamelib/schematics.py @ 58:52913ba12988
Check for multiple points in can_spend
author | Neil Muller <drnlmuller@gmail.com> |
---|---|
date | Mon, 07 May 2012 23:20:41 +0200 |
parents | 168cfac9a445 |
children | 182fce9f70b6 |
line wrap: on
line diff
--- a/gamelib/schematics.py Mon May 07 23:13:05 2012 +0200 +++ b/gamelib/schematics.py Mon May 07 23:20:41 2012 +0200 @@ -30,8 +30,8 @@ BASE_POWER = None POWER_INCREMENT = None - def can_spend(self, lab): - extra = self.UPGRADE_REQUIREMENT * self.points + 1 + def can_spend(self, lab, spend): + extra = self.UPGRADE_REQUIREMENT * self.points + spend return lab.meet_requirements(self, extra) def is_a(self, category): @@ -62,7 +62,7 @@ def spend_point(self): raise NotImplementedError() - def can_spend(self, lab): + def can_spend(self, lab, spend): return False