Mercurial > parpg-source
changeset 164:ed24962cdf5e
Small fixes.
author | KarstenBock@gmx.net |
---|---|
date | Sat, 19 Nov 2011 19:28:38 +0100 |
parents | 9c82ed72dc9d |
children | 95461b06bac1 |
files | entities/action.py systems/scriptingsystem.py |
diffstat | 2 files changed, 5 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/entities/action.py Sat Nov 19 16:12:56 2011 +0100 +++ b/entities/action.py Sat Nov 19 19:28:38 2011 +0100 @@ -450,11 +450,8 @@ @param commands: Special commands that are executed @type commands: Dictionary """ - self.commands = commands or () - self.controller = controller - self.model = controller.model + Action.__init__(self, controller, commands) self.script = script - self.executed = False def execute(self): self.controller.systems.scripting.runScript(self.script)
--- a/systems/scriptingsystem.py Sat Nov 19 16:12:56 2011 +0100 +++ b/systems/scriptingsystem.py Sat Nov 19 19:28:38 2011 +0100 @@ -52,7 +52,10 @@ self.system.funcs, self.system.vals ) - self.cur_action = action(self.system.world, action_params) + if not (isinstance(action_params, list) + or isinstance(action_params, tuple)): + action_params = [action_params] + self.cur_action = action(self.system.world, *action_params) self.wait = action_data[2] if len(action_data) >= 4: vals = (