1. AI War 2
  2. News

AI War 2 News

v2.062 Released! "Savegame/Networking Data Compaction"

This is on the beta branch, as it's a freaking huge number of changes. The more testers the better, please! Full notes here.
[h3]How To Play A Beta Branch Build[/h3]

To play this on Steam, please go under betas and choose current_beta from the drop-down list. We would really appreciate some testers on this so that we can get back out of beta status as quickly as possible! There is not currently a way to get the beta versions on GOG, but we won't be in that status for more than a week, knock on wood.

We want to make sure we didn't break anything with all the substantial changes in here, but we fully expect some savegames to throw cosmetic errors at the very minimum. Please report and upload those here: https://bugtracker.arcengames.com/
[h3]What's New?[/h3]
  • The biggest thing for me personally is the new data compaction stuff, which I have been pouring hours into in preparation for multiplayer. The last thing I want is for multiplayer to be functional, but immediately laggy as soon as we have the desync repair stuff going. I needed to start with efficient data storage and transmittal so that there wouldn't be a point where I need to disappear for a week to redo all that after we're into multiplayer's alpha.
  • I'm not entirely done with my data compaction shenanigans, but I'm very excited about how it has turned out so far. I do expect it to result in a number of user-facing errors, though, so hence the beta, which I really hope you'll partake in.
  • Badger fixed a number of bugs, including several achievements that were not triggering. Also that all the AI units have had the equivalent of mark 1 shields/hull for the last two weeks??
  • Meanwhile, Badger also implemented another major fireteams upgrade, this one which is intended for the upcoming DLC2 but has been backported to the base game.
  • The first use of this fireteams code is to let the AI really fight some other faction other than you with giant fists, without killing you in the process. Aka, let it fight the Marauders or the Nanocaust using REALLY BIG AND SCARY GUNS if those two factions are taking over the galaxy... but don't have that be game-ending for you. You're not the problem, after all, from the AI's point of view.
  • The second use of this is to let us have certain sub-groups of the AI faction, most notably Hunters right now, which have a sub-subgroup that just focuses on one objective after you harass them. The example in place right now is Major Data Centers (MDCs). Those always triggered an Exogalactic Wave, previously, which was boring -- more ships come in increasing waves, and you survive them or don't. It felt kind of uninspired. NOW, instead, the hunters get a major buff to a certain sub-team that explicitly hunts the MDC and its protectors... and if it wins against that, eventually, then they just leave you alone -- "job's done, bye!"
  • The way that the hunter deals with allied factions to you is a lot more interesting, too, rather than your allies causing rapid AIP gains by killing all the warp gates and aggroing the AI in that way.
  • These are some major strides forward towards multiplayer being a smooth and fun experience as we get into that, and towards the DLC2 that will come out around the time multiplayer fully releases (multiplayer will be free). Please note that none of the DLC2 stuff is slowing down multiplayer at all, as Badger is not working at all on multiplayer and I'm entirely focused on that and related things for now.
  • Oh, also, for the sake of modders we've documented some new things that will help with making sure mods are multiplayer-compatible.
  • Note that if a mod you like turns out NOT to be multiplayer-compatible, the game should still be playable. You'll just have a ton more desync-repair messages going back and forth, related to the mod. This is an excellent example of why I want those desync-repair messages to be absolutely as efficient as they possibly can be, which means representing all our data in as tiny a format as possible.


More to come soon!

But here's some further reading on what we're doing in detail:
[h3]Why Do We Care About Compaction?[/h3]

I explain what I mean by this below, and go into detailed benchmarks. The release notes have a lot of other detailed info. But a TLDR of why this matters is certainly a good place to start:
  • Smaller savegames are easier to transmit across the network when you're initially synchronizing your game from a host to clients.
  • Doing it via our compaction method, versus compression, uses FAR less CPU cycles, and thus makes the transfer of even small, frequent bits of data run more smoothly.
  • Doing it via our compaction method makes even small bits of data... smaller. Compression often requires a lot of data before it makes much difference.
  • Given that we are going to have frequent small commands being sent back and forth just to have the game run at all, and then we ALSO are going to have the desync-repair data going back and forth that is still small (but substantially larger at the scale of network messages), this is pretty critical.
  • So the TLDR of the TLDR is that we use less bandwidth and less CPU to do the same thing, and thus your game will run way more smoothly in multiplayer.
  • And it has the side benefit of making savegames a lot smaller, and also faster to save.

