1. AI War 2
  2. News

AI War 2 News

Beta 3.750 Smooth Simulator

Ho. Le. Mo. Le. Wheeew, new build: https://wiki.arcengames.com/index.php?title=AI_War_2:The_Great_Refactor#Beta_3.750_Smooth_Simulator

This one rips up the entire threading model that we've been evolving for the game since 2016, and replaces it with something more modern, as well as fixing a number of threading-related bugs and other issues. The TLDR is that it's faster than ever, especially on older computers, and it works REALLY well and is way easier for myself and others to debug, too.

The game was downright unplayable for the last few weeks in terms of things like stalled threads and a bunch of cross-threading issues. I've been really tearing my hair out, trying to figure out what on earth was going on, and simplifying code, simplifying it further, and lots of experimenting. Daniexpert really gets MVP once again for truly excellent help with bugtesting and reporting in this arena.

Special thanks also to tom.prince, who had lots of great ideas and commentary on the threading model and things that we'd have to consider. There were several cases where I was going to do one thing, and chatting with tom on discord let me skip a few steps of pain and jump to a better solution.

There's also a bunch of other improvements in here, and various features for DLC3. I am extremely weary, though, so I'm not going to enumerate all of them. I thought I'd be done with this threading thing days ago, and then I started wondering when on earth I'd be done with it at all. Very happy to say it seems to work well now, and if there are remaining problems, they will be much easier for me to debug.

Tomorrow, it will be time to move on and work on other bugs and features that have been delayed by this whole mess. I think this was first on my radar on October 27th, maybe a bit before, so this was QUITE a diversion. The release notes have pretty much the whole story, and the chris-talks-code-gameplay discord subchannel has the rest of it, if you're curious.

More to come soon.
Enjoy!

Beta 3.746 Phantom Ship Syndrome

New beta! https://wiki.arcengames.com/index.php?title=AI_War_2:The_Great_Refactor#Beta_3.746_Phantom_Ship_Syndrome

This one has a toooon of bugfixes. Some of these are fixes to regressions in the prior build, of which there were an uncomfortable number. An amusing one was causing lots of phantom icons to spring up all over the place, in this kind of insanity kaleidoscope. Others were just error spam. These were a result of my improvements to the collections to lazy-initialize, and there were some edge cases in a couple of them that I did not properly account for. That's fixed now.

Hey, also there are several features that had been "DLC3 while testing" that are now part of the base game. Roguelike features like Hidden Galaxy, and then the new Border Aggression feature.

There's a large class of exceptions based around "someone changed a thing on the unit and we're looking at it belatedly and now it's null and time to throw an exception." Those are all fixed, because we no longer allow them to be nulled out. That led to some interim internal hilarious bugs with scaling and stats being off, but now it seems to work fine, knock on wood. So this is a pretty large category of stuff that no longer will break anywhere in the codebase.

There were some pathfinder errors that could still pop up, although these were new ones. These are now fixed. They MAY have been related to thread timings, but I'm not sure. Either way, I made some changes to make them more robust in their defenses, and that seemed to work.

Another big group of bugs were some "invisible dead ships" that would hang around on planets, sometimes with a full forcefield showing, and then also appear on the galaxy map. I am not sure why exactly that started happening, but I have it so that it self-repairs properly now. Most ships don't properly explode on death anymore (but their icons still do), so that's something else I need to fix next week.

Last major known issue that really impacts play lately is the stuck threads issue. I've made some progress on that, in large part due to Tom and in particular Daniexpert doing some debugging. I've corrected a few of the most major cases, and then there's a couple of remaining cases that I now have a pattern for reproducing, and will start chasing down on Monday. In the meantime, as long as you don't reload the game too too many times, it seems to work fine. Or if it's messed up and you reload one more time, then it also fixes itself. I don't think pausing and unpausing works anymore. But overall if there are behaviors you see, or other ways to get it to mess up, then I'd love to have that information.

Hopefully after a lot of these things, code will kind of start settling down. I still have one major piece of surgery, which is to take the necromancer away from being its own faction and to instead be a faction type for humans. That will probably be some bugs. And there are still other known issues like the xml reload locking up (though I need to retest that actuallly), and tutorials and beacons not being re-enabled yet. But a lot of the biggest, scariest things seem to be slowly settling down. Or we're just through the first batch and about to discover a giant new cache of new ones, who knows. Hopefully not.

More to come soon.
Enjoy!

Beta 3.745 Deadlock Removal

New beta build! https://wiki.arcengames.com/index.php?title=AI_War_2:The_Great_Refactor#Beta_3.745_Deadlock_Removal

