
this was coursework for my java programming module at uni. it's a 2d platform game, the kind where you run and jump your way through levels.
you collect coins to unlock the next level and apples to get health back, while enemies patrol parts of the map. a timer tracks how you're doing, there's music and sound effects, and you can save and come back later.
the hard bits were making the movement feel right and getting the difficulty balanced across levels. i tested it a lot and adjusted until it was fun but still a challenge.
this was coursework for my Java programming module at uni. it's a 2d platform game, the kind where you run and jump your way through levels. I built it in Java with City's modified JBox2D library for the physics.
you collect coins to unlock the next level and apples to get health back, while enemies patrol parts of the map. a timer tracks how you're doing, there's music and sound effects, and you can save and come back later.
there are multiple levels, and you unlock the next one by collecting coins. enemies patrol set regions of the map so you have to time your way through those bits rather than sprinting everywhere. apples restore health when you pick them up. the timer just records how a run went, and save/load means you can stop mid-game and pick it up again. background music and sound effects sit on top of that so the levels don't feel silent.
the hard bits were making the movement feel right and getting the difficulty balanced across levels. JBox2D handles the physics, but jump height, run speed and how the character lands all had to be tuned by hand. if any of those are slightly off the whole thing feels wrong even when the collisions are technically correct. balancing the levels was the other long job. I tested a lot and adjusted until it was fun but still a challenge, mostly by playing the same sections over and over and moving platforms or enemy paths when something felt cheap or too easy.
I documented the code with Javadoc so the game logic and level setup were readable later, and kept the project on GitHub so the history wasn't just sitting on one machine. I also made a video of the gameplay to show the mechanics working end to end, which helped for the coursework write-up and for anyone opening the repo cold.
Sign in to join the conversation