in_specific_dimension_fact
Check if player is in a specific dimension — misc entry.
Entry Information
| Property | Value |
|---|---|
| Entry ID | in_specific_dimension_fact |
| Type | Misc |
| Color | Blue |
| Icon | mdi: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
| Field | Type | Description |
|---|---|---|
comment | String | A comment to keep track of what this fact is used for. |
group | Ref<GroupEntry> | If left empty, every player has its own group. |
dimension | Ref<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: ""