Package mindustry.world.modules
Class LiquidModule
java.lang.Object
mindustry.world.modules.BlockModule
mindustry.world.modules.LiquidModule
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic interface
static interface
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
clear()
current()
Last received or loaded liquid.float
void
float
float
getFlowRate
(Liquid liquid) void
handleFlow
(Liquid liquid, float amount) boolean
hasFlowLiquid
(Liquid liquid) void
void
void
void
void
stopFlow()
float
void
void
Methods inherited from class mindustry.world.modules.BlockModule
read
-
Constructor Details
-
LiquidModule
public LiquidModule()
-
-
Method Details
-
updateFlow
public void updateFlow() -
stopFlow
public void stopFlow() -
getFlowRate
- Returns:
- current liquid's flow rate in u/s; any value < 0 means 'not ready'.
-
hasFlowLiquid
-
current
Last received or loaded liquid. Only valid for liquid modules with 1 type of liquid. -
reset
-
set
-
currentAmount
public float currentAmount() -
get
-
clear
public void clear() -
add
-
handleFlow
-
remove
-
each
-
sum
-
write
- Specified by:
write
in classBlockModule
-
read
- Overrides:
read
in classBlockModule
-