Differences

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

Link to this comparison view

Both sides previous revision Previous revision
component:tank_controller [2015/01/14 23:40]
127.0.0.1 external edit
component:tank_controller [2015/04/05 15:50]
rashy Added missing functions.
Line 11: Line 11:
 - `getTankCapacity(side:​number):​number or nil[, string]`  ​ - `getTankCapacity(side:​number):​number or nil[, string]`  ​
   Get the capacity of the tank on the specified side of the robot. Back refers to the robot'​s own selected tank.   Get the capacity of the tank on the specified side of the robot. Back refers to the robot'​s own selected tank.
 +- `getTankLevel(side:​number):​number or nil[,​string]`  ​
 +  Gets amount of fluid in tank on specified side.
 - `getFluidInTank(side:​number):​table`  ​ - `getFluidInTank(side:​number):​table`  ​
-  Get a description of the fluid in the the tank on the specified side of the robot. ​Back refers to the robot'​s own selected ​tank.+  Get a description of the fluid in the the tank on the specified side of the robot. ​**Note:** sides.back deprecated, use `getFluidInInternalTank()` 
 +- `getFluidInInternalTank(slot):​table` 
 +  Get a description of fluid in the specified or selected ​slot of robot inventory.
 - `drain([amount:​number]):​boolean`  ​ - `drain([amount:​number]):​boolean`  ​
   Transfers fluid from a tank in the selected inventory slot to the selected tank. If the amount of fluid that would be generated from the item is too large to fit into the tank (for example buckets will usually generate 1000) nothing will happen, that is no fluid is lost.   Transfers fluid from a tank in the selected inventory slot to the selected tank. If the amount of fluid that would be generated from the item is too large to fit into the tank (for example buckets will usually generate 1000) nothing will happen, that is no fluid is lost.
 - `fill([amount:​number]):​boolean`  ​ - `fill([amount:​number]):​boolean`  ​
   Transfers fluid from the selected tank to a tank in the selected inventory slot. If the specified amount is too low (for example for buckets the minimum amount will usually be 1000) nothing will happen, that is no fluid is lost.   Transfers fluid from the selected tank to a tank in the selected inventory slot. If the specified amount is too low (for example for buckets the minimum amount will usually be 1000) nothing will happen, that is no fluid is lost.
 +- `getTankCapacityInSlot(slot:​number):​number`  ​
 +  Gets capacity of tank in specified or selected slot of the robot inventory.
 +- `getTankLevelInSlot(slot:​number):​number`  ​
 +  Gets amount of fluid tank item in specified or selected slot of the robot inventory.
 +- `getFluidInTankInSlot(slot:​number):​table`  ​
 +  Gets description of fluid in tank item in the specified or selected slot of the robot inventory.
  
 ---- ----
  
 {{page>​component:​contents&​noheader&​noeditbutton&​nouser&​nofooter}} {{page>​component:​contents&​noheader&​noeditbutton&​nouser&​nofooter}}