Purpose of the mod:
This mod addresses widespread errors in the TotA TechTree.xml files. These errors pretty much broke many of the unique TechTrees, causing the AI to pursue a deeply flawed research strategy and outright preventing the research of many techs. Part of the fix included rearranging a number of the TechTrees to fix the seemingly random arrangement of some techs and reduce the number of branches for the AI to get sidetracked on. Along the way, I ended up fixing many UP issues, planetary improvements, starbase modules, and did some general improvement and balancing on individual techs.
This mod is a direct result of MarvinKosh's Space Weapons Fix Mod, which provided the inspiration. A lot of my development commentary and good input from other modders working on their own fixes is in that topic. Thanks MarvinKosh, Quaternus, deweyjohn, TOV, foxthree, qrtxian and all others for input and support.
05-10-13: v3.51 release
Update to fix some errors in v3.5.
04-28-13: v3.5 release
Here it is, the more or less finished product after all this time. It's been about a year since I put this project down, so I'm a bit fuzzy on what exactly I did before coming back to finish it up. I'm pretty sure I've got the major things nailed down, though. Let's see:
TechTree Fix v3.51 with Dumb Old Minors: I did nothing to the minor races here. If you want the same dumb minors you've always known and loved, this is the mod for you.
TechTree Fix v3.51 with Smart Old Minors: Same old minors that still won't colonize, but I added code to make them play to the best of the AI's ability. I gave them respectable descriptions, modest bonuses, and changed out the silly race images to reflect their upgrade. Since they can't colonize, they'll send out a bunch of freighters and actually send constructors to grab up a lot of the resources while the majors are still colonizing. They still get slaughtered when it comes down to it, but I've had fun watching them. It's also interesting to see the majors make a ton of regular starbases since there are fewer resources to grab.
TechTree Fix v3.51 with MoOII Minors: The MoOII minors in this mod will colonize and behave pretty much like weak majors. Much larger than the other mods due to the RaceImage and RaceLogo files. If you try this mod, remember to use the "quick save fix". That is, the minors won't start behaving like majors until you save and reload. So, start your game, quicksave, reload, and enjoy.
TechTree Fix v3.51 with MoOII and Smart Old Minors: Why not? If you want a little variety, I packaged up both versions of the minors in one mod. Your minors could be one, the other, or a mix of both. Still be sure to use the quick-save fix, or your MoOII minors won't play nice. I haven't tested this arrangement, but I can't see why it won't work. (famous last words.)
03-04-12: v3.0 Release
v3.0 continues the work, this time focusing on starbase modules and planetary improvements, particularly Galactic Achievements, Super Projects, and Trade Goods. Also included is a wonderful conversation mod, kindly contributed by qrtxian. His mod fixes the errors in the GC2_Conversations.xml, so now you can enjoy all the unique dialogue as intended.
Highlights
I think that's most of it. Without further ado, here it is:
TechTree Fix v3.0 with Dumb Old Minors: I did nothing to the minor races here. If you want the same dumb minors you've always known and loved, this is the mod for you.
TechTree Fix v3.0 with Smart Old Minors: Same old minors that still won't colonize, but I added code to make them play to the best of the AI's ability. I gave them respectable descriptions, modest bonuses, and changed out the silly race images to reflect their upgrade. Since they can't colonize, they'll send out a bunch of freighters and actually send constructors to grab up a lot of the resources while the majors are still colonizing. They still get slaughtered when it comes down to it, but I've had fun watching them. It's also interesting to see the majors make a ton of regular starbases since there are fewer resources to grab.
TechTree Fix v3.0 with MoOII Minors: The MoOII minors in this mod will colonize and behave pretty much like weak majors. Much larger than the other mods due to the RaceImage and RaceLogo files. If you try this mod, remember to use the "quick save fix". That is, the minors won't start behaving like majors until you save and reload. So, start your game, quicksave, reload, and enjoy.
TechTree Fix v3.0 with MoOII and Smart Old Minors: Why not? If you want a little variety, I packaged up both versions of the minors in one mod. Your minors could be one, the other, or a mix of both. Still be sure to use the quick-save fix, or your MoOII minors won't play nice. I haven't tested this arrangement, but I can't see why it won't work. (famous last words.)
Update 01-07-12: v2 Release
After nearly a year, here it finally is. Details can be found in this post.
v1.1 Notes:
I'm sad to report that not only are your findings correct, but my suggested fix doesn't work. I broke the StarbaseModules.xml into two separate, roughly equal files. Then I put Starbase Defenses (my new defense module) at the bottom of the regular one and Battle Stations at the bottom of the one in the mod folder. Just for confirmation I gave everyone the Drengin Industrial Starbase techs. They used the Mining Matrix and the Starbase Defenses, but nobody used Battle Stations.
This is a sad discovery, indeed. I added quite a few attack, defense, and assist modules. I guess now I have to determine how many modules need to be cut out. I think the first thing I might do is put all the culture modules at the bottom and see if that works. The AI doesn't really use culture bases very well, anyway. It probably won't hurt - and actually might help - if they didn't use up any constructors on those modules.
Sigh.
No prob on the Influence bases, Tolmekian, glad to help. Too bad that it looks like distributing the cost of modules among more levels might just break everything more .
Fascinating issue with starbase modules; I can't imagine how that was never caught in production, nor how an XML parser could possibly have limits. The only thing that comes to mind is some fixed-sixed container inside the program for starbase modules; if that is the case, no amount of rearrangement will help since there simply will not be enough room.
However, it is more likely something weird on the interpretation of the XML in the first place, since I can't imagine anyone using a fixed sized container for storing objects that are sucked out of an XML file. In which case cutting the xml up may work; it seems iffy to me. Maybe culling the herd with starbase modules could be a good thing; fewer options, clearer decisions for the player and AI. You could save some with Battle Stations a bit, since it seems like something intended to make your initial starbases resilient enough to survive the first attacks when you don't necessarily know what kinda of damage you'll get thrown your way. Forcing the player to make more trade offs may make the strategy more engaging.
Here's a crazy question: does anyone know the order available modules appear in on the starbase upload screen? Because it is possible that when the AI says "I want to install a module" it gets the same list as the one we see in the GUI. If that is the case, what if the AI can only see the first, say, 2 modules on that list for whatever reason? That seems like a more likely coding error. If it decides to install neither of those 2 modules, then it will stop upgrading a starbase even when there are modules it would choose to install. If the modules appear in the order they appear in the XML, then that would cause ordering effects too that might look like a limit to the number of modules it can see over all, but really has to do with the number of modules it sees when it upgrades. Let's hope it isn't that problem, because there isn't anything anyone can do about it .
I wish I could provide more concrete help, but my modding project at the moment is polishing the graphics; the shader code is out in the data files, so I've been working the graphics calculations over and editing the textures to match the new rendering methods. So my testing time is devoted to pretty pictures and not gameplay.
Is it possible this is related to the UP decision restricting starbase module quantities, and the AI is making decisions based off of that even when it's not in effect? And misapplying it, apparently.
In other words, how many modules do you see the AI make use of?
LZ, you're suggesting the AI doesn't have a scroll button? That could also be the cause...but it definitely seems iffy. If done properly, the AI shouldn't -need- a scroll button.
Well, I've been trying your idea and had the same result as you. It was worth a try.On the bright side, I had success in finding the limitation. I moved the 'Mining Collectives' back to the end of the file and began to remove modules until the Yor were using all of the 'Collectives'. This happened when I reached line 1104. Then, just to be sure, I gave all modules a Tech_Requirement, Module_Requirement and ModuleCost entry. This added another 32 lines, but had no effect ingame. Only when I was adding another module to the file were the Yor stopping to use their last 'Mining Collective' module.So, I am safe to say now, that the line count doesn't matter at all. It is the amount of modules. To be exact: the AI can only register 100 modules. This number seemed oddly round to me, so I counted again two more times. Still 100. The more I think about it now, the more I believe this might not be a bug at all, but intentional. Maybe a leftover from GalCiv I. In any case, it severely hampers the possibility of new modules, if you want the AI to use them to.To that end, I began taking a closer look on how the AI was fitting out it's starbases:- Sensor Modules and Terror Stars are never used. Terror Stars were no surprise, but you would think the AI used Sensors. I have seen it adding Sensors to ships but never starbases. So, those modules can safely be moved beyond the first 100 modules.- Trade and Culture Modules are used rarely. The AI only uses them if it thinks, that it is necessary or advantageous. And even then just sparingly. The current number of Trade Modules (5) is fine, but the Culture Modules (17) make up an significant amount. It would probably be a good idea to reduce their number, while increasing the power and cost.- Military Assistance, Speed Assistance and Slow Enemy Modules are being used. If the AI decides to build a Military Starbase, it will definitely add Attack Assistance Modules. Defense Assistance, Speed Assistance and Slow Enemy Modules will eventually be added, too, but take a lower priority. The Military Assistance Modules (28) take up a huge portion already in the un-modded game, so it would be wise to reduce their number, too. The number of speed related modules (4) is fine.- Mining, Production Assistance and Defense Modules will always be used. The AI tries to maximize the mining and production bonus as fast as possible, while adding defenses to all of it's starbases (except Influence). The Defense Modules (31) take up the biggest portion in the stock game, so they should definitely be reduced. The Mining (17) and Production Assistance Modules (15) could potentialy be reduced.- I'm still uncertain if the AI uses the Hull Repair Module, so it would probably be wise to leave it at the end of the 100-limit, just in case.I hope this information is helpful to you.
I can confirm from my own test games that AIP7 works incredibly well on maps with a high habitual planet density.
Dumb question but have you guys tried to ask the stardock people for help ?
No, I'm not. The AI is going to "see" a data structure of some kind when it looks at what modules it can install, and I was suggesting that it was possible that some scrap of code somewhere unintentionally limits the number it can look at at any one time. Also, it isn't working as intended, so clearly the AI or somethign else isn't implemented 100% properly .
Gaunathor has proved this possibility wrong, it would seem, and a reduction of modules is in order.
enieraew37, my experience in modding tells me that might be fruitless, though the Stardock guys do seem really cool. There are a whole bunch of variables in that equation, though: how many of the original team are still at Stardock? Do they know about these bugs? Do they still have access to the codebase? Are they authorized to make a patch? Do they have the time to make a patch for a game they haven't been waste-deep in the guts of for two years? If they can't make a patch, do they have time to dig up the code and devise a work-around out in data-space that will prove effective?
They certainly would not get paid for their trouble, and I don't want to paint them in a bad light, but I can smell GalCiv II's code's stink every time I delve into the datafiles. GalCiv II is a great game, but it has and will always have issues. I only hope that if, or when, they get around to GalCiv III they've learned a few things, but Bethesda has gotten away with four bug-ridden games on the same engine and still makes awesome stuff. Lastly, there is the fact that there is something rewarding about finding the limitations of a game and working around them, making it better. It's part of the modding challenge. Working on the shaders is the same way, since I have very hard limits on the input data I can work with.
I'm talking too much, and it threatens to derail this investigative thread. I'll try to start a topic for my graphics polishing at some point.
Heh I was just thinking to go to them for answers to your question about the modules..not a patch It might be fruitful to program up a spam bot or whatever to get their attention. Certainly doesnt seem like they are reading their own forum.
Alrighty, then. My mod has 149 starbase modules. Looks like I have some work to do.
While you're at it, you might want to take a look at a few things I noted in your mod:1. The 'Interstellar Navigation'-Techs are twice in the TechTree.XML. First, right after 'HyperDrive' and then a second time after 'Advanced Battle Stations'.2. Some leftover Stardock-Bugs:
- The 'Xeno Influence Module' has 'Insurrection Coordinator' as a requirement, but the Thalans don't have 'Cultural Insurrection' in their Tech Tree. - The planetary improvement 'Planetary Defense' is missing the line <PlanetaryDefenseBonus>25</PlanetaryDefenseBonus>. Without it, the improvement doesn't do anything. - The line <PlanetaryQualityBonus>x</PlanetaryQualityBonus> from 'Soil Enhancement', 'Habitat Improvement', 'Terraforming' and 'Gaia Vortex' isn't doing anything. It is most likely leftover code from GalCiv I. This isn't much of a problem, except for 'Gaia Vortex'. I suggest replacing it there with <PlanetQualityChange>x</PlanetQualityChange>. - The query graphics for 'Shrine of the Mithrilar' and 'Manufacturing Matrix L3' are not working because of a typo. Replacing the entries with 'ShrineOfTheMithralar.png' and 'SymbiosisPlatforms.png' fixes this.Thats it for now. I might have some suggestions later, but for the moment I have to work on my own mod. The Terrans are slaughtering everyone, while the Arceans are getting slaughtered by everyone. I really have to look into this.
Thanks for the info.
1) Looks like a cut-and-paste that was light on the cut.
2)
- Xeno Influence already fixed for v2.1
- Planetary Defense already fixed in v1.1. Not sure how it's coming up wrong for you.
- PlanetaryQualityChange for the Gaia Vortex is huge. Thanks.
- I was just wondering about those query graphics. The Altarians build the shrine quite often and that black square was a bit . . . disturbing.
Please keep it up if you can. Maybe, just maybe, someday all the bugs can be cleaned up.
PS - It was pretty easy to find 50 starbase modules to put "below the line" simply based on observations of which modules the AI never uses. The high end modules virtually never get used by the AI because by the time they research that far, they are well past the point of building constructors.
This makes me wonder - could the AI actually use Terror Stars if they were brought below the 100-module limit? I suspect not, but it might be worth trying to find out.
You're right. Must have overlooked the line. Sorry.
I already tried that. Didn't work.
Empirically, it seems to me that the races are avoiding offensive technologies and always going for defense as soon as that tier opens up. This happened in both games I've played with this mod. It may be that the artificial increase in the costs of weapons techs are important; they keep the AIs from going at weapons techs too fast and ruining the opening of the game. Maybe they're like a hidden balancing factor that compensate for weapons techs and defense techs at the same tier having the same cost.
I'm not sure if I understood you there correctly. You're not keeping the value at 10, are you? PlanetaryQualityBonus is a Percentage Bonus. A value of one or two would be enough. Otherwise, 'Gaia Vortex' would become the most powerful GA in the Universe.Some more leftover bugs I completely forgot:- 'Terraforming' is missing the query graphic entry. 'TheTerraformer.png' would be fitting.- The first module in the 'Xeno Business'-line, 'Interstellar Consortium', requires 'Interstellar Embassy' from the diplomacy-line, while the second one, 'Franchise Center', has no module requirements. The dependency on the diplomacy-line for 'Xeno Business'-modules might not be a bug. The missing module requirement for 'Franchise Center', though, most likely is.- The 'Warfare Tax' UP proposals are supposed to be a percentage but deduct the voted value as a flat number (i.e. a 20% tax will be 20 BC, no matter the income).- GC2_Conversations.xml and FlavorText.xml have a lot of errors, preventing text from showing up, dialog never appearing and a lot more. There is a mod already that's trying to fix this, but it isn't complete and the author added dialog of his own, which might not be for everyone.
Fixed this in my own mod, though it's not uploaded anywhere.
I was talking about this one: http://www.i-mod-productions.com/downloads.php?do=file&id=171
Actually, I was going to keep it at 10. I was figuring that since the Arceans and Altarians (and Drath?) already have one-per-planet improvements that increase PQ by 3, the Gaia Vortex would have to be something special. On second thought, 10 may be a bit extreme. At least 3, but maybe 5, is my thought right now. Also, it looks like PlanetaryQualityBonus is leftover from Dread Lords.
-The Terraformer is the new Gaia Vortex, so something else I guess!
- Well, as part of my work to meet the 100 module limit, I nixed the whole line of diplomatic modules and removed the requirement for Interstellar Consortium. Thanks for the info on Franchise Center, though. I'll have to add a requirement there.
- Interesting to know about the warfare tax. I'll have to edit the description and maybe tweak the values to be more significant.
- Conversations and Flavor. Ugh. Something I haven't even begun to dig through. Low on the priority list, though. If I ever do get around to it, I'm more likely to add stuff for custom majors than to go back and clean up the mess.
Thanks again!
I know about that, but like you said, it's not for everyone - I was saying that, while it's not currently uploaded anywhere, I do have a mod that simply brings back all the missing dialogue, complete and without additions.
If you would be willing to share, I'd be happy to package it with the TechTree fix mod. With appropriate credit given, of course. It would be a nice addition and help to bring the game closer to "completion", as far as we are able.
I understood that. Sorry, for not being clear. I would greatly appreciate it though, if you could upload your mod.
You're welcome!
I'm not sure that is such a good idea. The Drengin, Korath and Yor have only access to those modules. This would make Influence Starbases useless for them. But then, the Korath (Dark Influence) and Yor (population) don't really need them that much.
Also: Some more testing showed, that my statement regarding Speed Modules was wrong. The AI does use Speed Assist Modules, but it doesn't use the Slow Enemy Modules. Maybe it will if the enemy uses more engines, but I'm not so sure about that. I also forgot the Speed Assist Modules from the Korx and Thalans in my counting.
I realized that after posting. At first I thought the Xeno Business techs would be enough, but then I realized that a number of races don't have those. Now the diplo modules are back in, but they're below the line. As of now, I think I'm ok with that. In my experience, the AI makes pretty lousy use of influence starbases. So, if they use the extra constructors to upgrade military, mining, and economic bases I figure it would be a net bonus for them. Heck, even if the put weapons and defenses on their influence bases it would make them more useful simply to repel invaders.
Interesting about the AI not using Slow Enemy modules. I put all the speed assist modules below the line, but left the Warp Disruptor above it. Guess the Warp Disruptor can join them, now.
By rearranging the modules, I've seen some evidence that the AI tends to go for modules higher up in the list first. Not always, but there's a definite tendency.
All that said, I think v2.1 is ready for release. Well, I need to package the different types of minors, but that's it. Oh, and I'm waiting on qrtxian's reply.
Quite true. But I have yet to see the AI adding weapons to an influence base.
BTW, I've been currently testing your idea regarding trade in my mod. I increased trade only by x5, because x10 seemed a bit much. It still provides more than enough money per route.
In one of my testing games the Altarians started right next to the Korx and the Korx were sending two freighters before they even had build a colony ship. I was quite surprised by this. This surely provided them an enormous boost to income, but they still lost in the end because they couldn't get enough planets.
More tests with the Korx showed, that this was a common problem for them. They regularly preferred to build freighters at the expense of colony ships, even if they couldn't reach the other races, thereby lost the colony rush and the game. Apparently, they regarded trade a little to high now. So I began to tweak the numbers a little.
After a little testing I found out, that a starting value in trade of about 300% still allows the Korx to take part in the colony rush, while keeping them interested enough to make full use of trade routes later. They even fully outfitted their economy bases with trading modules. The tech description of the Korx' 'Super Trade Bases' mentions a doubling of the revenue, so an increase to 100% seems appropriate.
Now, I still have to find out how to prevent the races from wasting their time with researching the fleet module techs. Even setting the ID to Biology and the category to Colonization didn't help. Not even with the AIP 8 races. They just keep on researching. I'm really about to scrap those techs, if I can't find a way soon.
Oh, the AI will arm influence bases just fine. Now that I think about it, maybe it's because I brought all my weapon and defense modules above the culture modules. They do add both, though.
Thanks for reminding me about trade. I was seriously considering dropping it down to 5x (+50% instead of 100%). It will be one of my finishing touches. It's too bad about the Korx. Super Trader is nice, but it has a downside.
For the fleet modules, I think I have a way. While fixing the TechTree, we found many techs with broken categories - typos and whatnot. I took a cue from that and assigned them a category of "null" and an AIValue of 0. That worked pretty well to ward the AI off, but some of them still researched the first offensive fleet module and one or two terror star techs. I took another step and changed them to Defenses ID. I haven't fully tested it, yet, but the AI needed special coaxing to research defense techs. Maybe see if it works for you.
That's strange. They never did in my games and I have the defense modules above the culture ones, too. I'm going to take another look. Maybe it just needs some rearranging.
It certainly is ironic that by making trade more powerful, Super Trader really starts to suck. At least in the hands of the AI.
Thanks, I'm going to try that.
I had already set the AIValue to 0 and tried several different ID and category combinations, but using a nonsensical category never crossed my mind. Sometimes I'm really missing the obvious.
There are many great features available to you once you register, including:
Sign in or Create Account