|
| 1 | +/******************************************************************************* |
| 2 | + * Copyright 2024 Maximilian Stark | Dakror <mail@dakror.de> |
| 3 | + * |
| 4 | + * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | + * you may not use this file except in compliance with the License. |
| 6 | + * You may obtain a copy of the License at |
| 7 | + * |
| 8 | + * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | + * |
| 10 | + * Unless required by applicable law or agreed to in writing, software |
| 11 | + * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | + * See the License for the specific language governing permissions and |
| 14 | + * limitations under the License. |
| 15 | + ******************************************************************************/ |
| 16 | + |
| 17 | +package de.dakror.quarry.structure.producer; |
| 18 | + |
| 19 | +import de.dakror.quarry.Const; |
| 20 | +import de.dakror.quarry.game.Item.ItemType; |
| 21 | +import de.dakror.quarry.game.Item.Items; |
| 22 | +import de.dakror.quarry.game.Item.Items.Amount; |
| 23 | +import de.dakror.quarry.game.Science.ScienceType; |
| 24 | +import de.dakror.quarry.structure.base.Direction; |
| 25 | +import de.dakror.quarry.structure.base.Dock; |
| 26 | +import de.dakror.quarry.structure.base.Dock.DockFilter; |
| 27 | +import de.dakror.quarry.structure.base.Dock.DockType; |
| 28 | +import de.dakror.quarry.structure.base.ProducerStructure; |
| 29 | +import de.dakror.quarry.structure.base.RecipeList; |
| 30 | +import de.dakror.quarry.structure.base.StructureType; |
| 31 | +import de.dakror.quarry.util.Sfx; |
| 32 | + |
| 33 | +/** |
| 34 | + * @author Maximilian Stark | Dakror |
| 35 | + */ |
| 36 | +public class SteamCompressor extends ProducerStructure { |
| 37 | + public static final ProducerSchema classSchema = new ProducerSchema(0, StructureType.SteamCompressor, 3, 2, |
| 38 | + "steamcompressor", |
| 39 | + new Items(ItemType.MachineFrame, 6, ItemType.SteelIngot, 18, ItemType.CopperTube, 16, ItemType.Dynamo, 2), |
| 40 | + new RecipeList() { |
| 41 | + @Override |
| 42 | + protected void init() { |
| 43 | + add(new Recipe(3f, "pressurizedsteam", 350) |
| 44 | + .input(new Amount(ItemType.Steam, 5000)) |
| 45 | + .output(new Amount(ItemType.PressurizedSteam, 1200))); |
| 46 | + } |
| 47 | + }, |
| 48 | + new Sfx("compactor" + Const.SFX_FORMAT, 0.7f), |
| 49 | + true, |
| 50 | + new Dock(0, 1, Direction.West, DockType.FluidIn, new DockFilter(ItemType.Steam)), |
| 51 | + new Dock(2, 1, Direction.East, DockType.FluidOut, new DockFilter(ItemType.PressurizedSteam)), |
| 52 | + new Dock(1, 0, Direction.South, DockType.Power)) |
| 53 | + .sciences(ScienceType.Electricity, ScienceType.HighTech); |
| 54 | + |
| 55 | + public SteamCompressor(int x, int y) { |
| 56 | + super(x, y, classSchema); |
| 57 | + } |
| 58 | +} |
0 commit comments