Find blocks
Ten poradnik jest dostępny tylko po angielsku.
Czy ta strona jest pomocna?
Ten poradnik jest dostępny tylko po angielsku.
Czy ta strona jest pomocna?
Finds blocks of the given ids within a radius of the bot. Results are sorted by ascending distance.
AuthorizationBearer <JWT>Preferred API authentication. Use a JWT with the api audience.
instance_id*stringuuidbot_id*stringuuidapplication/jsonblockIds*array<string>Block ids to match (namespaced, e.g. "minecraft:diamond_ore"). A block matches if its id equals any entry in this list.
maxDistance*integerMaximum search radius in blocks, measured from the bot's current block position. Server clamps to an implementation-defined maximum.
int32maxCount*integerMaximum number of matches to return. Results are ordered by ascending distance from the bot.
int32Successful response.
application/jsonblocks?array<>curl -X POST 'http://127.0.0.1:38765/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/bots/497f6eca-6276-4993-bfeb-53cbbbba6f08/live/world/blocks:find' \ -H 'Content-Type: application/json' \ -d '{ "blockIds": [ "string" ], "maxDistance": 0, "maxCount": 0}'{ "blocks": [ { "position": { "x": 0, "y": 0, "z": 0, "dimension": "string" }, "blockId": "string", "properties": { "property1": "string", "property2": "string" } } ]}curl -X POST 'http://127.0.0.1:38765/v1/instances/497f6eca-6276-4993-bfeb-53cbbbba6f08/bots/497f6eca-6276-4993-bfeb-53cbbbba6f08/live/world/blocks:find' \
-H 'Content-Type: application/json' \
-d '{
"blockIds": [
"string"
],
"maxDistance": 0,
"maxCount": 0
}'{
"blocks": [
{
"position": {
"x": 0,
"y": 0,
"z": 0,
"dimension": "string"
},
"blockId": "string",
"properties": {
"property1": "string",
"property2": "string"
}
}
]
}