How reliable is Player.IsActorDetected?

Post » Wed Nov 10, 2010 9:17 pm

All,

I've got a little script that does something when I'm a) sneaking and B) not detected. It has been working perfectly fine for a day or two.


Somehow my game got in this state where my stealth eye is faded but Player.IsActorDetected is returning a value of 1. I'm 10 feet behind a guy, sneaking, and even though the stealth eye is faded, the variable I'm printing out in my debug message says "1" for Player.IsActorDetected.

Is there some bug where maybe a guy I killed is still somehow reporting that I'm detected? Is there a function that gets the faded level of the stealth eye instead of the isActorDetected setting? The eye seems to be accurate, but the function isnt working now. Its like it got in a funky state. I havent changed my code at all from when it was working before.

Thanks
User avatar
Fluffer
 
Posts: 3489
Joined: Thu Jul 05, 2007 6:29 am

Post » Thu Nov 11, 2010 12:47 am

All,

I've got a little script that does something when I'm a) sneaking and B) not detected. It has been working perfectly fine for a day or two.


Somehow my game got in this state where my stealth eye is faded but Player.IsActorDetected is returning a value of 1. I'm 10 feet behind a guy, sneaking, and even though the stealth eye is faded, the variable I'm printing out in my debug message says "1" for Player.IsActorDetected.

Is there some bug where maybe a guy I killed is still somehow reporting that I'm detected? Is there a function that gets the faded level of the stealth eye instead of the isActorDetected setting? The eye seems to be accurate, but the function isnt working now. Its like it got in a funky state. I havent changed my code at all from when it was working before.

Thanks

Yes it happens when the game stops (for a number of reasons) processing an actor's AI when that actor can still detect you, although in my experience the sneak eye usually goes wonky too. Ex: Stand in front of an NPC who detects you and call SetUnconscious 0 on him == player remains detected even outside of NPC's cell until SetUnconscious 1 is called.
Type ShowWhoDetectsPlayer in the console to print a list of all actors who currently detect the player.
User avatar
Susan Elizabeth
 
Posts: 3420
Joined: Sat Oct 21, 2006 4:35 pm


Return to IV - Oblivion