Sid Meier's Civilization VI

Sid Meier's Civilization VI

1,956 ratings
Real Strategy (AI)
8
9
4
2
12
11
4
4
2
7
3
5
4
2
2
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
1.074 MB
6 Jan, 2019 @ 3:22pm
5 Aug, 2023 @ 3:29pm
23 Change Notes ( view )

Subscribe to download
Real Strategy (AI)

Description
New version 2.3.1 as of 6.08 - AI should build Walls.

The mod is currently being updated. I will try to address suggestions and fix problems reported since v2.0. Contributions in various forms are welcomed. Please contact me via GitHub.

Different approach to make the AI better, a mixture of Lua "thinking" and tuning of AiLists.

CivFanatics[forums.civfanatics.com] GitHub[github.com]

Before you start
- Real Strategy (RST) works with vanilla, Rise and Fall, Gathering Storm and all DLCs, in any configuration. However, please note that it is balanced for Gathering Storm.
- Do NOT use with Scenarios as they usually have their own rules for AI.
- The mod's flag "affects save files" is set to FALSE. You can enable / disable it whenever you want. However, it stores its own data in a save-file, so after a reload a civ can continue its behavior uninterrupted.
- It is NOT compatible with AI+. You will most likely get DB errors with both mods enabled.
- It is also NOT recommended to mix it with other AI-altering mods - they technically might work together, but you will most likely get weird results.
- Game Modes that change AI behavior will not align well - like Barbarian Clans or Zombies. Game Modes with only new content added should work ok - like Tech Shuffle, Monopolies and Corporations, Secret Societies, Heroes and Legends.

Overview of the key features
Detailed description[forums.civfanatics.com]
- AI uses more sophisticated approach to decide what victory to pursue. This is the core part of the mod programmed in Lua. It evaluates the current situation, and assess what other are doing. Basically these are concepts and ideas used in Civ5 re-programmed to be used in Civ6.
- Each Victory Strategy is revised and enhanced accordingly. Diplomatic Victory is also supported.
- Anti-Strategies to better handle disabled victory-conditions have been created.
- New approach to Naval strategies. A civ will determine based on revealed tiles (during exploration) in what situation it is: Pangea, Default, Coastal, Island and tune its behavior accordingly.
- Each Leader, Policy, Wonders, and few other things have flavors assigned to indicate what type of game we are playing.
- The leaders' behavior (AiLists) have been enhanced. Not changed - (practically) all original entries are there. Errors are fixed and many more are added to help leaders pursue their goals.
- Few supporting strategies have been implemented, mostly to help manage military and wars. Very simple ones, this area will be improved in the future. Basically Peace/War behavior, Catching up behavior when we start lagging in military (weak civs are always first to be killed), Science or Culture and an emergency Defense when a strong civ attacks us.
- Time strategies - revised and updated.
- Simple tweaks to Tactics and Operations systems. Some fiddling with behavior trees. Mostly to make AI better at sieges (they use Rams, etc.) and general war preparation.
- AI uses Bombers extensively, and Nukes cites too.
- Missing start biases added for civs depending on geo-location.
- A bit revised Settling params. AI chooses better spots (a bit, the system is too simple to achieve any grand results).
- Scripts for better GWAM handling (temporarily disabled).
- Last, but not least. No cheating policy is in effect. The "thinking" part uses only information that is also available to the human player, e.g. it doesn't know anything about another civ until it's met. This mod doesn't give AI anything for free (no units, no boosts, yields, etc.)

If you want to check yourself how the AI works with the mod, on the CivFanatics forum I posted[forums.civfanatics.com] a simple tool for that (FireTuner panel).
Important. In case of issues or errors please also post Lua.log - it contains crucial information needed for analysis and tuning.

More information on the mod homepage on CivFanatics.[forums.civfanatics.com]

I really prefer to have discussions on CivFanatics.

Multi Player note
This mod can be used in MP. The support was added 2 months ago and I have not received any reports about de-sync issues. The most problematic function - random numbers - has been changed into a function from the game engine that works in MP. There are 3 options (RST_Params.sql) that you can choose to use / test:
- 0 - random numbers are not used at all.
- 1 - for Single Player only, uses math.random.
- 2 - for Multi Player & SP, uses Game.GetRandNum - this is the default option.

iOS note
I think all platforms have now the same base game and all expansions (?), so the mod should work on all of them with no issues. However, I am not able to test it on iOS, as I only have the base game there.
The latest version dedicated for only vanilla game is 1.4 and can be downloaded from CivFanatics.

