I want to have a trigger change a variable in a script...How do I do this?
Variable Usage
Posted by Xalfor on Fri 28 Mar 2003 09:54 AM — 3 posts, 14,036 views.
You can make the trigger call a script like this:
If the variable is one of the trigger wildcards, just use that, eg.
However in that case you can do it without a script, like this:
sub OnMyTrigger (name, line, wildcards)
world.SetVariable "myvariable", "mycontents"
end sub
If the variable is one of the trigger wildcards, just use that, eg.
sub OnMyTrigger (name, line, wildcards)
world.SetVariable "myvariable", wildcards (1)
end sub
However in that case you can do it without a script, like this:
<triggers>
<trigger
custom_colour="7"
enabled="y"
match="A * attacks you!"
send_to="9"
sequence="100"
variable="target"
>
<send>%1</send>
</trigger>
</triggers>
Thanks...Trying to make a script to do a puzzle in a MUD I play automatically, for when I'm feeling lazy. Have sort of an idea on how oto do it, but am not totally sure.