Skip to content

Preset Condition Document

TRCStudioDean edited this page May 19, 2025 · 5 revisions

Description

This is some preset conditions for the 'Conditions' option in the function, written based on BukkitAPI/Minecraft 1.16.5,so some conditions may not be effective (this feature will continue to be expanded and optimized in the future)
Preset condition only pre wraps some of the original functions in the Bukkit API. Filling in the matching parameters can return a Boolean result (true/false), which can be used for function condition filtering.

Special note

By default, all spaces in condition expressions will be removed. If the expression requires spaces, please wrap the string in double quotes "".
If the expression already contains double quotes " , you can escape it by adding a back slash \ in front to avoid recognizing the special symbol. (For example \" )
Example:

  • Hello World! -> HelloWorld!
  • Hello "The World"! -> HelloThe World!

Compass

Preset Conditions of Player

Click the condition to view details.
Basic Format: Player:[Name]:[Condition]:[Parameters]...
If only Player:[Name] is used, it is considered as "determining whether a player is online"

Condition Action
IsBlocking Check if player is blocking
IsCollidable Check if player is collidable
IsConversing Check if player is conversing
IsCustomNameVisible Check if player is custom name visible
IsDead Check if player is dead
IsFlying Check if player is flying
IsGliding Check if player is gliding
IsGlowing Check if player is glowing
IsHandRaised Check if player is hand raised
IsHealthScaled Check if player is health scaled
IsInWater Check if player is in water
IsInsideVehicle Check if player is in vehicle
IsInvisible Check if player is invisible
IsInvulnerable Check if player is invulnerable
IsOnGround Check if player is on ground
IsOp Check if player is OP
IsPlayerTimeRelative Check if player is player time relative
IsRiptiding Check if player is riptiding
IsSilent Check if player is silent
IsSleeping Check if player is sleeping
IsSleepingIgnored Check if player is sleeping ignored
IsSneaking Check if player is sneaking
IsSprinting Check if player is sprinting
IsSwimming Check if player is swimming
IsWhitelisted Check if player is whitelisted
GetAllowFlight Check if player can fly
GetCanPickupItems Check if player can pickup items
HasGravity Check if player has gravity
HasPlayedBefore Check if player has played before
CanSee Check if player can see a certain player
HasCooldown Check if player has cooldown on the specified item
HasMetadata Check if player has meta data
HasPermission Check if player has permission

Preset Conditions of World

Click the condition to view details.
Basic Format: World:[Name]:[Condition]:[Parameters]...
If only World:[Name] is used, it is considered as "determining whether a world is exist"

Condition Action
GetAllowAnimals Check if the world allow animals
GetAllowMonsters Check if the world allow monsters
GetKeepSpawnInMemory Check if the world keep spawn in memory
GetPvP Check if the world can PvP
CanGenerateStructures Check if the world can generate structures
HasMetadata Check if the world has meta data
HasStorm Check if the world has storm
IsAutoSave Check if the world is auto save
IsChunkForceLoaded Check if the world is chunk force loaded
IsChunkGenerated Check if the world is chunk generated
IsChunkLoaded Check if the world is chunk loaded
IsClearWeather Check if the world is clear weather
IsGameRule Check if the world's GameRule is valid
IsHardcore Check if the world is hardcore
IsThundering Check if the world is thundering

Preset Conditions of Server

Click the condition to view details.
Basic Format: Server:[Condition]:[Parameters]...

Condition Action
GetAllowEnd Check if this server allows the End or not
GetAllowNether Check if this server allows the Nether or not
GetAllowFlight Check if this server allows flying or not
GetGenerateStructures Check if the server has enabled generate structures
GetOnlineMode Check if the Server is in online mode or not
HasWhitelist Check if this server has a whitelist or not
IsHardcore Check if the server is in hardcore mode or not
PluginManager Conditions that provided by PluginManager

IsBlocking

  • Action: Check if the player is currently blocking (ie with a shield).
  • Format: Player:[Name]:IsBlocking
  • Example: 'Player:Steve:IsBlocking'

IsCollidable

  • Action: Gets if this player is subject to collisions with other entities.
  • Format: Player:[Name]:IsCollidable
  • Example: 'Player:Steve:IsCollidable'

IsConversing

  • Action: Tests to see of a Conversable object is actively engaged in a conversation.
  • Format: Player:[Name]:IsConversing
  • Example: 'Player:Steve:IsConversing'

IsCustomNameVisible

  • Action: Check if or not the mob's custom name is displayed client side.
  • Format: Player:[Name]:IsCustomNameVisible
  • Example: 'Player:Steve:IsCustomNameVisible'

IsDead

  • Action: Returns true if this player has been marked for removal.
  • Format: Player:[Name]:IsDead
  • Example: 'Player:Steve:IsDead'

IsFlying

  • Action: Checks to see if this player is currently flying or not.
  • Format: Player:[Name]:IsFlying
  • Example: 'Player:Steve:IsFlying'

