PlayerGate

PlayerGate

Blocks the player from entering this cell unless they possess a specific flag or item. An optional modal message is shown when movement is blocked, matching the conversational feel of an NPC gate.

Typical use: pair with an NPC to simulate a guard who refuses to let the player pass until a condition is met — e.g. require the player to carry a Pass before crossing a checkpoint.

Constructor

new PlayerGate()

Source:

Extends

Classes

PlayerGate

Methods

getProxiedTerrain()

Description:
  • Return the terrain being wrapped (TerrainProxy interface).

Source:
Overrides:

onEnterInternal()

Description:
  • Cancels the movement event if the player does NOT satisfy PlayerGate#testable, optionally showing a modal message first. Skips silently when the event is already cancelled.

Source: