View previous topic :: View next topic |
Author |
Message |
Foxman Voice

Joined: 10 Jan 2007 Posts: 9 Location: Delft, Zuid-Holland, The Netherlands
|
Posted: Wed Jan 10, 2007 5:38 pm Post subject: How to make Eggdrop bot Blind for colors? |
|
|
I would like to let my users to be able to use Colors, Bolds, Underlines etc.. and to use public (Eggdrop) commands, to answer Trivia Questions and able to communicate with my AI eggdrop bot.
Or differently said, I would like my eggdrop bot to be blind for Colors, bolds and underline codes...
sounds not to difficult....
How could i make this possible?
Thanks for reading this, or even reply to this
Greetings Foxman |
|
Back to top |
|
 |
user

Joined: 18 Mar 2003 Posts: 1452 Location: Norway
|
Posted: Wed Jan 10, 2007 5:59 pm Post subject: |
|
|
I'm not sure this will work, but it's worth a shot
Code: | unbind raw - PRIVMSG *raw:irc:msg
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
} |
_________________ Have you ever read "The Manual"? |
|
Back to top |
|
 |
crux Voice

Joined: 05 Jan 2007 Posts: 35 Location: Myanmar
|
Posted: Thu Jan 11, 2007 5:51 am Post subject: |
|
|
I don't know how to make with color, but if u want trivia with color
Bogus Trivia is the best ... look like mIRC trivia. _________________ Myanmar Chat Online
MCO Chat |
|
Back to top |
|
 |
Foxman Voice

Joined: 10 Jan 2007 Posts: 9 Location: Delft, Zuid-Holland, The Netherlands
|
Posted: Wed Mar 07, 2007 1:44 pm Post subject: |
|
|
User i would like to Thank you very much for that piece of script
It works like a charm
Thanks a lot  |
|
Back to top |
|
 |
Foxman Voice

Joined: 10 Jan 2007 Posts: 9 Location: Delft, Zuid-Holland, The Netherlands
|
Posted: Fri Sep 07, 2007 1:24 pm Post subject: |
|
|
I always die or get killed on a .rehash because of that little script, any idea why or how to solve that?
I did put that little script in a new fresh TCL file, still works like a charm though... except that i can't rehash anymore  |
|
Back to top |
|
 |
rosc2112 Revered One

Joined: 19 Feb 2006 Posts: 1454 Location: Northeast Pennsylvania
|
Posted: Sat Sep 08, 2007 1:05 pm Post subject: |
|
|
Use catch around the unbinds (I assume those are the lines causing the crashes)
Code: |
catch {unbind raw - PRIVMSG *raw:irc:msg}
catch {unbind raw - PRIVMSG *raw:PRIVMSG}
|
Might want to also read here about how to load scripts without crashing the bot:
http://forum.egghelp.org/viewtopic.php?p=63899#63899 |
|
Back to top |
|
 |
Foxman Voice

Joined: 10 Jan 2007 Posts: 9 Location: Delft, Zuid-Holland, The Netherlands
|
Posted: Sun Sep 09, 2007 1:55 am Post subject: |
|
|
Yes! I can Rehash again, Thank you very much rosc2112  |
|
Back to top |
|
 |
br00 Voice
Joined: 19 Jun 2006 Posts: 9
|
Posted: Mon Sep 10, 2007 5:32 am Post subject: |
|
|
what a great little piece of script  |
|
Back to top |
|
 |
Pberetta Voice
Joined: 22 Oct 2007 Posts: 1
|
Posted: Mon Oct 22, 2007 2:12 pm Post subject: |
|
|
I created strip.tcl like this
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"
|
Added to egggdrop.conf
But triviascript still doesn't react to users answering in coloured text. Am i doing something wrong? Help would be greatly apreciated
Peer |
|
Back to top |
|
 |
Diablo228 Voice
Joined: 27 Sep 2007 Posts: 5
|
Posted: Tue Nov 04, 2008 4:48 am Post subject: |
|
|
Thank you so much! I have been fighting with color code issues on Chatspace for months. This little snippet of a script works flawlessly with eggdrop 1.6.19. Users are also able to play BogusTrivia in color now. Sweetness. Thank you all.
--Diablo228-- |
|
Back to top |
|
 |
|