Public paste
Undefined
By: breulz | Date: Dec 20 2006 12:28 | Format: None | Expires: never | Size: 1.68 KB | Hits: 1238

  1. on *:TEXT:adduser *:?:{
  2.   if ($readini(database/userlist.ini,$2,$address($nick,2)) == owner) || ($readini(database/global.ini,global,$address($nick,2)) == owner) {
  3.     if  (!$3) {
  4.       notice $nick You forgot to type a nickname  
  5.       notice $nick correct usage /msg $me adduser <channel> <nick> <flags>
  6.       close -m $nick
  7.     }
  8.     elseif (!$4) {
  9.       notice $nick You forgot to type the flags
  10.       notice $nick correct usage /msg $me adduser <channel> <nick> <flags>
  11.       close -m $nick
  12.     }
  13.     elseif ($chr(35) isin $2) && ($4 == +aomn) {
  14.       writeini database/userlist.ini $chan $address($3,2) owner
  15.       writeini database/hosts.ini hosts $address($3,2) chanowner
  16.       Notice $nick Added $3 As an owner. He has acces to all my commands now
  17.       notice $3 You have been added as a owner on $2
  18.       notice $3 Use /msg $me showcommands for my commands
  19.       notice $3 Don't forget if you find any bugs report them to my creator
  20.       close -m $nick
  21.     }
  22.     elseif ($chr(35) isin $2) && ($4 == +aom) {
  23.       writeini database/userlist.ini $chan $address($3,2) master
  24.       writeini database/hosts.ini hosts $address($3,2) chanmaster
  25.       Notice $nick Added $3 As a master. He has acces to my commands now
  26.       Notice $3 You have been added as a master on $2
  27.       notice $3 use /msg $me showcommands for my commands
  28.       notice $3 Don't forget if you find any bugs report them to my creator
  29.       close -m $nick
  30.     }
  31.     elseif (!$2) {
  32.       Notice $nick adduser : not enough parameters
  33.       notice $nick use /msg $me adduser <chan> <nick> <flags>
  34.       close -m $nick
  35.     }
  36.   }
  37.   else { notice $nick You don't have acces to this command
  38.     close -m $nick
  39.   }
  40. }