TTLG|Thief|Bioshock|System Shock|Deus Ex|Mobile
Results 1 to 8 of 8

Thread: AI signal response priority?

  1. #1
    Registered: Sep 2004

    AI signal response priority? - trying to figure out what the priority does (mostly when sending an AI from one spot to another), found some out by trial and error;

    Default/None -
    Very Low - stops after spotting the player, or if finds slain AIs along the path
    Low - stops after spotting the player, but ignores slain AIs along the path
    Normal -
    High -
    Very High - ignore everything, but death will stop them
    Absolute - nothing stops the AI, not even death

    any idea about the rest?

  2. #2
    Registered: Apr 2011
    This is very rough based on a few minutes looking into the code, but here goes: AIs pick their next goal when their current goal is completed, or when something happens (like an alertness change) that signals them to choose a new goal immediately.

    When picking a goal, the highest priority goal among the current options is chosen.
    If that's a tie, then the type of the goals are compared: the more important one wins.
    If it's still a tie, then the goals are compared to see if one of them relates to a player; if so, it wins.
    And the final tie breaker is to pick whichever goal is closest to the AI.

    This isn't quite the whole story, because in addition to goals, AIs have different modes: combat mode and non-combat mode at least. And things like spotting the player or bodies or suspicious objects is tied into the awareness system, which feeds alertness, which then gives the AI new goals like investigating or attacking—and it's complicated for me to follow how all that links together.

    But here's the priorities for the standard AI goals, and the ranking of the different types of goals at least:

    Standard priorities:
    Idle: very low
    Investigate: low
    Patrol: low
    Start conversation: low
    Follow: normal
    Inform other AIs: normal
    Non-combat damage response: normal
    Pseudoscript actions (default): normal
    Watch actions (default): normal
    Combat: high
    Flee: high
    Die: very high
    Freeze: very high
    Stun: very high

    Goal types (in increasing importance):
    Goto location
    Flee (note: both the stun and freeze goals use the Flee type, so they rank here)
    Last edited by vfig; 27th Sep 2018 at 18:39.

  3. #3
    Registered: Sep 2004
    hmm.. so that would translate into if signal priority is set to "normal", the AI will not stop to investigate slain AIs, as that is action is ranked as "low" etc, correct?

  4. #4
    Registered: Apr 2011
    That looks correct.

    I threw together a test map to be sure. Set up an AI with a Normal priority signal response to go to a marker, then sent the signal to set them off. As they were walking, I dropped a body in front of them. They noticed it and yelled "murder!", but just kept on walking. Once they reached the marker about 10 seconds later, they then started investigating (since they were still alerted and aware of the body).

  5. #5
    Registered: Sep 2004
    thanks - was hoping things would be slightly less complicated, but ah well.

  6. #6
    Registered: Apr 2011
    What is it you're trying to achieve? If you want them to ignore bodies, then the "Notices bodies" property is probably better. If you want them to stop and investigate when they see the body, then use low priority for your response, because the low priority investigate action should win out over the low priority goto.

  7. #7
    Registered: Sep 2004
    nothing in particular (anymore), I was just thinking that a short, simple description of each signal priority level could be handy in the future, but it looks like things are way more complex than expected.

  8. #8
    Registered: Apr 2011
    Does rearranging it this way make it a little easier to figure out?

    Standard AI goals at each priority level, ranked high to low:

    Absolute: (no standard AI goals use absolute priority)
    Very high: Die, Freeze/Stun
    High: Flee, Attack/Defend
    Normal: Damage response, Inform (Investigate), Follow
    Low: Patrol (Goto), Investigate
    Very low: Idle

    Your pseudoscript actions run at a default priority (Normal for watch and response pseudoscripts, Low for conversations), or at a different priority if you choose it. Pseudoscript actions will only beat the standard AI goals of the same priority if they are higher in this ranking (high to low):

    Ranking at equal priority: Die, Flee/Freeze/Stun, Attack/Defend, Investigate, Follow, Goto location, Idle

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts