View Single Post
Shadows Adi
AlliedModders Donor
Join Date: Aug 2019
Location: Romania
Old 01-09-2022 , 14:07   Re: set task disable
Reply With Quote #6

Quote:
Originally Posted by abdobiskra View Post
Code:
public function_check(id) {
    if(task_exists(id + 100000))
    {         client_print(id, print_chat,"Your Task is running!!");
        remove_task(id + 100000);
        return PLUGIN_HANDLED;     }     else     {         client_print(id, print_chat,"Your Task is  not running!!");         return PLUGIN_HANDLED;     }      return PLUGIN_HANDLED; }
That is wrong, because you already pass (id + 100000) value when you set task. So, if you print out (id) it will show you (id /* a integer value already*/ + 100000), you don't need to add again 100000 on those lines.
__________________


Accepting Paid Requests, contact PM.

MVP Of The Round View project on GITHUB / AlliedModders
CSGO REMAKE ~ CSGO MOD [STABLE + SOURCE CODE]
Shadows Adi is offline