This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Need Help With Keepnick

Old posts that have not been replied to for several years.
Locked
User avatar
CoMMy
Halfop
Posts: 99
Joined: Thu Jul 24, 2003 1:03 am
Location: Cyprus

Need Help With Keepnick

Post by CoMMy »

Hey Guys.

I made a public tcl (!keepnick) that sets keepnick to the var given. ex. set keepnick $var .
But the bot doesnt save that. Can you suggest a way on doing this?

Thanks
(c) CoMMy (c)
Resistance is Futile!!
We Are The Borg!!
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

keepnick can be enabled or disabled as in 1 or 0 (at least the one from the .conf file). If you want it to keep a certain nick the use "set nick the nick you want".
Once the game is over, the king and the pawn go back in the same box.
User avatar
CoMMy
Halfop
Posts: 99
Joined: Thu Jul 24, 2003 1:03 am
Location: Cyprus

Post by CoMMy »

Yeaa but i want to be able to change it via tcl. set keepnick in a proc doesnt seem to work.
Any suggestions?
(c) CoMMy (c)
Resistance is Futile!!
We Are The Borg!!
User avatar
Dedan
Master
Posts: 260
Joined: Wed Jul 09, 2003 10:50 pm
Location: Memphis

Post by Dedan »

in your conf. file,
make this change.

# This setting makes the bot try to get his original nickname back if its
# primary nickname is already in use.
set keep-nick 0
I once was an intelligent young man, now i am old and i can not remember who i was.
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

Can you be more specific on what is not working? That should be helpfull..
Once the game is over, the king and the pawn go back in the same box.
User avatar
CoMMy
Halfop
Posts: 99
Joined: Thu Jul 24, 2003 1:03 am
Location: Cyprus

Post by CoMMy »

Well what i need is a tcl that you can control via a public
command !keepnick so that i can control the keepnick quickly instead of opening the config each time. I tried doing this but it doesnt work. Can you make one please?

Thanks
(c) CoMMy (c)
Resistance is Futile!!
We Are The Borg!!
O
Ofloo
Owner
Posts: 953
Joined: Tue May 13, 2003 1:37 am
Location: Belguim
Contact:

Post by Ofloo »

try this

Code: Select all

bind pub n !keepnick keepnick:pub

proc keepnick:pub {nick uhost hand chan arg} {
   global botnick
   set botnick [lindex $arg 0]
}
try to set new global botnick variable and after ur done u reset it to its original ...

this is basic if u want errors on error stuff like that u have to do some reading ;) like

Code: Select all

if {[string match -nocase {} [lindex $arg 0]]} {
  ...
}
if u wana use the script, not sur don't know it but i do know u can use off on switch by setting a varable 1 & 2

1 yournick
2 bnick

and by typing !keepnick on or off u can make the bot choose a nick like sample above if on then use global variable yournick = botnick if off then use global variable bnick = botnick ..
XplaiN but think of me as stupid
Locked