"Hangman game" works fine on Screen1 but not on another screen

Hello I would like to tell you about my problem and ask if somebody can help me: I copied the blocks from a youtube video for the game The hangman, (the game show you a set of blank letters that match a hidden word and you have to guess what these letters are to reveal the hidden word), to test if the application worked correctly. I created a new project, I copied all the blocks on Screen1 and I tried it on AI companion and it worked perfectly, (I even compiled the application and it works fine too) then I wanted to put that game inside another application that I had already created, it is an application that has several screens, I created a new screen, I copied all the blocks, and I tried it in the "AI companion" and it works correctly. The problem is that when I compile the application and want to play the game, at the first wrong letter that I choose the image of the hanged man disappears. If the letters I choose coincide with the word that is hidden, the image does not disappear and I end up getting the message on the label "You won" but if I make a mistake in any letter, the image disappears, it allows me to continue playing and after To err several times I get the message "You lost" but the important thing about the game is that the images of the hanged man appears one by one and that the hanged man is been formed, and if the images dissapears that does not work for me. I think the problem is not in the blocks because I checked it one by one betwen both apps and they are the same. I checked the designer items betwen both apps and their are the same too. So I dont know what to do, I think maybe the problem have something to do with the fact that the game is on a different screen than Screen1? Thanks in advance..!

Check for global variable usage.
Their values don't cross screens.

Did you also copy required code from Screen1.Initialize to the new screen?

If that doesn't help ...


Please export your project and post it here.

Instead of different screens, why dont you use different Vertical Arrangements ?
Set their visible = true / false as per requirement.

Thank you for answering me. I was going to upload the aia file in which the game worked well both in the companion and in the compiled application and the aia file in which the game worked badly so that you can advise me, but for the last time I created a new project, on screen1 I made a welcome´s screen and on screen2 I copied the blocks of the game that worked well, I compiled the application and now it works well. Maybe it was a bug that the program had, I don't know, anyway thanks for your help. The only tedious thing now is that I have to copy the blocks and design of the previous application on each screen and it takes me a long time but hey, I guess I have to be patient. Thank you anyway..!

Thank you for your suggestion..! I have been learning along the way, through trial and error, and at one point I read that it was better instead of creating screens to do what you suggest, that is, open and close horizontal or vertical arragments with true and false, but This application is old, from when I did not know how to do all that ..! Anyway, your suggestion is very good because I also have a problem with an mp3 music file that I add on the welcome screen 1 and that when I change the screen it does not continue playing and sometimes, when I go to screen 2 and return to screen 1 the mp3 audios overlap, and I suppose that if the guest did not have to open other screens but only one would not have that problem ..! I'll try..! Thank you!!

AI2 has Ctrl-C and Ctrl-V in the Designer, and the associated blocks ride along.
I don't support duplication of code, but this can be useful for refactoring.