What it does

Gravity Sweeper will entertain users for hours as they play!

How we built it

The game was built in the Unity game engine, which uses C# scripts to control game objects and their interactions. All our art was drawn manually on a tablet in order to create an organic and nostalgic feel.

Challenges we ran into

Our first attempts to make asteroids drift randomly were terrible. We had to make sure they moved smoothly and at a constant speed to be fair to the player, but we also wanted them to stay relatively localized to allow for more controlled level creation. Picking a random point, moving straight to it, and then repeating didn’t meet any of these criteria. We ended up making each asteroid move steadily towards an invisible marker. The marker quickly orbited around a central point and switched directions at random intervals. This created the perfect motion!

After playing early versions of the game, we realized we need to make the player always appear on top of the screen, or the controls become unintuitive. We created a complex script to rotate the world, essentially making the player drag the perspective of the game and keep the rocket within 20 degrees of the top of the planet at all times.

Another challenge was creating a responsive and quick UI. This was done by templating the menu elements and grouping them together to reduce delay. We used simple scripts to switch between different game objects in one scene, instead of manually switching scenes when a button is clicked. Finding the right color combination and creating pixel art for the scripts also required a lot of effort. We went through many iterations of earth, background, rocketship, and force field designs to create the best look possible.

Accomplishments that we're proud of

During YHACK2024, our team accomplished several noteworthy achievements that we're proud to highlight. Firstly, we successfully developed a dependable gravitational model, laying the foundation for realistic in-game physics. Additionally, we implemented intricate checks to effectively manage the placement of debris within designated areas of the level while also meticulously modeling rocket thrust for optimal gameplay dynamics. Our efforts extended to simulating asteroid motion and rotation, where we employed a sophisticated pseudo-random technique to generate smooth and natural drift patterns. Furthermore, we dedicated significant time to refining the control mechanisms for both the rocket and asteroids, ensuring a seamless and enjoyable experience for players navigating through the game environment.

What we learned

We had a chance to practice our high-level design and programming skills, learn more about the Unity Engine workflow and pixel art, and improve our knowledge of mathematical modeling. We also learned how to work better in a small team, manage project time, and come up with clever solutions under pressure.

What's next for Gravity Sweeper

We plan to keep the development momentum gained at YHACK2024. Our team is set on expanding our physics model, adding more mechanics such as gravitational wells, portals, and indestructible asteroids and designing levels with engaging puzzles.

Built With

Share this project:

Updates