egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Public Kick/Ban Script (w/ stored info & extended mutes)
Goto page Previous  1, 2, 3  Next
 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Support & Releases
View previous topic :: View next topic  
Author Message
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Fri Dec 31, 2021 10:33 am    Post subject: Reply with quote

i placed it here but it didnt seem to have the desired effect:

Quote:
set ok "" ; set err ""

foreach user $userls {
set user "[string trimleft $user "@+"]"
Back to top
View user's profile Send private message
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Fri Dec 31, 2021 10:57 am    Post subject: Reply with quote

thanks for the explanation on irc spike^^ i guess stripping @ would break gettin a custom banmask to set ban on as u explained on irc
Back to top
View user's profile Send private message
SpiKe^^
Owner


Joined: 12 May 2006
Posts: 770
Location: Tennessee, USA

PostPosted: Fri Dec 31, 2021 5:49 pm    Post subject: Reply with quote

Perhaps this can be a usable compromise.

Find this line in the script
Code:
    } elseif {[string is digit -strict $item]} {  set btime $item


and Add these lines just after that line...
Code:

    } elseif {[string match {[+%]?*} $item]} {
      lappend nickls [string trimleft $item "+%"]
    } elseif {[string match "@?*" $item] && ![string match {*[.:]*} $item]} {
      lappend nickls [string trimleft $item "@"]


_________________
SpiKe^^

Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
.
Back to top
View user's profile Send private message Visit poster's website
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Sat Jan 01, 2022 9:06 am    Post subject: Reply with quote

excellent tried it and seems to work well thanks Spike^^
Back to top
View user's profile Send private message
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Wed Feb 02, 2022 1:13 pm    Post subject: Reply with quote

i had a request if u are up for it Spike^^ as we use this code on various networks i found chanops on some of our networks never use multiple nicks to kick and kickban users but rather use:

!k nick custom reason
!kb nick custom reason

would it be easy to edit the code to have it work like this ?


thanks in advance.
Back to top
View user's profile Send private message
SpiKe^^
Owner


Joined: 12 May 2006
Posts: 770
Location: Tennessee, USA

PostPosted: Wed Feb 02, 2022 2:26 pm    Post subject: Reply with quote

I thought that was how it worked now?
_________________
SpiKe^^

Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
.
Back to top
View user's profile Send private message Visit poster's website
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Wed Feb 02, 2022 2:46 pm    Post subject: Reply with quote

atm its stacked both modes and kicks
Back to top
View user's profile Send private message
SpiKe^^
Owner


Joined: 12 May 2006
Posts: 770
Location: Tennessee, USA

PostPosted: Wed Feb 02, 2022 2:50 pm    Post subject: Reply with quote

I don't get the difference.

the stacker can work with a "stack" of 1, just as well as 4 or 44?
_________________
SpiKe^^

Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
.
Back to top
View user's profile Send private message Visit poster's website
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Wed Feb 02, 2022 2:50 pm    Post subject: Reply with quote

yea but it wont get the custom kick msg
Back to top
View user's profile Send private message
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Wed Feb 02, 2022 2:52 pm    Post subject: Reply with quote

<+Simo> !k Dari test
Dari Kicked from #test
-Hawk- : test is not on channel #test

the custom kick msg wasnt used by the code
Back to top
View user's profile Send private message
SpiKe^^
Owner


Joined: 12 May 2006
Posts: 770
Location: Tennessee, USA

PostPosted: Wed Feb 02, 2022 2:58 pm    Post subject: Reply with quote

That's because the command is: !k Dari .test
_________________
SpiKe^^

Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
.
Back to top
View user's profile Send private message Visit poster's website
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Wed Feb 02, 2022 3:01 pm    Post subject: Reply with quote

but we wanted to just kick 1 nick at a time and have custom kick message right after it without any additional chars like . or other


!k nick custom kick here
!kb nick custom kick here
Back to top
View user's profile Send private message
SpiKe^^
Owner


Joined: 12 May 2006
Posts: 770
Location: Tennessee, USA

PostPosted: Wed Feb 02, 2022 3:35 pm    Post subject: Lame hack Reply with quote

Try find this line in the script....
Code:
  if {$uh ne "Timer" && ![is:allowed $nk $hn $ch]} {  return 0  }



and add these lines just after that line...
Code:
  if {$do eq "k" || $do eq "kb"} {
    if {[llength [set temp [split $tx]]]>1 && ![matchstr ".*" [lindex $temp 1]]} {
      set tx "[lindex $temp 0] .[join [lrange $temp 1 end]]"
    }
  }



Leaves the script mostly as it is except for the !k and !kb commands can only do a single nick, unless you start the custom reason with a . as before.

EDIT: On further thought that may be somewhat shortsighted, as it does not look for "change target channel" or "custom bantime" arguments...
_________________
SpiKe^^

Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
.
Back to top
View user's profile Send private message Visit poster's website
simo
Owner


Joined: 22 Mar 2015
Posts: 859

PostPosted: Wed Feb 02, 2022 5:03 pm    Post subject: Reply with quote

so doing like this wont work ?

!k nick custom kick msg
!kb nick custom kick msg

i tested it ad added the line u suggested but it didnt add the custom kick msg
Back to top
View user's profile Send private message
SpiKe^^
Owner


Joined: 12 May 2006
Posts: 770
Location: Tennessee, USA

PostPosted: Wed Feb 02, 2022 5:08 pm    Post subject: Reply with quote

That's not what I said.

Said it just does that and kills the other options for the k and kb commands.

Try the hack and see...
_________________
SpiKe^^

Get BogusTrivia 2.06.4.7 at www.mytclscripts.com
or visit the New Tcl Acrhive at www.tclarchive.org
.
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Support & Releases All times are GMT - 4 Hours
Goto page Previous  1, 2, 3  Next
Page 2 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber