diff behaviours/npc.py @ 48:1bdadb768bcf

Added approach functionality to the BaseBehaviour
author KarstenBock@gmx.net
date Thu, 08 Sep 2011 14:20:31 +0200
parents dd9bd93ec81c
children 8b1ad2d342d8
line wrap: on
line diff
--- a/behaviours/npc.py	Wed Sep 07 14:48:08 2011 +0200
+++ b/behaviours/npc.py	Thu Sep 08 14:20:31 2011 +0200
@@ -66,14 +66,13 @@
         """What the NPC does when it has finished an action.
            Called by the engine and required for InstanceActionListeners.
            @type instance: fife.Instance
-           @param instance: self.agent (the NPC listener is listening for this
-                                        instance)
+           @param instance: self.agent
            @type action: ???
            @param action: ???
            @return: None"""
         if self.state == base._AGENT_STATE_WANDER:
             self.target_loc = self.getTargetLocation()
-        self.idle()
+        BaseBehaviour.onInstanceActionFinished(self, instance, action)
         
     
     def idle(self):