Nice plugin ;)
I guess you should replace :
Code:
isCooldown[id] = true
set_task(get_pcvar_float(cCooldown), "endCooldown", id, "", 0, "")
with something like :
Code:
g_lastshove_time[id] = get_systime()
and replace
Code:
if(isCooldown[id])
{
client_print(id, print_chat, "[Shove Mod] Your muscles are weak from shoving the player. You must wait to do it again.")
return PLUGIN_HANDLED
}
with
Code:
if( get_systime() - g_lastshove_time[id] < get_pcvar_num(cCooldown) ) {
client_print(id, print_chat, "[Shove Mod] Your muscles are weak from shoving the player. You must wait to do it again.")
return PLUGIN_HANDLED
}
Then you don't need a task.