Skip to main content

Barrier

info

This module can only be used in Entity scripts.

Functions

block(targetObject)

Enables this barrier's collision with certain objects.

Parameters

  • targetObject Target Player, Entity, Entity Code or BarrierLayer.

unblock(targetObject)

Disables this barrier's collision with certain objects.

Parameters

  • targetObject Target Player, Entity, Entity Code or BarrierLayer.

reset()

Resets this barrier's collision. All objects will be blocked again.


isBlocked(targetObject)

Check if this barrier is blocking a specific entity type.

Parameters

  • targetObject Player, Entity, Entity Code or BarrierLayer to check.