1. The forums will be archived and moved to a read only mode in about 2 weeks (mid march).

Solved Floatings Text Plugin

Discussion in 'Plugin Help' started by ced23, Oct 27, 2018.

  1. ced23

    ced23 Spider Jockey

    Messages:
    30
    GitHub:
    Ced2300
    Hello, does anyone know how to fix this error?

    Link:
    https://github.com/Ad5001/FloatingTexts/tree/f18ee6266cca30d6f5151a4eea9351ecd57f486b


    Erreur:
    Code:
    [19:22:56] [Server thread/CRITICAL]: Error: "Call to undefined method pocketmine\Server::getScheduler()" (EXCEPTION) in "FloatingTexts-master/src/Ad5001/FloatingTexts/Main" at line 22
    [19:22:56] [Server thread/DEBUG]: #0 src/pocketmine/plugin/PluginBase(108): Ad5001\FloatingTexts\Main->onEnable()
    [19:22:56] [Server thread/DEBUG]: #1 src/pocketmine/plugin/PluginManager(566): pocketmine\plugin\PluginBase->setEnabled(boolean 1)
    [19:22:56] [Server thread/DEBUG]: #2 src/pocketmine/Server(1918): pocketmine\plugin\PluginManager->enablePlugin(Ad5001\FloatingTexts\Main object)
    [19:22:56] [Server thread/DEBUG]: #3 src/pocketmine/Server(1904): pocketmine\Server->enablePlugin(Ad5001\FloatingTexts\Main object)
    [19:22:56] [Server thread/DEBUG]: #4 src/pocketmine/Server(1698): pocketmine\Server->enablePlugins(integer 1)
    [19:22:56] [Server thread/DEBUG]: #5 src/pocketmine/PocketMine(249): pocketmine\Server->__construct(BaseClassLoader object, pocketmine\utils\MainLogger object, string C:\Users\cedric PC\Desktop\PocketMine\PocketMine-MP\, string C:\Users\cedric PC\Desktop\PocketMine\PocketMine-MP\plugins\)
    [19:22:56] [Server thread/DEBUG]: #6 C:/Users/cedric PC/Desktop/PocketMine/PocketMine-MP/PocketMine-MP.phar(1): require(string phar://C:/Users/cedric PC/Desktop/PocketMine/PocketMine-MP/PocketMine-MP.phar/src/pocketmine/PocketMine.php)
     
  2. corytortoise

    corytortoise Skeleton

    Messages:
    825
    GitHub:
    corytortoise
    First of all, bolding your text doesn't make it easier to read. Second, your plugin is outdated. It's trying to use the outdated method $this->getServer()->getScheduler()... Basically, just don't get the server object, and instead get the scheduler directly from the PluginBase. I'm fairly sure that the plugin will have several other problems in addition to this one.
     
  3. XenialDan

    XenialDan Baby Zombie

    Messages:
    141
    GitHub:
    thebigsmilexd
  4. Enrico Angelon

    Enrico Angelon Spider Jockey

    Messages:
    37
    GitHub:
    herryyt
    use :
    PHP:
    $this->getScheduler()
    after the new update the method changed.. this should work!
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.