Author Topic: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)  (Read 7372 times)

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #30 on: March 18, 2010, 04:56:06 pm »
Hmm, must have been a combination of game state size and available memory on your computer, but I'm guessing your available memory wasn't abnormally low (any idea what it was?), and my concern would be that the game state was artificially big.  Though if this is the same game you've posted reports from previously it was pretty big.  Do you have an autosave or something from pretty close to the time of the problem?

Also, did it crash, or did it somehow garbage collect, recover, and let you keep playing?
Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #31 on: March 18, 2010, 04:57:35 pm »
His physical memory is not all that relevant, as it will cap out at 2gb, being a 32bit program.  Memory fragmentation is a big risk if this game has been in process for a long time, and is super huge to start with.
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #32 on: March 18, 2010, 05:00:17 pm »
Ah yes, I was thinking if the physical memory started lower than, say, 3GB it could be that the actual available to the game was less than the 32-bit limit.

How long was that particular play session?  If it was hours and hours memory fragmentation would make sense, if it was relatively fresh from loading that would be a bit different.
Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline Draxis

  • Jr. Member Mark III
  • **
  • Posts: 95
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #33 on: March 19, 2010, 02:38:56 pm »
The game crashed out completely.  I am on vista 64, with 4Gb of RAM.  The game was probably running for an hour or two on the 120 planet map I had been on.  I have an autosave from about 10 minutes before the crash which I will be returning to when I can.

Isnt one of the perks of .NET that you dont have to deal with memory fragmentation?  If the GC cannot get enough consecutive memory to meet the allocation request, it performs a full GC heap collect, compact, and retry before throwing the exception.  Unless you have some unmanaged components in your application that are making allocations the GC cant touch, the only problem you have with memory is from handles you forgot to free or pinned memory.

Have you tried making the exe large address aware?  This would give you a 4Gb address space to play with on 64bit systems.

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #34 on: March 19, 2010, 02:45:29 pm »
Anything that touches DirectX or otherwise winds up with a lot of unmanaged components in use in the same memory space.  Over enough time, that can lead to fragmentation.  Memory fragmentation is also a known issue with .NET when there are certain "global hooks" in memory on the client machine.  For instance, MSN messenger apparently can cause severe memory fragmentation in .NET programs simply by being running on the client program.  Thankfully, that's evidently a pretty rare exception.

AI War was originally able to run on 32 or 64 bit systems (in alpha versions), but that caused numerous problems in terms of multiplayer desyncs, and even including performance differentials based on ints and longs and such being differently sized on the 64bit version.  Even the Microsoft classes, such as Stopwatch, have fairly extreme performance differentials between the 32bit and 64bit versions.  And lastly there is the issue of other outside PInvoke calls such as for ogg playback, which has to have separate versions for 32 and 64 bit uses.  The whole thing was a big mess for a performance-critical application that requires simulation determinism cross-hardware, so we went exclusively 32bit instead.
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #35 on: March 19, 2010, 02:55:04 pm »
Chris, there's a /LARGEADDRESSAWARE flag for the c++ linker that supposedly lets a 32-bit app access 4GB on a 64-bit machine.  I'm not sure how to set it on a c# project.
Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #36 on: March 19, 2010, 02:58:15 pm »
Ah, here we go:

http://connect.microsoft.com/VisualStudio/feedback/details/93771/net-compilers-should-support-a-largeaddressaware-flag

Basically there's a post-build hack workaround but officially microsoft does not support making a c# 32-bit assembly large address aware.  So that could be a reliability problem.
Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #37 on: March 19, 2010, 02:59:51 pm »
Very interesting.  Does look like it might lead to various problems, though, as you say.
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline Draxis

  • Jr. Member Mark III
  • **
  • Posts: 95
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #38 on: March 19, 2010, 05:50:35 pm »
I figured I would give the large address switch a go, since I was getting memory problems after and hour again.  It wasnt catastrophic, but as soon as I got around 1.5Gb allocated (what seems to be the danger zone), the view in game constantly moved to the top left, like I was holding down the up and left cursor keys.  It didn't crash like I expected, but it wasnt playable :p

Its an unlikely situation I guess, the 120 planet map has gone on way too long (just broke 30 hours) due to some bad tactical decisions I made early on, but it shouldnt be long now, I have paths to the level 4 systems bordering the AI homeworlds, just 10K core ships to chew through and I am there.  I just wish I could get rid of the hive golem I have, repairing that thing has been the biggest mistake of the entire game!

Offline Draxis

  • Jr. Member Mark III
  • **
  • Posts: 95
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #39 on: March 19, 2010, 06:04:36 pm »
Also, I realised that I have not had a single CPA turn up in the entire game.  I get the warnings, but once they expire no ships go on the offensive.

Save Game - Start of a CPA

