Himeko Sutori, tactical turn-based JRPG, armies of hundreds of unique characters

Thanks very much udkultimate and Kee Hoon Ahn. I’m slowly getting this game to where I want it to be, one line of code at a time.

Here’s the official February update:

In there we have the world map, enemy armies, transition to combat and back again, plus background music. I think the mix got messed up because I set the music to higher processing priority, and so the music probably got ahead of the timer during a performance hiccup.

In the video I also mention that I had the game spawning around 5,000 pawns, which was slowing down the game. Each character is only a square that adds two triangles to the scene. 10,000 additional triangles shouldn’t make a difference. I used Unreal’s profiler to find out what exactly was slowing down my game, and discovered that most of the problem was with ticking the pawns’ controllers. So I only give controllers to the enemy pawns when they enter combat. The next biggest slowdown was a deproject that I perform on every character to find out where on the screen it is so that I can tilt the 2D character sprites to counteract the camera’s perspective. Somewhere around here I have a long explanation for how I draw the sprites and why I do it that way. Anyway, point is, it involves a deproject and doing it 5,000 times per tick is pretty costly. So I changed that to update only while the character is onscreen. After some other optimizations, the game runs just fine, even with up to 5,000 characters in the game.

At this point the game engine is pretty much finished and I’m going to focus on making a playable campaign.