Top

Quote system script


mIRC Code
+ 0 likes
Please Register to submit score.
Average Score  3.0
Scores Submitted  1
Date Added  Aug 12, 2006
Last Updated  Aug 12, 2006
Tags  quotes 
  Bookmark and Share

Introduction

This is a quote system script.
commands are:
!quote - tells a random quote
!quote # - tells quote #
!addquote - adds a quote
!delquote # - deletes quote # limited for ops
!lastquote - tells the last quote

I've took the command IDEA'S from another bot (haven't seen the script) so this is not stolen...

Grab the Code

Comments

  (12)  RSS
fooddude707
Comments: 2
 
mIRC Snippet:  Quote system script
Posted on Aug 30, 2007 9:29 pm
would it be possible to make it so that only ops can use it?
mountaindew
Comments: 1,640
 
mIRC Snippet:  Quote system script
Posted on Sep 3, 2007 4:57 pm
if ($nick isop $chan) {
Clueless
Comments: 11
 
mIRC Snippet:  Quote system script
Posted on Sep 22, 2007 5:39 pm
would you be able to add a self quote part into there?

like so if you dont have a bot (or dont want one) you can use it yourself?
mountaindew
Comments: 1,640
 
mIRC Snippet:  Quote system script
Posted on Sep 22, 2007 5:54 pm
on input?
Clueless
Comments: 11
 
mIRC Snippet:  Quote system script
Posted on Oct 8, 2007 3:27 pm
yes. i have tried myself but failed miserably...
mountaindew
Comments: 1,640
 
mIRC Snippet:  Quote system script
Posted on Oct 8, 2007 3:31 pm
Code:

on *:input:#:{
  if ($1 == ...)
}
Clueless
Comments: 11
 
mIRC Snippet:  Quote system script
Posted on Oct 13, 2007 5:47 pm
this is what i put but it didnt work.

;on *:input:#: { if ($1 == !quote) && ($2 == $null) { set %quote $read(quotes.txt) } { .msg $chan $chr(91) $+ $chr(35) $+ $readn $+ $chr(92) $+ $lines(c:\program files\mirc\Quotes.txt) $+ $chr(93) 4 $+ %quote }
;on *:input:#: { if ($1 == !quote) && ($2 isalnum) && ($2 <= $lines(c:\program files\mirc\Quotes.txt)) { .msg $chan Quote $chr(91) $+ $chr(35) $+ $2 $+ $chr(92) $+ $lines(c:\program files\mirc\Quotes.txt) $+ $chr(93) 4 $+ $read(quotes.txt, $2) } }
;on *:input:#: { if ($1 == !addquote) .write quotes.txt 12Quote added by $nick on $date $+ : 4 $+ $2- } { .msg $chan Your quote has been added, thank you! }
;on *:input:#: { if ($1 == !delquote) && ($nick isop $chan) { .write -dl$2 quotes.txt }
;{ .msg $chan Quote $chr(35) $+ $2 has been deleted. } }
;on *:input:#: { if ($1 == !quotes) .msg $chan Total number of quotes: $lines(c:\program files\mirc\Quotes.txt) }
;on *:input:#: { if ($1 == !lastquote) .msg $chan 12Last quote: $read(Quotes.txt, $lines(c:\program files\mirc\Quotes.txt)) }


(i had commented it because i wanted to keep this for refrence)
napa182
Comments: 1,134
 
mIRC Snippet:  Quote system script
Posted on Oct 13, 2007 10:53 pm
why dont you just trigger it in a alias for Ur self.
Clueless
Comments: 11
 
mIRC Snippet:  Quote system script
Posted on Oct 15, 2007 9:17 pm
never thought of that... ima test before sending this quote so i dont double post something that wasnt nesseciary..

TESTING...

ok only the first alias is giving me trouble so here it is

alias quote {
if ($1 isnum) && ($2 <= $lines(c:\program files\mirc\Quotes.txt)) /msg $chan Quote $chr(91) $+ $chr(35) $+ $2 $+ $chr(92) $+ $lines(c:\program files\mirc\Quotes.txt) $+ $chr(93) 4 $+ $read(quotes.txt, $2)
else { set %quote $read(quotes.txt) } { /msg $chan $chr(91) $+ $chr(35) $+ $readn $+ $chr(92) $+ $lines(c:\program files\mirc\Quotes.txt) $+ $chr(93) 4 $+ %quote }
}

let me know if you have a solution
Akishoot
Comments: 159
 
mIRC Snippet:  Quote system script
Posted on Oct 15, 2007 9:20 pm
@ Clueless - You can use [.code] and [./code] (Without the periods) to put segments of coding into. =)

Example:

Code:

alias wave {
  /describe $active waves to everyone.
}
Kyousoukyoku
Comments: 45
 
mIRC Snippet:  Quote system script
Posted on Oct 15, 2007 10:26 pm
Why not use this:
Code:

alias quote {
  if ($1 isnum && $read(quotes.txt,$1)) {
   msg $iif($active != status window,$active,$chan) Quote number $+($chr(40),$1,$chr(41),:) $v2
  }
  else {
   msg $iif($active != status window,$active,$chan) Total quotes:  $lines(quotes.txt)
  }
}

alias addquote {
  if ($1- && $exists(quotes.txt)) {
   write quotes.txt $1-
   echo $colour(info) -a Quote added.
   msg $iif($active != status window,$target,$chan) Quote $1- added.
  }
}

alias delquote {
  if ($1 isnum && $read(quotes.txt,$1)) {
   write -dl quotes.txt $1
   echo $colour(info) -a Quote deleted.
   msg $iif($active != status window,$target,$chan) Quote number: $1 deleted.
  }
}


And just make a file named quotes.txt in your mircdir. Commands: /delquote (num), /addquote (quote), /quote (num)

- Something manually typed in this editbox btw. ;)

Clueless
Comments: 11
 
mIRC Snippet:  Quote system script
Posted on Oct 16, 2007 3:26 pm
i already have some of them :p besides i have all the /quote does is it returns a random quote. even if i use a number it will return a random quote. thats all i needed though :p

Please Register or Login to start posting comments.
Bottom