comparison src/parpg/behaviours/npc.py @ 73:58661f5b2f6b

Removed layer as attribute of BaseBehaviour and added it as a parameter to the attachToLayer method.
author KarstenBock@gmx.net
date Wed, 07 Sep 2011 13:54:02 +0200
parents 2915dbb60940
children 47e1345fbac2
comparison
equal deleted inserted replaced
72:9aebbf4e02f7 73:58661f5b2f6b
18 import base 18 import base
19 from base import BaseBehaviour 19 from base import BaseBehaviour
20 20
21 class NPCBehaviour(BaseBehaviour): 21 class NPCBehaviour(BaseBehaviour):
22 """This is a basic NPC behaviour""" 22 """This is a basic NPC behaviour"""
23 def __init__(self, parent=None, layer=None): 23 def __init__(self, parent=None):
24 super(NPCBehaviour, self).__init__(layer) 24 super(NPCBehaviour, self).__init__()
25 25
26 self.parent = parent 26 self.parent = parent
27 self.state = base._AGENT_STATE_NONE 27 self.state = base._AGENT_STATE_NONE
28 self.pc = None 28 self.pc = None
29 self.target_loc = None 29 self.target_loc = None