Core - Enums Module
anvil.api.core.enums
Anchor
Bases: StrEnum
Enumeration representing the two anchor points that can be used in Minecraft: the feet and the eyes.
BlockCardinalConnection
Bases: StrEnum
Enumeration representing the connected faces of a block in Minecraft, used for blocks that can connect to adjacent blocks (e.g., fences, walls).
BlockCorner
Bases: StrEnum
Enumeration representing the corner and cardinal directions for block placement in Minecraft.
BlockFaces
Bases: StrEnum
Enumeration representing the different faces of a block in Minecraft.
BlockMaterial
Bases: StrEnum
Enumeration representing the different types of rendering methods a block can use in Minecraft.
BlockMovementType
Bases: StrEnum
Enumeration for the different types of block movement in Minecraft.
PushPull: The default value for this field. The block will be pushed and pulled by a piston. Push: The block will only be pulled by a piston and will ignore a sticky piston. Popped: The block is destroyed when moved by a piston. Immovable: The block is unaffected by a piston.
BlockStickyType
Bases: StrEnum
Enumeration for the different types of block stickiness in Minecraft.
Sticky: The block will stick to a sticky piston. NonSticky: The block will not stick to a sticky piston.
CameraShakeType
Bases: StrEnum
Enumeration representing the types of camera shakes that can occur in Minecraft.
CloneMode
Bases: StrEnum
Enumeration representing the different modes that can be used when cloning in Minecraft.
ComponentTarget
Bases: StrEnum
Enumeration for the different component targets in Minecraft.
DamageCause
Bases: StrEnum
Enumeration for the different causes of damage in the game.
Difficulty
Bases: StrEnum
Enumeration for the different levels of game difficulty.
Dimension
Bases: StrEnum
Enumeration for the different dimensions in the game.
EnchantsSlots
Bases: StrEnum
Enumeration of enchantment slots available in Minecraft.
This enum defines all possible equipment slots that can receive enchantments, organized by equipment type and usage category.
Armor Slots
ArmorHead: Helmet slot enchantments ArmorTorso: Chestplate slot enchantments ArmorLegs: Leggings slot enchantments ArmorFeet: Boots slot enchantments GArmor: General armor enchantments (applicable to any armor piece)
Weapon Slots
Sword: Sword-specific enchantments Bow: Bow-specific enchantments Spear: Spear/trident enchantments Crossbow: Crossbow-specific enchantments MeleeSpear: Melee trident enchantments
Tool Slots
GTool: General tool enchantments (applicable to multiple tool types) Hoe: Hoe-specific enchantments Shears: Shears-specific enchantments Flintandsteel: Flint and steel enchantments Shield: Shield-specific enchantments
Digging Tools
GDigging: General digging tool enchantments Axe: Axe-specific enchantments Pickaxe: Pickaxe-specific enchantments Shovel: Shovel-specific enchantments
Special Items
FishingRod: Fishing rod enchantments CarrotStick: Carrot on a stick enchantments Elytra: Elytra wing enchantments CosmeticHead: Cosmetic head item enchantments
FeatureRulePlacementPass
Bases: StrEnum
Enumeration for the different feature rule placement passes in Minecraft.
FilterEquipmentDomain
Bases: StrEnum
Enumeration representing the different equipment domains that can be used in filters in Minecraft.
FilterOperation
Bases: StrEnum
Enumeration representing the different operations that can be used in filters in Minecraft.
FilterSubject
Bases: StrEnum
Enumeration representing the different subjects that can be used in filters in Minecraft.
FogCameraLocation
Bases: StrEnum
Enumeration for the different locations of the fog camera in the game.
Gamemodes
Bases: StrEnum
Enumeration for the different types of game modes.
InputPermissions
Bases: StrEnum
Enumeration representing the different input permissions that can be set for a player in Minecraft.
ItemCategory
Bases: StrEnum
Enumeration representing the categories of blocks and items that can be used in Minecraft.
LeashSpringType
Bases: StrEnum
Enumeration for the different types of leash springs in Minecraft.
Bouncy: Simulates a highly elastic spring that never reaches an equilibrium if the leashed entity is suspended mid-air. Dampened: Simulates a dampened spring attached to the front of the leashed entity's collision. It reaches an equilibrium if the entity is suspended mid-air and aligns with the movement direction. QuadDampened: Simulates four dampened springs connected to the center of each side of the entities' collisions. It reaches an equilibrium if the entity is suspended mid-air and gradually aligns with the leash holder over time.
LootPoolType
Bases: StrEnum
Enumeration for the different types of loot pools.
MaskMode
Bases: StrEnum
Enumeration representing the different mask modes that can be applied in Minecraft.
MaterialDefinitions
Bases: StrEnum
Enumeration representing the different definitions that can be set for a material in Minecraft.
MaterialFunc
Bases: StrEnum
Enumeration representing the different functions that can be set for a material in Minecraft.
MaterialOperation
Bases: StrEnum
Enumeration representing the different operations that can be set for a material in Minecraft.
MaterialStates
Bases: StrEnum
Enumeration representing the different states a material can be in Minecraft.
MusicCategory
Bases: StrEnum
Enumeration for the different categories of music in the game.
Population
Bases: StrEnum
Enumeration for the different types of in-game populations.
RenderDistanceType
Bases: StrEnum
Enumeration for the different types of render distances in the game.
RideableDismountMode
Bases: StrEnum
Enumeration for the different modes of dismounting a rideable entity in Minecraft.
ScoreboardOperation
Bases: StrEnum
Enumeration for the different operations that can be performed on a scoreboard.
ScoreboardOperator
Bases: StrEnum
Enumeration for the different types of mathematical operators.
Slots
Bases: StrEnum
Enumeration for the different types of inventory slots in the game.
SoundCategory
Bases: StrEnum
Enumeration for the different categories of sounds in the game.
Style
Bases: StrEnum
Enumeration for the different styles of text in the game.
Target
Bases: StrEnum
Enumeration for the types of targets that can be selected in Minecraft.
Weather
Bases: StrEnum
Enumeration representing the different types of weather that can be set in Minecraft.
expand_block_face_sides(faces)
Expand BlockFaces.Side and BlockFaces.All into explicit face lists.
Side expands to the four cardinal directions (North, South, East, West).
All expands to all six faces.
The input list is not mutated; a new list is returned.