Max's Acronyms

By MaxEvans on Apr 11, 2009

After working on this for a while and getting it just the way I want it, I decided to post it here for other people to use.

This is a simple acronyms script, which basically shows "Laughing Out Loud" instead of just "lol". It has a lot of acronyms in it, most of the popular ones. If I missed any, or you want to suggest one for me to add, just post a comment or send me a pm.

This script is different than most acronyms scripts I've seen. I made this one so you can choose the colors you want for first and second colors, as well as turn the script on and off. I have five color presets with some nice names, and they look nice too. Commands are pretty simple, I have alias commands and a menu.

Alias commands are as follows:

To turn the acronyms on and off just type /acro. It will turn it on and off.

For choosing colors to use, just type /acolors and then the numbers for the colors without the ctrl+k with a space between. (For example: /acolors 9 3) It will echo a confirmation showing the colors you chose.

You can even select background colors as well. By using "/acolors 9,3 3,9". Or any other colors you want.

Color Index (For Color Numbers):
Image

For presets:

"/acrored" for Strawberry Daiquiri preset
"/acroblue" for Blueberry Paradise preset
"/acrogrey" for Stormy Sunrise preset
"/acrory" for Strawberry Banana preset
"/acropy" for Pink Lemonade preset

Then the menu is pretty self explanatory. Does the same thing the aliases do, just in menu format. The color chooser has input requests for the numbers without the ctrl+k. As well as an advertiser. =]

Screenshot:

Image

;Main Acronym Script

