the code is in a sub, i tried to put it in a function but i didn't solve anything... i tried to write only this code in a new file, to test it out of my game, but it doesn't work... i added "PRINT time, 100, 100" in the IF phase=2 block, to check if the values were right, but the time goes to 0 when the block starts, and it decrease the time value of 1, then it stops... so the time value stays to -1... this is strange too... the value should be decreased of 1 over and over again... but it stops... the variable phase is GLOBAL, but if i set it as LOCAL when i release the enter button it returns to phase=1... i used a variable called press to check if the enter key is pressed, if it is pressed the variable has the value 1... this is the code i used:
if key(enter) and press=0
phase=2
press=1
ENDIF
so when i press enter the mini-game should start, and should go on without holding the key down... and it shouldn't return to the instructions, right? i don't know why, it doesn't work... it's like the variables assume the value 0 in every new IF block, even if the are delared outside the IF blocks...