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


Python ToontownInternalRepository.handleConnected方法代码示例

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


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

示例1: handleConnected

# 需要导入模块: from toontown.distributed.ToontownInternalRepository import ToontownInternalRepository [as 别名]
# 或者: from toontown.distributed.ToontownInternalRepository.ToontownInternalRepository import handleConnected [as 别名]
 def handleConnected(self):
     ToontownInternalRepository.handleConnected(self)
     if config.GetBool('want-ClientServicesManagerUD', self.wantUD):
         # Only generate the root object once, with the CSMUD.
         rootObj = DistributedDirectoryAI(self)
         rootObj.generateWithRequiredAndId(self.getGameDoId(), 0, 0)
     self.createGlobals()
开发者ID:Toonerz,项目名称:Toontown-World-Online-Leak,代码行数:9,代码来源:ToontownUberRepository.py

示例2: handleConnected

# 需要导入模块: from toontown.distributed.ToontownInternalRepository import ToontownInternalRepository [as 别名]
# 或者: from toontown.distributed.ToontownInternalRepository.ToontownInternalRepository import handleConnected [as 别名]
    def handleConnected(self):
        self.notify.info('Yarn. Waking up (This may take a while!).')
        ToontownInternalRepository.handleConnected(self)
        self.districtId = self.allocateChannel()
        self.distributedDistrict = ToontownDistrictAI(self)
        self.distributedDistrict.setName(self.districtName)
        self.distributedDistrict.generateWithRequiredAndId(
            self.districtId, self.getGameDoId(), 2)

        # Claim ownership of that district...
        dg = PyDatagram()
        dg.addServerHeader(
            self.districtId,
            self.ourChannel,
            STATESERVER_OBJECT_SET_AI)
        dg.addChannel(self.ourChannel)
        self.send(dg)

        self.notify.info('Creating Global Managers')
        self.createGlobals()
        self.notify.info('Creating Toontown')
        self.createZones()

        self.statusSender.start()

        self.distributedDistrict.b_setAvailable(1)
        self.notify.info('District is now ready.')
开发者ID:Toonerz,项目名称:Toontown-World-Online-Leak,代码行数:29,代码来源:ToontownAIRepository.py

示例3: handleConnected

# 需要导入模块: from toontown.distributed.ToontownInternalRepository import ToontownInternalRepository [as 别名]
# 或者: from toontown.distributed.ToontownInternalRepository.ToontownInternalRepository import handleConnected [as 别名]
    def handleConnected(self):
        ToontownInternalRepository.handleConnected(self)
        rootObj = DistributedDirectoryAI(self)
        rootObj.generateWithRequiredAndId(self.getGameDoId(), 0, 0)

        if config.GetBool('want-rpc-server', False):
            endpoint = config.GetString('rpc-server-endpoint', 'http://localhost:8080/')
            self.rpcServer = ToontownRPCServer(endpoint, ToontownRPCHandler(self))
            self.rpcServer.start(useTaskChain=True)

        self.createGlobals()
        self.notify.info('Done.')
开发者ID:RandomToon,项目名称:Toontown-2,代码行数:14,代码来源:ToontownUberRepository.py

示例4: handleConnected

# 需要导入模块: from toontown.distributed.ToontownInternalRepository import ToontownInternalRepository [as 别名]
# 或者: from toontown.distributed.ToontownInternalRepository.ToontownInternalRepository import handleConnected [as 别名]
    def handleConnected(self):
        ToontownInternalRepository.handleConnected(self)
        self.notify.info(True)
        if config.GetBool("want-ClientServicesManagerUD", self.wantUD):
            self.notify.info("Creating ClientServicesManagerUD...")
            # Only generate the root object once, with the CSMUD.
            rootObj = DistributedDirectoryAI(self)
            rootObj.generateWithRequiredAndId(self.getGameDoId(), 0, 0)
        self.notify.info("Creating globals...")
        self.createGlobals()

        if config.GetBool("want-rpc-server", False):
            self.notify.info("Starting RPC server...")
            import ToontownRPCHandler

            self.rpcserver = RPCServer(ToontownRPCHandler(self))
        self.notify.info("Done.")
开发者ID:Teku16,项目名称:TTR-Offline,代码行数:19,代码来源:ToontownUberRepository.py

示例5: handleConnected

# 需要导入模块: from toontown.distributed.ToontownInternalRepository import ToontownInternalRepository [as 别名]
# 或者: from toontown.distributed.ToontownInternalRepository.ToontownInternalRepository import handleConnected [as 别名]
 def handleConnected(self):
     ToontownInternalRepository.handleConnected(self)
     threading.Thread(target=self.startDistrict).start()
开发者ID:BmanGames,项目名称:ToontownStride,代码行数:5,代码来源:ToontownAIRepository.py


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