Tank

Stores liquids and gases. When a liquid or gas touches the Tank, the Tank will automatically store it. Will not conduct heat when containing a fluid, making it a good heat storage part. It is a craftable and spawnable non-flammable solid.
Here is a list of possible sizes that reach the maximum malleability (1000) that have integer components: 1x1x1000, 1x2x500, 1x4x250, 1x5x200, 1x8x125, 1x10x100, 1x20x50, 1x25x40, 2x2x250, 2x4x125, 2x5x100, 2x10x50, 2x20x25, 4x5x50, 4x10x25, 5x5x40, 5x8x25, 5x10x20, 10x10x10
At its default size (3x3x3) it has a durability of 1, at its maximum size it has a durability of 4.
By default, its colour is #69665c.
Methods
GetResource() → resource
Gets the name of the resource contained, will return the string "nil"
if nothing is stored, rather than actually returning nil
.
The resource return can be any of the following types:
-
string
-
"nil"
GetResourceAmount() → amount
Gives you the total amount of objects in the container.
The amount return is a number
.
GetAmount() → amount
This method is deprecated. Use :GetResourceAmount()
instead.
Gives you the total amount of objects in the container.
The amount return is a number
.
Configurables
CanBeCraftedFrom
Determines whether this Tank can be used by nearby players to craft objects. It is a boolean
.
Resource
The kind of resource the bin can hold. You can set this to Any to allow the bin to accept anything. It is a string
.
Events
ContainerChanged(resourceType, resourceAmount)
Fires when the amount of the resource in the container changes.
The parameters for ContainerChanged
are as follows:
- The resourceType parameter is a string that can be
Power
,Solid
, orFluid
- The resourceAmount parameter is a
number
.
OnClick(clickerId)
Fires when the object is clicked.
The clickerId parameter is the UserId
of the player who clicked the object. It is a number
.