| View previous topic :: View next topic |
| Author |
Message |
m4s Halfop

Joined: 30 Jan 2017 Posts: 97
|
Posted: Tue May 30, 2017 12:47 pm Post subject: Dalnet Bot Service 2.0 |
|
|
Hi all!
I am using this script. It is able to identify my bot to nickserv but when I do rehash in DCC the bot stops an I get this error message:
Tcl error in file 'configfilel':
[18:27] invalid timerID
while executing
"killtimer $optimer "
(file "scripts/nickserv.tcl" line 145)
invoked from within
* CONFIG FILE NOT LOADED (NOT FOUND, OR ERROR)
Here is the script:
https://paste.ubuntu.com/24716793/
Can anyone have a look?
Thanks!
IMPORTANT!
!!! I don't use this script on DALNET! I am using it on another network so the script is modified! !!!
Update: You can use this script on those networks where the identification to nickserv look like this:
/msg nickserv IDENTIFY password.
Last edited by m4s on Mon Sep 25, 2017 3:59 pm; edited 4 times in total |
|
| Back to top |
|
 |
simo Owner
Joined: 22 Mar 2015 Posts: 941
|
Posted: Tue May 30, 2017 1:17 pm Post subject: |
|
|
you could give this a try:
| Code: |
bind evnt - init-server evnt:init_server
proc evnt:init_server {type} {
global botnick
putquick "MODE $botnick +RSi"
putquick "PRIVMSG NickServ@services.dal.net :identify password"
}
bind notc - "*This nick is owned by someone else*" autoident
bind notc - "*Password accepted for*" compautoident
proc autoident {nick uhost hand text dest} {
putserv "PRIVMSG NickServ@services.dal.net :identify password"
}
proc compautoident {nick uhost hand text dest} {
putserv "PRIVMSG #yourchannel :\002Identification\002 has been successful.."
}
bind join - * mejoin
proc mejoin {nick uhost hand chan} {
if {$chan == "#yourchannel"} {
if [isbotnick $nick] {putserv "PRIVMSG ChanServ@services.dal.net op $chan"}
}
}
|
|
|
| Back to top |
|
 |
CP1832 Halfop
Joined: 09 Oct 2014 Posts: 68
|
Posted: Wed May 31, 2017 9:52 am Post subject: |
|
|
Hi m4s:
I've been using for a while now on dalnet and it's been flawlessly: | Code: | # Keep nick v2.0 by Mezen <mezen0@msn.com>
# This script allows to solve connection issue after receiving
# Invalid Nick notice from the network. It will make the bot release
# its nickname and identify to it.
# This script is made for Dalnet but can be adapted to any other
# network with small modifications
# to install it, just copy it to the folder /path/to/eggdrop/scripts
# then add this line at the end of the eggdrop.conf
# source scripts/keepnick.tcl
#######################################
# Config #
#######################################
# set here bot's password
set KP(botpass) "yourpass"
# set here nickserv's hostname
set KP(nickserv) "nickserv@services.dal.net"
#######################################
# Do not edit below this line #
#######################################
# removing old binds
unbind evnt - init-server evnt:init_server
# creating new binds
foreach bind [binds kp_invalid_server_proc] {lassign $bind type flags mask num proc; unbind $type $flags $mask $proc}
bind evnt - init-server kp_init_server_proc
foreach bind [binds kp_invalid_nick_proc] {lassign $bind type flags mask num proc; unbind $type $flags $mask $proc}
bind raw - 432 kp_invalid_nick_proc
bind raw - 433 kp_invalid_nick_proc
# saving bot's nick in a variable
set KP(botnick) $nick
proc kp_invalid_nick_proc { from keyword text } {
global nick altnick botnet-nick
set newnick $nick
set chars "abcdefghijkmnopqrstuvwxyz023456789";
set anick $altnick
while {[regexp -all {\?} $anick]>0} {
set char [string index $chars [expr int(rand()*[string length $chars])]]
if {[expr rand()]>0.5} {set char [string toupper $char]}
regsub {\?} $anick $char anick
}
putlog "Alternating Nick: $nick -> $anick"
set nick $anick
if {[string match -nocase ${botnet-nick} $newnick]} {
putlog "Jumping to next server..."
jump
}
}
proc kp_init_server_proc {type} {
global nick KP
putquick "MODE $nick +ir-ws"
putquick "PRIVMSG $KP(nickserv) :identify $KP(botnick) $KP(botpass)" -next
putquick "PRIVMSG $KP(nickserv) :release $KP(botnick) $KP(botpass)" -next
putquick "PRIVMSG $KP(nickserv) :ghost $KP(botnick) $KP(botpass)" -next
set nick $KP(botnick)
}
set KP(version) " 2.0"
set KP(script) "KP -- Keep Nick -- "
putlog "\002Loading\002: $KP(script)$KP(version) by Mezen." |
|
|
| Back to top |
|
 |
