Mercurial > parpg-source
comparison components/fifeagent.py @ 28:bcabbffc88e6
Move setup_behaviour method of the Character entity to a function in fifeagent.py
author | KarstenBock@gmx.net |
---|---|
date | Sun, 04 Sep 2011 16:25:23 +0200 |
parents | def430d59281 |
children | a236fff5feea |
comparison
equal
deleted
inserted
replaced
27:59a4337f328f | 28:bcabbffc88e6 |
---|---|
17 """Component that stores the values for a fife agent""" | 17 """Component that stores the values for a fife agent""" |
18 | 18 |
19 def __init__(self): | 19 def __init__(self): |
20 """Constructor""" | 20 """Constructor""" |
21 Component.__init__(self, identifier=int, layer=object, behaviour=object, gfx=str) | 21 Component.__init__(self, identifier=int, layer=object, behaviour=object, gfx=str) |
22 | |
23 | |
24 def setup_behaviour(agent): | |
25 """Attach the behaviour to the layer""" | |
26 if agent.behaviour: | |
27 agent.behaviour.attachToLayer(agent.identifier) |