| View previous topic :: View next topic |
| Author |
Message |
[3-33] Voice
Joined: 08 Aug 2009 Posts: 6
|
Posted: Sun Aug 09, 2009 11:35 am Post subject: |
|
|
| arfer wrote: | I downloaded bottalk.tcl from this site. After loading the script and restarting I was able to get my bot to respond to $nick, $nick; $nick: AND $nick alone.
[22:41] <@arfer> Osmosis
[22:41] <@osmosis> arfer: What? Чего надо ?
[22:41] <@arfer> osmosis
[22:41] <@osmosis> arfer: What? Чего надо ?
[22:42] <@arfer> osmosis, hello
[22:42] <@osmosis> arfer: Пиво есть ?
[22:42] <@arfer> Osmosis: hello
[22:42] <@osmosis> arfer: Скок годиков тебе ?
[22:42] <@arfer> Osmosis; what are you doing?
[22:42] <@osmosis> arfer: hello
I don't have a clue what the original poster did to break it. |
Well, can you upload your bot so, i`ll use this new one and that? _________________ The end is a new begining |
|
| Back to top |
|
 |
arfer Master

Joined: 26 Nov 2004 Posts: 436 Location: Manchester, UK
|
Posted: Sun Aug 09, 2009 1:19 pm Post subject: |
|
|
It is from the Tcl archive here at www.egghelp.org/tcl.htm
No clue what you mean by my bot but that also is the latest version 1.6.19+ctcpfix _________________ I must have had nothing to do |
|
| Back to top |
|
 |
[3-33] Voice
Joined: 08 Aug 2009 Posts: 6
|
Posted: Mon Aug 10, 2009 3:05 am Post subject: |
|
|
Well, if your eggdrop works, and my no, maybe its about what version of eggdrop i have, so would you upload or give me bot like that?
I think the problem can be in the eggdrop, also my bot is not uploaded to a shell, i start it from my machine,from a .bat file..so.. _________________ The end is a new begining |
|
| Back to top |
|
 |
arfer Master

Joined: 26 Nov 2004 Posts: 436 Location: Manchester, UK
|
Posted: Mon Aug 10, 2009 7:53 am Post subject: |
|
|
Sorry but I'm not prepared to upload my complete bot, not that it would necessarily do you any good anyway. I very much doubt if this issue has anything to do with your bot version. If you still believe this to be the case simply compile/install the current version.
I just thought of a possibility. Are you using an IRC client that throws in a spurious space character after typing in part of an onchan nick and using a predefined key (usually tab) for autocompletion? This used to occur with XChat, though I don't know if current versions still do that.
However, it is possible that the script author has included the following otherwise seemingly improper code segment to get rid of any such character :-
| Code: |
proc pub_dotalkz {nick uhost hand chan rest} {
set str [lrange $rest 0 end]
|
The variable 'rest' is not a list and shouldn't normally be treated as one. Even if it was a list, [lrange $rest 0 end] would return all of it, which sort makes it strange that there would be a need to additionally define 'str'.
There are other parts of the script that I think look rather ugly. For example :-
| Code: |
if {$nick == $botnick} {
return 0
}
if {$str == ""} {
putchan $chan "$nick: What? Чего надо ?"
return 0
}
|
Would look rather better as :-
| Code: |
if {[isbotnick $nick]} {
return 0
}
if {[string length $str] == 0} {
putchan $chan "$nick: What? Чего надо ?"
return 0
}
|
Not that this would excuse the cross-over of string and list manipulation functions, which I have maintained by using 'string length' on the list variable 'str' as returned from the 'lrange' statement.
I'm not saying these corrections and several others in the script would resolve your problem but I am saying that I wouldn't use this script. _________________ I must have had nothing to do |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Mon Aug 10, 2009 12:35 pm Post subject: |
|
|
One thing that I thought of, thanks to arfer's mentioning of spaces...
It's not uncommon for clients/extensions to add control characters (such as bold, color, underline, etc) when using nick completion.. In this case, the pub binding will undoubtedly fail, as eggdrop does not strip these prior mask/command matching. If this is the case, your best option would be to use a pubm binding and create a suitable pattern/regular expression, possibly along with the use of the stripcodes command. _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
[3-33] Voice
Joined: 08 Aug 2009 Posts: 6
|
Posted: Mon Aug 10, 2009 12:52 pm Post subject: |
|
|
well, i didnt say to upload your complete bot of course, i say if u can give me link, or upload the version of that bot u are using  _________________ The end is a new begining |
|
| Back to top |
|
 |
|
|
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
|
|