Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
component:robot [2018/09/27 02:07]
payonel
component:robot [2018/09/27 02:08]
payonel
Line 4: Line 4:
 Component name: `robot`.  ​ Component name: `robot`.  ​
  
-====InventoryController Trait API==== +===Base Methods=== 
- +{{page>​component:agent#Robot Component API&​noheader&​nofooter}} 
-- `inventorySize():number`  ​ +{{page>​component:agent#Agent Trait API&​noheader&​nofooter}}
-  ​Returns the size of the device'​s internal inventory. +
-- `select([slot:number]):​number` ​  +
-  Get the currently selected slot; set the selected slot if specified. +
-- `count([slot:​number]):​number` ​  +
-  Get the number of items in the specified slot, otherwise in the selected slot. +
-- `space([slot:​number]):​number` ​  +
-  Get the remaining space in the specified slot, otherwise in the selected slot. +
-- `compareTo(otherSlot:​number):​boolean` ​  +
-  Compare the contents of the selected slot (in the robot inventory) to the contents of the specified slot (also in the robot inventory). +
-- `transferTo(toSlot:​number[,​ amount:​number]):​boolean` ​  +
-  Move the specified amount of items from the selected slot into the specified slot. If no amount is specified, the entire stack is moved to the target slot. +
  
 ====WorldControl Trait API==== ====WorldControl Trait API====