Mercurial > parpg-source
comparison charactercreationcontroller.py @ 188:2a12e2843984
Removed bGrease, which is in a seperate repository, here: https://github.com/Beliaar/bGrease
author | Beliar <KarstenBock@gmx.net> |
---|---|
date | Tue, 27 Mar 2012 13:41:20 +0200 |
parents | b3b82c2aebee |
children | 4381be70e1bb |
comparison
equal
deleted
inserted
replaced
187:ab6a0fd1668a | 188:2a12e2843984 |
---|---|
17 | 17 |
18 from parpg import vfs | 18 from parpg import vfs |
19 from controllerbase import ControllerBase | 19 from controllerbase import ControllerBase |
20 from gamescenecontroller import GameSceneController | 20 from gamescenecontroller import GameSceneController |
21 from gamesceneview import GameSceneView | 21 from gamesceneview import GameSceneView |
22 from parpg.world import World | 22 from parpg.world import PARPGWorld |
23 from parpg.entities import General | 23 from parpg.entities import General |
24 from parpg.components import character_statistics | 24 from parpg.components import character_statistics |
25 | 25 |
26 def getStatCost(offset): | 26 def getStatCost(offset): |
27 """Gets and returns the cost to increase stat based on the offset""" | 27 """Gets and returns the cost to increase stat based on the offset""" |
48 elif offset < 41: | 48 elif offset < 41: |
49 return 9 | 49 return 9 |
50 else: | 50 else: |
51 return 10 | 51 return 10 |
52 | 52 |
53 class CharacterCreationController(ControllerBase, World): | 53 class CharacterCreationController(ControllerBase, PARPGWorld): |
54 """Controller defining the behaviour of the character creation screen.""" | 54 """Controller defining the behaviour of the character creation screen.""" |
55 | 55 |
56 #TODO: Change to actual values | 56 #TODO: Change to actual values |
57 MAX_TRAITS = 3 | 57 MAX_TRAITS = 3 |
58 MIN_AGE = 16 | 58 MIN_AGE = 16 |
75 @param application: Application used to glue the various MVC | 75 @param application: Application used to glue the various MVC |
76 components together. | 76 components together. |
77 @type application: | 77 @type application: |
78 L{fife.extensions.basicapplication.ApplicationBase}""" | 78 L{fife.extensions.basicapplication.ApplicationBase}""" |
79 ControllerBase.__init__(self, engine, view, model, application) | 79 ControllerBase.__init__(self, engine, view, model, application) |
80 World.__init__(self) | 80 PARPGWorld.__init__(self) |
81 self.settings = self.model.settings | 81 self.settings = self.model.settings |
82 self.view.start_new_game_callback = self.startNewGame | 82 self.view.start_new_game_callback = self.startNewGame |
83 self.view.cancel_new_game_callback = self.cancelNewGame | 83 self.view.cancel_new_game_callback = self.cancelNewGame |
84 | 84 |
85 def reset_character(self): | 85 def reset_character(self): |