IsGliding

  • Action: Checks to see if player is gliding, such as using an Elytra.
  • Format: Player:[Name]:IsGliding
  • Example: 'Player:Steve:IsGliding'

IsGlowing

  • Action: Check if player is glowing or not. nb: this refers to the 'Glowing' entity property, not whether a glowing potion effect is applied
  • Format: Player:[Name]:IsGlowing
  • Example: 'Player:Steve:IsGlowing'

IsHandRaised

  • Action: Check if the player currently has their hand raised (ie about to begin blocking).
  • Format: Player:[Name]:IsHandRaised
  • Example: 'Player:Steve:IsHandRaised'

IsHealthScaled

  • Action: Gets if the client is displayed a 'scaled' health
  • Format: Player:[Name]:IsHealthScaled
  • Example: 'Player:Steve:IsHealthScaled'

IsInWater

  • Action: Gets if the player is in water
  • Format: Player:[Name]:IsInWater
  • Example: 'Player:Steve:IsInWater'

IsInsideVehicle

  • Action: Returns whether this player is inside a vehicle.
  • Format: Player:[Name]:IsInsideVehicle
  • Example: 'Player:Steve:IsInsideVehicle'

IsInvisible

  • Action: Returns whether this player is invisible
  • Format: Player:[Name]:IsInvisible
  • Example: 'Player:Steve:IsInvisible'

IsInvulnerable

  • Action: Returns whether this player is invulnerable
  • Format: Player:[Name]:IsInvulnerable
  • Example: 'Player:Steve:IsInvulnerable'

IsOnGround

  • Action: Returns true if player is supported by a block. This value is a state updated by the server and is not recalculated unless the entity moves
  • Format: Player:[Name]:IsOnGround
  • Example: 'Player:Steve:IsOnGround'

IsOp

  • Action: Returns whether this player is OP
  • Format: Player:[Name]:IsOp
  • Example: 'Player:Steve:IsOp'

IsPlayerTimeRelative

  • Action: Returns true if the player's time is relative to the server time, otherwise the player's time is absolute and will not change its current time unless done so with SetPlayerTime (Player function)
  • Format: Player:[Name]:IsPlayerTimeRelative
  • Example: 'Player:Steve:IsPlayerTimeRelative'

IsRiptiding

  • Action: Checks to see if player is currently using the Riptide enchantment.
  • Format: Player:[Name]:IsRiptiding
  • Example: 'Player:Steve:IsRiptiding'

IsSilent

  • Action: Check if player is silent or not.
  • Format: Player:[Name]:IsSilent
  • Example: 'Player:Steve:IsSilent'

IsSleeping

  • Action: Returns whether this player is slumbering.
  • Format: Player:[Name]:IsSleeping
  • Example: 'Player:Steve:IsSleeping'

IsSleepingIgnored

  • Action: Returns whether the player is sleeping ignored.
  • Format: Player:[Name]:IsSleepingIgnored
  • Example: 'Player:Steve:IsSleepingIgnored'

IsSneaking

  • Action: Returns if the player is in sneak mode
  • Format: Player:[Name]:IsSneaking
  • Example: 'Player:Steve:IsSneaking'

IsSprinting

  • Action: Check if the player is sprinting or not.
  • Format: Player:[Name]:IsSprinting
  • Example: 'Player:Steve:IsSprinting'

IsSwimming

  • Action: Checks to see if player is swimming.
  • Format: Player:[Name]:IsSwimming
  • Example: 'Player:Steve:IsSwimming'

IsWhitelisted

  • Action: Checks if this player is whitelisted or not
  • Format: Player:[Name]:IsWhitelisted
  • Example: 'Player:Steve:IsWhitelisted'

GetAllowFlight

  • Action: Determines if the Player is allowed to fly via jump key double-tap like in creative mode.
  • Format: Player:[Name]:GetAllowFlight
  • Example: 'Player:Steve:GetAllowFlight'

GetCanPickupItems

  • Action: Gets if the living entity can pick up items.
  • Format: Player:[Name]:GetCanPickupItems
  • Example: 'Player:Steve:GetCanPickupItems'

HasGravity

  • Action: Returns whether gravity applies to this player.
  • Format: Player:[Name]:HasGravity
  • Example: 'Player:Steve:HasGravity'

HasPlayedBefore

  • Action: Checks if this player has played on this server before.
  • Format: Player:[Name]:HasPlayedBefore
  • Example: 'Player:Steve:HasPlayedBefore'

CanSee

  • Action: Checks to see if a player has been hidden from this player
  • Format: Player:[Name]:CanSee:[Target]
  • Example: 'Player:Steve:CanSee:Alex' #Determine if Steve can see Alex

HasCooldown

  • Action: Check whether a cooldown is active on the specified material.
  • Format: Player:[Name]:HasCooldown:[Item]
  • Example: 'Player:Steve:HasCooldown:ENDER_PEARL'

