Well I am playing on Aardwolf and am tring to combine what would take two regualer triggers giving two messages into one message.
first idea i had was:
Questor tells you 'As a reward, I am giving you [0-9] quest points and [0-9] gold.'
send: (something like) echo %1 qp %2 gold
You get lucky and gain an extra [0-9] quest points.
send echo %1 qp
and get a script to add the 2 diffrent qp ammounts and send it over a channel with the gold number added as well
any ideas would be helpfull thanks in advance.
ok i have been fiddling with the script posted on the other thread and can't get it to work (when i hit edit script the page is blank could that have something to do with it?) and a error screen pops up say statement expected error in line.
What are you doing? You need to check "enable scripting", set it to VBScript, Then Import those triggers (copy/paste, or importXML). No script file involved.
However, those triggers DO use the MCCP bonus as a fairly important line, is there any reason (assuming youre on the same mud) that you DONT have MCCP turned on (and thus arent getting the bonus?) That line made the whole system a lot easier.
I have done all that (all ready had all that done)
I keep getting this :
Error Number: -2146827286
Event: Execution of line 1 column 50
Description: Syntax error
Line in error:
setvariable "qpgain", Cint(getvariable("qpgain")+
Called By: Immediate execution
Error Number: -2146827282
Event: Execution of line 1 column 51
Description: Expected ')'
Line in error:
setvariable "qpgain", Cint(getvariable("qpgain")+2
Called By: Immediate execution
the second time it fired i didn't notice because i hit my complete quest macro (recalls/uses recall portal, runs to questor and sends quest complete)and left my keyboard to use restroom and came back it caused mushclient to close the muds window.
Though the second is probably better, since you already know that '+ 2' is an integer. If gpgain for some reason isn't, then you would get another error, as a result of adding 2 to a non-number. You need to fix the first line the same way *and* add the value you want to add to it, which I assume was supposed to be '1':
thanks everyone for the help. Flannel even with what you sent me i have to fiddle with to get it to work. for furture refrence this is the set the ended up working.
just realized small typo corrected 12/20/07
<triggers>
<trigger
custom_colour="12"
enabled="y"
ignore_case="y"
keep_evaluating="y"
match="^Questor tells you \'As a reward, I am giving you (\d{1,}) quest points and (\d{1,}) gold\.\'$"
name="QuestTrig1"
regexp="y"
send_to="12"
sequence="98"
>
<send>setvariable "goldgain", %2
setvariable "qpgain", %1
enabletrigger "QuestTrig2", 1
enabletrigger "QuestTrig3", 1
</send>
</trigger>
<trigger
custom_colour="12"
ignore_case="y"
keep_evaluating="y"
match="^You gain an extra (.*?) quest points \'MCCP Bonus\'\.$"
name="QuestTrig3"
regexp="y"
send_to="12"
sequence="98"
>
<send>setvariable "qpgain", Cint(getvariable("qpgain")+%1)
enabletrigger "QuestTrig2", 0
enabletrigger "QuestTrig3", 0
send "gtell Quest Complete: " & getvariable("qpgain") & " qp and " & getvariable("goldgain") & " gold."
</send>
</trigger>
<trigger
custom_colour="12"
ignore_case="y"
keep_evaluating="y"
match="^You get lucky and gain an extra (.*?) quest points\.$"
name="QuestTrig2"
regexp="y"
send_to="12"
sequence="98"
>
<send>setvariable "qpgain", Cint(getvariable("qpgain")+%1)
</send>
</trigger>
</triggers>