diff --git a/LiveSigns/src/aliuly/livesigns/common/PluginCallbackTask.php b/LiveSigns/src/aliuly/livesigns/common/PluginCallbackTask.php new file mode 100644 index 0000000..a1d2a94 --- /dev/null +++ b/LiveSigns/src/aliuly/livesigns/common/PluginCallbackTask.php @@ -0,0 +1,52 @@ +callable = $callable; + $this->args = $args; + $this->args[] = $this; + } + /** + * @return callable + */ + public function getCallable(){ + return $this->callable; + } + + public function onRun($currentTicks){ + $c = $this->callable; + $args = $this->args; + $args[] = $currentTicks; + $c(...$args); + } + +}