Closed xodamcm closed 2 years ago
PocketMine-MP Crash Dump Sat Jun 11 20:34:23 UTC 2022
PocketMine-MP version: 4.5.1 [Protocol 527] Git commit: d641812c52ef278e714e9d72c5277733b0b2fda9 PHP version: 8.0.17 OS: Linux, linux
A PLUGIN WAS INVOLVED IN THIS CRASH BAD PLUGIN: VanillaX
Error: Value -1 is outside the range 0 - 24791 File: pmsrc/src/entity/Attribute Line: 151 Type: InvalidArgumentException Backtrace:
Code: [142] return $this->currentValue; [143] } [144] [145] /* [146] @return $this [147] */ [148] public function setValue(float $value, bool $fit = false, bool $forceSend = false){ [149] if($value > $this->getMaxValue() || $value < $this->getMinValue()){ [150] if(!$fit){ [151] throw new \InvalidArgumentException("Value $value is outside the range " . $this->getMinValue() . " - " . $this->getMaxValue()); [152] } [153] $value = min(max($value, $this->getMinValue()), $this->getMaxValue()); [154] } [155] [156] if($this->currentValue != $value){ [157] $this->desynchronized = true; [158] $this->currentValue = $value; [159] }elseif($forceSend){ [160] $this->desynchronized = true; [161] }
And also enchantment doesn’t work https://youtu.be/afa4oqjIw2o
plugin loaded (1): VanillaX
duplicate #180
PocketMine-MP Crash Dump Sat Jun 11 20:34:23 UTC 2022
PocketMine-MP version: 4.5.1 [Protocol 527] Git commit: d641812c52ef278e714e9d72c5277733b0b2fda9 PHP version: 8.0.17 OS: Linux, linux
A PLUGIN WAS INVOLVED IN THIS CRASH BAD PLUGIN: VanillaX
Error: Value -1 is outside the range 0 - 24791 File: pmsrc/src/entity/Attribute Line: 151 Type: InvalidArgumentException Backtrace:
0 pmsrc/src/entity/ExperienceManager(194): pocketmine\entity\Attribute->setValue(float -1)
1 pmsrc/src/entity/ExperienceManager(74): pocketmine\entity\ExperienceManager->setXpAndProgress(int -1, null)
2 plugins/VanillaX_v3.0.0.phar/src/CLADevs/VanillaX/inventories/types/EnchantInventory(24): pocketmine\entity\ExperienceManager->setXpLevel(int -1)
3 plugins/VanillaX_v3.0.0.phar/src/CLADevs/VanillaX/listeners/types/PacketListener(37): CLADevs\VanillaX\inventories\types\EnchantInventory->handlePacket(object pocketmine\player\Player#190165, object pocketmine\network\mcpe\protocol\ActorEventPacket#328292)
4 pmsrc/src/event/RegisteredListener(60): CLADevs\VanillaX\listeners\types\PacketListener->onDataPacketReceive(object pocketmine\event\server\DataPacketReceiveEvent#201032)
5 pmsrc/src/event/Event(62): pocketmine\event\RegisteredListener->callEvent(object pocketmine\event\server\DataPacketReceiveEvent#201032)
6 pmsrc/src/network/mcpe/NetworkSession(387): pocketmine\event\Event->call()
7 pmsrc/src/network/mcpe/NetworkSession(351): pocketmine\network\mcpe\NetworkSession->handleDataPacket(object pocketmine\network\mcpe\protocol\ActorEventPacket#328292, string[5] ..>".)
8 pmsrc/src/network/mcpe/raklib/RakLibInterface(182): pocketmine\network\mcpe\NetworkSession->handleEncoded(string[21] .W.d....g&....*=.N...)
9 pmsrc/vendor/pocketmine/raklib-ipc/src/RakLibToUserThreadMessageReceiver(42): pocketmine\network\mcpe\raklib\RakLibInterface->onPacketReceive(int 15, string[30] .._...y/.m..1....^...u?|,...V.)
10 pmsrc/src/network/mcpe/raklib/RakLibInterface(112): raklib\server\ipc\RakLibToUserThreadMessageReceiver->handle(object pocketmine\network\mcpe\raklib\RakLibInterface#134418)
11 pmsrc/vendor/pocketmine/snooze/src/SleeperHandler(123): pocketmine\network\mcpe\raklib\RakLibInterface->pocketmine\network\mcpe\raklib{closure}()
12 pmsrc/vendor/pocketmine/snooze/src/SleeperHandler(82): pocketmine\snooze\SleeperHandler->processNotifications()
13 pmsrc/src/Server(1703): pocketmine\snooze\SleeperHandler->sleepUntil(float 1654979663.3963)
14 pmsrc/src/Server(1063): pocketmine\Server->tickProcessor()
15 pmsrc/src/PocketMine(304): pocketmine\Server->__construct(object BaseClassLoader#2, object pocketmine\utils\MainLogger#3, string[16] /home/container/, string[24] /home/container/plugins/)
16 pmsrc/src/PocketMine(327): pocketmine\server()
17 pmsrc(11): require(string[60] phar:///home/container/PocketMine-MP.phar/src/PocketMine.php)
Code: [142] return $this->currentValue; [143] } [144] [145] /* [146] @return $this [147] */ [148] public function setValue(float $value, bool $fit = false, bool $forceSend = false){ [149] if($value > $this->getMaxValue() || $value < $this->getMinValue()){ [150] if(!$fit){ [151] throw new \InvalidArgumentException("Value $value is outside the range " . $this->getMinValue() . " - " . $this->getMaxValue()); [152] } [153] $value = min(max($value, $this->getMinValue()), $this->getMaxValue()); [154] } [155] [156] if($this->currentValue != $value){ [157] $this->desynchronized = true; [158] $this->currentValue = $value; [159] }elseif($forceSend){ [160] $this->desynchronized = true; [161] }