Skip to content

Commit

Permalink
Fluid transport
Browse files Browse the repository at this point in the history
  • Loading branch information
Slotterleet committed May 20, 2024
1 parent 0103056 commit 9096ca4
Show file tree
Hide file tree
Showing 5 changed files with 86 additions and 14 deletions.
16 changes: 14 additions & 2 deletions res/bundles/bundle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -141,10 +141,22 @@ block.fos-tin-bridge.name = Tin Bridge Conveyor
block.fos-tin-bridge.description = Transports items over terrain or buildings.
block.fos-tin-belt.name = Tin Belt
block.fos-tin-belt.description = Transports items forward.
block.fos-fluid-pipe.name = Fluid Pipe
block.fos-fluid-pipe.description = Transports liquids and gasses.
block.fos-copper-pipe.name = Copper Pipe
block.fos-copper-pipe.description = Moves liquids and gasses forward.
block.fos-brass-pipe.name = Brass Pipe
block.fos-brass-pipe.description = Moves liquids and gasses forward. Does not accept input from the sides.
block.fos-fluid-junction.name = Fluid Junction
block.fos-fluid-junction.description = Acts as a bridge between two crossing pipes.
block.fos-fluid-bridge.name = Bridge Pipe
block.fos-fluid-bridge.description = Transports fluid over terrain or buildings.
block.fos-pumpjack.name = Pumpjack
block.fos-pumpjack.description = Pumps and outputs liquids. Does not require power.
block.fos-fluid-router.name = Fluid Router
block.fos-fluid-router.description = Accepts liquids and outputs them to up to 3 directions equally. Also stores a certain amount of fluid.
block.fos-fluid-barrel.name = Fluid Barrel
block.fos-fluid-barrel.description = Stores a sizeable amount of fluid. Outputs to all sides, similarly to a fluid router.
block.fos-fluid-tank.name = Fluid Tank
block.fos-fluid-tank.description = Stores a large amount of fluid. Outputs to all sides, similarly to a fluid router.
block.fos-tin-wire.name = Tin Wire
block.fos-tin-wire.description = Connects power blocks and distributes power between them.
block.fos-tin-wire.details = Not ideal for long-range connections because of high resistance. Consider upgrading to better wires when possible.
Expand Down
18 changes: 15 additions & 3 deletions res/bundles/bundle_ru.properties
Original file line number Diff line number Diff line change
Expand Up @@ -141,10 +141,22 @@ block.fos-tin-bridge.name = Оловянный мостовой конвейер
block.fos-tin-bridge.description = Перемещает предметы над местностью или зданиями.
block.fos-tin-belt.name = Оловянная лента
block.fos-tin-belt.description = Перемещает предметы вперед.
block.fos-fluid-pipe.name = Трубопровод
block.fos-fluid-pipe.description = Транспортирует жидкости и газы.
block.fos-pumpjack.name = Поверхностный насос
block.fos-copper-pipe.name = Медная труба
block.fos-copper-pipe.description = Переносит жидкости и газы вперед.
block.fos-brass-pipe.name = Латунная труба
block.fos-brass-pipe.description = Переносит жидкости и газы вперед. Не принимает ввод по бокам.
block.fos-fluid-junction.name = Жидкостный перекресток
block.fos-fluid-junction.description = Действует как мост для двух пересекающихся труб.
block.fos-fluid-bridge.name = Мостовая труба
block.fos-fluid-bridge.description = Перемещает жидкости над любой местностью или зданиями.
block.fos-pumpjack.name = Штанговый насос
block.fos-pumpjack.description = Перекачивает и выводит жидкости. Не требует энергию.
block.fos-fluid-router.name = Жидкостный маршрутизатор
block.fos-fluid-router.description = Принимает жидкости и газы равномерно распределяет их до 3 сторон. Также может хранить определенное количество жидкости.
block.fos-fluid-barrel.name = Жидкостная бочка
block.fos-fluid-barrel.description = Хранит небольшое количество жидкости. Выводит во все стороны, подобно жидкостному маршрутизатору.
block.fos-fluid-tank.name = Жидкостный бак
block.fos-fluid-tank.description = Хранит большое количество жидкости. Выводит во все стороны, подобно жидкостному маршрутизатору.
block.fos-tin-wire.name = Оловянный провод
block.fos-tin-wire.description = Соединяет энергетические структуры и передает энергию между ними. Не подходит для соединения на дальних расстояниях.
block.fos-tin-wire.details = Не подходит для соединения на дальних расстояниях из-за высокого сопротивления. Постройте провода получше, когда возможно.
Expand Down
48 changes: 42 additions & 6 deletions src/fos/content/FOSBlocks.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
import mindustry.world.blocks.defense.turrets.*;
import mindustry.world.blocks.distribution.*;
import mindustry.world.blocks.environment.*;
import mindustry.world.blocks.liquid.Conduit;
import mindustry.world.blocks.liquid.*;
import mindustry.world.blocks.power.*;
import mindustry.world.blocks.production.*;
import mindustry.world.blocks.storage.Unloader;
Expand Down Expand Up @@ -63,7 +63,7 @@ public class FOSBlocks {
spaceDuct, spaceRouter, spaceBridge, itemCatapult, tinRouter, tinDistributor, tinJunction, tinBridge, tinBelt, tinSorter, flowGate, liquidConveyor,

// FLUIDS
fluidPipe, pumpjack,
copperPipe, brassPipe, fluidJunction, fluidBridge, pumpjack, fluidRouter, fluidBarrel, fluidTank,

// POWER
tinWire, copperWire, brassWire, tinWirePole, copperWirePole, brassWirePole, windTurbine, burnerGenerator, heatGenerator, plasmaLauncher, solarPanelMedium,
Expand Down Expand Up @@ -1310,11 +1310,30 @@ diamond, new MissileBulletType(5f, 5){{
}};
//endregion
//region liquids
fluidPipe = new Conduit("fluid-pipe"){{
health = 5;
size = 1;
copperPipe = new Conduit("copper-pipe"){{
health = 50;
liquidCapacity = 20f;
requirements(Category.liquid, with(copper, 2));
}};
brassPipe = new ArmoredConduit("brass-pipe"){{
health = 100;
liquidCapacity = 20f;
requirements(Category.liquid, with(tin, 1, silver, 1));
requirements(Category.liquid, with(brass, 1));
}};
fluidJunction = new LiquidJunction("fluid-junction"){{
health = 50;
solid = false;
requirements(Category.liquid, with(tin, 5, copper, 5));
((Conduit)copperPipe).junctionReplacement = this;
((Conduit)brassPipe).junctionReplacement = this;
}};
fluidBridge = new LiquidBridge("fluid-bridge"){{
health = 100;
range = 4;
liquidCapacity = 20f;
requirements(Category.liquid, with(tin, 5, copper, 10));
((Conduit)copperPipe).bridgeReplacement = this;
((Conduit)brassPipe).bridgeReplacement = this;
}};
pumpjack = new Pump("pumpjack"){{
scaledHealth = 60;
Expand All @@ -1323,6 +1342,23 @@ diamond, new MissileBulletType(5f, 5){{
liquidCapacity = 45f;
requirements(Category.liquid, with(tin, 150, silicon, 50, copper, 100, vanadium, 75));
}};
fluidRouter = new LiquidRouter("fluid-router"){{
scaledHealth = 75;
liquidCapacity = 30f;
requirements(Category.liquid, with(copper, 3));
}};
fluidBarrel = new LiquidRouter("fluid-barrel"){{
scaledHealth = 75;
size = 2;
liquidCapacity = 300f;
requirements(Category.liquid, with(copper, 15, brass, 10));
}};
fluidTank = new LiquidRouter("fluid-tank"){{
scaledHealth = 75;
size = 3;
liquidCapacity = 1000f;
requirements(Category.liquid, with(copper, 50, brass, 50, vanadium, 50));
}};
//endregion
//region power
tinWire = new PowerWire("tin-wire"){{
Expand Down
16 changes: 14 additions & 2 deletions src/fos/content/LumoniTechTree.java
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,20 @@ public static void load() {
});
});

// FLUID PUMP(S?)
node(pumpjack);
// FLUIDS
node(pumpjack, () ->
node(copperPipe, () -> {
node(brassPipe);
node(fluidRouter, () -> {
node(fluidBarrel, () -> {
node(fluidTank);
});
});
node(fluidJunction, () ->
node(fluidBridge)
);
})
);

// ORE DETECTORS
node(oreDetector, () -> {
Expand Down
2 changes: 1 addition & 1 deletion src/fos/content/UxerdTechTree.java
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public static void load() {
node(solarPanelMedium);
node(resourceExtractor, () -> {
node(cliffDetonator);
node(sublimator, () -> node(fluidPipe));
node(sublimator, () -> node(copperPipe));
node(cuberiumSynthesizer, () -> {
/* TODO: move to Lumoni */ node(orbitalAccelerator, Seq.with(new Research(coreFortress)), () -> {});
node(bigBoy);
Expand Down

0 comments on commit 9096ca4

Please sign in to comment.