Which kind of mining script are you building?
Ignore the material at first. Choose the mining mode from the shape of the work.
One exact coordinate
Use hexis.mining.mine_block when Lua already knows the exact x, y, and
z. Hexis mines that block and no substitute.
local result = hexis.await(hexis.mining.mine_block({
world_generation = observed.world_generation,
target = {x = 12, y = 70, z = -8},
blocks = {priorities = {["minecraft:diamond_ore"] = 100}},
}), {timeout = 60})
Good for a block selected from a previous observation. Do not use it when any nearby matching block would satisfy the goal.
One matching block
Use hexis.mining.mine_one for scattered matches. Hexis chooses and mines one
eligible block, then returns control to Lua.
local result = hexis.await(hexis.mining.mine_one({
world_generation = found.world_generation,
area = {kind = "zone", route = "user:Sea_Pickles"},
blocks = {priorities = {["minecraft:sea_pickle"] = 100}},
}), {timeout = 180})
Good for sea pickles, isolated ores, or any loop that should decide again after each break.
One connected vein or tree
Use hexis.mining.mine_connected when touching blocks form one object. Hexis
finishes one face-connected component from the supplied seed positions.
local result = hexis.await(hexis.mining.mine_connected({
world_generation = route.world_generation,
seeds = route.seeds,
blocks = {priorities = {["minecraft:oak_log"] = 100}},
maximum_blocks = 128,
}), {timeout = 300})
Good for ore veins and trees. Do not use it for separated targets.
Every match inside a bounded place
Use hexis.mining.mine_area for a field, crop patch, box, radius, or route
zone. Hexis works through eligible matches inside that boundary.
local result = hexis.await(hexis.mining.mine_area({
world_generation = found.world_generation,
area = {kind = "radius", radius = 12},
blocks = {priorities = {["minecraft:wheat"] = 100}},
maximum_blocks = 400,
}), {timeout = 600})
Good for bounded mining and crop patches. Always choose a finite boundary.
Describe eligible blocks
All four modes use the same exact block-ID priority map:
local BLOCKS = {
priorities = {
["minecraft:diamond_ore"] = 100,
["minecraft:deepslate_diamond_ore"] = 90,
},
}
A held-item selector is optional:
held = {name_patterns = {"Pickaxe", "Drill"}}
All four modes require mining, navigation, and pathfinding. Add
etherwarp only when navigation enables Ether Transmission.
Success means the action reached its documented server-observed completion
condition. Retry terrain_incomplete, search_node_limit, or navigation
failures only when the returned result says retryable = true.
Start with the defaults. Break models, handoff behavior, harvest tuning, and debug output are advanced options.