| View previous topic :: View next topic |
| Author |
Message |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Tue Aug 09, 2011 2:34 am Post subject: how to start this.. |
|
|
| on join whois the user if nick is registered.. |
|
| Back to top |
|
 |
caesar Mint Rubber

Joined: 14 Oct 2001 Posts: 3741 Location: Mint Factory
|
Posted: Tue Aug 09, 2011 3:19 am Post subject: |
|
|
You'll have to at least mention the network (or the server). _________________ Once the game is over, the king and the pawn go back in the same box. |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Tue Aug 09, 2011 11:40 pm Post subject: |
|
|
| Oops sorry sir the network is Dalnet |
|
| Back to top |
|
 |
caesar Mint Rubber

Joined: 14 Oct 2001 Posts: 3741 Location: Mint Factory
|
Posted: Wed Aug 10, 2011 4:22 am Post subject: |
|
|
| Code: |
bind join * * registered:join
bind raw - 307 registered:match
bind raw - 311 registered:first
bind raw - 318 registered:last
proc registered:join {nick uhost hand chan} {
if {[isbotnick $nick]} return
puthelp "WHOIS $nick"
}
proc registered:first {from key text} {
global registered
set user [lindex [split $text] 1]
set registered($user) 0
}
proc registered:match {from key text} {
global registered
set user [lindex [split $text] 1]
set registered($user) 1
# user has identified for this nick
# use $user to do whatever you need with it
}
proc registered:last {from key text} {
global registered
set user [lindex [split $text] 1]
if {!$registered($user)} {
# user didn't identified for this nick
# use $user to do whatever you need with it
}
# don't remove the following line
array unset registered $user
}
|
As always, I haven't tested this, but should work. If it doesn't then let me know.
Edit: fixed. _________________ Once the game is over, the king and the pawn go back in the same box.
Last edited by caesar on Thu Oct 20, 2011 6:27 am; edited 1 time in total |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Thu Sep 22, 2011 7:06 am Post subject: |
|
|
Hi sir caesar, how can i halt the script on netsplit since it will autovoice all registered nick that came from netsplit? Thanks in advance.  |
|
| Back to top |
|
 |
Sydneybabe Op
Joined: 27 Apr 2007 Posts: 106 Location: Philippines
|
Posted: Thu Oct 20, 2011 3:08 am Post subject: |
|
|
Hello sir caesar, i am encountering an error on the script this is what appear on the partyline:
| Code: | <eggdrop> [14:56:21] Tcl error [registered:first]: can't read "user": no such variable
<eggdrop> [14:56:21] Tcl error [registered:match]: can't read "user": no such variable |
|
|
| Back to top |
|
 |
caesar Mint Rubber

Joined: 14 Oct 2001 Posts: 3741 Location: Mint Factory
|
Posted: Thu Oct 20, 2011 6:27 am Post subject: |
|
|
Ah, sorry, mixed two lines and forgot to add one. Fixed the code in my previous post. _________________ Once the game is over, the king and the pawn go back in the same box. |
|
| Back to top |
|
 |
|