Commands/fog

Used for managing active fogs for players.

Usage
Fogs pushed by this command are stored in each player's NBT data in a data structure similar to stack.

In this data structure, each element is in the format of. Multiple elements can share a same fogID or userProvidedId. Duplicate elements are valid.

To push a new element into it, both fogID and userProvidedId are required. To pop a element, userProvidedId is required. It searches from the top (newest) of the "stack", the first element with the specific userProvidedId is popped. All elememts with a specific userProvidedId can be removed together with  mode. If you forget the userProvidedId of an element, then the only way to remove the elememt is editing the player's NBT via an NBT editor.

When rendering, all fogs in this are applied one by one from the bottom (oldest) to the top (newest) of this "stack". The effects (e.g. air, weather, water, lava, lava_resistance, powder_snow, etc.) defined in the later fog overrides the earlier's. Each effect type works independently.

Vanilla fogs (biome fog, powder snow fog, etc) are applied before all fogs in this "stack".

Syntax

 * Pushes a fog into the fog "stack" of targeted players.
 * Pops a fog from the fog "stack", or removes all the fogs with the specified userProvidedId from the "stack" of targeted players.
 * Pops a fog from the fog "stack", or removes all the fogs with the specified userProvidedId from the "stack" of targeted players.
 * Pops a fog from the fog "stack", or removes all the fogs with the specified userProvidedId from the "stack" of targeted players.

Arguments

 * Specifies the player(s) to be targeted.
 * And it should be of player type.


 * Specifies a fog.
 * Should be in a fog setting name defined under the Json path  in the /fogs/.json file).


 * Specifies whether to pop or remove the fog "stack".
 * Must be one of  and.


 * Specified the userProvidedId.

Vanilla Fog Setting IDs
Here are all the fog setting IDs that are currently in the vanilla game.



History
Befehl/fog 命令/fog Команды консоли/fog