pmmp / PocketMine-MP

A server software for Minecraft: Bedrock Edition in PHP
https://pmmp.io
GNU Lesser General Public License v3.0
3.27k stars 1.54k forks source link

Player Experience #5270

Closed Amzy7 closed 2 years ago

Amzy7 commented 2 years ago

Issue description

Steps to reproduce the issue

  1. ...
  2. ...

OS and versions

Plugins

It's in my core so I honestly have no clue. My guess is yes.

public function onItemUse(PlayerItemUseEvent $event): void{

    $player = $event->getPlayer();
    $item = $player->getInventory()->getItemInHand();

    if($item->getNamedTag()->getTag("XpBottle") !== null){

    $xp = $item->getNamedTag()->getInt("XpAmount");

    $player->getXpManager()->addXp($xp);

} }

Crashdump, backtrace or other files

There is no crash error.

(Sorry if I haven't provided enough information on this)

github-actions[bot] commented 2 years ago

Hi, we only accept bug reports on this issue tracker, but this issue looks like a support request.

Instead of creating an issue, try the following:

Docs | Discord | Forums