UNPKG

minecraft-bedrock-json-types

Version:

Typescript types for Minecraft Bedrock's add-on json configuration files.

235 lines (234 loc) 6.13 kB
/** * This file was automatically generated by json-schema-to-typescript. * DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file, * and run json-schema-to-typescript to regenerate this file. */ /** * A version that tells minecraft what type of data format can be expected when reading this file. */ type FormatVersion = string; /** * The identifier for these fog settings. The identifier must include a namespace. */ type Identifier = string; /** * The distance from the player that the fog will begin to appear. 'fog_start' must be less than or equal to 'fog_end'. */ type FogStart = number; /** * The distance from the player that the fog will become fully opaque. 'fog_end' must be greater than or equal to 'fog_start'. */ type FogEnd = number; /** * The color that the fog will take on. */ type FogColor = string; /** * Determines how distance value is used. Fixed distance is measured in blocks. Dynamic distance is multiplied by the current render distance. */ type RenderDistanceType = ("fixed" | "render"); /** * Additional fog data which will slowly transition to the distance fog of current biome. */ type TransitionFog = boolean; /** * The maximum amount of opaqueness that the ground fog will take on. A value from [0.0, 1.0]. */ type MaximumDensity = number; /** * The height in blocks that the ground fog will become it's maximum density. */ type MaximumDensityHeight = number; /** * The height in blocks that the ground fog will be completely transparent and begin to appear. This value needs to be at least 1 higher than `max_density_height`. */ type ZeroDensityHeight = number; /** * When set to true, the density will be uniform across all heights. */ type Uniform = boolean; /** * Proportion of light that is absorbed (lost) per block. */ type Absorption = ([] | [Red] | [Red, Green] | [Red, Green, Blue] | string); type Red = number; type Green = number; type Blue = number; /** * Proportion of light that is scattered per block. */ type Scattering = ([] | [Red] | [Red, Green] | [Red, Green, Blue] | string); /** * UNDOCUMENTED. */ export interface Fog { format_version?: FormatVersion; "minecraft:fog_settings"?: FogSettings; } /** * The definition of a single fog. */ interface FogSettings { description?: Description; distance?: Distance; volumetric?: Volumetric; } /** * The identifying description of this fog settings. */ interface Description { identifier?: Identifier; } /** * The distance fog settings for different camera locations. */ interface Distance { air?: Air; weather?: Weather; water?: Water; lava?: Lava; lava_resistance?: LavaResistance; powder_snow?: PowderSnow; } /** * The fog settings when the camera is in the air. */ interface Air { fog_start: FogStart; fog_end: FogEnd; fog_color: FogColor; render_distance_type: RenderDistanceType; transition_fog?: TransitionFog; } /** * The fog settings for when the camera is in the air with active weather (rain, snow, etc..). */ interface Weather { fog_start: FogStart; fog_end: FogEnd; fog_color: FogColor; render_distance_type: RenderDistanceType; transition_fog?: TransitionFog; } /** * The fog settings when the camera is in water. */ interface Water { fog_start: FogStart; fog_end: FogEnd; fog_color: FogColor; render_distance_type: RenderDistanceType; transition_fog?: TransitionFog; } /** * The fog settings when the camera is in lava. */ interface Lava { fog_start: FogStart; fog_end: FogEnd; fog_color: FogColor; render_distance_type: RenderDistanceType; transition_fog?: TransitionFog; } /** * The fog settings when the camera is in lava and the player has the lava resistance effect active. */ interface LavaResistance { fog_start: FogStart; fog_end: FogEnd; fog_color: FogColor; render_distance_type: RenderDistanceType; transition_fog?: TransitionFog; } /** * The fog settings when the camera is inside a Powder Snow block. */ interface PowderSnow { fog_start: FogStart; fog_end: FogEnd; fog_color: FogColor; render_distance_type: RenderDistanceType; transition_fog?: TransitionFog; } /** * The volumetric fog settings. */ interface Volumetric { density?: Density; media_coefficients?: MediaCoefficients; } /** * The density settings for different camera locations. */ interface Density { air?: Air1; water?: Water1; lava?: Lava1; lava_resistance?: LavaResistance1; } /** * Fog density values as light passes through air blocks. */ interface Air1 { max_density: MaximumDensity; max_density_height?: MaximumDensityHeight; zero_density_height?: ZeroDensityHeight; uniform?: Uniform; } /** * Fog density values as light passes through water blocks. */ interface Water1 { max_density: MaximumDensity; max_density_height?: MaximumDensityHeight; zero_density_height?: ZeroDensityHeight; uniform?: Uniform; } /** * Fog density values as light passes through lava blocks. */ interface Lava1 { max_density: MaximumDensity; max_density_height?: MaximumDensityHeight; zero_density_height?: ZeroDensityHeight; uniform?: Uniform; } /** * Fog density values as light passes through lava blocks while the player has lava resistance. */ interface LavaResistance1 { max_density: MaximumDensity; max_density_height?: MaximumDensityHeight; zero_density_height?: ZeroDensityHeight; uniform?: Uniform; } /** * The coefficient settings for the volumetric fog in different blocks. */ interface MediaCoefficients { air?: Air2; water?: Water2; cloud?: Cloud; } /** * Fog coefficient values while light passes through air. */ interface Air2 { absorption?: Absorption; scattering?: Scattering; } /** * Fog coefficient values while light passes through water. */ interface Water2 { absorption?: Absorption; scattering?: Scattering; } /** * Fog coefficient values while light passes through clouds. */ interface Cloud { absorption?: Absorption; scattering?: Scattering; } export {};