menu
#3069278 Call to undefined method revivalpmmp\pureentities\entity\monster\walking\Witch::getInventory()

Submitted by PocketMine-MP 3.9.7

General information

Version: 3.9.7
Git commit: 0c91d568
Plugin involvement: Direct
Report date: 2019-11-06 10:22:00 +0000 UTC

System Information

PHP version: 7.3.7
Operating system: linux
System banner: Linux 9f3774c689e8 4.4.0-150-generic #176-Ubuntu SMP Wed May 29 18:56:26 UTC 2019 x86_64

Error information

Warning: the AdminTroll plugin was directly involved in this crash. Please contact the plugin author.
Message: Call to undefined method revivalpmmp\pureentities\entity\monster\walking\Witch::getInventory()
File: plugins/AdminTroll.phar/src/Swourire/AdminTroll/Events/Events
Line: #28
Error level: Error
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
    public function __construct(Main $plugin){
$this->plugin = $plugin;
}

public function onPlayerHit(EntityDamageByEntityEvent $event){
$damager = $event->getDamager();

$player = $event->getEntity();

$item = $damager->getInventory()->getItemInHand();
if($item->getId() === ItemIds::BLAZE_ROD && $item->getCustomName() === '§l§1> §r§bReal Smiter'){
$this->plugin->functions->sendLightning($player);
}
if($item->getId() === ItemIds::STICK && $item->getCustomName() === '§l§1> §r§bFalse Smiter'){
$this->plugin->functions->sendLightning($player);
$event->setCancelled();
}
if($item->getId() === ItemIds::GLASS && $item->getCustomName() === '§l§1> §r§bTrapper'){
$this->plugin->functions->trapPlayer($player);
$event->setCancelled();
#0 src/pocketmine/plugin/MethodEventExecutor(38): Swourire\AdminTroll\Events\Events->onPlayerHit(object pocketmine\event\entity\EntityDamageByEntityEvent)
#1 src/pocketmine/plugin/RegisteredListener(98): pocketmine\plugin\MethodEventExecutor->execute(object Swourire\AdminTroll\Events\Events, object pocketmine\event\entity\EntityDamageByEntityEvent)
#2 src/pocketmine/event/Event(97): pocketmine\plugin\RegisteredListener->callEvent(object pocketmine\event\entity\EntityDamageByEntityEvent)
#3 src/pocketmine/entity/Entity(992): pocketmine\event\Event->call()
#4 src/pocketmine/entity/Living(574): pocketmine\entity\Entity->attack(object pocketmine\event\entity\EntityDamageByEntityEvent)
#5 plugins/PureEntitiesX.phar/src/revivalpmmp/pureentities/entity/monster/walking/Witch(110): pocketmine\entity\Living->attack(object pocketmine\event\entity\EntityDamageByEntityEvent)
#6 plugins/PureEntitiesX.phar/src/revivalpmmp/pureentities/entity/monster/WalkingMonster(72): revivalpmmp\pureentities\entity\monster\walking\Witch->attackEntity(object slapper\entities\SlapperHuman)
#7 plugins/PureEntitiesX.phar/src/revivalpmmp/pureentities/entity/monster/WalkingMonster(198): revivalpmmp\pureentities\entity\monster\WalkingMonster->checkAndAttackEntity(object slapper\entities\SlapperHuman)
#8 src/pocketmine/level/Level(853): revivalpmmp\pureentities\entity\monster\WalkingMonster->onUpdate(integer 2218)
#9 src/pocketmine/level/Level(786): pocketmine\level\Level->actuallyDoTick(integer 2218)
#10 src/pocketmine/Server(2446): pocketmine\level\Level->doTick(integer 2218)
#11 src/pocketmine/Server(2577): pocketmine\Server->checkTickUpdates(integer 2218, double 1573035720.7176)
#12 src/pocketmine/Server(2346): pocketmine\Server->tick()
#13 src/pocketmine/Server(2206): pocketmine\Server->tickProcessor()
#14 src/pocketmine/Server(1784): pocketmine\Server->start()
#15 src/pocketmine/PocketMine(278): pocketmine\Server->__construct(object BaseClassLoader, object pocketmine\utils\MainLogger, string[16] /aternos/server/, string[24] /aternos/server/plugins/)
#16 src/pocketmine/PocketMine(300): pocketmine\server()
#17 (1): require(string[64] phar:///aternos/server/server.phar/src/pocketmine/PocketMine.php)

Loaded Plugins

  • Show

Server Settings

  • Show