Differences from AI+
Since this is going to be an inevitable question:
- AI+ adds a lot of strategies on top of existing ones. RST enhances existing programming. You can turn it on / off even for games in-progress (doesn't affect the save files).
- Victory conditions. AI+ uses existing conditions, no improvement here. RST uses a more sophisticated approach here (see here[forums.civfanatics.com] for details).
- Leaders. AI+ uses Traits as a way to give various civs more unique behavior. RST tunes each civ and leader separately to its preferred victories.
- Tactics. AI+ introduces its own behavior tress and overhauls this part. RST just tweaks few things here. However, I see the need to use more advanced (or better) behavior trees. This is for the future development.
- Difficulties. AI+ employs a bit different strategies on higher diffs, with focus on Deity. Mostly more aggressive and more military focus strategies. RST - no changes here. Imo, the Civ philosophy has been always that difficulties come from giving AI more bonuses. And I am ok with that. AI should be "smart" no matter what difficulty we are playing.
Personally, I consider AI+ to be a really good mod. I used it a source of (good) ideas and "tested" mechanics. Whatever gems are hidden there (and there are), I will most likely try to implement them in RST.

Troubleshooting
1. This mod does NOT attach itself to save files. So, you will not see it in the list of mods when browsing games.
2. Make sure the mod is actually running during the gameplay. Go to the Pause menu and check if it appears in the list of active mods.
3. Starting biases conflict. Courtesy of MykolaCZ:
For people who getting error when enable this mod.
It can be compatibility issue ( confirmed on "Better Balanced ..." at least).
You need to turn off one parameter in the file "RealStrategy_Params.sql"
File located: disk:\SteamLibrary\steamapps\workshop\content\289070\1617282434
String 22 in version 1.7
INSERT INTO GlobalParameters (Name, Value) VALUES ('RST_OPTION_BIASES', '1');
change to
INSERT INTO GlobalParameters (Name, Value) VALUES ('RST_OPTION_BIASES', '0');

Credits
- Delnar - FastPillage operation and BH tree from his mod "AI CleanUp". I am not sure if it is working, but I like the idea :) Jan 22nd: Didn't work but I think I fixed it.
Popular Discussions View All (7)
146
1
2 Jul, 2024 @ 2:11pm
PINNED: Please report issues here.
infixo
6
6 Aug, 2023 @ 3:16am
AI government preference edit
Trump King
4
17 Sep, 2019 @ 4:17am
CIVITAS CityStates [OBSOLETE]
infixo
1,174 Comments
REZ 4 Sep @ 12:57am 
Does this mod also work with the Leader mod?
burrik 30 Aug @ 11:32am 
For some reason barbarians don't attack my units with this mod enabled. Tested at the same turn - they attack as they should with this mod disabled
infixo  [author] 17 Aug @ 11:09am 
@rilquermascarenhas @chrismartin is right, any mechanic/feature that is not available in the core game, cannot be properly utilized by AI. So, e.g. unit from population cannot be "understood" and used by AI properly because there is no such feature in the core game. AI will build military units as needed by at the same time will lose pop. The cost of lost will NOT be taken into consideration when scheduling unit builds. This would require coding in the game engine. For historical victories the issue is not the victory condition, because Civ6 is pretty felixble in this regard. The issue is with the nature of said mini-quests, if AI "knows" how to do them or not. Take a look at my Real Eurekas mod. It deals with similar problem. AI is coded to pursue vanilla eurekas and knows how to do that. But I needed to code other eurekas, and some of them AI can do (those using native mechanics) and some cannot do.
ChrisMartin 17 Aug @ 2:14am 
You answered your own question; The AI in Civ6 will never be able to use/take advantage of mod-added functions/rules/units/buildings in a good way, just by changing sql and xml files.
I'm hoping for Civ7 to crash and burn, "forcing" Firaxis to release the core-files for Civ6 (to stay relevant in the market), so advanced coding and modding can take place.
rilquermascarenhas 15 Aug @ 4:37pm 
Hello. First of all, I really love this mod. It is one of my favorites and I dont think I can play without it anymore. I wanna gain a better understanding of the AI improvements, especially in regards to its behavior with mods that overhauls game mechanics. I have been using three mods that add new mechanics: 1) Unit limit enforcement (sets a cap to the number of units which can be changed by building infrastructure); 2) Military from population (units cost 1 pop); 3) Historical victories (adds new small quests unique to each civ as victory conditions). I feel AI would have a problem with them because the first two are mechanics not found in the unmodded game, and the third consists of new victory conditions. So far, I havent had much problem with AI and these mods, I believe Real Strategy AI is doing its job in making AI smarter. But I was overall curious if anyone would have any thoughts/previous experience on this. Thanks.
Fugandoats 14 Jul @ 5:34pm 
I've given the mod a go in Vanilla GS (no other AI mods enabled) and thought I'd try Prince difficulty as I usually play Emperor and thought it would be wise to try this on a lower difficulty first. However I've found throughout the game into the medieval era that the AI isn't only different to vanilla, it seems to be somewhat disabled entirely? They aren't building districts or attempting to advance at all. It doesn't seem like an issue that would resolve from simply upping the difficulty, I'm wondering if it's malfunctioning somehow? I can't see any errors or anything.
Molten Ice 25 Jun @ 2:31am 
@rilquermascarenhas nothing to do with this mod, I've noticed that barbarian clans mode doesn't even work with vanilla AI. In general I don't think the AI knows how to handle this mode at all, so this mod would probably not have the ability to be able to change that.

@TikaTops try adding late game AI https://steamproxy.com/sharedfiles/filedetails/?id=2939752243 on top of this mod, and bump up the difficulty to higher than deity if it's not doing what you're after.

@Infixo, I just wanted to say I love this mod and use it on all my games, thank you for making it and I hope you keep maintaining it!
rilquermascarenhas 14 Jun @ 8:25pm 
Has anyone played this with Barbarians Clan mode and seen any issues?
TikaTops 19 May @ 2:46pm 
Thanks a lot for getting back to me. What I'm trying to achieve is for the AI to build larger armies and actually use them if it sees it has the advantage. Just off the top of your head, how would you recommend tweaking these parameters to get the effect I'm aiming for without throwing the game balance off too much? I'm playing with vanilla rules, no DLC.
infixo  [author] 19 May @ 1:40pm 
@tikatops It won't break the mod, just your game could be unbalanced.