unixwz0r

motd.tcl

Mar 24th, 2015
446
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
TCL 1.49 KB | None | 0 0
  1. # UNIXwz0r motd
  2.  
  3. ###########################
  4. #= CONFIGURATION SECTION =#
  5. ###########################
  6.  
  7. ## PUT THE CHANNEL HERE IN WHICH YOU WANT THIS SCRIPT TO WORK ##
  8. ## YOU CAN USE THIS SCRIPT IN ONLY ONE CHANNEL SO DONOT ENTER MORE THAN ONE CHANNEL IT WILL CAUSE TROBLE ##
  9.  
  10. set urchan "#bsdgeekclub"
  11.  
  12. ## ENTER THE PATH OF THE FILE CONTAINING WELCOME MESSAGES ##
  13. ## IF YOU WILL LEAVE IT AS IT IS YOU HAVE TO PUT THE "motd.txt" FILE INTO SCRIPTS FOLDER ##
  14.  
  15. set txtfile1 "/home/gary/motd.txt"
  16.  
  17. ###########################
  18. # CONFIGURATION ENDS HERE #
  19. ###########################
  20.  
  21.  
  22. #--------------------------------------------------------------------------------------------------------------------#
  23. #  SCRIPT STARTS FROM HERE.YOU CAN MAKE MODIFICATIONS AT UR OWN RISK, I DONT RESTRICT YOU TO NOT TO TOUCH THE CODE!  #
  24. #--------------------------------------------------------------------------------------------------------------------#
  25.  
  26. bind join - * UNIXwz0r:wjoin
  27.  
  28. proc UNIXwz0r:wjoin {nick host handle chan} {
  29.  global urchan txtfile1
  30.  set aire $urchan
  31.  set ranadil [open $txtfile1 r]
  32.  set readvar [split [read $ranadil] \n]
  33.  close $ranadil
  34.  foreach line $readvar {
  35.  puthelp "PRIVMSG $aire :$line"
  36.  
  37.  }
  38. }
  39.  
  40.  
  41. #Ever Seen such simple coding ??? eh
  42.  
  43. ##################################################################################################
  44. putlog "UNIXwz0r motd.tcl script Loaded!"
  45. ##################################################################################################
Advertisement
Add Comment
Please, Sign In to add comment