Cleanup is going to take awhile, so the site is back up but editing has been disabled.
Ai relationship
From HalfLife 2 Knowledge Base
Contents |
[edit]
ai_relationship
Half-Life 2 Point Entity
[edit]
description
AI Relationship - Sets relationships between groups of NPCs in the AI.
[edit]
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
[edit]
spawn flags
none.
[edit]
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
[edit]
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.
[edit]
related tutorials
Submit your tutorial for ai_relationship

