Game Development So Far
Straight off the bat, last week’s tasks were:
- Finish the fixes for collision avoidance
- Add more equipment
- Add animations for new equipment
I’ve spent all of this week purely focused on the collision avoidance.
Other Developments
In my last post I alluded to getting closer to a solution that involved the ragdoll collision boxes contained within the character causing confusion when looking for collision boxes to avoid. Long story short the closer I got to resolving this issue the messier the code got, the less efficient it became and I could see the final solution was not going to give the visual results I was hoping for.
I went back to the drawing board and started investigating Unity’s built in NavMesh options. Unity includes functionality whereby you can define a NavMeshSurface (i.e. a surface that is navigable by NavMeshAgents) and set NavMeshObstacles for the NavMeshAgents to avoid.

I originally avoided this method as the environment for a tycoon game is likely to vary, therefore a pre-baked navigable surface didn’t make sense. However, looking more into it turns out that NavMesh can deal with this.
Therefore the majority of this week has been spent setting up the NavMesh. Not without its own issues. To start with all of the character (NavMeshAgents) were at a weird angle in the game, kind of like they were all doing the Michael Jackson lean from smooth criminal.

While cool in its own right, it meant that the characters couldn’t navigate their surroundings and just rotated around the spot! Upon further investigation it turned out that the surface I was using for the floor in the gym wasn’t total flat, there were some sneaky angles here and there. This was solved by remaking the floor as a completely flat plane. I also took the opportunity to put in a change I’ve planning for a while to the way the floor is generated and to also give it a slightly updated look.

The next issue I faced was that with this now solved all the Agents suddenly started pushing off to the edges of the NavMesh. This turned out the be that the collision radius of each individual agent was lower than the minimum required radius that was imposed by the NavMesh. Not a big issue but just an indication of some of the stumbling blocks when using/learning a new function.
I’m now at the point where the characters nicely avoid obstacles and take varied paths throughout the environment. The next challenges are to make the characters avoid each other.
The past few weeks have felt really challenging and have been quite possibly the most challenging weeks of my game dev career so far. The thing is that I’ve had it quite good in terms of progress in the fact that most tasks and challenges I’ve faced I’ve had continuous progress on and managed to solve quite quickly. Also a lot of the updates over the past few months have given me a lot of output to show to the community. These past few weeks have felt quite slow in terms of progress as I’ve had to try quite a few different approaches to solve the issues, some of which are yet to be solved. It’s left me feeling at times like I’m never going to get past these issues. Equally the changes don’t have as much of a visual impact as they do a functional one. But hey that’s game development! It was never going to be easy and is what makes the progress so much more satisfying! As I always say a little bit of progress each and every day is the key to success.
Time Management
With that being said this week’s task list is a very small but very realistic one:
- NAVMESH!
Gym Empire is now available to add to your Steam Wishlist.
Join the discord for exclusive beta access Chronik Spartan Discord.
For news and updates on Chronik Spartan games and future blog posts please subscribe.
You can support Chronik Spartan Games and get exclusive access to in depth behind the scenes news and other awesome rewards at Patreon.
