commands.getBlockInfos
From ComputerCraft Wiki
Revision as of 04:10, 26 December 2015 by Bomb Bloke (Talk | contribs) (Created page with "{{lowercase}} {{Function |name=commands.getBlockInfos |args={{type|number}} x1, {{type|number}} y1, {{type|number}} z1, {{type|number}} x2, {{type|number}} y2, {{type|number}}...")
Function commands.getBlockInfos | |
Available only to Command Computers as of ComputerCraft version 1.76, returns a numerically-indexed table containing information on the blocks within the specified world co-ordinates. Each sub-table is formatted per the output of commands.getBlockInfo():
{ state = table state information name = string block's name, metadata = number block's metadata } A maximum of 4096 (2^12) blocks may be inspected at a time (for example, a 16x16x16 cube); the function will error if the block count exceeds this. The blocks are returned in the order of lowest x-co-ord to highest x-co-ord, then lowest z-co-ord to highest z-co-ord, then lowest y-co-ord to highest y-co-ord; that is to say, west to east, then north to south, then lowest altitude to highest altitude. See also: commands.getBlockInfo(), Data Values @ Minecraft wiki | |
Syntax | commands.getBlockInfos(number x1, number y1, number z1, number x2, number y2, number z2) |
Returns | table blocks info |
Part of | ComputerCraft |
API | commands |
Examples
Commands API Functions |
---|
commands.exec - commands.execAsync - commands.list - commands.getBlockPosition - commands.getBlockInfo - commands.getBlockInfos |