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.

Automatic undo +t and -o nick and kick with setudef flag

Old posts that have not been replied to for several years.
User avatar
Papillon
Owner
Posts: 724
Joined: Fri Feb 15, 2002 8:00 pm
Location: *.no

Post by Papillon »

ah.. sorry.. little typo there :oops:
hmmm
[21:24:53] * Ralfos sets mode: +t <<--- Ralfos wouldn't happen to have the +n userflag would he?
Elen sila lúmenn' omentielvo
V
Volume
Halfop
Posts: 84
Joined: Fri May 23, 2003 5:08 am

Post by Volume »

Papillon wrote:ah.. sorry.. little typo there :oops:
hmmm
[21:24:53] * Ralfos sets mode: +t <<--- Ralfos wouldn't happen to have the +n userflag would he?
Ralfos have non flags is a handop login
V
Volume
Halfop
Posts: 84
Joined: Fri May 23, 2003 5:08 am

@Papillon

Post by Volume »

Volume wrote:
Papillon wrote:ah.. sorry.. little typo there :oops:
hmmm
[21:24:53] * Ralfos sets mode: +t <<--- Ralfos wouldn't happen to have the +n userflag would he?
Ralfos have non flags is a handop login
thank you very mutch for your greate help :)

i have edit this line:

Code: Select all

if {![string match "+topiccheck" $chaninfo]} {
to

Code: Select all

if {![string match "*+topiccheck*" $chaninfo]} {
and the scripts works perfectly :wink:
V
Volume
Halfop
Posts: 84
Joined: Fri May 23, 2003 5:08 am

Limit Restrictet script problem

Post by Volume »

This script Restrict users (no bots and owners) they change +l or -l on a chan. but the dont works :( i would the script to adjust on the partyline but the bot doing nothing after the edit :( please help me Papillon i have no idea.

This script Boot the user on the partyline and kick him on the chan and add. a 24 h globalban sticky its good wenn the user is not adding :). than change the flags -fp and give him +k and than +d.
The Boot from partyline must automatic always whatever LIMITCHECK is on or off. other settings can be edit on the partyline.

for all edits is the +LIMITCHECK flag assumption.

Partyline edit:

Code: Select all

# Für wie viele Minuten möchtest du den Channel auf Invite lassen?
# For how many minutes whould you like chan invite?
#     (default : 20)
set chan(invitetime) 20

# Für wie vielen Minuten möchtest du den Globalban Sticky laufen lassen?
# Clones [T-Online] und andere Dialin haben max. 24h login (24h Trennung) !
# For how many minutes whould you like the Globalban Sticky?
# Clones [T-Online] and other Dialin have max. 24h login (24h breakup)
#     (default: 1440 = 24h)
set glb(sticky) 1440


# ---------------------- code - nicht verändern - don´t change - code ------------------------#

setudef flag LIMITCHECK
setudef flag linvite
setudef flag ldeop
setudef flag lkick
setudef flag limitback
setudef flag lglobban
setudef flag lautodeinvite

proc majonas_limit_restrict {nick uhost hand chan mode victim} {
    set chaninfo [channel info $chan]
    if {![string match "*+LIMITCHECK*" $chaninfo]} { 
      return
    if {$mode == "+l" || $mode == "-l"} {
    if {![botisop $chan] || [matchattr $hand b] || [matchattr $hand n]} {
      return
    if {[onchan $nick $chan] && $nick != $::botnick} {
    set delflagfp "chattr [nick2hand $nick] -fp"
    set bootpl "boot [nick2hand $nick] 12limitabuse0.5.tcl"
    set kick "putkick $chan $nick"
    set chlimit "pushmode $chan +l [expr [llength [chanlist $chan]] + 4]"
    set hostban "*!*[string range $uhost [string first "@" $uhost] end]"
    set addflagk "chattr [nick2hand $nick] +k"
    set globban "newban $hostban 7Majonas 12limitabuse0.4.tcl $::glb(sticky) sticky"
    set deinvite "pushmode $chan -i"
    set globdeop "chattr [nick2hand $nick] +d"
    if {[string match "*+linvite*" $chaninfo]} { pushmode $chan +i } 
    if {[string match "*+ldeop*" $chaninfo]} { pushmode $chan -o $nick }    
    if {[string match "*+lkick*" $chaninfo]} { list putkick $chan $kick }      
    if {[string match "*+limitback*" $chaninfo]} { utimer 3 $chlimit }
    if {[string match "*+lglobban*" $chaninfo]} { utimer 4 $globban }          
    if {[string match "*+lautodeinvite*" $chaninfo]} { timer $::chan(invitetime) $deinvite }
    utimer 1 $delflagfp
    utimer 1 $bootpl
    utimer 2 $addflagk
    utimer 5 $globdeop    
     
		
	}
}

return 0

	} }
}

Originalscript that works great but is not edit on partyline:

Code: Select all

# Für wie viele Minuten möchtest du den Channel auf Invite lassen?
# For how many minutes whould you like chan invite?
#     (default : 20)
set chan(invite) 20

# Für wie vielen Minuten möchtest du den Globalban Sticky laufen lassen?
# Clones [T-Online] und andere Dialin haben max. 24h login (24h Trennung) !
# For how many minutes whould you like the Globalban Sticky?
# Clones [T-Online] and other Dialin have max. 24h login (24h breakup)
#     (default: 1440 = 24h)
set glb(sticky) 1440


# ---------------------- code - nicht verändern - don´t change - code ------------------------#


bind mode - * majonas_limit_restrict

proc majonas_limit_restrict {nick uhost hand chan mode victim} {

    if {$mode == "+l" || $mode == "-l"} {
    if {[matchattr $hand b] || [matchattr $hand n]} {

    return 0

    } else {
    
    if {[onchan $nick $chan]} {
      pushmode $chan +i
      pushmode $chan -o $nick
      set kick "putkick $chan $nick"
      utimer 1 $kick
          set delflagfp "chattr [nick2hand $nick] -fp"
          utimer 1 $delflagfp
          set bootpl "boot [nick2hand $nick] 12limitabuse0.5.tcl"
          utimer 1 $bootpl
          set addflagk "chattr [nick2hand $nick] +k"
          utimer 2 $addflagk
      set chlimit "pushmode $chan +l [expr [llength [chanlist $chan]] + 4]"
      utimer 3 $chlimit
          set hostban "*!*[string range $uhost [string first "@" $uhost] end]"
          set globban "newban $hostban 7Majonas 12limitabuse0.4.tcl $::glb(sticky) sticky"
          utimer 4 $globban
          set globdeop "chattr [nick2hand $nick] +d"
          utimer 5 $globdeop
      set deinvite "pushmode $chan -i"
      timer $::chan(invite) $deinvite

	}
}

return 0

	}
}
Locked