Arnold_X-P Master

Joined: 30 Oct 2006 Posts: 221 Location: DALnet - Trinidad - Beni - Bolivia
|
Posted: Sun Jun 04, 2017 4:58 pm Post subject: Re: Dalnet Bot Service 2.0 |
|
|
hi m4s
your code error is set optimer [timer $opcheck nickID]
The error was in the reading of time and to which I solve.
Try to try:
| Code: |
###################################################################
# DALnet Bot Services v2.0
# By Get_A_Fix - getafix007@hotmail.com
# update for Arnold_X-P network: DALnet irc.dal.net channel #tcls
# Features:
# * Auto-Identify when the bot detects that NickServ
# wants a password.
# * Manual commands to get the bot to identify and to op #channel
# * Auto checks to see if the bot has ops. If the bot doesn't
# the bot will request ops from ChanServ.
#
# Manual usage:
# * Type ".nickserv" in DCC Chat [without inverted commas]
# * Type "!identify" in channel [without inverted commas]
# * Type "!opup" in channel [without inverted commas]
#
###################################################################
# Channels to check weather or not the bot has ops
# ie: set chancheck "#channel1 #channel2 #channel3"
set chancheck "#mychan"
# Command used to identify with nick services
set identcmd "identify"
# Set channel you want msg's from the bot to go to
set homechan "#mychan"
# Password for nick services
set identpass "mypass"
# Nickname for nick services bot
set nickserv "NickServ"
# Set this to what message Nickserv issues when it detects a registered nick
bind notc - "This nick**" identify_notc
# Nickname for channel services bot
set chanserv "ChanServ"
# How often do you want to check ops status (minutes)
# Default of 1hr checks
set opcheck 60
####################################
#### DO NOT EDIT ANYTHING BELOW ####
####################################
set nickver 2.0
proc say_succ { nick uh hand text dest } {
global homechan nickserv
putserv "PRIVMSG $homechan :\002Identified to NickServ successfully\002"
putlog "Identified to $nickserv successfully"
unbind notc - "*Password accepted*" say_succ
}
proc identify_notc { nick uh hand text dest } {
global botnick nickserv identcmd identpass
putlog "$nickserv requested identification..."
if {[string match [string tolower $nick] [string tolower $nickserv]]} {
putserv "PRIVMSG $nickserv $identcmd $identpass"
putlog "Identifying $nickserv as $botnick..."
}
}
bind dcc - nickserv identify_dcc
proc identify_dcc { hand idx args } {
global botnick nickserv identcmd identpass
putlog "Identifying to $nickserv as $botnick..."
putserv "PRIVMSG $nickserv $identcmd $identpass"
bind notc - "*Password accepted*" say_succ
}
bind pub o|o !identify identify_pub
proc identify_pub { nick uhost hand chan arg } {
global botnick nickserv identcmd identpass
putlog "$nick requested in $chan to identify to $nickserv..."
putserv "PRIVMSG $chan :\002Identifying to $nickserv (Requested by $nick)\002"
putlog "Identifying to $nickserv as $botnick..."
putserv "PRIVMSG $nickserv $identcmd $identpass"
bind notc - "*Password accepted*" say_succ
}
bind pub o|o !opup opup_pub
proc opup_pub { nick uhost hand chan arg } {
global botnick nickserv chanserv identcmd identpass
putlog "$nick requested in $chan to op up..."
putserv "PRIVMSG $chan :\002OP-Up for $chan (Requested by $nick)\002"
putlog "Requesting ops for $chan..."
putserv "PRIVMSG $nickserv $identcmd $identpass"
putserv "PRIVMSG $chanserv OP $chan $botnick"
}
bind notc - "*Jelszavad elfogadva*" identify_succ
proc identify_succ { nick uh hand text dest } {
global botnick nickserv
putlog "Identified to $nickserv as $botnick successfully!"
}
proc nickID {} {
global botnick opcheck identcmd identpass nickopauth optimer nickserv
if {$identpass == ""} {
putlog "Services Error: No password defined."
unset -nocomplain -- optimer
return 0
} else {
putlog "Authorizing with Nickserv ..."
putserv "PRIVMSG $nickserv $identcmd $identpass"
set nickopauth true
utimer 5 checkops
}
}
proc checkops {} {
global botnick chancheck nickopauth opcheck optimer
if {$nickopauth == ""} {
putlog "Services Error: Did NOT auth with NickServ."
nickID
return 0
} else {
if {$chancheck == ""} {
putlog "Services Error: No channels defined!"
return 0
} else {
set channels [llength $chancheck]
putlog "Checking @ status on: $chancheck ..."
for {set loop 0} {$loop < $channels} {incr loop} {
if {[validchan [lindex $chancheck $loop]]} {
if {![botisop [lindex $chancheck $loop]]} {
utimer 5 "Op_Req [lindex $chancheck $loop]"
putlog "Requesting @ from ChanServ on [lindex $chancheck $loop] ..."
}
} else {putlog "Services Error: No channel record for [lindex $chancheck $loop]"}
}
unset -nocomplain -- nickopauth
timer $opcheck [list nickID]
}
}
}
proc Op_Req {channel} {
global botnick chanserv
if {![botisop $channel]} {puthelp "PRIVMSG $chanserv OP $channel $botnick"}
}
if {[info exists optimer]} {killtimer $optimer}
timer $opcheck [list nickID]
putlog "DALnet Bot Services v$nickver By Get_A_Fix - Loaded and Running"
putlog "Command will be: /NickServ $identcmd HIDDENPASS" |
_________________
thanks to that they help, that others learn  |
|
| Back to top |
|
 |
