本文整理匯總了Python中toontown.golf.GolfGlobals.getHistoryIndexForTrophy方法的典型用法代碼示例。如果您正苦於以下問題:Python GolfGlobals.getHistoryIndexForTrophy方法的具體用法?Python GolfGlobals.getHistoryIndexForTrophy怎麽用?Python GolfGlobals.getHistoryIndexForTrophy使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類toontown.golf.GolfGlobals
的用法示例。
在下文中一共展示了GolfGlobals.getHistoryIndexForTrophy方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: grow
# 需要導入模塊: from toontown.golf import GolfGlobals [as 別名]
# 或者: from toontown.golf.GolfGlobals import getHistoryIndexForTrophy [as 別名]
def grow(self, index, pos):
self.trophyPanels[index]['image_color'] = Vec4(1.0, 1.0, 0.8, 1.0)
if index < GolfGlobals.NumTrophies:
self.trophyTextDisplay['text'] = TTLocalizer.GolfTrophyTextDisplay % {'number': index + 1,
'desc': TTLocalizer.GolfTrophyDescriptions[index]}
historyIndex = GolfGlobals.getHistoryIndexForTrophy(index)
if historyIndex >= 0:
self.currentHistory['text'] = TTLocalizer.GolfCurrentHistory % {'historyDesc': TTLocalizer.GolfHistoryDescriptions[historyIndex],
'num': self.avatar.getGolfHistory()[historyIndex]}