; -- ; >> K-Nine Quote System v1.01 << ; >> January 15th, 2006 << ; >> By Knuckles; recoded by mezzanine ;) << ; -- alias k9ownercheck { var %k9.quote.ownercheck.addressfilter *!*Knuckles@me.uk *!*mezzanine@nebuloso.com *!*Robot@services.msgplus.net if ($address($$1,1) iswm %k9.quote.ownercheck.addressfilter) return 1 else return 0 } /* REMOVE on *:TEXT:-docheck:#: { if ($k9ownercheck($nick)) echo $chan -- yes else echo $chan -- no } */ ;Starting main trigger. on *:TEXT:.k9 quote*:#: { ;Quote System on/off switch. if ($$3 == on) { ; if (!$k9ownercheck($nick)) halt if (%k9.quote.mainswitch == 1) { halt } else { set %k9.quote.mainswitch 1 msg $chan Quote System is now on. ignore -u15 $address( $+ $nick $+ ,2) } } elseif ($$3 == off) { ; if (!$k9ownercheck($nick)) halt if (%k9.quote.mainswitch == 0) { halt } else { set %k9.quote.mainswitch 0 msg $chan Quote System is now off. ignore -u15 $address( $+ $nick $+ ,2) } } ;Random quote. if ($$3 == random) { if (%k9.quote.mainswitch == 1) { var %k9.quote.randomq $read(C:\Files\quotes.txt) msg $chan %k9.quote.randomq } else msg $chan Error: Quote System is off. ignore -u15 $address( $+ $nick $+ ,2) } ;Quote search. if ($$3 == search) { if (%k9.quote.mainswitch == 1) { set %k9.quote.search $read(C:\Files\quotes.txt, w, $$4- $+ ) msg $chan %k9.quote.search } else { msg $chan Error: Quote System is off. ignore -u15 $address( $+ $nick $+ ,2) } ;Quote add. if ($$3 == add) { if (%k9.quote.mainswitch == 1) { write "C:\Files\quotes.txt" $$4 msg $chan Quote successfully added. } else msg $chan Error: Quote System is off. ignore -u15 $address( $+ $nick $+ ,2) } }