[h3]Data Compaction vs Compression[/h3]

What the heck is data "compaction?" Well, in the most direct sense here, it's a term I made up. The way I'm defining the term, for purposes of what we're doing here, is "making data smaller at the level of small objects, as we put it into a binary stream."

Wait, what? Basically... it's something we do as we go along, and it works on very small pieces of information. A single integer. One ship and its data. That sort of thing.

Compression, by contrast, requires a lot of processing AFTER you put in your data to some sort of format. So to compress a bunch of data in AI War Classic, for instance, we write roughly 30MB of data for a savegame into a temporary buffer, and then we run GZIP compression on that, which turns it into maybe 1MB that we can store on the disk or send across the network.

That 30:1 ratio is legitimately what AIWC was seeing, on average, by the way. The downside is that it only really works well for very large amounts of data, and it also requires a lot of processing every time it wants to send or save. You'll notice that AIWC has a noticeable hitch in itself every time it saves the game. AI War 2, by contrast, doesn't use compression and thus doesn't have that sort of hitching.

AI War 2 is a lot smarter about how it represents its data to start with (using binary formats directly instead of a unicode-based format), and uses clever tricks to also know when not to send data of certain sorts (if I don't have X properties, then don't bother tracking them). So this realistically converts what would have been 30MB in AI War Classic into something that might be... 5 MB in AI War 2.

Beyond that, though, requires a lot more work, because we actually have far more data here than in AI War Classic -- enough that despite our better formats and such, we'd be back up around 10 MB or so for savegames.

Several years ago, perhaps four now, Keith LaMothe came up with a great new concept he called "buzzsaw binary," and we posted benchmarks on how incredibly efficient it was at storing data. After working out some kinks with it, we've been using that for the last few years, and it saves blazing fast, as you've probably noticed.

