comparison demos/rpg/scripts/gamecontroller.py @ 510:cd959b05a262

There is now a main menu. You can also view the credits. Taking a screenshot and opening the console should also work.
author prock@33b003aa-7bff-0310-803a-e67f0ece8222
date Thu, 20 May 2010 21:12:23 +0000
parents 3951042a701e
children 6ddb1eb9dfa6
comparison
equal deleted inserted replaced
509:3951042a701e 510:cd959b05a262
26 26
27 import sys, os, re, math, random, shutil 27 import sys, os, re, math, random, shutil
28 28
29 from fife import fife 29 from fife import fife
30 30
31 from scripts.guicontroller import GUIController
32
31 class GameController(object): 33 class GameController(object):
32 def __init__(self, application, engine, settings): 34 def __init__(self, application, engine, settings):
33 self._application = application 35 self._application = application
34 self._engine = engine 36 self._engine = engine
35 self._settings = settings 37 self._settings = settings
36 38
39 self._guicontroller = GUIController(self, self._engine, self._settings)
40
41 self._guicontroller.showMainMenu()
42
43 def onConsoleCommand(self, command):
44 """
45 Might be useful if you want to have the game parse a command
46 """
47 result = ""
48 return result
49
50 def newGame(self):
51 pass
52
53 def quit(self):
54 self._application.requestQuit()
55
37 def pump(self): 56 def pump(self):
38 pass 57 pass