Greeting Script

By Kancer on Sep 24, 2003

This is a greeting script for a channel bot, you should "/guser 50 yournick" so you have suffecient access to use this command, type -greeton to turn the greeting on, -setgreeting to set your greeting , -greetoff to turn the greeting off, or -greeting to view the current channel greeting. I'm sure most of you already know how to change this to you're likings anyway :P

;Greeting on/of Script
on *:text:-greeton*:#:{
  if ($nick !isop $chan) {
  .notice $nick You Aren't Allowed Access To This Command! }
  else { set %greeton true
    .notice $nick Greeting Turned On!
  }
}
on *:text:-greetoff*:#:{
  if ($nick !isop $chan) {
  .notice $nick You Are Not Allowed Access To This Command! }
  else { set %greeton false
    .notice $nick Greeting Turned Off!
  }
}

;Greeting Script
on 50:text:-setgreeting *:#:{
  if (%greeton == true) {
    set %greeting $2- | .notice $nick Channel Greeting Set To " $+ $2- $+ "
    else { .notice $nick Greeting Is Off! Turn it on by using "-greeton" to activate the greeting! }
  }
}
on *:JOIN:#:{
  if (%greeton == true) {
  .notice $nick %greeting }
}
on *:text:-greeting*:#:{ notice $nick Current Greeting: " $+ %greeting $+ " }

Comments

Sign in to comment.
Creamlistner   -  Sep 23, 2007

First:
Change the \"on 50:text:-setgreeting :#:\" To: \"on :text:-setgreeting *:#:\"
Otherwise It wont let you load a greeting.
Second, possibly update It to have a toggle on and off setting, It can be annoying to have the same greeting in diffrent rooms, eathier an off switch for the specific room, or diffrent greetings per room?

 Respond  
kyle_6600   -  Dec 05, 2003

i see some bracket mismatches

 Respond  
kyle_6600   -  Dec 05, 2003

i think the code is useful and gr8 for all levels of scripters

 Respond  
Kancer   -  Sep 25, 2003

ty Hawkee, i wrote it up for my bot and thought it to be a great \"step-by-step\" type of thing for newbies, and possibly something even the advanced scripter could use :)

 Respond  
Hawkee   -  Sep 24, 2003

This is some great example code, very simple and easy to follow.

 Respond  
Kancer   -  Sep 24, 2003

anyone think this is useful or should i never post things i make again haha :P

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.