Nick Changer

By DragonFlare on Dec 27, 2009

I got bored and decided to make this
if you type !BNick nickhere it will add the selected nick the the badnicks ini file and when someone goes to change your bot to a nick that is in the Badnick.ini it will not allow them to
if you want to change the name of the ini file change this part of the script

 writeini Badnick.ini Badnicks $2 $2 

Badnick.ini Badnicks
Leave

 $2 $2  on the end of the script 
On *:Text:!BNick*:#:{
  writeini Badnick.ini Badnicks $2 $2
  msg $chan 4,1 $+ $2 added To The BadNick ini File
}
On *:Text:!Nick*:#:{
  %var = $readini(Badnick.ini,Badnicks,$2)
  if %var = $2 { Msg $chan 4,1Failed Attempt By $nick With Command !Nick Reason: Inappropriate nick Failed Nick ( $2 ) }
  else { msg $chan 4,1Authorized nick Changing nick to ( $2 ) | nick $2 }
}

Comments

Sign in to comment.
Silo   -  Dec 30, 2009

Isn't that an English idiom? I think it means what's good for you may not be good for others. To each our own, I reckon?

Yes, that is correct. I was wondering if it would sound weird lol

 Respond  
sunslayer   -  Dec 30, 2009

no idea, but > IT'S A LIST WOW DOESN'T NEED TO BE IN ANY ORDER FFS! i may be wrong but i don't think hashes are in any specific order?

 Respond  
Jethro   -  Dec 30, 2009

Isn't that an English idiom? I think it means what's good for you may not be good for others. To each our own, I reckon?

 Respond  
sunslayer   -  Dec 30, 2009

Horses for courses.lol'd

 Respond  
Jethro   -  Dec 30, 2009

Hash tables are stored locally in your RAM, not in the hard disk... unlike INI files. Therefore, they're practically faster, because our PCs can access RAM quicker. ini file is pretty decent for general settings. Anything other than that, use variables. If you need more organization, use hash tables. Again, variables, text Files, and INI Files are all stored on the computer's hard drive.

 Respond  
DragonFlare   -  Dec 30, 2009

Aucun50 [quote] omfg no hash tables you nubs! TXT FILE WORKS HERE NO NEED FOR HASH TABLE FFS! IT'S A LIST WOW DOESN'T NEED TO BE IN ANY ORDER FFS! [/quote]
He is right Hash tables are not needed here it is just a list
Why have it on a hash table does it matter how it is scripted it works dont it
Silo [quote] Chill out, man. Horses for courses. I'm new to hash stuff, but it's way faster to process. [/quote]
Hash tables and Inis Are both good ways of scripting

 Respond  
Silo   -  Dec 28, 2009

Touche ;)

 Respond  
Master-Of-Death   -  Dec 28, 2009

faster for the way, slower for the delay ;)

 Respond  
Silo   -  Dec 28, 2009

Chill out, man. Horses for courses. I'm new to hash stuff, but it's way faster to process.

 Respond  
Aucun50   -  Dec 28, 2009

omfg no hash tables you nubs! TXT FILE WORKS HERE NO NEED FOR HASH TABLE FFS! IT'S A LIST WOW DOESN'T NEED TO BE IN ANY ORDER FFS!

 Respond  
Jethro   -  Dec 28, 2009

I prefer the use of a hash table for this sort of operation:

on *:START:bn
on *:CONNECT:bn
on *:EXIT:hsave b b.hsh
alias -l bn {
  if (!$hget(b)) { hmake b 100 }
  if ($isfile($qt($scriptdirb.hsh))) { hload b $qt($scriptdirb.hsh) }
}
on $*:TEXT:/!(\w+)\s(\S+)/iS:#: {
  if ($regml(1) = bnick) { 
    hadd -m b n $addtok($hget(b,n),$regml(2),32) | .msg # 4,1 $+ $regml(2) added to the hash file!
  }
  elseif ($regml(1) = nick) && (!$istok($hget(b,n),$regml(2),32)) {
    .msg # 4,1Failed Attempt By $nick With $1 Reason: Inappropriate nick Failed Nick ( $regml(2) )
  }
  else { msg # 4,1 $+ Authorized nick changing nick to: $regml(2) | nick $regml(2) }
}
 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.