• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.
...Personally, I increase the spotter and sensor ranges because I like to play the long game, usually to 450 and 600 meters, respectively. This means on many maps, however, that as soon as you drop you are in detection range so combat rounds begin immediately. I also turn AllowRearArcSpotting to False.
I've never really understood the very short ranges in this game.
Ok, I can get the sensor limitations, as perhaps all mechs have some sort of passive stealth, so I generally keep that to around 600.

However, the visual limitations make no sense at all. No 'cloaking devices' in the BT universe.
It's also contradicted by the lore as well. I remember reading in one of the novels (Second Gray Death?) that one of the characters spotted a Griffin at 3 Km. Now I keep that set to about 1200.
Hell, that's not even particular long range even for current sniper rifles.

On the other hand, rear Arc spotting is definitely supported by the lore.
Mechs have cockpit screens that show a 360 display within a 120 degree arc so that warrior can see all around them without the need for rear-view mirrors
 
  • 1
  • 1
Reactions:
So, I'm starting to feel Better AI 2.0 (in git as Clean Slate Testing Branch) is starting to shape up now that I added a first pass vehicle file. There's still some targeting prioritization I feel needs to be addressed, but if anyone want's to take it for a spin:

From the main Better AI Git - select the "Branch" dropdown on the left, should say "master" and pick "Clean Slate Testing Branch" and use the green "Code" button on the right to DL the zip file.

I looking for feedback in contracts, but skirmish is fine too.

I've had to turn off the short range line of fire (the thing that disabled the dumb long range pathfinder) as I kept finding more and more locations the AI would just get stuck on. I've managed to tune some of the patrol route throttles to compensate, which is used in a lot of contracts, but not in skirmish. So Lances should stay a little closer together by accident due to choking the throttle on Scouts, and opening a full 100% speed on everyone else. I don't really know how this might affect convoy escort/ambush but the few I've played have run mostly the same. I need to locate some problem maps and take the time to clock how many rounds it takes for them to complete the route to be sure I'm not making things too hard or easy depending on if you're trying to catch or coddle vehicles.
 
  • 3Like
Reactions:
So, I'm starting to feel Better AI 2.0 (in git as Clean Slate Testing Branch) is starting to shape up now that I added a first pass vehicle file. There's still some targeting prioritization I feel needs to be addressed, but if anyone want's to take it for a spin:

From the main Better AI Git - select the "Branch" dropdown on the left, should say "master" and pick "Clean Slate Testing Branch" and use the green "Code" button on the right to DL the zip file.

I looking for feedback in contracts, but skirmish is fine too.

I've had to turn off the short range line of fire (the thing that disabled the dumb long range pathfinder) as I kept finding more and more locations the AI would just get stuck on. I've managed to tune some of the patrol route throttles to compensate, which is used in a lot of contracts, but not in skirmish. So Lances should stay a little closer together by accident due to choking the throttle on Scouts, and opening a full 100% speed on everyone else. I don't really know how this might affect convoy escort/ambush but the few I've played have run mostly the same. I need to locate some problem maps and take the time to clock how many rounds it takes for them to complete the route to be sure I'm not making things too hard or easy depending on if you're trying to catch or coddle vehicles.

I just keep thinking more is needed outside of just the modification to the AI. Specifically, the spotter and sensor ranges. I think the AI benefits from being able to "see" more of the battlefield.

And, if it's not going to create excessive heat, the AI should fire as many weapons as possible regardless of how low the hit chance is, as opposed to holding fire, or firing only a single weapon, because the % is below the threshold, especially if it is a missile weapon.

In addition, and this is probably controversial, the AI should have the same Critical Hit chance as the player. It doesn't make a lot of sense to weigh the AI's targeting decisions based on a vanishingly small critical chance.

My own preference is to also increase the overall AI pilot abilities, giving most if not all bulwark, while at the same time using the semi-permanent evasion system, which I think is pure genius. And last, if I could, I'd turn on the "friendly fire" where stray shots could hit friendly units as well as non-friendly. I think it would hurt the player a lot more than the AI as players tend to focus fire, especially when they have one unit in melee with any enemy and the rest of the lance firing on it.

Thanks for all your deep diving on this. I'm using the Clean Slate Branch now.
 
  • 1Like
Reactions:
I just keep thinking more is needed outside of just the modification to the AI. Specifically, the spotter and sensor ranges. I think the AI benefits from being able to "see" more of the battlefield.

And, if it's not going to create excessive heat, the AI should fire as many weapons as possible regardless of how low the hit chance is, as opposed to holding fire, or firing only a single weapon, because the % is below the threshold, especially if it is a missile weapon.

In addition, and this is probably controversial, the AI should have the same Critical Hit chance as the player. It doesn't make a lot of sense to weigh the AI's targeting decisions based on a vanishingly small critical chance.

