[MudWalker] Trigger formatting

Damon G dgaumont at gmail.com
Fri Jan 11 09:56:06 PST 2008


Please help...I saw the script posted in a previous post on this list
but I can't seen to get it to work for me.

Here's the trigger setup I lifted from:

Blastron <blastron at mac.com> wrote:

> Trigger:
> ^(.*)h, ^(.*)m -
>
> Script:
> @@if arg[2] <= 100 then
> drink potion
> @@end

You'll need to convert arg[2] from a string to a number for the
comparison to work:

  @@if tonumber(arg[2]) <= 100 then

<http://www.lua.org/manual/5.0/manual.html#5.1>

So here is my HP bar:

 HP:470/470 C:100%  NRG:180/180(6)  SP:66/117  B:1(81%) G2N:3k

When my SP drops below 50 I want to "evoke tidal wave"

I tried to do this with the following:

Trigger:
SP:^(.*)

Script:
@@if tonumber(arg[1]) <= 50 then
evoke tidal wave
@@end

---

For whatever reason nothing executes. Even if I type "SP:49" into the
console to make it pop up.

Any suggestions?


More information about the MudWalker mailing list