Chat Triggers (PARTIAL)
TODO: Write-up explaining chat triggers, including both standard triggers and dynamic regex triggers (particularly a catch-all). Remind the user to activate it with trigger
in on assignment
.
Placeholder
Until this page is written, you can view the old tutorial video here.
Sample Script
Here's a quick sample of a modern interact script with two basic chat triggers.
my_assignment:
type: assignment
actions:
on assignment:
- trigger name:chat state:true
interact scripts:
- my_interact
my_interact:
type: interact
steps:
1:
chat trigger:
1:
trigger: /Hello/ friendly NPC!
script:
- chat "Hello, <player.name>!"
2:
trigger: /Goodbye/ friendly NPC!
script:
- chat "Farewell, <player.name>!"
This script can be assigned to your selected NPC via /ex assignment set my_assignment