Skip to main content

UsingItem

Gets called when the player is using an item.

Start a script section

!-- OnEvent UsingItem
-- require @evPlayer *evUsableItem $evIsAllowed

# Add your instructions here
  • Group: PlayerEvents
  • Cancellable: Yes
  • Event data: PlayerUsingItemEventArgs

Injected variables

VariableTypeDescription
@evPlayerplayer valueGets the player using the item.
*evUsableItemreference to UsableItem objectGets the item that is being used.
$evIsAllowedbool valueWhether the event is allowed to run.