Slingers can also benefit from counterstrikes at long range, but I think it's too rare to have your target attack you (with the right damage type), then you attack your target when you are far apart from each other. I may have it check riposte though...stinkstink wrote:Might want to allow this if they have Wave of Power off cooldown.lukep wrote:- Block no longer used as an attack at long range
Improving tactical information for AI
Moderator: Moderator
Re: Improving tactical information for AI
Re: Improving tactical information for AI
The only possible problem I can see is missing checks for target.x and target.y. Trylukep wrote:New version coming, but a inscrutable bug first:Why doesn't that work?Code: Select all
newai(Talents.T_BLOCK, { ATTACK = function(self, t, target) if target and core.fov.distance(self.x, self.y, target.x, target.y) > 1 then return 0 end return 4 end, DEFEND = 3 })
Code: Select all
newai(Talents.T_BLOCK, { ATTACK = function(self, t, target) if target and target.x and target.y and core.fov.distance(self.x, self.y, target.x, target.y) <= 1 then return 4 end return 0 end, DEFEND = 3 })
Re: Improving tactical information for AI
HUGE bug fixed: I was preventing anything from being calculated properly. Replaced all uppercase types (eg. ATTACK, BUFF) with lowercase ones (eg. attack, buff). This also seems to fix the block issue, which was just the same bug, but I noticed it sooner.
Also, Rush is now only used from range 2, and disable's weight reduced to (attack weight/2 + best disable value), from (attack weight + best disable value).
Also, Rush is now only used from range 2, and disable's weight reduced to (attack weight/2 + best disable value), from (attack weight + best disable value).
- Attachments
-
- tome-betterai.zip
- (22.01 KiB) Downloaded 218 times
Re: Improving tactical information for AI
That is huge! And a quick check shows that the tactical AI in 1.0 and current svn has the same bug. I wonder if how much smarter the native AI would get even without your tweaks if this was fixed.lukep wrote:HUGE bug fixed: I was preventing anything from being calculated properly. Replaced all uppercase types (eg. ATTACK, BUFF) with lowercase ones (eg. attack, buff). This also seems to fix the block issue, which was just the same bug, but I noticed it sooner.
Re: Improving tactical information for AI
Not a bug in the main version. IIRC, it runs the talents through function that does that automatically.aardvark wrote:That is huge! And a quick check shows that the tactical AI in 1.0 and current svn has the same bug. I wonder if how much smarter the native AI would get even without your tweaks if this was fixed.
In my bugged version,
Code: Select all
=game.player:getTalentFromId(game.player.T_BLOCK).tactical
Code: Select all
=game.player:getTalentFromId(game.player.T_SPIT_POISON).tactical
EDIT: and, after a bit of preliminary testing, rares seem smarter, deadlier, and more aggressive. Of course, it still doesn't help when they spawn with mis-matched talents and weapons.
Re: Improving tactical information for AI
You're right. It's in data/talents.lua. It looks like you could use the "ToME:load" hook to "superload" the newTalent() function with one that changes your tactical tables to lowercase, just like data/talents.lua does for the current tables. That would make your changes easier for darkgod to pull into trunk, if he decides to do that.
-
- Spiderkin
- Posts: 543
- Joined: Sat Feb 11, 2012 1:12 am
Re: Improving tactical information for AI
How are you handling Fearscape? Because the priority should be dialed way down if the user isn't a demon somehow, or the target is.
Re: Improving tactical information for AI
I've left it as-is, which is to say, that it should only be used against targets that have finished the game, if I'm reading it right. (same for Dreamscape).
Also, I just added a lower-casing part to my function, so I can keep it looking the same as it is in the talents files.
Idea: add/remove parts of this addon, and make the final bosses fight each other to objectively see if it is helping them be deadlier. I'm thinking 1v1 sun paladin vs. reaver.
Also, I just added a lower-casing part to my function, so I can keep it looking the same as it is in the talents files.
Idea: add/remove parts of this addon, and make the final bosses fight each other to objectively see if it is helping them be deadlier. I'm thinking 1v1 sun paladin vs. reaver.
Re: Improving tactical information for AI
Interesting; know that my eye is on you ! 

[tome] joylove: You can't just release an expansion like one would release a Kraken XD
--
[tome] phantomfrettchen: your ability not to tease anyone is simply stunning
--
[tome] phantomfrettchen: your ability not to tease anyone is simply stunning

Re: Improving tactical information for AI
The Evil Eye!
Hmmm that could be a nice artifact name...
Hmmm that could be a nice artifact name...
My feedback meter decays into coding. Give me feedback and I make mods.
Re: Improving tactical information for AI
Haven't tried this yet, but I was wondering if you have done anything about how enemies use traps and other trap-like talents, because right now they are really stupid about it; they tend to use them on the space you are currently standing, which doesn't trigger them. They should try to place them in front of you to block your advance, or perhaps behind you to block your escape.
Re: Improving tactical information for AI
I haven't done anything with traps, or glyphs, or aether beam/breach, or aiming summons, or manually aiming to hit/miss different targets. All of those changes would be good, but quite difficult to do, and (necessarily) have very small niches. I probably won't do anything about them, and if I do, it would be after all of the easier work is done.Amphouse wrote:Haven't tried this yet, but I was wondering if you have done anything about how enemies use traps and other trap-like talents, because right now they are really stupid about it; they tend to use them on the space you are currently standing, which doesn't trigger them. They should try to place them in front of you to block your advance, or perhaps behind you to block your escape.
Re: Improving tactical information for AI
I got through the rest of the talents (total number of talents altered: 261).
Next up:
- better, universal damage estimator (and using it in stuff), also, a effect application chance calculator like "_M:canBe("foo")", but returning a percentage instead.
- new (NPC-exclusive) talents like "switch to fire infusion" and "spike physical psionic shield".
- look at making CURE into mental, physical, and magical, at least.
- bug testing
Maybe:
- Silence is better on spellcasters, disable is better on melee/archer, removing buffs is better when they have buffs,
Next up:
- better, universal damage estimator (and using it in stuff), also, a effect application chance calculator like "_M:canBe("foo")", but returning a percentage instead.
- new (NPC-exclusive) talents like "switch to fire infusion" and "spike physical psionic shield".
- look at making CURE into mental, physical, and magical, at least.
- bug testing
Maybe:
- Silence is better on spellcasters, disable is better on melee/archer, removing buffs is better when they have buffs,
- Attachments
-
- tome-betterai.zip
- (22.15 KiB) Downloaded 192 times
Re: Improving tactical information for AI
Why dont you upload it to te4.org 

[tome] joylove: You can't just release an expansion like one would release a Kraken XD
--
[tome] phantomfrettchen: your ability not to tease anyone is simply stunning
--
[tome] phantomfrettchen: your ability not to tease anyone is simply stunning
