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 

on join
Goto page Previous  1, 2
 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help
View previous topic :: View next topic  
Author Message
ap
Halfop


Joined: 09 Jun 2006
Posts: 44

PostPosted: Tue May 15, 2007 11:01 pm    Post subject: Reply with quote

Thanks Sir,Fz i'll try it and then i'll let ya know
Back to top
View user's profile Send private message
ap
Halfop


Joined: 09 Jun 2006
Posts: 44

PostPosted: Sat May 19, 2007 6:08 pm    Post subject: Reply with quote

Thank you for your help Sir_Fz, it worked great.

I have a one last question please. The following codes works sometime and sometime they don't. Am i missing something?

so user with Z flag types /msg bot inv

Code:
bind msg Z inv msg:invite
proc msg:invite {nick host hand text} {
if {![onchan $nick #name]} {
   putserv "INVITE $nick #name"
 } else {
  puthelp "NOTICE $nick :you are already in"
 }
}


thanks
Back to top
View user's profile Send private message
YooHoo
Owner


Joined: 13 Feb 2003
Posts: 939
Location: Redwood Coast

PostPosted: Sun May 20, 2007 12:20 am    Post subject: Reply with quote

maybe if you include a matchattr check inside your procedure it would be better
_________________
Mr. Green
Johoho's TCL for beginners
Mr. Green
Back to top
View user's profile Send private message Send e-mail
ap
Halfop


Joined: 09 Jun 2006
Posts: 44

PostPosted: Sun May 20, 2007 12:33 am    Post subject: Reply with quote

now they don't work at all
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2857

PostPosted: Sun May 20, 2007 2:37 am    Post subject: Reply with quote

My guess would be that hostmasks for one or several users are not properly set up, causing users not to be recognized, or recognized as someone else...

In this case, the solution (obviously) would be to correct hostmasks of those users. The .channel dcc-command might be useful to actually see whom your eggdrop identifies the user as
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
ap
Halfop


Joined: 09 Jun 2006
Posts: 44

PostPosted: Sun May 20, 2007 2:39 pm    Post subject: Reply with quote

thank you nml375;

I've created invite handle and added 4,5 ip/hosts to it to test it. they all are added like *!*ident@ip and their idents are different.

When channel is invite only then they cann't get in so i cann't use .channel command to see.. so these codes are correct?

Code:
bind msg Z inv msg:invite
proc msg:invite {nick host hand text} {
if {![onchan $nick #name]} {
   putserv "INVITE $nick #name"
 } else {
  puthelp "NOTICE $nick :you are already in"
 }
}


thanks
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2857

PostPosted: Sun May 20, 2007 2:44 pm    Post subject: Reply with quote

You could always remove the Z from the binding, and add something like this in the beginning of your proc:
Code:
 if {![matchattr $hand +Z]} {
  putlog "Inviter: Failed invite by $nick!$host ($hand), no permissions"
  return 0
 }

Should dump a logmessage if the user does not have permissions, including the handle (s)he was identified as...

edit: And yes, your code is otherwize proper... and, just to make sure, by saying remove Z, you should replace it with a -
_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
ap
Halfop


Joined: 09 Jun 2006
Posts: 44

PostPosted: Sun May 20, 2007 3:46 pm    Post subject: Reply with quote

thank you again nml375, i'll give it a try
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help All times are GMT - 4 Hours
Goto page Previous  1, 2
Page 2 of 2

 
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