menu
#7034892 Undefined property: pocketmine\player\Player::$getLocation

Submitted by PocketMine-MP 4.5.1

General information

Version: 4.5.1
Git commit: d641812c
Plugin involvement: Direct
Report date: 2022-06-23 14:08:51 +0000 UTC
Server uptime: 0 days 0 hours 0 minutes 41 seconds

System Information

PHP version: 8.0.19
Operating system: win
System banner: Windows NT DESKTOP-9P84H7C 10.0 build 19043 (Windows 10) AMD64

Error information

Warning: the CosmeticsUI plugin was directly involved in this crash. Please contact the plugin author.
Message: Undefined property: pocketmine\player\Player::$getLocation
File: plugins/vvvvvvvvvvvvvv.phar/src/CosmeticsUI/Task/HeartParticleActivate
Line: #25
Error level: ErrorException
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
        $this->player = $player;
}

public function onRun(): void{
foreach($this->plugin->getServer()->getOnlinePlayers() as $player) {
$name = $player->getName();

$player = $this->player;
$level = $player->getWorld();
$level->addParticle(new HeartParticle(new Vector3($player->getLocation()->getFloorX(), $player->getLocation()->getFloorY() + 0.5, $player->getLocation->getFloorZ())));
$level->addParticle(new HeartParticle(new Vector3($player->getLocation()->getFloorX(), $player->getLocation()->getFloorY() + 1, $player->getLocation->getFloorZ())));
$level->addParticle(new HeartParticle(new Vector3($player->getLocation()->getFloorX(), $player->getLocation()->getFloorY() + 1.5, $player->getLocation->getFloorZ())));
$level->addParticle(new HeartParticle(new Vector3($player->getLocation()->getFloorX(), $player->getLocation()->getFloorY() + 2, $player->getLocation->getFloorZ())));
}
}
}
#0 plugins/vvvvvvvvvvvvvv.phar/src/CosmeticsUI/Task/HeartParticleActivate(25): pocketmine\errorhandler\ErrorToExceptionHandler::handle(int 2, string[58] Undefined property: pocketmine\player\Player::$getLocation, string[115] phar://C:/Users/anist/Desktop/PocketMine/plugins/vvvvvvvvvvvvvv.phar/src/Cosmeti, int 25)
#1 pmsrc/src/scheduler/TaskHandler(114): CosmeticsUI\Task\HeartParticleActivate->onRun()
#2 pmsrc/src/scheduler/TaskScheduler(141): pocketmine\scheduler\TaskHandler->run()
#3 pmsrc/src/plugin/PluginManager(498): pocketmine\scheduler\TaskScheduler->mainThreadHeartbeat(int 576)
#4 pmsrc/src/Server(1811): pocketmine\plugin\PluginManager->tickSchedulers(int 576)
#5 pmsrc/src/Server(1700): pocketmine\Server->tick()
#6 pmsrc/src/Server(1063): pocketmine\Server->tickProcessor()
#7 pmsrc/src/PocketMine(304): pocketmine\Server->__construct(object BaseClassLoader#2, object pocketmine\utils\MainLogger#3, string[34] C:\Users\anist\Desktop\PocketMine\, string[42] C:\Users\anist\Desktop\PocketMine\plugins\)
#8 pmsrc/src/PocketMine(327): pocketmine\server()
#9 pmsrc(11): require(string[78] phar://C:/Users/anist/Desktop/PocketMine/PocketMine-MP.phar/src/PocketMine.php)

Loaded Plugins

  • Show

Server Settings

  • Show

Installed PHP Extensions

  • Show