This one has a lot more going on under the hood than might be apparent on the surface. It's more efficient in how it allocates RAM (which you can see in certain logs mainly), and it is also safer in how it allocates that RAM (thus avoiding some deadlock situations that I had introduced in the last few weeks). So that's very pleasing, but not exactly a marquee feature for people playing. Deadlocks are a special sort of bug that I particularly hate, though, so I'm glad to have it gone.

While I was doing that, Tom has added a new cheat (grantalltechs), and a number of ui improvements and bugfixes.

For DLC3, Zeus has been adding yet more orbital stuff, and the DLC3 testers can now properly test that, too. These orbital bits are suuuuper cool. There's also a new general rare "nasty pick" that is an orbital inertial battery. Playing with DLC3 simply enabled is one of those things that won't make the game harder (that's always important), but just like DLC1 makes it so that there are so many more turret types all over the place (thanks to Democracy and Puffin), DLC3 makes things come alive more with various orbitals here and there even amongst non-orbital AIs.

The galaxy-wide caps are now properly shown thanks to Tom, and Zeus made the super fortress a lot more super.

More to come soon.
Enjoy!

Beta 3.744 Pathfinding

New beta build, lots of fixes once again! https://wiki.arcengames.com/index.php?title=AI_War_2:The_Great_Refactor#Beta_3.744_Pathfinding

One of the most annoying issues lately has been "pathfinder errors," and it turns out they were a source of memory leaks, as well. And also just some general performance degradation, and over-use of RAM. I've done a massive refactor on it, and it now uses literally multiple orders of magnitude less data, which is great for everyone. It's not super well tested yet, but it seems to work from what I can tell so far.

There's a new issue where if you try to do the F7 dump prior to the first time you load into a game, and then load into a game, it locks up. No idea what that's about, but it's on my list for soon. The number of truly severe issues seems to be dropping, which is good, and at the same time we're getting into a position where performance is able to be better than ever before.

I also made a new... kind of complicated to understand, but easy to use... data structure called ThreadStaticWrapperedPooledItem. This funky thing lets us use the magic of the ThreadStatic while not having collections and other large portions of data orphaned on threads that are no longer using those items. Over time, I'll likely convert even more things to using this rather than just directly using ThreadStatic collections. It should be a notable improvement in memory usage, without any extra CPU cost during normal operations. This thing is one of the strangest pieces of code I've written, but despite that it is something I'm really pleased with because of just how effective it is.

Tom fixed a whole bunch of other errors in this release, including notifications not showing up properly in the prior version (that was an oops on my part). Lots more excellent bug reporting and narrowing-down of issues from Daniexpert, saving me and others a huge amount of time. Seriously, I'm so grateful to our testers, Daniexpert most of all recently.

Badger is continuing to improve the Elderlings in DLC3 for those testing that, and Zeus has made some very exciting further improvements to the new Orbital AI type in DLC3 (it's one of the most surreal AI types we've ever had, and an instant favorite for me).

Tom also added a number of quality of life improvements to various parts of the UI, which is very cool!

Tomorrow I'm hoping to knock out the strange "ships are showing when they should not be" bug and a number of other things. This pathfinder issue was always going to be a huge time sink, but I'm glad to have it done. And the new ThreadStaticWrapperedPooledItem is a new power tool that I can start strategically using anywhere else where we start seeming to have too many allocations over the course of many game loads.

More to come soon.
Enjoy!

Beta 3.743 Return Of The Imperial Spire

New build, tons of bugfixes and improvements: https://wiki.arcengames.com/index.php?title=AI_War_2:The_Great_Refactor#Beta_3.743_Return_Of_The_Imperial_Spire

We're getting closer to having stability, but not there yet. Fallen Spire, on the other hand, seem to be pretty much returned to their former glory thanks to Tom, and the main things missing now are the final bolstering interface and then the new modular stuff.

NR SirLimbo continues to work magic on the technical front, adding many new options to how outguard can spawn things, which is quite exciting for modders as well as the DLC developers.

Brutal Lair is a little less brutal, thanks to Badger toning that down.

A lot of new cool things to test if you're in the DLC3 beta, related to Necromancer start options, the Elderlings being better and more interesting, and so on.

More bugfixes and hardening of code and other general refactors and improvements from me, and from Tom, and from Badger. Some balance tweaks and fixes from Zeus and CRCGamer. Daniexpert continues to be a super help with the debugging of things like serialization issues, etc.

It's coming along, and more is coming soon.
Enjoy!