minecraft-bedrock-json-types
Version:
Typescript types for Minecraft Bedrock's add-on json configuration files.
1,757 lines • 378 kB
TypeScript
/**
* 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 name of the animation controller / animation.
*/
type AnimationController = string;
/**
* Sets the identifier for this entity's description.
*/
type Identifier = string;
/**
* Sets whether or not this entity has a spawn egg in the creative ui.
*/
type IsSpawnable = boolean;
/**
* Sets whether or not we can summon this entity using commands such as /summon.
*/
type IsSummonableProperty = boolean;
/**
* Sets whether or not this entity is experimental. Experimental entities are only enabled when the experimental toggle is enabled.
*/
type IsExperimental = boolean;
/**
* The default value of the property.
*/
type Default = (string | boolean);
/**
* The default value of the property.
*/
type Default1 = (string | number);
/**
* The range of the property.
*/
type Range = [] | [Min] | [Min, Max];
/**
* The minimum value of the property.
*/
type Min = number;
/**
* The minimum value of the property.
*/
type Max = number;
/**
* The default value of the property.
*/
type Default2 = (string | number);
/**
* The range of the property.
*/
type Range1 = [] | [Min1] | [Min1, Max1];
/**
* The minimum value of the property.
*/
type Min1 = number;
/**
* The minimum value of the property.
*/
type Max1 = number;
/**
* Sets whether or not the property is synced to the client.
*/
type ClientSync = boolean;
/**
* The values of the property.
*
* @minItems 1
*/
type Values = [string, ...(string)[]];
/**
* Sets the name for the Vanilla Minecraft identifier this entity will use to build itself from.
*/
type RuntimeIdentifier = string;
/**
* The name of an animation controller referenced in animations.
*/
type Animation = string;
type Animation1 = string;
/**
* Tells minecraft to run which animation / animation controllers and under what conditions.
*/
type Animate = (Animation | ConditionalAnimation)[];
/**
* The minimum starting health an entity has.
*/
type Minimum = number;
/**
* The maximum starting health an entity has.
*/
type Maximum = number;
/**
* The amount of health an entity to start with by default.
*/
type Value = (number | [] | [A] | [A, B] | {
range_min?: RangeMin;
range_max?: RangeMax;
});
/**
* The first value of the range.
*/
type A = number;
/**
* The second value of the range.
*/
type B = number;
/**
* The minimum value of the range.
*/
type RangeMin = number;
/**
* The maximum value of the range.
*/
type RangeMax = number;
/**
* The entity type that will be riding this entity.
*/
type EntityType = string;
/**
* The spawn event that will be used when the riding entity is created.
*/
type SpawnEvent = string;
/**
* Duration, in seconds, for which mob won't admire items if it was hurt.
*/
type CooldownAfterBeingAttacked = number;
/**
* Duration, in seconds, that the mob is pacified.
*/
type Duration = number;
/**
* List of items that the entity drops when it grows up.
*/
type DropItems = (BB[] | ((ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
}) & string));
type BB = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* A minecraft item identifier.
*/
type ItemIdentifier = string;
/**
* A minecraft item identifier.
*/
type ItemIdentifier1 = string;
/**
* [UNDOCUMENTED] A Molang expression ran against item or block to match.
*/
type Molang = string;
/**
* A minecraft item identifier.
*/
type ItemIdentifier2 = string;
/**
* Amount of time before the entity grows up, -1 for always a baby.
*/
type Duration1 = number;
/**
* List of items that can be fed to the entity. Includes `item` for the item name and `growth` to define how much time it grows up by
*/
type FeedItems = ((ItemIdentifier | {
growth?: number;
item?: BB;
[k: string]: unknown;
})[] | ItemIdentifier3);
/**
* A minecraft item identifier.
*/
type ItemIdentifier3 = string;
type Filters = (BFGroupsSpec[] | BFFiltersSpec);
type BFGroupsSpec = (BFGroupsSpec[] | BFFiltersSpec);
type BFFiltersSpec = ({
all_of?: AllOf;
any_of?: AnyOf;
none_of?: NoneOf;
[k: string]: unknown;
} | ({
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
} & {
[k: string]: unknown;
}));
/**
* All tests in an `all_of` group must pass in order for the group to pass.
*/
type AllOf = (BFGroupsSpec[] | BFFiltersSpec);
/**
* One or more tests in an `any_of` group must pass in order for the group to pass.
*/
type AnyOf = (BFGroupsSpec[] | BFFiltersSpec);
/**
* All tests in a `none_of` group must fail in order for the group to pass.
*/
type NoneOf = (BFGroupsSpec[] | BFFiltersSpec);
/**
* The event to fire.
*/
type Event = string;
/**
* The target of the event.
*/
type Target = ("baby" | "block" | "damager" | "other" | "parent" | "player" | "self" | "target");
/**
* The feed item used will transform to this item upon successful interaction. Format: itemName:auxValue
*/
type TransformToItem = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* List of conditions to meet so that the entity can be fed.
*/
type Filters1 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* Level sound event to be played as the ambient sound.
*/
type EventName = string;
/**
* The condition that must be satisfied to select the given ambient sound.
*/
type Condition = string;
/**
* Level sound event to be played as the ambient sound.
*/
type EventName1 = string;
/**
* Maximum time in seconds to randomly add to the ambient sound delay time.
*/
type Range2 = number;
/**
* Minimum time in seconds before the entity plays its ambient sound again.
*/
type Value1 = number;
/**
* Anger level will decay over time. Defines how often anger towards all nuisances will be decreased by one
*/
type AngerDecrementInterval = number;
/**
* Anger boost applied to angry threshold when mob gets angry.
*/
type AngryBoost = number;
/**
* Threshold that define when the mob is considered angry at a nuisance.
*/
type AngryThreshold = number;
/**
* The default amount of annoyingness for any given nuisance. Specifies how much to raise anger level on each provocation
*/
type DefaultAnnoyingness = number;
/**
* The default amount of annoyingness for projectile nuisance. Specifies how much to raise anger level on each provocation
*/
type DefaultProjectileAnnoyingness = number;
/**
* The maximum anger level that can be reached. Applies to any nuisance
*/
type MaximumAnger = number;
/**
* Filter that is applied to determine if a mob can be a nuisance.
*/
type Filters2 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* The event that will trigger the sound
*/
type Condition1 = string;
/**
* The sound to play
*/
type Sound = string;
type OnIncreaseSounds = {
condition: Condition1;
sound: Sound;
}[];
/**
* Defines if the mob should remove target if it falls below 'angry' threshold.
*/
type RemoveTargetsBelowAngryThreshold = boolean;
/**
* If true, other entities of the same entity definition within the broadcastRange will also become angry.
*/
type BroadcastAnger = boolean;
/**
* Conditions that make this entry in the list valid.
*/
type Filters3 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* Filter out mob types that it should not attack while angry (other Piglins).
*/
type Filters4 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* Distance in blocks within which other entities of the same entity definition will become angry.
*/
type BroadcastRange = number;
/**
* An entity family.
*/
type BroadcastTargets1 = string;
/**
* A list of entity families to broadcast anger to.
*/
type BroadcastTargets = BroadcastTargets1[];
/**
* The sound event to play when the mob is angry.
*/
type AngrySound = string;
/**
* If true, other entities of the same entity definition within the broadcastRange will also become angry whenever this mob attacks.
*/
type BroadcastAngerOnAttack = boolean;
/**
* If true, other entities of the same entity definition within the broadcastRange will also become angry whenever this mob is attacked.
*/
type BroadcastAngerOnBeingAttacked = boolean;
/**
* The amount of time in seconds that the entity will be angry.
*/
type Duration2 = number;
/**
* Variance in seconds added to the duration [-delta, delta].
*/
type DurationDelta = number;
/**
* The range of time in seconds to randomly wait before playing the sound again.
*/
type SoundInterval = ([] | [Minimum1] | [Minimum1, Maximum1] | {
range_min?: RangeMinimum;
range_max?: RangeMaximum;
});
/**
* The minimum interval.
*/
type Minimum1 = number;
/**
* The maximum interval.
*/
type Maximum1 = number;
/**
* The minimum interval.
*/
type RangeMinimum = number;
/**
* The maximum interval.
*/
type RangeMaximum = number;
/**
* The time in seconds required to break through doors.
*/
type BreakTime = number;
/**
* The minimum difficulty that the world must be on for this entity to break doors.
*/
type MinimumDifficulty = string;
/**
* The type of damage that is applied to entities that enter the damage range.
*/
type Cause = ("all" | "anvil" | "block_explosion" | "campfire" | "charging" | "contact" | "drowning" | "entity_attack" | "entity_explosion" | "fall" | "falling_block" | "fatal" | "fire" | "fire_tick" | "fireworks" | "fly_into_wall" | "freezing" | "lava" | "lightning" | "magic" | "magma" | "none" | "override" | "piston" | "projectile" | "ram_attack" | "sonic_boom" | "soul_campfire" | "stalactite" | "stalagmite" | "starve" | "suffocation" | "suicide" | "temperature" | "thorns" | "void" | "wither");
/**
* Attack cooldown (in seconds) for how often this entity can attack a target.
*/
type DamageCooldown = number;
/**
* How much damage per tick is applied to entities that enter the damage range.
*/
type DamagePerTick = number;
/**
* How close a hostile entity must be to have the damage applied.
*/
type DamageRange = number;
/**
* The set of entities that are valid to apply the damage to when within range.
*/
type Filters5 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* If the entity should play their attack sound when attacking a target.
*/
type PlayAttackSound = (PlayAttackSound1 & PlayAttackSound2);
type PlayAttackSound1 = boolean;
type PlayAttackSound2 = number;
/**
* Event to be run when the cooldown is complete.
*/
type AttackCooldownCompleteEvent = (string | Trigger | Trigger1[]);
/**
* The event to run when the conditions for this trigger are met.
*/
type Event1 = string;
/**
* The list of conditions for this trigger to execute.
*/
type Filters6 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* The subject of this filter test.
*/
type Subject = ("block" | "other" | "parent" | "player" | "self" | "target" | "damager");
/**
* Amount of time in seconds for the cooldown. Can be specified as a number or a pair of numbers (Minimum and max).
*/
type AttackCooldownTime = ([] | [Maximum2] | [Maximum2, Maximum3] | number);
type Maximum2 = number;
type Maximum3 = number;
/**
* Range of the random amount of damage the melee attack deals. A negative value can heal the entity instead of hurting it.
*/
type Damage = (number | [] | [A] | [A, B] | {
range_min?: RangeMin;
range_max?: RangeMax;
});
/**
* Identifier of the status ailment to apply to an entity attacked by this entity's melee attack.
*/
type EffectName = string;
/**
* Duration in seconds of the status ailment applied to the damaged entity.
*/
type EffectDuration = number;
/**
* Distance in blocks where the 'spring' effect lifts the entity.
*/
type SoftDistance = number;
/**
* Distance in blocks where the balloon breaks.
*/
type MaxDistance = number;
/**
* Event to call when the entity is ballooned.
*/
type OnBalloon = string;
/**
* Event to call when the entity is unballooned.
*/
type OnUnballoon = string;
/**
* Mass that the entity has when computing balloon pull forces.
*/
type Mass = number;
/**
* Loot table that's used to drop a random item.
*/
type BarterTable = string;
/**
* Duration, in seconds, for which mob won't barter items if it was hurt.
*/
type CooldownAfterBeingAttacked1 = number;
/**
* The maximum radial distance in which a specified block can be detected. The biggest radius is 32.0.
*/
type SensorRadius = number;
/**
* A minecraft block identifier.
*/
type BlockID = string;
/**
* List of blocks that will trigger the sensor.
*/
type BlockList = BlockID[];
/**
* Event to run when a block breaks.
*/
type OnBlockBroken1 = string;
/**
* Blocks that will trigger the component when broken and what event will trigger.
*/
type OnBreak = OnBlockBroken[];
/**
* List of sources that break the block to listen for. If none are specified, all block breaks will be detected.
*/
type Sources = Filters[];
/**
* Time in seconds for the boost.
*/
type Duration3 = number;
/**
* Factor by which the entity's normal speed increases. E.g. 2.0 means go twice as fast.
*/
type SpeedMultiplier = number;
/**
* This is the damage that the item will take each time it is used.
*/
type Damage1 = number;
/**
* Name of the item that can be used to boost.
*/
type Item = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* The item used to boost will become this item once it is used up.
*/
type ReplaceItem = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* List of items that can be used to boost while riding this entity.
*/
type BoostItems = {
damage?: Damage1;
item?: Item;
replace_item?: ReplaceItem;
}[];
/**
* The Maximum distance from the boss at which the boss's health bar is present on the players screen.
*/
type HudRange = number;
/**
* The name that will be displayed above the boss's health bar.
*/
type Name = string;
/**
* Whether the sky should darken in the presence of the boss.
*/
type ShouldDarkenSky = boolean;
/**
* UNDOCUMENTED.
*/
type BlockName = string;
/**
* A list of the blocks that can be broken as this entity moves around.
*/
type BreakableBlocks = BlockName[];
/**
* Time in seconds the entity can hold its breath.
*/
type TotalSupply = number;
/**
* Time in seconds between suffocation damage.
*/
type SuffocateTime = number;
/**
* Time in seconds to recover breath to maximum.
*/
type InhaleTime = number;
/**
* If true, this entity can breathe in air.
*/
type BreathesAir = boolean;
/**
* If true, this entity can breathe in water.
*/
type BreathesWater = boolean;
/**
* If true, this entity can breathe in lava.
*/
type BreathesLava = boolean;
/**
* If true, this entity can breathe in solid blocks.
*/
type BreathesSolids = boolean;
/**
* If true, this entity will have visible bubbles while in water.
*/
type GeneratesBubbles = boolean;
/**
* A minecraft block reference.
*/
type BlockReference = (BlockIdentifier | BlockReference1);
/**
* A minecraft block identifier.
*/
type BlockIdentifier = string;
/**
* A minecraft block identifier.
*/
type BlockIdentifier1 = string;
/**
* The key of property is the name of the block state/property, the value must be the same as the block properties accepted values.
*/
type StateValue = (boolean | number | string);
/**
* A condition using Molang queries that results to true/false that can be used to query for blocks with certain tags.
*/
type Molang1 = string;
/**
* List of blocks this entity can breathe in, in addition to the above.
*/
type BreatheBlocks = BlockReference[];
/**
* List of blocks this entity can't breathe in, in addition to the above.
*/
type NonBreathesBlocks = BlockReference[];
/**
* If true, entities can breed while sitting.
*/
type AllowSitting = boolean;
/**
* If true, the entities will blend their attributes in the offspring after they breed.
*/
type BlendAttributes = boolean;
/**
* Time in seconds before the Entity can breed again.
*/
type BreedCooldown = number;
/**
* The list of items that can be used to get the entity into the `love` state.
*/
type BreedItems = (BreedItem[] | ((ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
}) & string));
/**
* An item that can be used to get the entity into the `love` state.
*/
type BreedItem = (BreedItem1 & BreedItem2);
type BreedItem1 = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
type BreedItem2 = string;
/**
* The list of entity definitions that this entity can breed with.
*/
type BreedsWith = (BCDBreedsWithSpec | BCDBreedsWithSpec1[]);
/**
* The entity definition of this entity's babies.
*/
type BabyType = string;
/**
* The event to fire.
*/
type Event2 = string;
/**
* The target of the event.
*/
type Target1 = ("baby" | "block" | "damager" | "other" | "parent" | "player" | "self" | "target");
/**
* The entity definition of this entity's mate.
*/
type MateType = string;
/**
* If true, the entity will become pregnant instead of spawning a baby.
*/
type CausesPregnancy = boolean;
/**
* The percentage chance of denying the parents` variant.
*/
type Chance = number;
/**
* The inclusive maximum of the variant range.
*/
type MaximumVariant = number;
/**
* The inclusive minimum of the variant range.
*/
type MinimumVariant = number;
/**
* The list of nearby block requirements to get the entity into the `love` state.
*/
type EnvironmentRequirements = (EnvironmentRequirements1 | EnvironmentRequirements2[]);
/**
* The block types required nearby for the entity to breed.
*/
type Blocks = (BlockReference2[] | BlockReference5);
/**
* A minecraft block reference.
*/
type BlockReference2 = (BlockReference3 & BlockReference4);
type BlockReference3 = (BlockIdentifier | BlockReference1);
type BlockReference4 = string;
/**
* A minecraft block reference.
*/
type BlockReference5 = (BlockReference6 & BlockReference7);
type BlockReference6 = (BlockIdentifier | BlockReference1);
type BlockReference7 = string;
/**
* The number of the required block types nearby for the entity to breed.
*/
type Count = number;
/**
* How many blocks radius from the mob's center to search in for the required blocks. Bounded between 0 and 16.
*/
type Radius = number;
/**
* Chance that up to 16 babies will spawn between 0.0 and 1.0, where 1.0 is 100%.
*/
type ExtraBabyChance = number;
/**
* The filters to run when attempting to fall in love.
*/
type Filters7 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* The percentage chance of a mutation on the entity's color.
*/
type Color = number;
/**
* The percentage chance of a mutation on the entity's extra variant type.
*/
type ExtraVariant = number;
/**
* The percentage chance of a mutation on the entity's variant type.
*/
type Variant = number;
/**
* Strategy used for mutating variants and extra variants for offspring. Current valid alternatives are 'random' and 'none'.
*/
type MutationStrategy = string;
/**
* [EXPERIMENTAL] List of attributes that should benefit from parent centric attribute blending. For example, horses blend their health, movement, and jump_strength in their offspring.
*/
type ParentCentricAttributeBlending = unknown[];
/**
* Range used to determine random extra variant.
*/
type RandomExtraVariantMutationInterval = (RandomExtraVariantMutationInterval1 & RandomExtraVariantMutationInterval2);
type RandomExtraVariantMutationInterval1 = number;
type RandomExtraVariantMutationInterval2 = [] | [X] | [X, Y];
/**
* The X component.
*/
type X = number;
/**
* The Y component.
*/
type Y = number;
/**
* Range used to determine random variant.
*/
type RandomVariantMutationInterval = (RandomVariantMutationInterval1 & RandomVariantMutationInterval2);
type RandomVariantMutationInterval1 = number;
type RandomVariantMutationInterval2 = [] | [X] | [X, Y];
/**
* If true, the babies will be automatically tamed if its parents are.
*/
type InheritTamed = boolean;
/**
* If true, the entity needs to be at full health before it can breed.
*/
type RequireFullHealth = boolean;
/**
* If true, the entities need to be tamed first before they can breed.
*/
type RequireTame = boolean;
/**
* The feed item used will transform to this item upon successful interaction. Format: itemName:auxValue
*/
type TransformToItem1 = string;
/**
* Time in seconds before the Entity can be bribed again.
*/
type BribeCooldown = number;
/**
* An item that can be used to bribe the entity.
*/
type BribeItems1 = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* The list of items that can be used to bribe the entity.
*/
type BribeItems = BribeItems1[];
/**
* Base buoyancy used to calculate how much will a mob float.
*/
type BaseBuoyancy = number;
/**
* Applies gravity each tick. Causes more of a wave simulation, but will cause more gravity to be applied outside liquids.
*/
type ApplyGravity = boolean;
/**
* Base buoyancy used to calculate how much will a mob float.
*/
type BaseBuoyancy1 = number;
/**
* Probability for a big wave hitting the entity. Only used if `simulate_waves` is true.
*/
type BigWaveProbability = number;
/**
* Multiplier for the speed to make a big wave. Triggered depending on `big_wave_probability`.
*/
type BigWaveSpeed = number;
/**
* How much an actor will be dragged down when the Buoyancy Component is removed.
*/
type DragDownOnBuoyancyRemoved = number;
/**
* A minecraft block reference.
*/
type BlockReference8 = (BlockIdentifier | BlockReference1);
/**
* List of blocks this entity can float on. Must be a liquid block.
*/
type LiquidBlocks = BlockReference8[];
/**
* Should the movement simulate waves going through.
*/
type SimulateWaves = boolean;
/**
* Specifies if/how a mob burns in daylight.
*/
type BurnsInDaylight = (boolean | {
[k: string]: unknown;
});
/**
* Marks the entity as being able to fly, the pathfinder won't be restricted to paths where a solid block is required underneath it.
*/
type CanFly = ({} | boolean);
/**
* If true, celebration will be broadcasted to other entities in the radius.
*/
type Broadcast = boolean;
/**
* The list of conditions that target of hunt must satisfy to initiate celebration.
*/
type Filters8 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* The sound event to play when the mob is celebrating.
*/
type CelebrateSound = string;
/**
* Duration, in seconds, of celebration.
*/
type Duration4 = number;
/**
* If broadcast is enabled, specifies the radius in which it will notify other entities for celebration.
*/
type Radius1 = number;
/**
* The range of time in seconds to randomly wait before playing the sound again.
*/
type SoundInterval1 = ([] | [Maximum4] | [Maximum4, Maximum5] | number | {
range_min?: Minimum2;
range_max?: Maximum6;
});
type Maximum4 = number;
type Maximum5 = number;
/**
* Minimum.
*/
type Minimum2 = number;
/**
* Maximum.
*/
type Maximum6 = number;
/**
* Height of the collision box in blocks. A negative value will be assumed to be 0.
*/
type Height = number;
/**
* Width of the collision box in blocks. A negative value will be assumed to be 0.
*/
type Width = number;
/**
* The Palette Color value of the entity.
*/
type Value2 = number;
/**
* The second Palette Color value of the entity.
*/
type Value3 = number;
/**
* Determines if the mob will grant mobs of the same type combat buffs if they kill the target.
*/
type ApplyToFamily = boolean;
/**
* Determines if the mob will grant itself the combat buffs if it kills the target.
*/
type ApplyToSelf = boolean;
/**
* The duration in seconds of Regeneration I added to the mob.
*/
type RegenerationDuration = number;
/**
* In relation to the optimization value, determines the maximum ticks spatial update packets can be not sent.
*/
type MaximumDroppedTicks = number;
/**
* The maximum distance considered during bandwidth optimizations. Any value below the Maximum is interpolated to find optimization, and any value greater than or equal to this Maximum results in Maximum optimization.
*/
type MaximumOptimizedDistance = number;
/**
* When set to true, smaller motion packets will be sent during drop packet intervals, resulting in the same amount of packets being sent as without optimizations but with much less data being sent. This should be used when actors are travelling very quickly or teleporting to prevent visual oddities.
*/
type UseMotionPredictionHints = boolean;
/**
* Conditions that must be met for these optimization values to be used.
*/
type ConditionalValues1 = Filters[];
/**
* The object containing the conditional bandwidth optimization values.
*/
type ConditionalValues = ConditionalValue[];
/**
* In relation to the optimization value, determines the maximum ticks spatial update packets can be not sent.
*/
type MaximumDroppedTicks1 = number;
/**
* The maximum distance considered during bandwidth optimizations. Any value below the Maximum is interpolated to find optimization, and any value greater than or equal to this Maximum results in Maximum optimization.
*/
type MaximumOptimizedDistance1 = number;
/**
* When set to true, smaller motion packets will be sent during drop packet intervals, resulting in the same amount of packets being sent as without optimizations but with much less data being sent. This should be used when actors are travelling very quickly or teleporting to prevent visual oddities.
*/
type UseMotionPredictionHints1 = boolean;
/**
* Height of the hitbox in blocks. A negative value will be assumed to be 0.
*/
type Width1 = number;
/**
* Width and Depth of the hitbox in blocks. A negative value will be assumed to be 0.
*/
type Height1 = number;
/**
* The offset from the entity's anchor where the hitbox will spawn.
*/
type Pivot = [] | [X1] | [X1, Y1] | [X1, Y1, Z];
type X1 = number;
type Y1 = number;
type Z = number;
/**
* Defines a hitbox size and pivot to test against.
*/
type Hitboxes = Hitbox[];
/**
* Amount of damage caused each hurt.
*/
type DamagePerHurt = number;
/**
* Time in seconds between damage.
*/
type TimeBetweenHurt = number;
/**
* The list of triggers that fire when the environment conditions match the given filter criteria.
*/
type Triggers = (Triggers1[] | Triggers2);
/**
* Type of damage that triggers the events.
*/
type Cause1 = ("all" | "anvil" | "block_explosion" | "campfire" | "charging" | "contact" | "drowning" | "entity_attack" | "entity_explosion" | "fall" | "falling_block" | "fatal" | "fire" | "fire_tick" | "fireworks" | "fly_into_wall" | "freezing" | "lava" | "lightning" | "magic" | "magma" | "none" | "override" | "piston" | "projectile" | "ram_attack" | "sonic_boom" | "soul_campfire" | "stalactite" | "stalagmite" | "starve" | "suffocation" | "suicide" | "temperature" | "thorns" | "void" | "wither");
/**
* A modifier that adds to/removes from the base damage from the damage cause. It does not reduce damage to less than 0.
*/
type DamageModifier = number;
/**
* A multiplier that modifies the base damage from the damage cause. If deals_damage is true the multiplier can only reduce the damage the entity will take to a minimum of 1.
*/
type DamageMultiplier = number;
/**
* If true, the damage dealt to the entity will take away health from it, set to false to make the entity ignore that damage.
*/
type DealsDamage = boolean;
/**
* Specifies filters for entity definitions and events.
*/
type OnDamage = (string | Trigger | Trigger1[]);
/**
* Defines what sound to play, if any, when the on_damage filters are met.
*/
type OnDamageSoundEvent = string;
/**
* The dash cooldown in seconds.
*/
type CooldownTime = number;
/**
* Horizontal momentum of the dash.
*/
type HorizoontalMomentum = number;
/**
* Vertical momentum of the dash.
*/
type VerticalMomentum = number;
/**
* Angle in degrees.
*/
type Value4 = number;
/**
* Determines if `min_range_random_chance` is used in the standard despawn rules.
*/
type DespawnFromChance = boolean;
/**
* Maximum distance for standard despawn rules to instantly despawn the mob.
*/
type MaximumDistance = number;
/**
* Minimum distance for standard despawn rules to try to despawn the mob.
*/
type MinimumDistance = number;
/**
* Determines if the `min_range_inactivity_timer` is used in the standard despawn rules.
*/
type DespawnFromInactivity = boolean;
/**
* Determines if the mob is instantly despawned at the edge of simulation distance in the standard despawn rules.
*/
type DespawnFromSimulationEdge = boolean;
/**
* The list of conditions that must be satisfied before the Actor is despawned. If a filter is defined then standard despawn rules are ignored.
*/
type Filters9 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* The amount of time in seconds that the mob must be inactive.
*/
type MinimumRangeInactivityTimer = number;
/**
* A random chance between 1 and the given value.
*/
type MinimumRangeRandomChance = number;
/**
* If true, all entities linked to this entity in a child relationship (eg. leashed) will also be despawned.
*/
type RemoveChildEntities = boolean;
/**
* Amount of time in seconds to dry out fully.
*/
type TotalTime = number;
/**
* Optional amount of additional time in seconds given by using splash water bottle on entity.
*/
type WaterBottleRefillTime = number;
/**
* The type of dwelling the mob wishes to join. Current Types: village
*/
type DwellingType = "village";
/**
* The role of which the mob plays in the dwelling. Current Roles: inhabitant, defender, hostile, passive.
*/
type DwellingRole = ("inhabitant" | "defender" | "hostile" | "passive");
/**
* How often the mob checks on their dwelling status in ticks. Positive values only.
*/
type UpdateIntervalBase = number;
/**
* The variant value in ticks that will be added to the update_interval_base.
*/
type UpdateIntervalVariant = number;
/**
* Whether or not the mob can find and add POI's to the dwelling.
*/
type CanFindPoi = boolean;
/**
* How much reputation should the players be rewarded on first founding?.
*/
type FirstFoundingReward = number;
/**
* Can this mob migrate between dwellings? Or does it only have its initial dwelling?.
*/
type CanMigrate = boolean;
/**
* A padding distance for checking if the mob is within the dwelling.
*/
type DwellingBoundsTolerance = number;
/**
* Allows the user to define a starting profession for this particular Dweller, instead of letting them choose organically. (They still need to gain experience from trading before this takes effect.)
*/
type PreferredProfession = string;
/**
* Determines when the mob transforms, if the trades should be converted when the new mob has a economy_trade_table. When the trades are converted, the mob will generate a new trade list with their new trade table, but then it will try to convert any of the same trades over to have the same enchantments and user data. For example, if the original has a Emerald to Enchanted Iron Sword (Sharpness 1), and the new trade also has an Emerald for Enchanted Iron Sword, then the enchantment will be Sharpness 1.
*/
type ConvertTradesEconomy = boolean;
/**
* How much should the discount be modified by when the player has cured the Zombie Villager. Can be specified as a pair of numbers (low-tier trade discount and high-tier trade discount)
*/
type CuredDiscount = [] | [A1] | [A1, B1];
/**
* Minimum.
*/
type A1 = number;
/**
* Maximum.
*/
type B1 = number;
/**
* Name to be displayed while trading with this entity.
*/
type DisplayName = string;
/**
* Used in legacy prices to determine how much should Demand be modified by when the player has the Hero of the Village mob effect.
*/
type HeroDemandDiscount = number;
/**
* The Maximum the discount can be modified by when the player has cured the Zombie Villager. Can be specified as a pair of numbers (low-tier trade discount and high-tier trade discount)
*/
type MaximumCuredDiscount = [] | [A2] | [A2, B2];
/**
* Minimum.
*/
type A2 = number;
/**
* Maximum.
*/
type B2 = number;
/**
* The Maximum the discount can be modified by when the player has cured a nearby Zombie Villager.
*/
type MaximumNearbyCuredDiscount = number;
/**
* How much should the discount be modified by when the player has cured a nearby Zombie Villager.
*/
type NearbyCuredDiscount = number;
/**
* Used to determine if trading with entity opens the new trade screen.
*/
type NewScreen = boolean;
/**
* Determines if the trades should persist when the mob transforms. This makes it so that the next time the mob is transformed to something with a trade_table or economy_trade_table, then it keeps their trades.
*/
type PersistTrades = boolean;
/**
* Show an in game trade screen when interacting with the mob.
*/
type ShowTradeScreen = boolean;
/**
* File path relative to the resource pack root for this entity's trades.
*/
type Table = string;
/**
* Determines whether the legacy formula is used to determines the trade prices.
*/
type UseLegacyPriceFormula = boolean;
/**
* A component that fires an event when a set of conditions are met by other entities within the defined range.
*/
type EntitySensor = ((EntitySensor1 & {
relative_range?: RelativeRange;
[k: string]: unknown;
}) | {
subsensors?: Subsensors;
relative_range?: RelativeRange1;
[k: string]: unknown;
});
/**
* How many seconds should elapse before the subsensor can once again sense for entities. The cooldown is applied on top of the base 1 tick (0.05 seconds) delay. Negative values will result in no cooldown being used.
*/
type Cooldown = number;
/**
* event.
*/
type Event3 = string;
/**
* The maximum number of entities that must pass the filter conditions for the event to send.
*/
type MaximumCount = number;
/**
* The minimum number of entities that must pass the filter conditions for the event to send.
*/
type MinimumCount = number;
/**
* The maximum distance another entity can be from this and have the filters checked against it.
*/
type Range3 = (VectorOf2Items | number);
/**
* An vector of 2 number.
*/
type VectorOf2Items = [] | [X] | [X, Y];
/**
* If true requires all nearby entities to pass the filter conditions for the event to send.
*/
type RequireAll = boolean;
/**
* The maximum distance another entity can be from this and have the filters checked against it.
*/
type SensorRange = number;
/**
* If true the sensor range is additive on top of the entity's size.
*/
type RelativeRange = boolean;
/**
* The list of subsensors.
*/
type Subsensors = EntitySensor1[];
/**
* If true the sensor range is additive on top of the entity's size.
*/
type RelativeRange1 = boolean;
/**
* The list of triggers that fire when the environment conditions match the given filter criteria.
*/
type Triggers3 = (string | Trigger | Trigger1[]);
/**
* Item that the entity should not equip.
*/
type ExcludedItems1 = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* List of items that the entity should not equip.
*/
type ExcludedItems = ExcludedItems1[];
/**
* The chance that the item in this slot will drop.
*/
type DropChance = number;
/**
* The slot in which the item will drop from.
*/
type Slot = string;
/**
* A list of slots with the chance to drop an equipped item from that slot.
*/
type SlotDropChance = SlotDropChance1[];
/**
* The file path to the equipment table, relative to the behavior pack's root.
*/
type Table1 = string;
/**
* The slot number of this slot.
*/
type Slot1 = number;
/**
* A item name.
*/
type AcceptedItems1 = (AcceptedItems2 & AcceptedItems3);
type AcceptedItems2 = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
type AcceptedItems3 = string;
/**
* The list of items that can go in this slot.
*/
type AcceptedItems = AcceptedItems1[];
/**
* Identifier of the item that can be equipped for this slot.
*/
type Item1 = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* Text to be displayed when the entity can be equipped with this item when playing with Touch-screen controls.
*/
type InteractText = string;
/**
* List of slots and the item that can be equipped.
*/
type Slots = Slots1[];
/**
* Amount of exhaustion applied when attacking.
*/
type Attack1 = number;
/**
* Amount of exhaustion applied when taking damage.
*/
type Damage2 = number;
/**
* Amount of exhaustion applied when healed through food regeneration.
*/
type Heal = number;
/**
* Amount of exhaustion applied when jumping.
*/
type Jump = number;
/**
* Amount of exhaustion applied when mining.
*/
type Mine = number;
/**
* Amount of exhaustion applied when sprinting.
*/
type Sprint = number;
/**
* Amount of exhaustion applied when sprint jumping.
*/
type SprintJump = number;
/**
* Amount of exhaustion applied when swimming.
*/
type Swim = number;
/**
* Amount of exhaustion applied when walking.
*/
type Walk = number;
/**
* A molang expression defining the amount of experience rewarded when this entity is successfully bred. An array of expressions adds each expression's result together for a final total.
*/
type OnBred = (string | number);
/**
* A molang expression defining the amount of experience rewarded when this entity dies. An array of expressions adds each expression's result together for a final total.
*/
type OnDeath = (string | number);
/**
* If true, the explosion will destroy blocks in the explosion radius.
*/
type BreaksBlocks = boolean;
/**
* If true, blocks in the explosion radius will be set on fire.
*/
type CausesFire = boolean;
/**
* If true, whether the explosion breaks blocks is affected by the mob griefing game rule.
*/
type DestroyAffectedByGriefing = boolean;
/**
* If true, whether the explosion causes fire is affected by the mob griefing game rule.
*/
type FireAffectedByGriefing = boolean;
/**
* The range for the random amount of time the fuse will be lit before exploding, a negative value means the explosion will be immediate.
*/
type FuseLength = ([] | [number] | [number, number] | number);
/**
* If true, the fuse is already lit when this component is added to the entity.
*/
type FuseLit = boolean;
/**
* A blocks explosion resistance will be capped at this value when an explosion occurs.
*/
type MaximumResistance = number;
/**
* The radius of the explosion in blocks and the amount of damage the explosion deals.
*/
type Power = number;
/**
* UNDOCUMENTED: value.
*/
type Value5 = number;
/**
* The amount of blocks away the entity will look at to push away from.
*/
type BlockDistance = number;
/**
* The weight of the push back away from blocks.
*/
type BlockWeight = number;
/**
* The amount of push back given to a flocker that breaches out of the water.
*/
type BreachInfluence = number;
/**
* The threshold in which to start applying cohesion.
*/
type CohesionThreshold = number;
/**
* The weight applied for the cohesion steering of the flock.
*/
type CohesionWeight = number;
/**
* The weight on which to apply on the goal output.
*/
type GoalWeight = number;
/**
* Determines the high bound amount of entities that can be allowed in the flock.
*/
type HighFlockLimit = number;
/**
* Tells the Flocking Component if the entity exists in water.
*/
type InWater = boolean;
/**
* The area around the entity that allows others to be added to the flock.
*/
type InfluenceRadius = number;
/**
* The distance in which the flocker will stop applying cohesion.
*/
type InnnerCohesionThreshold = number;
/**
* The percentage chance between 0-1 that a fish will spawn and not want to join flocks. Invalid values will be capped at the end points.
*/
type LonerChance = number;
/**
* Determines the low bound amount of entities that can be allowed in the flock.
*/
type LowFlockLimit = number;
/**
* Tells the flockers that they can only match similar entities that also match the variant, mark variants, and color data of the other potential flockers.
*/
type MatchVariants = boolean;
/**
* The Maximum height allowable in the air or water.
*/
type MaximumHeight = number;
/**
* The Minimum height allowable in the air or water.
*/
type MinimumHeight = number;
/**
* The distance that is determined to be to close to another flocking and to start applying separation.
*/
type SeparationThreshold = number;
/**
* The weight applied to the separation of the flock.
*/
type SeparationWeight = number;
/**
* Tells the flockers that they will follow flocks based on the center of mass.
*/
type UseCenterOfMass = boolean;
/**
* Flying speed in blocks per tick.
*/
type Value6 = number;
/**
* The higher the number, the more the friction affects this entity. A value of 1.0 means regular friction, while 2.0 means twice as much
*/
type Value7 = number;
/**
* If true, the `flap` game event will be emitted when the entity moves through air.
*/
type EmitFlap = boolean;
/**
* If true, the `entityMove` game event will be emitted when the entity moves on ground or through a solid.
*/
type EmitMove = boolean;
/**
* If true, the `swim` game event will be emitted when the entity moves through a liquid.
*/
type EmitSwim = boolean;
/**
* Chance that an allele will be replaced with a random one instead of the parent's allele during birth.
*/
type MutationRate = number;
/**
* The range of positive integer allele values for this gene. Spawned mobs will have a random number in this range assigned to them.
*/
type AlleleRange = (number | {
range_min?: RangeMinimum1;
range_max?: RangeMaximum1;
[k: string]: unknown;
});
/**
* Lower bound of the vaues.
*/
type RangeMinimum1 = number;
/**
* Upper bound of the vaues.
*/
type RangeMaximum1 = number;
/**
* If this value is non-negative, compare both the mob's main and hidden alleles with this value for a match with both. Can also be a range of integers.
*/
type BothAllele = (number | {
range_min?: RangeMinimum1;
range_max?: RangeMaximum1;
[k: string]: unknown;
});
/**
* If this value is non-negative, compare both the mob's main and hidden alleles with this value for a match with either. Can also be a range of integers.
*/
type EitherAllele = number;
/**
* If this value is non-negative, compare the mob's hidden allele with this value for a match. Can also be a range of integers.
*/
type HiddenAllele = number;
/**
* If this value is non-negative, compare the mob's main allele with this value for a match. Can also be a range of integers.
*/
type MainAllele = (number | {
range_min?: RangeMinimum1;
range_max?: RangeMaximum1;
[k: string]: unknown;
});
/**
* If this value is non-negative, overrides the chance for this gene that an allele will be replaced with a random one instead of the parent's allele during birth. Non-negative values greater than 1 will be the same as the value 1.
*/
type MutationRate1 = number;
/**
* The list of genetic variants for this gene. These check for particular allele combinations and fire events when all of them are satisfied.
*/
type GeneticVariants = GeneticVariants1[];
/**
* The name of the gene.
*/
type Name1 = string;
/**
* The list of genes that this entity has and will cross with a partner during breeding.
*/
type Genes = Gene[];
/**
* An optional cool down in seconds to prevent spamming interactions.
*/
type Cooldown1 = number;
/**
* An items that can be given to the entity to place in their inventory.
*/
type Properties1 = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* The list of items that can be given to the entity to place in their inventory.
*/
type Properties = Properties1[];
/**
* The value of the entity's offset from the terrain, in blocks.
*/
type Value8 = number;
/**
* The list of conditions that must be satisfied for other entities to be counted towards group size.
*/
type Filters10 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* Radius from center of entity.
*/
type Radius2 = number;
/**
* Value between 0-1. Chance of success per tick.
*/
type Chance1 = number;
/**
* Number of charges.
*/
type Charges = number;
/**
* Determines if item can be used regardless of entity being at full health.
*/
type ForceUse = boolean;
/**
* The filter group that defines the conditions for using this item to heal the entity.
*/
type Filters11 = (BFGroupsSpec[] | BFFiltersSpec);
/**
* The amount of health this entity gains when fed this item.
*/
type HealAmount = number;
/**
* Item that can be used to heal this entity.
*/
type Item2 = (ItemIdentifier | ItemDescriptor | {
item?: (ItemIdentifier2 | ItemDescriptor2);
[k: string]: unknown;
});
/**
* UNDOCUMENTED.
*/
type Name2 = string;
/**
* The array of items that can be used to heal this entity.
*/
type Items = {
filters?: Filters11;
heal_amount?: HealAmount;
item?: Item2;
effects?: (BGJEffect | BGJEffect[]);
[k: string]: unknown;
}[];
/**
* A Molang expression defining the inter-beat interval in seconds. A value of zero or less means no heartbeat..
*/
type Interval = (string | number);
/**
* Level sound event to be played as the heartbeat sound.
*/
type SoundEvent = string;
/**
* The radius that the entity will be restricted to in relation to its home.
*/
type RestrictionRadius = number;
/**
* A minecraft item identifier.
*/
type ItemIdentifier4 = string;
/**
* Optional block list that the home position will be associated with. If any of the blocks no longer exist at that position, the home restriction is removed. Example syntax: minecraft:sand. Not supported: minecraft:sand:1
*/
type HomeBlockList = ItemIdentifier4[];
/**
* The multiplier to apply to the jumping height.
*/
type Value9 = ({
range_min?: number;
range_max?: number;
} | number);
/**
* Damage cause.
*/
type Cause2 = ("all" | "anvil" | "block_explosion" | "campfire" | "charging" | "contact" | "drowning" | "entity_attack" | "entity_explosion" | "fall" | "falling_block" | "fatal" | "fire" | "fire_tick" | "fireworks" | "fly_into_wall" | "freezing" | "lava" | "lightning" | "magic" | "magma" | "none" | "override" | "piston" | "projectile" | "ram_attack" | "sonic_boom" | "soul_campfire" | "stalactite" | "stalagmite" | "starve" | "suffocation" | "suicide" | "temperature" | "thorns" | "void" | "wither");
/**
* Amount of damage done each tick that the conditions are met.
*/
type DamagePerTick1 = number;
/**
* An array of conditions used to compare the event to.
*/
type DamageConditions = DamageCondition[];
/**
* The block id, for example: `minecraft:air'.
*/
type Name3 = string;
/**
* A single state of a block.
*/
type State = (string | boolean | number);
/**
* List of blocks, with certain block states, that we are monitoring to see if the entity is inside.
*/
type BlockList1 = Block[];
/**
* Number of days the mob has to stay up until the insomnia effect begins.
*/
type DaysUntilInsomnia = number;
/**
* If true, all entities linked to this entity in a child relationship (eg. leashed) will also be despawned.
*/
type RemoveCh