Fix nothing working

Hi, I’m making a project that requires the player to press a button in a certain window of time. I ran into a bug that goes something like this: The player presses the “↑” key and I set a variable boolean to true. I print this boolean onto the screen for me to see and it goes “false, true, false, true” but I just want it to be true… see photo (1)


I have a function that checks if the boolean for up is true or not, but this “true/false” thing is messing with that… anyone know a fix? Thank you in advance