Java Tower Stacker

The first prgramming language you learn at Arizona State is Java. After learning the core of object oriented programming, we learn a bit about graphical user interfaces (GUIs). Learning backend programming skills was super cool, but learning GUIs was really cool because I felt like a real programmer because that's all I thought programming was, making user applications with GUIs😅. Outside of homework projects, I wanted to make something fun with my new GUI skills.
The Project
I decided to create a game on my own time because I wanted to get practice with creating GUIs rather than just boring command line programs. Aferall, Minecraft was created in Java.
Results
I watched great tutorials on YouTube from The New Boston and taught myself how to make the game. Unfortunately I couldn't get sound to work (neither could the ASU tutors) even though I tried very hard, but I did manage to run the game in glorious 60FPS (Frames Per Second).

It's hard to tell but the blocks move faster with each level. I programmed it so that if the user landed at least half of the block on the block below then it wouldn't fall off. The block also spawns in at a random horizontal location on the screen and with a random direction.You'll notice that it pauses after the payer triggers it to stack. This is so that the player can see where it was before moving to the next level. You also may have noticed a glitch where the boxes move after the pause. For some reason, the game processed another frame after the pause, and I couldn't figure out why.
What I Learned
- Game Development - I learned just the basics really, like keyboard listeners and how to handle simultaneous keystrokes, as well as how to redraw the canvas 60 times per second while still checking for user input. There are serious timing intricacies in the programming of games.
- More Java - I really don't think I'll be using Java in the future because python is very popular, but here I am learning more Java.
Conclusion
Overall it was cool to see how images are shown on the screen in the back end. People usually take it for granted, but I was amazed at how powerful computers were since they could draw graphics and perform calculations a surprising 60 times per second because it's different when you're programming it. Its crazy to think about how many instructions the CPU is doing per second