Response System: Difference between revisions
Jump to navigation
Jump to search
m (→Introduction) |
No edit summary |
||
Line 1: | Line 1: | ||
{{stub}} | {{stub}} | ||
==Introduction== | ==Introduction== | ||
In HL2, AIs | In HL2, AIs speak based on [[Concepts]]. | ||
<code>/scripts/talker/response_rules.txt</code> is the base script file for this Response System. It contains [[Criteria|criterion]]/[[Rules|rule]]/[[Responses|response]] definitions. This controls interactive NPC talks in game. e.g. It makes Alyx say "Excuse me," Citizens greet, Vortigaunts tell stories, etc. | |||
The Response system checks each rule against the set, give it a numeric score based on the rule's set of criteria. Then the system picks one rule with the highest score, dispatch a response that the rule points. | |||
The | |||
* | *[[Concepts]] | ||
* | *[[Criteria]] | ||
* | *[[Enumeration]] | ||
* | *[[Contexts]] | ||
* | *[[Rules]] | ||
* | *[[Reponses]] | ||
==Add your new custum NPC to the Response System== | ==Add your new custum NPC to the Response System== | ||
*Make your NPC derived from | *Make your NPC derived from NPC_talker | ||
*Write a new rule script for your NPC | *Write a new rule script for your NPC | ||
**See npc_xxx.txt for examples | **See npc_xxx.txt for examples |
Revision as of 20:29, 7 August 2005
Introduction
In HL2, AIs speak based on Concepts.
/scripts/talker/response_rules.txt
is the base script file for this Response System. It contains criterion/rule/response definitions. This controls interactive NPC talks in game. e.g. It makes Alyx say "Excuse me," Citizens greet, Vortigaunts tell stories, etc.
The Response system checks each rule against the set, give it a numeric score based on the rule's set of criteria. Then the system picks one rule with the highest score, dispatch a response that the rule points.
Add your new custum NPC to the Response System
- Make your NPC derived from NPC_talker
- Write a new rule script for your NPC
- See npc_xxx.txt for examples
- Include the new script in
/scripts/talker/response_rules.txt