Hi all, I'm getting back into MUDing after a long time, and trying to write the simplest trigger is driving me crazy.
My trigger works, and I get the correct output, but before the correct output I get the following:
Error:
Sample Input:
Trigger:
Lua:
If I create the following trigger instead it works fine:
But I'd prefer to keep this stuff in an external file instead of having the code live in my triggers. I have no idea why this is happening and it's been driving me nuts! Any help is appreciated.
Version: Getting the same results on version 5.01 and 4.94.
My trigger works, and I get the correct output, but before the correct output I get the following:
Error:
Error number: 0
Event: Compile error
Description: [string "Trigger: "]:1: unexpected symbol near '<'
Called by: Immediate execution
Sample Input:
<641/641hp 14/14sp 207/207ep 345xp>Trigger:
<trigger
enabled="y"
group="Colorize"
match="<* * * *>"
omit_from_output="y"
script="Prompt"
send_to="12"
sequence="100"
>
<send>%0</send>
</trigger>
Lua:
function Prompt (name, text, wildcards)
Tell ("<")
ColourTell("yellow", "black", wildcards[1] .. " ")
ColourTell("cyan", "black", wildcards[2] .. " ")
ColourTell("magenta", "black", wildcards[3] .. " ")
ColourTell("grey", "black", wildcards[4])
Tell (">")
end
If I create the following trigger instead it works fine:
<trigger
enabled="y"
expand_variables="y"
group="Colorize"
keep_evaluating="y"
match="<* * * *>"
omit_from_output="y"
send_to="12"
sequence="100"
>
<send>Tell ("<")
ColourTell("yellow", "black", "%1" .. " ")
ColourTell("cyan", "black", "%2" .. " ")
ColourTell("magenta", "black", "%3" .. " ")
ColourTell("grey", "black", "%4")
Tell (">")</send>
</trigger>
But I'd prefer to keep this stuff in an external file instead of having the code live in my triggers. I have no idea why this is happening and it's been driving me nuts! Any help is appreciated.
Version: Getting the same results on version 5.01 and 4.94.