#acro on
on *:Input:*:{
  if (/* iswm $1-) { $1- | halt } 
  if ($1 == lol) { msg $active  $+ %fac $+ L $+ %sac $+ aughing  $+ %fac $+ O $+ %sac $+ ut  $+ %fac $+ L $+ %sac $+ oud $2- | halt }
  if ($1 == rofl) { msg $active  $+ %fac $+ R $+ %sac $+ olling  $+ %fac $+ O $+ %sac $+ n  $+ %fac $+ T $+ %sac $+ he  $+ %fac $+ F $+ %sac $+ loor  $+ %fac $+ L $+ %sac $+ aughing $2- | halt }
  if ($1 == lmao) { msg $active  $+ %fac $+ L $+ %sac $+ aughing  $+ %fac $+ M $+ %sac $+ y  $+ %fac $+ A $+ %sac $+ ss  $+ %fac $+ O $+ %sac $+ ff $2- | halt }
  if ($1 == lmfao) { msg $active  $+ %fac $+ L $+ %sac $+ aughing  $+ %fac $+ M $+ %sac $+ y  $+ %fac $+ F $+ %sac $+ ucking  $+ %fac $+ A $+ %sac $+ ss  $+ %fac $+ O $+ %sac $+ ff $2- | halt }
  if ($1 == brb) { msg $active   $+ %fac $+ B $+ %sac $+ e  $+ %fac $+ R $+ %sac $+ ight  $+ %fac $+ B $+ %sac $+ ack $2- | halt }
  if ($1 == bbs) { msg $active  $+ %fac $+ B $+ %sac $+ e  $+ %fac $+ B $+ %sac $+ ack  $+ %fac $+ S $+ %sac $+ oon $2- | halt }
  if ($1 == bbl) { msg $active  $+ %fac $+ B $+ %sac $+ e  $+ %fac $+ B $+ %sac $+ ack  $+ %fac $+ L $+ %sac $+ ater $2- | halt }
  if ($1 == ok) { msg $active  $+ %fac $+ O $+ %sac $+ kay $2- | halt }
  if ($1 == okay) { msg $active  $+ %fac $+ O $+ %sac $+ kay $2- | halt }
  if ($1 == yes) { msg $active  $+ %fac $+ Y $+ %sac $+ es $2- | halt }
  if ($1 == no) { msg $active  $+ %fac $+ N $+ %sac $+ o $2- | halt }
  if ($1 == xd) { msg $active  $+ %fac $+ x $+ %sac $+ D $2- | halt }
  if ($1 == xdd) { msg $active  $+ %fac $+ x $+ %sac $+ DD $2- | halt }
  if ($1 == wtf) { msg $active  $+ %fac $+ W $+ %sac $+ hat  $+ %fac $+ T $+ %sac $+ he  $+ %fac $+ F $+ %sac $+ uck $+  $+ %fac $+ ? $2- | halt }
  if ($1 == wth) { msg $active  $+ %fac $+ W $+ %sac $+ hat  $+ %fac $+ T $+ %sac $+ he  $+ %fac $+ H $+ %sac $+ ell $+  $+ %fac $+ ? $2- | halt }
  if ($1 == ty) { msg $active  $+ %fac $+ T $+ %sac $+ hank  $+ %fac $+ Y $+ %sac $+ ou $2- | halt }
  if ($1 == yw) { msg $active  $+ %fac $+ Y $+ %sac $+ ou're  $+ %fac $+ W $+ %sac $+ elcome $2- | halt }
  if ($1 == np) { msg $active  $+ %fac $+ N $+ %sac $+ o  $+ %fac $+ P $+ %sac $+ roblem $2- | halt }
  if ($1 == sys) { msg $active  $+ %fac $+ S $+ %sac $+ ee  $+ %fac $+ Y $+ %sac $+ ou  $+ %fac $+ S $+ %sac $+ oon $2- | halt }      
  if ($1 == syl) { msg $active  $+ %fac $+ S $+ %sac $+ ee  $+ %fac $+ Y $+ %sac $+ ou  $+ %fac $+ L $+ %sac $+ ater $2- | halt }
  if ($1 == btw) { msg $active  $+ %fac $+ B $+ %sac $+ y  $+ %fac $+ T $+ %sac $+ he  $+ %fac $+ W $+ %sac $+ ay $2- | halt }
  if ($1 == omg) { msg $active  $+ %fac $+ O $+ %sac $+ h  $+ %fac $+ M $+ %sac $+ y  $+ %fac $+ G $+ %sac $+ od $2- | halt }
  if ($1 == wb) { msg $active  $+ %fac $+ W $+ %sac $+ elcome  $+ %fac $+ B $+ %sac $+ ack $2- | halt }
  if ($1 == idk) { msg $active  $+ %fac $+ I  $+ %fac $+ D $+ %sac $+ on't  $+ %fac $+ K $+ %sac $+ now $2- | halt }
  if ($1 == nm) { msg $active  $+ %fac $+ N $+ %sac $+ othing  $+ %fac $+ M $+ %sac $+ uch $2- | halt }
  if ($1 == gtg) { msg $active  $+ %fac $+ G $+ %sac $+ ot  $+ %fac $+ T $+ %sac $+ o  $+ %fac $+ G $+ %sac $+ o $2- | halt }
}
#acro end

;Set Acronym Color Alias

alias acolors {
  /set %fac $$1 | set %sac $$2 | echo -a *  $+ %fac $+ C $+ %sac $+ olor  $+ %fac $+ P $+ %sac $+ references  $+ %fac $+ H $+ %sac $+ ave  $+ %fac $+ B $+ %sac $+ een  $+ %fac $+ S $+ %sac $+ et -  $+ %fac $+ M $+ %sac $+ ax's $+ %fac A $+ %sac $+ cronyms
}

;On/Off Alias

alias acro {
  $iif($group(#acro) == off,.enable,.disable) #acro | $iif($group(#acro) == on,echo *  $+ %fac $+ M $+ %sac $+ ax's  $+ %fac $+ A $+ %sac $+ cronyms  $+ %fac $+ A $+ %sac $+ re  $+ %fac $+ N $+ %sac $+ ow  $+ %fac $+ O $+ %sac $+ n, echo *  $+ %fac $+ M $+ %sac $+ ax's  $+ %fac $+ A $+ %sac $+ cronyms  $+ %fac $+ A $+ %sac $+ re  $+ %fac $+ N $+ %sac $+ ow  $+ %fac $+ O $+ %sac $+ ff)
}

;Color Preset Aliases

alias acrored {
  set %fac 5
  set %sac 4
  echo -a * 5S4trawberry 5D4aiquiri 5P4reset 5C4hosen - 5M4ax's 5A4cronyms
}
alias acroblue {
  set %fac 2
  set %sac 12
  echo -a * 2B12lueberry 2P12aradise 2P12reset 2C12hosen - 2M12ax's 2A12cronyms
}
alias acrogrey {
  set %fac 14
  set %sac 15
  echo -a * 14S15tormy 14S15unrise 14P15reset 14C15hosen - 14M15ax's 14A15cronyms
}
alias acrory {
  set %fac 4
  set %sac 8
  echo -a * 4S8trawberry 4B8anana 4P8reset 4C8hosen - 4M8ax's 4A8cronyms
}
alias acropy {
  set %fac 13
  set %sac 8
  echo -a * 13P8ink 13L8emonade 13P8reset 13C8hosen - 13M8ax's 13A8cronyms
}

;Menu

menu * {
  .Max's Acronyms Set Up
  ..Turn Max's Acronyms $iif($group(#acro) == on,Off,On) : $iif($group(#acro) == off,.enable,.disable) #acro | $iif($group(#acro) == on,echo *  $+ %fac $+ M $+ %sac $+ ax's  $+ %fac $+ A $+ %sac $+ cronyms  $+ %fac $+ A $+ %sac $+ re  $+ %fac $+ N $+ %sac $+ ow  $+ %fac $+ O $+ %sac $+ n, echo *  $+ %fac $+ M $+ %sac $+ ax's  $+ %fac $+ A $+ %sac $+ cronyms  $+ %fac $+ A $+ %sac $+ re  $+ %fac $+ N $+ %sac $+ ow  $+ %fac $+ O $+ %sac $+ ff) 
  ..Set Colors: { set %fac $?="Color Of The First Letter Of Every Word" | set %sac $?="Color Of All Letters Except First Of Every Word" | echo -a *  $+ %fac $+ C $+ %sac $+ olor  $+ %fac $+ P $+ %sac $+ references  $+ %fac $+ H $+ %sac $+ ave  $+ %fac $+ B $+ %sac $+ een  $+ %fac $+ S $+ %sac $+ et -  $+ %fac $+ M $+ %sac $+ ax's $+ %fac A $+ %sac $+ cronyms }
  .Color Theme Presets
  ..Strawberry Daiquiri: { acrored }
  ..Blueberry Paradise: { acroblue }
  ..Stormy Sunrise: { acrogrey }
  ..Strawberry Banana: { acrory }
  ..Pink Lemonade: { acropy }
  .Advertise Max's Acronyms: { msg $active  $+ %fac I $+ %sac $+ 'm $+ %fac U $+ %sac $+ sing $+ %fac M $+ %sac $+ ax's $+ %fac A $+ %sac $+ cronyms $+ %fac $+ ! G $+ %sac $+ et $+ %fac T $+ %sac $+ he $+ %fac S $+ %sac $+ cript $+ %fac F $+ %sac $+ or $+ %fac Y $+ %sac $+ our $+ %fac C $+ %sac $+ lient $+ %fac A $+ %sac $+ t $+ %fac H $+ %sac $+ awkee: http://www.hawkee.com/snippet/6001/ }
}

Comments

Sign in to comment.
Kirby   -  Apr 11, 2009

Cool Max, nice to see the use of grouping rather than variables.
I like the presets, they have interesting names. :p

There is one thing I recommend modifying. For the on input event, instead of

if (/* iswm $1-) { $1- | halt }

, I'd recommend using

if (/ !isin $left($1-,1)) && (!$ctrlenter) {

This not only checks if the slash is used, but also if the Ctrl key is held or not.

I'd also check to see if the active channel has channel mode +c is set or not. So adding to the modified code posted above, I think you should add

(c !isincs $chan(#).mode)
 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.