Cleanup is going to take awhile, so the site is back up but editing has been disabled.

Ai relationship

From HalfLife 2 Knowledge Base

Jump to: navigation, search

Contents

ai_relationship

Half-Life 2 Point Entity


description

AI Relationship - Sets relationships between groups of NPCs in the AI.


properties

  • Name targetname(target_source)
    The name that other entities refer to this entity by.
  • Subject(s) subject(target_name_or_class)
    This is the NPC(s) whose disposition will change. May be a targetname or a classname.
  • Target(s) target(target_name_or_class)
    This is the NPC(s) about whom the Subject(s) will change their disposition. May be a targetname or a classname. If left blank, target will be the player(in a single player map).
  • Disposition disposition(choices) - default: Choose the way the Subject(s) should feel about the Target(s)
    3
    • 1 - Hate (Subject will attack target on sight)*
    • 2 - Fear (Subject will run from target on sight)*
    • 3 - Like (Subject will follow target on sight)*
    • 4 - Neutral (unknown)
      *These conditions depend on the level of Disposition Priority
  • Radius for subject radius(float) - default: 0
  • Disposition Priority rank(integer) - default: 0
    How much the Subject(s) should Like/Hate/Fear the Target(s). Higher priority = stronger feeling.
  • Start Active StartActive(choices)
    • 0 - No
    • 1 - Yes
  • Reciprocal Reciprocal(choices) - default: Set this to YES to have the new relationship mirrored by Target
    • 0 - No
    • 1 - Yes

spawn flags

none.


inputs

  • Kill(void)
    Removes this entity from the world.
  • KillHierarchy(void)
    Removes this entity and all its children from the world.
  • AddOutput(string)
    Adds an entity I/O connection to this entity. Format
  • FireUser1(void)
    Causes this entity's OnUser1 output to be fired.
  • FireUser2(void)
    Causes this entity's OnUser2 output to be fired.
  • FireUser3(void)
    Causes this entity's OnUser3 output to be fired.
  • FireUser4(void)
    Causes this entity's OnUser4 output to be fired.
  • ApplyRelationship(void)
    Apply relationship changes
  • RevertRelationship(void)
    Revert relationship changes

outputs

  • OnUser1(void)
    Fired in response to FireUser1 input.
  • OnUser2(void)
    Fired in response to FireUser2 input.
  • OnUser3(void)
    Fired in response to FireUser3 input.
  • OnUser4(void)
    Fired in response to FireUser4 input.


related tutorials

Submit your tutorial for ai_relationship

Personal tools