there must be 3 argments for a script function if i want
send some values into scritp variables??!!
eg.
Trigger: ^.*Mana:(\s+)(\d+)/(\s+)(\d+)
send:
script:Ongetinfo
//function in script
function Ongetinfo(TriggerName, trig_line, wildcards)
{
var wildcard1 = VBArray(wildcards).toArray();
var Mana = wildcard1[1];
var maxMana = wildcard1[3];
world.note("Mana is " + Mana);
world.note("maxMana is "+ maxMana);
}
i know this will work good, but, i dont know how does it
work, could you explain it to me? :) such as what each
argment means, why the "wildcards" must be the 3rd argment,
etc...
and, is there any other way make it easier to send
something that i got from regexp into script(i want to send
more that one value once a time, so i dont wanna select
"Send to Variable(lable is name)" in list box) ?
if not, will you do it in next version? :P
send some values into scritp variables??!!
eg.
Trigger: ^.*Mana:(\s+)(\d+)/(\s+)(\d+)
send:
script:Ongetinfo
//function in script
function Ongetinfo(TriggerName, trig_line, wildcards)
{
var wildcard1 = VBArray(wildcards).toArray();
var Mana = wildcard1[1];
var maxMana = wildcard1[3];
world.note("Mana is " + Mana);
world.note("maxMana is "+ maxMana);
}
i know this will work good, but, i dont know how does it
work, could you explain it to me? :) such as what each
argment means, why the "wildcards" must be the 3rd argment,
etc...
and, is there any other way make it easier to send
something that i got from regexp into script(i want to send
more that one value once a time, so i dont wanna select
"Send to Variable(lable is name)" in list box) ?
if not, will you do it in next version? :P