Mercurial > parpg-source
diff components/fifeagent.py @ 160:75c0b728ccf3
Further work on the scripting system.
author | KarstenBock@gmx.net |
---|---|
date | Sun, 13 Nov 2011 17:19:14 +0100 |
parents | f94d4577ca5e |
children |
line wrap: on
line diff
--- a/components/fifeagent.py Sun Nov 13 13:37:24 2011 +0100 +++ b/components/fifeagent.py Sun Nov 13 17:19:14 2011 +0100 @@ -34,4 +34,10 @@ def setup_behaviour(agent): """Attach the behaviour to the layer""" if agent.behaviour: - agent.behaviour.attachToLayer(agent.entity.getID(), agent.layer) \ No newline at end of file + agent.behaviour.attachToLayer(agent.entity.getID(), agent.layer) + +def approach(agent, target_or_location, action): + if agent.behaviour: + agent.behaviour.approach(target_or_location, action) + +commands = {"approach":approach} \ No newline at end of file