Offline Doddler

  • Sr. Member
  • ****
  • Posts: 287
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #40 on: March 20, 2010, 01:58:18 pm »
I love the new AI modifiers.  Having them both enabled changes the feel of the game substantially.  Interestingly the 'ships attack from AI worlds' balances out the impossible unannounced waves, because it makes it again so that you can still prepare for them.  With both on it doesn't necessarily make it too much harder if you're good at scouting and protect your back a little, but it takes away that scripted pre-planned feel of the AI.

There's a couple of points I wanted to bring up about it.

- You can still tell how many ships are going to be incoming by the number listed under wave.  I think that it should not show you the wave number if unannounced waves is on.
- Presently the top left alert box is gone, but I hear that a better implementation is forthcoming.  You can still tell a wave is coming because of the wave announcement sound.  Perhaps if the notice still existed but did not tell you the who what and where.  Like 'Intel suggests the AI is planning on launching an offensive'.  More cruel would be not to give any warning until the wave has actually occurred, but the player should still be notified of an attack, even if it occurs the moment the notice is given.
- I think you still need some warning about cross planetary attacks.  At least, if you want to be fair.

A couple questions about this mode too.

- Does destroying a warp gate prevent the AI from launching an attack from that system?
- How do wave multipliers work when the AI launches waves from its own systems?

Offline keith.lamothe

  • Arcen Games Staff
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 19,505
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #41 on: March 21, 2010, 12:48:59 am »
- You can still tell how many ships are going to be incoming by the number listed under wave.  I think that it should not show you the wave number if unannounced waves is on.
Yea, I intentionally left it as is to see if people thought it should stay, but I'm leaning towards taking it out... *sound of power tools and clattering metal* ... ok, out for 3.085 :)

Quote
- Presently the top left alert box is gone, but I hear that a better implementation is forthcoming.
Yea, it's been added back with non-wave warnings for 3.085.

Quote
You can still tell a wave is coming because of the wave announcement sound.
Yea, I had left it in for atmosphere but either it should give an alert visually or it shouldn't give one at all so there's not an artificial reason to keep sound on, fixed to not play if no-wave-warnings is on in 3.085. 

Quote
Perhaps if the notice still existed but did not tell you the who what and where.  Like 'Intel suggests the AI is planning on launching an offensive'.  More cruel would be not to give any warning until the wave has actually occurred, but the player should still be notified of an attack, even if it occurs the moment the notice is given.
I think I'll flesh out the "planets currently under attack" display to make it easier to tell when a new assault is starting and to go to a planet under attack.  That could take a while, priority wise.

Quote
- I think you still need some warning about cross planetary attacks.  At least, if you want to be fair.
When it comes to these two AI modifiers fair is the least of my concerns ;D  But if the people wanting these options want to get CPA warnings, the change could be made.

Quote
- Does destroying a warp gate prevent the AI from launching an attack from that system?
With Cross-planet-waves on warp gates are apparently more or less irrelevant, because it's just using the logic it normally uses when it doesn't have any warp gates adjacent to or on one of your planets.

Quote
- How do wave multipliers work when the AI launches waves from its own systems?
Hmm, I think it just uses the modifiers that would apply if sending the wave to the planet that they actually spawn on, so this would make a border ZPG much easier, for example.  I'm willing to call that a fair tradeoff, but if folks want maximum brutality I could perhaps convince it to add in the wave modifier of the nearest human system or something.
Have ideas or bug reports for one of our games? Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!

Offline superspeck

  • Newbie Mark III
  • *
  • Posts: 37
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #43 on: March 24, 2010, 12:38:27 pm »
I thought so too but wasn't sure what color to use.  Could go back to the red/orange of other beam weapons, I suppose.

Could. Could also use a shade you haven't used before that's relatively easy to discern, like pink, purple, yellow ... or you could come up with some new visual effect like a "travelling" beam; make a laser blast sprite longer and change it's color, or put a concentric ring about the blast, or stutter the blast like a progress bar's action -- there's lots of things that shouldn't be too difficult to throw some code in for besides just changing the color. Check out Cliff/Positech.co.uk's GSB for some ideas. ;)

Um, unless there's some reason in code that this is a bad idea. I realize that your attention is focused elsewhere.

Offline x4000

  • Chris McElligott Park, Arcen Founder and Lead Dev
  • Arcen Staff
  • Zenith Council Member Mark III
  • *****
  • Posts: 31,651
Re: Prerelease 3.084 (2 New AI Mods, Balance tweaks and bugfixes)
« Reply #44 on: March 24, 2010, 12:48:25 pm »
Those sort of visual effects (rings and such on sprites, etc) are something that aren't possible with the sort of line drawing we are doing.  They require some form of texturable lines, which is complex in all sorts of ways.  That's something we're looking at in Unity (not for AI War yet, but maybe someday), but with raw DirectX it's not very feasible.
Have ideas or bug reports for one of our games?  Mantis for Suggestions and Bug Reports. Thanks for helping to make our games better!