Category: Chris Talks

Last time I fired up AI War 2 on my Mac, which is a pretty outdated machine with a really really bad GPU, the results were pretty bad. I wasn’t really surprised, because I was running it with all the settings turned up, and the music was throwing errors a bunch, and I knew it could get a lot better with some polish. An old intel 4000 integrated GPU is not exactly at the middle end of the market anymore, even.

Just retested the latest build, which has the music swapped over to a different playback system, and which has a metric ton of performance optimizations from myself and mainly from Keith (the entire game simulation runs on a secondary thread, now).

Results? 300-some odd ships in the very opening battle, with all the settings turned up to maximum still, and it was buttery-smooth. I have no idea what the framerate was, but I feel confident saying it was north of 60.

I just… whaaat? That’s… not what I expected. It’s fantastic, but it’s also a big surprise.

I’m not going to run out immediately and lower the minimum stated system requirements expectations, but that is certainly super duper positive as an indication thus far.

Reminds Me Of Something…

As kind of a fun aside, back when I was coding AI War Classic in the early days I was hoping to get 10k ships in a game, and was pretty sure I could do it. The maximum any other RTS had at the time was about 1000, and it was super choppy and laggy with that many units in the other titles. I felt like I could bump that up by a 10x partly thanks to going 2D, and partly just due to coding practices.

By the time the first public builds were around for AI War Classic, the typically number of units in the game was more like 30k, and it would start to chug around 45k units. Within a year after that, 50k was more typical and it would start to chug at 75k units.

More Generalized Thoughts on Optimization

Sometimes it’s just really surprising how things can go when you throw everything and the kitchen sink at optimization. It’s kinda-sorta working, it’s getting along okay, and then suddenly you pass this critical mass and whoosh the performance jumps by an order of magnitude.

I’m not remotely ready to say that’s happened here, yet, though. The simulation is not remotely finished for the game, as there’s still a lot more AI to build out, and lots more ship functions. The largest battles still have only involved just a few thousand ships at a time for me, whereas in classic sometimes north of 10k ships in one fight would happen.

So I want to see what happens with all those things. Right now early indications are ridiculously, surprisingly good; but some monkey wrench could still very well appear between now and early access that makes me say “yeah, the minimum system requirements for a truly pleasant experience should still be more than a lousy intel 4000.” Then again — maybe not. 🙂

Oh, One Last Thing

In AI War Classic, the simulation speed was locked to the framerate on the slowest computer in a multiplayer game, or to your framerate in solo play. Kinda common for RTS titles, though not all of them.

In AI War 2, your visible framerate is completely unrelated to simulation speed. We’re actually running the simulation speed at 10 cycles per second no matter what, which gives us a lot of muscle per cycle on a secondary group of threads. It doesn’t need to be any more fine-grained than that.

Then for input and actual visual display, of course it can run at much higher framerates, basically up to whatever your hardware can handle. If you’re running at a buttery-smooth 200fps and everything is just peachy, and I’m having more trouble on my machine at a hard-won 30fps or something, the simulation won’t slow down for either of us.

If you’ve looked at my todo list, you’ll see why. There are so many things that I want do do, where I just think “oh, but I could get that done in just a couple of hours at most!”

And it’s true in each instance, but there’s a very real additive cost to all that.

I know that I can make the background starfields, which I’m growing tired of already from a visual sense, look a lot better and more stylized. But is that more important than bugfixes? No… sigh.

I want to get MasterAudio set up so that I can go ahead and have music ducking and so forth in place when I get to that point… but is that more important than just getting uAudio out and thus the game working on OSX properly, and then back to those bugfixes? Again… no… sigh.

And so it goes. Things move fast with Arcen, but there’s still just never enough hours in a day. I’ve had a very unhealthy work/life balance for years, and in the last year or so I’ve been trying to get that more under control.

So… priorities. Making sure I can load music in a cross-platform way and play it efficiently. We’ll worry about audio ducking later when we’d even be doing that at all.

Among other things that will just have to wait. At least with the todo list, you alpha folks can see where my head is at and what I am valuing over what in the short and middle term.

Hopefully everything on that entire list is done within the next month, knock on wood. I have three in which to do it, but I’d rather be done in one.

I’ve been mostly running ubuntu in a Parallels VM on my Macbook. It’s worked well for the last number of years. However, now… well, it’s a combination of drivers and just other accumulated issues.

Basically, the short of it is that my linux install still works, kinda-sorta, but it’s buggy as all get out and randomly crashes and is constantly reporting errors in itself, steam, and various random programs.

This VM was perfectly capable of running Release Raptor, at least at a low framerate with a lot of quality settings off. It also ran a much earlier build of AI War 2.

However, now it literally gives a blue screen in the window that unity pops up when I try to start AI War 2. I think that this is because my VM is so hosed in general, and also because it’s running an older version of ubuntu than unity now supports… and which I can’t upgrade from due to lack of virtual disk space.

All of which is to say, while we DO have “day one alpha” linux support in the game, as promised, I am not presently sure if it works at all. I’m tired of VMs, and I work pretty much exclusively on laptops these days, so what I’ve decided to do is order a new Oryx Pro from system76, with ubuntu natively installed.

All my other machines are MSI, Asus, or Alienware at present, aside from my mac and a trio of old desktop machines in my attic. I don’t have room to run a bunch of desktop towers in my office, though, which is why I went the VM route in the first place.

I looked into getting ubuntu on my existing laptops, but it’s just one of those things that is so fraught because of lack of driver support from those vendors in a lot of cases (shakes fist). Trying to test the game on those would involve hours of actually setting up the ubuntu install, possibly corrupting my master boot records (thanks, Windows 10), and possibly still having a steaming mess of unsupported hardware.

I figured I should Do This Right, instead. The bad news? It may be another two weeks before that new linux machine actually reaches me. So if linux works out of the gate for you during alpha, then I’ll be overjoyed and that’s a relief. If there are problems, I can try to use your error messages to figure out what is up, but most likely I’ll need to have my own linux box before I can really get into it if it’s something complicated.

Hopefully it just works. But you know how that sort of thing can go.

I apologize for not being more on top of the linux build from the start, but it WAS working and it hadn’t occurred to me to test it lately and find that it was suddenly not. The way it dies instantly pretty much guarantees that it’s missing something in my particular install, and not our code doing something that breaks linux. My worry is more that if you get past the first issue on your machine (having a non-broken install and all that), that you’ll instead run into something that’s broken in my part of the code.

Anyway, teething pains. Apologies again if it doesn’t work day 1, and fingers crossed that it will.