Skip to main content

EnteringHazard

Gets called when player is entering any environmental hazard.

Start a script section

!-- OnEvent EnteringHazard
-- require @evPlayer *evHazard $evIsAllowed

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

Injected variables

VariableTypeDescription
@evPlayerplayer valueThe player which is entering the hazard.
*evHazardreference to Hazard objectThe target hazard.
$evIsAllowedbool valueGets or sets whether the event is allowed. Not allowing this event will cause the player to not be affected by the hazard.