Mercurial > parpg-source
comparison world.py @ 51:d3a9caba067b
Modifications to make talking with npcs possible again. Special actions won't work yet though.
author | KarstenBock@gmx.net |
---|---|
date | Thu, 08 Sep 2011 15:18:39 +0200 |
parents | 4f9747116061 |
children | e2004c9549d7 |
comparison
equal
deleted
inserted
replaced
50:b4a525456c99 | 51:d3a9caba067b |
---|---|
1 from bGrease.world import * | 1 from bGrease.world import * |
2 from bGrease.component import Component | |
2 | 3 |
3 from parpg.mode import FifeMode | 4 from parpg.mode import FifeMode |
4 from parpg import components | 5 from parpg import components |
5 | 6 |
6 class World(FifeMode, BaseWorld): | 7 class World(FifeMode, BaseWorld): |
17 self.components.description = components.Description() | 18 self.components.description = components.Description() |
18 self.components.dialogue = components.Dialogue() | 19 self.components.dialogue = components.Dialogue() |
19 self.components.fifeagent = components.FifeAgent() | 20 self.components.fifeagent = components.FifeAgent() |
20 self.components.lockable = components.Lockable() | 21 self.components.lockable = components.Lockable() |
21 self.components.usable = components.Usable() | 22 self.components.usable = components.Usable() |
23 | |
24 #WORKAROUND: To get rid of exception in gamescenecontroller | |
25 self.components.change_map = Component() | |
22 | 26 |
23 def pump(self, dt): | 27 def pump(self, dt): |
24 for component in self.components: | 28 for component in self.components: |
25 if hasattr(component, "step"): | 29 if hasattr(component, "step"): |
26 component.step(dt) | 30 component.step(dt) |