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.
Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Sir_Fz
Revered One
Posts: 3794 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Sat Aug 11, 2007 8:56 pm
Oh, I didn't understand what you meant by those bots. zigana's suggestion should match them all.
Evil
Voice
Posts: 17 Joined: Thu May 10, 2007 5:03 am
Post
by Evil » Mon Sep 17, 2007 1:33 pm
Sir_Fz wrote: Code: Select all
set targChan #zielchannel
set srcChan #quellchannel
set newsBot {GWNEWS-[01][1-5]}
set namesList {
name1
name2
name3
}
bind pubm - * forward:pubm
proc forward:pubm {n uh h chan t} {
global targChan srcChan newsBot namesList
if {[string equal -nocase $srcChan $chan]} {
if {[regexp -nocase $newsBot $n]} {
foreach nm $namesList {
if {![string match -nocase *$nm* $t]} {continue}
putmsg $targChan "$n: $t"
break
}
}
}
}
Edit: Fixed bug.
Edit2: Changed matching method to regexp for newsBot.
the script works nice with one to four names but it is not wok with 50 names
.. than the bot start to posts all news and not only the news with
the namens list.
did you have an idea to fix that ?
BR/Ralf
Sir_Fz
Revered One
Posts: 3794 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Mon Sep 17, 2007 4:40 pm
I've edited the code, try it now.
Evil
Voice
Posts: 17 Joined: Thu May 10, 2007 5:03 am
Post
by Evil » Tue Sep 18, 2007 10:14 am
I am not sure what you change but it is the same. The bot forward the complete news and not only the news from the namenslist
here are the complete code.
set targChan #xgc-news
set srcChan #gwnews.global
set newsBot {gwnews-[01][1-5]}
set namesList {
Evil One
Sandsturm
Masters
GeisteskrankePsychopaten
Wazzup
United Chemikers
becks4all
Vipers
Amplified
Saufköppe
BWG
Cherusker
D4YW4LK3RS
The All Stars
The_Pretorians
Hornet
The Unknown Giants
Feng Sushi
bandito
Stormfront
39 Boys
P.F.C.
Gertsch`s Gäng
The Scotsmen
Flügelstuzer
Sanitöter
nudelholz-bande
TeilzeitMafiosi
DVC
Holy Sanctuary
Magicans
Die tigers
Knastbrüder AG
unsynetic
DeutscheGangJäger
ogame
Bande der Zeitlosen
Thok´ra
Ruff Raider
rebell treter
united fraggers
willis-gang
Kenjis-God-Gang
RusskajaMafia
Bongomen
}
bind pubm - * forward:pubm
proc forward:pubm {n uh h chan t} {
global targChan srcChan newsBot namesList
if {[string equal -nocase $srcChan $chan]} {
if {[regexp -nocase $newsBot $n]} {
foreach nm $namesList {
if {![string match -nocase *$nm* $t]} {continue}
putmsg $targChan "$n: $t"
break
}
}
}
}
Sir_Fz
Revered One
Posts: 3794 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Tue Sep 18, 2007 4:25 pm
Go to the first page of this topic and check the edited code.
Evil
Voice
Posts: 17 Joined: Thu May 10, 2007 5:03 am
Post
by Evil » Wed Sep 19, 2007 11:55 am
ok i tested with your edited code but it is not working
he forward the complete news not from the nameslist.
did it helps to see the message ? like
gwnews-01: Server03 -> Genf: Die
angolakoennt hat den
Die Doktoren ein(e,en) Versteck abgenommen.
my bot have to check the green and red name. Comes a name from the nameslist in the message, forward that my bot in my channel.
Thanks again for help