InventoryTransactionEvent: rewrite documentation

This commit is contained in:
Dylan K. Taylor 2022-05-21 21:20:11 +01:00
parent 7d172e2211
commit 3ca80b353b
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D

View File

@ -29,8 +29,17 @@ use pocketmine\event\Event;
use pocketmine\inventory\transaction\InventoryTransaction;
/**
* Called when there is a transaction between two Inventory objects.
* The source of this can be a Player, entities, mobs, or even hoppers in the future!
* Called when a player performs actions involving items in inventories.
*
* This may involve multiple inventories, and may include actions such as:
* - moving items from one slot to another
* - splitting itemstacks
* - dragging itemstacks across inventory slots (slot painting)
* - dropping an item on the ground
* - taking an item from the creative inventory menu
* - destroying (trashing) an item
*
* @see https://doc.pmmp.io/en/rtfd/developer-reference/inventory-transactions.html for more information on inventory transactions
*/
class InventoryTransactionEvent extends Event implements Cancellable{
use CancellableTrait;