Hi, Im trying to use Task but it doesn't work. What do you think is the problem ? Code: if($dgen1l == 1){ $this->p->getScheduler()->scheduleRepeatingTask(new Demir($this), 100); $config->set($arena . "Demir1level", 1.5); $config->save(); } Code: $task = $this->p->getScheduler()->scheduleRepeatingTask(new Demir($this), 100)->getTaskId(); var_dump($task); $this->p->getScheduler()->cancelTask($task);
You are creating a second task with the second part of code. You will need to save the first one and cancel it.