My own preference is to also increase the overall AI pilot abilities, giving most if not all bulwark, while at the same time using the semi-permanent evasion system, which I think is pure genius. And last, if I could, I'd turn on the "friendly fire" where stray shots could hit friendly units as well as non-friendly. I think it would hurt the player a lot more than the AI as players tend to focus fire, especially when they have one unit in melee with any enemy and the rest of the lance firing on it.

Thanks for all your deep diving on this. I'm using the Clean Slate Branch now.

The AI does get the same crit chance as the player with Better AI since a long time ago. AICritChanceBaseMultiplier should be set to 1.0 and give the same odds unless something has changed since I've been gone.

As for Bulwark - My personal opinion is just remove Bulwark and replace it with Juggernaut or some other ability and work the base damage reductions to mimic what a Bulwark pilot has now, maybe with a slight reduction based on feedback. This gives everyone Bulwark without occupying a pilot slot the player had to pick, and the AI can't choose on its own.

As for the conservative shot - This is the part of the targeting logic I want to see if I can work on before pushing this 2.0 to release. With it set to 0, I just jump a FS9 or PHX in to LoS and let everyone fire at it, reserving down my units. Then, I can stroll them in to the open knowing the AI has already run to the heat line and can't alpha in the next turn. This can totally change how Lunar Biome maps run, where heat management is king and cover is non-existent, it becomes a cake walk once you "pre-heat" the AI by baiting them with a lone high evasive target.

Sadly, AI Toolkit doesn't give me the same metrics with target selection as it does with movement variables. It's mostly a haze to me at this time. What I would want, is an AI that will shoot a little at a hard to hit target, but then easily move to a easier to hit one, even if it isn't as damaged or more heavily armored than the bait unit. I think I can get this done, but targeting testing is just plain more time consuming to test.
 
  • 1Like
Reactions:
Keen to take the 2.0 for a spin, and will give you my observations once I get a few missions under my belt.
As I noted previously, your 1.9.1.1 version is a significant improvement on the version that shipped with BEX, but it still often seems to hold back a bit.
Against my fast light/mediums, that still gives me an advantage.

And, if it's not going to create excessive heat, the AI should fire as many weapons as possible regardless of how low the hit chance is, as opposed to holding fire, or firing only a single weapon, because the % is below the threshold, especially if it is a missile weapon.

My own preference is to also increase the overall AI pilot abilities, giving most if not all bulwark, while at the same time using the semi-permanent evasion system, which I think is pure genius. And last, if I could, I'd turn on the "friendly fire" where stray shots could hit friendly units as well as non-friendly. I think it would hurt the player a lot more than the AI as players tend to focus fire, especially when they have one unit in melee with any enemy and the rest of the lance firing on it.

Couldn't agree more.
If it doesn't risk shutdown/ammo explosion I would love to see the AI unloading all, at every opportunity.
The latest (now previous) version has been much better, but I still feel that they are still holding back from time to time. As Sigil says, this seem to apply more to missiles. In a recent Flashpoint, a cool Archer would let loose with his MLs on my Flea 17, but held back on the LRMs several times.
That Flea eventually cored his ass.

I'd also like to see the friendly fire element, but not sure if it actually works.
I previously ran a mod that supposedly enabled this, but never once saw any examples, in spite of the fact I often fired on targets who had been just melee'd.
My lads were happy to not have to suck down company missiles, but it should be something to consider (Pat Tillman, RIP)

Thanks for your continuing excellent work in this
 
  • 2Like
Reactions:
Keen to take the 2.0 for a spin, and will give you my observations once I get a few missions under my belt.
As I noted previously, your 1.9.1.1 version is a significant improvement on the version that shipped with BEX, but it still often seems to hold back a bit.
Against my fast light/mediums, that still gives me an advantage.



Couldn't agree more.
If it doesn't risk shutdown/ammo explosion I would love to see the AI unloading all, at every opportunity.
The latest (now previous) version has been much better, but I still feel that they are still holding back from time to time. As Sigil says, this seem to apply more to missiles. In a recent Flashpoint, a cool Archer would let loose with his MLs on my Flea 17, but held back on the LRMs several times.
That Flea eventually cored his ass.

I'd also like to see the friendly fire element, but not sure if it actually works.
I previously ran a mod that supposedly enabled this, but never once saw any examples, in spite of the fact I often fired on targets who had been just melee'd.
My lads were happy to not have to suck down company missiles, but it should be something to consider (Pat Tillman, RIP)

Thanks for your continuing excellent work in this

I've also been skeptical of friendly fire setting. There was a simple mod that enabled this that I also have used since it was allowed. I remember it working at first, but since I've returned I've grown skeptical that setting is working. I might try to test this out later just for my own peace of mind. Even if it does work, this would not fall in to the scope of Better AI. Also, there are already existing mods that just enable that and nothing else.

