fix fish bingo crashes
Hope you had fun playing Fish Bingo.
This commit is contained in:
parent
8df97582b2
commit
d6c0975c05
2 changed files with 4 additions and 4 deletions
|
@ -13,7 +13,7 @@ class BingoCardBase:
|
|||
self.cardSize = cardSize
|
||||
self.cellList = []
|
||||
self.gameType = None
|
||||
self.gameState = 1 << self.cardSize / 2
|
||||
self.gameState = 1 << self.cardSize // 2
|
||||
return
|
||||
|
||||
def destroy(self):
|
||||
|
@ -35,7 +35,7 @@ class BingoCardBase:
|
|||
rodId = 0
|
||||
|
||||
for index in range(self.cardSize):
|
||||
if index != self.cardSize / 2:
|
||||
if index != self.cardSize // 2:
|
||||
choice = rng.randrange(0, len(fishList))
|
||||
self.cellList.append(fishList.pop(choice))
|
||||
else:
|
||||
|
|
|
@ -32,7 +32,7 @@ class BingoCardGui(DirectFrame):
|
|||
self.initialiseoptions(BingoCardGui)
|
||||
self.game = None
|
||||
self.cellGuiList = []
|
||||
self.parent = parent
|
||||
self._parent = parent
|
||||
self.load()
|
||||
self.hide()
|
||||
self.taskNameFlashFish = 'flashMatchingFishTask'
|
||||
|
@ -126,7 +126,7 @@ class BingoCardGui(DirectFrame):
|
|||
self.gameType.hide()
|
||||
self.jpText = DirectLabel(parent=self, pos=(BG.GridXOffset, 0, 0.22), relief=None, state=DGG.NORMAL, text='', text_scale=TTLocalizer.BCGjpText, text_pos=(0, 0, 0), text_fg=(1, 1, 1, 1), text_shadow=(0, 0, 0, 1), text_font=ToontownGlobals.getInterfaceFont(), text_wordwrap=TTLocalizer.BCGjpTextWordwrap)
|
||||
self.gameOver = DirectLabel(parent=self, pos=(BG.GridXOffset, 0, 0), relief=None, state=DGG.NORMAL, text='', text_scale=textScale, text_fg=(1, 1, 1, 1), text_font=ToontownGlobals.getSignFont())
|
||||
self.jpSign = DirectFrame(parent=self.parent, relief=None, state=DGG.NORMAL, pos=BG.CardPosition, scale=(0.035, 0.035, 0.035), text=TTLocalizer.FishBingoJackpot, text_scale=2, text_pos=(-1.5, 18.6), text_fg=(1, 1, 1, 1), image=self.model.find('**/jackpot'), image_pos=(0, 0, 0), image_hpr=(0, 90, 0), sortOrder=DGG.BACKGROUND_SORT_INDEX)
|
||||
self.jpSign = DirectFrame(parent=self._parent, relief=None, state=DGG.NORMAL, pos=BG.CardPosition, scale=(0.035, 0.035, 0.035), text=TTLocalizer.FishBingoJackpot, text_scale=2, text_pos=(-1.5, 18.6), text_fg=(1, 1, 1, 1), image=self.model.find('**/jackpot'), image_pos=(0, 0, 0), image_hpr=(0, 90, 0), sortOrder=DGG.BACKGROUND_SORT_INDEX)
|
||||
self.makeJackpotLights(self.jpSign)
|
||||
self.hideJackpot()
|
||||
self.makeTutorial()
|
||||
|
|
Loading…
Reference in a new issue