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


Python GardenGlobals.whatCanBePlanted方法代码示例

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


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

示例1: plantSomething

# 需要导入模块: import GardenGlobals [as 别名]
# 或者: from GardenGlobals import whatCanBePlanted [as 别名]
 def plantSomething(self):
     whatCanBePlanted = GardenGlobals.whatCanBePlanted(self.ownerIndex, self.plot)
     if whatCanBePlanted == GardenGlobals.INVALID_TYPE:
         self.notify.warning('whatCanBePlanted returned INVALID_TYPE for %d %d' % (self.ownerIndex, self.plot))
     elif whatCanBePlanted == GardenGlobals.FLOWER_TYPE:
         self.popupFlowerPlantingGui()
         self.startInteraction()
     elif whatCanBePlanted == GardenGlobals.GAG_TREE_TYPE:
         self.popupTreePlantingGui()
         self.startInteraction()
     elif whatCanBePlanted == GardenGlobals.STATUARY_TYPE:
         self.popupItemPlantingGui()
         self.startInteraction()
开发者ID:Toonerz,项目名称:Toontown-World-Online-Leak,代码行数:15,代码来源:DistributedGardenPlot.py

示例2: getPlantingText

# 需要导入模块: import GardenGlobals [as 别名]
# 或者: from GardenGlobals import whatCanBePlanted [as 别名]
 def getPlantingText(self):
     plantText = 'hardcoding'
     if self.canBePlanted():
         whatCanBePlanted = GardenGlobals.whatCanBePlanted(self.ownerIndex, self.plot)
         plantText = TTLocalizer.GardeningPlant
         if whatCanBePlanted == GardenGlobals.INVALID_TYPE:
             self.notify.warning('whatCanBePlanted returned INVALID_TYPE for %d %d' % (self.ownerIndex, self.plot))
         elif whatCanBePlanted == GardenGlobals.FLOWER_TYPE:
             plantText = TTLocalizer.GardeningPlantFlower
         elif whatCanBePlanted == GardenGlobals.GAG_TREE_TYPE:
             plantText = TTLocalizer.GardeningPlantTree
         elif whatCanBePlanted == GardenGlobals.STATUARY_TYPE:
             plantText = TTLocalizer.GardeningPlantItem
     return plantText
开发者ID:Toonerz,项目名称:Toontown-World-Online-Leak,代码行数:16,代码来源:DistributedGardenPlot.py

示例3: announceGenerate

# 需要导入模块: import GardenGlobals [as 别名]
# 或者: from GardenGlobals import whatCanBePlanted [as 别名]
 def announceGenerate(self):
     self.plotType = GardenGlobals.whatCanBePlanted(self.ownerIndex, self.plot)
     self.stickUp = 0.0
     if self.getOwnerId() != localAvatar.doId:
         self.defaultModel = None
     elif self.plotType == GardenGlobals.FLOWER_TYPE:
         self.collSphereRadius = 2.0
         self.collSphereOffset = 0.0
         self.plotScale = 0.7
         self.stickUp = 1.1
     elif self.plotType == GardenGlobals.GAG_TREE_TYPE:
         self.collSphereRadius = 3.0
         self.plotScale = 1.5
         self.colorScaler = Vec4(1.0, 1.0, 1.0, 1)
     elif self.plotType == GardenGlobals.STATUARY_TYPE:
         self.collSphereRadius = 3.0
         self.plotScale = 0.075
         self.stickUp = -0.0
         self.defaultModel = 'phase_5.5/models/estate/garden_slab'
     else:
         self.collSphereOffset = 0.0
     self.notify.debug('announceGenerate')
     DistributedLawnDecor.DistributedLawnDecor.announceGenerate(self)
开发者ID:Toonerz,项目名称:Toontown-World-Online-Leak,代码行数:25,代码来源:DistributedGardenPlot.py

示例4: announceGenerate

# 需要导入模块: import GardenGlobals [as 别名]
# 或者: from GardenGlobals import whatCanBePlanted [as 别名]
 def announceGenerate(self):
     DistributedLawnDecorAI.announceGenerate(self)
     self.plotType = GardenGlobals.whatCanBePlanted(self.ownerIndex, self.plot)
     self.__plantingAvId = 0
开发者ID:Kawaiikat14,项目名称:Toontown-2-Revised,代码行数:6,代码来源:DistributedGardenPlotAI.py

示例5: stick2Ground

# 需要导入模块: import GardenGlobals [as 别名]
# 或者: from GardenGlobals import whatCanBePlanted [as 别名]
    def stick2Ground(self, *args, **kwargs):
        plotType = GardenGlobals.whatCanBePlanted(self.ownerIndex, self.plot)
        if plotType == GardenGlobals.FLOWER_TYPE:
            return

        return DistributedLawnDecor.DistributedLawnDecor.stick2Ground(self, *args, **kwargs)
开发者ID:BmanGames,项目名称:ToontownStride,代码行数:8,代码来源:DistributedGardenPlot.py


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