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 

how to make eggdrop strip colors from ctcr

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


Joined: 22 Mar 2015
Posts: 941

PostPosted: Thu Apr 23, 2015 7:51 am    Post subject: how to make eggdrop strip colors from ctcr Reply with quote

i alread found this tcl and was wondering how to make it strip colors in ctcr too for whatever VERSION/TIME and what not

Code:
catch {unbind raw - PRIVMSG *raw:irc:msg}
catch {unbind raw - PRIVMSG *raw:PRIVMSG}
bind raw - PRIVMSG striprivmsg
proc striprivmsg {f k a} {
   set a [stripcodes abcgru $a]
   *raw:irc:msg $f $k $a
   *raw:PRIVMSG $f $k $a
}

putlog "colourstripper... Loaded"
Back to top
View user's profile Send private message
willyw
Revered One


Joined: 15 Jan 2009
Posts: 1175

PostPosted: Thu Apr 23, 2015 9:32 am    Post subject: Re: how to make eggdrop strip colors from ctcr Reply with quote

simo wrote:
i alread found this tcl and was wondering how to make it strip colors in ctcr too for whatever VERSION/TIME and what not

...


Go here:
http://www.eggheads.org/support/egghtml/1.6.21/tcl-commands.html

and text search to find: bind ctcr

Experiment with that bind.
_________________
For a fun (and popular) Trivia game, visit us at: irc.librairc.net #science-fiction . Over 300K Q & A to play in BogusTrivia !
Back to top
View user's profile Send private message
simo
Owner


Joined: 22 Mar 2015
Posts: 941

PostPosted: Thu Apr 23, 2015 11:13 am    Post subject: Reply with quote

yea i looked there but couldnt figure it

i need to strip colors from ctcp version reply i was told that is a NOTICE
i just cant figure how to do that
Back to top
View user's profile Send private message
willyw
Revered One


Joined: 15 Jan 2009
Posts: 1175

PostPosted: Thu Apr 23, 2015 12:28 pm    Post subject: Reply with quote

simo wrote:
yea i looked there but couldnt figure it

i need to strip colors from ctcp version reply i was told that is a NOTICE
i just cant figure how to do that



Play with this to see how to use
bind ctcr

Code:

# April 23, 2015
# http://forum.egghelp.org/viewtopic.php?p=103927#103927


bind ctcr - * ctcr_proc

proc ctcr_proc {nick uhost handle dest keyword text} {

        putserv "privmsg your_nick_here :$nick $uhost $handle $dest $keyword $text"

        putserv "privmsg your_nick_here :Using stripcodes :[stripcodes bcruag $text]"
}


Do:
.tcl putserv "privmsg some_nick_here :\001VERSION\001"

from the partyline, to make the bot send out a CTCP version

With that bind ctcp above loaded, bot will trigger on the ctcr reply to it.
_________________
For a fun (and popular) Trivia game, visit us at: irc.librairc.net #science-fiction . Over 300K Q & A to play in BogusTrivia !
Back to top
View user's profile Send private message
simo
Owner


Joined: 22 Mar 2015
Posts: 941

PostPosted: Thu Apr 23, 2015 8:57 pm    Post subject: Reply with quote

thx willyw that helped a lot apreciated
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