Post news RSS Turnover - Progress Report for 10/27

Enemy mechanics, Minimap work & optimizations are detailed in this progress update for Turnover.

Posted by on

I launched Turnover’s website last week - It’s good to finally have a landing page for the game. I’ve put some screenshots up over there, so check them out.

Attack Dog, Attacking Mechanics

The attack mechanics of the Attack Dog have been pretty set in stone from the beginning of development. If he spots you, he runs you down (barking all the while) and mauls you. You have so much time to press the ‘use’ key to fight him off, disabling him. If you don’t disable him in time, you die. If you fight him off, you end up crippled, reducing move speed and increasing the stamina needed to run. Also, while he is mauling, he drains your stamina bar.

Now, this mechanic was all well and good in the beginning. There were many status effects that could have been implemented. Over time, Turnover emerged as a fairly straight stealth game, and the RPG-ish ideas I had once harbored have fallen by the wayside. This is when I realized that the crippled status was the only status effect in the game. To me, this meant that it had to go.

So I asked myself, what the hell do I do with the Attack Dog’s attack mechanic? Does removing his ability to cripple destroy who he is as an enemy? The poor ol’ boy was having an existential crisis.

So, I held a few brainstorming sessions. How about I make cripple work different? Maybe have something else happen to the player when mauled? Maybe a temporary effect of some sort could affect the player. Every option seemed to come back to a status effect.

My mind kept on coming back to what makes him dangerous. If you run around him, he barks, alerting nearby enemies. Eliminating crippling, what happens when he mauls you? You have a short amount of time to fight him off as he drains your stamina. That’s when it hit me.

There is an internal timer which gives you so much time to fight him off before death, something like 3 seconds. Meanwhile, your stamina drains as you are held stationary, unable to move. So, I removed the internal timer and tied how much time you have to fight him off to how much stamina you have. I’ll need to put him through some testing, but some results are immediately apparent from this. One, players who run around willy-nilly are going to have a tough time. Having your stamina expended around the Attack Dog could now result in a one hit kill. Two, this allows perk rewards that directly affect stamina to help you out around Attack Dogs. He feels more tied to the actual game now than just doling out a status effect.


Things to note in the GIF:

  • Attack Dog drains stamina on maul. I’ll need to tweak those values for balance.
  • The sound indicator. He barks loudly while mauling. He never used to bark while mauling you. This might catch the attention of more patrols throughout the game.

Hints / Difficulty

I decided some time ago that Turnover would not hold the player’s hand when it comes to what to do. Instead, I’ve opted to ease the player into the mechanics and then set them out on their own. Frankly, the hand holding in some modern games can get a little tiring.


I added a tiny arrow to the minimap recently to give the player a hint as to where the exit is on each floor. That is the extent the player will get, regarding help, when it comes to completing a floor. This doesn’t mean the player can just gun for the exit. They may need to complete some other task to be able to reach the exit, such as disable a Turret or get help from a Rent a Cop. It’s just a hint, after all.

Minimap Draw Optimization

Speaking of the minimap, I was able to optimize the handling of the minimap drawing, knocking an optimization item off the to do list.

On each world draw tick, the game sprites are drawn and rendered. For the minimap, the game world is then drawn again and shrunk down to create the minimap. This means on each draw tick (which happens at 60+ times a second), the sprites are being drawn twice. This was fine for the development version of the minimap, but I knew there were more efficient ways to handle this.

The minimap gives us an overview of the general area. When you look at the map, the only things that move within the map are non-static entities, such as the player and enemies. Everything else is stationary. So, it makes little sense to have to constantly draw things that will not move every tick.

To optimize the minimap, I only want to draw the static sprites once. So, after world load — when everything is loaded and initialized — I draw the static sprites to a RenderTexture and set that off to the side. Then, when the minimap is updated and drawn each tick, I draw the non-static sprites and combine them with the static RenderTexture image, then render the output. So, only non-stationary sprites are drawn a second time each tick.

In the above hint GIF, you can see that everything turned out great. I eliminated a heck of a lot of draw calls from the minimap rendering, thus allowing the engine spend less time drawing.

Post a comment
Sign in or join with:

Only registered members can share their thoughts. So come on! Join the community today (totally free - or sign in with your social account on the right) and join in the conversation.

Post news
Related Games
Turnover Stealth