As for the single laser vs the missile - I think the AI picks from weapons that have the highest hit chance. So lasers having a base 5% boost means they get picked. I don't think the AI is smart enough to consider that 4x SRMs at 25% is better than 1 ML at 30%. Again, the semi-perm evasion add-on is available for players who want it or for packs like BEX where evasion is more permanent. The add-on will work with the new builds without issue.
 
  • 1Like
  • 1
Reactions:
I've also been skeptical of friendly fire setting. ... Even if it does work, this would not fall in to the scope of Better AI. ...
Yep. Fair enough.
Interesting feature, that should play a bigger part in a commanders move and fire decisions (especially considering how often missed shots blast buildings and other close opposing mechs), but clearly not an AI issue.
I'd be interested to hear the results if you can test this, though.

As for the single laser vs the missile - I think the AI picks from weapons that have the highest hit chance. So lasers having a base 5% boost means they get picked. I don't think the AI is smart enough to consider that 4x SRMs at 25% is better than 1 ML at 30%. Again, the semi-perm evasion add-on is available for players who want it or for packs like BEX where evasion is more permanent. The add-on will work with the new builds without issue.
I am using your perm-evasion addon, and it has made a big difference.
But I am still seeing cases where enemies aren't shooting their full load (even when heat wouldn't seem to be a concern for them) all over my high evasion lights.
As you noted, even a low percentage shot with 40 LRMs can make a cheeky Flea very unhappy.
Anyway to increase the chances that enemies will fire all weapons, even on very low hit probability shots?

Will let you know how your latest 'Clean slate version' (with perm-evasion addon) pans out.
 
  • 1Like
Reactions:
I've also been skeptical of friendly fire setting. There was a simple mod that enabled this that I also have used since it was allowed. I remember it working at first, but since I've returned I've grown skeptical that setting is working. I might try to test this out later just for my own peace of mind. Even if it does work, this would not fall in to the scope of Better AI. Also, there are already existing mods that just enable that and nothing else.

I too have never seen friendly fire although I have played with mods that claimed to have enabled it. I even tried manually setting the friendly fire value to 3 as I was told that would work as well. It didn't :(
 
  • 1Like
Reactions:
Also have not seen friendly fire with the simple FF mod since 1.9 game update.

I assume somewhere the AI is calculating statistcally expected damage, is there a way to use that instead of hit chance on evasive targets? That would prefer to shoot an SRM6 over a ML
 
  • 2Like
Reactions:
2.0.0 Release for BT 1.9.1
Better AI - 2.0.0 - SEE UPDATED OP

Uses ModTek 0.7.7.4
Better AI can be used with the HBS mod loader, however DLC content will not be corrected. It's recommended to use this mod with ModTek.

Instructions:
For older versions - Delete old Better AI folder in BATTLETECH\Mods
Copy BetterAI-2.0.0 in to the BATTLETECH\Mods folder.

Release Notes:
Better AI 2.0 is a clean slate rewrite using the AI diagnostic tools developed by mpstark and input from Koztaz of "Relentless AI" to further improve the tactical challenge in a stock environment. It's more aggressive, keeps Lances cohesive and is more capable in reserve play with numbers. This mod has been built for and tested with the stock game mechanics. The Better AI Permanent Evasion Add On will still be needed for mods and modpacks that use it. If you are using the BT: Extended, BT: Advanced, please wait for the modpack curators to update to this version. BT: Revised users now have "Relentless AI" from Koztaz already tuned to their modpack.
Feedback is greatly appreciated either on the PDX forum Better AI thread or the various BT discords.

Modpack users: AT YOUR OWN RISK - Copying only the "\data\behaviorVariables" folder from Better AI 2.0 in to your modpacks existing Better AI folder should work with minimal interference. However, this is not recommended.

Better AI Permanent Evasion Add On - No update of Add-On required, will work with 2.0.0 automatically



It's finally done! I feel like the AI is a step up from the previous version, but still not the smartest kid on the block. From here, I'll be going in to making custom behavior trees using the existing nodes with mpstark's AIToolkit. This should let me do things like change what order the AI moves units, like moving the slowest units in a phase first before the faster ones.

The biggest thing I need is feedback!
 
  • 6Like
  • 2Love
Reactions:
Nice.
Thanks a ton for your continuing efforts to help the AI brutally murder my hard working and skilled team.
Will be more than happy to share my observations on how well those evil and/or misguided b@$tar@ds fare in their mission to slaughter the righteous.
 
  • 1Like
Reactions:
Feedback: I have been using Better AI 2.0 with my latest game using the Hyades Rim mod, and I've noticed sometimes that enemy mechs will stand still and shoot at my units, even though they could move into cover one or two hexes over. I don't remember seeing this behavior before. I can try to provide more details if it would be helpful, particularly if there are log files that are being (or could be ) generated - I'd just need to know what to provide.
 
  • 1Like
