Class MultiblockMember.Builder
java.lang.Object
fr.robie.machineengine.api.multiblock.MultiblockMember.Builder
- Enclosing class:
MultiblockMember
Makes the behavior factories of members.
-
Method Summary
Modifier and TypeMethodDescriptionframe()A casing or glass: finds the structure; anchors it when it is the anchor block.frame(@NotNull MultiblockMember.AnchorTask task, long everyTicks) A frame block whose anchor also runstaskeveryeveryTickswhile the structure is formed.A valve or port with modes (a configurator cycles them): it fills the anchor'sinsertIntostorages, and in each mode gives out the storagespusheslists for it (pushed to its neighbors, and taken by pipes).port(@NotNull String storage, @NotNull MultiblockMember.PortRate outputRate) A port whose output rate also depends on the port block's options (D34).port(@NotNull String storage, @NotNull ToLongFunction<MultiblockStructure> outputRate) A port: passesstoragein, or (inoutputmode) pushes it out atoutputRateper tick.@NotNull MultiblockMember.BuilderportMode(@NotNull MachineDataKey<String> key) The machine data key ports keep their mode in (an addon keeping its own saved key).A valve: passes through to the anchor'sstorages.A valve filling the anchor'sinsertIntostorages and emptying itsextractFromones.
-
Method Details
-
portMode
@NotNull public @NotNull MultiblockMember.Builder portMode(@NotNull @NotNull MachineDataKey<String> key) The machine data key ports keep their mode in (an addon keeping its own saved key). -
frame
A casing or glass: finds the structure; anchors it when it is the anchor block. -
frame
@NotNull public MachineBehavior.Factory frame(@NotNull @NotNull MultiblockMember.AnchorTask task, long everyTicks) A frame block whose anchor also runstaskeveryeveryTickswhile the structure is formed. -
valve
@NotNull public MachineBehavior.Factory valve(@NotNull @NotNull List<String> storages, boolean exclusive) A valve: passes through to the anchor'sstorages. Withexclusive, the structure holds one of them at a time (a tank holds a fluid or a chemical). -
valve
@NotNull public MachineBehavior.Factory valve(@NotNull @NotNull List<String> insertInto, @NotNull @NotNull List<String> extractFrom) A valve filling the anchor'sinsertIntostorages and emptying itsextractFromones. -
modal
@NotNull public MachineBehavior.Factory modal(@NotNull @NotNull List<String> insertInto, @NotNull @NotNull Map<String, List<String>> pushes) A valve or port with modes (a configurator cycles them): it fills the anchor'sinsertIntostorages, and in each mode gives out the storagespusheslists for it (pushed to its neighbors, and taken by pipes). The block shows the mode (modeproperty, oractivewhen not ininput). -
port
@NotNull public MachineBehavior.Factory port(@NotNull @NotNull String storage, @NotNull @NotNull ToLongFunction<MultiblockStructure> outputRate) A port: passesstoragein, or (inoutputmode) pushes it out atoutputRateper tick. -
port
@NotNull public MachineBehavior.Factory port(@NotNull @NotNull String storage, @NotNull @NotNull MultiblockMember.PortRate outputRate) A port whose output rate also depends on the port block's options (D34).
-