level: edits for python 3 support
This commit is contained in:
parent
b2d956d1a4
commit
a47d4ccd0e
4 changed files with 30 additions and 30 deletions
|
@ -19,8 +19,8 @@ def nothing(*args):
|
||||||
return 'nothing'
|
return 'nothing'
|
||||||
|
|
||||||
|
|
||||||
def nonlocal(*args):
|
def nonlocalEnt(*args):
|
||||||
return 'nonlocal'
|
return 'nonlocalEnt'
|
||||||
|
|
||||||
|
|
||||||
class EntityCreator(EntityCreatorBase.EntityCreatorBase):
|
class EntityCreator(EntityCreatorBase.EntityCreatorBase):
|
||||||
|
|
|
@ -104,7 +104,7 @@ class Level:
|
||||||
Level.notify.debug('creating %s %s' % (spec['type'], entId))
|
Level.notify.debug('creating %s %s' % (spec['type'], entId))
|
||||||
entity = self.entityCreator.createEntity(entId)
|
entity = self.entityCreator.createEntity(entId)
|
||||||
announce = False
|
announce = False
|
||||||
if entity is 'nonlocal':
|
if entity is 'nonlocalEnt':
|
||||||
self.nonlocalEntIds[entId] = None
|
self.nonlocalEntIds[entId] = None
|
||||||
elif entity is 'nothing':
|
elif entity is 'nothing':
|
||||||
self.nothingEntIds[entId] = None
|
self.nothingEntIds[entId] = None
|
||||||
|
|
|
@ -9,7 +9,7 @@ class CogdoEntityCreator(EntityCreator.EntityCreator):
|
||||||
def __init__(self, level):
|
def __init__(self, level):
|
||||||
EntityCreator.EntityCreator.__init__(self, level)
|
EntityCreator.EntityCreator.__init__(self, level)
|
||||||
nothing = EntityCreator.nothing
|
nothing = EntityCreator.nothing
|
||||||
nonlocal = EntityCreator.nonlocal
|
nonlocalEnt = EntityCreator.nonlocalEnt
|
||||||
self.privRegisterTypes({'levelMgr': CogdoLevelMgr,
|
self.privRegisterTypes({'levelMgr': CogdoLevelMgr,
|
||||||
'cogdoBoardroomGameSettings': Functor(self._createCogdoSettings, CogdoBoardroomGameConsts.Settings),
|
'cogdoBoardroomGameSettings': Functor(self._createCogdoSettings, CogdoBoardroomGameConsts.Settings),
|
||||||
'cogdoCraneGameSettings': Functor(self._createCogdoSettings, CogdoCraneGameConsts.Settings),
|
'cogdoCraneGameSettings': Functor(self._createCogdoSettings, CogdoCraneGameConsts.Settings),
|
||||||
|
|
|
@ -16,40 +16,40 @@ class FactoryEntityCreator(EntityCreator.EntityCreator):
|
||||||
def __init__(self, level):
|
def __init__(self, level):
|
||||||
EntityCreator.EntityCreator.__init__(self, level)
|
EntityCreator.EntityCreator.__init__(self, level)
|
||||||
nothing = EntityCreator.nothing
|
nothing = EntityCreator.nothing
|
||||||
nonlocal = EntityCreator.nonlocal
|
nonlocalEnt = EntityCreator.nonlocalEnt
|
||||||
self.privRegisterTypes({'activeCell': nonlocal,
|
self.privRegisterTypes({'activeCell': nonlocalEnt,
|
||||||
'crusherCell': nonlocal,
|
'crusherCell': nonlocalEnt,
|
||||||
'battleBlocker': nonlocal,
|
'battleBlocker': nonlocalEnt,
|
||||||
'beanBarrel': nonlocal,
|
'beanBarrel': nonlocalEnt,
|
||||||
'button': nonlocal,
|
'button': nonlocalEnt,
|
||||||
'conveyorBelt': ConveyorBelt.ConveyorBelt,
|
'conveyorBelt': ConveyorBelt.ConveyorBelt,
|
||||||
'crate': nonlocal,
|
'crate': nonlocalEnt,
|
||||||
'door': nonlocal,
|
'door': nonlocalEnt,
|
||||||
'directionalCell': nonlocal,
|
'directionalCell': nonlocalEnt,
|
||||||
'gagBarrel': nonlocal,
|
'gagBarrel': nonlocalEnt,
|
||||||
'gear': GearEntity.GearEntity,
|
'gear': GearEntity.GearEntity,
|
||||||
'goon': nonlocal,
|
'goon': nonlocalEnt,
|
||||||
'gridGoon': nonlocal,
|
'gridGoon': nonlocalEnt,
|
||||||
'golfGreenGame': nonlocal,
|
'golfGreenGame': nonlocalEnt,
|
||||||
'goonClipPlane': GoonClipPlane.GoonClipPlane,
|
'goonClipPlane': GoonClipPlane.GoonClipPlane,
|
||||||
'grid': nonlocal,
|
'grid': nonlocalEnt,
|
||||||
'healBarrel': nonlocal,
|
'healBarrel': nonlocalEnt,
|
||||||
'levelMgr': FactoryLevelMgr.FactoryLevelMgr,
|
'levelMgr': FactoryLevelMgr.FactoryLevelMgr,
|
||||||
'lift': nonlocal,
|
'lift': nonlocalEnt,
|
||||||
'mintProduct': MintProduct.MintProduct,
|
'mintProduct': MintProduct.MintProduct,
|
||||||
'mintProductPallet': MintProductPallet.MintProductPallet,
|
'mintProductPallet': MintProductPallet.MintProductPallet,
|
||||||
'mintShelf': MintShelf.MintShelf,
|
'mintShelf': MintShelf.MintShelf,
|
||||||
'mover': nonlocal,
|
'mover': nonlocalEnt,
|
||||||
'paintMixer': PaintMixer.PaintMixer,
|
'paintMixer': PaintMixer.PaintMixer,
|
||||||
'pathMaster': PathMasterEntity.PathMasterEntity,
|
'pathMaster': PathMasterEntity.PathMasterEntity,
|
||||||
'rendering': RenderingEntity.RenderingEntity,
|
'rendering': RenderingEntity.RenderingEntity,
|
||||||
'platform': PlatformEntity.PlatformEntity,
|
'platform': PlatformEntity.PlatformEntity,
|
||||||
'sinkingPlatform': nonlocal,
|
'sinkingPlatform': nonlocalEnt,
|
||||||
'stomper': nonlocal,
|
'stomper': nonlocalEnt,
|
||||||
'stomperPair': nonlocal,
|
'stomperPair': nonlocalEnt,
|
||||||
'laserField': nonlocal,
|
'laserField': nonlocalEnt,
|
||||||
'securityCamera': nonlocal,
|
'securityCamera': nonlocalEnt,
|
||||||
'elevatorMarker': nonlocal,
|
'elevatorMarker': nonlocalEnt,
|
||||||
'trigger': nonlocal,
|
'trigger': nonlocalEnt,
|
||||||
'moleField': nonlocal,
|
'moleField': nonlocalEnt,
|
||||||
'maze': nonlocal})
|
'maze': nonlocalEnt})
|
||||||
|
|
Loading…
Reference in a new issue