From bd1735a9ecaca0a5f3640036f460496e67e322d6 Mon Sep 17 00:00:00 2001 From: Darren Ranalli Date: Fri, 11 Nov 2005 23:24:40 +0000 Subject: [PATCH] added static versions of getZoneChangeEvent and getLogicalZoneChangeEvent --- direct/src/distributed/DistributedObjectAI.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/direct/src/distributed/DistributedObjectAI.py b/direct/src/distributed/DistributedObjectAI.py index ad023661f7..c3235eb961 100644 --- a/direct/src/distributed/DistributedObjectAI.py +++ b/direct/src/distributed/DistributedObjectAI.py @@ -249,13 +249,20 @@ class DistributedObjectAI(DirectObject): # this event is generated whenever this object changes zones. # arguments are newZoneId, oldZoneId # includes the quiet zone. - return 'DOChangeZone-%s' % self.doId + return DistributedObjectAI.staticGetZoneChangeEvent(self.doId) def getLogicalZoneChangeEvent(self): # this event is generated whenever this object changes to a # non-quiet-zone zone. # arguments are newZoneId, oldZoneId # does not include the quiet zone. - return 'DOLogicalChangeZone-%s' % self.doId + return DistributedObjectAI.staticGetLogicalZoneChangeEvent(self.doId) + + @staticmethod + def staticGetZoneChangeEvent(doId): + return 'DOChangeZone-%s' % doId + @staticmethod + def staticGetLogicalZoneChangeEvent(doId): + return 'DOLogicalChangeZone-%s' % doId def handleLogicalZoneChange(self, newZoneId, oldZoneId): """this function gets called as if we never go through the