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.

Why does this code not work????

Old posts that have not been replied to for several years.
Locked
S
Salvia
Voice
Posts: 15
Joined: Mon Mar 10, 2003 4:43 pm

Why does this code not work????

Post by Salvia »

Everything I read tells me that there is 26 user defined Flags "All capital letters"

So why does this script not work????

it is not an auto voice script!!!!!!!!!!!!!!!!
it is a auto VIP script
our IRCd server has this mode it is +V

as we all know voice is +v

I set the user flag to +fV on the bot for my channel and when he joins nothing happens
________________________________________________________

set flag1 V
set chanflag1 V

bind join V * join:mbti_autovip
bind join - * join:mbti_cautovip

proc join:mbti_autovip {nick host hand chan} {
pushmode $chan +V $nick
}

proc join:mbti_cautovip {nick host hand chan} {
if {[matchchanattr $hand V $chan]} {pushmode $chan +V $nick}
}
User avatar
stdragon
Owner
Posts: 959
Joined: Sun Sep 23, 2001 8:00 pm
Contact:

Post by stdragon »

Maybe it's refusing to pass on the +V since eggdrop doesn't know what +V is? It does some really silly things for "optimization" purposes. You could try putserv instead, although it might still not work. If it doesn't, putdccraw will work for sure.
S
Salvia
Voice
Posts: 15
Joined: Mon Mar 10, 2003 4:43 pm

Post by Salvia »

This does not work......
________________________________
set flag1 S
set chanflag2 S

bind join S * join_auto_op

proc join_auto_op {nick host hand chan} {
putserv "mode $chan +V $nick" }
__________________________________________

Below does work
_________________________________________

bind join - * join_auto_op

proc join_auto_op {nick host hand chan} {
putserv "mode $chan +V $nick" }


So what is up with this flag thing???????
s
spock
Master
Posts: 319
Joined: Thu Dec 12, 2002 8:40 pm

Post by spock »

your first bind will only trigger if the joining user is added, and is global +S
photon?
S
Salvia
Voice
Posts: 15
Joined: Mon Mar 10, 2003 4:43 pm

Post by Salvia »

well how do I make it work for per channel?????

and wait a minute yes I did try adding the flag to the users global and no it still did not work

I am a beginner this is my first script will someone please tell me what I need to do
J
Juustro
Voice
Posts: 11
Joined: Wed Oct 02, 2002 4:15 pm

Post by Juustro »

Salvia wrote:well how do I make it work for per channel?????
well add check for channel

if {$chan == "#mychan" } {
...commands...
}

or use bind

bind join - "#mychan *" join_auto_op

or something like this
S
Salvia
Voice
Posts: 15
Joined: Mon Mar 10, 2003 4:43 pm

Post by Salvia »

That will not work for a multi channel bot

The point is there is 26 user-defined Global flags

and there is 26 user-defined Channel Flags

I want to know how to define these flags
______________________________________________
Again here goes and yes I have set the users global flag to +S
and for shits and giggles also set their channel flag to +S

This does not work......
________________________________
set flag1 S
set chanflag2 S

bind join S * join_auto_op

proc join_auto_op {nick host hand chan} {
putserv "mode $chan +V $nick" }
__________________________________________

Below does work
_________________________________________

bind join - * join_auto_op

proc join_auto_op {nick host hand chan} {
putserv "mode $chan +V $nick" }
User avatar
strikelight
Owner
Posts: 708
Joined: Mon Oct 07, 2002 10:39 am
Contact:

Post by strikelight »

It looks as though you have been reading a tcl tutorial for older eggdrops... You do not need to defined the flags with 'set flag1 V', etc.. anymore...

You simply just: .chattr <user> <flag> in the partyline... flag can be any capital letter, you don't need to define it in a script or anything..

Also... Because of the old tutorial you probably looked at, you are only binding globally, when I believe what you want is globally or channel specific bindings...
ie:
bind join S|S * join_auto_op

Furthur more, I assume you are trying to give a user voice status in the channel.. in which case (as stdragon was alluding to), you would want to make it puthelp "MODE $chan +v $nick"
(notice the little v)

In any event, for a more current tutorial, I suggest you check out
www.suninet.nl
S
Salvia
Voice
Posts: 15
Joined: Mon Mar 10, 2003 4:43 pm

Re: Why does this code not work????

Post by Salvia »

Salvia wrote:
it is not an auto voice script!!!!!!!!!!!!!!!!
it is a auto VIP script
our IRCd server has this mode it is +V

as we all know voice is +v

I set the user flag to +fV on the bot for my channel and when he joins nothing happens
________________________________________________________

bind join V|V * join:mbti_autovip
bind join - * join:mbti_cautovip

proc join:mbti_autovip {nick host hand chan} {
pushmode $chan +V $nick
}

proc join:mbti_cautovip {nick host hand chan} {
if {[matchchanattr $hand V $chan]} {pushmode $chan +V $nick}
}
User avatar
strikelight
Owner
Posts: 708
Joined: Mon Oct 07, 2002 10:39 am
Contact:

Re: Why does this code not work????

Post by strikelight »

Well I missed that part.. however it does look like now that you have modified what you originally said as well... V|V was not there in the original message.

And instead of using pushmode, use puthelp or putserv, as stated many times already.
Salvia wrote:
Salvia wrote:
it is not an auto voice script!!!!!!!!!!!!!!!!
it is a auto VIP script
our IRCd server has this mode it is +V

as we all know voice is +v

I set the user flag to +fV on the bot for my channel and when he joins nothing happens
________________________________________________________

bind join V|V * join:mbti_autovip
bind join - * join:mbti_cautovip

proc join:mbti_autovip {nick host hand chan} {
pushmode $chan +V $nick
}

proc join:mbti_cautovip {nick host hand chan} {
if {[matchchanattr $hand V $chan]} {pushmode $chan +V $nick}
}
S
Salvia
Voice
Posts: 15
Joined: Mon Mar 10, 2003 4:43 pm

Post by Salvia »

Yes I did modify it because that was the new guess that I tried I was incorrect to quote it I should have just copy and pasted

But I have tried several things and I still can not get it to work

These are the user modes the network I connect to has

+a <-- sop !username
+o <-- op @username
+h <-- hop %username
+V <-- VIP =username
+v <-- voice +username
+d <-- silenced -username

the netowrk I am using is: irc.betas-online.com

if anyone can please help me with this script All of the channel masters
at Betas-online would be much appreciated

I am a visual basic programmer this is my first time ever trying to write a tcl script please help I have tried multiple things and I am getting no where
User avatar
stdragon
Owner
Posts: 959
Joined: Sun Sep 23, 2001 8:00 pm
Contact:

Post by stdragon »

Code: Select all

bind join S * join_auto_op

proc join_auto_op {nick host hand chan} {
  putserv "mode $chan +V $nick"
}
If that doesn't work, then it's a problem with your users. Make sure the bot sees them as who you think they are. When they're on channel, type .channel #blah and make sure the bot has them listed as the correct user. Make sure you have the correct hostmasks for each user. Also do .match +S and make sure that they really have that flag.
Locked