Basically, this takes each data point that we want to store in binary and writes it directly into a bitstream (which C# does not officially have -- they only have bytestreams). As it writes to our custom bitstream, it analyzes each piece of data and figures out if it can make it any smaller than would normally happen for that kind of data. The types of data that Keith built support for were string, 32bit integer, and 64bit integer. The last of those also gave us support for our own FInt fixed-integer format, and by extension also some limited float support (thought we avoid float as much as possible).

The plan was always to go further, and he left notes to himself to do so directly in the code, actually. With this format, storing a byte was actually highly inefficient, taking on average 10 bits rather than 8. But we never even tried to directly store bytes, so that was kind of irrelevant.

In most programming languages, integer numbers can be stored as 8, 16, or 32 bits, with or without the ability to have negative numbers (called signed numbers). In the prior edition of buzzsaw binary, we assumed all numbers were signed and could be up to 64 bits, and wrote them out in a manner that still produced results that were often 16 bits or less for a 32bit number. That was a savings of 50% or more, in lots of cases.

A big part of the savings is what to do with "default case" numbers, such as those that are 0. How many bits should you take to store that zero? By default, a 32bit number will take 32 bits to say 0, and a 64bit number will take 64 bits to say 0. In buzzsaw binary, regardless of the bit level of the number, it has always taken us 1 bit to store a zero.

One tricky thing is that we use a lot of -1s as defaults for various reasons, and that was something that required 10 bits to store. Ack!

So for me, I went in and finally figured out Keith's code, and added a ton of comments to make it clear what was going on. I added explicit support for
  • 8bit (aka byte) and 16bit (aka short) numbers
  • And some special cases for:
  • numbers of 16 or more bits that cannot be negative
  • numbers of 16 or more bits that cannot be any smaller than -1
  • and 8 bit numbers (bytes) that are frequently 0


Those are... strange categories, I know. But when you look at the data we use, and apply the same sort of buzzsaw binary approach, but with more hinting from the higher-level program (as well as more appropriate number formats for variables instead of int32 for everything), then you wind up with some truly amazing compaction. I've detailed the macro results of that here.

Bytes now take an average of 4.74 bits in a savegame, down from 10ish in our previous implementations. In the benchmarks I just not the percentage relative to the normal 8 bits. "32 bit numbers that cannot be less than -1" are averaging out at 2.71 bits instead of 32.

Overall file sizes for the game dropped in this build to commonly about 70% of what they previously were, and as low as 28% in one case. The actual data format change only represents a savings of 10%, sadly, but it's still a win, even if it is a minority of the gains.
[h3]Please Do Report Any Issues![/h3]

If you run into any bugs, we'd definitely like to hear about those.

The release of this game has been going well so far, and I think that the reviews that folks have been leaving for the game have been a big help for anyone passing by who's on the fence. For a good while we were sitting at Overwhelmingly Positive on the Recent Reviews breakdown, but there have been a lot fewer reviews lately and so that has definitely had a material negative effect. Go figure. Having a running selection of recent reviews definitely is helpful, but at least we have a pretty healthy set of long-term reviews. If you've been playing the game and enjoying it, we'd greatly appreciate it if you'd drop by and leave your own thoughts, too.

More to come soon. Enjoy!
[h3]Problem With The Latest Build?[/h3]

If you right-click the game in Steam and choose properties, then go to the Betas tab of the window that pops up, you'll see a variety of options. You can always choose most_recent_stable from that build to get what is essentially one-build-back. Or two builds back if the last build had a known problem, etc. Essentially it's a way to keep yourself off the very bleeding edge of updates, if you so desire.
[h3]The Usual Reminders[/h3]

Quick reminder of our new Steam Developer Page. If you follow us there, you'll be notified about any game releases we do.

Also: Would you mind leaving a Steam review for some/any of our games? It doesn't have to super detailed, but if you like a game we made and want more people to find it, that's how you make it happen. Reviews make a material difference, and like most indies, we could really use the support.

Enjoy!

Chris

v2.048 Released! "Bugfixes"

This one is nothing but a collection of bugfixes, but there are some very welcome ones. Full notes here.

What's new?
  • You can upgrade forcefield frigates beyond mark 4, as they now use the heavy hull tech type.
  • Fleet Research Stations, new in the last version, now properly charge you AI Progress (AIP) for the things you get from them.
  • Handy new cheat code "heal me" that is useful for bugtesting.
  • Multiple improvements to make tachyon sources way more efficient.
  • A fix to make tachyon sources work at the proper speed when they are on background planets (with coarse processing on) or when you have the sim speed higher than one. Previously it took longer to decloak enemies, but now it works at the same speed regardless of those factors. This is a super old issue! At least two years old, if not more.
  • We also found and removed a really super old form of performance profile logging, which generally was unused but could be toggled on by some unknown mechanism and then slow down your game at some points. This was code that hadn't been touched in 2-3 years, s it was a surprising find.
  • Fallen Spire cities that were able to rarely get extra flagships now have those properly scaled back. And if you ever have a city missing its flagship, it will fix that for you (though we've no reports of that).
  • And finally, there was a very annoying issue that if you had selected any ships directly and they changed planets, it would deselect them. Selecting by fleet did not have this problem, so to people who experienced it, it just seemed intermittent. As someone who pretty much always selects by-fleet, I had not been seeing the issue until it was pointed out with steps on how to reproduce it.


More to come soon!
[h3]Please Do Report Any Issues![/h3]

If you run into any bugs, we'd definitely like to hear about those.

The release of this game has been going well so far, and I think that the reviews that folks have been leaving for the game have been a big help for anyone passing by who's on the fence. For a good while we were sitting at Overwhelmingly Positive on the Recent Reviews breakdown, but there have been a lot fewer reviews lately and so that has definitely had a material negative effect. Go figure. Having a running selection of recent reviews definitely is helpful, but at least we have a pretty healthy set of long-term reviews. If you've been playing the game and enjoying it, we'd greatly appreciate it if you'd drop by and leave your own thoughts, too.

More to come soon. Enjoy!
[h3]Problem With The Latest Build?[/h3]

If you right-click the game in Steam and choose properties, then go to the Betas tab of the window that pops up, you'll see a variety of options. You can always choose most_recent_stable from that build to get what is essentially one-build-back. Or two builds back if the last build had a known problem, etc. Essentially it's a way to keep yourself off the very bleeding edge of updates, if you so desire.
[h3]The Usual Reminders[/h3]

Quick reminder of our new Steam Developer Page. If you follow us there, you'll be notified about any game releases we do.

Also: Would you mind leaving a Steam review for some/any of our games? It doesn't have to super detailed, but if you like a game we made and want more people to find it, that's how you make it happen. Reviews make a material difference, and like most indies, we could really use the support.

Enjoy!

Chris

v2.047 Released! "Perks By Another Mother"

Only a day later, but this is a big one! Full notes here.

What's new?
  • First off, Badger found a bug in some of the fire teams code that had been leading them to be less efficient with their forces (using overwhelming force where it was not needed). This was actually a really cool behavior in the Nanocaust, and the "Nanocaust Deathballs" are both menacing as well as fun and engaging to avoid, so we've left that behavior for them.
  • But for all the other factions and sub-factions that use fireteams... watch out! As Badger puts it: I'm not sure how impactful this will be, but the answer might be "Very", at least for any faction that had enough ships to be overkilling their targets significantly. There are lots of potential cases. Where the Hunter has just broken through a chokepoint and now has its pick of weakly defended economic planets, it's now going to be a lot scarier.
  • Next up, mobile forcefield generator ships are now a lot more useful since they no longer come with the damage penalty. This mostly helps you.
  • ...but AI forcefield generators now in general no longer have the penalty at all, for the (relatively) rare cases when they do use a forcefield. Both of these things bring this part of the game more in line with AI War Classic.
  • You can now have up to 40 ship lines per fleet, rather than 5. Also, swapping ships between fleets on the same planet no longer destroys the fleets. Your ability to customize fleets is now far greater.
  • Raiders have gotten a buff, but no longer have the one-off "super-charges the rest of their fleet" ability, since that was out of place on its own with them, and way too powerful to have on random ships you can find now that the fleets can be arbitrarily large.
  • There is a brand new structure that you can find and hack in new campaigns: the Fleet Research Station. It allows for you to get new, advanced fleet-bonus-giving large ship lines if you hack them AND pay an AIP penalty.
  • There are currently six of these types of ship lines, and they open very new kinds of play and synergies in these large fleets. If some of them seem expensive for what they are, bear in mind that you may not be considering just how impactful they can be if you have a truly giant fleet. All of these things give fleet-wide buffs ranging from the raider-style speed boost, to attack and defensive boosts of various sorts.
  • We will likely explore the concept of these sorts of fleet-wide perk-centric ship lines through FRSes more in the future, either through future free updates or in DLC, or both. But basically this gives the sort of flavor I was thinking of with what fleet EXP upgrade perks would once have given... but still minus the grind, and now with potentially even more power as well as more flexibility. You may not use these much, depending on your playstyle, but they should hopefully be the sort of thing that is a cool and incredibly helpful tool to use a minority of the time. I really enjoy mechanics like that, where they aren't mandatory for play but are things that are killer if the circumstances are right.
  • Plus some bugfixes and other tweaks!


More to come soon!
[h3]Please Do Report Any Issues![/h3]

If you run into any bugs, we'd definitely like to hear about those.

The release of this game has been going well so far, and I think that the reviews that folks have been leaving for the game have been a big help for anyone passing by who's on the fence. For a good while we were sitting at Overwhelmingly Positive on the Recent Reviews breakdown, but there have been a lot fewer reviews lately and so that has definitely had a material negative effect. Go figure. Having a running selection of recent reviews definitely is helpful, but at least we have a pretty healthy set of long-term reviews. If you've been playing the game and enjoying it, we'd greatly appreciate it if you'd drop by and leave your own thoughts, too.

More to come soon. Enjoy!
[h3]Problem With The Latest Build?[/h3]

If you right-click the game in Steam and choose properties, then go to the Betas tab of the window that pops up, you'll see a variety of options. You can always choose most_recent_stable from that build to get what is essentially one-build-back. Or two builds back if the last build had a known problem, etc. Essentially it's a way to keep yourself off the very bleeding edge of updates, if you so desire.
[h3]The Usual Reminders[/h3]

Quick reminder of our new Steam Developer Page. If you follow us there, you'll be notified about any game releases we do.

Also: Would you mind leaving a Steam review for some/any of our games? It doesn't have to super detailed, but if you like a game we made and want more people to find it, that's how you make it happen. Reviews make a material difference, and like most indies, we could really use the support.

Enjoy!

Chris

v2.045 Released! "Scientific Emergence"

Very similarly to the prior release, it's been 24 days since the last writeup (and in this case, the last non-beta build). This new version is only the fifth public build since then, though most of them were hefty and were in beta. Full notes here.

What's new?
  • First up, there is a brand new "journal" concept, which lets us put in a whole bunch of new thematic or useful text that you can find. And of course it can be used in mods. I don't personally plan to use it a whole lot, but I know some mod authors and some folks wanting to volunteer some minor lore writing have been waiting for this.
  • Chat, as used for multiplayer and for the AI talking to you, has been revamped a fair bit, since the journal-like things are no longer a part of that. It's now more efficient, and has a few new capabilities, like...
  • Cheat codes and debug commands issued via chat have been added! Am I strange for feeling like cheat codes are anachronistic in the current market? Sigh. Anyway, I've always liked having those for folks.
  • Fleet EXP has been removed, and we're no longer planning on doing the "perks" system that we've been talking about for about 2 years. Basically it was always something that could cause you to have to grind, and there are simply better ways to let you upgrade fleets and make them how you want them.
  • Speaking of, all fleets (or their flagships at very minimum) can now be upgraded directly by science. There have been some science costs rejiggered based on this, and a lot of interface additions to make this really smooth in the most recent version in particular. This basically gives you a cheap way to have the same-ish experience, but without the ability/requirement to grind for levels.
  • There's a big new "hooks" framework for mods, which we can use to talk to mods in an indirect way when they want to do something right before, during, or after key events.
  • There's an interesting new debug setting that you can enable to test some new mechanics: "Enable Astro Train Power Increase"
  • Drones of all sorts now get upgraded based on their spawner being upgraded, so they are far more dangerous than before.
  • The dyson sphere voice lines should now be played properly.
  • Cloaked and agile transports are both something you can now find in the wild in new campaigns.
  • Lots and lots of bugfixes!


More to come soon!
[h3]Please Do Report Any Issues![/h3]

If you run into any bugs, we'd definitely like to hear about those.

The release of this game has been going well so far, and I think that the reviews that folks have been leaving for the game have been a big help for anyone passing by who's on the fence. For a good while we were sitting at Overwhelmingly Positive on the Recent Reviews breakdown, but there have been a lot fewer reviews lately and so that has definitely had a material negative effect. Go figure. Having a running selection of recent reviews definitely is helpful, but at least we have a pretty healthy set of long-term reviews. If you've been playing the game and enjoying it, we'd greatly appreciate it if you'd drop by and leave your own thoughts, too.

More to come soon. Enjoy!
[h3]Problem With The Latest Build?[/h3]

If you right-click the game in Steam and choose properties, then go to the Betas tab of the window that pops up, you'll see a variety of options. You can always choose most_recent_stable from that build to get what is essentially one-build-back. Or two builds back if the last build had a known problem, etc. Essentially it's a way to keep yourself off the very bleeding edge of updates, if you so desire.
[h3]The Usual Reminders[/h3]

Quick reminder of our new Steam Developer Page. If you follow us there, you'll be notified about any game releases we do.

Also: Would you mind leaving a Steam review for some/any of our games? It doesn't have to super detailed, but if you like a game we made and want more people to find it, that's how you make it happen. Reviews make a material difference, and like most indies, we could really use the support.

Enjoy!

Chris

v2.031 Released! "Faction Color Choice"

The last release I did a writeup on was 25 days ago, an eternity. This new version marks the twelfth public build since then, although the most recent stretch were in beta. Full notes here.

What's new?
  • First up, we got GOG Galaxy support fully working, and also improved some of our Steamworks integration. Both of these are in preparation for multiplayer over (and potentially between) those two platforms. Overall we are having three options for how you can connect with people for multiplayer, and those were the two I'm least familiar with.
  • As part of this, we also finally fully got the support for achievements in GOG Galaxy in there.
  • As part of THAT, we also improved the performance of some of the achievement checks on Steam, and made it so that your offline achievements are properly stored no matter how you play.
  • The Scourge got some minor buffs.
  • The AI Reserves now announce themselves for a moment before attacking, versus just showing up out of the blue.
  • The pathfinding between planets is now smarter when you are ordering your ships around, and there are three modes you can swap your ships between (Default, Safest, or Shortest).
  • Non-scourge factions that use fireteams are now better about stacking their units (across fireteams, often), which helps enormously with performance in certain late-game situations.
  • A whole heap of quality of life improvements to the text chat window (for upcoming multiplayer), including some new UI framework bits under the hood to make that possible.
  • Techs that have already been fully unlocked now continue to show up on the tech sidebar, since having those disappear was freaking confusing.
  • When viewing the tooltip for a unit, it now shows how many upgrades have happened out of how many upgrades for each tech line that benefits the unit.
  • Lots of changes to how planets are stored and iterated-over, some of which are building toward some future DLC content as well as some future content for late-adding extra players to multiplayer games.
  • Various minor UI improvements.
  • Three new options for turning off beams of certain types under the Performance tab of Personal Settings. In certain super-lategame battles, turning off tachyon beam visuals can be an incredible performance boost. It may be to the point that we advise just turning those off in general.
  • There's a new Journal tab, but it doesn't do anything yet. Coming soon!
  • Command stations that die now come back still with any upgraded levels that you bought with science for their specific planet. It was an error that that was not already the case!
  • Ships that you have not fully claimed yet, like golems, no longer charge you energy.
  • In the escape/system menu, there is now a View/Edit Factions option that brings you into a new screen. This screen lets you edit the colors for any faction (even zombies and outguard, which never have been editable before).
  • The V/E Factions screen also lets you edit any of the settings for Discoverable factions, up until you hack their beacon. This is incredibly helpful if you decide a bit of a way into the game that you'd like a really specifically-configured enemy or allied faction of whatever sort to come in... now you can configure that rather than just getting the faction defaults when hacking them to bring them in.
  • Lots and lots of bugfixes!


More to come soon!
[h3]Please Do Report Any Issues![/h3]

If you run into any bugs, we'd definitely like to hear about those.

The release of this game has been going well so far, and I think that the reviews that folks have been leaving for the game have been a big help for anyone passing by who's on the fence. For a good while we were sitting at Overwhelmingly Positive on the Recent Reviews breakdown, but there have been a lot fewer reviews lately and so that has definitely had a material negative effect. Go figure. Having a running selection of recent reviews definitely is helpful, but at least we have a pretty healthy set of long-term reviews. If you've been playing the game and enjoying it, we'd greatly appreciate it if you'd drop by and leave your own thoughts, too.

More to come soon. Enjoy!
[h3]Problem With The Latest Build?[/h3]

If you right-click the game in Steam and choose properties, then go to the Betas tab of the window that pops up, you'll see a variety of options. You can always choose most_recent_stable from that build to get what is essentially one-build-back. Or two builds back if the last build had a known problem, etc. Essentially it's a way to keep yourself off the very bleeding edge of updates, if you so desire.
[h3]The Usual Reminders[/h3]

Quick reminder of our new Steam Developer Page. If you follow us there, you'll be notified about any game releases we do.

Also: Would you mind leaving a Steam review for some/any of our games? It doesn't have to super detailed, but if you like a game we made and want more people to find it, that's how you make it happen. Reviews make a material difference, and like most indies, we could really use the support.

Enjoy!

Chris