m4s Halfop

Joined: 30 Jan 2017 Posts: 97
|
Posted: Thu Jun 15, 2017 2:05 pm Post subject: Re: Dalnet Bot Service 2.0 |
|
|
| Quote: | hi m4s
your code error is set optimer [timer $opcheck nickID]
The error was in the reading of time and to which I solve.
Try to try:
|
Hi Arnold_X-P!
Thanks for your script it works! Great!  |
|
| Back to top |
|
 |
Get_A_Fix Master

Joined: 07 May 2005 Posts: 206 Location: New Zealand
|
Posted: Thu Jun 15, 2017 9:17 pm Post subject: |
|
|
WOW, that script is so old, I haven't used that Hotmail email since the 90's _________________ We explore.. and you call us criminals. We seek after knowledge.. and you call us criminals. We exist without skin color, without nationality, without religious bias.. and you call us criminals. |
|
| Back to top |
|
 |
Arnold_X-P Master

Joined: 30 Oct 2006 Posts: 221 Location: DALnet - Trinidad - Beni - Bolivia
|
Posted: Sat Jun 17, 2017 12:34 pm Post subject: |
|
|
Thank the creator Get_A_Fix he is the real genius
I just corrected a small sector _________________
thanks to that they help, that others learn  |
|
| Back to top |
|
 |
m4s Halfop

Joined: 30 Jan 2017 Posts: 97
|
Posted: Sat Jun 17, 2017 2:06 pm Post subject: |
|
|
Hi,
Guys, I have just found another thing.
I deoped my bot to see the how the oping procedure works.
I got the following error:
[19:55] <Mybot> [19:55] Requesting @ from ChanServ on #mychan ...
[19:55] <Mybot> [19:55] Tcl error in script for 'timer386455':
[19:55] <Mybot> [19:55] can't read "chanserv": no such variable
First I changed this line (115):
global botnick chancheck nickopauth opcheck optimer
to this:
global botnick chancheck nickopauth opcheck optimer chanserv
but the error still have.
Any Idea?
In the config section I use this: set chanserv "ChanServ".
Thanks!  |
|
| Back to top |
|
 |
