On, http://www.gammon.com.au/forum/?id=6030, you explained how to create a trigger that sends a colored note when hp is low. How can I do this with an an alias script please?
Below is what I was trying, but it doesn't work.
<aliases>
<alias
match="chkhp"
enabled="y"
send_to="12"
sequence="100"
>
<send>require "wait"
wait.make(function () -- Start of Coroutine
Send ("look")
local x = wait.match("^[%/%hp*",2)
if %1 < 50 then
Note ("Your health is low.")
else
Note ("Your health is OK.")
end --
end) -- end of Coroutine</send>
</alias>
</aliases>