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 

Quick Request

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests
View previous topic :: View next topic  
Author Message
whittinghamj
Op


Joined: 21 May 2006
Posts: 103

PostPosted: Sat Sep 23, 2006 5:16 am    Post subject: Quick Request Reply with quote

Hello guys.

Quick question / request if I may please.

I am looking for something like the following.

(User types this)

(user)whos the [censored] do you think you are son?

Now i have the ircd setup to replace [censored] with censored.

Everyone else sees blah blah (censored) blah blah

What I need is the bot to read every line of the irc channel chat - every channelt he bot is in. and when it see's the word

Code:
consored
it puts out the following message

(bot> Please dont use language like that in a public channel.

Can anyone help me out with this please.

cheers

Jamie
Back to top
View user's profile Send private message
monie089
Halfop


Joined: 29 Jul 2006
Posts: 76

PostPosted: Sat Sep 23, 2006 6:19 am    Post subject: Reply with quote

Code:

bind pub - "*censored" censored:check

proc censored:check {nick uhost hand chan text} {
putquick "PRIVMSG $nick :Please don't curse in $chan"
}

Something like this.
_________________
New server irc.NintendoXG.com come and visit
Back to top
View user's profile Send private message Send e-mail
r0t3n
Owner


Joined: 31 May 2005
Posts: 507
Location: UK

PostPosted: Sat Sep 23, 2006 6:20 am    Post subject: Reply with quote

Not very well described... more confusing...
But i think this is what your looking for:

Code:
bind pubm - * censored

proc censored {nickname hostname handle channel text} {
  if {[string match -nocase *censored* $text]} {
    putserv "PRIVMSG $channel :Please dont use language like that in a public channel."
  }
}

_________________
r0t3n @ #r0t3n @ Quakenet
Back to top
View user's profile Send private message MSN Messenger
whittinghamj
Op


Joined: 21 May 2006
Posts: 103

PostPosted: Sat Sep 23, 2006 6:44 am    Post subject: Reply with quote

thanks guys that did the trick nicely.

One more thing to do with this script.

Is it posable to have the following upgrade.

(user) why dont you go <consored> off !!!
(bot) Please dont use that language in a public chanel

but also

(bot) The following consored line was detected "why dont you go <censored> off !!!" $chan.

and the bots says that into our staff channel. this way I can see what the bot flagged the announce for?

something like arg -1 i think its something like that but not sure? does that make sence?

the bot should listen for the cencsored on all channels but report to #staff channel

The bot is an ircop if that makes any difference and its unrealircd if that makes any differnce as well.

cheers guys - your all aces.

Quest
Back to top
View user's profile Send private message
metroid
Owner


Joined: 16 Jun 2004
Posts: 771

PostPosted: Sat Sep 23, 2006 8:37 am    Post subject: Reply with quote

monie089 wrote:
Code:

bind pub - "*censored" censored:check

proc censored:check {nick uhost hand chan text} {
putquick "PRIVMSG $nick :Please don't curse in $chan"
}

Something like this.


You shouldn't attempt to make scripts for others since you obviously don't know how a PUB bind works.


also,

Quote:
(user) why dont you go <consored> off !!!
(bot) Please dont use that language in a public chanel


Why don't you add that yourself, it's just another line which you then send to your 'staff' channel.
Back to top
View user's profile Send private message
r0t3n
Owner


Joined: 31 May 2005
Posts: 507
Location: UK

PostPosted: Sat Sep 23, 2006 10:43 am    Post subject: Reply with quote

Code:
bind pubm - * censored

proc censored {nickname hostname handle channel text} {
  if {[string match -nocase *censored* $text] && ![string match -nocase #STAFFCHANNEL $channel]} {
    putserv "PRIVMSG $channel :Please dont use language like that in a public channel."
    putserv "PRIVMSG #STAFFCHANNEL :The following censored line was detected \"$text\" by $nickname on $channel.
  }
}


Change both instances of #STAFFCHANNEL to your staff channel.
_________________
r0t3n @ #r0t3n @ Quakenet
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests 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