Reactions:
Feedback: I have been using Better AI 2.0 with my latest game using the Hyades Rim mod, and I've noticed sometimes that enemy mechs will stand still and shoot at my units, even though they could move into cover one or two hexes over. I don't remember seeing this behavior before. I can try to provide more details if it would be helpful, particularly if there are log files that are being (or could be ) generated - I'd just need to know what to provide.


Thanks for that. I'll run it by Koztaz, whos working on altering the AI behavior tree and is finding a lot of little bugs we didn't know about before. That standing and shooting is something I think he's working on due to some problems in melee/DFA logic. For whatever reason, my current config seems more susceptible to this and I'm not sure yet what I can change to fix it. But it's really good to get a 3rd party report of the same thing we've been seeing! Thanks!
 
  • 1Like
Reactions:
On a defend base or similar mission, what behavior or variables influence how soon and under what conditions the AI attacks a building?

Nerfing the AI to not engage those targets in those missions really just ruins them.
 
  • 1Like
Reactions:
On a defend base or similar mission, what behavior or variables influence how soon and under what conditions the AI attacks a building?

Nerfing the AI to not engage those targets in those missions really just ruins them.
I haven't seen that happen using Better AI 2.0. For me, in those missions, the AI runs at the buildings and targets them exclusively unless they are shot at by the player or the player's allies. What are you seeing?
 
I haven't seen that happen using Better AI 2.0. For me, in those missions, the AI runs at the buildings and targets them exclusively unless they are shot at by the player or the player's allies. What are you seeing?
I'm afraid I'm in the "unsupported" realm. I'm using the built-in HBS Mod Loader since I'm on a Mac and I've used AMechWarrior's suggestion:

"Modpack users: AT YOUR OWN RISK - Copying only the "\data\behaviorVariables" folder from Better AI 2.0 in to your modpacks existing Better AI folder should work with minimal interference. However, this is not recommended."

And then, to compound it, I'm checking against a customized "Smithon: Defense" campaign mission I've incorporated into a Career Flashpoint.

Let me know if you're interested in checking out the mod, it's in a playable state now, and see how it behaves for you.
 
I'm afraid I'm in the "unsupported" realm. I'm using the built-in HBS Mod Loader since I'm on a Mac and I've used AMechWarrior's suggestion:

"Modpack users: AT YOUR OWN RISK - Copying only the "\data\behaviorVariables" folder from Better AI 2.0 in to your modpacks existing Better AI folder should work with minimal interference. However, this is not recommended."

And then, to compound it, I'm checking against a customized "Smithon: Defense" campaign mission I've incorporated into a Career Flashpoint.

Let me know if you're interested in checking out the mod, it's in a playable state now, and see how it behaves for you.
Ah, okay! I appreciate the invitation, but currently have my attention devoted to other projects at the moment. Hopefully a solution presents itself.
 
On a defend base or similar mission, what behavior or variables influence how soon and under what conditions the AI attacks a building?

Nerfing the AI to not engage those targets in those missions really just ruins them.

I get about as many for and against this change, so if anything that tells me I'm in the right area. IIRC I tuned this down from the pre-2.0 versions and the variables are:

Code:
{
      /* Should targeting this unit distract it from attacking a
         priority target? */
      "k": "Bool_ProhibitTargetingPriorityTargetsAfterBeingTargeted",
      "v": {
        "type": "Bool",
        "boolVal": false
      }
    },
    {
      /* Percentage (0-100) of time to attack priority
         targets. */
      "k": "Float_PriorityAttackPercentage",
      "v": {
        "type": "Float",
        "floatVal": 66
      }
    },
    {
      /* Percentage (0-100) of time to move towards priority
         targets. */
      "k": "Float_PriorityMovePercentage",
      "v": {
        "type": "Float",
        "floatVal": 80
      }
    },

In BAI 1.7, the Float_PriorityAttackPercentage and Float_PriorityMovePercentage were both at "100" or one-hundred percent "always shoot/move at priority targets. " Searching the global.json for other instances of "priority" didn't turn up anything relevant to mission bits so I think just pumping those to 100 would return it to the previous state.

Personally - I also don't quite like the change. I find it harder to keep buildings alive over winning the brawl. However, the reason I came around to this is that it's trivial to let them advance on the buildings and rear-core them without threat, one by one, until the Lance is destroyed. I considered this a bigger "dumb move" than not completing the objective like a suicide drone. The great distances in Attack/Defend really showcase this error, where previously the closer enemy spawns in Escort and Base Def. to the objectives hid this exploit significantly.
 
  • 3
  • 2Like
Reactions: