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.

FZCommands - problems

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
User avatar
m4s
Halfop
Posts: 97
Joined: Mon Jan 30, 2017 3:24 pm

FZCommands - problems

Post by m4s »

Hello Everyone!

I am using fzcommand.tcl by Opposing and I have two requests.

1. The eggdrop don't remove the ban however I set the set fzcom(btime) variable.
2. If I want to change my password using "/msg botnick PASS oldpass newpass" command the script response with a notice:
Your password has been set before, you don't need to set it again. Simply type: [/msg botnick auth <password>] to authenticate yourself.

The script is here: https://pastebin.ubuntu.com/24333312/

Can anyone help? Thank You! :))

P.s.: I deleted my previous topic regarding fzcommands.tcl.
Last edited by m4s on Wed May 01, 2019 7:42 am, edited 2 times in total.
User avatar
Arnold_X-P
Master
Posts: 226
Joined: Mon Oct 30, 2006 12:19 am
Location: DALnet - Trinidad - Beni - Bolivia
Contact:

Re: FZCommands

Post by Arnold_X-P »

I am using fzcommand.tcl by Opposing and I have two requests.

1. The eggdrop don't remove the ban however I set the set fzcom(btime) variable.
2. If I want to change my password using "/msg botnick PASS oldpass newpass" command the script response with a notice:
Your password has been set before, you don't need to set it again. Simply type: [/msg botnick auth <password>] to authenticate yourself.

1.- The first point was solved
2.- To change the password is /msg botname pass <password>

tcl
.:an ideal world:. www.geocities.ws/chateo/yo.htm
my programming place /server ix.scay.net:7005
User avatar
m4s
Halfop
Posts: 97
Joined: Mon Jan 30, 2017 3:24 pm

Re: FZCommands

Post by m4s »

Arnold_X-P wrote:I am using fzcommand.tcl by Opposing and I have two requests.

1. The eggdrop don't remove the ban however I set the set fzcom(btime) variable.
2. If I want to change my password using "/msg botnick PASS oldpass newpass" command the script response with a notice:
Your password has been set before, you don't need to set it again. Simply type: [/msg botnick auth <password>] to authenticate yourself.

1.- The first point was solved
2.- To change the password is /msg botname pass <password>

tcl
First thank you for your work and help! I appreciate it! :)

The 2nd error still have. After /msg botname pass <password>

I got: [Notice] -Mybot- : Your password has been set before, you don't need to set it again. Simply type: [/msg Mybot auth <password>] to authenticate yourself.

I did a restart but nothing changed.
User avatar
m4s
Halfop
Posts: 97
Joined: Mon Jan 30, 2017 3:24 pm

Post by m4s »

The 1. point solved by Arnold_X-P. Thanks! :)
The 2. point also 'solved'.
To avoid the above mentioned error you only comment the following lines in the script:

original line: unbind msg - pass *msg:pass
modified line: #unbind msg - pass *msg:pass

original line: bind msg p|p pass fz:mpass
modified line: #bind msg p|p pass fz:mpass

original section:

Code: Select all

proc fz:mpass {nick uhost hand arg} {
 global botnick fzcom
 if {[set pw [lindex [split $arg] 0]] == ""} {
  puthelp "NOTICE $nick :$fzcom(logo): SYNTAX: /msg $botnick pass <password>" 
  return 0
 }
 if {![passwdok $hand ""]} {
  puthelp "NOTICE $nick :$fzcom(logo): Your password has been set before, you don't need to set it again. Simply type: \[/msg $botnick auth <password>\] to authenticate yourself. To change the password use only /msg $botnick pass <password>"
  return 0
 }
 setuser $hand PASS $pw
 puthelp "NOTICE $nick :$fzcom(logo): Your password is now set to: \002$pw\002, remember your password for future use."
 putcmdlog "$fzcom(logo): <<$nick>> !$hand! Set Password."
 return 0
}
modified section:

Code: Select all

#proc fz:mpass {nick uhost hand arg} {
# global botnick fzcom
# if {[set pw [lindex [split $arg] 0]] == ""} {
#  puthelp "NOTICE $nick :$fzcom(logo): SYNTAX: /msg $botnick pass <password>" 
# return 0
#[/b] }
# [/b]if {![passwdok $hand ""]} {
#  puthelp "NOTICE $nick :$fzcom(logo): Your password has been set before, you don't #need to set it again. Simply type: \[/msg $botnick auth <password>\] to authenticate #yourself. To change the password use only /msg $botnick pass <password>"
#  return 0
# }
# setuser $hand PASS $pw
# puthelp "NOTICE $nick :$fzcom(logo): Your password is now set to: \002$pw\002, remember your password for future use."
# putcmdlog "$fzcom(logo): <<$nick>> !$hand! Set Password."
#return 0
#}
The !up command did not work needed a modification.
original line:
putserv "$fzcom(chanserv) :[string map [list %chan $chan %botnick $botnick] $fzcom(chanservop)]"

modified lline:
putserv "$fzcom(chanserv) [string map [list %chan $chan %botnick $botnick] $fzcom(chanservop)]"

The working script is here: https://paste.ubuntu.com/24890970/

Can someone add !halfop and !dehalfop commands to this script? :)
User avatar
m4s
Halfop
Posts: 97
Joined: Mon Jan 30, 2017 3:24 pm

Bot removes the ban

Post by m4s »

Hi,

I want my bot not to remove the ban after !bankick and I set the set fzcom(btime) "0", because 0 means unlimited (# Set default bantime for ban commands if no bantime was specified (in minutes, 0 means unlimited):).

If the fzcom(btime) is 0 and i use !bankick nick the bot removes the ban immediately.

Can someone have a look pls? Thanks! :)

Tcl.: https://pastebin.ubuntu.com/24882707/
s
simo
Revered One
Posts: 1071
Joined: Sun Mar 22, 2015 2:41 pm

Post by simo »

ive tested this tcl on my testnet and it seems to work fine tho it didnt remove ban instantly as u mentioned:


(+simo) : !bankick
-TCL-Tester- : SYNTAX: !bankick <nick1/ban1,nick2/ban1,..> [reason] [bantime].
(+simo) : !bankick Obryan,Loan,Gertrude SomeReason
~TCL-Tester Sets Mode on #testing to: +b *!*@RifSytes-04u.091.42.96.IP
(1 User) is Banned Obryan
Obryan Kicked from #testing By ~TCL-Tester <> ( SomeReason )
~TCL-Tester Sets Mode on #testing to: +b *!*@Cloaked-mz1.202.41.87.IP
(1 User) is Banned Loan
Loan Kicked from #testing By ~TCL-Tester <> ( SomeReason )
~TCL-Tester Sets Mode on #testing to: +b *!*@16.50.136.121
(1 User) is Banned Gertrude
Gertrude Kicked from #testing By ~TCL-Tester <> ( SomeReason )
-TCL-Tester- : Bankicked Obryan,Loan,Gertrude from #testing.

yes i removed the logo thing and such for testing
User avatar
m4s
Halfop
Posts: 97
Joined: Mon Jan 30, 2017 3:24 pm

Post by m4s »

simo wrote:ive tested this tcl on my testnet and it seems to work fine tho it didnt remove ban instantly as u mentioned:

Strange... I checked again and the ban is removed within a minute...
s
simo
Revered One
Posts: 1071
Joined: Sun Mar 22, 2015 2:41 pm

Post by simo »

ive tested again and yes it seems ur right it does remove ban within a minute

if this is used
and no bantime is provided in the bankick command

SYNTAX: !bankick <nick1/ban1,nick2/ban1,..> [reason] [bantime].

set fzcom(btime) "0"

it doesnt if this is used tho

set fzcom(btime) "30"
Post Reply