HasMetadata

  • Action: Tests to see whether the implementing object contains the given metadata value in its metadata store.
  • Format: Player:[Name]:HasMetadata:[Value]
  • Example: 'Player:Steve:HasMetadata:EXAMPLE'

HasPermission

  • Action: Gets the value of the specified permission, if set.
  • Format: Player:[Name]:HasPermission:[Permission]
  • Example: 'Player:Steve:HasPermission:litecommandeditor.example'

GetAllowAnimals

  • Action: Check if animals can spawn in this world.
  • Format: World:[Name]:GetAllowAnimals
  • Example: 'World:world:GetAllowAnimals'

GetAllowMonsters

  • Action: Check if monsters can spawn in this world.
  • Format: World:[Name]:GetAllowMonsters
  • Example: 'World:world:GetAllowMonsters'

GetKeepSpawnInMemory

  • Action: Check if the world's spawn area should be kept loaded into memory or not.
  • Format: World:[Name]:GetKeepSpawnInMemory
  • Example: 'World:world:GetKeepSpawnInMemory'

GetPvP

  • Action: Gets the current PVP setting for this world.
  • Format: World:[Name]:GetPvP
  • Example: 'World:world:GetPvP'

CanGenerateStructures

  • Action: Check if or not structures are being generated.
  • Format: World:[Name]:CanGenerateStructures
  • Example: 'World:world:CanGenerateStructures'

HasMetadata

  • Action: Tests to see whether the implementing object contains the given metadata value in its metadata store.
  • Format: World:[Name]:HasMetadata:[Value]
  • Example: 'World:world:HasMetadata:EXAMPLE'

HasStorm

  • Action: Returns whether the world has an ongoing storm.
  • Format: World:[Name]:HasStorm
  • Example: 'World:world:HasStorm'

IsAutoSave

  • Action: Check if or not the world will automatically save
  • Format: World:[Name]:IsAutoSave
  • Example: 'World:world:IsAutoSave'

IsChunkForceLoaded

  • Action: Check if the chunk at the specified chunk coordinates is force loaded.
  • Format: World:[Name]:IsChunkForceLoaded:[X]:[Z]
  • Example: 'World:world:IsChunkForceLoaded:0:0'

IsChunkGenerated

  • Action: Checks if the Chunk at the specified coordinates is generated
  • Format: World:[Name]:IsChunkGenerated:[X]:[Z]
  • Example: 'World:world:IsChunkGenerated:0:0'

IsChunkLoaded

  • Action: Checks if the Chunk at the specified coordinates is loaded
  • Format: World:[Name]:IsChunkLoaded:[X]:[Z]
  • Example: 'World:world:IsChunkLoaded:0:0'

IsClearWeather

  • Action: Checks if the world is clear weather
  • Format: World:[Name]:IsClearWeather
  • Example: 'World:world:IsClearWeather'

IsGameRule

  • Action: Checks if string is a valid game rule
  • Format: World:[Name]:IsGameRule:[GameRule]
  • Tips: Use the command to view a list of game rules: /lce tools listNames gamerule
  • Example: 'World:world:IsGameRule:KEEP_INVENTORY'

IsHardcore

  • Action: Check if the world is hardcore or not. In a hardcore world the difficulty is locked to hard.
  • Format: World:[Name]:IsHardcore
  • Example: 'World:world:IsHardcore'

IsThundering

  • Action: Returns whether there is thunder.
  • Format: World:[Name]:IsThundering
  • Example: 'World:world:IsThundering'

GetAllowEnd

  • Action: Check if this server allows the End or not.
  • Format: Server:GetAllowEnd (No params)

GetAllowNether

  • Action: Check if this server allows the Nether or not.
  • Format: Server:GetAllowNether (No params)

GetAllowFlight

  • Action: Check if this server allows flying or not.
  • Format: Server:GetAllowFlight (No params)

GetGenerateStructures

  • Action: Check if the server has enabled generate structures
  • Format: Server:GetGenerateStructures (No params)

GetOnlineMode

  • Action: Check if the Server is in online mode or not.
  • Format: Server:GetOnlineMode (No params)

HasWhitelist

  • Action: Check if this server has a whitelist or not.
  • Format: Server:HasWhitelist (No params)

IsHardcore

  • Action: Check if the server is in hardcore mode or not.
  • Format: Server:IsHardcore (No params)

PluginManager

  • Action: Conditions that provided by PluginManager
  • Format: Server:PluginManager:[Condition]
    Condition Action Format
    IsPluginEnabled Checks if the given plugin is enabled or not 'PluginManager:IsPluginEnabled:[PluginName]'
  • Example: 'PluginManager:IsPluginEnabled:LiteCommandEditor' #Check if LiteCommandEditor is enabled or not

Clone this wiki locally