Arnold_X-P Master

Joined: 30 Oct 2006 Posts: 221 Location: DALnet - Trinidad - Beni - Bolivia
|
Posted: Sat Jun 17, 2017 2:19 pm Post subject: |
|
|
What version of eggdrop does _________________
thanks to that they help, that others learn  |
|
| Back to top |
|
 |
m4s Halfop

Joined: 30 Jan 2017 Posts: 97
|
Posted: Sat Jun 17, 2017 2:26 pm Post subject: |
|
|
| Arnold_X-P wrote: | | What version of eggdrop does |
1.8.1 |
|
| Back to top |
|
 |
Arnold_X-P Master

Joined: 30 Oct 2006 Posts: 221 Location: DALnet - Trinidad - Beni - Bolivia
|
Posted: Sat Jun 17, 2017 2:27 pm Post subject: |
|
|
Version 1.8.1 is full of errors
Use eggdrop version 1.6.20 (download eggdrop 1.6.20)
And change #mychan There place the name of your channel edit that _________________
thanks to that they help, that others learn  |
|
| Back to top |
|
 |
thommey Halfop
Joined: 01 Apr 2008 Posts: 73
|
Posted: Sat Jun 17, 2017 2:35 pm Post subject: |
|
|
| Arnold_X-P wrote: | | Version 1.8.1 is full of errors |
Oh? Do you have any concrete errors you are experiencing in 1.8.1 that you haven't in 1.6.21?
I would be very interested to hear about them and fix them.
Eggdrop1.8.x is actively developed and we appreciate any input to find and fix bugs on https://github.com/eggheads/eggdrop. |
|
| Back to top |
|
 |
Arnold_X-P Master

Joined: 30 Oct 2006 Posts: 221 Location: DALnet - Trinidad - Beni - Bolivia
|
Posted: Sat Jun 17, 2017 2:39 pm Post subject: |
|
|
If I have one in specific
Give me a few minutes _________________
thanks to that they help, that others learn  |
|
| Back to top |
|
 |
Arnold_X-P Master

Joined: 30 Oct 2006 Posts: 221 Location: DALnet - Trinidad - Beni - Bolivia
|
Posted: Sat Jun 17, 2017 2:49 pm Post subject: |
|
|
my bot is Deborilla
[14:45] * Deborilla (~Cutty@server01.shell-hosting.com) has joined #lapaz
[14:45] * ChanServ sets mode: +o Deborilla
In that bot I use the SpiKe^^ trivia and always worked fine on my eggdrop 1.6.20
When I add it in eggdrop 1.8.1 it only works for a few moments and then it drops
[14:45] <@Deborilla> 15,05 .0000. Idiomas©-«(Jejeje) ¿Cómo se dice "otorrinolaringólogo" en japonés ?
[14:45] <@Deborilla> 15,05 1er Pista: **** ****** ****** 05 Valor de la Pregunta :14 8000 puntos.
[14:45] * @Deborilla (~Cutty@server01.shell-hosting.com) Quit (Quit: triv: fatal error)
I can not enter the party line because its fall is very fast and I can not see the error
The same happens with the tcl of fb.lagcheck.tcl I get time errors
[14:46] Tcl error in script for 'timer576475':
And the error is the same in both tcl in trivia and fb.lagcheck.tcl
Apparently has the same error as eggdrop 1.6.21 in reading the time to run some tcl _________________
thanks to that they help, that others learn  |
|
| Back to top |
|
 |
Arnold_X-P Master

Joined: 30 Oct 2006 Posts: 221 Location: DALnet - Trinidad - Beni - Bolivia
|
Posted: Sat Jun 17, 2017 2:54 pm Post subject: |
|
|
Both mentioned tcl work well in eggdrop 1.6.20 _________________
thanks to that they help, that others learn  |
|
| Back to top |
|
 |
|