[TMG]Energy Posted May 9, 2005 Share Posted May 9, 2005 Can someone give the !warn script? Thanks Energy Link to comment
Niels Posted May 9, 2005 Share Posted May 9, 2005 alias mta.warn { if ($4 != $null) { if ( $readini( "MTAwarn.ini", main, $mta.name($1,$4) ) == 1 ) { if ($5 != $null) { mta.say $1 $mta.name($1,$4) $+ : 2nd warning. 1 more warning and you will be kicked. Reason: $5- writeini "MTAwarn.ini" main $mta.name($1,$4) 2 writeini "MTAwarn.ini" reasons $mta.name($1,$4) $5- } else { mta.say $1 $mta.name($1,$4) $+ : 2nd warning. 1 more warning and you will be kicked. writeini "MTAwarn.ini" main $mta.name($1,$4) 2 } } elseif ( $readini( "MTAwarn.ini", main, $mta.name($1,$4) ) == 2 ) { if ($5 != $null) { mta.say $1 $mta.name($1,$4) $+ : 3rd and final warning. Reason: $5- $+ . Goodbye! mta.kick $1 $4 writeini "MTAwarn.ini" main $mta.name($1,$4) 3 writeini "MTAwarn.ini" reasons $mta.name($1,$4) $5- } else { mta.say $1 $mta.name($1,$4) $+ : 3rd and final warning. Goodbye! mta.kick $1 $4 writeini "MTAwarn.ini" main $mta.name($1,$4) 3 } } else { if ($5 != $null) { mta.say $1 $mta.name($1,$4) $+ : 1st warning. 2 more warnings and you will be kicked. Reason: $5- writeini "MTAwarn.ini" main $mta.name($1,$4) 1 writeini "MTAwarn.ini" reasons $mta.name($1,$4) $5- } else { mta.say $1 $mta.name($1,$4) $+ : 1st warning. 2 more warnings and you will be kicked. writeini "MTAwarn.ini" main $mta.name($1,$4) 1 } } } else { mta.say $1 $mta.name($1,$2) $+ : Syntax - !warn } } on *:SIGNAL:mta.join: { elseif ( $readini( "MTAwarn.ini", main, $mta.name($1,$2) ) == 3 ) { mta.say $1 $mta.name($1,$2) $+ : Access denied - exceeded warn quota writeini "MTAwarn.ini" joinkick $mta.name($1,$2) $mta.ip($1,$2) mta.kick $1 $2 } } on *:SIGNAL:mta.command: { if ($3 == !warn) && ($mta.name($1,$2) == [TMG]Energy) { mta.warn $1- } if ($3 == !warnings) { if ($4 != $null) { if ( $readini( "MTAwarn.ini", main, $mta.name($1,$4) ) == 1 ) { mta.say $1 $mta.name($1,$4) has been warned 1 time. } elseif ( $readini( "MTAwarn.ini", main, $mta.name($1,$4) ) == 2 ) { mta.say $1 $mta.name($1,$4) has been warned 2 times. } else { mta.say $1 $mta.name($1,$4) has been warned 0 times. } } else { if ( $readini( "MTAwarn.ini", main, $mta.name($1,$2) ) == 1 ) { mta.say $1 $mta.name($1,$2) $+ : you have been warned 1 time. } elseif ( $readini( "MTAwarn.ini", main, $mta.name($1,$2) ) == 2 ) { mta.say $1 $mta.name($1,$2) $+ : you have been warned 2 times. } else { mta.say $1 $mta.name($1,$2) $+ : you have been warned 0 times. } } } if ($3 == !erasewarn) && ($mta.name($1,$2) == [TMG]Energy) { if ($4 != $null) { mta.say $1 $mta.name($1,$2) $+ : Removed warnings on $4 remini "MTAwarn.ini" main $4 remini "MTAwarn.ini" joinkick $4 remini "MTAwarn.ini" reasons $4 } else { mta.say $1 Syntax: !erasewarn } } } Script by oli Link to comment
=DS=*Weed* Posted May 10, 2005 Share Posted May 10, 2005 Not a real safe script no admin system only if ($3 == !warn && $mta.name($1,$2) == [TMG]Energy. Every clone can warn. Why don't u use the GRS? Link to comment
MeanpantheR Posted May 10, 2005 Share Posted May 10, 2005 and what if he wants to make his own script that isnt as heavy as GRS Edit: also you can simple change ($mta.name($1,$2) == [TMG]Energy) to ($mta.ip($1,$2) == yourIPhere) Link to comment
[TMG]Energy Posted May 12, 2005 Author Share Posted May 12, 2005 it's work but one problem... } if ($3 == !erasewarn) && ($mta.name($1,$2) == [TMG]Energy) { if ($4 != $null) { mta.say $1 $mta.name($1,$2) $+ : Removed warnings on $4 remini "MTAwarn.ini" main $4 remini "MTAwarn.ini" joinkick $4 remini "MTAwarn.ini" reasons $4 } else { mta.say $1 Syntax: !erasewarn } } } i must do --> !erasewarn [TMG]Energy i will can do --> !erasewarn Energy (or ene, ener or ID number) Link to comment
Niels Posted May 12, 2005 Share Posted May 12, 2005 if ($3 == !erasewarn) && ($mta.name($1,$2) == [TMG]Energy) { if ($4 != $null) { mta.say $1 $mta.name($1,$2) $+ : Removed warnings on $mta.name($1,$4) remini "MTAwarn.ini" main $mta.name($1,$4) remini "MTAwarn.ini" joinkick $mta.name($1,$4) remini "MTAwarn.ini" reasons $mta.name($1,$4) } else { mta.say $1 Syntax: !erasewarn } } } Try this this is working by id. Link to comment
Recommended Posts