on text / on msg ? - 27/04/05 08:57 PM
My script is now like this:
; !scorecalc <roid> <his> <yours>
on $*:Text:m/^!scorecalc\s([0-9]+?)\s([0-9]+?)\s([0-9]+?)$/i:*:{
%g = $roidcalc($2,$3,$4)
msg $chan Result: %g
}
Alias roidcalc { Var %r = $1, %h = $2, %y = $3, %g
%g = $calc((%h / %y) * 10)
If (%g > 20) { %g = 20 }
%g = $calc((%r * %g) * 60)
Return %g
}
on *:Text:!scorecalc help:#:{ /msg $chan Yo $nick type "!scorecalc <roidcap> <hisvalue> <yourvalue>"
}
Seems to work ok.
But If i want to make it possible to answer if I get msg request too ?
Can anyone help?
PS: n00b detected -
; !scorecalc <roid> <his> <yours>
on $*:Text:m/^!scorecalc\s([0-9]+?)\s([0-9]+?)\s([0-9]+?)$/i:*:{
%g = $roidcalc($2,$3,$4)
msg $chan Result: %g
}
Alias roidcalc { Var %r = $1, %h = $2, %y = $3, %g
%g = $calc((%h / %y) * 10)
If (%g > 20) { %g = 20 }
%g = $calc((%r * %g) * 60)
Return %g
}
on *:Text:!scorecalc help:#:{ /msg $chan Yo $nick type "!scorecalc <roidcap> <hisvalue> <yourvalue>"
}
Seems to work ok.
But If i want to make it possible to answer if I get msg request too ?
Can anyone help?
PS: n00b detected -