|
Joined: Mar 2007
Posts: 3
Self-satisified door
|
OP
Self-satisified door
Joined: Mar 2007
Posts: 3 |
Hello i am not very good with scripting so i hope you want to help me =)
Can some one give me a script like you can find most time in #help channels
if you typ !next the first who has joined wil get voice (+v) and if you typ !done he get kicked banned for like 10 sec (rejoin block)
Can some help me with this
Thx in advance =)
|
|
|
|
Joined: Mar 2005
Posts: 420
Fjord artisan
|
Fjord artisan
Joined: Mar 2005
Posts: 420 |
Try this Simple Helpbot snippet I made before. It just doesn't have the kick ban after !done.
If you have a plastic floor runner over your tiles, then you're one Hella Pinoy!
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
Here's one that will do that as well. If someone leaves the channel (part/quit), they lose their spot. Only ops can use !next/!done and the script will do what you asked for those commands. ** Replace all occurences of #chan with your channel name.
on *:join:#chan: {
write joinlist.txt $nick
}
on *:part:#chan: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:quit: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:text:!next:#chan: {
if ($nick isop $chan) {
if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return }
set %help.next $read(joinlist.txt,1)
while (%help.next !ison $chan) {
write -dl1 joinlist.txt
if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return }
set %help.next $read(joinlist.txt,1)
}
mode $chan +v %help.next
msg $chan %help.next $+ , how may we help you?
}
}
on *:text:!done:#chan: {
if ($nick isop $chan) {
if (%help.next ison $chan) { ban -ku10 $chan %help.next }
}
}
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Mar 2007
Posts: 3
Self-satisified door
|
OP
Self-satisified door
Joined: Mar 2007
Posts: 3 |
Here's one that will do that as well. If someone leaves the channel (part/quit), they lose their spot. Only ops can use !next/!done and the script will do what you asked for those commands. ** Replace all occurences of #chan with your channel name.
on *:join:#chan: {
write joinlist.txt $nick
}
on *:part:#chan: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:quit: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:text:!next:#chan: {
if ($nick isop $chan) {
if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return }
set %help.next $read(joinlist.txt,1)
while (%help.next !ison $chan) {
write -dl1 joinlist.txt
if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return }
set %help.next $read(joinlist.txt,1)
}
mode $chan +v %help.next
msg $chan %help.next $+ , how may we help you?
}
}
on *:text:!done:#chan: {
if ($nick isop $chan) {
if (%help.next ison $chan) { ban -ku10 $chan %help.next }
}
}
It works but if someone already have op [16:30:58] [Join-#help] Tombraider [16:30:58] [Mode-#help] ChanServ +o Tombraider [16:44:13] [Join-#help] gast [16:46:03] @BigSmoke : !next [16:46:03] <@VoiceBot> Tombraider, how may we help you? [16:46:03] [Mode-#help] VoiceBot +v Tombraider [16:46:08] @BigSmoke : !next [16:46:08] <@VoiceBot> Tombraider, how may we help you? [16:46:09] @BigSmoke : !next [16:46:09] <@VoiceBot> Tombraider, how may we help you? but he leaves gast (and Tombraider is op) zo why he give him voice
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
Sorry, didn't think about if a person gets opped. Here you are:
on *:join:#chan: {
write joinlist.txt $nick
}
on *:op:#chan: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:part:#chan: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:quit: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:text:!next:#chan: {
if ($nick isop $chan) {
if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return }
set %help.next $read(joinlist.txt,1)
while (%help.next !ison $chan) {
write -dl1 joinlist.txt
if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return }
set %help.next $read(joinlist.txt,1)
}
mode $chan +v %help.next
msg $chan %help.next $+ , how may we help you?
}
}
on *:text:!done:#chan: {
if ($nick isop $chan) {
if (%help.next ison $chan) { ban -ku10 $chan %help.next }
}
}
That will fix the problem if someone's opped after joining the channel.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Mar 2007
Posts: 3
Self-satisified door
|
OP
Self-satisified door
Joined: Mar 2007
Posts: 3 |
Thanks for your help man i really am greatfull but he still doesnt work =(
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
Are you getting any error messages? If so, what are they? If not, then what are you basing your statement of it not working on? I tested Riamus' code, after you posted that it's not working, and it worked for me exactly as it should.
|
|
|
|
Joined: Mar 2007
Posts: 38
Ameglian cow
|
Ameglian cow
Joined: Mar 2007
Posts: 38 |
Riamus2 good work, i take the code to improve it... On green my modifications...on *:join: #replaceforyourchannel: { if ($nick !isop #) { write joinlist.txt $nick } } on *:op: #replaceforyourchannel: { if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt } } on *:part: #replaceforyourchannel: { if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt } } on *:quit: { if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt } } on *:text:!next: #replaceforyourchannel: { if ($nick isop $chan) { if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return } set %help.next $read(joinlist.txt,1) while (%help.next !ison $chan) { write -dl1 joinlist.txt if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return } set %help.next $read(joinlist.txt,1) } mode $chan +v %help.next msg $chan %help.next $+ , how may we help you? write -dl1 joinlist.txt } } on *:text:!done: #replaceforyourchannel: { if ($nick isop $chan) { if (%help.next ison $chan) { ban -ku10 $chan %help.next | kick $chan %help.next If you dont need more, please, out from #replaceforyourchannel } } } Sorry, I don't speak english Cya.-
"if ($me ison $forum) { say Hello! }"
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
Well, most of that isn't necessary. on *:join:#replaceforyourchannel: { if ($nick !isop #) { write joinlist.txt $nick } }
That's not necessary as no one is op when they join. This is why you need the on OP event. As far as all of your #chan replacements... I already mentioned that they needed changed. That part is good to have. It shouldn't make a difference, but it's a valid change to the script, though it would be better in the kick part. if (%help.next ison $chan) { ban -ku10 $chan %help.next | kick $chan %help.next If you dont need more, please, out from #replaceforyourchannel }
That's unnecessary. The /ban command already is kicking the person. If a message is needed, then it can be added to the end of the ban command in my script. Below, is the updated version that has the line deletion added.
on *:join:#chan: {
write joinlist.txt $nick
}
on *:op:#chan: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:part:#chan: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:quit: {
if ($read(joinlist.txt,w,$nick)) { write -dl $readn joinlist.txt }
}
on *:text:!next:#chan: {
if ($nick isop $chan) {
if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return }
set %help.next $read(joinlist.txt,1)
while (%help.next !ison $chan) {
write -dl1 joinlist.txt
if ($lines(joinlist.txt) == 0) { msg $chan No users waiting for help. | return }
set %help.next $read(joinlist.txt,1)
}
mode $chan +v %help.next
msg $chan %help.next $+ , how may we help you?
}
}
on *:text:!done:#chan: {
if ($nick isop $chan) {
if (%help.next ison $chan) {
ban -ku10 $chan %help.next If you need more help, you may return.
if ($read(joinlist.txt,w,%help.next)) { write -dl $readn joinlist.txt }
}
}
}
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Mar 2007
Posts: 38
Ameglian cow
|
Ameglian cow
Joined: Mar 2007
Posts: 38 |
Well, most of that isn't necessary. on *:join:#replaceforyourchannel: { if ($nick !isop #) { write joinlist.txt $nick } }
That's not necessary as no one is op when they join. This is why you need the on OP event. If you join a channel with your @, you are a helper, so, why put this nick on list? You are writing 2 times when you can no write... And the OP event its neccesary if you join and get the op later... As far as all of your #chan replacements... I already mentioned that they needed changed.
Only for prevent 'coz i dont quote all your post... That part is good to have. It shouldn't make a difference, but it's a valid change to the script, though it would be better in the kick part. No, if you have 2 helpers working when the first helper take the first nick on joinlist, the 2 helper must be ready to take the new first nick on joinlist, so, when you give the voice, delete the nick... if (%help.next ison $chan) { ban -ku10 $chan %help.next | kick $chan %help.next If you dont need more, please, out from #replaceforyourchannel }
That's unnecessary. The /ban command already is kicking the person. If a message is needed, then it can be added to the end of the ban command in my script. /ban command, kick too? I have an older mirc and /ban only make the ban... Cya!.-
"if ($me ison $forum) { say Hello! }"
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
If you join a channel with your @, you are a helper, so, why put this nick on list? You are writing 2 times when you can no write... And the OP event its neccesary if you join and get the op later... When you join, you do not have @ or + or any other channel mode. You get these *after* you join, so you cannot check for it the way that you did. No, if you have 2 helpers working when the first helper take the first nick on joinlist, the 2 helper must be ready to take the new first nick on joinlist, so, when you give the voice, delete the nick... The script is made for helping one nick at a time. It would need various other changes to work with multiple nicks. Unless that is necessary, then the -dl line should be in the kick part. /ban command, kick too? I have an older mirc and /ban only make the ban... /help /ban You'll find that the -k switch has been around for a long time.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Mar 2007
Posts: 38
Ameglian cow
|
Ameglian cow
Joined: Mar 2007
Posts: 38 |
You said that you havent @ when join a channel? I have this:
on *:JOIN:#ayuda:{
if ($nick isop #) { echo -ste $nick joined #ayuda }
}
} And works. /ban -ku10 ... I don't see the -k in your script, my mistake [16:30:58] [Join-#help] Tombraider [16:30:58] [Mode-#help] ChanServ +o Tombraider [16:44:13] [Join-#help] gast [16:46:03] @BigSmoke : !next [16:46:03] <@VoiceBot> Tombraider, how may we help you? [16:46:03] [Mode-#help] VoiceBot +v Tombraider [16:46:08] @BigSmoke : !next [16:46:08] <@VoiceBot> Tombraider, how may we help you? [16:46:09] @BigSmoke : !next [16:46:09] <@VoiceBot> Tombraider, how may we help you?
In this example, he try more of 1 nick, so... I think that he want more of one... Cya!.-
"if ($me ison $forum) { say Hello! }"
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
You said that you havent @ when join a channel? I have this:
on *:JOIN:#ayuda:{
if ($nick isop #) { echo -ste $nick joined #ayuda }
}
} And works. It shouldn't. And I tested it and it doesn't. If you have it "working," then there is probably another script that is doing the same echo "on OP" instead. In this example, he try more of 1 nick, so... I think that he want more of one... If you look closely, only 1 person is helping in that example.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Mar 2007
Posts: 38
Ameglian cow
|
Ameglian cow
Joined: Mar 2007
Posts: 38 |
If you look closely, only 1 person is helping in that example.
But 2 nicks of the JoinList... If you delete the first nick of the joinlist when you have the voice, then you can take the new first nick on joinlist and help both... I see that on the log... 1 nick helping 2 nicks of the JoinList... If you know about OGamenet servers, had this bots, and 1 helper can take 1 or more "tickets" to help... Cya!.-
"if ($me ison $forum) { say Hello! }"
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
He's only helping one at a time. The other was an op. This script works for 1 nick being helped at a time. It will not work for helping more than 1 nick at a time because it uses a variable to track the nick being helped. Trust me. I wrote the script, so I know what it's capable of.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Mar 2007
Posts: 38
Ameglian cow
|
Ameglian cow
Joined: Mar 2007
Posts: 38 |
He's only helping one at a time. The other was an op. This script works for 1 nick being helped at a time. It will not work for helping more than 1 nick at a time because it uses a variable to track the nick being helped. Trust me. I wrote the script, so I know what it's capable of. You don't understand me... [16:30:58] [Join-#help] Tombraider [16:30:58] [Mode-#help] ChanServ +o Tombraider [16:44:13] [Join-#help] gast [16:46:03] @BigSmoke : !next [16:46:03] <@VoiceBot> Tombraider, how may we help you? [16:46:03] [Mode-#help] VoiceBot +v Tombraider [16:46:08] @BigSmoke : !next [16:46:08] <@VoiceBot> Tombraider, how may we help you? [16:46:09] @BigSmoke : !next [16:46:09] <@VoiceBot> Tombraider, how may we help you?
Join Tombraider, later gast... If you put !next, the script take gast for the list, then +v gast. If you delete this nick when you gives the voice, if you write !next, the bot take the next on list... If no nicks, return "No nicks waiting for help" else gives voice to the other nick (If exists) 1 nick (Tombraider) help 1 nick (gast) or 2 nick (if exists) or more... I copy paste the code on my irc-bot, believe me, works fine with 1 helper -> 1 or more nicks 2 helper -> 2 or more nicks. If you want to see... /server irc.ogamenet.net -j #bar Cya!.- EDIT: I dont use your script, 'coz have a modification. I think its the script that BigSmoke wants to do...
Last edited by HuMoR; 25/03/07 07:38 PM.
"if ($me ison $forum) { say Hello! }"
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
It will not kick/ban anyone when doing multiple nicks without requiring that either the nick be supplied with !done, or a change to how the nick is tracked.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
|