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.

AutoIdentify script for other nicks (DALnet)

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

I don't see why it shouldn't work. Since you can't provide any information at all, try debugging the script. Use this version for debugging:

Code: Select all

set nicksNpasses {
 nick1 pass1
 nick2 pass2
 nick3 pass3
}

# Change "10 days" to "1 min" so you won't have to wait that long :P
set tenDays [clock scan "1 min"]

# change {00 00 *} to * so it'll run every minute
bind time - * identify:nicks

proc identify:nicks args {
 global nicksNpasses tenDays
 if {[unixtime] >= $tenDays} {
  identifyNicks $nicksNpasses
  set tenDays [clock scan "1 min"]
 }
}

proc identifyNicks np {
 set items 0
 foreach {nick pass} $np {
  if {$items < 5} {
   # show identification in partyline
   putlog "Identifying $nick with password: $pass"
   # comment the line below so the script doesn't send real identification
   #puthelp "NickServ :identify $nick $pass"
   incr items
  } {
   utimer 15 [list identifyNicks [lrange $nicksNpasses [expr {$items*2}] end]]
   break
  }
 }
}
Try this code. It's supposed to print "Identifying <nick> with password: <password>" in your bot's partyline for each nickname every minute (with the 15 seconds queue between every 5 nicknames of course). If it works, then there's nothing wrong with the script.
User avatar
Amr
Halfop
Posts: 94
Joined: Fri Sep 14, 2007 7:13 am
Location: Egypt

Post by Amr »

I got this error in the party line.

Code: Select all

Tcl error [identify:nicks]: can't read "nicksNpasses": no such variable
User avatar
speechles
Revered One
Posts: 1398
Joined: Sat Aug 26, 2006 10:19 pm
Location: emerald triangle, california (coastal redwoods)

Post by speechles »

Code: Select all

proc identifyNicks np {
 global nicksNpasses
 set items 0
 foreach {nick pass} $np {
 ... rest of proc continues ...
add global nicksNpasses here.
User avatar
Amr
Halfop
Posts: 94
Joined: Fri Sep 14, 2007 7:13 am
Location: Egypt

Post by Amr »

Now it says in the party line that it's identify the nicks , but it doesn't.

Also it says that it's identify the same 5 nicks every 1 sec , and ignores the

rest of the list.
User avatar
Amr
Halfop
Posts: 94
Joined: Fri Sep 14, 2007 7:13 am
Location: Egypt

Post by Amr »

so , how to fix it?
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

You didn't report that bug before although it did exist in the previous version. The correct code would be:

Code: Select all

set nicksNpasses {
 nick1 pass1
 nick2 pass2
 nick3 pass3
}

# Change "10 days" to "1 min" so you won't have to wait that long :P
set tenDays [clock scan "1 min"]

# change {00 00 *} to * so it'll run every minute
bind time - * identify:nicks

proc identify:nicks args {
 global nicksNpasses tenDays
 if {[unixtime] >= $tenDays} {
  identifyNicks $nicksNpasses
  set tenDays [clock scan "1 min"]
 }
}

proc identifyNicks np {
 set items 0
 foreach {nick pass} $np {
  if {$items < 5} {
   # show identification in partyline
   putlog "Identifying $nick with password: $pass"
   # comment the line below so the script doesn't send real identification
   #puthelp "NickServ :identify $nick $pass"
   incr items
  } {
   utimer 15 [list identifyNicks [lrange $np [expr {$items*2}] end]]
   break
  }
 }
}
Try to test it with a small list since it's just for testing purposes and will *NOT* send actual identification to the services.
Post Reply