mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-23 15:48:34 +01:00
Added configuration for Phantom blocks
This commit is contained in:
parent
55827f10b3
commit
789bd76e0a
4 changed files with 9 additions and 7 deletions
|
@ -207,9 +207,9 @@ public final class InitBooklet{
|
|||
//No RF Using Blocks
|
||||
new BookletChapter("breaker", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockBreaker), new PageCrafting(1, BlockCrafting.recipeBreaker).setWildcard(), new PageCrafting(2, BlockCrafting.recipePlacer).setWildcard(), new PageCrafting(3, BlockCrafting.recipeLiquidPlacer).setWildcard(), new PageCrafting(4, BlockCrafting.recipeLiquidCollector).setWildcard());
|
||||
new BookletChapter("dropper", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockDropper), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeDropper).setNoText());
|
||||
new BookletChapter("phantomfaces", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomLiquiface), new PageTextOnly(1).addTextReplacement("<range>", TileEntityPhantomface.RANGE), new PageTextOnly(2), new PageCrafting(3, BlockCrafting.recipePhantomface), new PageCrafting(4, BlockCrafting.recipeLiquiface), new PageCrafting(5, BlockCrafting.recipeEnergyface), new PageCrafting(6, ItemCrafting.recipePhantomConnector).setNoText(), new PageCrafting(7, BlockCrafting.recipePhantomBooster)).setImportant();
|
||||
new BookletChapter("phantomfaces", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomLiquiface), new PageTextOnly(1).addTextReplacement("<range>", ConfigIntValues.PHANTOMFACE_WORK_RANGE.getValue()), new PageTextOnly(2), new PageCrafting(3, BlockCrafting.recipePhantomface), new PageCrafting(4, BlockCrafting.recipeLiquiface), new PageCrafting(5, BlockCrafting.recipeEnergyface), new PageCrafting(6, ItemCrafting.recipePhantomConnector).setNoText(), new PageCrafting(7, BlockCrafting.recipePhantomBooster)).setImportant();
|
||||
new BookletChapter("phantomRedstoneface", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomRedstoneface), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipePhantomRedstoneface).setNoText());
|
||||
new BookletChapter("phantomBreaker", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomBreaker), new PageTextOnly(1).addTextReplacement("<range>", TileEntityPhantomPlacer.RANGE), new PageCrafting(2, BlockCrafting.recipePhantomPlacer).setNoText(), new PageCrafting(3, BlockCrafting.recipePhantomBreaker).setNoText());
|
||||
new BookletChapter("phantomBreaker", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomBreaker), new PageTextOnly(1).addTextReplacement("<range>", ConfigIntValues.PHANTOM_PLACER_WORK_RANGE.getValue()), new PageCrafting(2, BlockCrafting.recipePhantomPlacer).setNoText(), new PageCrafting(3, BlockCrafting.recipePhantomBreaker).setNoText());
|
||||
new BookletChapter("esd", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockInputterAdvanced), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeESD).setNoText(), new PageCrafting(3, BlockCrafting.recipeAdvancedESD).setNoText()).setSpecial();
|
||||
new BookletChapter("xpSolidifier", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockXPSolidifier), new PageTextOnly(1).addItemsToPage(new ItemStack(InitItems.itemSolidifiedExperience)), new PageCrafting(2, BlockCrafting.recipeSolidifier).setNoText()).setImportant();
|
||||
new BookletChapter("greenhouseGlass", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockGreenhouseGlass), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeGlass));
|
||||
|
|
|
@ -98,7 +98,9 @@ public enum ConfigIntValues{
|
|||
SHOCK_ABSORBER_WORK_RANGE("Shock Absorber: Work Range", ConfigCategories.MACHINE_VALUES, 5, 1, 16, "Distance in block in which Shock Absorber protects blocks and entities."),
|
||||
PLAYER_INTERFACE_ENERGY_CAPACITY("Player Interface: Energy Capacity", ConfigCategories.MACHINE_ENERGY_VALUES, 30000, 1000, 1000000000, "Amount of energy Player Interface can store."),
|
||||
PLAYER_INTERFACE_ENERGY_RECEIVE("Player Interface: Energy Receive Rate", ConfigCategories.MACHINE_ENERGY_VALUES, 50, 1, 1000000000, "Amount of energy Player Interface can receive per tick.\nThis option defines rate of charging items in player's inventory."),
|
||||
PLAYER_INTERFACE_WORK_RANGE("Player Interface: Work Range", ConfigCategories.MACHINE_VALUES, 32, 1, 64, "Distance in block in which Player Interface works.");
|
||||
PLAYER_INTERFACE_WORK_RANGE("Player Interface: Work Range", ConfigCategories.MACHINE_VALUES, 32, 1, 64, "Distance in block in which Player Interface works."),
|
||||
PHANTOMFACE_WORK_RANGE("Phantomface: Work Range", ConfigCategories.MACHINE_VALUES, 16, 1, 32, "Distance in block in which Phantomface, Phantom Itemface, Phantom Liquidface, Phantom Energyface and Phantom Redstoneface work."),
|
||||
PHANTOM_PLACER_WORK_RANGE("Phantom Breaker/Placer: Work Range", ConfigCategories.MACHINE_VALUES, 3, 1, 8, "Distance in block in which Phantom Breaker and Placer work.");
|
||||
|
||||
public final String name;
|
||||
public final String category;
|
||||
|
|
|
@ -11,6 +11,7 @@
|
|||
package de.ellpeck.actuallyadditions.mod.tile;
|
||||
|
||||
import de.ellpeck.actuallyadditions.api.tile.IPhantomTile;
|
||||
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
|
||||
import de.ellpeck.actuallyadditions.mod.inventory.GuiHandler;
|
||||
import de.ellpeck.actuallyadditions.mod.network.gui.IButtonReactor;
|
||||
import de.ellpeck.actuallyadditions.mod.util.StackUtil;
|
||||
|
@ -28,7 +29,6 @@ import net.minecraftforge.fml.relauncher.SideOnly;
|
|||
|
||||
public class TileEntityPhantomPlacer extends TileEntityInventoryBase implements IPhantomTile, IButtonReactor{
|
||||
|
||||
public static final int RANGE = 3;
|
||||
public BlockPos boundPosition;
|
||||
public int currentTime;
|
||||
public int range;
|
||||
|
@ -83,7 +83,7 @@ public class TileEntityPhantomPlacer extends TileEntityInventoryBase implements
|
|||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!this.world.isRemote){
|
||||
this.range = TileEntityPhantomface.upgradeRange(RANGE, this.world, this.pos);
|
||||
this.range = TileEntityPhantomface.upgradeRange(ConfigIntValues.PHANTOM_PLACER_WORK_RANGE.getValue(), this.world, this.pos);
|
||||
|
||||
if(!this.hasBoundPosition()){
|
||||
this.boundPosition = null;
|
||||
|
|
|
@ -13,6 +13,7 @@ package de.ellpeck.actuallyadditions.mod.tile;
|
|||
import de.ellpeck.actuallyadditions.api.tile.IPhantomTile;
|
||||
import de.ellpeck.actuallyadditions.mod.blocks.BlockPhantom;
|
||||
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
||||
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
@ -27,7 +28,6 @@ import net.minecraftforge.fml.relauncher.SideOnly;
|
|||
|
||||
public abstract class TileEntityPhantomface extends TileEntityInventoryBase implements IPhantomTile{
|
||||
|
||||
public static final int RANGE = 16;
|
||||
public BlockPos boundPosition;
|
||||
public BlockPhantom.Type type;
|
||||
public int range;
|
||||
|
@ -86,7 +86,7 @@ public abstract class TileEntityPhantomface extends TileEntityInventoryBase impl
|
|||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!this.world.isRemote){
|
||||
this.range = upgradeRange(RANGE, this.world, this.getPos());
|
||||
this.range = upgradeRange(ConfigIntValues.PHANTOMFACE_WORK_RANGE.getValue(), this.world, this.getPos());
|
||||
|
||||
if(!this.hasBoundPosition()){
|
||||
this.boundPosition = null;
|
||||
|
|
Loading…
Reference in a new issue