本文整理汇总了Python中toontown.quest.Quests.avatarHasAllRequiredRewards方法的典型用法代码示例。如果您正苦于以下问题:Python Quests.avatarHasAllRequiredRewards方法的具体用法?Python Quests.avatarHasAllRequiredRewards怎么用?Python Quests.avatarHasAllRequiredRewards使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类toontown.quest.Quests
的用法示例。
在下文中一共展示了Quests.avatarHasAllRequiredRewards方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: avatarConsiderProgressTier
# 需要导入模块: from toontown.quest import Quests [as 别名]
# 或者: from toontown.quest.Quests import avatarHasAllRequiredRewards [as 别名]
def avatarConsiderProgressTier(self, av):
# Get the avatars current tier.
currentTier = av.getRewardTier()
# Check if they have all required rewards.
if Quests.avatarHasAllRequiredRewards(av, currentTier):
if currentTier != Quests.ELDER_TIER:
currentTier += 1
av.b_setRewardHistory(currentTier, [])
示例2: __considerProgressTier
# 需要导入模块: from toontown.quest import Quests [as 别名]
# 或者: from toontown.quest.Quests import avatarHasAllRequiredRewards [as 别名]
def __considerProgressTier(self, av):
tier = av.getRewardHistory()[0]
hasAllRewards = Quests.avatarHasAllRequiredRewards(av, tier)
if hasAllRewards:
if not av.getQuests():
tier = min(Quests.ELDER_TIER, tier + 1)
av.b_setRewardHistory(tier, [])
return 0
return 1
return 0
示例3: avatarProgressTier
# 需要导入模块: from toontown.quest import Quests [as 别名]
# 或者: from toontown.quest.Quests import avatarHasAllRequiredRewards [as 别名]
def avatarProgressTier(self, toon):
currentTier = toon.getRewardHistory()[0]
if Quests.avatarHasAllRequiredRewards(toon, currentTier):
if currentTier != Quests.ELDER_TIER:
currentTier += 1
toon.b_setRewardHistory(currentTier, [])