Hizkaldir() is getting 1991 as the id argument and then it is erroring when passed to set_user_maxspeed(), client_print(), and doping[]. You need to add the player id to the task-id when creating the task and then subtract when using it on a player. You also do not need to call remove_task() within the called function on a task that only occurs once.
Also, add debug after your plugin in plugins.ini to get more details about the error.
Code:
set_task(20.0,"HizKaldir",1991)
...
public Hizkaldir(id){
set_user_maxspeed(id, dopingsizhiz)
client_print(id,print_chat,"[WLG]: Doping effect.")
remove_task(1991)
doping[id] = false
}
to
PHP Code:
set_task( 20.0 , "HizKaldir" , 1991 + id )
...
public Hizkaldir(id)
{
id -= 1991
set_user_maxspeed(id, dopingsizhiz)
client_print(id,print_chat,"[WLG]: Doping effect.")
//remove_task(1991)
doping[id] = false
}
//You should also add this any time you use set task on a player (except maybe when the interval is 0.1).
//Failure to do this will result in an error if a player disconnects between when set_task() is called and the 20 second interval.
public client_disconnect( id )
{
remove_task(1991 + id)
}
__________________