Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

>> THE GREAT REFACTORING <<

Wow, it's been a while. A lot has happened since I lost updated this post. School got crazy and my job got crazier. There was a long stretch of time where I didn't even want to look at the game because I burnt myself out so bad. But I took a long break from game development before finally sitting down and re-planning out everything that I wanted to work on.

I believe I said this somewhere already but for a long time I only could work on my game for about two hours a day. This was true at the time but now I have reached a point where I can actually work on it for far longer than that. After taking care of myself, failing a couple times of porting to a different game engine (Godot, in case you were wondering), and finally finding the strength to open the project, I realized that I coded this thing like a maniac.

Nested if-statements were rampant, memory-leaks were abundant, and references to an object's code were referenced by another object's code that referenced the original object's code. As a programmer, I was a bit disappointed in myself that I would create such jarring code like that. As a game designer, however, I can safely say that it was necessary spaghetti code in order to just START something. I truly believe that every game ever developed started out code-wise looking utter garbage and later on during development cleaned up and refined. I believe the time is NOW for me to start refining all this code and actually making it look nicer and more efficient for future programming.

>> WHERE DO I EVEN BEGIN? <<

The first thing that was on my radar was the combat system. I kept running into a memory leak that turned out to be a simple fix. Basically, I had a draw-call somewhere that was suppose to run only once but was accidentally left inside of a loop thus making calling the draw-call every frame. Super simple fix.

After fixing that, the entire battle system needed to be rewritten. I had a good chunk of code related to the battle system inside of the Player Object for some reason. For the battle system I am making, having the Player Object hold any of the code for it was ridiculous and definitely needed to be removed. Of course, moving code around also affected other areas of the project as they originally referenced the code in the Player Object. This probably took the most amount of time to fix due to going through and manually seeing what object's code was referencing what and changing them to reference the Battle Manager Object instead.

While controller support is still on the back-burner, I did have to create a Controller Object to handle all the input. Technically, I don't need to do this but I wanted to so I won't clog up the Player Object with input controls.

There's still so much I have to do and so much I have to both refactor and create from scratch. I actually started a Trello account just to keep track of everything I needed to do which was a first for me. I usually just have to-do lists on Google Docs or something. But getting back on track, due to the refactoring, now I have more bugs I have to fix.

For example: When the player wants to leave a fight, the game freezes. I have no idea why it does that but it does. The inventory system is completely broken due to data being moved around. All references to that data has been lost so now whenever the Player opens their inventory it just crashes. This is also a simple fix as I just have to re-reference where the data has been moved to but because I'm trying to fix so many other issues it has taken a backseat as I squash way more threatening bugs.

>> SO WHAT CAN WE EXPECT FROM YOU? <<

I'm planning on coming back with the monthly updates. I might post more than once a month depending on the kind of update it is. I also have been looking into maybe posting devlogs on Youtube Channel instead of just posting memes and mashups.

I will also be cross-posting these devlogs on more than one website, including itch.io and my website. Eventually I'll look into a mailing list system like Mailchimp or something so that way I don't have to keep copying and pasting the same thing everywhere.

My main goal, besides from developing this game, is to keep everyone updated on it. I want the word to get out there and the only way to do that is to actually talk about the game.

It's going to be an interesting journey and I hope you're excited as I am about what's to come.

Until next time, take care.