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.

need help with warn script

Help for those learning Tcl or writing their own scripts.
Post Reply
Y
Yusif
Voice
Posts: 34
Joined: Fri Aug 18, 2023 11:08 am

need help with warn script

Post by Yusif »

hi, when i send warn to user nothing work nothing go to room where user chat in

i do command:
!warn #chan Nick warn-msg

then in telent i get this:
[14H:08m:1692541163s] triggering bind chan:warn

nothing goes to chan

Code: Select all

# Commands:
# !warn $nick reasons-for-warn <=- send channel warn.

###################################################################

# Set channel command trigger (default: !)
set warntriga "!"

# Set channel access flags to use these commands (default: o)
# This channel access flag is only able to use: !warn
set warnchanflags o

proc getWarnTriga {} {
  global warntriga
  return $warntriga
}

bind pub - ${warntriga}warn chan:warn
proc chan:warn {nick uhost hand chan arg} {
  global warnchanflags
  if {[matchattr [nick2hand $nick] $warnchanflags $chan]} {
    putquick "MSG $chan :\002WARN\002 for $chan sent to $nick"
    putserv "MSG $nick :********* \002$chan Warn\002 **********"

    foreach botwarn [warn $chan] {
      putserv "MSG $nick :\002BOTWARN\002: $botwarn"
    }
   putserv "MSG $nick :********** \002$chan Warn \037END\037\002 **********"
  }
}

bind msg - warn chan:warn
proc chan:warn {nick uhost hand chan arg} {
  global warnchanflags
  if {([lindex $arg 0] == "") && ([matchattr [nick2hand $nick] $warnchanflags])} {
    putquick "MSG $nick :********** \002WARN\002 **********"
    foreach botwarn [warn] {
      putquick "MSG $nick :\002CHANWARN\002: $botwarn"
    }
    putquick "MSG $nick :********** \002Warn \037END\037\002 **********"
      foreach chanwarn [warn $chan] {
        putquick "MSG $nick :\002CHANWARN\002: $chanwarn"
      }
      putquick "MSG $nick :********** \002$chan Warn \037END\037\002 **********"
    }
  }

putlog "LOADED .:Warn.tcl:. - istok @ IRCSpeed"
can any help with that please
User avatar
SpiKe^^
Owner
Posts: 831
Joined: Fri May 12, 2006 10:20 pm
Location: Tennessee, USA
Contact:

MSG is Not a proper IRC command

Post by SpiKe^^ »

MSG is Not a proper IRC command!

Try using PRIVMSG...

Code: Select all

putquick "PRIVMSG $chan :\002WARN\002 for $chan sent to $nick"
SpiKe^^

Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
.
User avatar
CrazyCat
Revered One
Posts: 1241
Joined: Sun Jan 13, 2002 8:00 pm
Location: France
Contact:

Post by CrazyCat »

And the eggdrop will send message to the chan where the command is typed, or to the nick who typed the command.
Y
Yusif
Voice
Posts: 34
Joined: Fri Aug 18, 2023 11:08 am

Post by Yusif »

ty SpiKe and CC , it was PRIVMSG and i tried NOTICE and MSG
all didn't work, changed back to PRIVMSG but still not working
s
simo
Revered One
Posts: 1081
Joined: Sun Mar 22, 2015 2:41 pm

Post by simo »

lets start with what are you trying to achieve ?
User avatar
CrazyCat
Revered One
Posts: 1241
Joined: Sun Jan 13, 2002 8:00 pm
Location: France
Contact:

Post by CrazyCat »

Y
Yusif
Voice
Posts: 34
Joined: Fri Aug 18, 2023 11:08 am

Post by Yusif »

simo wrote:lets start with what are you trying to achieve ?
what do you think ?
if that all you can help with you better not bothered to ask nor reply
Y
Yusif
Voice
Posts: 34
Joined: Fri Aug 18, 2023 11:08 am

Post by Yusif »

CrazyCat wrote:I guess OP tries to do http://forum.egghelp.org/viewtopic.php?p=112085
yes i try to get help or request script as long as this forum provide that

that post i requested for payment request if any will
but seems with all good skill you have, unfortunate you not qualified to know how to deal with others
User avatar
CrazyCat
Revered One
Posts: 1241
Joined: Sun Jan 13, 2002 8:00 pm
Location: France
Contact:

Post by CrazyCat »

Yusif wrote:but seems with all good skill you have, unfortunate you not qualified to know how to deal with others
Ok.

So, let me say:
1. we have a life out of eggdrop, so peharps we wait to have time to spend to help you rather than quickly do something which won't work.
2. your ask for a script lacks a lot of things. How much can you spend in ? Is your eggdrop ircop ? Is your eggdtop present on each channel of the network ? ....
3. Personnaly, I think you idea of script is totaly dumb, and your last answer makes me think you're just an idiot, so I won't help you.
4. I won't help you, you're an idiot.

P.S.: next time, think twice before insulting people who can help you.
User avatar
SpiKe^^
Owner
Posts: 831
Joined: Fri May 12, 2006 10:20 pm
Location: Tennessee, USA
Contact:

Post by SpiKe^^ »

You can't just name all of your processes the same thing...

Code: Select all

proc chan:warn {nick uhost hand chan arg} {
the last one in the file just over-writes the others.

Delete the 2nd bind and process, and .restart the bot.
SpiKe^^

Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
.
Y
Yusif
Voice
Posts: 34
Joined: Fri Aug 18, 2023 11:08 am

Post by Yusif »

CrazyCat wrote:
Yusif wrote:but seems with all good skill you have, unfortunate you not qualified to know how to deal with others
4. I won't help you, you're an idiot.

P.S.: next time, think twice before insulting people who can help you.
this is exactly why you are not qualified to know how to deal with others


P.S.: you didn't help, you only talk from high horse

thanks for nothing
Y
Yusif
Voice
Posts: 34
Joined: Fri Aug 18, 2023 11:08 am

Post by Yusif »

thanks for your help ... all now fine someone coded script from scratch and works great .. thanks to him
Post Reply