当前位置: 首页>>代码示例>>Python>>正文


Python DistributedNode.disable方法代码示例

本文整理汇总了Python中direct.distributed.DistributedNode.DistributedNode.disable方法的典型用法代码示例。如果您正苦于以下问题:Python DistributedNode.disable方法的具体用法?Python DistributedNode.disable怎么用?Python DistributedNode.disable使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在direct.distributed.DistributedNode.DistributedNode的用法示例。


在下文中一共展示了DistributedNode.disable方法的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
    def disable(self):
        """ This method is called when the object is removed from the
        scene, for instance because it left the zone.  It is balanced
        against generate(): for each generate(), there will be a
        corresponding disable().  Everything that was done in
        generate() or announceGenerate() should be undone in disable().

        After a disable(), the object might be cached in memory in case
        it will eventually reappear.  The DistributedObject should be
        prepared to receive another generate() for an object that has
        already received disable().

        Note that the above is only strictly true for *cacheable*
        objects.  Most objects are, by default, non-cacheable; you
        have to call obj.setCacheable(True) (usually in the
        constructor) to make it cacheable.  Until you do this, your
        non-cacheable object will always receive a delete() whenever
        it receives a disable(), and it will never be stored in a
        cache.
        """

        # Take it out of the scene graph.
        self.detachNode()

        DistributedNode.disable(self)
开发者ID:mcgillcomp361,项目名称:COMP361Project,代码行数:27,代码来源:distributedPlayer.py

示例2: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     if self.avatarInTurret:
         self.avatarInTurret.getPart('legs').show()
         self.avatarInTurret.getPart('torso').show()
         self.avatarInTurret.getPart('head').show()
         self.avatarInTurret = None
     self.removeCannon()
     DistributedNode.disable(self)
     return
开发者ID:coginvasion,项目名称:src,代码行数:11,代码来源:DistributedToonCannon.py

示例3: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     taskMgr.remove('showEnterMessage')
     DistributedNode.disable(self)
     if self.geom:
         self.geom.removeNode()
     
     self.unloadConnectors()
     for request in self.pendingSetupConnector.itervalues():
         self.cr.relatedObjectMgr.abortRequest(request)
     
     self.pendingSetupConnector = { }
     self.builder.delete()
     self.builder = None
开发者ID:TTGhost,项目名称:POTCOR-src,代码行数:15,代码来源:DistributedGameArea.py

示例4: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     self.ignore(self.uniqueName('enterShipDeploySphere'))
     self.ignore(self.uniqueName('exitShipDeploySphere'))
     self.ignore(self.uniqueName('enterShipDeploy-MaxSphereSoft'))
     self.ignore(self.uniqueName('exitShipDeploy-MaxSphereSoft'))
     self.ignore(self.uniqueName('enterShipDeploy-MaxSphereHard'))
     self.ignore(self.uniqueName('exitShipDeploy-MaxSphereHard'))
     self.ignore(self.uniqueName('enterShipDeploy-MinSphere'))
     self.ignore(self.uniqueName('exitShipDeploy-MinSphere'))
     self.ignore('settingLocalShip')
     self.unlockMessages()
     self.removeChildren()
     self.minSphere = None
     self.maxSphereSoft = None
     self.maxSphereHard = None
     self.deploySpheres = []
     DistributedNode.disable(self)
开发者ID:Puggyblue999,项目名称:PiratesOfTheCarribeanOnline,代码行数:19,代码来源:DistributedShipDeployer.py

示例5: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     self.ignore('enter' + self.triggerNP.node().getName())
     self.__removeAllBarrels()
     self.barrels = None
     self.numBarrels = None
     if self.rope:
         self.rope.removeNode()
         self.rope = None
     if self.pod:
         self.pod.removeNode()
         self.pod = None
     if self.kart:
         self.kart.removeNode()
         self.kart = None
     self.mg = None
     DistributedNode.disable(self)
     return
开发者ID:coginvasion,项目名称:src,代码行数:19,代码来源:DistributedDeliveryTruck.py

示例6: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     self.fsm.requestFinalState()
     if self.moPath:
         self.moPath.stop()
         self.moPath = None
     self.moPaths = None
     self.honkSfxPath = None
     self.cartModelPath = None
     self.soundEngineLoop = None
     self.soundDriveBy = None
     if self.suitInCar:
         self.suitInCar.disable()
         self.suitInCar.delete()
         self.suitInCar = None
     if self.cart:
         self.cart.removeNode()
         self.cart = None
     del self.fsm
     DistributedNode.disable(self)
     return
开发者ID:coginvasion,项目名称:src,代码行数:22,代码来源:DistributedCityCart.py

示例7: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     DistributedNode.disable(self)
     self.stopProcessVisibility()
开发者ID:AdrianF98,项目名称:Toontown-2-Revised,代码行数:5,代码来源:DistributedCartesianGrid.py

示例8: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     self.unload()
     DistributedNode.disable(self)
开发者ID:coginvasion,项目名称:src,代码行数:5,代码来源:DistributedDroppableCollectableObject.py

示例9: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     self.inShop = False
     self.snp = None
     self.removeClerk()
     DistributedNode.disable(self)
     return
开发者ID:coginvasion,项目名称:src,代码行数:8,代码来源:DistributedShop.py

示例10: disable

# 需要导入模块: from direct.distributed.DistributedNode import DistributedNode [as 别名]
# 或者: from direct.distributed.DistributedNode.DistributedNode import disable [as 别名]
 def disable(self):
     DistributedNode.disable(self)
     del self.trolleyStation
     del self.trolleyCar
开发者ID:coginvasion,项目名称:src,代码行数:6,代码来源:DistributedTrolley.py


注:本文中的direct.distributed.DistributedNode.DistributedNode.disable方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。