egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Special Characters in set nick.

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help
View previous topic :: View next topic  
Author Message
CoMMy
Halfop


Joined: 24 Jul 2003
Posts: 99
Location: Cyprus

PostPosted: Sun Apr 02, 2006 11:50 am    Post subject: Special Characters in set nick. Reply with quote

Hi,

Im trying to use {[]} characters in a nickname. But because those codes are TCL Operators eggdrop things its a command.

Please help me out,

Thanks
_________________
(c) CoMMy (c)
Resistance is Futile!!
We Are The Borg!!
Back to top
View user's profile Send private message
De Kus
Revered One


Joined: 15 Dec 2002
Posts: 1361
Location: Germany

PostPosted: Sun Apr 02, 2006 11:58 am    Post subject: Reply with quote

there is no problem about such nicks. Only when the content of $nick gets evalated you have to worry about it. In most times split and list are your friends. In care cases like in a calculator you can string map them with escapes.

Give us some code, if you are unsure how to properly escape them without escaping them too much.
_________________
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...
Back to top
View user's profile Send private message MSN Messenger
CoMMy
Halfop


Joined: 24 Jul 2003
Posts: 99
Location: Cyprus

PostPosted: Sun Apr 02, 2006 12:02 pm    Post subject: Reply with quote

Basically its this.

set nick "{[MyNick]}"

(Set in the eggdrops config file).

Thanks
_________________
(c) CoMMy (c)
Resistance is Futile!!
We Are The Borg!!
Back to top
View user's profile Send private message
De Kus
Revered One


Joined: 15 Dec 2002
Posts: 1361
Location: Germany

PostPosted: Sun Apr 02, 2006 12:05 pm    Post subject: Reply with quote

CoMMy wrote:
set nick "{[MyNick]}"


use instead
Code:
set nick {{[MyNick]}}

strings within "" are substituted but within {} only blackslashing of { and } is neccessary (even line breaks will be included).

Alternately, if you must keep substitution, you can escape [] with \[\].
_________________
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...


Last edited by De Kus on Sun Apr 02, 2006 12:10 pm; edited 3 times in total
Back to top
View user's profile Send private message MSN Messenger
CoMMy
Halfop


Joined: 24 Jul 2003
Posts: 99
Location: Cyprus

PostPosted: Sun Apr 02, 2006 12:08 pm    Post subject: Reply with quote

I'll try it man,

Thanks for fast reply
_________________
(c) CoMMy (c)
Resistance is Futile!!
We Are The Borg!!
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber