Better Tactical AI Addon

A place to post your add ons and ideas for them

Moderator: Moderator

Message
Author
jenx
Sher'Tul Godslayer
Posts: 2263
Joined: Mon Feb 14, 2011 11:16 pm

Better Tactical AI Addon

#1 Post by jenx »

This addon dramatically improves the tactical ai of tome. Tactical ai is used by certain summons and friends (Norgan, thought-forms, etc) and certain npcs (all rares, most bosses, some creatures, such as master skeleton archers, crystals, orc pyromancers, etc).

It can be found here: http://te4.org/games/addons/tome/better-tactical-ai-0

This addon develops and extends the excellent addon, betterai, devised by lukep, and full credit must go to him for the key architecture regarding improving how the tactical ai weightings for talents can be modified.

I have introduced these additional improvements:
1. Improved the use of collecting combo points for brawler talents
2. fixed amakthel talent from lukep's code
3. increased range for checking talent use of traps and mucus by 1 (i.e. npcs place traps/mucus in the space between you/your summons and them as you approach)
4. increased range for checking talent use of summons, rampage, and crate minions by 8 (i.e. npcs summon/rampage when you are 8 paces away, rather than 1!)
5. fixed attack talents that have no required target (such as flurry, radius damage attacks)
6. allowed the ai to deactivate mindslayer shields and auras
7. fixed thought forms so solipsist npcs reactivate them if the thought-forms are killed
8. introduced a canHeal check - if npc has *no* healing talents at all, then this check is removed from calculations. So npc will attack rather than escape. Currently, they just move away from you and are easy to hunt down and kill. Now they are more kamikaze!!
9. fixed solipsists so thought-form does not count as an ally by the npc for use of talents like Mind Sear etc. Otherwise, npcs won't use mindsear for fear of hurting this ally.
10. removed weighting for closein talents (like Rush, Blindside) that scaled higher the further away you are from npc.
11. added buff and escape to slime roots
12. stopped ai thinking slime roots hits itself (not sure why it does think this, but it means they are often not used currently)
13. made leaves tide talent activate as soon as player is seen, as it is such a good defensive talent
14. fixed mindlash so it works for npc even if conduit is not active (thanks to Hachem)
updated uppercut & body shot so that the stun disable increases as combo points increase
15. fixed concussive shot so attackarea is taken into account with combo points (and added to main attack)
16. fixed haymaker so combo points are included in calculation of attack strength
17 fixed nourishing moss to heal rather than disable
18. added buff for dream hammer as it cools down talents
19. added HEAL to Time Shield
20. nerfed Mark Prey, to stop ai from using it constantly. This is because the ai has had no chance to kill your subtype and so benefits little from using predator
21. added scaling tactical values to indominatable cure and defend, as it scales off talent level
22. reduced healing nexus disable to 1 from 3, as it is not very useful
23. changed tactics calculation, so each tactic weighed on its own tactical ai merit, (eg disable receives no attack bonus)
24. changed buff tactic to require visible enemies, otherwise heroism etc is used when no one is around
25. numerous small tweaks of various talents
26. added sort routines for closein, defend, buff tactics, to choose best option for each

What is the result? ALL npcs are much tougher to beat because they:
1. heal sooner
2. always prefer instant cast talents
3. summon sooner
4. choose stronger talents more reliably
5. use all available talents
6. use movement to and from player much more effectively
7. Use defensive talents much more regularly (time shield, displacement shield, healing talents, leaves tide, etc).

Which npcs are most notably improved?
1. Rogues
2. Solipsists
3. Shadowblades
4. Summoners
5. Oozemancers

what should I be most careful about? **** RANDOM BOSSES **** (i.e. farportal and last peak). These npcs are SERIOUSLY difficult, when they get certain combinations of talents. So shadowblade + temporal wardens are DEADLY, and will use their powerful disabling and high damaging talents first off. And as for the Dark Crypt..... I'll leave that for you to experience. Finally, you'lll be playing a version of yourself closer to how strong you really are. :lol:

So for those who are annoyed at tactical ai not working very well, this is the addon for you !!!!

I"m hoping many of the code changes can be introduced into the main game, even if they are in modified form. The code is well documented to show changes to existing code.

