Advertisement
Guest User

Untitled

a guest
Oct 1st, 2017
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
TCL 0.46 KB | None | 0 0
  1. bind pub - !spam inputspam
  2. set spamonoff 0
  3.  
  4. proc inputspam { nick host hand chan } {
  5. if { $text == "on" } {
  6. set spamonoff 1
  7. }
  8. if { $text == "off" } {
  9. set spamonoff 0
  10. }
  11. }
  12. if { $spamonoff == "on" } {
  13. utimer 1 spam
  14. }
  15. proc spam { nick host hand chan text } {
  16. set spamtxt "scripts/spam.txt"
  17. set spamfile [open $spamtxt r]
  18. set spamread [split [read $spamfile] \n]
  19. close $spamfile
  20. putquick "PRIVMSG $chan :[lindex $spamread [rand [llength $spamread]]]"
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement