ex.43 classes
This commit is contained in:
parent
366d216035
commit
53232c9869
2 changed files with 181 additions and 0 deletions
66
sami/learn-python-the-hard-way/ex43_classes.py
Normal file
66
sami/learn-python-the-hard-way/ex43_classes.py
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
|
||||
class Scene(object):
|
||||
|
||||
def enter(self):
|
||||
pass
|
||||
|
||||
|
||||
|
||||
class Engine(object):
|
||||
|
||||
def __init__(self, scene_map):
|
||||
pass
|
||||
|
||||
def play(self):
|
||||
pass
|
||||
|
||||
|
||||
class Death(Scene):
|
||||
|
||||
def enter(self):
|
||||
pass
|
||||
|
||||
|
||||
class CentralCorridor(Scene):
|
||||
|
||||
def enter(self):
|
||||
pass
|
||||
|
||||
|
||||
class LaserWeaponArmory(Scene):
|
||||
|
||||
def enter(self):
|
||||
pass
|
||||
|
||||
|
||||
class TheBridge(Scene):
|
||||
|
||||
def enter(self):
|
||||
pass
|
||||
|
||||
|
||||
class EscapePod(Scene):
|
||||
|
||||
def enter(self)
|
||||
pass
|
||||
|
||||
|
||||
|
||||
class Map(object):
|
||||
|
||||
|
||||
|
||||
def __init__(self, start_scene):
|
||||
pass
|
||||
|
||||
|
||||
def next_scene(self, scene_name):
|
||||
pass
|
||||
|
||||
def opening_scene(self):
|
||||
pass
|
||||
|
||||
|
||||
a_map = Map('central_corridor')
|
||||
a_game = Engine(a_map)
|
||||
a_game.play()
|
||||
Loading…
Add table
Add a link
Reference in a new issue