Super Hamster Havoc – Weekly Recap #1

Reading Time: 3 minutes

Happy Sunday Everyone,

We are starting a new blog for the development of Super Hamster Havoc where we’ll write about what updates have been made to Super Hamster Havoc in our weekly development cycle.

For those who are new here, this is what Super Hamster Havoc is about:

Lead the Havoc, an Elite Hamster Strike Squad through a world where humans are no longer. You and your comrades in arms will have to battle against the forces of the evil Rat Menace who’ve overtaken Old Earth.

The game will feature competitive and cooperative modes, and a map editor with the Early Access version (coming Fall 2019), with the campaign being released with the full version of the game.

Things are Going Up

Gif of a player jumping in a test enviroment

No seriously, you can jump in the game now

So the biggest addition to the game this week is being able to jump around in the world. We added this because behind the scenes in the code there was already so much going on behind the scenes to give the illusion of isometric 3D that we might as well commit to it and make stuff collide and process logic with an actual Z-axis in mind.

We are excited about this design-wise because this affords many things in the realm of level design

ALOT of stuff got refactored

So under the hood of Super Hamster Havoc, actual 3D collisions are taking place. All objects have an X, Y, and Z axis, as well as heights, collision volumes, etc. This is important because we are making this game in Gamemaker Studio 2 (An amazing but not exactly 3D Engine) and it doesn’t come with 3D collisions. However, it makes pixel art look awesome, we already several months into this, and I’m very stubborn so we wrote a 3D collision function and began replacing all the 2D collision checks with 3D ones. This exposed a few things to me that I really should fix:

  1. I have broken the sin of not copy and paste my code. Multiple Times
  2. The collision code I wrote assumes that whatever I’m colliding with has been refactored (has a Z-Axis, Height, etc)
  3. Multiple objects in the game have the same base functionality that I keep rewriting over and over again (velocity, friction, collisions, gravity, etc)
Nabil Sweating Meme

A actual picture of Nabil seeing the error of his ways

My solution was to make a base object (because Gamemaker has yet to add classes) that has all the typical behaviors that any object in a level would have and make children that build upon those specific behaviors (an Entity Base, Projectile Base, Prop Base, etc). This means that everything works with 3D collision and new things can be added with minimal effort, and have whatever behaviors that the base object has. The development of the base object, tweaking 3D Collisions and rewriting depth sorting took about a week but has made development a lot easier moving forward because basic things only have to be added/tweaked in one place.

Feel free to scold me in the comments for being a bad coder monkey. 

Leave a Comment

Login
Loading...
Sign Up

New membership are not allowed.

Loading...