Raised This Month: $ Target: $400
 0% 

Ban users for freekilling


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Doc-Holiday
AlliedModders Donor
Join Date: Jul 2007
Old 10-31-2009 , 22:23   Re: Ban users for freekilling
Reply With Quote #1

Quote:
Originally Posted by izzle View Post
I want to ban them because I dont wan't them to freekill.

Right but if you do a check for 7 glows....

It will stop them after 7 kills
Doc-Holiday is offline
izzle
Senior Member
Join Date: Aug 2009
Old 10-31-2009 , 22:25   Re: Ban users for freekilling
Reply With Quote #2

Quote:
Originally Posted by NcB_Sav View Post
Right but if you do a check for 7 glows....

It will stop them after 7 kills
But it doesn't matter if they can't use the menu anymore, they can still freekill, thats why I wanted to ban them
__________________
izzle is offline
Doc-Holiday
AlliedModders Donor
Join Date: Jul 2007
Old 10-31-2009 , 22:26   Re: Ban users for freekilling
Reply With Quote #3

Quote:
Originally Posted by izzle View Post
But it doesn't matter if they can't use the menu anymore, they can still freekill, thats why I wanted to ban them

Ok well do the check if more then 7 the

ban (user) type ... but use that type of check


glowlimit[32]


then every time they use it ++glowlimit[id]

if(glowlimit[id] >= 7)
{
ban

}
Doc-Holiday is offline
izzle
Senior Member
Join Date: Aug 2009
Old 10-31-2009 , 22:27   Re: Ban users for freekilling
Reply With Quote #4

Quote:
Originally Posted by NcB_Sav View Post
Ok well do the check if more then 7 the

ban (user) type ... but use that type of check


glowlimit[32]


then every time they use it ++glowlimit[id]

if(glowlimit[id] >= 7)
{
ban

}
Ok but I want it to ban them if they use it more than 2 times in 7 rounds
__________________
izzle is offline
Doc-Holiday
AlliedModders Donor
Join Date: Jul 2007
Old 10-31-2009 , 22:29   Re: Ban users for freekilling
Reply With Quote #5

Quote:
Originally Posted by izzle View Post
Ok but I want it to ban them if they use it more than 2 times in 7 rounds

im not sure how to check the 7 rounds part.. or is 7 rounds your round limit?



if(glowlimit[id] >= 2)
{
//ban
}
Doc-Holiday is offline
izzle
Senior Member
Join Date: Aug 2009
Old 10-31-2009 , 22:29   Re: Ban users for freekilling
Reply With Quote #6

Quote:
Originally Posted by NcB_Sav View Post
im not sure how to check the 7 rounds part.. or is 7 rounds your round limit?



if(glowlimit[id] >= 2)
{
//ban
}
Every 7 rounds they can use it 2 times
__________________
izzle is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 11-01-2009 , 01:15   Re: Ban users for freekilling
Reply With Quote #7

Try something like this:

PHP Code:
#include <amxmodx>

new count[33][8// count[id][0] is the client's round count.

public plugin_init( )
{
    
register_clcmd("kill""cmdTest")
    
// hook new round.
}

public 
client_putinserver(id)
{
    for(new 
0sizeof(count[]); i++)
    {
        
count[id][i] = 0
    
}
}

public 
event_newround()
{
    new 
players[32], num
    get_players
(playersnum)
    
    new 
idclient_round_count
    
for(new 0numi++)
    {
        
id players[i]
        
client_round_count count[id][0]++
        
count[id][(client_round_count 7) + 1] = 0
    
}
}

public 
cmdTest(id)
{
    if(
getcount(id) < 2)  // This number is the max times you can use the command in 7 rounds.
    
{
        
// Client has not used the command the maximum number of times yet.
        
        
count[id][(count[id][0] % 7) + 1] += 1
    
}
}

getcount(id)
{
    new 
total 0
    
for(new 1sizeof(count[]); i++)
    {
        
total += count[id][i]
    }
    
    return 
total

I haven't had time to test it but I thought it out for a while.
__________________
fysiks is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 17:38.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode