Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Pylon is an upcoming Minecraft Java plugin that will hugely expand vanilla gamep

Pylon uses an addon system, meaning anyone can add content to Pylon by writing an addon for it! It also comes with a number of really useful features, such as:
- First-class translation support, meaning each player can select their own language.
- Extensive configuration options, including per-machine configuration.
- Extensive configuration options, including per-machine configuration
- An intuitive and user-friendly guide to help players figure out the plugin.

## Find out more
Expand Down
21 changes: 17 additions & 4 deletions src/main/java/io/github/pylonmc/pylon/base/BaseBlocks.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@
import io.github.pylonmc.pylon.base.content.building.ExplosiveTarget;
import io.github.pylonmc.pylon.base.content.building.Immobilizer;
import io.github.pylonmc.pylon.base.content.building.Pedestal;
import io.github.pylonmc.pylon.base.content.components.EnrichedSoulSoil;
import io.github.pylonmc.pylon.base.content.components.*;
import io.github.pylonmc.pylon.base.content.machines.cargo.CargoExtractor;
import io.github.pylonmc.pylon.base.content.machines.cargo.CargoInserter;
import io.github.pylonmc.pylon.base.content.machines.diesel.*;
import io.github.pylonmc.pylon.base.content.machines.cargo.CargoBuffer;
import io.github.pylonmc.pylon.base.content.machines.diesel.machines.*;
import io.github.pylonmc.pylon.base.content.machines.diesel.production.Biorefinery;
import io.github.pylonmc.pylon.base.content.machines.diesel.production.Fermenter;
import io.github.pylonmc.pylon.base.content.machines.fluid.*;
import io.github.pylonmc.pylon.base.content.machines.hydraulics.*;
import io.github.pylonmc.pylon.base.content.machines.hydraulics.CoalFiredPurificationTower;
Expand Down Expand Up @@ -58,6 +60,10 @@ public static void initialize() {
PylonBlock.register(BaseKeys.FLUID_TANK_CASING_BRONZE, Material.ORANGE_STAINED_GLASS, FluidTankCasing.class);
PylonBlock.register(BaseKeys.FLUID_TANK_CASING_IGNEOUS_COMPOSITE, Material.BLACK_STAINED_GLASS, FluidTankCasing.class);
PylonBlock.register(BaseKeys.FLUID_TANK_CASING_STEEL, Material.GRAY_STAINED_GLASS, FluidTankCasing.class);
PylonBlock.register(BaseKeys.FLUID_INPUT_HATCH, Material.LIGHT_BLUE_TERRACOTTA, FluidInputHatch.class);
PylonBlock.register(BaseKeys.FLUID_OUTPUT_HATCH, Material.ORANGE_TERRACOTTA, FluidOutputHatch.class);
PylonBlock.register(BaseKeys.ITEM_INPUT_HATCH, Material.GREEN_TERRACOTTA, ItemInputHatch.class);
PylonBlock.register(BaseKeys.ITEM_OUTPUT_HATCH, Material.RED_TERRACOTTA, ItemOutputHatch.class);
PylonBlock.register(BaseKeys.FLUID_VALVE, Material.STRUCTURE_VOID, FluidValve.class);
PylonBlock.register(BaseKeys.WATER_PUMP, Material.BLUE_TERRACOTTA, WaterPump.class);
PylonBlock.register(BaseKeys.FLUID_FILTER, Material.STRUCTURE_VOID, FluidFilter.class);
Expand Down Expand Up @@ -112,8 +118,6 @@ public static void initialize() {
PylonBlock.register(BaseKeys.MANUAL_CORE_DRILL, Material.CHISELED_STONE_BRICKS, ManualCoreDrill.class);
PylonBlock.register(BaseKeys.IMPROVED_MANUAL_CORE_DRILL, Material.WAXED_OXIDIZED_COPPER, ImprovedManualCoreDrill.class);
PylonBlock.register(BaseKeys.HYDRAULIC_CORE_DRILL, Material.WAXED_COPPER_BULB, HydraulicCoreDrill.class);
PylonBlock.register(BaseKeys.HYDRAULIC_CORE_DRILL_INPUT_HATCH, Material.LIGHT_BLUE_TERRACOTTA, HydraulicCoreDrillInputHatch.class);
PylonBlock.register(BaseKeys.HYDRAULIC_CORE_DRILL_OUTPUT_HATCH, Material.ORANGE_TERRACOTTA, HydraulicCoreDrillOutputHatch.class);
PylonBlock.register(BaseKeys.VACUUM_HOPPER_1, Material.HOPPER, VacuumHopper.class);
PylonBlock.register(BaseKeys.VACUUM_HOPPER_2, Material.HOPPER, VacuumHopper.class);
PylonBlock.register(BaseKeys.VACUUM_HOPPER_3, Material.HOPPER, VacuumHopper.class);
Expand All @@ -132,6 +136,15 @@ public static void initialize() {
PylonBlock.register(BaseKeys.DIESEL_FURNACE, Material.FURNACE, DieselFurnace.class);
PylonBlock.register(BaseKeys.DIESEL_BREAKER, Material.DROPPER, DieselBreaker.class);
PylonBlock.register(BaseKeys.DIESEL_MINER, Material.IRON_BLOCK, DieselMiner.class);
PylonBlock.register(BaseKeys.FERMENTER, Material.PINK_TERRACOTTA, Fermenter.class);
PylonBlock.register(BaseKeys.FERMENTER_CORE, Material.GRAY_STAINED_GLASS, PylonBlock.class);
PylonBlock.register(BaseKeys.FERMENTER_CASING, Material.GRAY_STAINED_GLASS_PANE, PylonBlock.class);
PylonBlock.register(BaseKeys.BIOREFINERY, Material.PURPLE_TERRACOTTA, Biorefinery.class);
PylonBlock.register(BaseKeys.BIOREFINERY_FOUNDATION, Material.LIGHT_GRAY_CONCRETE, PylonBlock.class);
PylonBlock.register(BaseKeys.BIOREFINERY_PLATING, Material.GRAY_STAINED_GLASS_PANE, PylonBlock.class);
PylonBlock.register(BaseKeys.BIOREFINERY_TOWER_RING, Material.IRON_BLOCK, PylonBlock.class);
PylonBlock.register(BaseKeys.BIOREFINERY_SMOKESTACK_RING, Material.POLISHED_DEEPSLATE_WALL, PylonBlock.class);
PylonBlock.register(BaseKeys.BIOREFINERY_SMOKESTACK_CAP, Material.FLOWER_POT, PylonBlock.class);
PylonBlock.register(BaseKeys.CARGO_DUCT, Material.STRUCTURE_VOID, CargoDuct.class);
PylonBlock.register(BaseKeys.CARGO_BUFFER, Material.STRUCTURE_VOID, CargoBuffer.class);
PylonBlock.register(BaseKeys.CARGO_EXTRACTOR, Material.STRUCTURE_VOID, CargoExtractor.class);
Expand Down
17 changes: 17 additions & 0 deletions src/main/java/io/github/pylonmc/pylon/base/BaseFluids.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import io.github.pylonmc.pylon.base.content.machines.smelting.Slurry;
import io.github.pylonmc.pylon.base.recipes.CastingRecipe;
import io.github.pylonmc.pylon.base.recipes.MeltingRecipe;
import io.github.pylonmc.pylon.core.content.guide.PylonGuide;
import io.github.pylonmc.pylon.core.fluid.PylonFluid;
import io.github.pylonmc.pylon.core.fluid.tags.FluidTemperature;
import io.github.pylonmc.pylon.core.recipe.RecipeInput;
Expand Down Expand Up @@ -150,6 +151,16 @@ private BaseFluids() {
Material.WHITE_CONCRETE_POWDER
).addTag(FluidTemperature.NORMAL);

public static final PylonFluid SUGARCANE = new PylonFluid(
baseKey("sugarcane"),
Material.LIME_CONCRETE
).addTag(FluidTemperature.NORMAL);

public static final PylonFluid ETHANOL = new PylonFluid(
baseKey("ethanol"),
Material.LIGHT_GRAY_CONCRETE_POWDER
).addTag(FluidTemperature.NORMAL);

public static final PylonFluid BIODIESEL = new PylonFluid(
baseKey("biodiesel"),
Material.YELLOW_CONCRETE
Expand Down Expand Up @@ -273,6 +284,12 @@ public static void initialize() {

REFLECTOR_FLUID.register();

SUGARCANE.register();

PylonGuide.hideFluid(SUGARCANE.getKey());

ETHANOL.register();

BIODIESEL.register();
}

Expand Down
109 changes: 94 additions & 15 deletions src/main/java/io/github/pylonmc/pylon/base/BaseItems.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
import io.github.pylonmc.pylon.base.content.machines.cargo.CargoBuffer;
import io.github.pylonmc.pylon.base.content.machines.cargo.CargoExtractor;
import io.github.pylonmc.pylon.base.content.machines.cargo.CargoInserter;
import io.github.pylonmc.pylon.base.content.machines.diesel.*;
import io.github.pylonmc.pylon.base.content.machines.diesel.machines.*;
import io.github.pylonmc.pylon.base.content.machines.diesel.production.Biorefinery;
import io.github.pylonmc.pylon.base.content.machines.diesel.production.Fermenter;
import io.github.pylonmc.pylon.base.content.machines.fluid.*;
import io.github.pylonmc.pylon.base.content.machines.hydraulics.*;
import io.github.pylonmc.pylon.base.content.machines.hydraulics.CoalFiredPurificationTower;
Expand Down Expand Up @@ -1093,6 +1095,34 @@ private BaseItems() {
BasePages.FLUID_PIPES_AND_TANKS.addItem(FLUID_TANK_CASING_STEEL);
}

public static final ItemStack FLUID_INPUT_HATCH = ItemStackBuilder.pylon(Material.LIGHT_BLUE_TERRACOTTA, BaseKeys.FLUID_INPUT_HATCH)
.build();
static {
PylonItem.register(PylonItem.class, FLUID_INPUT_HATCH, BaseKeys.FLUID_INPUT_HATCH);
BasePages.COMPONENTS.addItem(FLUID_INPUT_HATCH);
}

public static final ItemStack FLUID_OUTPUT_HATCH = ItemStackBuilder.pylon(Material.ORANGE_TERRACOTTA, BaseKeys.FLUID_OUTPUT_HATCH)
.build();
static {
PylonItem.register(PylonItem.class, FLUID_OUTPUT_HATCH, BaseKeys.FLUID_OUTPUT_HATCH);
BasePages.COMPONENTS.addItem(FLUID_OUTPUT_HATCH);
}

public static final ItemStack ITEM_INPUT_HATCH = ItemStackBuilder.pylon(Material.GREEN_TERRACOTTA, BaseKeys.ITEM_INPUT_HATCH)
.build();
static {
PylonItem.register(PylonItem.class, ITEM_INPUT_HATCH, BaseKeys.ITEM_INPUT_HATCH);
BasePages.COMPONENTS.addItem(ITEM_INPUT_HATCH);
}

public static final ItemStack ITEM_OUTPUT_HATCH = ItemStackBuilder.pylon(Material.RED_TERRACOTTA, BaseKeys.ITEM_OUTPUT_HATCH)
.build();
static {
PylonItem.register(PylonItem.class, ITEM_OUTPUT_HATCH, BaseKeys.ITEM_OUTPUT_HATCH);
BasePages.COMPONENTS.addItem(ITEM_OUTPUT_HATCH);
}

public static final ItemStack ROTOR = ItemStackBuilder.pylon(Material.IRON_TRAPDOOR, BaseKeys.ROTOR)
.build();
static {
Expand Down Expand Up @@ -1663,20 +1693,6 @@ private BaseItems() {
BasePages.HYDRAULICS.addItem(HYDRAULIC_CORE_DRILL);
}

public static final ItemStack HYDRAULIC_CORE_DRILL_INPUT_HATCH = ItemStackBuilder.pylon(Material.LIGHT_BLUE_TERRACOTTA, BaseKeys.HYDRAULIC_CORE_DRILL_INPUT_HATCH)
.build();
static {
PylonItem.register(PylonItem.class, HYDRAULIC_CORE_DRILL_INPUT_HATCH, BaseKeys.HYDRAULIC_CORE_DRILL_INPUT_HATCH);
BasePages.HYDRAULICS.addItem(HYDRAULIC_CORE_DRILL_INPUT_HATCH);
}

public static final ItemStack HYDRAULIC_CORE_DRILL_OUTPUT_HATCH = ItemStackBuilder.pylon(Material.ORANGE_TERRACOTTA, BaseKeys.HYDRAULIC_CORE_DRILL_OUTPUT_HATCH)
.build();
static {
PylonItem.register(PylonItem.class, HYDRAULIC_CORE_DRILL_OUTPUT_HATCH, BaseKeys.HYDRAULIC_CORE_DRILL_OUTPUT_HATCH);
BasePages.HYDRAULICS.addItem(HYDRAULIC_CORE_DRILL_OUTPUT_HATCH);
}

public static final ItemStack REACTIVATED_WITHER_SKULL = ItemStackBuilder.pylon(Material.WITHER_SKELETON_SKULL, BaseKeys.REACTIVATED_WITHER_SKULL)
.durability(Settings.get(BaseKeys.REACTIVATED_WITHER_SKULL).getOrThrow("durability", ConfigAdapter.INT))
.useCooldown(Settings.get(BaseKeys.REACTIVATED_WITHER_SKULL).getOrThrow("cooldown-ticks", ConfigAdapter.INT), BaseKeys.REACTIVATED_WITHER_SKULL)
Expand Down Expand Up @@ -1903,6 +1919,69 @@ private BaseItems() {
BasePages.DIESEL_MACHINES.addItem(DIESEL_MINER);
}

public static final ItemStack FERMENTER = ItemStackBuilder.pylon(Material.PINK_TERRACOTTA, BaseKeys.FERMENTER)
.build();
static {
PylonItem.register(Fermenter.Item.class, FERMENTER, BaseKeys.FERMENTER);
BasePages.DIESEL_PRODUCTION.addItem(FERMENTER);
}

public static final ItemStack FERMENTER_CORE = ItemStackBuilder.pylon(Material.GRAY_STAINED_GLASS, BaseKeys.FERMENTER_CORE)
.build();
static {
PylonItem.register(PylonItem.class, FERMENTER_CORE, BaseKeys.FERMENTER_CORE);
BasePages.DIESEL_PRODUCTION.addItem(FERMENTER_CORE);
}

public static final ItemStack FERMENTER_CASING = ItemStackBuilder.pylon(Material.GRAY_STAINED_GLASS_PANE, BaseKeys.FERMENTER_CASING)
.build();
static {
PylonItem.register(PylonItem.class, FERMENTER_CASING, BaseKeys.FERMENTER_CASING);
BasePages.DIESEL_PRODUCTION.addItem(FERMENTER_CASING);
}

public static final ItemStack BIOREFINERY = ItemStackBuilder.pylon(Material.PURPLE_TERRACOTTA, BaseKeys.BIOREFINERY)
.build();
static {
PylonItem.register(Biorefinery.Item.class, BIOREFINERY, BaseKeys.BIOREFINERY);
BasePages.DIESEL_PRODUCTION.addItem(BIOREFINERY);
}

public static final ItemStack BIOREFINERY_FOUNDATION = ItemStackBuilder.pylon(Material.LIGHT_GRAY_CONCRETE, BaseKeys.BIOREFINERY_FOUNDATION)
.build();
static {
PylonItem.register(PylonItem.class, BIOREFINERY_FOUNDATION, BaseKeys.BIOREFINERY_FOUNDATION);
BasePages.DIESEL_PRODUCTION.addItem(BIOREFINERY_FOUNDATION);
}

public static final ItemStack BIOREFINERY_PLATING = ItemStackBuilder.pylon(Material.GRAY_STAINED_GLASS_PANE, BaseKeys.BIOREFINERY_PLATING)
.build();
static {
PylonItem.register(PylonItem.class, BIOREFINERY_PLATING, BaseKeys.BIOREFINERY_PLATING);
BasePages.DIESEL_PRODUCTION.addItem(BIOREFINERY_PLATING);
}

public static final ItemStack BIOREFINERY_TOWER_RING = ItemStackBuilder.pylon(Material.IRON_BLOCK, BaseKeys.BIOREFINERY_TOWER_RING)
.build();
static {
PylonItem.register(PylonItem.class, BIOREFINERY_TOWER_RING, BaseKeys.BIOREFINERY_TOWER_RING);
BasePages.DIESEL_PRODUCTION.addItem(BIOREFINERY_TOWER_RING);
}

public static final ItemStack BIOREFINERY_SMOKESTACK_RING = ItemStackBuilder.pylon(Material.POLISHED_DEEPSLATE_WALL, BaseKeys.BIOREFINERY_SMOKESTACK_RING)
.build();
static {
PylonItem.register(PylonItem.class, BIOREFINERY_SMOKESTACK_RING, BaseKeys.BIOREFINERY_SMOKESTACK_RING);
BasePages.DIESEL_PRODUCTION.addItem(BIOREFINERY_SMOKESTACK_RING);
}

public static final ItemStack BIOREFINERY_SMOKESTACK_CAP = ItemStackBuilder.pylon(Material.FLOWER_POT, BaseKeys.BIOREFINERY_SMOKESTACK_CAP)
.build();
static {
PylonItem.register(PylonItem.class, BIOREFINERY_SMOKESTACK_CAP, BaseKeys.BIOREFINERY_SMOKESTACK_CAP);
BasePages.DIESEL_PRODUCTION.addItem(BIOREFINERY_SMOKESTACK_CAP);
}

public static final ItemStack CARGO_DUCT = ItemStackBuilder.pylon(Material.STRUCTURE_VOID, BaseKeys.CARGO_DUCT)
.set(DataComponentTypes.ITEM_MODEL, Material.GRAY_CONCRETE.getKey())
.build();
Expand Down
18 changes: 16 additions & 2 deletions src/main/java/io/github/pylonmc/pylon/base/BaseKeys.java
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,11 @@ public class BaseKeys {
public static final NamespacedKey FLUID_TANK_CASING_IGNEOUS_COMPOSITE = baseKey("fluid_tank_casing_igneous_composite");
public static final NamespacedKey FLUID_TANK_CASING_STEEL = baseKey("fluid_tank_casing_steel");

public static final NamespacedKey FLUID_INPUT_HATCH = baseKey("fluid_input_hatch");
public static final NamespacedKey FLUID_OUTPUT_HATCH = baseKey("fluid_output_hatch");
public static final NamespacedKey ITEM_INPUT_HATCH = baseKey("item_input_hatch");
public static final NamespacedKey ITEM_OUTPUT_HATCH = baseKey("item_output_hatch");

public static final NamespacedKey WATER_PUMP = baseKey("water_pump");

public static final NamespacedKey FLUID_VALVE = baseKey("fluid_valve");
Expand Down Expand Up @@ -259,8 +264,6 @@ public class BaseKeys {
public static final NamespacedKey IMPROVED_MANUAL_CORE_DRILL = baseKey("improved_manual_core_drill");

public static final NamespacedKey HYDRAULIC_CORE_DRILL = baseKey("hydraulic_core_drill");
public static final NamespacedKey HYDRAULIC_CORE_DRILL_INPUT_HATCH = baseKey("hydraulic_core_drill_input_hatch");
public static final NamespacedKey HYDRAULIC_CORE_DRILL_OUTPUT_HATCH = baseKey("hydraulic_core_drill_output_hatch");

public static final NamespacedKey SHALLOW_CORE_CHUNK = baseKey("shallow_core_chunk");
public static final NamespacedKey SUBSURFACE_CORE_CHUNK = baseKey("subsurface_core_chunk");
Expand Down Expand Up @@ -303,6 +306,17 @@ public class BaseKeys {
public static final NamespacedKey DIESEL_BREAKER = baseKey("diesel_breaker");
public static final NamespacedKey DIESEL_MINER = baseKey("diesel_miner");

public static final NamespacedKey FERMENTER = baseKey("fermenter");
public static final NamespacedKey FERMENTER_CORE = baseKey("fermenter_core");
public static final NamespacedKey FERMENTER_CASING = baseKey("fermenter_casing");

public static final NamespacedKey BIOREFINERY = baseKey("biorefinery");
public static final NamespacedKey BIOREFINERY_FOUNDATION = baseKey("biorefinery_foundation");
public static final NamespacedKey BIOREFINERY_PLATING = baseKey("biorefinery_plating");
public static final NamespacedKey BIOREFINERY_TOWER_RING = baseKey("biorefinery_tower_ring");
public static final NamespacedKey BIOREFINERY_SMOKESTACK_RING = baseKey("biorefinery_smokestack_ring");
public static final NamespacedKey BIOREFINERY_SMOKESTACK_CAP = baseKey("biorefinery_smokestack_cap");

public static final NamespacedKey CARGO_BUFFER = baseKey("cargo_buffer");
public static final NamespacedKey CARGO_DUCT = baseKey("cargo_duct");
public static final NamespacedKey CARGO_EXTRACTOR = baseKey("cargo_extractor");
Expand Down
2 changes: 2 additions & 0 deletions src/main/java/io/github/pylonmc/pylon/base/BasePages.java
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ public class BasePages {
public static final SimpleStaticGuidePage HYDRAULICS = new SimpleStaticGuidePage(baseKey("hydraulics"), Material.BLUE_CONCRETE_POWDER);
public static final SimpleStaticGuidePage CARGO = new SimpleStaticGuidePage(baseKey("cargo"), Material.HOPPER);
public static final SimpleStaticGuidePage DIESEL_MACHINES = new SimpleStaticGuidePage(baseKey("diesel_machines"), Material.YELLOW_CONCRETE);
public static final SimpleStaticGuidePage DIESEL_PRODUCTION = new SimpleStaticGuidePage(baseKey("diesel_production"), Material.YELLOW_CONCRETE_POWDER);
private static final SimpleStaticGuidePage MACHINES = new SimpleStaticGuidePage(baseKey("machines"), Material.BLAST_FURNACE);

public static final SimpleStaticGuidePage BUILDING = new SimpleStaticGuidePage(baseKey("building"), Material.STONE_BRICK_WALL);
Expand Down Expand Up @@ -52,6 +53,7 @@ public boolean shouldDisplay(@NotNull Player player) {
MACHINES.addPage(HYDRAULICS);
MACHINES.addPage(CARGO);
MACHINES.addPage(DIESEL_MACHINES);
MACHINES.addPage(DIESEL_PRODUCTION);
PylonGuide.getRootPage().addPage(MACHINES);

PylonGuide.getRootPage().addPage(BUILDING);
Expand Down
Loading