The following forum posts discuss the issues herein:

Improving tactical information for AI http://forums.te4.org/viewtopic.php?f=39&t=36957
[1.0.4] tactical ai never uses Mindlash... http://forums.te4.org/viewtopic.php?f=42&t=38745
[1.0.4] Reduce Howl tactical value to 1 or 2 http://forums.te4.org/viewtopic.php?f=39&t=38766
[1.0.4] Nourishing Moss tactical ai should include HEAL... http://forums.te4.org/viewtopic.php?f=42&t=38754
[1.0.4] Consolidated list of changes to TACTICAL ai http://forums.te4.org/viewtopic.php?f=42&t=38771
Tactical AI Analyses and Discussion http://forums.te4.org/viewtopic.php?f=36&t=38513

Finally, the player also benefits from this addon in several ways. Norgan and other friends (think, last battle) play much better for you, thought-forms use tactical ai :D, talents like shadow simulcrum create a better tactical version of you !, but this is my favorite: if you cast inner demons on an npc that uses tactical ai, each inner demon uses the new addon logic (think, bosses, and a certain room full of overpowered fire-breathing ....).

enjoy ...... :mrgreen: :mrgreen: :mrgreen:
MADNESS rocks

Doctornull
Sher'Tul Godslayer
Posts: 2402
Joined: Tue Jun 18, 2013 10:46 pm
Location: Ambush!

Re: Better Tactical AI Addon

#2 Post by Doctornull »

jenx wrote:enjoy ...... :mrgreen: :mrgreen: :mrgreen:
Downloading now, and I am eagerly anticipating hating you so much, so very very much... ;)
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.

jenx
Sher'Tul Godslayer
Posts: 2263
Joined: Mon Feb 14, 2011 11:16 pm

Re: Better Tactical AI Addon

#3 Post by jenx »

Doctornull wrote:
jenx wrote:enjoy ...... :mrgreen: :mrgreen: :mrgreen:
Downloading now, and I am eagerly anticipating hating you so much, so very very much... ;)
Let me know how it all goes :)

I'm keen to see how this plays out.
MADNESS rocks

Doctornull
Sher'Tul Godslayer
Posts: 2402
Joined: Tue Jun 18, 2013 10:46 pm
Location: Ambush!

Re: Better Tactical AI Addon

#4 Post by Doctornull »

My Thought-Forged Warrior just Death Dance'd me, leading to my death... maybe that talent needs better targeting?

