Checking for level to determine if outmatched?

Post » Tue Feb 16, 2016 9:48 am

These are some of the AI Attributes from the AI Tab.


Cowardly 0 Will always avoid/flee from threats. Cowardly actors NEVER engage in combat under any circumstances. Confidence can never be lower than 0.


Cautious 1 Will avoid/flee from threats unless the Actor is stronger than the threat.

How does the actor AI determine if they are stronger than the threat?


Average 2 Will avoid/flee from threats if outmatched.

How does the actor AI determine if they are outmatched?


Brave 3 Will avoid/flee from threats only if severely outmatched.

How does the actor AI determine if they are severely outmatched?


Does the AI check for the level of the opponent?


Does this change if the opponent is the player?
User avatar
Evaa
 
Posts: 3502
Joined: Mon Dec 18, 2006 9:11 am

Post » Tue Feb 16, 2016 5:42 am

To answer the last first, it appears to be checking ONLY the player. Everyone seems to go kamikaze against dragons, and vampires, otherwise there wouldn't be mods for that.



I'd expect a simple Player.GetLevel() call does it all.

User avatar
Soph
 
Posts: 3499
Joined: Fri Oct 13, 2006 8:24 am

Post » Tue Feb 16, 2016 6:31 am

I think Ghastly is partly right, but I also think there might be a bit more going on.



Looking on the Wiki, there are a number of Game Settings associated with Confidence and Intimidation. For example, someone who is 'cowardly' gets a multiplier of zero, someone who is 'foolhardy' gets a multiplier of 100, and an 'average' person gets a multiplier of 1. This makes me think there is some kind of calculation based upon a 'threshold', which is probably tied to the Player's Level/Intimidation. I assume 'cowardly' is to make it never trigger, and 'foolhardy' is to guarantee it triggers.



Something like : AttackChance = ( Target Level + NPC's Random Confidence) * Intimidation Confidence Multiplier. And if AttackChance is high enough, they attack.



The wiki says that each Actor chooses a confidence between -0.5 and +0.5, and then there are these multipliers. It'd maybe be worth setting up an NPC, tweaking those game settings, and seeing how he reacts to being attacked by the Player. It's also possible to modify the Player's Intimidation via Perks Entry Points, which makes me think there's probably a 'base intimidation' based on the Player's Level or something.

User avatar
Keeley Stevens
 
Posts: 3398
Joined: Wed Sep 06, 2006 6:04 pm

Post » Tue Feb 16, 2016 10:10 am


Yes that would seem to be the case.



I have seen NPCs run from other NPCs though.



The reason I am asking is this:



As you know these are some of the AI Attributes from the AI Tab.


Cowardly 0 Will always avoid/flee from threats. Cowardly actors NEVER engage in combat under any circumstances. Confidence can never be lower than 0.


Cautious 1 Will avoid/flee from threats unless the Actor is stronger than the threat.


Average 2 Will avoid/flee from threats if outmatched.


Brave 3 Will avoid/flee from threats only if severely outmatched.


What if the opponent is the player and they have leveled up higher than the actor. Will that not cause the actor to flee from the player?


Foolhardy 4 Will never avoid/flee from anyone.

This is the setting I use whenever I can.



As far as how this effects the stealth gameplay.


Remember " Will avoid/flee from threats if outmatched. "


This basically kills any challenging stealth gameplay in environments that have opponents of a lover level than the player and are not set to Foolhardy.


They will not engage the player they avoid the player if the player has leveled above them.



"In my mod I keep the player at level 1, and it is very effective in regards to keeping the opponents aggressive. It also makes stealth game play more challenging. One other huge benefit to not leveling up the game is you can optimize the environment for combat."


People have been responding like this.


" AI does not get affected by player level. I know this because I deal with mob AI every day on my project."


All my testing clearly indicates otherwise. I do not want to give misinformation. I even suspect the level of the player and the opponents is the cause of my arrows issue.


An issue in which arrows are bouncing off opponents that I have leveled above their normal level.


Some have resulted in heavy and light armor skills increasing to 100. However wizards armor skill stays a 15 no matter how high you level them. Most of them anyway, and the arrows still bounce off them.
User avatar
Lou
 
Posts: 3518
Joined: Wed Aug 23, 2006 6:56 pm

Post » Mon Feb 15, 2016 10:28 pm

The confidence decision won;t be just made once, but at each point that the actor is preparing an attack. They're already deciding whether to use a ranged or melee attack, and the "do I attack or flee" choice must also be rolled in there. A wounded opponent will sometimes break off and run off to heal. So the algorithm is also considering current health. However, at the start, they're at 100% of their health, so I'd assume that has no effect until it starts to drop.

User avatar
Isabella X
 
Posts: 3373
Joined: Sat Dec 02, 2006 3:44 am

Post » Tue Feb 16, 2016 1:05 pm


I agree.

User avatar
Carlos Vazquez
 
Posts: 3407
Joined: Sat Aug 25, 2007 10:19 am

Post » Tue Feb 16, 2016 11:37 am


Ya, It would have to be based on player level or would seem to have to be because it would change during the game as the player leveled up.

User avatar
Katie Pollard
 
Posts: 3460
Joined: Thu Nov 09, 2006 11:23 pm


Return to V - Skyrim