本文整理汇总了Python中src.toontown.hood.ZoneUtil.isGoofySpeedwayZone方法的典型用法代码示例。如果您正苦于以下问题:Python ZoneUtil.isGoofySpeedwayZone方法的具体用法?Python ZoneUtil.isGoofySpeedwayZone怎么用?Python ZoneUtil.isGoofySpeedwayZone使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类src.toontown.hood.ZoneUtil
的用法示例。
在下文中一共展示了ZoneUtil.isGoofySpeedwayZone方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: handleWaitForSetZoneResponse
# 需要导入模块: from src.toontown.hood import ZoneUtil [as 别名]
# 或者: from src.toontown.hood.ZoneUtil import isGoofySpeedwayZone [as 别名]
def handleWaitForSetZoneResponse(self, requestStatus):
hoodId = requestStatus['hoodId']
canonicalHoodId = ZoneUtil.getCanonicalZoneId(hoodId)
toHoodPhrase = ToontownGlobals.hoodNameMap[canonicalHoodId][0]
hoodName = ToontownGlobals.hoodNameMap[canonicalHoodId][-1]
zoneId = requestStatus['zoneId']
requestStatus['loader'] = 'cogHQLoader' if ZoneUtil.isCogHQZone(hoodId) else requestStatus['loader']
loaderName = requestStatus['loader']
avId = requestStatus.get('avId', -1)
ownerId = requestStatus.get('ownerId', avId)
if base.config.GetBool('want-qa-regression', 0):
self.notify.info('QA-REGRESSION: NEIGHBORHOODS: Visit %s' % hoodName)
count = ToontownGlobals.hoodCountMap[canonicalHoodId]
if loaderName == 'safeZoneLoader':
count += ToontownGlobals.safeZoneCountMap[canonicalHoodId]
elif loaderName == 'townLoader':
count += ToontownGlobals.townCountMap[canonicalHoodId]
if not loader.inBulkBlock:
if hoodId == ToontownGlobals.MyEstate:
if avId == -1:
loader.beginBulkLoad('hood', TTLocalizer.HeadingToYourEstate, count, 1, TTLocalizer.TIP_ESTATE, zoneId)
else:
owner = base.cr.identifyAvatar(ownerId)
if owner == None:
friend = base.cr.identifyAvatar(avId)
if friend != None:
avName = friend.getName()
loader.beginBulkLoad('hood', TTLocalizer.HeadingToFriend % avName, count, 1, TTLocalizer.TIP_ESTATE, zoneId)
else:
self.notify.warning("we can't perform this teleport")
return
else:
avName = owner.getName()
loader.beginBulkLoad('hood', TTLocalizer.HeadingToEstate % avName, count, 1, TTLocalizer.TIP_ESTATE, zoneId)
elif ZoneUtil.isCogHQZone(zoneId):
loader.beginBulkLoad('hood', TTLocalizer.HeadingToHood % {'to': toHoodPhrase,
'hood': hoodName}, count, 1, TTLocalizer.TIP_COGHQ, zoneId)
elif ZoneUtil.isGoofySpeedwayZone(zoneId):
loader.beginBulkLoad('hood', TTLocalizer.HeadingToHood % {'to': toHoodPhrase,
'hood': hoodName}, count, 1, TTLocalizer.TIP_KARTING, zoneId)
else:
loader.beginBulkLoad('hood', TTLocalizer.HeadingToHood % {'to': toHoodPhrase,
'hood': hoodName}, count, 1, TTLocalizer.TIP_GENERAL, zoneId)
if hoodId == ToontownGlobals.Tutorial:
self.loadDnaStoreTutorial()
else:
if not hasattr(self, 'dnaStore'):
self.loadDnaStore()
hoodClass = self.getHoodClassByNumber(canonicalHoodId)
self.hood = hoodClass(self.fsm, self.hoodDoneEvent, self.dnaStore, hoodId)
self.hood.load()
self.hood.loadLoader(requestStatus)
if not base.placeBeforeObjects:
loader.endBulkLoad('hood')
return