comparison components/fifeagent.py @ 36:a236fff5feea

Added pos value to the FifeAgent component
author KarstenBock@gmx.net
date Mon, 05 Sep 2011 14:44:53 +0200
parents bcabbffc88e6
children ff3e395abf91
comparison
equal deleted inserted replaced
35:895be696ae86 36:a236fff5feea
10 # 10 #
11 # You should have received a copy of the GNU General Public License 11 # You should have received a copy of the GNU General Public License
12 # along with this program. If not, see <http://www.gnu.org/licenses/>. 12 # along with this program. If not, see <http://www.gnu.org/licenses/>.
13 13
14 from parpg.grease.component import Component 14 from parpg.grease.component import Component
15 from grease.geometry import Vec2d
15 16
16 class FifeAgent(Component): 17 class FifeAgent(Component):
17 """Component that stores the values for a fife agent""" 18 """Component that stores the values for a fife agent"""
18 19
19 def __init__(self): 20 def __init__(self):
20 """Constructor""" 21 """Constructor"""
21 Component.__init__(self, identifier=int, layer=object, behaviour=object, gfx=str) 22 Component.__init__(self, identifier=str, layer=object, behaviour=object, gfx=str, pos=Vec2d)
22 23
23 24
24 def setup_behaviour(agent): 25 def setup_behaviour(agent):
25 """Attach the behaviour to the layer""" 26 """Attach the behaviour to the layer"""
26 if agent.behaviour: 27 if agent.behaviour: