GenisysPro  for Minecraft PE/Windows 10 v1.1.x
Feature-rich server software for Minecraft PE and Windows 10 Edition
EntityInventoryChangeEvent Class Reference

Public Member Functions

 __construct (Entity $entity, Item $oldItem, Item $newItem, $slot)
 
 getSlot ()
 
 getNewItem ()
 
 setNewItem (Item $item)
 
 getOldItem ()
 
- Public Member Functions inherited from EntityEvent
 getEntity ()
 
- Public Member Functions inherited from Event
 getEventName ()
 
 getHandlers ()
 
- Public Member Functions inherited from Cancellable
 isCancelled ()
 
 setCancelled ($forceCancel=false)
 

Static Public Attributes

static $handlerList = null
 

Additional Inherited Members

- Protected Attributes inherited from EntityEvent
 $entity
 
- Protected Attributes inherited from Event
 $eventName = null
 

Constructor & Destructor Documentation

◆ __construct()

__construct ( Entity  $entity,
Item  $oldItem,
Item  $newItem,
  $slot 
)

EntityInventoryChangeEvent constructor.

Parameters
Entity$entity
Item$oldItem
Item$newItem
$slot
43  {
44  $this->entity = $entity;
45  $this->oldItem = $oldItem;
46  $this->newItem = $newItem;
47  $this->slot = (int) $slot;
48  }

Member Function Documentation

◆ getNewItem()

getNewItem ( )
Returns
Item
60  {
61  return $this->newItem;
62  }

◆ getOldItem()

getOldItem ( )
Returns
Item
74  {
75  return $this->oldItem;
76  }

◆ getSlot()

getSlot ( )
Returns
int
53  {
54  return $this->slot;
55  }

◆ setNewItem()

setNewItem ( Item  $item)
Parameters
Item$item
67  {
68  $this->newItem = $item;
69  }

Field Documentation

◆ $handlerList

$handlerList = null
static

The documentation for this class was generated from the following file: