mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-21 08:17:34 +00:00
DropItemAction: Consider invalid if the target item is null
it's not possible to drop a null item.
This commit is contained in:
parent
7ad0aa56b1
commit
70635d0870
@ -38,7 +38,7 @@ class DropItemAction extends InventoryAction{
|
||||
}
|
||||
|
||||
public function isValid(Player $source) : bool{
|
||||
return true;
|
||||
return !$this->targetItem->isNull();
|
||||
}
|
||||
|
||||
public function onPreExecute(Player $source) : bool{
|
||||
|
Loading…
x
Reference in New Issue
Block a user