Currently its not possible to mod the AI in SupCom2, but we CAN see the code. I would like to start gathering AI suggestions for future mods for when modding may or may not be available.
Please post any specific issues you have seen with the Supcom 2 AI. Please indicate:
- The number of players, human and AI
- The AI types selected.
- The map chosen
- Any other non-standard options
Some key issues/bugs I have seen so far to start off:
- AI builds too many transports on some maps
- Cheat AI is too powerful earlier game. This is particularly true on small maps. The handicap may need to grow over time.
*|||1 human
Any number of AI's
Cheating Turtle AI, Cheating AI, Hard Ai
all 1 vs 1 maps other than Clarke Training Center (or was it facility? xD)
The only 3 player map. I really need to learn the names of the maps. -_-
-It seems to favor Air about 80% of the time, takes the fun out of me smashing it with my ground force. Only when the AI is Illuminate will it actually construct a ground force. It will at some point send a land army to my base but will only do it about twice which is odd.
-They usually box in their ACU in their base making them very easy targets.
-They dont expand very well
I cant think of anything else right now, I know theres a few more quirks. But I'll try to remember them later and post them.|||This is with hard away on every map.
The AI will send a force of ONLY engineers right in your base or even drop them of with a transport.
Its wasting its recourse to make them and feed them to ya.|||On coalition command, I have tried playing 4 times with me vs 3 hard or cheating AIs. I turn off nukes and air so I can have a "smash the ground forces" fun match. Most of the time, two of the AIs will do nothing while the third, and closest, does what it needs to do. I have got the second closest to make one factory by turning off fog of war, but that is the only factory it builds. The third one at the far end still just gets its initial economy buildings up and then stops.|||seiya|||Any UEF ai that decides to use the noah cannon, will do so on the exact same spot every time - even if that spot is surrounded by ground point defense structures so every unit dies less than a second after touching down.
The AI also has no countermeasures for a player with multiple nuke defense silos protected by shields, AA measures, and 10+ long range artillery cannons.
Also, not an AI issue, but I would think that for the return fire setting for artillery structures should have a draggable (changeable) radius for targeting, such as a group of heavy artillery can take down a mob of 4+ land experimentals very, very quickly.|||1.)
If you watch replays you can see the AI want to constantly go beyond the field limit if you have choosen a no rush timer. Makes it starting with the wrong strategy.
I had bombers coming at me after the 5 minutes have past, bashing them with my AA defence and fighters
The AI should prepare air/land/sea units if there is a timer and should scout bevor trying to do something stupid. If there is no timer it also should constanly scout enemies and use the right tactic/units against them.
2.) AI uses Artillery even if it has no use. If it fires on a spot that has a couple of shields it will continue to fire endless on this spot. It doesn't redirect it's fire on a more usefull/weaker spot.|||you can mod the AI, you just cant do it as a mod, have to edit the lua.scd itself, which is a huge PITA because you can only add .lua files into the .scd once, then you need to copy/paste a new clean one so u can add them again whenever u want to update something
have been messing with the research options for the AI, trying to force them to not build/research waste of time stuff. it is actually very nice to work with the research settings for the ai.
sad thing is it looks like most of the naval ai is totally shutdown
there are also a few areas where it just defaults to air strategy to avoid problems.
There are 7 different AI currently.
Air
Balanced(air and land)
Land
Land with no transports
Naval
Rush
Turtle
When the game starts it auto selects the AI based on a points system. Each AI gets certain "points" for different things, such as how far away it is from the enemy, map features, etc, the AI with highest points gets chosen. Choosing "turtle" ai doesn't actually force turtle AI, just gives a ton of points :)
The biggest problem I've seen so far is that all of the AI lean towards air.
All in all, once GPG releases real mod support I imagine some awesome things will be able to be done with this AI, it seems a much nicer system to work with than FA.
also...i did manage to get an AI to send a 200 or so wave of fighter bombers at me, that was pretty exciting lol, in return i spawned about 20 commanders inside his base!|||I thought there was no way to mod the lua files. That's why I haven't started to look at nodding the supcom2 ai yet. Can you give more details of what you are doing?
Also what do you mean by spawning 20 commanders? I thought debug mode is disabled too?|||To get the debug features you can edit the defaultkeymap.lua. Move all debug functions out of the debug keymap and into the normal one, you can also remove the comments from the ping functions if you want to use them again, they don't work quite as well as they used to.
The way I've been modding the lua is as follows(im not sure if there are better ways out there)
Working with the uncompiled_lua files I make whatever changes I want.
Then I open the lua.scd, the real compiled one, with WinRar. Browse to the directory where the files I changed are and add them.
The annoying part is that the changed files need to be added all at once, you can only change the lua.scd once for some reason(i might just be screwing something up).
I tried taking the original lua.scd, uncompressing it with WinRAR(and other programs) and then just remaking it into lua.scd with zero changes, and it fails. Tried a million things to get it to work but no joy. It does work in Forged Alliance though so I know I'm not just screwing something up.
When I am testing a change I make to the AI what I do is.
Copy/paste a copy of the original lua.scd into the gamedata folder. Then open in winrar and add in both my keymap changes as well as AI changes all in one go. If I then want to change the keymap, I again have to copy/paste an original lua.scd and add both the new keymap as well as the AI changes.
Hope this helps. I can try to put my current "mod" online for download if that would help, but my ai tweaking so far is just trying to learn how it functions and is certainly not "improved"|||As far as what I have done with the AI so far.
I have mainly been playing with the turtle AI because it is the only one selectable in the skirmish lobby and so it is the easiest to change and then test.
I have been trying to mess with the starting build order via SAIEngineerBuilders_Turtle_Startup.bp
Hasn't seemed to be working as it should. I tried forcing the AI to only build land factories but it always builds an air factory first. (this is testing on Seton's Clutch).
Messed with the other engineerbuilders as well trying to force a land factory first but no luck, still trying to figure out what is going on.
Messed with the PlatoonTemplates and PlatoonFormBuilders, they are pretty straightforward working.
In the AI Arechetypes there are ResearchPlans which I have been playing with lately. The AI for some reason doesn't follow them always, and I'm not sure how to force it. I tried removing certain units the AI loves to build from the ResearchPlan, and add in things I felt it should research. I removed all transports from the plan, but it still researches them quite early most of the time. I know the AI is designed to research things not in ResearchPlan once it has researched everything in the plan, but there must be something else that allows overrides to the items in the plan.
Have played a little with reducing the AI obsession for transports, no real progress yet. Maybe a good place to look is inside the "Land - No Transport" AI. Tried reducing the priority of transports in the factorybuilders but didn't seem to make a difference, or at least not a noticeable one.
What I really need is to figure out how to take control of the AI during skirmish games. It would be a great help to be able to check on how the AI is doing with resources, whether it has too much mass/energy at certain times, or if it is often running out of one or the other, etc.
While it was easy enough to get the keyboard debug commands remapped and usable, still have had no luck finding out where to enable the console.
Unfortunately I have zero programming experience and really no idea on how/if that is even possible.|||wow that is interesting... I will ask around to see if we can solve the lua editing only once problem. If we can its possible we could create an installer that would backup the lua.scd and insert the script changes into file. This way multiple mods may be able to better co-exist.
As for AI fixes. The issues that I would like to fix first:
- Rush AI and Land AI wait too long before building second fac. This more than anything makes them weak on small maps. I believe this is because they are waiting for 6 mexes before building the second fac. This can be fixed in SAIEngineerBuilders_Factories_RushFocus.bp and the land one.
- The AI builds too many transports. A quick fix is to reduce the priority of the 'Air Unit - Transport - Max 5' group to 0. The AI will still build transports, but not as soon and will be limited to 3 at once. This may need to be tweaked further.
- Amend SAIArchetype_AirArchetypes.lua and SAIArchetype_BalancedArchetypes.lua evaluate functions so they dont select the Air type AIs if Exclusions of Air are on.
- Tweak the handicap levels in SkirmishAISystem.lua. Need to increase hard handicap level and decrease cheat handicap level. Maybe also amend the handicaps based on map size and number of players.
- Remove useless research items or reorder so ACU upgrades are not selected as often.|||With the cheating AI, it is getting an omni cheat to remove fog of war, I'd really like this as an optional cheat for the AI. Since the AI reacts to certain things it sees(builds shields if it sees an experimental or artillery, builds anti-nuke if it sees nuke), having it able to see and react instantly isn't always desirable :)
Ideally we would have something like Sorian made for adjusting the specific amount of cheat the AI gets, but until then...
I never use the Easy or normal AI, was thinking of just setting the handicap levels so that
easy = hard
normal = hard + a bit more
hard = cheat but no omni cheat
cheat = cheat with omni cheat
Going with your idea of the handicap changing based on map size/number of players. I wonder if it would be possible for the handicap to change mid game. Something that keeps the AI reasonable in the beginning of the game, but gives it a nice boost late game when it seems to struggle.
- As cool as it is for it to be able to choose which AI it should use based on various things, I think I'd rather be able to select which AI I want, or at least have the option for both :)
No comments:
Post a Comment