Raised This Month: $51 Target: $400
 12% 

Little Help Learning


Post New Thread Reply   
 
Thread Tools Display Modes
Ezekiel
Member
Join Date: Mar 2004
Old 03-20-2004 , 09:48  
Reply With Quote #11

Code:
forward client_putinserver(id);
Ezekiel is offline
IceMouse[WrG]
Senior Member
Join Date: Mar 2004
Old 03-20-2004 , 09:52  
Reply With Quote #12

Here are all of your functions:
Code:
public plugin_init() { 
   register_plugin("Low Skill Kicker","1.0","Ezekiel") 
   return PLUGIN_CONTINUE 
}
Code:
public client_disconnect(id) { 
   remove_task(id) 
   return PLUGIN_CONTINUE 
}
Code:
kickPlayer(id) { 
   new name[32] 
   get_user_name(id, name, 31) 
   new uID = get_user_userid(id) 
   server_cmd("banid %d #%d", BANTIME, uID) 
   client_cmd(id, "echo ^"Sorry but you don't have a high enough score^"; disconnect") 
   client_print(0, print_chat, "%s was disconnected due to being shite!", name) 
   return PLUGIN_CONTINUE 
}
Not public BTW
Code:
public checkScore(param[]) 
{ 
   new id = param[0] 
   if ((get_user_flags(id) & ADMIN_RESERVATION)) { 
      remove_task(id) 
      client_print(id, print_chat, "Score checking disabled due to immunity...you'd best not be shite! ") 
      return PLUGIN_CONTINUE 
   } 

   new PLAYERS = get_playersnum() 
   if ( PLAYERS >= MINPLAYERS) { 
      new FRAGS = get_user_frags(id) 
      new DEATHS = get_user_deaths(id) 
      new KD = FRAGS - DEATHS 
      if (KD <= RATIO) 
      { 
         kickPlayer(id) 
         return PLUGIN_CONTINUE 
      } 
      else { 
         return PLUGIN_CONTINUE 
      } 
   } 
   else { 
      return PLUGIN_CONTINUE 
   } 
   return PLUGIN_CONTINUE 
}
There is no
Code:
public client_putinserver()
Or
Code:
public client_connect()
IceMouse[WrG] is offline
Send a message via AIM to IceMouse[WrG] Send a message via MSN to IceMouse[WrG] Send a message via Yahoo to IceMouse[WrG]
[RED-Designs]
Senior Member
Join Date: Mar 2004
Location: .us
Old 03-20-2004 , 09:55  
Reply With Quote #13

Please use [-small-] tags(without "-")

Also, as IceMouse said, you need to grab the user on connect..

Ie:
Code:
public client_putinserver(id){ }

Edit:: Just clearing up what IceMouse said seconds before I pressed "Submit"

Also, I dont see where you are starting the task. I only see it being removed.
__________________
.My personal Blog
."If the country were open on its borders, new
forms would certainly immigrate, and this also
would seriously disturb the relations of some
of the former inhabitants." - Charles Darwin
[RED-Designs] is offline
Send a message via AIM to [RED-Designs] Send a message via MSN to [RED-Designs] Send a message via Yahoo to [RED-Designs]
IceMouse[WrG]
Senior Member
Join Date: Mar 2004
Old 03-20-2004 , 11:47  
Reply With Quote #14

He is going to start the task when the client connects =\
IceMouse[WrG] is offline
Send a message via AIM to IceMouse[WrG] Send a message via MSN to IceMouse[WrG] Send a message via Yahoo to IceMouse[WrG]
[RED-Designs]
Senior Member
Join Date: Mar 2004
Location: .us
Old 03-20-2004 , 14:13  
Reply With Quote #15

Quote:
Originally Posted by IceMouse[WrG
]He is going to start the task when the client connects =\
I know, but he didnt have that yet so I was reminding him
__________________
.My personal Blog
."If the country were open on its borders, new
forms would certainly immigrate, and this also
would seriously disturb the relations of some
of the former inhabitants." - Charles Darwin
[RED-Designs] is offline
Send a message via AIM to [RED-Designs] Send a message via MSN to [RED-Designs] Send a message via Yahoo to [RED-Designs]
Ezekiel
Member
Join Date: Mar 2004
Old 03-20-2004 , 16:24  
Reply With Quote #16

Code:
/* AMX Mod script * * (c) 2004, Ezekiel * This file is provided as is (no warranties). * * A plugin that will generate a value based on player kill minus player deaths * and kick if this value is below a certain value. * * Players with immunity won't be checked */ #include <amxmod> new RATIO = -5 // the number kills-deaths has to equal or be smaller than for the user to be kicked and banned new MINPLAYERS = 12 // number of players to be on server before plugin works new BANTIME = 240 // amount of time to ban people for (minutes) public plugin_init() {     register_plugin("Low Skill Kicker","1.0","Ezekiel")     return PLUGIN_CONTINUE } public client_disconnect(id) {     remove_task(id)     return PLUGIN_CONTINUE } public client_putinserver(id){     new param[1]     param[0] = id     set_task(300.0, "checkScore", id, param, 1) } kickPlayer(id) {     new name[32]     get_user_name(id, name, 31)     new uID = get_user_userid(id)     server_cmd("banid %d #%d", BANTIME, uID)     client_cmd(id, "echo ^"Sorry but you don't have a high enough score^"; disconnect")     client_print(0, print_chat, "%s was disconnected due to being shite!", name)     return PLUGIN_CONTINUE } public checkScore(param[]) {    new id = param[0]    if ((get_user_flags(id) & ADMIN_RESERVATION)) {       remove_task(id)       client_print(id, print_chat, "Score checking disabled due to immunity...you'd best not be shite! ")       return PLUGIN_CONTINUE    }    new PLAYERS = get_playersnum()    if ( PLAYERS >= MINPLAYERS) {       new FRAGS = get_user_frags(id)       new DEATHS = get_user_deaths(id)       new KD = FRAGS - DEATHS       if (KD <= RATIO)       {          kickPlayer(id)          return PLUGIN_CONTINUE       }       else {          return PLUGIN_CONTINUE       }    }    else {       return PLUGIN_CONTINUE    }    return PLUGIN_CONTINUE }

like that?
Ezekiel is offline
IceMouse[WrG]
Senior Member
Join Date: Mar 2004
Old 03-20-2004 , 18:21  
Reply With Quote #17

That will work, but might I suggest a ratio? If you have a guy who is
10394/10400, that isn't really a bad record, but he will still get kicked by your system... Do K/D(If(K/D <=.6)) instead of K-D
IceMouse[WrG] is offline
Send a message via AIM to IceMouse[WrG] Send a message via MSN to IceMouse[WrG] Send a message via Yahoo to IceMouse[WrG]
Ezekiel
Member
Join Date: Mar 2004
Old 03-20-2004 , 21:14  
Reply With Quote #18

thats a rubbish record ;P
will have a think about a ratio, i think i want to do it this way but ill make sure.
Ezekiel is offline
IceMouse[WrG]
Senior Member
Join Date: Mar 2004
Old 03-21-2004 , 00:52  
Reply With Quote #19

Its not rubbish if you look at an average CS player... If you look at it statistically, then it is 6 less kills than deaths... But if the other team has the max of 16 people, then it would take 649.625 aces... You tell me a guy who can do that(Please take into consideration of getting tired, going to the bathroom, getting a drink, going AFK)

While his K ratio is a fair 0.999423
IceMouse[WrG] is offline
Send a message via AIM to IceMouse[WrG] Send a message via MSN to IceMouse[WrG] Send a message via Yahoo to IceMouse[WrG]
Ezekiel
Member
Join Date: Mar 2004
Old 03-21-2004 , 05:37  
Reply With Quote #20

still by K : D ratio, which is how i rate scores in my head, its less than 1:1, which is poor. no ones ever gonna reach 10k kills either.
Ezekiel 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 02:32.


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