Skip to main content

in_specific_dimension_fact

Check if player is in a specific dimension — misc entry.

Entry Information

PropertyValue
Entry IDin_specific_dimension_fact
TypeMisc
ColorBlue
Iconmdi:earth-arrow-right

Description

Fact entry to check if a player is currently in a temporary dimension. Returns 1 if in any temporary dimension, 0 otherwise. / @Entry("in_temporary_dimension_fact", "Check if player is in a temporary dimension", Colors.BLUE, "mdi:earth-box") class InTemporaryDimensionFactEntry( override val id: String = "", override val name: String = "", @MultiLine @Help("A comment to keep track of what this fact is used for.") override val comment: String = "", @Help("If left empty, every player has its own group.") override val group: Ref<GroupEntry> = emptyRef(), ) : ReadableFactEntry { override fun readSinglePlayer(player: Player): FactData { val instance = TemporaryDimensionRegistry.findPlayerInstance(player.uniqueId) return FactData(if (instance != null) 1 else 0) } } /** Fact entry to check if a player is in a specific temporary dimension. Returns 1 if in the specified dimension, 0 otherwise.

Fields

FieldTypeDescription
commentStringA comment to keep track of what this fact is used for.
groupRef<GroupEntry>If left empty, every player has its own group.
dimensionRef<TemporaryDimensionEntry>The temporary dimension to check

Usage Example

- entry: in_specific_dimension_fact
name: "Check if player is in a specific dimension"
comment: ""
group: ""
dimension: ""