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.

what's wrong with this code (bind dcc)

Old posts that have not been replied to for several years.
Locked
User avatar
z_one
Master
Posts: 269
Joined: Mon Jan 14, 2002 8:00 pm
Location: Canada

what's wrong with this code (bind dcc)

Post by z_one »

What's wrong with this code. The bot keeps on saying "What, you need help?"

Code: Select all

set getoppedchannel "#mychannel"
set getoppedflags "W"

bind dcc -|W opme do_getoppedproc

proc do_getoppedproc {hand idx arg} {
  global getoppedchannel 
  if {$arg == ""} { 
    if {![botisop $getoppedchannel]} { 
      putidx $idx "Sorry, I am not opped on $getoppedchannel right now" ; return 0
    }
    set dogetoppednick [hand2nick $hand $getoppedchannel]
    if {![onchan $dogetoppednick $getoppedchannel]} {
      putidx $idx "You're not on $getoppedchannel" ; return 0
    }
    if {[isop $dogetoppednick $getoppedchannel]} {
      putidx $idx "You're already opped on $getoppedchannel" ; return 0
    }
    pushmode $getoppedchannel +o $dogetoppednick
  } else {
    putidx $idx "To get opped just type \0034 .opme \003" ; return 0
  }
}
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

you either didn't .rehash after loading the script or you dont have the W flag (which is needed for the command).
User avatar
z_one
Master
Posts: 269
Joined: Mon Jan 14, 2002 8:00 pm
Location: Canada

Post by z_one »

I do have the +W flag (I double checked) and I also rehashed and made sure the script was loaded.
The problem is none of the above. That's why I asked "what's wrong with the code".

So can anyone shed a light in here? Thanks.
User avatar
strikelight
Owner
Posts: 708
Joined: Mon Oct 07, 2002 10:39 am
Contact:

Post by strikelight »

z_one wrote:I do have the +W flag (I double checked) and I also rehashed and made sure the script was loaded.
The problem is none of the above. That's why I asked "what's wrong with the code".

So can anyone shed a light in here? Thanks.
Nothing with the code would produce a 'What? You need help.' response from the bot. That is an eggdrop response to a user trying to use a command that either does not exist, or the user does not have access to.
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

yes, maybe there's a script that has unbind dcc -|W opme do_getoppedproc in it ?
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

Add some putlogs to see if it's beeing called. Also, do a .binds dcc and see if your bind is there.
Once the game is over, the king and the pawn go back in the same box.
Locked