Mercurial > parpg-source
diff gamemodel.py @ 167:b3b82c2aebee
Using fife settings module again instead of our own.
author | Beliar <KarstenBock@gmx.net> |
---|---|
date | Mon, 20 Feb 2012 16:50:10 +0100 |
parents | d224bbce512a |
children | 0296f5f74a0f |
line wrap: on
line diff
--- a/gamemodel.py Thu Jan 12 18:42:48 2012 +0100 +++ b/gamemodel.py Mon Feb 20 16:50:10 2012 +0100 @@ -68,7 +68,7 @@ self.map_change = False self.load_saver = False self.savegame = None - quests_directory = settings.parpg.QuestsPath + quests_directory = settings.get("parpg", "QuestsPath") self.game_state = GameState(quests_dir=quests_directory) #self.game_state.quest_engine = #self.game_state.quest_engine.readQuests() @@ -85,16 +85,16 @@ self.fife_model = engine.getModel() # set values from settings - maps_directory = settings.parpg.MapsPath + maps_directory = settings.get("parpg", "MapsPath") self.game_state.maps_file = '/'.join([maps_directory, - settings.parpg.MapsFile]) + settings.get("parpg", "MapsFile")]) self.all_agents_file = '/'.join([maps_directory, - settings.parpg.AllAgentsFile]) - objects_directory = self.settings.parpg.ObjectsPath + settings.get("parpg", "AllAgentsFile")]) + objects_directory = self.settings.get("parpg", "ObjectsPath") self.objects_directory = objects_directory self.object_db_file = '/'.join([objects_directory, - settings.parpg.ObjectDatabaseFile]) - self.dialogue_directory = settings.parpg.DialoguesPath + settings.get("parpg", "ObjectDatabaseFile")]) + self.dialogue_directory = settings.get("parpg", "DialoguesPath") self.dialogues = {} self.agent_import_files = {} self.obj_loader = XMLObjectLoader(self.engine) @@ -703,7 +703,7 @@ if obj.fifeagent.behaviour: obj.fifeagent.behaviour.parent = obj fifeagent.setup_behaviour(obj.fifeagent) - obj.fifeagent.behaviour.speed = self.settings.parpg.PCSpeed + obj.fifeagent.behaviour.speed = self.settings.get("parpg", "PCSpeed") #Start the behaviour obj.fifeagent.behaviour.idle() # create the agent