- Apr 15, 2017
- 35
- 22
I've posted a few renpy questions so far and figuring it out more as I go. One response pointed out that the match 3 minigame I'm using is pretty out of date but it's serving its purpose for me while I 'demo' my game. But I've broken something in the win/loss portion and can't figure it out.
THE PROBLEM:
The match 3 game is going to be a best 3/5. Each round won will call a cut scene (calls a label then returns, I've tested these and they're working fine) and return to the game. The game is SUPPOSED to end after 3 wins or at 5 rounds, whichever comes first.
Currently my round 1, round 2 and BONUS cutscenes work but the game won't end and just keeps going round after round (I've gone as high as 8 rounds won and just closed it down as clearly it wasn't stopping at 5 either way)
The CODE:
Anything I'm overlooking?
THE PROBLEM:
The match 3 game is going to be a best 3/5. Each round won will call a cut scene (calls a label then returns, I've tested these and they're working fine) and return to the game. The game is SUPPOSED to end after 3 wins or at 5 rounds, whichever comes first.
Currently my round 1, round 2 and BONUS cutscenes work but the game won't end and just keeps going round after round (I've gone as high as 8 rounds won and just closed it down as clearly it wasn't stopping at 5 either way)
The CODE:
Code:
label memo_game_win:
hide screen memo_scr
$ renpy.pause (0.1, hard = True)
$ renpy.pause (0.1, hard = True)
"You win!"
$ gameSet += 1
$ win += 1
if win == 1:
call expression challenger + "_" + match + "_win_1"
elif win == 2:
call expression challenger + "_" + match + "_win_2"
else:
jump memoria_game
$ winImg += 1
if winImg >= 5:
$ winImg == 4
if gameSet == 2:
if win == 2:
call expression challenger + "_" + match + "_BONUS"
jump memoria_game
if gameSet <= 4:
if win == 3:
call expression challenger + "_" + match + "_won"
elif win <= 2:
jump memoria_game
elif gameSet == 5:
if win == 3:
call expression challenger + "_" + match + "_won"
elif win <= 2:
call expression challenger + "_" + match + "_lost"