Also, the current MD5 seems to be wrong, and this addon is invalidating my games. :(
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.

Zireael
Archmage
Posts: 449
Joined: Tue Jun 18, 2013 7:24 pm

Re: Better Tactical AI Addon

#5 Post by Zireael »

Grabbed it, will test is when I get around to playing ToME itself.

jenx
Sher'Tul Godslayer
Posts: 2263
Joined: Mon Feb 14, 2011 11:16 pm

Re: Better Tactical AI Addon

#6 Post by jenx »

Doctornull wrote:My Thought-Forged Warrior just Death Dance'd me, leading to my death... maybe that talent needs better targeting?

Also, the current MD5 seems to be wrong, and this addon is invalidating my games. :(
That's a difficult problem for me to to solve. it must have been surrounded by many foes to think attacking them outweighed not hurting you. Someone might be able to provide provide code to fix this.

The md5 is correct, I think dg needs to include the add-on somehow.
MADNESS rocks

Doctornull
Sher'Tul Godslayer
Posts: 2402
Joined: Tue Jun 18, 2013 10:46 pm
Location: Ambush!

Re: Better Tactical AI Addon

#7 Post by Doctornull »

jenx wrote:
Doctornull wrote:My Thought-Forged Warrior just Death Dance'd me, leading to my death... maybe that talent needs better targeting?
That's a difficult problem for me to to solve. it must have been surrounded by many foes to think attacking them outweighed not hurting you. Someone might be able to provide provide code to fix this.
It was just:
Me -> Thought-Forged Warrior -> Naga Myrmidon

Maybe Death Dance should be "friendlyfire=false" so I can use it around Escorts and my minions can use it next to me?
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.

lukep
Sher'Tul Godslayer
Posts: 1712
Joined: Mon Mar 14, 2011 10:32 am
Location: Canada

Re: Better Tactical AI Addon

#8 Post by lukep »

jenx wrote:That's a difficult problem for me to to solve. it must have been surrounded by many foes to think attacking them outweighed not hurting you. Someone might be able to provide provide code to fix this.
If everything else is working properly, just increasing the Thoughtform's ally compassion rating (defaults at 1 IIRC) should be enough.

...now that I think of it, a separate "summoner compassion" rating could be useful, as that could allow a Hydra (for example) to see hitting another summon as fine, but not its summoner.
Last edited by lukep on Fri Sep 13, 2013 12:49 am, edited 1 time in total.
Some of my tools for helping make talents:
Melee Talent Creator
Annotated Talent Code (incomplete)

Doctornull
Sher'Tul Godslayer
Posts: 2402
Joined: Tue Jun 18, 2013 10:46 pm
Location: Ambush!

Re: Better Tactical AI Addon

#9 Post by Doctornull »

Death Dance happened again with just me and a Yeach adjacent to the Warrior. Didn't kill me this time, but I'll be using the Defender for a bit instead.

Another bit of oddness: I encountered a shoal of nagas in the darkness, and I could see them via Heightened Senses but they apparently couldn't see me, nor could they target me. They just stood there while I Mind Sear'd them into elf sushi.
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.

HousePet
Perspiring Physicist
Posts: 6215
Joined: Sun Sep 09, 2012 7:43 am

Re: Better Tactical AI Addon

#10 Post by HousePet »

Have you tried reentering the md5 value? Sometimes that works.
My feedback meter decays into coding. Give me feedback and I make mods.

Doctornull
Sher'Tul Godslayer
Posts: 2402
Joined: Tue Jun 18, 2013 10:46 pm
Location: Ambush!

Re: Better Tactical AI Addon

#11 Post by Doctornull »

A rare Mindslayer just spiked his aura at me, doing me some damage and utterly murdering two of his allies.

Maybe there's something off about targeting compassion?
Check out my addons: Nullpack (classes), Null Tweaks (items & talents), and New Gems fork.

jenx
Sher'Tul Godslayer
Posts: 2263
Joined: Mon Feb 14, 2011 11:16 pm

Re: Better Tactical AI Addon

#12 Post by jenx »

Doctornull wrote:A rare Mindslayer just spiked his aura at me, doing me some damage and utterly murdering two of his allies.

Maybe there's something off about targeting compassion?
No, that's probably correct. his allies don't mean as much to him than does killing you :P
MADNESS rocks

Jeoshua
Cornac
Posts: 37
Joined: Sat Sep 14, 2013 2:08 pm

Re: Better Tactical AI Addon

#13 Post by Jeoshua »

I'm getting the invalidation, too. As far as an md5 checksum, I'm getting:

dddb00cdeb361f428fd4299d75eba4c0

Maybe you have the right checksum, but uploaded the wrong file?

jenx
Sher'Tul Godslayer
Posts: 2263
Joined: Mon Feb 14, 2011 11:16 pm

Re: Better Tactical AI Addon

#14 Post by jenx »

Jeoshua wrote:I'm getting the invalidation, too. As far as an md5 checksum, I'm getting:

dddb00cdeb361f428fd4299d75eba4c0

Maybe you have the right checksum, but uploaded the wrong file?
I've reloaded with md5. hopefully this works now!
MADNESS rocks

Jeoshua
Cornac
Posts: 37
Joined: Sat Sep 14, 2013 2:08 pm

Re: Better Tactical AI Addon

#15 Post by Jeoshua »

Well this one doesn't seem to be working for me, either. Interesting thought tho:

The file is claimed to be named tome-better-tactical-ai.teaa on that download page. The actual file link is sitting in the /games/addons/tome-better-tactical-ai-0/ directory on the website, and the file that actually gets downloaded is tome-better-tactical-ai_0.teaa. None of these match, and might be throwing the system off. I tried all three names to no avail, and even the old one that was loaded before.

It's sad because this file definitely works. The AI does seem to really be a lot more intelligently using its abilities. But not being able to validate makes it a difficult decision to not use it.

Post Reply