Browse Source

added getEntityTypes

Darren Ranalli 22 years ago
parent
commit
c617e83e9b
1 changed files with 5 additions and 0 deletions
  1. 5 0
      direct/src/level/EntityCreatorBase.py

+ 5 - 0
direct/src/level/EntityCreatorBase.py

@@ -22,6 +22,11 @@ class EntityCreatorBase:
         # inheritor must define doCreateEntity
         return self.doCreateEntity(self.entType2Ctor[entType], entId)
 
+    def getEntityTypes(self):
+        """by definition, this object knows the full list of entity types
+        that may exist within the level"""
+        return self.entType2Ctor.keys()
+
     def privRegisterType(self, entType, ctor):
         if self.entType2Ctor.has_key(entType):
             self.notify.warning('replacing %s ctor %s with %s' %