mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-12-22 19:39:24 +01:00
You will be like "wat." when I tell ya that
I removed lots of config options!
This commit is contained in:
parent
61ab865eb8
commit
85ea472b1d
55 changed files with 316 additions and 556 deletions
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.blocks;
|
|||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.ItemFertilizer;
|
||||
import ellpeck.actuallyadditions.items.ItemMisc;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheMiscItems;
|
||||
|
@ -89,7 +88,7 @@ public class BlockCompost extends BlockContainerBase implements IActAddItemOrBlo
|
|||
ItemStack stackPlayer = player.getCurrentEquippedItem();
|
||||
TileEntityCompost tile = (TileEntityCompost)world.getTileEntity(x, y, z);
|
||||
//Add items to be composted
|
||||
if(stackPlayer != null && stackPlayer.getItem() instanceof ItemMisc && stackPlayer.getItemDamage() == TheMiscItems.MASHED_FOOD.ordinal() && (tile.slots[0] == null || (!(tile.slots[0].getItem() instanceof ItemFertilizer) && tile.slots[0].stackSize < ConfigIntValues.COMPOST_AMOUNT.getValue()))){
|
||||
if(stackPlayer != null && stackPlayer.getItem() instanceof ItemMisc && stackPlayer.getItemDamage() == TheMiscItems.MASHED_FOOD.ordinal() && (tile.slots[0] == null || (!(tile.slots[0].getItem() instanceof ItemFertilizer) && tile.slots[0].stackSize < TileEntityCompost.AMOUNT))){
|
||||
if(tile.slots[0] == null){
|
||||
tile.slots[0] = new ItemStack(stackPlayer.getItem(), 1, TheMiscItems.MASHED_FOOD.ordinal());
|
||||
}
|
||||
|
|
|
@ -13,7 +13,6 @@ package ellpeck.actuallyadditions.blocks;
|
|||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.ActuallyAdditions;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.proxy.ClientProxy;
|
||||
import ellpeck.actuallyadditions.tile.*;
|
||||
import ellpeck.actuallyadditions.util.IActAddItemOrBlock;
|
||||
|
@ -49,10 +48,10 @@ public class BlockPhantom extends BlockContainerBase implements IActAddItemOrBlo
|
|||
this.setStepSound(soundTypeStone);
|
||||
|
||||
if(type == Type.FACE || type == Type.LIQUIFACE || type == Type.ENERGYFACE){
|
||||
this.range = ConfigIntValues.PHANTOMFACE_RANGE.getValue();
|
||||
this.range = TileEntityPhantomface.RANGE;
|
||||
}
|
||||
else if(type == Type.BREAKER || type == Type.PLACER){
|
||||
this.range = ConfigIntValues.PHANTOM_PLACER_RANGE.getValue();
|
||||
this.range = TileEntityPhantomPlacer.RANGE;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
package ellpeck.actuallyadditions.blocks.render.model;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.tile.TileEntityCompost;
|
||||
import net.minecraft.client.model.ModelRenderer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
|
||||
|
@ -71,15 +71,15 @@ public class ModelCompost extends ModelBaseAA{
|
|||
@Override
|
||||
public void renderExtra(float f, TileEntity tile){
|
||||
int meta = tile.getWorldObj().getBlockMetadata(tile.xCoord, tile.yCoord, tile.zCoord);
|
||||
if(meta > 0 && meta <= ConfigIntValues.COMPOST_AMOUNT.getValue()){
|
||||
int heightToDisplay = meta*13/ConfigIntValues.COMPOST_AMOUNT.getValue();
|
||||
if(meta > 0 && meta <= TileEntityCompost.AMOUNT){
|
||||
int heightToDisplay = meta*13/TileEntityCompost.AMOUNT;
|
||||
if(heightToDisplay > 13){
|
||||
heightToDisplay = 13;
|
||||
}
|
||||
|
||||
this.innerRawList[heightToDisplay-1].render(f);
|
||||
}
|
||||
else if(meta == ConfigIntValues.COMPOST_AMOUNT.getValue()+1){
|
||||
else if(meta == TileEntityCompost.AMOUNT+1){
|
||||
this.innerDone.render(f);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,11 +21,13 @@ import ellpeck.actuallyadditions.booklet.entry.BookletEntryAllSearch;
|
|||
import ellpeck.actuallyadditions.booklet.page.*;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.crafting.*;
|
||||
import ellpeck.actuallyadditions.gen.OreGen;
|
||||
import ellpeck.actuallyadditions.items.InitItems;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheFoods;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheMiscItems;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheSpecialDrops;
|
||||
import ellpeck.actuallyadditions.recipe.ReconstructorRecipeHandler;
|
||||
import ellpeck.actuallyadditions.tile.*;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.crafting.IRecipe;
|
||||
|
@ -55,15 +57,15 @@ public class InitBooklet{
|
|||
//Getting Started
|
||||
chapterIntro = new BookletChapter("intro", entryGettingStarted, new ItemStack(InitItems.itemLexicon), new PageTextOnly(1), new PageTextOnly(2), new PageTextOnly(3));
|
||||
new BookletChapter("bookTutorial", entryGettingStarted, new ItemStack(InitItems.itemLexicon), new PageTextOnly(1), new PageTextOnly(2), new PageCrafting(3, ItemCrafting.recipeBook));
|
||||
new BookletChapter("crystals", entryGettingStarted, new ItemStack(InitBlocks.blockAtomicReconstructor), new PageTextOnly(1).addTextReplacement("<rf>", ConfigIntValues.RECONSTRUCTOR_BASE_ENERGY_USE.getValue()), new PageTextOnly(2), new PagePicture(3, "pageAtomicReconstructor", 0).setNoText(), new PageTextOnly(4), new PageCrafting(5, BlockCrafting.recipeAtomicReconstructor).setNoText(), new PageCrafting(6, MiscCrafting.recipesCrystals).setNoText(), new PageCrafting(7, MiscCrafting.recipesCrystalBlocks).setNoText(), new PageReconstructor(8, ReconstructorRecipeHandler.mainPageRecipes).setNoText()).setSpecial();
|
||||
new BookletChapter("coalGen", entryGettingStarted, new ItemStack(InitBlocks.blockCoalGenerator), new PageCrafting(1, BlockCrafting.recipeCoalGen).addTextReplacement("<rf>", ConfigIntValues.COAL_GEN_ENERGY_PRODUCED.getValue()));
|
||||
new BookletChapter("crystals", entryGettingStarted, new ItemStack(InitBlocks.blockAtomicReconstructor), new PageTextOnly(1).addTextReplacement("<rf>", TileEntityAtomicReconstructor.ENERGY_USE), new PageTextOnly(2), new PagePicture(3, "pageAtomicReconstructor", 0).setNoText(), new PageTextOnly(4), new PageCrafting(5, BlockCrafting.recipeAtomicReconstructor).setNoText(), new PageCrafting(6, MiscCrafting.recipesCrystals).setNoText(), new PageCrafting(7, MiscCrafting.recipesCrystalBlocks).setNoText(), new PageReconstructor(8, ReconstructorRecipeHandler.mainPageRecipes).setNoText()).setSpecial();
|
||||
new BookletChapter("coalGen", entryGettingStarted, new ItemStack(InitBlocks.blockCoalGenerator), new PageCrafting(1, BlockCrafting.recipeCoalGen).addTextReplacement("<rf>", TileEntityCoalGenerator.PRODUCE));
|
||||
new BookletChapter("craftingIngs", entryGettingStarted, new ItemStack(InitItems.itemMisc, 1, TheMiscItems.COIL.ordinal()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeCoil).setNoText(), new PageCrafting(3, ItemCrafting.recipeCoilAdvanced).setNoText(), new PageCrafting(4, BlockCrafting.recipeCase).setNoText(), new PageCrafting(5, BlockCrafting.recipeStoneCase).setNoText(), new PageCrafting(6, BlockCrafting.recipeEnderPearlBlock).setNoText(), new PageCrafting(7, BlockCrafting.recipeEnderCase).setNoText(), new PageCrafting(8, ItemCrafting.recipeRing).setNoText(), new PageCrafting(9, ItemCrafting.recipeKnifeHandle).setNoText(), new PageCrafting(10, ItemCrafting.recipeKnifeBlade).setNoText(), new PageCrafting(11, ItemCrafting.recipeKnife).setNoText(), new PageCrafting(12, ItemCrafting.recipeDough).setNoText(), new PageCrafting(13, ItemCrafting.recipeRiceDough).setNoText(), new PageCrafting(14, BlockCrafting.recipeIronCase).setNoText()).setImportant();
|
||||
|
||||
//Miscellaneous
|
||||
new BookletChapter("reconstructorLenses", entryMisc, new ItemStack(InitItems.itemMisc, 1, TheMiscItems.LENS.ordinal()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeLens).setNoText(), new PageReconstructor(3, ReconstructorRecipeHandler.recipeColorLens), new PageReconstructor(4, ReconstructorRecipeHandler.colorConversionRecipes).setNoText(), new PageReconstructor(5, ReconstructorRecipeHandler.recipeExplosionLens)).setImportant();
|
||||
new BookletChapter("miscDecorStuffsAndThings", entryMisc, new ItemStack(InitBlocks.blockTestifiBucksGreenWall), new PageTextOnly(1), new PageReconstructor(2, ReconstructorRecipeHandler.recipeWhiteWall).setNoText(), new PageReconstructor(3, ReconstructorRecipeHandler.recipeGreenWall).setNoText());
|
||||
new BookletChapter("bookStand", entryMisc, new ItemStack(InitBlocks.blockBookletStand), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeBookStand));
|
||||
new BookletChapter("quartz", entryMisc, new ItemStack(InitItems.itemMisc, 1, TheMiscItems.QUARTZ.ordinal()), new PageTextOnly(1).setStack(new ItemStack(InitBlocks.blockMisc, 1, TheMiscBlocks.ORE_QUARTZ.ordinal())).addTextReplacement("<lowest>", ConfigIntValues.BLACK_QUARTZ_MIN_HEIGHT.getValue()).addTextReplacement("<highest>", ConfigIntValues.BLACK_QUARTZ_MAX_HEIGHT.getValue()), new PageTextOnly(2).setStack(new ItemStack(InitItems.itemMisc, 1, TheMiscItems.QUARTZ.ordinal())), new PageCrafting(3, BlockCrafting.recipeQuartzBlock).setNoText(), new PageCrafting(4, BlockCrafting.recipeQuartzPillar).setNoText(), new PageCrafting(5, BlockCrafting.recipeQuartzChiseled).setNoText());
|
||||
new BookletChapter("quartz", entryMisc, new ItemStack(InitItems.itemMisc, 1, TheMiscItems.QUARTZ.ordinal()), new PageTextOnly(1).setStack(new ItemStack(InitBlocks.blockMisc, 1, TheMiscBlocks.ORE_QUARTZ.ordinal())).addTextReplacement("<lowest>", OreGen.QUARTZ_MIN).addTextReplacement("<highest>", OreGen.QUARTZ_MAX), new PageTextOnly(2).setStack(new ItemStack(InitItems.itemMisc, 1, TheMiscItems.QUARTZ.ordinal())), new PageCrafting(3, BlockCrafting.recipeQuartzBlock).setNoText(), new PageCrafting(4, BlockCrafting.recipeQuartzPillar).setNoText(), new PageCrafting(5, BlockCrafting.recipeQuartzChiseled).setNoText());
|
||||
new BookletChapter("cloud", entryMisc, new ItemStack(InitBlocks.blockSmileyCloud), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeSmileyCloud).setNoText()).setSpecial();
|
||||
new BookletChapter("coalStuff", entryMisc, new ItemStack(InitItems.itemMisc, 1, TheMiscItems.TINY_COAL.ordinal()), new PageTextOnly(1), new PageCrafting(2, ItemCrafting.recipeTinyCoal).setNoText(), new PageCrafting(3, ItemCrafting.recipeTinyChar).setNoText(), new PageCrafting(4, BlockCrafting.recipeBlockChar).setNoText());
|
||||
ArrayList<BookletPage> lampPages = new ArrayList<BookletPage>();
|
||||
|
@ -81,32 +83,32 @@ public class InitBooklet{
|
|||
//No RF Using Blocks
|
||||
new BookletChapter("breaker", entryFunctionalNonRF, new ItemStack(InitBlocks.blockBreaker), new PageCrafting(1, BlockCrafting.recipeBreaker), new PageCrafting(2, BlockCrafting.recipePlacer), new PageCrafting(3, BlockCrafting.recipeLiquidPlacer), new PageCrafting(4, BlockCrafting.recipeLiquidCollector));
|
||||
new BookletChapter("dropper", entryFunctionalNonRF, new ItemStack(InitBlocks.blockDropper), new PageTextOnly(1), new PageCrafting(1, BlockCrafting.recipeDropper).setNoText());
|
||||
new BookletChapter("phantomfaces", entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomLiquiface), new PageTextOnly(1).addTextReplacement("<range>", ConfigIntValues.PHANTOMFACE_RANGE.getValue()), new PageCrafting(2, BlockCrafting.recipePhantomface), new PageCrafting(3, BlockCrafting.recipeLiquiface), new PageCrafting(4, BlockCrafting.recipeEnergyface), new PageCrafting(5, ItemCrafting.recipePhantomConnector).setNoText(), new PageCrafting(6, BlockCrafting.recipePhantomBooster)).setImportant();
|
||||
new BookletChapter("phantomBreaker", entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomBreaker), new PageTextOnly(1).addTextReplacement("<range>", ConfigIntValues.PHANTOM_PLACER_RANGE.getValue()), new PageCrafting(2, BlockCrafting.recipePhantomPlacer).setNoText(), new PageCrafting(3, BlockCrafting.recipePhantomBreaker).setNoText());
|
||||
new BookletChapter("phantomfaces", entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomLiquiface), new PageTextOnly(1).addTextReplacement("<range>", TileEntityPhantomface.RANGE), new PageCrafting(2, BlockCrafting.recipePhantomface), new PageCrafting(3, BlockCrafting.recipeLiquiface), new PageCrafting(4, BlockCrafting.recipeEnergyface), new PageCrafting(5, ItemCrafting.recipePhantomConnector).setNoText(), new PageCrafting(6, BlockCrafting.recipePhantomBooster)).setImportant();
|
||||
new BookletChapter("phantomBreaker", 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("esd", entryFunctionalNonRF, new ItemStack(InitBlocks.blockInputterAdvanced), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeESD).setNoText(), new PageCrafting(3, BlockCrafting.recipeAdvancedESD).setNoText()).setSpecial();
|
||||
new BookletChapter("xpSolidifier", entryFunctionalNonRF, new ItemStack(InitBlocks.blockXPSolidifier), new PageTextOnly(1).setStack(new ItemStack(InitItems.itemSpecialDrop, 1, TheSpecialDrops.SOLIDIFIED_EXPERIENCE.ordinal())), new PageCrafting(2, BlockCrafting.recipeSolidifier).setNoText()).setSpecial();
|
||||
new BookletChapter("greenhouseGlass", entryFunctionalNonRF, new ItemStack(InitBlocks.blockGreenhouseGlass), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeGlass).setNoText());
|
||||
new BookletChapter("fishingNet", entryFunctionalNonRF, new ItemStack(InitBlocks.blockFishingNet), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeFisher).setNoText());
|
||||
new BookletChapter("feeder", entryFunctionalNonRF, new ItemStack(InitBlocks.blockFeeder), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeFeeder).setNoText());
|
||||
new BookletChapter("compost", entryFunctionalNonRF, new ItemStack(InitBlocks.blockCompost), new PageTextOnly(1).setStack(new ItemStack(InitItems.itemFertilizer)).addTextReplacement("<num>", ConfigIntValues.COMPOST_AMOUNT.getValue()), new PageCrafting(2, BlockCrafting.recipeCompost).setNoText(), new PageCrafting(3, ItemCrafting.recipesMashedFood));
|
||||
new BookletChapter("compost", entryFunctionalNonRF, new ItemStack(InitBlocks.blockCompost), new PageTextOnly(1).setStack(new ItemStack(InitItems.itemFertilizer)).addTextReplacement("<num>", TileEntityCompost.AMOUNT), new PageCrafting(2, BlockCrafting.recipeCompost).setNoText(), new PageCrafting(3, ItemCrafting.recipesMashedFood));
|
||||
new BookletChapter("crate", entryFunctionalNonRF, new ItemStack(InitBlocks.blockGiantChest), new PageCrafting(1, BlockCrafting.recipeCrate), new PageCrafting(2, ItemCrafting.recipeChestToCrateUpgrade));
|
||||
new BookletChapter("rangedCollector", entryFunctionalNonRF, new ItemStack(InitBlocks.blockRangedCollector), new PageTextOnly(1).addTextReplacement("<range>", ConfigIntValues.RANGED_COLLECTOR_RANGE.getValue()), new PageCrafting(2, BlockCrafting.recipeRangedCollector).setNoText());
|
||||
new BookletChapter("rangedCollector", entryFunctionalNonRF, new ItemStack(InitBlocks.blockRangedCollector), new PageTextOnly(1).addTextReplacement("<range>", TileEntityRangedCollector.RANGE), new PageCrafting(2, BlockCrafting.recipeRangedCollector).setNoText());
|
||||
|
||||
//RF Using Blocks
|
||||
new BookletChapter("laserRelays", entryFunctionalRF, new ItemStack(InitBlocks.blockLaserRelay), new PageTextOnly(1).addTextReplacement("<range>", ConfigIntValues.LASER_RELAY_MAX_DISTANCE.getValue()).addTextReplacement("<loss>", ConfigIntValues.LASER_RELAY_LOSS.getValue()), new PagePicture(2, "pageLaserRelay", 0).setNoText(), new PageCrafting(3, BlockCrafting.recipeLaserRelay).setNoText(), new PageCrafting(4, ItemCrafting.recipeLaserWrench).setNoText()).setImportant();
|
||||
new BookletChapterCoffee("coffeeMachine", entryFunctionalRF, new ItemStack(InitBlocks.blockCoffeeMachine), new PageTextOnly(1).setStack(new ItemStack(InitItems.itemCoffeeBean)).addTextReplacement("<rf>", ConfigIntValues.COFFEE_MACHINE_ENERGY_USED.getValue()).addTextReplacement("<coffee>", ConfigIntValues.COFFEE_CACHE_USED_PER_ITEM.getValue()).addTextReplacement("<water>", ConfigIntValues.COFFEE_MACHINE_WATER_USED.getValue()), new PageTextOnly(2).setStack(new ItemStack(InitItems.itemCoffee)), new PagePicture(3, "pageCoffeeMachine", 115), new PageCrafting(4, BlockCrafting.recipeCoffeeMachine).setNoText(), new PageCrafting(5, ItemCrafting.recipeCup).setNoText()).setImportant();
|
||||
new BookletChapterCrusher("crusher", entryFunctionalRF, new ItemStack(InitBlocks.blockGrinderDouble), new PageTextOnly(1).addTextReplacement("<rf1>", ConfigIntValues.GRINDER_ENERGY_USED.getValue()).addTextReplacement("<rf2>", ConfigIntValues.GRINDER_DOUBLE_ENERGY_USED.getValue()), new PageCrafting(2, BlockCrafting.recipeCrusher).setNoText(), new PageCrafting(3, BlockCrafting.recipeDoubleCrusher).setNoText(), new PageCrusherRecipe(4, CrusherCrafting.recipeSugar).setNoText(), new PageCrusherRecipe(5, CrusherCrafting.recipeIronHorseArmor).setNoText(), new PageCrusherRecipe(6, CrusherCrafting.recipeGoldHorseArmor).setNoText(), new PageCrusherRecipe(7, CrusherCrafting.recipeDiamondHorseArmor).setNoText());
|
||||
new BookletChapter("furnaceDouble", entryFunctionalRF, new ItemStack(InitBlocks.blockFurnaceDouble), new PageCrafting(1, BlockCrafting.recipeFurnace).addTextReplacement("<rf>", ConfigIntValues.FURNACE_ENERGY_USED.getValue()));
|
||||
new BookletChapter("lavaFactory", entryFunctionalRF, new ItemStack(InitBlocks.blockLavaFactoryController), new PageTextOnly(1).addTextReplacement("<rf>", ConfigIntValues.LAVA_FACTORY_ENERGY_USED.getValue()), new PagePicture(2, "pageLavaFactory", 0).setNoText(), new PageCrafting(3, BlockCrafting.recipeLavaFactory).setNoText(), new PageCrafting(4, BlockCrafting.recipeCasing).setNoText());
|
||||
new BookletChapter("laserRelays", entryFunctionalRF, new ItemStack(InitBlocks.blockLaserRelay), new PageTextOnly(1).addTextReplacement("<range>", TileEntityLaserRelay.MAX_DISTANCE).addTextReplacement("<loss>", ConfigIntValues.LASER_RELAY_LOSS.getValue()), new PagePicture(2, "pageLaserRelay", 0).setNoText(), new PageCrafting(3, BlockCrafting.recipeLaserRelay).setNoText(), new PageCrafting(4, ItemCrafting.recipeLaserWrench).setNoText()).setImportant();
|
||||
new BookletChapterCoffee("coffeeMachine", entryFunctionalRF, new ItemStack(InitBlocks.blockCoffeeMachine), new PageTextOnly(1).setStack(new ItemStack(InitItems.itemCoffeeBean)).addTextReplacement("<rf>", TileEntityCoffeeMachine.ENERGY_USED).addTextReplacement("<coffee>", TileEntityCoffeeMachine.CACHE_USE).addTextReplacement("<water>", TileEntityCoffeeMachine.WATER_USE), new PageTextOnly(2).setStack(new ItemStack(InitItems.itemCoffee)), new PagePicture(3, "pageCoffeeMachine", 115), new PageCrafting(4, BlockCrafting.recipeCoffeeMachine).setNoText(), new PageCrafting(5, ItemCrafting.recipeCup).setNoText()).setImportant();
|
||||
new BookletChapterCrusher("crusher", entryFunctionalRF, new ItemStack(InitBlocks.blockGrinderDouble), new PageTextOnly(1).addTextReplacement("<rf1>", TileEntityGrinder.getEnergyUse(false)).addTextReplacement("<rf2>", TileEntityGrinder.getEnergyUse(true)), new PageCrafting(2, BlockCrafting.recipeCrusher).setNoText(), new PageCrafting(3, BlockCrafting.recipeDoubleCrusher).setNoText(), new PageCrusherRecipe(4, CrusherCrafting.recipeSugar).setNoText(), new PageCrusherRecipe(5, CrusherCrafting.recipeIronHorseArmor).setNoText(), new PageCrusherRecipe(6, CrusherCrafting.recipeGoldHorseArmor).setNoText(), new PageCrusherRecipe(7, CrusherCrafting.recipeDiamondHorseArmor).setNoText());
|
||||
new BookletChapter("furnaceDouble", entryFunctionalRF, new ItemStack(InitBlocks.blockFurnaceDouble), new PageCrafting(1, BlockCrafting.recipeFurnace).addTextReplacement("<rf>", TileEntityFurnaceDouble.ENERGY_USE));
|
||||
new BookletChapter("lavaFactory", entryFunctionalRF, new ItemStack(InitBlocks.blockLavaFactoryController), new PageTextOnly(1).addTextReplacement("<rf>", TileEntityLavaFactoryController.ENERGY_USE), new PagePicture(2, "pageLavaFactory", 0).setNoText(), new PageCrafting(3, BlockCrafting.recipeLavaFactory).setNoText(), new PageCrafting(4, BlockCrafting.recipeCasing).setNoText());
|
||||
new BookletChapter("energizer", entryFunctionalRF, new ItemStack(InitBlocks.blockEnergizer), new PageCrafting(1, BlockCrafting.recipeEnergizer), new PageCrafting(2, BlockCrafting.recipeEnervator));
|
||||
new BookletChapter("repairer", entryFunctionalRF, new ItemStack(InitBlocks.blockItemRepairer), new PageCrafting(1, BlockCrafting.recipeRepairer).addTextReplacement("<rf>", ConfigIntValues.REPAIRER_ENERGY_USED.getValue()));
|
||||
new BookletChapter("longRangeBreaker", entryFunctionalRF, new ItemStack(InitBlocks.blockDirectionalBreaker), new PageTextOnly(1).addTextReplacement("<rf>", ConfigIntValues.DIRECTIONAL_BREAKER_RF_PER_BLOCK.getValue()).addTextReplacement("<range>", ConfigIntValues.DIRECTIONAL_BREAKER_RANGE.getValue()), new PageCrafting(2, BlockCrafting.recipeDirectionalBreaker));
|
||||
new BookletChapter("repairer", entryFunctionalRF, new ItemStack(InitBlocks.blockItemRepairer), new PageCrafting(1, BlockCrafting.recipeRepairer).addTextReplacement("<rf>", TileEntityItemRepairer.ENERGY_USE));
|
||||
new BookletChapter("longRangeBreaker", entryFunctionalRF, new ItemStack(InitBlocks.blockDirectionalBreaker), new PageTextOnly(1).addTextReplacement("<rf>", TileEntityDirectionalBreaker.ENERGY_USE).addTextReplacement("<range>", TileEntityDirectionalBreaker.RANGE), new PageCrafting(2, BlockCrafting.recipeDirectionalBreaker));
|
||||
|
||||
//RF Generating Blocks
|
||||
new BookletChapter("solarPanel", entryGeneratingRF, new ItemStack(InitBlocks.blockFurnaceSolar), new PageTextOnly(1).addTextReplacement("<rf>", ConfigIntValues.FURNACE_SOLAR_ENERGY_PRODUCED.getValue()), new PageCrafting(2, BlockCrafting.recipeSolar).setNoText());
|
||||
new BookletChapter("heatCollector", entryGeneratingRF, new ItemStack(InitBlocks.blockHeatCollector), new PageTextOnly(1).addTextReplacement("<rf>", ConfigIntValues.HEAT_COLLECTOR_ENERGY_PRODUCED.getValue()).addTextReplacement("<min>", ConfigIntValues.HEAT_COLLECTOR_BLOCKS.getValue()), new PageCrafting(2, BlockCrafting.recipeHeatCollector).setNoText());
|
||||
new BookletChapter("canola", entryGeneratingRF, new ItemStack(InitBlocks.blockFermentingBarrel), new PageTextOnly(1).setStack(new ItemStack(InitItems.itemMisc, 1, TheMiscItems.CANOLA.ordinal())).addTextReplacement("<pressRF>", ConfigIntValues.PRESS_ENERGY_USED.getValue()).addTextReplacement("<canola>", ConfigIntValues.PRESS_MB_PRODUCED.getValue()).addTextReplacement("<rf>", ConfigIntValues.OIL_GEN_ENERGY_PRODUCED.getValue()), new PageCrafting(2, BlockCrafting.recipeCanolaPress).setNoText(), new PageCrafting(3, BlockCrafting.recipeFermentingBarrel).setNoText(), new PageCrafting(4, BlockCrafting.recipeOilGen).setNoText());
|
||||
new BookletChapter("leafGen", entryGeneratingRF, new ItemStack(InitBlocks.blockLeafGenerator), new PageTextOnly(1).addTextReplacement("<rf>", ConfigIntValues.LEAF_GENERATOR_ENERGY_PRODUCED.getValue()).addTextReplacement("<range>", ConfigIntValues.LEAF_GENERATOR_RANGE.getValue()), new PageCrafting(2, BlockCrafting.recipeLeafGen)).setImportant();
|
||||
new BookletChapter("solarPanel", entryGeneratingRF, new ItemStack(InitBlocks.blockFurnaceSolar), new PageTextOnly(1).addTextReplacement("<rf>", TileEntityFurnaceSolar.PRODUCE), new PageCrafting(2, BlockCrafting.recipeSolar).setNoText());
|
||||
new BookletChapter("heatCollector", entryGeneratingRF, new ItemStack(InitBlocks.blockHeatCollector), new PageTextOnly(1).addTextReplacement("<rf>", TileEntityHeatCollector.ENERGY_PRODUCE).addTextReplacement("<min>", TileEntityHeatCollector.BLOCKS_NEEDED), new PageCrafting(2, BlockCrafting.recipeHeatCollector).setNoText());
|
||||
new BookletChapter("canola", entryGeneratingRF, new ItemStack(InitBlocks.blockFermentingBarrel), new PageTextOnly(1).setStack(new ItemStack(InitItems.itemMisc, 1, TheMiscItems.CANOLA.ordinal())).addTextReplacement("<pressRF>", TileEntityCanolaPress.ENERGY_USE).addTextReplacement("<canola>", TileEntityCanolaPress.PRODUCE).addTextReplacement("<rf>", TileEntityOilGenerator.ENERGY_PRODUCED), new PageCrafting(2, BlockCrafting.recipeCanolaPress).setNoText(), new PageCrafting(3, BlockCrafting.recipeFermentingBarrel).setNoText(), new PageCrafting(4, BlockCrafting.recipeOilGen).setNoText());
|
||||
new BookletChapter("leafGen", entryGeneratingRF, new ItemStack(InitBlocks.blockLeafGenerator), new PageTextOnly(1).addTextReplacement("<rf>", TileEntityLeafGenerator.ENERGY_PRODUCED).addTextReplacement("<range>", TileEntityLeafGenerator.RANGE), new PageCrafting(2, BlockCrafting.recipeLeafGen)).setImportant();
|
||||
|
||||
//No RF Using Items
|
||||
new BookletChapter("wings", entryItemsNonRF, new ItemStack(InitItems.itemWingsOfTheBats), new PageTextOnly(1).setStack(new ItemStack(InitItems.itemMisc, 1, TheMiscItems.BAT_WING.ordinal())), new PageCrafting(2, ItemCrafting.recipeWings).setNoText()).setSpecial();
|
||||
|
|
|
@ -20,12 +20,8 @@ public enum ConfigCategories{
|
|||
MOB_DROPS("Mob Drops", "Everything regarding Item drops from mobs"),
|
||||
WORLD_GEN("World Gen", "Everything regarding World Generation"),
|
||||
POTION_RING_CRAFTING("Ring Crafting", "Crafting Recipes for Rings"),
|
||||
OTHER("Other", "Everything else"),
|
||||
FLUIDS("Fluids", "Everything regarding fluids"),
|
||||
DRILL_VALUES("Drill Values", "Properties of Drills and their Upgrades"),
|
||||
CRUSHER_RECIPES("Crusher Recipes", "Recipes for the Crusher"),
|
||||
RECONSTRUCTOR_RECIPES("Reconstructor Recipes", "Recipes for the Atomic Reconstructor"),
|
||||
ARMOR_VALUES("Armor Values", "Values for Armor");
|
||||
OTHER("Other", "Everything else");
|
||||
|
||||
public final String name;
|
||||
public final String comment;
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.config;
|
|||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigBoolValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigCrafting;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigFloatValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import net.minecraftforge.common.config.Configuration;
|
||||
|
||||
|
@ -20,7 +19,6 @@ public class ConfigValues{
|
|||
|
||||
public static ConfigCrafting[] craftingConfig = ConfigCrafting.values();
|
||||
public static ConfigIntValues[] intConfig = ConfigIntValues.values();
|
||||
public static ConfigFloatValues[] floatConfig = ConfigFloatValues.values();
|
||||
public static ConfigBoolValues[] boolConfig = ConfigBoolValues.values();
|
||||
|
||||
public static String[] crusherRecipeExceptions;
|
||||
|
@ -35,19 +33,16 @@ public class ConfigValues{
|
|||
public static void defineConfigValues(Configuration config){
|
||||
|
||||
for(ConfigCrafting currConf : craftingConfig){
|
||||
currConf.currentValue = config.get(currConf.category, currConf.name, currConf.defaultValue, "If the "+currConf.extraText+"Crafting Recipe for the "+currConf.name+" is Enabled").getBoolean();
|
||||
currConf.currentValue = config.get(currConf.category, currConf.name, currConf.defaultValue, "If the Recipe for the "+currConf.name+" is Enabled").getBoolean();
|
||||
}
|
||||
for(ConfigIntValues currConf : intConfig){
|
||||
currConf.currentValue = config.get(currConf.category, currConf.name, currConf.defaultValue, currConf.desc, currConf.min, currConf.max).getInt();
|
||||
}
|
||||
for(ConfigFloatValues currConf : floatConfig){
|
||||
currConf.currentValue = (float)config.get(currConf.category, currConf.name, currConf.defaultValue, currConf.desc, currConf.min, currConf.max).getDouble();
|
||||
}
|
||||
for(ConfigBoolValues currConf : boolConfig){
|
||||
currConf.currentValue = config.get(currConf.category, currConf.name, currConf.defaultValue, currConf.desc).getBoolean();
|
||||
}
|
||||
|
||||
crusherRecipeExceptions = config.get(ConfigCategories.CRUSHER_RECIPES.name, "Crusher Recipe Exceptions", new String[]{"ingotBrick", "ingotBrickNether"}, "The Ingots, Dusts and Ores blacklisted from being auto-registered to be crushed by the Crusher. This list uses OreDictionary Names of the Inputs only.").getStringList();
|
||||
crusherRecipeExceptions = config.get(ConfigCategories.OTHER.name, "Crusher Recipe Exceptions", new String[]{"ingotBrick", "ingotBrickNether"}, "The Ingots, Dusts and Ores blacklisted from being auto-registered to be crushed by the Crusher. This list uses OreDictionary Names of the Inputs only.").getStringList();
|
||||
mashedFoodCraftingExceptions = config.get(ConfigCategories.ITEMS_CRAFTING.name, "Mashed Food Crafting Exceptions", new String[]{"ActuallyAdditions:itemCoffee"}, "The ItemFood, IGrowable and IPlantable Items that can not be used to craft Mashed Food. These are the actual registered Item Names, the ones you use, for example, when using the /give Command.").getStringList();
|
||||
paxelExtraMiningWhitelist = config.get(ConfigCategories.TOOL_VALUES.name, "AIOT Extra Whitelist", new String[]{"TConstruct:GravelOre"}, "By default, the AIOT can mine certain blocks. If there is one that it can't mine, but should be able to, put its REGISTRY NAME here. These are the actual registered Item Names, the ones you use, for example, when using the /give Command.").getStringList();
|
||||
drillExtraminingWhitelist = config.get(ConfigCategories.TOOL_VALUES.name, "Drill Extra Whitelist", new String[]{"TConstruct:GravelOre"}, "By default, the Drill can mine certain blocks. If there is one that it can't mine, but should be able to, put its REGISTRY NAME here. These are the actual registered Item Names, the ones you use, for example, when using the /give Command.").getStringList();
|
||||
|
|
|
@ -131,22 +131,9 @@ public enum ConfigCrafting{
|
|||
QUARTZ("Black Quartz in a Crafting Table", ConfigCategories.ITEMS_CRAFTING),
|
||||
LAMPS("Lamps", ConfigCategories.BLOCKS_CRAFTING),
|
||||
|
||||
REDSTONE("Redstone Ore -> Redstone", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
LAPIS("Lapis Ore -> Lapis", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
COAL("Coal -> Coal Dust", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
COAL_ORE("Coal Ore -> Coal", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
COAL_BLOCKS("Coal Block -> Coal Dust", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
QUARTZ_ORE("Quartz Ore -> Quartz", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
COBBLESTONE("Cobblestone -> Sand", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
GRAVEL("Gravel -> Flint", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
STONE("Stone -> Cobblestone", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
RICE_SUGAR("Rice -> Sugar", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
NICKEL("Nickel Ore -> Nickel Dust + Platinum Dust", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
IRON("Iron Ore -> Iron Dust + Gold Dust", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
HORSE_ARMORS("Horse Armor -> Raw Materials", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
CRUSHER_MISC("Misc. Crusher Recipes like Bone Meal & Dyes", ConfigCategories.CRUSHER_RECIPES, "Crusher"),
|
||||
HORSE_ARMORS("Horse Armor -> Raw Materials (Crusher)", ConfigCategories.OTHER),
|
||||
|
||||
RECONSTRUCTOR_MISC("Misc. Reconstructor Recipes like Soul Sand", ConfigCategories.RECONSTRUCTOR_RECIPES, "Reconstructor"),
|
||||
RECONSTRUCTOR_MISC("Misc. Recipes like Soul Sand (Reconstructor)", ConfigCategories.OTHER),
|
||||
|
||||
TELE_STAFF("Tele Staff", ConfigCategories.ITEMS_CRAFTING),
|
||||
CASING("Casing", ConfigCategories.BLOCKS_CRAFTING),
|
||||
|
@ -166,7 +153,6 @@ public enum ConfigCrafting{
|
|||
public final String name;
|
||||
public final String category;
|
||||
public final boolean defaultValue;
|
||||
public final String extraText;
|
||||
|
||||
public boolean currentValue;
|
||||
|
||||
|
@ -175,18 +161,9 @@ public enum ConfigCrafting{
|
|||
}
|
||||
|
||||
ConfigCrafting(String name, ConfigCategories category, boolean defaultValue){
|
||||
this(name, category, "", defaultValue);
|
||||
}
|
||||
|
||||
ConfigCrafting(String name, ConfigCategories category, String extraText, boolean defaultValue){
|
||||
this.name = name;
|
||||
this.category = category.name;
|
||||
this.defaultValue = defaultValue;
|
||||
this.extraText = extraText.length() > 0 ? extraText+" " : "";
|
||||
}
|
||||
|
||||
ConfigCrafting(String name, ConfigCategories category, String extraText){
|
||||
this(name, category, extraText, true);
|
||||
}
|
||||
|
||||
public boolean isEnabled(){
|
||||
|
|
|
@ -1,50 +0,0 @@
|
|||
/*
|
||||
* This file ("ConfigFloatValues.java") is part of the Actually Additions Mod for Minecraft.
|
||||
* It is created and owned by Ellpeck and distributed
|
||||
* under the Actually Additions License to be found at
|
||||
* http://github.com/Ellpeck/ActuallyAdditions/blob/master/README.md
|
||||
* View the source code at https://github.com/Ellpeck/ActuallyAdditions
|
||||
*
|
||||
* © 2015 Ellpeck
|
||||
*/
|
||||
|
||||
package ellpeck.actuallyadditions.config.values;
|
||||
|
||||
import ellpeck.actuallyadditions.config.ConfigCategories;
|
||||
|
||||
public enum ConfigFloatValues{
|
||||
|
||||
EMERALD_SPEED("Emerald: Efficiency", ConfigCategories.TOOL_VALUES, 9.0F, 1.0F, 20.0F, "How fast Emerald Tools are"),
|
||||
EMERALD_MAX_DAMAGE("Emerald: Damage", ConfigCategories.TOOL_VALUES, 5.0F, 0.1F, 50.0F, "How much damage an Emerald Tool deals"),
|
||||
|
||||
OBSIDIAN_SPEED("Obsidian: Efficiency", ConfigCategories.TOOL_VALUES, 4.0F, 1.0F, 20.0F, "How fast Obsidian Tools are"),
|
||||
OBSIDIAN_MAX_DAMAGE("Obsidian: Damage", ConfigCategories.TOOL_VALUES, 2.0F, 0.1F, 50.0F, "How much damage an Obsidian Tool deals"),
|
||||
|
||||
QUARTZ_SPEED("Quartz: Efficiency", ConfigCategories.TOOL_VALUES, 6.5F, 1.0F, 20.0F, "How fast Quartz Tools are"),
|
||||
QUARTZ_MAX_DAMAGE("Quartz: Damage", ConfigCategories.TOOL_VALUES, 2.0F, 0.1F, 50.0F, "How much damage an Quartz Tool deals"),
|
||||
|
||||
DRILL_DAMAGE("Drill: Default Damage", ConfigCategories.DRILL_VALUES, 8.0F, 1.0F, 30.0F, "How much Damage the Drill does to an Entity");
|
||||
|
||||
public final String name;
|
||||
public final String category;
|
||||
public final float defaultValue;
|
||||
public final float min;
|
||||
public final float max;
|
||||
public final String desc;
|
||||
|
||||
public float currentValue;
|
||||
|
||||
ConfigFloatValues(String name, ConfigCategories category, float defaultValue, float min, float max, String desc){
|
||||
this.name = name;
|
||||
this.category = category.name;
|
||||
this.defaultValue = defaultValue;
|
||||
this.min = min;
|
||||
this.max = max;
|
||||
this.desc = desc;
|
||||
}
|
||||
|
||||
public float getValue(){
|
||||
return this.currentValue;
|
||||
}
|
||||
|
||||
}
|
|
@ -11,173 +11,20 @@
|
|||
package ellpeck.actuallyadditions.config.values;
|
||||
|
||||
import ellpeck.actuallyadditions.config.ConfigCategories;
|
||||
import net.minecraftforge.fluids.FluidContainerRegistry;
|
||||
|
||||
public enum ConfigIntValues{
|
||||
|
||||
JAM_VILLAGER_ID("Jam Villager: ID", ConfigCategories.WORLD_GEN, 493827, 100, 1000000, "The ID of the Jam Villager"),
|
||||
|
||||
LEAF_BLOWER_RANGE_SIDES("Leaf Blower: Side Range", ConfigCategories.TOOL_VALUES, 5, 1, 25, "The Leaf Blower's Range to the Sides"),
|
||||
LEAF_BLOWER_RANGE_UP("Leaf Blower: Range Up", ConfigCategories.TOOL_VALUES, 1, 1, 10, "The Leaf Blower's Range Up"),
|
||||
|
||||
BLACK_QUARTZ_BASE_AMOUNT("Black Quartz: Amount", ConfigCategories.WORLD_GEN, 5, 1, 50, "How big a Black Quartz Vein is at least"),
|
||||
BLACK_QUARTZ_ADD_CHANCE("Black Quartz: Additional Chance", ConfigCategories.WORLD_GEN, 3, 0, 50, "How much bigger than the Base Amount a Black Quartz Vein can get"),
|
||||
BLACK_QUARTZ_CHANCE("Black Quartz: Chance", ConfigCategories.WORLD_GEN, 10, 1, 150, "How often the Black Quartz tries to generate"),
|
||||
BLACK_QUARTZ_MIN_HEIGHT("Black Quartz: Min Height", ConfigCategories.WORLD_GEN, 0, 0, 256, "How high the Black Quartz starts to generate"),
|
||||
BLACK_QUARTZ_MAX_HEIGHT("Black Quartz: Max Height", ConfigCategories.WORLD_GEN, 45, 0, 256, "How high the Black Quartz stops to generate at"),
|
||||
|
||||
COMPOST_AMOUNT("Compost: Amount Needed To Convert", ConfigCategories.MACHINE_VALUES, 10, 1, 64, "How many items are needed in the Compost to convert to Fertilizer"),
|
||||
COMPOST_TIME("Compost: Conversion Time Needed", ConfigCategories.MACHINE_VALUES, 1000, 30, 10000, "How long the Compost needs to convert to Fertilizer"),
|
||||
|
||||
FISHER_TIME("Fishing Net: Time Needed", ConfigCategories.MACHINE_VALUES, 15000, 50, 500000, "How long it takes on Average until the Fishing Net catches a Fish"),
|
||||
|
||||
FEEDER_REACH("Feeder: Reach", ConfigCategories.MACHINE_VALUES, 5, 1, 20, "The Radius of Action of the Feeder"),
|
||||
FEEDER_TIME("Feeder: Time Needed", ConfigCategories.MACHINE_VALUES, 100, 50, 5000, "The time spent between feeding animals with the Feeder"),
|
||||
FEEDER_THRESHOLD("Feeder: Threshold", ConfigCategories.MACHINE_VALUES, 30, 3, 500, "How many animals need to be in the area for the Feeder to stop"),
|
||||
|
||||
KNIFE_DAMAGE("Knife: Max Uses", ConfigCategories.TOOL_VALUES, 100, 5, 5000, "How often the Knife can be crafted with"),
|
||||
|
||||
EMERALD_HARVEST_LEVEL("Emerald: Harvest Level", ConfigCategories.TOOL_VALUES, 3, 0, 20, "What Harvest Level Emerald Tools have (0 = Wood, 1 = Stone, 2 = Iron, 3 = Diamond)"),
|
||||
EMERALD_USES("Emerald: Max Uses", ConfigCategories.TOOL_VALUES, 2000, 50, 10000, "How often Emerald Tools can be used"),
|
||||
EMERALD_ENCHANTABILITY("Emerald: Enchantability", ConfigCategories.TOOL_VALUES, 15, 1, 30, "How enchantable an Emerald Tool is"),
|
||||
|
||||
OBSIDIAN_HARVEST_LEVEL("Obsidian: Harvest Level", ConfigCategories.TOOL_VALUES, 3, 0, 20, "What Harvest Level Obsidian Tools have (0 = Wood, 1 = Stone, 2 = Iron, 3 = Diamond)"),
|
||||
OBSIDIAN_USES("Obsidian: Max Uses", ConfigCategories.TOOL_VALUES, 8000, 50, 20000, "How often Obsidian Tools can be used"),
|
||||
OBSIDIAN_ENCHANTABILITY("Obsidian: Enchantability", ConfigCategories.TOOL_VALUES, 15, 1, 30, "How enchantable an Obsidian Tool is"),
|
||||
|
||||
QUARTZ_HARVEST_LEVEL("Quartz: Harvest Level", ConfigCategories.TOOL_VALUES, 2, 0, 20, "What Harvest Level Quartz Tools have (0 = Wood, 1 = Stone, 2 = Iron, 3 = Diamond)"),
|
||||
QUARTZ_USES("Quartz: Max Uses", ConfigCategories.TOOL_VALUES, 280, 50, 20000, "How often Quartz Tools can be used"),
|
||||
QUARTZ_ENCHANTABILITY("Quartz: Enchantability", ConfigCategories.TOOL_VALUES, 10, 1, 30, "How enchantable an Quartz Tool is"),
|
||||
|
||||
DRILL_HARVEST_LEVEL("Drill: Harvest Level", ConfigCategories.TOOL_VALUES, 4, 0, 20, "What Harvest Level the Drill has (0 = Wood, 1 = Stone, 2 = Iron, 3 = Diamond)"),
|
||||
|
||||
EMERALD_ARMOR_DURABILITY("Emerald Armor: Durability", ConfigCategories.ARMOR_VALUES, 1500, 10, 10000, "The Durability of Emerald Armor"),
|
||||
EMERALD_ARMOR_HEAD_DAMAGE("Emerald Helmets: Damage Reduction", ConfigCategories.ARMOR_VALUES, 5, 0, 10, "The Damage Reduction of Emerald Helmets"),
|
||||
EMERALD_ARMOR_CHEST_DAMAGE("Emerald Chests: Damage Reduction", ConfigCategories.ARMOR_VALUES, 9, 0, 10, "The Damage Reduction of Emerald Chests"),
|
||||
EMERALD_ARMOR_LEGS_DAMAGE("Emerald Legs: Damage Reduction", ConfigCategories.ARMOR_VALUES, 8, 0, 10, "The Damage Reduction of Emerald Legs"),
|
||||
EMERALD_ARMOR_BOOTS_DAMAGE("Emerald Boots: Damage Reduction", ConfigCategories.ARMOR_VALUES, 5, 0, 10, "The Damage Reduction of Emerald Boots"),
|
||||
EMERALD_ARMOR_ENCHANTABILITY("Emerald Armor: Enchantability", ConfigCategories.ARMOR_VALUES, 15, 1, 30, "The Enchantability of Emerald Armor"),
|
||||
|
||||
QUARTZ_ARMOR_DURABILITY("Quartz Armor: Durability", ConfigCategories.ARMOR_VALUES, 200, 10, 10000, "The Durability of Quartz Armor"),
|
||||
QUARTZ_ARMOR_HEAD_DAMAGE("Quartz Helmets: Damage Reduction", ConfigCategories.ARMOR_VALUES, 3, 0, 10, "The Damage Reduction of Quartz Helmets"),
|
||||
QUARTZ_ARMOR_CHEST_DAMAGE("Quartz Chests: Damage Reduction", ConfigCategories.ARMOR_VALUES, 6, 0, 10, "The Damage Reduction of Quartz Chests"),
|
||||
QUARTZ_ARMOR_LEGS_DAMAGE("Quartz Legs: Damage Reduction", ConfigCategories.ARMOR_VALUES, 5, 0, 10, "The Damage Reduction of Quartz Legs"),
|
||||
QUARTZ_ARMOR_BOOTS_DAMAGE("Quartz Boots: Damage Reduction", ConfigCategories.ARMOR_VALUES, 3, 0, 10, "The Damage Reduction of Quartz Boots"),
|
||||
QUARTZ_ARMOR_ENCHANTABILITY("Quartz Armor: Enchantability", ConfigCategories.ARMOR_VALUES, 8, 1, 30, "The Enchantability of Quartz Armor"),
|
||||
|
||||
OBSIDIAN_ARMOR_DURABILITY("Obsidian Armor: Durability", ConfigCategories.ARMOR_VALUES, 7000, 10, 10000, "The Durability of Obsidian Armor"),
|
||||
OBSIDIAN_ARMOR_HEAD_DAMAGE("Obsidian Helmets: Damage Reduction", ConfigCategories.ARMOR_VALUES, 3, 0, 10, "The Damage Reduction of Obsidian Helmets"),
|
||||
OBSIDIAN_ARMOR_CHEST_DAMAGE("Obsidian Chests: Damage Reduction", ConfigCategories.ARMOR_VALUES, 4, 0, 10, "The Damage Reduction of Obsidian Chests"),
|
||||
OBSIDIAN_ARMOR_LEGS_DAMAGE("Obsidian Legs: Damage Reduction", ConfigCategories.ARMOR_VALUES, 3, 0, 10, "The Damage Reduction of Obsidian Legs"),
|
||||
OBSIDIAN_ARMOR_BOOTS_DAMAGE("Obsidian Boots: Damage Reduction", ConfigCategories.ARMOR_VALUES, 1, 0, 10, "The Damage Reduction of Obsidian Boots"),
|
||||
OBSIDIAN_ARMOR_ENCHANTABILITY("Obsidian Armor: Enchantability", ConfigCategories.ARMOR_VALUES, 10, 1, 30, "The Enchantability of Obsidian Armor"),
|
||||
|
||||
GRINDER_CRUSH_TIME("Crusher: Time", ConfigCategories.MACHINE_VALUES, 100, 10, 1000, "How long the Crusher takes to crush an item"),
|
||||
GRINDER_DOUBLE_CRUSH_TIME("Double Crusher: Time", ConfigCategories.MACHINE_VALUES, 150, 10, 1000, "How long the Double Crusher takes to crush an item"),
|
||||
FURNACE_DOUBLE_SMELT_TIME("Double Furnace: Time", ConfigCategories.MACHINE_VALUES, 80, 10, 1000, "How long the Double Furnace takes to crush an item"),
|
||||
|
||||
REPAIRER_SPEED_SLOWDOWN("Repairer: Speed Slowdown", ConfigCategories.MACHINE_VALUES, 2, 1, 100, "How much slower the Item Repairer repairs"),
|
||||
HEAT_COLLECTOR_BLOCKS("Heat Collector: Blocks Needed", ConfigCategories.MACHINE_VALUES, 4, 1, 5, "How many Blocks are needed for the Heat Collector to power Machines above it"),
|
||||
HEAT_COLLECTOR_LAVA_CHANCE("Heat Collector: Random Chance", ConfigCategories.MACHINE_VALUES, 15000, 10, 100000, "The Chance of the Heat Collector destroying a Lava Block around (Default Value 2000 meaning a 1/2000 Chance!)"),
|
||||
|
||||
GLASS_TIME_NEEDED("Greenhouse Glass: Time", ConfigCategories.MACHINE_VALUES, 300, 1, 10000, "Time Needed for the Greenhouse Glass to grow a Plant below it"),
|
||||
|
||||
BREAKER_TIME_NEEDED("Breaker and Placer: Time Needed", ConfigCategories.MACHINE_VALUES, 15, 1, 10000, "The Time Needed for the Breaker and the Placer to place or break a Block"),
|
||||
DROPPER_TIME_NEEDED("Dropper: Time Needed", ConfigCategories.MACHINE_VALUES, 10, 1, 10000, "The Time Needed for the Dropper to drop an Item"),
|
||||
|
||||
CAT_DROP_CHANCE("Cat Drops: Chance", ConfigCategories.OTHER, 5000, 5, 10000000, "The 1 in X chance for a Hairy Ball to Drop from a Cat with X being this value"),
|
||||
SPIDER_DROP_CHANCE("Cobweb Drop from Spider: Chance", ConfigCategories.MOB_DROPS, 500, 1, 1000000000, "The 1 in X chance for a Cobweb to drop from a Spider"),
|
||||
BAT_DROP_CHANCE("Wings from Bats: Chance", ConfigCategories.MOB_DROPS, 10, 1, 1000000000, "The 1 in X chance for a Wing to drop from a Bat"),
|
||||
|
||||
RICE_AMOUNT("Rice Amount", ConfigCategories.WORLD_GEN, 15, 1, 100, "The Chance of Rice generating"),
|
||||
CANOLA_AMOUNT("Canola Amount", ConfigCategories.WORLD_GEN, 10, 1, 50, "The Chance of Canola generating"),
|
||||
FLAX_AMOUNT("Flax Amount", ConfigCategories.WORLD_GEN, 8, 1, 50, "The Chance of Flax generating"),
|
||||
COFFEE_AMOUNT("Coffee Amount", ConfigCategories.WORLD_GEN, 6, 1, 50, "The Chance of Coffee generating"),
|
||||
BLACK_LOTUS_AMOUNT("Black Lotus Amount", ConfigCategories.WORLD_GEN, 14, 1, 50, "The Chance of the Black Lotus generating"),
|
||||
RICE_CHANCE("Rice Chance", ConfigCategories.WORLD_GEN, 50, 1, 3000, "The 1 in X chance for Rice to generate"),
|
||||
NORMAL_PLANT_CHANCE("Plant Chance", ConfigCategories.WORLD_GEN, 400, 1, 3000, "The 1 in X chance for Flax, Coffee and Canola to generate"),
|
||||
TREASURE_CHEST_CHANCE("Treasure Chest Chance", ConfigCategories.WORLD_GEN, 300, 1, 3000, "The 1 in X chance for a Treasure Chest to generate in an Ocean"),
|
||||
TREASURE_CHEST_MIN_HEIGHT("Treasure Chest Min Height", ConfigCategories.WORLD_GEN, 25, 0, 65, "The Min Height for a Treasure Chest to generate"),
|
||||
TREASURE_CHEST_MAX_HEIGHT("Treasure Chest Max Height", ConfigCategories.WORLD_GEN, 45, 0, 65, "The Max Height for a Treasure Chest to generate"),
|
||||
|
||||
GRINDER_ENERGY_USED("Energy Use: Crusher", ConfigCategories.MACHINE_VALUES, 40, 1, 500, "The Amount of Energy used by the Crusher per Tick"),
|
||||
GRINDER_DOUBLE_ENERGY_USED("Energy Use: Double Crusher", ConfigCategories.MACHINE_VALUES, 60, 1, 500, "The Amount of Energy used by the Double Crusher per Tick"),
|
||||
FURNACE_SOLAR_ENERGY_PRODUCED("Energy Production: Furnace Solar", ConfigCategories.MACHINE_VALUES, 15, 1, 500, "The Amount of Energy produced by the Solar per Tick"),
|
||||
HEAT_COLLECTOR_ENERGY_PRODUCED("Energy Production: Heat Collectors", ConfigCategories.MACHINE_VALUES, 60, 1, 500, "The Amount of Energy produced by the Heat Collector per Tick"),
|
||||
REPAIRER_ENERGY_USED("Energy Use: Repairer", ConfigCategories.MACHINE_VALUES, 1250, 1, 5000, "The Amount of Energy used by the Repairer per Tick"),
|
||||
FURNACE_ENERGY_USED("Energy Use: Double Furnace", ConfigCategories.MACHINE_VALUES, 25, 1, 500, "The Amount of Energy used by the Double Furnace per Tick"),
|
||||
|
||||
PRESS_PROCESSING_TIME("Canola Press: Processing Time", ConfigCategories.MACHINE_VALUES, 30, 1, 1000, "The Amount of time it takes to process one Canola"),
|
||||
PRESS_MB_PRODUCED("Canola Press: mB Produced", ConfigCategories.MACHINE_VALUES, 100, 1, 5000, "The Amount of Canola Oil produced from one Canola"),
|
||||
PRESS_ENERGY_USED("Energy Use: Canola Press", ConfigCategories.MACHINE_VALUES, 35, 10, 500, "The Amount of Energy used by the Canola Press per Tick"),
|
||||
|
||||
BARREL_MB_PRODUCED("Fermenting Barrel: mB Produced", ConfigCategories.MACHINE_VALUES, 50, 1, 3000, "The Amount of mB produced by the Barrel per cycle"),
|
||||
BARREL_PROCESSING_TIME("Fermenting Barrel: Processing Time", ConfigCategories.MACHINE_VALUES, 100, 1, 5000, "The Amount of time it takes to process one Canola Oil to Oil"),
|
||||
COAL_GEN_ENERGY_PRODUCED("Coal Generator: Energy Produced", ConfigCategories.MACHINE_VALUES, 30, 1, 500, "The Amount of Energy generated by the Coal Generator"),
|
||||
|
||||
PHANTOMFACE_RANGE("Phantomface: Default Range", ConfigCategories.MACHINE_VALUES, 16, 3, 100, "The Default Range of the Phantomface"),
|
||||
|
||||
OIL_GEN_ENERGY_PRODUCED("Oil Generator: Energy Produced", ConfigCategories.MACHINE_VALUES, 76, 1, 500, "The Amount of Energy generated by the Oil Generator"),
|
||||
OIL_GEN_FUEL_USED("Oil Generator: Fuel Usage", ConfigCategories.MACHINE_VALUES, 50, 1, 300, "The Amount of Fuel used per Burnup in the Oil Generator"),
|
||||
OIL_GEN_BURN_TIME("Oil Generator: Burn Time", ConfigCategories.MACHINE_VALUES, 100, 1, 1000, "The Amount of Time Fuel keeps burning for"),
|
||||
|
||||
PHANTOM_PLACER_TIME("Phantom Placer and Breaker: Time Needed", ConfigCategories.MACHINE_VALUES, 30, 1, 500, "The Amount of Time a Phantom Placer/Breaker needs"),
|
||||
PHANTOM_PLACER_RANGE("Phantom Placer and Breaker: Range", ConfigCategories.MACHINE_VALUES, 3, 1, 100, "The Default Range of the Phantom Placer/Breaker"),
|
||||
|
||||
LAVA_FACTORY_ENERGY_USED("Lava Factory: Energy Used", ConfigCategories.MACHINE_VALUES, 150000, 10, 3000000, "The amount of Energy used by the Lava Factory per Bucket of Lava produced"),
|
||||
LAVA_FACTORY_TIME("Lava Factory: Production Time", ConfigCategories.MACHINE_VALUES, 200, 5, 10000, "The amount of time it takes for the Lava Factory to produce one Bucket"),
|
||||
|
||||
COFFEE_MACHINE_ENERGY_USED("Coffee Machine: Energy Use", ConfigCategories.MACHINE_VALUES, 150, 10, 3000, "The amount of Energy used by the Coffee Machine per Tick"),
|
||||
COFFEE_CACHE_ADDED_PER_ITEM("Coffee Machine: Coffee added per Cup", ConfigCategories.MACHINE_VALUES, 1, 1, 300, "The amount of Coffee added by one Coffee Item in the Coffee Machine"),
|
||||
COFFEE_CACHE_USED_PER_ITEM("Coffee Machine: Coffee used per Cup", ConfigCategories.MACHINE_VALUES, 10, 1, 300, "The amount of Coffee used to brew one Coffee in the Coffee Machine"),
|
||||
COFFEE_MACHINE_TIME_USED("Coffee Machine: Time to Brew", ConfigCategories.MACHINE_VALUES, 500, 10, 10000, "The amount of time the Coffee Machine takes to brew a Coffee"),
|
||||
COFFEE_MACHINE_WATER_USED("Coffee Machine: Water Used per Cup", ConfigCategories.MACHINE_VALUES, 500, 1, 4*FluidContainerRegistry.BUCKET_VOLUME, "The amount of Water the Coffee Machine uses per Cup"),
|
||||
|
||||
COFFEE_DRINK_AMOUNT("Coffee: Drink Amount", ConfigCategories.OTHER, 4, 1, 100, "How often a Coffee can be drunk from"),
|
||||
DRILL_ENERGY_USE("Drill: Energy Use Per Block or Hit", ConfigCategories.DRILL_VALUES, 100, 5, 10000, "How much Energy the Drill uses per Block"),
|
||||
|
||||
DRILL_SPEED_EXTRA_USE("Speed Upgrade: Extra Energy Use", ConfigCategories.DRILL_VALUES, 50, 0, 10000, "How much extra Energy the Speed Upgrade uses"),
|
||||
DRILL_SPEED_II_EXTRA_USE("Speed II Upgrade: Extra Energy Use", ConfigCategories.DRILL_VALUES, 75, 0, 10000, "How much extra Energy the Speed II Upgrade uses"),
|
||||
DRILL_SPEED_III_EXTRA_USE("Speed III Upgrade: Extra Energy Use", ConfigCategories.DRILL_VALUES, 175, 0, 10000, "How much extra Energy the Speed III Upgrade uses"),
|
||||
DRILL_SILK_EXTRA_USE("Silk Upgrade: Extra Energy Use", ConfigCategories.DRILL_VALUES, 30, 0, 10000, "How much extra Energy the Silk Upgrade uses"),
|
||||
DRILL_FORTUNE_EXTRA_USE("Fortune Upgrade: Extra Energy Use", ConfigCategories.DRILL_VALUES, 40, 0, 10000, "How much extra Energy the Fortune Upgrade uses"),
|
||||
DRILL_FORTUNE_II_EXTRA_USE("Fortune II Upgrade: Extra Energy Use", ConfigCategories.DRILL_VALUES, 60, 0, 10000, "How much extra Energy the Fortune II Upgrade uses"),
|
||||
DRILL_THREE_BY_THREE_EXTRA_USE("3x3 Upgrade: Extra Energy Use", ConfigCategories.DRILL_VALUES, 10, 0, 10000, "How much extra Energy the 3x3 Upgrade uses"),
|
||||
DRILL_FIVE_BY_FIVE_EXTRA_USE("5x5 Upgrade: Extra Energy Use", ConfigCategories.DRILL_VALUES, 30, 0, 10000, "How much extra Energy the 5x5 Upgrade uses"),
|
||||
|
||||
TELE_STAFF_REACH("TeleStaff: Range", ConfigCategories.MACHINE_VALUES, 100, 5, 200, "How far the TeleStaff can teleport you"),
|
||||
TELE_STAFF_ENERGY_USE("TeleStaff: Energy Use per Block", ConfigCategories.MACHINE_VALUES, 200, 1, 5000, "How much energy the TeleStaff uses per Block you teleport"),
|
||||
TELE_STAFF_WAIT_TIME("TeleStaff: Wait Time", ConfigCategories.MACHINE_VALUES, 30, 0, 500, "The time the TeleStaff takes between Teleports"),
|
||||
|
||||
GROWTH_RING_RANGE("Growth Ring: Range", ConfigCategories.MACHINE_VALUES, 3, 1, 30, "The Range the Growth Ring has"),
|
||||
GROWTH_RING_COOLDOWN("Growth Ring: Cooldown Time", ConfigCategories.MACHINE_VALUES, 30, 0, 1000, "The Time between Growth Bursts"),
|
||||
GROWTH_RING_ENERGY_USE("Growth Ring: Energy Used", ConfigCategories.MACHINE_VALUES, 550, 10, 6000, "The Amount of Energy used per Tick"),
|
||||
GROWTH_RING_GROWTH_PER_CYCLE("Growth Ring: Growth Ticks per Cycle", ConfigCategories.MACHINE_VALUES, 45, 1, 200, "The Amount of plants that get ticked per cycle"),
|
||||
|
||||
MAGNET_RING_RANGE("Magnet Ring: Range", ConfigCategories.MACHINE_VALUES, 5, 3, 30, "The Range of the Magnet Ring"),
|
||||
MAGNET_RING_ENERGY_USE("Magnet Ring: Energy Used", ConfigCategories.MACHINE_VALUES, 5, 0, 500, "The Amount of Energy the Magnet Ring uses per tick"),
|
||||
|
||||
WATER_RING_RANGE("Water Ring: Range", ConfigCategories.MACHINE_VALUES, 3, 1, 10, "The Range of the Water Ring"),
|
||||
WATER_RING_ENERGY_USE("Water Ring: Energy Used", ConfigCategories.MACHINE_VALUES, 30, 0, 500, "The Amount of Energy the Water Ring uses per Block"),
|
||||
|
||||
LEAF_GENERATOR_ENERGY_PRODUCED("Leaf Generator: Energy Produced", ConfigCategories.MACHINE_VALUES, 300, 1, 10000, "How much Energy the Leaf Generator produces per Leaf broken"),
|
||||
LEAF_GENERATOR_COOLDOWN_TIME("Leaf Generator: Cooldown Time", ConfigCategories.MACHINE_VALUES, 5, 0, 100, "The amount of ticks that it takes util another Leaf gets proken"),
|
||||
LEAF_GENERATOR_RANGE("Leaf Generator: Range", ConfigCategories.MACHINE_VALUES, 7, 1, 100, "The radius of a leaf generator"),
|
||||
|
||||
DIRECTIONAL_BREAKER_RF_PER_BLOCK("Directional Breaker: RF per Block", ConfigCategories.MACHINE_VALUES, 5, 0, 1000, "The amount of RF the Directional Breaker uses to break each block"),
|
||||
DIRECTIONAL_BREAKER_RANGE("Directional Breaker: Range", ConfigCategories.MACHINE_VALUES, 8, 1, 1000, "The range of the Directional Breaker"),
|
||||
|
||||
RANGED_COLLECTOR_RANGE("Ranged Collector: Range", ConfigCategories.MACHINE_VALUES, 6, 1, 30, "The range of the Ranged Collector"),
|
||||
RICE_AMOUNT("Rice: Amount", ConfigCategories.WORLD_GEN, 15, 1, 100, "The Amount of Rice generating"),
|
||||
CANOLA_AMOUNT("Canola: Amount", ConfigCategories.WORLD_GEN, 10, 1, 50, "The Amount of Canola generating"),
|
||||
FLAX_AMOUNT("Flax: Amount", ConfigCategories.WORLD_GEN, 8, 1, 50, "The Amount of Flax generating"),
|
||||
COFFEE_AMOUNT("Coffee: Amount", ConfigCategories.WORLD_GEN, 6, 1, 50, "The Amount of Coffee generating"),
|
||||
BLACK_LOTUS_AMOUNT("Black Lotus: Amount", ConfigCategories.WORLD_GEN, 14, 1, 50, "The Amount of Black Lotus generating"),
|
||||
|
||||
LASER_RELAY_LOSS("Laser Relay: Loss", ConfigCategories.MACHINE_VALUES, 5, 0, 80, "The Energy Loss of the Laser Relay per Transfer in Percent"),
|
||||
LASER_RELAY_MAX_DISTANCE("Laser Relay: Max Distance", ConfigCategories.MACHINE_VALUES, 15, 3, 80, "The max distance between two connected Laser Relays"),
|
||||
LASER_RELAY_MAX_TRANSFER("Laser Relay: Max Transfer", ConfigCategories.MACHINE_VALUES, 10000, 100, 1000000, "The max amount of RF a Laser Relay can receive and try to transfer (if it's given 100 RF and can only transfer 50, it will only accept 50, it won't waste any power!)"),
|
||||
|
||||
RECONSTRUCTOR_DISTANCE("Atomic Reconstructor: Distance", ConfigCategories.MACHINE_VALUES, 10, 1, 50, "The max distance the Reconstructor goes forward to find blocks to convert"),
|
||||
RECONSTRCUTOR_RANGE("Atomic Reconstructor: Range", ConfigCategories.MACHINE_VALUES, 2, 1, 10, "The range of Converting blocks or items into other blocks or items"),
|
||||
RECONSTRUCTOR_BASE_ENERGY_USE("Atomic Reconstructor: Base Energy Use", ConfigCategories.MACHINE_VALUES, 200, 0, 100000, "The base amount of Energy the Reconstructor uses per laser shot (extra energy, determined by the recipe, is used per conversion)"),
|
||||
RECONSTRUCTOR_COOLDOWN_TIMER("Atomic Reconstrucor: Cooldown Timer", ConfigCategories.MACHINE_VALUES, 100, 0, 10000, "The amount of time the Reconstructor waits between shooting lasers"),
|
||||
|
||||
TILE_ENTITY_UPDATE_INTERVAL("Tile Entities: Update Interval", ConfigCategories.OTHER, 5, 1, 100, "The amount of ticks waited before a TileEntity sends an additional Update to the Client");
|
||||
|
||||
public final String name;
|
||||
|
|
|
@ -28,81 +28,55 @@ public class CrusherCrafting{
|
|||
public static void init(){
|
||||
ModUtil.LOGGER.info("Initializing Crusher Recipes...");
|
||||
|
||||
if(ConfigCrafting.CRUSHER_MISC.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("itemBone", "boneMeal", 6);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("sugarCane", "sugar", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("itemBone", "boneMeal", 6);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("sugarCane", "sugar", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
|
||||
CrusherRecipeRegistry.addRecipe("flowerDandelion", "dyeYellow", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerPoppy", "dyeRed", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerOrchid", "dyeLightBlue", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerAllium", "dyeMagenta", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerBluet", "dyeLightGray", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerRedTulip", "dyeRed", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerOrangeTulip", "dyeOrange", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerWhiteTulip", "dyeLightGray", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerPinkTulip", "dyePink", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerDaisy", "dyeLightGray", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerSunflower", "dyeYellow", 4);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerLilac", "dyeMagenta", 4);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerRoseBush", "dyeRed", 4);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerPeony", "dyePink", 4);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
}
|
||||
CrusherRecipeRegistry.addRecipe("flowerDandelion", "dyeYellow", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerPoppy", "dyeRed", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerOrchid", "dyeLightBlue", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerAllium", "dyeMagenta", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerBluet", "dyeLightGray", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerRedTulip", "dyeRed", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerOrangeTulip", "dyeOrange", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerWhiteTulip", "dyeLightGray", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerPinkTulip", "dyePink", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerDaisy", "dyeLightGray", 3);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerSunflower", "dyeYellow", 4);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerLilac", "dyeMagenta", 4);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerRoseBush", "dyeRed", 4);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
CrusherRecipeRegistry.addRecipe("flowerPeony", "dyePink", 4);
|
||||
miscRecipes.add(Util.GetRecipes.lastCrusherRecipe());
|
||||
|
||||
if(ConfigCrafting.REDSTONE.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("oreRedstone", "dustRedstone", 10);
|
||||
}
|
||||
if(ConfigCrafting.LAPIS.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("oreLapis", "gemLapis", 12);
|
||||
}
|
||||
if(ConfigCrafting.COAL.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("coal", "dustCoal", 1);
|
||||
}
|
||||
if(ConfigCrafting.COAL_ORE.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("oreCoal", "coal", 3);
|
||||
}
|
||||
if(ConfigCrafting.COAL_BLOCKS.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("blockCoal", "coal", 9);
|
||||
}
|
||||
if(ConfigCrafting.QUARTZ_ORE.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("oreQuartz", "gemQuartz", 3);
|
||||
}
|
||||
CrusherRecipeRegistry.addRecipe("oreRedstone", "dustRedstone", 10);
|
||||
CrusherRecipeRegistry.addRecipe("oreLapis", "gemLapis", 12);
|
||||
CrusherRecipeRegistry.addRecipe("coal", "dustCoal", 1);
|
||||
CrusherRecipeRegistry.addRecipe("oreCoal", "coal", 3);
|
||||
CrusherRecipeRegistry.addRecipe("blockCoal", "coal", 9);
|
||||
CrusherRecipeRegistry.addRecipe("oreQuartz", "gemQuartz", 3);
|
||||
CrusherRecipeRegistry.addRecipe("cobblestone", "sand", 1);
|
||||
CrusherRecipeRegistry.addRecipe("gravel", "flint", 1);
|
||||
CrusherRecipeRegistry.addRecipe("stone", "cobblestone", 1);
|
||||
CrusherRecipeRegistry.addRecipe("cropRice", "sugar", 2);
|
||||
recipeSugar = Util.GetRecipes.lastCrusherRecipe();
|
||||
|
||||
if(ConfigCrafting.COBBLESTONE.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("cobblestone", "sand", 1);
|
||||
}
|
||||
if(ConfigCrafting.GRAVEL.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("gravel", "flint", 1);
|
||||
}
|
||||
if(ConfigCrafting.STONE.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("stone", "cobblestone", 1);
|
||||
}
|
||||
if(ConfigCrafting.RICE_SUGAR.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("cropRice", "sugar", 2);
|
||||
recipeSugar = Util.GetRecipes.lastCrusherRecipe();
|
||||
}
|
||||
CrusherRecipeRegistry.addRecipe("oreNickel", "dustNickel", 2, "dustPlatinum", 1, 15);
|
||||
CrusherRecipeRegistry.addRecipe("oreIron", "dustIron", 2, "dustGold", 1, 20);
|
||||
|
||||
if(ConfigCrafting.NICKEL.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("oreNickel", "dustNickel", 2, "dustPlatinum", 1, 15);
|
||||
}
|
||||
if(ConfigCrafting.IRON.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("oreIron", "dustIron", 2, "dustGold", 1, 20);
|
||||
}
|
||||
if(ConfigCrafting.HORSE_ARMORS.isEnabled()){
|
||||
CrusherRecipeRegistry.addRecipe("armorHorseIron", "dustIron", 8);
|
||||
recipeIronHorseArmor = Util.GetRecipes.lastCrusherRecipe();
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.event;
|
|||
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigBoolValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.InitItems;
|
||||
import ellpeck.actuallyadditions.items.ItemWingsOfTheBats;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
|
@ -32,7 +31,7 @@ public class EntityLivingEvent{
|
|||
if(event.entityLiving != null && event.entityLiving.worldObj != null && !event.entityLiving.worldObj.isRemote){
|
||||
if((event.entityLiving instanceof EntityOcelot && ((EntityOcelot)event.entityLiving).isTamed()) || (event.entityLiving instanceof EntityPlayer && event.entityLiving.getUniqueID().equals(/*KittyVanCat*/ UUID.fromString("681d4e20-10ef-40c9-a0a5-ba2f1995ef44")))){
|
||||
if(ConfigBoolValues.DO_CAT_DROPS.isEnabled()){
|
||||
if(Util.RANDOM.nextInt(ConfigIntValues.CAT_DROP_CHANCE.getValue())+1 == 1){
|
||||
if(Util.RANDOM.nextInt(5000)+1 == 1){
|
||||
EntityItem item = new EntityItem(event.entityLiving.worldObj, event.entityLiving.posX+0.5, event.entityLiving.posY+0.5, event.entityLiving.posZ+0.5, new ItemStack(InitItems.itemHairyBall));
|
||||
event.entityLiving.worldObj.spawnEntityInWorld(item);
|
||||
}
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.event;
|
|||
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigBoolValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.InitItems;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheMiscItems;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheSpecialDrops;
|
||||
|
@ -41,14 +40,14 @@ public class LivingDropEvent{
|
|||
|
||||
//Drop Cobwebs from Spiders
|
||||
if(ConfigBoolValues.DO_SPIDER_DROPS.isEnabled() && event.entityLiving instanceof EntitySpider){
|
||||
if(Util.RANDOM.nextInt(ConfigIntValues.SPIDER_DROP_CHANCE.getValue()) <= 0){
|
||||
if(Util.RANDOM.nextInt(500) <= 0){
|
||||
event.entityLiving.entityDropItem(new ItemStack(Blocks.web, Util.RANDOM.nextInt(2)+1), 0);
|
||||
}
|
||||
}
|
||||
|
||||
//Drop Wings from Bats
|
||||
if(ConfigBoolValues.DO_BAT_DROPS.isEnabled() && event.entityLiving instanceof EntityBat){
|
||||
if(Util.RANDOM.nextInt(ConfigIntValues.BAT_DROP_CHANCE.getValue()) <= 0){
|
||||
if(Util.RANDOM.nextInt(30) <= 0){
|
||||
event.entityLiving.entityDropItem(new ItemStack(InitItems.itemMisc, Util.RANDOM.nextInt(2)+1, TheMiscItems.BAT_WING.ordinal()), 0);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -41,13 +41,13 @@ public class WorldDecorationEvent{
|
|||
|
||||
//Generate Treasure Chests
|
||||
if(ConfigBoolValues.DO_TREASURE_CHEST_GEN.isEnabled()){
|
||||
if(event.rand.nextInt(ConfigIntValues.TREASURE_CHEST_CHANCE.getValue()) == 0){
|
||||
if(event.rand.nextInt(300) == 0){
|
||||
int genX = event.chunkX+event.rand.nextInt(16)+8;
|
||||
int genZ = event.chunkZ+event.rand.nextInt(16)+8;
|
||||
int genY = event.world.getTopSolidOrLiquidBlock(genX, genZ);
|
||||
|
||||
if(event.world.getBiomeGenForCoords(genX, genZ) instanceof BiomeGenOcean){
|
||||
if(genY >= ConfigIntValues.TREASURE_CHEST_MIN_HEIGHT.getValue() && genY <= ConfigIntValues.TREASURE_CHEST_MAX_HEIGHT.getValue()){
|
||||
if(genY >= 25 && genY <= 45){
|
||||
if(event.world.getBlock(genX, genY, genZ).getMaterial() == Material.water){
|
||||
if(event.world.getBlock(genX, genY-1, genZ).getMaterial().isSolid()){
|
||||
event.world.setBlock(genX, genY, genZ, InitBlocks.blockTreasureChest, event.rand.nextInt(4), 2);
|
||||
|
@ -63,7 +63,7 @@ public class WorldDecorationEvent{
|
|||
private void generateRice(DecorateBiomeEvent event){
|
||||
if(ConfigBoolValues.DO_RICE_GEN.isEnabled()){
|
||||
for(int i = 0; i < ConfigIntValues.RICE_AMOUNT.getValue(); i++){
|
||||
if(event.rand.nextInt(ConfigIntValues.RICE_CHANCE.getValue()) == 0){
|
||||
if(event.rand.nextInt(50) == 0){
|
||||
int genX = event.chunkX+event.rand.nextInt(16)+8;
|
||||
int genZ = event.chunkZ+event.rand.nextInt(16)+8;
|
||||
int genY = event.world.getTopSolidOrLiquidBlock(genX, genZ);
|
||||
|
@ -85,7 +85,7 @@ public class WorldDecorationEvent{
|
|||
private void genPlantNormally(Block plant, int meta, int amount, boolean doIt, Material blockBelow, DecorateBiomeEvent event){
|
||||
if(doIt){
|
||||
for(int i = 0; i < amount; i++){
|
||||
if(event.rand.nextInt(ConfigIntValues.NORMAL_PLANT_CHANCE.getValue()) == 0){
|
||||
if(event.rand.nextInt(400) == 0){
|
||||
int genX = event.chunkX+event.rand.nextInt(16)+8;
|
||||
int genZ = event.chunkZ+event.rand.nextInt(16)+8;
|
||||
int genY = event.world.getTopSolidOrLiquidBlock(genX, genZ)-1;
|
||||
|
|
|
@ -16,7 +16,6 @@ import ellpeck.actuallyadditions.blocks.InitBlocks;
|
|||
import ellpeck.actuallyadditions.blocks.metalists.TheMiscBlocks;
|
||||
import ellpeck.actuallyadditions.config.ConfigValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigBoolValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import net.minecraft.block.Block;
|
||||
|
@ -31,6 +30,9 @@ import java.util.Random;
|
|||
|
||||
public class OreGen implements IWorldGenerator{
|
||||
|
||||
public static final int QUARTZ_MIN = 0;
|
||||
public static final int QUARTZ_MAX = 45;
|
||||
|
||||
public static void init(){
|
||||
ModUtil.LOGGER.info("Registering World Generator...");
|
||||
GameRegistry.registerWorldGenerator(new OreGen(), 10);
|
||||
|
@ -68,7 +70,7 @@ public class OreGen implements IWorldGenerator{
|
|||
|
||||
private void generateSurface(World world, Random random, int x, int z){
|
||||
if(ConfigBoolValues.GENERATE_QUARTZ.isEnabled()){
|
||||
this.addOreSpawn(InitBlocks.blockMisc, TheMiscBlocks.ORE_QUARTZ.ordinal(), Blocks.stone, world, random, x, z, MathHelper.getRandomIntegerInRange(random, ConfigIntValues.BLACK_QUARTZ_BASE_AMOUNT.getValue(), ConfigIntValues.BLACK_QUARTZ_ADD_CHANCE.getValue()), ConfigIntValues.BLACK_QUARTZ_CHANCE.getValue(), ConfigIntValues.BLACK_QUARTZ_MIN_HEIGHT.getValue(), ConfigIntValues.BLACK_QUARTZ_MAX_HEIGHT.getValue());
|
||||
this.addOreSpawn(InitBlocks.blockMisc, TheMiscBlocks.ORE_QUARTZ.ordinal(), Blocks.stone, world, random, x, z, MathHelper.getRandomIntegerInRange(random, 5, 8), 10, QUARTZ_MIN, QUARTZ_MAX);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -74,7 +74,7 @@ public class GuiCoffeeMachine extends GuiContainer{
|
|||
this.func_146283_a(Collections.singletonList(text3), x, y);
|
||||
}
|
||||
|
||||
String text2 = this.machine.coffeeCacheAmount+"/"+this.machine.coffeeCacheMaxAmount+" "+StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.coffee");
|
||||
String text2 = this.machine.coffeeCacheAmount+"/"+TileEntityCoffeeMachine.COFFEE_CACHE_MAX_AMOUNT+" "+StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.coffee");
|
||||
if(x >= guiLeft+40 && y >= guiTop+25 && x <= guiLeft+49 && y <= guiTop+56){
|
||||
this.func_146283_a(Collections.singletonList(text2), x, y);
|
||||
}
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.inventory.gui;
|
|||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.inventory.ContainerFeeder;
|
||||
import ellpeck.actuallyadditions.tile.TileEntityBase;
|
||||
import ellpeck.actuallyadditions.tile.TileEntityFeeder;
|
||||
|
@ -43,7 +42,7 @@ public class GuiFeeder extends GuiContainer{
|
|||
public void drawScreen(int x, int y, float f){
|
||||
super.drawScreen(x, y, f);
|
||||
if(x >= guiLeft+69 && y >= guiTop+30 && x <= guiLeft+69+10 && y <= guiTop+30+10){
|
||||
String[] array = new String[]{(this.tileFeeder.currentAnimalAmount+" "+StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.animals")), ((this.tileFeeder.currentAnimalAmount >= 2 && this.tileFeeder.currentAnimalAmount < ConfigIntValues.FEEDER_THRESHOLD.getValue()) ? StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.enoughToBreed") : (this.tileFeeder.currentAnimalAmount >= ConfigIntValues.FEEDER_THRESHOLD.getValue() ? StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.tooMany") : StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.notEnough")))};
|
||||
String[] array = new String[]{(this.tileFeeder.currentAnimalAmount+" "+StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.animals")), ((this.tileFeeder.currentAnimalAmount >= 2 && this.tileFeeder.currentAnimalAmount < TileEntityFeeder.THRESHOLD) ? StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.enoughToBreed") : (this.tileFeeder.currentAnimalAmount >= TileEntityFeeder.THRESHOLD ? StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.tooMany") : StringUtil.localize("info."+ModUtil.MOD_ID_LOWER+".gui.notEnough")))};
|
||||
this.func_146283_a(Arrays.asList(array), x, y);
|
||||
}
|
||||
}
|
||||
|
@ -66,11 +65,11 @@ public class GuiFeeder extends GuiContainer{
|
|||
this.drawTexturedModalRect(guiLeft+85, guiTop+42-i, 181, 19+19-i, 6, 20);
|
||||
}
|
||||
|
||||
if(this.tileFeeder.currentAnimalAmount >= 2 && this.tileFeeder.currentAnimalAmount < ConfigIntValues.FEEDER_THRESHOLD.getValue()){
|
||||
if(this.tileFeeder.currentAnimalAmount >= 2 && this.tileFeeder.currentAnimalAmount < TileEntityFeeder.THRESHOLD){
|
||||
this.drawTexturedModalRect(guiLeft+70, guiTop+31, 192, 16, 8, 8);
|
||||
}
|
||||
|
||||
if(this.tileFeeder.currentAnimalAmount >= ConfigIntValues.FEEDER_THRESHOLD.getValue()){
|
||||
if(this.tileFeeder.currentAnimalAmount >= TileEntityFeeder.THRESHOLD){
|
||||
this.drawTexturedModalRect(guiLeft+70, guiTop+31, 192, 24, 8, 8);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,7 +13,6 @@ package ellpeck.actuallyadditions.items;
|
|||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheMiscItems;
|
||||
import ellpeck.actuallyadditions.util.IActAddItemOrBlock;
|
||||
import ellpeck.actuallyadditions.util.ItemUtil;
|
||||
|
@ -39,7 +38,7 @@ public class ItemCoffee extends ItemFood implements IActAddItemOrBlock{
|
|||
|
||||
public ItemCoffee(){
|
||||
super(8, 5.0F, false);
|
||||
this.setMaxDamage(ConfigIntValues.COFFEE_DRINK_AMOUNT.getValue()-1);
|
||||
this.setMaxDamage(3);
|
||||
this.setAlwaysEdible();
|
||||
this.setMaxStackSize(1);
|
||||
this.setNoRepair();
|
||||
|
|
|
@ -16,8 +16,6 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.ActuallyAdditions;
|
||||
import ellpeck.actuallyadditions.config.ConfigValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigFloatValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.inventory.GuiHandler;
|
||||
import ellpeck.actuallyadditions.util.ItemUtil;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
|
@ -57,6 +55,8 @@ public class ItemDrill extends ItemEnergy{
|
|||
@SideOnly(Side.CLIENT)
|
||||
private IIcon purpleIcon;
|
||||
|
||||
private static final int ENERGY_USE = 100;
|
||||
|
||||
public ItemDrill(){
|
||||
super(500000, 5000);
|
||||
this.setMaxDamage(0);
|
||||
|
@ -245,7 +245,7 @@ public class ItemDrill extends ItemEnergy{
|
|||
@Override
|
||||
public Multimap getAttributeModifiers(ItemStack stack){
|
||||
Multimap map = super.getAttributeModifiers(stack);
|
||||
map.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(), new AttributeModifier(field_111210_e, "Drill Modifier", this.getEnergyStored(stack) >= ConfigIntValues.DRILL_ENERGY_USE.getValue() ? 8.0F : 0.1F, 0));
|
||||
map.put(SharedMonsterAttributes.attackDamage.getAttributeUnlocalizedName(), new AttributeModifier(field_111210_e, "Drill Modifier", this.getEnergyStored(stack) >= ENERGY_USE ? 8.0F : 0.1F, 0));
|
||||
return map;
|
||||
}
|
||||
|
||||
|
@ -291,7 +291,8 @@ public class ItemDrill extends ItemEnergy{
|
|||
|
||||
@Override
|
||||
public boolean canHarvestBlock(Block block, ItemStack stack){
|
||||
return this.getEnergyStored(stack) >= this.getEnergyUsePerBlock(stack) && (this.hasExtraWhitelist(block) || block.getMaterial().isToolNotRequired() || (block == Blocks.snow_layer || block == Blocks.snow || (block == Blocks.obsidian ? ConfigIntValues.DRILL_HARVEST_LEVEL.getValue() >= 3 : (block != Blocks.diamond_block && block != Blocks.diamond_ore ? (block != Blocks.emerald_ore && block != Blocks.emerald_block ? (block != Blocks.gold_block && block != Blocks.gold_ore ? (block != Blocks.iron_block && block != Blocks.iron_ore ? (block != Blocks.lapis_block && block != Blocks.lapis_ore ? (block != Blocks.redstone_ore && block != Blocks.lit_redstone_ore ? (block.getMaterial() == Material.rock || (block.getMaterial() == Material.iron || block.getMaterial() == Material.anvil)) : ConfigIntValues.DRILL_HARVEST_LEVEL.getValue() >= 2) : ConfigIntValues.DRILL_HARVEST_LEVEL.getValue() >= 1) : ConfigIntValues.DRILL_HARVEST_LEVEL.getValue() >= 1) : ConfigIntValues.DRILL_HARVEST_LEVEL.getValue() >= 2) : ConfigIntValues.DRILL_HARVEST_LEVEL.getValue() >= 2) : ConfigIntValues.DRILL_HARVEST_LEVEL.getValue() >= 2))));
|
||||
int harvestLevel = this.getHarvestLevel(stack, "");
|
||||
return this.getEnergyStored(stack) >= this.getEnergyUsePerBlock(stack) && (this.hasExtraWhitelist(block) || block.getMaterial().isToolNotRequired() || (block == Blocks.snow_layer || block == Blocks.snow || (block == Blocks.obsidian ? harvestLevel >= 3 : (block != Blocks.diamond_block && block != Blocks.diamond_ore ? (block != Blocks.emerald_ore && block != Blocks.emerald_block ? (block != Blocks.gold_block && block != Blocks.gold_ore ? (block != Blocks.iron_block && block != Blocks.iron_ore ? (block != Blocks.lapis_block && block != Blocks.lapis_ore ? (block != Blocks.redstone_ore && block != Blocks.lit_redstone_ore ? (block.getMaterial() == Material.rock || (block.getMaterial() == Material.iron || block.getMaterial() == Material.anvil)) : harvestLevel >= 2) : harvestLevel >= 1) : harvestLevel >= 1) : harvestLevel >= 2) : harvestLevel >= 2) : harvestLevel >= 2))));
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -304,7 +305,7 @@ public class ItemDrill extends ItemEnergy{
|
|||
|
||||
@Override
|
||||
public int getHarvestLevel(ItemStack stack, String toolClass){
|
||||
return ConfigIntValues.DRILL_HARVEST_LEVEL.getValue();
|
||||
return 4;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -314,37 +315,37 @@ public class ItemDrill extends ItemEnergy{
|
|||
* @return The Energy use per Block
|
||||
*/
|
||||
public int getEnergyUsePerBlock(ItemStack stack){
|
||||
int use = ConfigIntValues.DRILL_ENERGY_USE.getValue();
|
||||
int use = ENERGY_USE;
|
||||
|
||||
//Speed
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.SPEED)){
|
||||
use += ConfigIntValues.DRILL_SPEED_EXTRA_USE.getValue();
|
||||
use += 50;
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.SPEED_II)){
|
||||
use += ConfigIntValues.DRILL_SPEED_II_EXTRA_USE.getValue();
|
||||
use += 75;
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.SPEED_III)){
|
||||
use += ConfigIntValues.DRILL_SPEED_III_EXTRA_USE.getValue();
|
||||
use += 175;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//Silk Touch
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.SILK_TOUCH)){
|
||||
use += ConfigIntValues.DRILL_SILK_EXTRA_USE.getValue();
|
||||
use += 100;
|
||||
}
|
||||
|
||||
//Fortune
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.FORTUNE)){
|
||||
use += ConfigIntValues.DRILL_FORTUNE_EXTRA_USE.getValue();
|
||||
use += 40;
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.FORTUNE_II)){
|
||||
use += ConfigIntValues.DRILL_FORTUNE_II_EXTRA_USE.getValue();
|
||||
use += 80;
|
||||
}
|
||||
}
|
||||
|
||||
//Size
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.THREE_BY_THREE)){
|
||||
use += ConfigIntValues.DRILL_THREE_BY_THREE_EXTRA_USE.getValue();
|
||||
use += 10;
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.FIVE_BY_FIVE)){
|
||||
use += ConfigIntValues.DRILL_FIVE_BY_FIVE_EXTRA_USE.getValue();
|
||||
use += 30;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -369,7 +370,7 @@ public class ItemDrill extends ItemEnergy{
|
|||
* @return The Mining Speed depending on the Speed Upgrades
|
||||
*/
|
||||
public float getEfficiencyFromUpgrade(ItemStack stack){
|
||||
float efficiency = ConfigFloatValues.DRILL_DAMAGE.getValue();
|
||||
float efficiency = 8.0F;
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.SPEED)){
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.SPEED_II)){
|
||||
if(this.getHasUpgrade(stack, ItemDrillUpgrade.UpgradeType.SPEED_III)){
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.items;
|
|||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
|
@ -47,7 +46,8 @@ public class ItemGrowthRing extends ItemEnergy{
|
|||
EntityPlayer player = (EntityPlayer)entity;
|
||||
ItemStack equipped = player.getCurrentEquippedItem();
|
||||
|
||||
if(equipped != null && equipped == stack && this.getEnergyStored(stack) >= ConfigIntValues.GROWTH_RING_ENERGY_USE.getValue()){
|
||||
int energyUse = 550;
|
||||
if(equipped != null && equipped == stack && this.getEnergyStored(stack) >= energyUse){
|
||||
ArrayList<WorldPos> blocks = new ArrayList<WorldPos>();
|
||||
|
||||
if(stack.stackTagCompound == null){
|
||||
|
@ -56,10 +56,11 @@ public class ItemGrowthRing extends ItemEnergy{
|
|||
int waitTime = stack.stackTagCompound.getInteger("WaitTime");
|
||||
|
||||
//Adding all possible Blocks
|
||||
if(waitTime >= ConfigIntValues.GROWTH_RING_COOLDOWN.getValue()){
|
||||
for(int x = -ConfigIntValues.GROWTH_RING_RANGE.getValue(); x < ConfigIntValues.GROWTH_RING_RANGE.getValue()+1; x++){
|
||||
for(int z = -ConfigIntValues.GROWTH_RING_RANGE.getValue(); z < ConfigIntValues.GROWTH_RING_RANGE.getValue()+1; z++){
|
||||
for(int y = -ConfigIntValues.GROWTH_RING_RANGE.getValue(); y < ConfigIntValues.GROWTH_RING_RANGE.getValue()+1; y++){
|
||||
if(waitTime >= 30){
|
||||
int range = 3;
|
||||
for(int x = -range; x < range+1; x++){
|
||||
for(int z = -range; z < range+1; z++){
|
||||
for(int y = -range; y < range+1; y++){
|
||||
int theX = MathHelper.floor_double(player.posX+x);
|
||||
int theY = MathHelper.floor_double(player.posY+y);
|
||||
int theZ = MathHelper.floor_double(player.posZ+z);
|
||||
|
@ -73,7 +74,7 @@ public class ItemGrowthRing extends ItemEnergy{
|
|||
|
||||
//Fertilizing the Blocks
|
||||
if(!blocks.isEmpty()){
|
||||
for(int i = 0; i < ConfigIntValues.GROWTH_RING_GROWTH_PER_CYCLE.getValue(); i++){
|
||||
for(int i = 0; i < 45; i++){
|
||||
WorldPos pos = blocks.get(Util.RANDOM.nextInt(blocks.size()));
|
||||
|
||||
int metaBefore = pos.getMetadata();
|
||||
|
@ -94,7 +95,7 @@ public class ItemGrowthRing extends ItemEnergy{
|
|||
|
||||
//Use Energy every tick
|
||||
if(!player.capabilities.isCreativeMode){
|
||||
this.extractEnergy(stack, ConfigIntValues.GROWTH_RING_ENERGY_USE.getValue(), false);
|
||||
this.extractEnergy(stack, energyUse, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,7 +13,6 @@ package ellpeck.actuallyadditions.items;
|
|||
import com.google.common.collect.Multimap;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.IActAddItemOrBlock;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
|
@ -27,7 +26,7 @@ import net.minecraft.util.IIcon;
|
|||
public class ItemKnife extends Item implements IActAddItemOrBlock{
|
||||
|
||||
public ItemKnife(){
|
||||
this.setMaxDamage(ConfigIntValues.KNIFE_DAMAGE.getValue());
|
||||
this.setMaxDamage(100);
|
||||
this.setMaxStackSize(1);
|
||||
this.setContainerItem(this);
|
||||
}
|
||||
|
|
|
@ -13,7 +13,6 @@ package ellpeck.actuallyadditions.items;
|
|||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigBoolValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.IActAddItemOrBlock;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
|
@ -95,9 +94,11 @@ public class ItemLeafBlower extends Item implements IActAddItemOrBlock{
|
|||
public void breakStuff(World world, int x, int y, int z){
|
||||
ArrayList<WorldPos> breakPositions = new ArrayList<WorldPos>();
|
||||
|
||||
for(int reachX = -ConfigIntValues.LEAF_BLOWER_RANGE_SIDES.getValue(); reachX < ConfigIntValues.LEAF_BLOWER_RANGE_SIDES.getValue()+1; reachX++){
|
||||
for(int reachZ = -ConfigIntValues.LEAF_BLOWER_RANGE_SIDES.getValue(); reachZ < ConfigIntValues.LEAF_BLOWER_RANGE_SIDES.getValue()+1; reachZ++){
|
||||
for(int reachY = (this.isAdvanced ? -ConfigIntValues.LEAF_BLOWER_RANGE_SIDES.getValue() : -ConfigIntValues.LEAF_BLOWER_RANGE_UP.getValue()); reachY < (this.isAdvanced ? ConfigIntValues.LEAF_BLOWER_RANGE_SIDES.getValue()+1 : ConfigIntValues.LEAF_BLOWER_RANGE_UP.getValue()+1); reachY++){
|
||||
int rangeSides = 5;
|
||||
int rangeUp = 1;
|
||||
for(int reachX = -rangeSides; reachX < rangeSides+1; reachX++){
|
||||
for(int reachZ = -rangeSides; reachZ < rangeSides+1; reachZ++){
|
||||
for(int reachY = (this.isAdvanced ? -rangeSides : -rangeUp); reachY < (this.isAdvanced ? rangeSides : rangeUp)+1; reachY++){
|
||||
//The current Block to break
|
||||
Block block = world.getBlock(x+reachX, y+reachY, z+reachZ);
|
||||
if(block != null && (block instanceof BlockBush || (this.isAdvanced && block.isLeaves(world, x+reachX, y+reachY, z+reachZ)))){
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.items;
|
|||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.entity.Entity;
|
||||
|
@ -36,9 +35,11 @@ public class ItemMagnetRing extends ItemEnergy{
|
|||
@SuppressWarnings("unchecked")
|
||||
@Override
|
||||
public void onUpdate(ItemStack stack, World world, Entity entity, int par4, boolean par5){
|
||||
if(this.getEnergyStored(stack) >= ConfigIntValues.MAGNET_RING_ENERGY_USE.getValue() && !entity.isSneaking()){
|
||||
int energyUse = 5;
|
||||
if(this.getEnergyStored(stack) >= energyUse && !entity.isSneaking()){
|
||||
//Get all the Items in the area
|
||||
ArrayList<EntityItem> items = (ArrayList<EntityItem>)world.getEntitiesWithinAABB(EntityItem.class, AxisAlignedBB.getBoundingBox(entity.posX-ConfigIntValues.MAGNET_RING_RANGE.getValue(), entity.posY-ConfigIntValues.MAGNET_RING_RANGE.getValue(), entity.posZ-ConfigIntValues.MAGNET_RING_RANGE.getValue(), entity.posX+ConfigIntValues.MAGNET_RING_RANGE.getValue(), entity.posY+ConfigIntValues.MAGNET_RING_RANGE.getValue(), entity.posZ+ConfigIntValues.MAGNET_RING_RANGE.getValue()));
|
||||
int range = 5;
|
||||
ArrayList<EntityItem> items = (ArrayList<EntityItem>)world.getEntitiesWithinAABB(EntityItem.class, AxisAlignedBB.getBoundingBox(entity.posX-range, entity.posY-range, entity.posZ-range, entity.posX+range, entity.posY+range, entity.posZ+range));
|
||||
if(!items.isEmpty()){
|
||||
for(EntityItem item : items){
|
||||
//If the Item is near enough to get picked up
|
||||
|
@ -58,7 +59,7 @@ public class ItemMagnetRing extends ItemEnergy{
|
|||
|
||||
//Use Energy per tick
|
||||
if(!((EntityPlayer)entity).capabilities.isCreativeMode){
|
||||
this.extractEnergy(stack, ConfigIntValues.MAGNET_RING_ENERGY_USE.getValue(), false);
|
||||
this.extractEnergy(stack, energyUse, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.items;
|
|||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
|
@ -38,7 +37,7 @@ public class ItemTeleStaff extends ItemEnergy{
|
|||
public ItemStack onItemRightClick(ItemStack stack, World world, EntityPlayer player){
|
||||
if(!world.isRemote){
|
||||
if(this.getWaitTime(stack) <= 0){
|
||||
MovingObjectPosition pos = WorldUtil.getNearestPositionWithAir(world, player, ConfigIntValues.TELE_STAFF_REACH.getValue());
|
||||
MovingObjectPosition pos = WorldUtil.getNearestPositionWithAir(world, player, 100);
|
||||
if(pos != null && (pos.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK || player.rotationPitch >= -5)){
|
||||
int side = pos.sideHit;
|
||||
if(side != -1){
|
||||
|
@ -47,14 +46,15 @@ public class ItemTeleStaff extends ItemEnergy{
|
|||
double x = pos.hitVec.xCoord-(side == 4 ? 0.5 : 0)+(side == 5 ? 0.5 : 0);
|
||||
double y = pos.hitVec.yCoord-(side == 0 ? 2.0 : 0)+(side == 1 ? 0.5 : 0);
|
||||
double z = pos.hitVec.zCoord-(side == 2 ? 0.5 : 0)+(side == 3 ? 0.5 : 0);
|
||||
int use = ConfigIntValues.TELE_STAFF_ENERGY_USE.getValue()+(int)(ConfigIntValues.TELE_STAFF_ENERGY_USE.getValue()*pos.hitVec.distanceTo(Vec3.createVectorHelper(player.posX, player.posY+(player.getEyeHeight()-player.getDefaultEyeHeight()), player.posZ)));
|
||||
int baseUse = 200;
|
||||
int use = baseUse+(int)(baseUse*pos.hitVec.distanceTo(Vec3.createVectorHelper(player.posX, player.posY+(player.getEyeHeight()-player.getDefaultEyeHeight()), player.posZ)));
|
||||
if(this.getEnergyStored(stack) >= use){
|
||||
((EntityPlayerMP)player).playerNetServerHandler.setPlayerLocation(x, y, z, player.rotationYaw, player.rotationPitch);
|
||||
player.mountEntity(null);
|
||||
world.playSoundAtEntity(player, "mob.endermen.portal", 1.0F, 1.0F);
|
||||
if(!player.capabilities.isCreativeMode){
|
||||
this.extractEnergy(stack, use, false);
|
||||
this.setWaitTime(stack, ConfigIntValues.TELE_STAFF_WAIT_TIME.getValue());
|
||||
this.setWaitTime(stack, 50);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.items;
|
|||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||
import net.minecraft.entity.Entity;
|
||||
|
@ -39,22 +38,24 @@ public class ItemWaterRemovalRing extends ItemEnergy{
|
|||
EntityPlayer player = (EntityPlayer)entity;
|
||||
ItemStack equipped = player.getCurrentEquippedItem();
|
||||
|
||||
if(equipped != null && equipped == stack && this.getEnergyStored(stack) >= ConfigIntValues.WATER_RING_ENERGY_USE.getValue()){
|
||||
int energyUse = 30;
|
||||
if(equipped != null && equipped == stack && this.getEnergyStored(stack) >= energyUse){
|
||||
|
||||
//Setting everything to air
|
||||
for(int x = -ConfigIntValues.WATER_RING_RANGE.getValue(); x < ConfigIntValues.WATER_RING_RANGE.getValue()+1; x++){
|
||||
for(int z = -ConfigIntValues.WATER_RING_RANGE.getValue(); z < ConfigIntValues.WATER_RING_RANGE.getValue()+1; z++){
|
||||
for(int y = -ConfigIntValues.WATER_RING_RANGE.getValue(); y < ConfigIntValues.WATER_RING_RANGE.getValue()+1; y++){
|
||||
int range = 3;
|
||||
for(int x = -range; x < range+1; x++){
|
||||
for(int z = -range; z < range+1; z++){
|
||||
for(int y = -range; y < range+1; y++){
|
||||
int theX = MathHelper.floor_double(player.posX+x);
|
||||
int theY = MathHelper.floor_double(player.posY+y);
|
||||
int theZ = MathHelper.floor_double(player.posZ+z);
|
||||
if(this.getEnergyStored(stack) >= ConfigIntValues.WATER_RING_ENERGY_USE.getValue()){
|
||||
if(this.getEnergyStored(stack) >= energyUse){
|
||||
//Remove Water
|
||||
if(world.getBlock(theX, theY, theZ) == Blocks.water || world.getBlock(theX, theY, theZ) == Blocks.flowing_water){
|
||||
world.setBlockToAir(theX, theY, theZ);
|
||||
|
||||
if(!player.capabilities.isCreativeMode){
|
||||
this.extractEnergy(stack, ConfigIntValues.WATER_RING_ENERGY_USE.getValue(), false);
|
||||
this.extractEnergy(stack, energyUse, false);
|
||||
}
|
||||
}
|
||||
//Remove Lava
|
||||
|
@ -62,7 +63,7 @@ public class ItemWaterRemovalRing extends ItemEnergy{
|
|||
world.setBlockToAir(theX, theY, theZ);
|
||||
|
||||
if(!player.capabilities.isCreativeMode){
|
||||
this.extractEnergy(stack, ConfigIntValues.WATER_RING_ENERGY_USE.getValue()*2, false);
|
||||
this.extractEnergy(stack, energyUse*2, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.material;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import net.minecraft.item.ItemArmor;
|
||||
import net.minecraftforge.common.util.EnumHelper;
|
||||
|
@ -24,9 +23,8 @@ public class InitArmorMaterials{
|
|||
public static void init(){
|
||||
ModUtil.LOGGER.info("Initializing Armor Materials...");
|
||||
|
||||
armorMaterialEmerald = EnumHelper.addArmorMaterial("armorMaterialEmerald", ConfigIntValues.EMERALD_ARMOR_DURABILITY.getValue(), new int[]{ConfigIntValues.EMERALD_ARMOR_HEAD_DAMAGE.getValue(), ConfigIntValues.EMERALD_ARMOR_CHEST_DAMAGE.getValue(), ConfigIntValues.EMERALD_ARMOR_LEGS_DAMAGE.getValue(), ConfigIntValues.EMERALD_ARMOR_BOOTS_DAMAGE.getValue()}, ConfigIntValues.EMERALD_ARMOR_ENCHANTABILITY.getValue());
|
||||
armorMaterialObsidian = EnumHelper.addArmorMaterial("armorMaterialObsidian", ConfigIntValues.OBSIDIAN_ARMOR_DURABILITY.getValue(), new int[]{ConfigIntValues.OBSIDIAN_ARMOR_HEAD_DAMAGE.getValue(), ConfigIntValues.OBSIDIAN_ARMOR_CHEST_DAMAGE.getValue(), ConfigIntValues.OBSIDIAN_ARMOR_LEGS_DAMAGE.getValue(), ConfigIntValues.OBSIDIAN_ARMOR_BOOTS_DAMAGE.getValue()}, ConfigIntValues.OBSIDIAN_ARMOR_ENCHANTABILITY.getValue());
|
||||
armorMaterialQuartz = EnumHelper.addArmorMaterial("armorMaterialQuartz", ConfigIntValues.QUARTZ_ARMOR_DURABILITY.getValue(), new int[]{ConfigIntValues.QUARTZ_ARMOR_HEAD_DAMAGE.getValue(), ConfigIntValues.QUARTZ_ARMOR_CHEST_DAMAGE.getValue(), ConfigIntValues.QUARTZ_ARMOR_LEGS_DAMAGE.getValue(), ConfigIntValues.QUARTZ_ARMOR_BOOTS_DAMAGE.getValue()}, ConfigIntValues.QUARTZ_ARMOR_ENCHANTABILITY.getValue());
|
||||
|
||||
armorMaterialEmerald = EnumHelper.addArmorMaterial("armorMaterialEmerald", 1500, new int[]{5, 9, 8, 5}, 15);
|
||||
armorMaterialObsidian = EnumHelper.addArmorMaterial("armorMaterialObsidian", 7000, new int[]{3, 4, 3, 1}, 10);
|
||||
armorMaterialQuartz = EnumHelper.addArmorMaterial("armorMaterialQuartz", 200, new int[]{3, 6, 5, 3}, 8);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,8 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.material;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigFloatValues;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import net.minecraft.item.Item.ToolMaterial;
|
||||
import net.minecraftforge.common.util.EnumHelper;
|
||||
|
@ -25,9 +23,9 @@ public class InitToolMaterials{
|
|||
public static void init(){
|
||||
ModUtil.LOGGER.info("Initializing Tool Materials...");
|
||||
|
||||
toolMaterialEmerald = EnumHelper.addToolMaterial("toolMaterialEmerald", ConfigIntValues.EMERALD_HARVEST_LEVEL.getValue(), ConfigIntValues.EMERALD_USES.getValue(), ConfigFloatValues.EMERALD_SPEED.getValue(), ConfigFloatValues.EMERALD_MAX_DAMAGE.getValue(), ConfigIntValues.EMERALD_ENCHANTABILITY.getValue());
|
||||
toolMaterialObsidian = EnumHelper.addToolMaterial("toolMaterialObsidian", ConfigIntValues.OBSIDIAN_HARVEST_LEVEL.getValue(), ConfigIntValues.OBSIDIAN_USES.getValue(), ConfigFloatValues.OBSIDIAN_SPEED.getValue(), ConfigFloatValues.OBSIDIAN_MAX_DAMAGE.getValue(), ConfigIntValues.OBSIDIAN_ENCHANTABILITY.getValue());
|
||||
toolMaterialQuartz = EnumHelper.addToolMaterial("toolMaterialQuartz", ConfigIntValues.QUARTZ_HARVEST_LEVEL.getValue(), ConfigIntValues.QUARTZ_USES.getValue(), ConfigFloatValues.QUARTZ_SPEED.getValue(), ConfigFloatValues.QUARTZ_MAX_DAMAGE.getValue(), ConfigIntValues.QUARTZ_ENCHANTABILITY.getValue());
|
||||
toolMaterialEmerald = EnumHelper.addToolMaterial("toolMaterialEmerald", 3, 2000, 9.0F, 5.0F, 15);
|
||||
toolMaterialObsidian = EnumHelper.addToolMaterial("toolMaterialObsidian", 3, 8000, 4.0F, 2.0F, 15);
|
||||
toolMaterialQuartz = EnumHelper.addToolMaterial("toolMaterialQuartz", 2, 280, 6.5F, 2.0F, 10);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -110,7 +110,7 @@ public class LaserRelayConnectionHandler{
|
|||
*/
|
||||
public boolean addConnection(WorldPos firstRelay, WorldPos secondRelay){
|
||||
int distance = (int)firstRelay.toVec().distanceTo(secondRelay.toVec());
|
||||
if(distance > ConfigIntValues.LASER_RELAY_MAX_DISTANCE.getValue() || firstRelay.isEqual(secondRelay) || firstRelay.getWorld() != secondRelay.getWorld()){
|
||||
if(distance > TileEntityLaserRelay.MAX_DISTANCE || firstRelay.isEqual(secondRelay) || firstRelay.getWorld() != secondRelay.getWorld()){
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
|
@ -18,11 +18,11 @@ import codechicken.nei.recipe.TemplateRecipeHandler;
|
|||
import ellpeck.actuallyadditions.blocks.InitBlocks;
|
||||
import ellpeck.actuallyadditions.booklet.BookletUtils;
|
||||
import ellpeck.actuallyadditions.booklet.page.BookletPage;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.inventory.gui.GuiCoffeeMachine;
|
||||
import ellpeck.actuallyadditions.items.InitItems;
|
||||
import ellpeck.actuallyadditions.items.ItemCoffee;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheMiscItems;
|
||||
import ellpeck.actuallyadditions.tile.TileEntityCoffeeMachine;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import ellpeck.actuallyadditions.util.StringUtil;
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
|
@ -150,7 +150,7 @@ public class NEICoffeeMachineRecipe extends TemplateRecipeHandler implements INE
|
|||
|
||||
public CachedCoffee(ItemCoffee.Ingredient ingredient){
|
||||
this.cup = new PositionedStack(new ItemStack(InitItems.itemMisc, 1, TheMiscItems.CUP.ordinal()), 45, 39);
|
||||
this.coffeeBeans = new PositionedStack(new ItemStack(InitItems.itemCoffeeBean, ConfigIntValues.COFFEE_CACHE_USED_PER_ITEM.getValue()), 2, 39);
|
||||
this.coffeeBeans = new PositionedStack(new ItemStack(InitItems.itemCoffeeBean, TileEntityCoffeeMachine.CACHE_USE), 2, 39);
|
||||
this.ingredientStack = new PositionedStack(ingredient.ingredient.copy(), 90, 21);
|
||||
this.setupResult(ingredient);
|
||||
this.extraText = ingredient.getExtraText();
|
||||
|
|
|
@ -18,9 +18,9 @@ import codechicken.nei.recipe.TemplateRecipeHandler;
|
|||
import ellpeck.actuallyadditions.blocks.InitBlocks;
|
||||
import ellpeck.actuallyadditions.booklet.BookletUtils;
|
||||
import ellpeck.actuallyadditions.booklet.page.BookletPage;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.InitItems;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheMiscItems;
|
||||
import ellpeck.actuallyadditions.tile.TileEntityCompost;
|
||||
import ellpeck.actuallyadditions.util.ModUtil;
|
||||
import ellpeck.actuallyadditions.util.StringUtil;
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
|
@ -57,7 +57,7 @@ public class NEICompostRecipe extends TemplateRecipeHandler implements INEIRecip
|
|||
@Override
|
||||
public void loadCraftingRecipes(String outputId, Object... results){
|
||||
if(outputId.equals(NAME) && getClass() == NEICompostRecipe.class){
|
||||
arecipes.add(new CachedCompostRecipe(new ItemStack(InitItems.itemMisc, ConfigIntValues.COMPOST_AMOUNT.getValue(), TheMiscItems.MASHED_FOOD.ordinal()), new ItemStack(InitItems.itemFertilizer, ConfigIntValues.COMPOST_AMOUNT.getValue())));
|
||||
arecipes.add(new CachedCompostRecipe(new ItemStack(InitItems.itemMisc, TileEntityCompost.AMOUNT, TheMiscItems.MASHED_FOOD.ordinal()), new ItemStack(InitItems.itemFertilizer, TileEntityCompost.AMOUNT)));
|
||||
}
|
||||
else{
|
||||
super.loadCraftingRecipes(outputId, results);
|
||||
|
@ -67,14 +67,14 @@ public class NEICompostRecipe extends TemplateRecipeHandler implements INEIRecip
|
|||
@Override
|
||||
public void loadCraftingRecipes(ItemStack result){
|
||||
if(NEIServerUtils.areStacksSameType(new ItemStack(InitItems.itemFertilizer), result)){
|
||||
arecipes.add(new CachedCompostRecipe(new ItemStack(InitItems.itemMisc, ConfigIntValues.COMPOST_AMOUNT.getValue(), TheMiscItems.MASHED_FOOD.ordinal()), new ItemStack(InitItems.itemFertilizer, ConfigIntValues.COMPOST_AMOUNT.getValue())));
|
||||
arecipes.add(new CachedCompostRecipe(new ItemStack(InitItems.itemMisc, TileEntityCompost.AMOUNT, TheMiscItems.MASHED_FOOD.ordinal()), new ItemStack(InitItems.itemFertilizer, TileEntityCompost.AMOUNT)));
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void loadUsageRecipes(ItemStack ingredient){
|
||||
if(NEIServerUtils.areStacksSameTypeCrafting(new ItemStack(InitItems.itemMisc, ConfigIntValues.COMPOST_AMOUNT.getValue(), TheMiscItems.MASHED_FOOD.ordinal()), ingredient)){
|
||||
CachedCompostRecipe theRecipe = new CachedCompostRecipe(new ItemStack(InitItems.itemMisc, ConfigIntValues.COMPOST_AMOUNT.getValue(), TheMiscItems.MASHED_FOOD.ordinal()), new ItemStack(InitItems.itemFertilizer, ConfigIntValues.COMPOST_AMOUNT.getValue()));
|
||||
if(NEIServerUtils.areStacksSameTypeCrafting(new ItemStack(InitItems.itemMisc, TileEntityCompost.AMOUNT, TheMiscItems.MASHED_FOOD.ordinal()), ingredient)){
|
||||
CachedCompostRecipe theRecipe = new CachedCompostRecipe(new ItemStack(InitItems.itemMisc, TileEntityCompost.AMOUNT, TheMiscItems.MASHED_FOOD.ordinal()), new ItemStack(InitItems.itemFertilizer, TileEntityCompost.AMOUNT));
|
||||
theRecipe.setIngredientPermutation(Collections.singletonList(theRecipe.input), ingredient);
|
||||
arecipes.add(theRecipe);
|
||||
}
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.recipe;
|
|||
|
||||
import ellpeck.actuallyadditions.blocks.metalists.TheColoredLampColors;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigCrafting;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.AssetUtil;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import net.minecraft.item.Item;
|
||||
|
@ -179,7 +178,7 @@ public class ReconstructorRecipeHandler{
|
|||
}
|
||||
|
||||
public int getDistance(){
|
||||
return ConfigIntValues.RECONSTRUCTOR_DISTANCE.getValue()*(this == DETONATION ? 3 : 1);
|
||||
return this == DETONATION ? 30 : 10;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -13,7 +13,6 @@ package ellpeck.actuallyadditions.tile;
|
|||
import cofh.api.energy.EnergyStorage;
|
||||
import cofh.api.energy.IEnergyReceiver;
|
||||
import cpw.mods.fml.common.network.NetworkRegistry;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.IReconstructorLens;
|
||||
import ellpeck.actuallyadditions.misc.DamageSources;
|
||||
import ellpeck.actuallyadditions.network.PacketAtomicReconstructor;
|
||||
|
@ -38,6 +37,8 @@ public class TileEntityAtomicReconstructor extends TileEntityInventoryBase imple
|
|||
|
||||
private int currentTime;
|
||||
|
||||
public static final int ENERGY_USE = 200;
|
||||
|
||||
public TileEntityAtomicReconstructor(){
|
||||
super(1, "reconstructor");
|
||||
}
|
||||
|
@ -47,15 +48,14 @@ public class TileEntityAtomicReconstructor extends TileEntityInventoryBase imple
|
|||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!this.worldObj.isRemote){
|
||||
int baseUse = ConfigIntValues.RECONSTRUCTOR_BASE_ENERGY_USE.getValue();
|
||||
if(!worldObj.isBlockIndirectlyGettingPowered(xCoord, yCoord, zCoord) && this.storage.getEnergyStored() >= baseUse){
|
||||
if(!worldObj.isBlockIndirectlyGettingPowered(xCoord, yCoord, zCoord) && this.storage.getEnergyStored() >= ENERGY_USE){
|
||||
if(this.currentTime > 0){
|
||||
this.currentTime--;
|
||||
if(this.currentTime <= 0){
|
||||
ForgeDirection sideToManipulate = ForgeDirection.getOrientation(worldObj.getBlockMetadata(xCoord, yCoord, zCoord));
|
||||
//Extract energy for shooting the laser itself too!
|
||||
this.storage.extractEnergy(baseUse, false);
|
||||
if(this.storage.getEnergyStored() >= baseUse){
|
||||
this.storage.extractEnergy(ENERGY_USE, false);
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE){
|
||||
|
||||
//The Lens the Reconstructor currently has installed
|
||||
ReconstructorRecipeHandler.LensType currentLens = this.getCurrentLens();
|
||||
|
@ -70,7 +70,7 @@ public class TileEntityAtomicReconstructor extends TileEntityInventoryBase imple
|
|||
|
||||
//Detonation
|
||||
if(currentLens == ReconstructorRecipeHandler.LensType.DETONATION){
|
||||
int use = baseUse+500000;
|
||||
int use = ENERGY_USE+500000;
|
||||
if(this.storage.getEnergyStored() >= use){
|
||||
this.worldObj.newExplosion(null, hitBlock.getX()+0.5, hitBlock.getY()+0.5, hitBlock.getZ()+0.5, 10F, true, true);
|
||||
this.storage.extractEnergy(use, false);
|
||||
|
@ -78,17 +78,17 @@ public class TileEntityAtomicReconstructor extends TileEntityInventoryBase imple
|
|||
}
|
||||
//Conversion Recipes
|
||||
else{
|
||||
int range = ConfigIntValues.RECONSTRCUTOR_RANGE.getValue();
|
||||
int range = 2;
|
||||
|
||||
//Converting the Blocks
|
||||
for(int reachX = -range; reachX < range+1; reachX++){
|
||||
for(int reachZ = -range; reachZ < range+1; reachZ++){
|
||||
for(int reachY = -range; reachY < range+1; reachY++){
|
||||
if(this.storage.getEnergyStored() >= baseUse){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE){
|
||||
WorldPos pos = new WorldPos(worldObj, hitBlock.getX()+reachX, hitBlock.getY()+reachY, hitBlock.getZ()+reachZ);
|
||||
ArrayList<ReconstructorRecipeHandler.Recipe> recipes = ReconstructorRecipeHandler.getRecipes(new ItemStack(pos.getBlock(), 1, pos.getMetadata()));
|
||||
for(ReconstructorRecipeHandler.Recipe recipe : recipes){
|
||||
if(recipe != null && this.storage.getEnergyStored() >= baseUse+recipe.energyUse && recipe.type == currentLens){
|
||||
if(recipe != null && this.storage.getEnergyStored() >= ENERGY_USE+recipe.energyUse && recipe.type == currentLens){
|
||||
ItemStack output = recipe.getFirstOutput();
|
||||
if(output != null){
|
||||
if(output.getItem() instanceof ItemBlock){
|
||||
|
@ -99,7 +99,7 @@ public class TileEntityAtomicReconstructor extends TileEntityInventoryBase imple
|
|||
EntityItem item = new EntityItem(worldObj, pos.getX()+0.5, pos.getY()+0.5, pos.getZ()+0.5, output.copy());
|
||||
worldObj.spawnEntityInWorld(item);
|
||||
}
|
||||
this.storage.extractEnergy(baseUse+recipe.energyUse, false);
|
||||
this.storage.extractEnergy(ENERGY_USE+recipe.energyUse, false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -112,19 +112,19 @@ public class TileEntityAtomicReconstructor extends TileEntityInventoryBase imple
|
|||
//Converting the Items
|
||||
ArrayList<EntityItem> items = (ArrayList<EntityItem>)worldObj.getEntitiesWithinAABB(EntityItem.class, AxisAlignedBB.getBoundingBox(hitBlock.getX()-range, hitBlock.getY()-range, hitBlock.getZ()-range, hitBlock.getX()+range, hitBlock.getY()+range, hitBlock.getZ()+range));
|
||||
for(EntityItem item : items){
|
||||
if(this.storage.getEnergyStored() >= baseUse){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE){
|
||||
ItemStack stack = item.getEntityItem();
|
||||
if(stack != null){
|
||||
ArrayList<ReconstructorRecipeHandler.Recipe> recipes = ReconstructorRecipeHandler.getRecipes(stack);
|
||||
for(ReconstructorRecipeHandler.Recipe recipe : recipes){
|
||||
if(recipe != null && this.storage.getEnergyStored() >= baseUse+recipe.energyUse && recipe.type == currentLens){
|
||||
if(recipe != null && this.storage.getEnergyStored() >= ENERGY_USE+recipe.energyUse && recipe.type == currentLens){
|
||||
ItemStack output = recipe.getFirstOutput();
|
||||
if(output != null){
|
||||
ItemStack outputCopy = output.copy();
|
||||
outputCopy.stackSize = stack.stackSize;
|
||||
item.setEntityItemStack(outputCopy);
|
||||
|
||||
this.storage.extractEnergy(baseUse+recipe.energyUse, false);
|
||||
this.storage.extractEnergy(ENERGY_USE+recipe.energyUse, false);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -144,7 +144,7 @@ public class TileEntityAtomicReconstructor extends TileEntityInventoryBase imple
|
|||
}
|
||||
}
|
||||
else{
|
||||
this.currentTime = ConfigIntValues.RECONSTRUCTOR_COOLDOWN_TIMER.getValue();
|
||||
this.currentTime = 100;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.tile;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.block.Block;
|
||||
|
@ -72,7 +71,7 @@ public class TileEntityBreaker extends TileEntityInventoryBase{
|
|||
}
|
||||
}
|
||||
else{
|
||||
this.currentTime = ConfigIntValues.BREAKER_TIME_NEEDED.getValue();
|
||||
this.currentTime = 15;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -15,7 +15,6 @@ import cofh.api.energy.IEnergyReceiver;
|
|||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.blocks.InitBlocks;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.InitItems;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheMiscItems;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
|
@ -34,6 +33,10 @@ public class TileEntityCanolaPress extends TileEntityInventoryBase implements IE
|
|||
private int lastTankAmount;
|
||||
private int lastProcessTime;
|
||||
|
||||
public static final int PRODUCE = 100;
|
||||
public static final int ENERGY_USE = 35;
|
||||
private static final int TIME = 30;
|
||||
|
||||
public TileEntityCanolaPress(){
|
||||
super(3, "canolaPress");
|
||||
}
|
||||
|
@ -43,11 +46,11 @@ public class TileEntityCanolaPress extends TileEntityInventoryBase implements IE
|
|||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
if(this.isCanola(0) && ConfigIntValues.PRESS_MB_PRODUCED.getValue() <= this.tank.getCapacity()-this.tank.getFluidAmount()){
|
||||
if(this.storage.getEnergyStored() >= ConfigIntValues.PRESS_ENERGY_USED.getValue()){
|
||||
if(this.isCanola(0) && PRODUCE <= this.tank.getCapacity()-this.tank.getFluidAmount()){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE){
|
||||
this.currentProcessTime++;
|
||||
this.storage.extractEnergy(ConfigIntValues.PRESS_ENERGY_USED.getValue(), false);
|
||||
if(this.currentProcessTime >= ConfigIntValues.PRESS_PROCESSING_TIME.getValue()){
|
||||
this.storage.extractEnergy(ENERGY_USE, false);
|
||||
if(this.currentProcessTime >= TIME){
|
||||
this.currentProcessTime = 0;
|
||||
|
||||
this.slots[0].stackSize--;
|
||||
|
@ -55,7 +58,7 @@ public class TileEntityCanolaPress extends TileEntityInventoryBase implements IE
|
|||
this.slots[0] = null;
|
||||
}
|
||||
|
||||
this.tank.fill(new FluidStack(InitBlocks.fluidCanolaOil, ConfigIntValues.PRESS_MB_PRODUCED.getValue()), true);
|
||||
this.tank.fill(new FluidStack(InitBlocks.fluidCanolaOil, PRODUCE), true);
|
||||
this.markDirty();
|
||||
}
|
||||
}
|
||||
|
@ -95,7 +98,7 @@ public class TileEntityCanolaPress extends TileEntityInventoryBase implements IE
|
|||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getProcessScaled(int i){
|
||||
return this.currentProcessTime*i/ConfigIntValues.PRESS_PROCESSING_TIME.getValue();
|
||||
return this.currentProcessTime*i/TIME;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
|
|
|
@ -14,7 +14,6 @@ import cofh.api.energy.EnergyStorage;
|
|||
import cofh.api.energy.IEnergyProvider;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
@ -30,6 +29,8 @@ public class TileEntityCoalGenerator extends TileEntityInventoryBase implements
|
|||
private int lastBurnTime;
|
||||
private int lastCurrentBurnTime;
|
||||
|
||||
public static final int PRODUCE = 30;
|
||||
|
||||
public TileEntityCoalGenerator(){
|
||||
super(1, "coalGenerator");
|
||||
}
|
||||
|
@ -43,12 +44,12 @@ public class TileEntityCoalGenerator extends TileEntityInventoryBase implements
|
|||
|
||||
if(this.currentBurnTime > 0){
|
||||
this.currentBurnTime--;
|
||||
this.storage.receiveEnergy(ConfigIntValues.COAL_GEN_ENERGY_PRODUCED.getValue(), false);
|
||||
this.storage.receiveEnergy(PRODUCE, false);
|
||||
}
|
||||
|
||||
if(this.currentBurnTime <= 0 && this.slots[0] != null && TileEntityFurnace.getItemBurnTime(this.slots[0]) > 0){
|
||||
int burnTime = TileEntityFurnace.getItemBurnTime(this.slots[0]);
|
||||
if(ConfigIntValues.COAL_GEN_ENERGY_PRODUCED.getValue()*burnTime <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN)){
|
||||
if(PRODUCE*burnTime <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN)){
|
||||
this.maxBurnTime = burnTime;
|
||||
this.currentBurnTime = burnTime;
|
||||
this.slots[0].stackSize--;
|
||||
|
@ -71,7 +72,7 @@ public class TileEntityCoalGenerator extends TileEntityInventoryBase implements
|
|||
this.markDirty();
|
||||
int meta = worldObj.getBlockMetadata(xCoord, yCoord, zCoord);
|
||||
if(meta == 1){
|
||||
if(!(this.currentBurnTime <= 0 && this.slots[0] != null && TileEntityFurnace.getItemBurnTime(this.slots[0]) > 0 && ConfigIntValues.COAL_GEN_ENERGY_PRODUCED.getValue()*TileEntityFurnace.getItemBurnTime(this.slots[0]) <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN))){
|
||||
if(!(this.currentBurnTime <= 0 && this.slots[0] != null && TileEntityFurnace.getItemBurnTime(this.slots[0]) > 0 && PRODUCE*TileEntityFurnace.getItemBurnTime(this.slots[0]) <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN))){
|
||||
worldObj.setBlockMetadataWithNotify(xCoord, yCoord, zCoord, 0, 2);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,7 +14,6 @@ import cofh.api.energy.EnergyStorage;
|
|||
import cofh.api.energy.IEnergyReceiver;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.InitItems;
|
||||
import ellpeck.actuallyadditions.items.ItemCoffee;
|
||||
import ellpeck.actuallyadditions.items.metalists.TheMiscItems;
|
||||
|
@ -33,8 +32,6 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements
|
|||
public static final int SLOT_OUTPUT = 2;
|
||||
public static final int SLOT_WATER_INPUT = 11;
|
||||
public static final int SLOT_WATER_OUTPUT = 12;
|
||||
public final int waterUsedPerCoffee = 500;
|
||||
public final int coffeeCacheMaxAmount = 300;
|
||||
public EnergyStorage storage = new EnergyStorage(300000);
|
||||
public FluidTank tank = new FluidTank(4*FluidContainerRegistry.BUCKET_VOLUME);
|
||||
public int coffeeCacheAmount;
|
||||
|
@ -44,6 +41,12 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements
|
|||
private int lastCoffeeAmount;
|
||||
private int lastBrewTime;
|
||||
|
||||
private static final int TIME_USED = 500;
|
||||
public static final int CACHE_USE = 15;
|
||||
public static final int ENERGY_USED = 150;
|
||||
public static final int WATER_USE = 500;
|
||||
public static final int COFFEE_CACHE_MAX_AMOUNT = 300;
|
||||
|
||||
public TileEntityCoffeeMachine(){
|
||||
super(13, "coffeeMachine");
|
||||
}
|
||||
|
@ -69,12 +72,13 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements
|
|||
|
||||
public void storeCoffee(){
|
||||
if(this.slots[SLOT_COFFEE_BEANS] != null && this.slots[SLOT_COFFEE_BEANS].getItem() == InitItems.itemCoffeeBean){
|
||||
if(ConfigIntValues.COFFEE_CACHE_ADDED_PER_ITEM.getValue() <= this.coffeeCacheMaxAmount-this.coffeeCacheAmount){
|
||||
int toAdd = 2;
|
||||
if(toAdd <= COFFEE_CACHE_MAX_AMOUNT-this.coffeeCacheAmount){
|
||||
this.slots[SLOT_COFFEE_BEANS].stackSize--;
|
||||
if(this.slots[SLOT_COFFEE_BEANS].stackSize <= 0){
|
||||
this.slots[SLOT_COFFEE_BEANS] = null;
|
||||
}
|
||||
this.coffeeCacheAmount += ConfigIntValues.COFFEE_CACHE_ADDED_PER_ITEM.getValue();
|
||||
this.coffeeCacheAmount += toAdd;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -83,11 +87,11 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements
|
|||
|
||||
public void brew(){
|
||||
if(!worldObj.isRemote){
|
||||
if(this.slots[SLOT_INPUT] != null && this.slots[SLOT_INPUT].getItem() == InitItems.itemMisc && this.slots[SLOT_INPUT].getItemDamage() == TheMiscItems.CUP.ordinal() && this.slots[SLOT_OUTPUT] == null && this.coffeeCacheAmount >= ConfigIntValues.COFFEE_CACHE_USED_PER_ITEM.getValue() && this.tank.getFluid() != null && this.tank.getFluid().getFluid() == FluidRegistry.WATER && this.tank.getFluidAmount() >= this.waterUsedPerCoffee){
|
||||
if(this.storage.getEnergyStored() >= ConfigIntValues.COFFEE_MACHINE_ENERGY_USED.getValue()){
|
||||
if(this.slots[SLOT_INPUT] != null && this.slots[SLOT_INPUT].getItem() == InitItems.itemMisc && this.slots[SLOT_INPUT].getItemDamage() == TheMiscItems.CUP.ordinal() && this.slots[SLOT_OUTPUT] == null && this.coffeeCacheAmount >= CACHE_USE && this.tank.getFluid() != null && this.tank.getFluid().getFluid() == FluidRegistry.WATER && this.tank.getFluidAmount() >= WATER_USE){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USED){
|
||||
this.brewTime++;
|
||||
this.storage.extractEnergy(ConfigIntValues.COFFEE_MACHINE_ENERGY_USED.getValue(), false);
|
||||
if(this.brewTime >= ConfigIntValues.COFFEE_MACHINE_TIME_USED.getValue()){
|
||||
this.storage.extractEnergy(ENERGY_USED, false);
|
||||
if(this.brewTime >= TIME_USED){
|
||||
this.brewTime = 0;
|
||||
ItemStack output = new ItemStack(InitItems.itemCoffee);
|
||||
for(int i = 3; i < this.slots.length-2; i++){
|
||||
|
@ -108,8 +112,8 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements
|
|||
if(this.slots[SLOT_INPUT].stackSize <= 0){
|
||||
this.slots[SLOT_INPUT] = null;
|
||||
}
|
||||
this.coffeeCacheAmount -= ConfigIntValues.COFFEE_CACHE_USED_PER_ITEM.getValue();
|
||||
this.tank.drain(this.waterUsedPerCoffee, true);
|
||||
this.coffeeCacheAmount -= CACHE_USE;
|
||||
this.tank.drain(WATER_USE, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -121,7 +125,7 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements
|
|||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getCoffeeScaled(int i){
|
||||
return this.coffeeCacheAmount*i/this.coffeeCacheMaxAmount;
|
||||
return this.coffeeCacheAmount*i/COFFEE_CACHE_MAX_AMOUNT;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
|
@ -136,7 +140,7 @@ public class TileEntityCoffeeMachine extends TileEntityInventoryBase implements
|
|||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getBrewScaled(int i){
|
||||
return this.brewTime*i/ConfigIntValues.COFFEE_MACHINE_TIME_USED.getValue();
|
||||
return this.brewTime*i/TIME_USED;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.tile;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.items.InitItems;
|
||||
import ellpeck.actuallyadditions.items.ItemFertilizer;
|
||||
import ellpeck.actuallyadditions.items.ItemMisc;
|
||||
|
@ -22,6 +21,8 @@ public class TileEntityCompost extends TileEntityInventoryBase{
|
|||
|
||||
public int conversionTime;
|
||||
|
||||
public static final int AMOUNT = 10;
|
||||
|
||||
public TileEntityCompost(){
|
||||
super(1, "compost");
|
||||
}
|
||||
|
@ -44,10 +45,10 @@ public class TileEntityCompost extends TileEntityInventoryBase{
|
|||
}
|
||||
|
||||
boolean theFlag = this.conversionTime > 0;
|
||||
if(this.slots[0] != null && !(this.slots[0].getItem() instanceof ItemFertilizer) && this.slots[0].stackSize >= ConfigIntValues.COMPOST_AMOUNT.getValue()){
|
||||
if(this.slots[0] != null && !(this.slots[0].getItem() instanceof ItemFertilizer) && this.slots[0].stackSize >= AMOUNT){
|
||||
this.conversionTime++;
|
||||
if(this.conversionTime >= ConfigIntValues.COMPOST_TIME.getValue()){
|
||||
this.slots[0] = new ItemStack(InitItems.itemFertilizer, ConfigIntValues.COMPOST_AMOUNT.getValue());
|
||||
if(this.conversionTime >= AMOUNT){
|
||||
this.slots[0] = new ItemStack(InitItems.itemFertilizer, AMOUNT);
|
||||
this.conversionTime = 0;
|
||||
}
|
||||
}
|
||||
|
@ -71,7 +72,7 @@ public class TileEntityCompost extends TileEntityInventoryBase{
|
|||
|
||||
@Override
|
||||
public int getInventoryStackLimit(){
|
||||
return ConfigIntValues.COMPOST_AMOUNT.getValue();
|
||||
return AMOUNT;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -14,7 +14,6 @@ import cofh.api.energy.EnergyStorage;
|
|||
import cofh.api.energy.IEnergyReceiver;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.block.Block;
|
||||
|
@ -32,6 +31,9 @@ public class TileEntityDirectionalBreaker extends TileEntityInventoryBase implem
|
|||
|
||||
private int currentTime;
|
||||
|
||||
public static final int RANGE = 8;
|
||||
public static final int ENERGY_USE = 5;
|
||||
|
||||
public TileEntityDirectionalBreaker(){
|
||||
super(9, "directionalBreaker");
|
||||
}
|
||||
|
@ -42,15 +44,13 @@ public class TileEntityDirectionalBreaker extends TileEntityInventoryBase implem
|
|||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
if(!worldObj.isBlockIndirectlyGettingPowered(xCoord, yCoord, zCoord)){
|
||||
int usagePerBlock = ConfigIntValues.DIRECTIONAL_BREAKER_RF_PER_BLOCK.getValue();
|
||||
int range = ConfigIntValues.DIRECTIONAL_BREAKER_RANGE.getValue();
|
||||
if(this.storage.getEnergyStored() >= usagePerBlock*range){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE*RANGE){
|
||||
if(this.currentTime > 0){
|
||||
this.currentTime--;
|
||||
if(this.currentTime <= 0){
|
||||
ForgeDirection sideToManipulate = ForgeDirection.getOrientation(worldObj.getBlockMetadata(xCoord, yCoord, zCoord));
|
||||
|
||||
for(int i = 0; i < range; i++){
|
||||
for(int i = 0; i < RANGE; i++){
|
||||
WorldPos coordsBlock = WorldUtil.getCoordsFromSide(sideToManipulate, worldObj, xCoord, yCoord, zCoord, i);
|
||||
if(coordsBlock != null){
|
||||
Block blockToBreak = worldObj.getBlock(coordsBlock.getX(), coordsBlock.getY(), coordsBlock.getZ());
|
||||
|
@ -63,7 +63,7 @@ public class TileEntityDirectionalBreaker extends TileEntityInventoryBase implem
|
|||
worldObj.playAuxSFX(2001, coordsBlock.getX(), coordsBlock.getY(), coordsBlock.getZ(), Block.getIdFromBlock(blockToBreak)+(meta << 12));
|
||||
WorldUtil.breakBlockAtSide(sideToManipulate, worldObj, xCoord, yCoord, zCoord, i);
|
||||
WorldUtil.addToInventory(this.slots, drops, true);
|
||||
this.storage.extractEnergy(usagePerBlock, false);
|
||||
this.storage.extractEnergy(ENERGY_USE, false);
|
||||
this.markDirty();
|
||||
}
|
||||
}
|
||||
|
@ -72,7 +72,7 @@ public class TileEntityDirectionalBreaker extends TileEntityInventoryBase implem
|
|||
}
|
||||
}
|
||||
else{
|
||||
this.currentTime = ConfigIntValues.BREAKER_TIME_NEEDED.getValue();
|
||||
this.currentTime = 15;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.tile;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
@ -41,7 +40,7 @@ public class TileEntityDropper extends TileEntityInventoryBase{
|
|||
}
|
||||
}
|
||||
else{
|
||||
this.currentTime = ConfigIntValues.DROPPER_TIME_NEEDED.getValue();
|
||||
this.currentTime = 5;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.tile;
|
|||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import net.minecraft.entity.passive.EntityAnimal;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
@ -28,6 +27,9 @@ public class TileEntityFeeder extends TileEntityInventoryBase{
|
|||
private int lastAnimalAmount;
|
||||
private int lastTimer;
|
||||
|
||||
public static final int THRESHOLD = 30;
|
||||
private static final int TIME = 100;
|
||||
|
||||
public TileEntityFeeder(){
|
||||
super(1, "feeder");
|
||||
}
|
||||
|
@ -38,12 +40,13 @@ public class TileEntityFeeder extends TileEntityInventoryBase{
|
|||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
boolean theFlag = this.currentTimer > 0;
|
||||
List<EntityAnimal> animals = worldObj.getEntitiesWithinAABB(EntityAnimal.class, AxisAlignedBB.getBoundingBox(this.xCoord-ConfigIntValues.FEEDER_REACH.getValue(), this.yCoord-ConfigIntValues.FEEDER_REACH.getValue(), this.zCoord-ConfigIntValues.FEEDER_REACH.getValue(), this.xCoord+ConfigIntValues.FEEDER_REACH.getValue(), this.yCoord+ConfigIntValues.FEEDER_REACH.getValue(), this.zCoord+ConfigIntValues.FEEDER_REACH.getValue()));
|
||||
int range = 5;
|
||||
List<EntityAnimal> animals = worldObj.getEntitiesWithinAABB(EntityAnimal.class, AxisAlignedBB.getBoundingBox(this.xCoord-range, this.yCoord-range, this.zCoord-range, this.xCoord+range, this.yCoord+range, this.zCoord+range));
|
||||
if(animals != null){
|
||||
this.currentAnimalAmount = animals.size();
|
||||
if(this.currentAnimalAmount >= 2){
|
||||
if(this.currentAnimalAmount < ConfigIntValues.FEEDER_THRESHOLD.getValue()){
|
||||
if(this.currentTimer >= ConfigIntValues.FEEDER_TIME.getValue()){
|
||||
if(this.currentAnimalAmount < THRESHOLD){
|
||||
if(this.currentTimer >= TIME){
|
||||
this.currentTimer = 0;
|
||||
if(this.slots[0] != null){
|
||||
EntityAnimal randomAnimal = animals.get(Util.RANDOM.nextInt(this.currentAnimalAmount));
|
||||
|
@ -94,7 +97,7 @@ public class TileEntityFeeder extends TileEntityInventoryBase{
|
|||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getCurrentTimerToScale(int i){
|
||||
return this.currentTimer*i/ConfigIntValues.FEEDER_TIME.getValue();
|
||||
return this.currentTimer*i/TIME;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -13,7 +13,6 @@ package ellpeck.actuallyadditions.tile;
|
|||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.blocks.InitBlocks;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.init.Items;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
@ -30,6 +29,8 @@ public class TileEntityFermentingBarrel extends TileEntityInventoryBase implemen
|
|||
private int lastOil;
|
||||
private int lastProcessTime;
|
||||
|
||||
private static final int PROCESS_TIME = 100;
|
||||
|
||||
public TileEntityFermentingBarrel(){
|
||||
super(4, "fermentingBarrel");
|
||||
}
|
||||
|
@ -39,13 +40,14 @@ public class TileEntityFermentingBarrel extends TileEntityInventoryBase implemen
|
|||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
if(this.canolaTank.getFluidAmount() >= ConfigIntValues.BARREL_MB_PRODUCED.getValue() && ConfigIntValues.BARREL_MB_PRODUCED.getValue() <= this.oilTank.getCapacity()-this.oilTank.getFluidAmount()){
|
||||
int produce = 50;
|
||||
if(this.canolaTank.getFluidAmount() >= produce && produce <= this.oilTank.getCapacity()-this.oilTank.getFluidAmount()){
|
||||
this.currentProcessTime++;
|
||||
if(this.currentProcessTime >= ConfigIntValues.BARREL_PROCESSING_TIME.getValue()){
|
||||
if(this.currentProcessTime >= PROCESS_TIME){
|
||||
this.currentProcessTime = 0;
|
||||
|
||||
this.oilTank.fill(new FluidStack(InitBlocks.fluidOil, ConfigIntValues.BARREL_MB_PRODUCED.getValue()), true);
|
||||
this.canolaTank.drain(ConfigIntValues.BARREL_MB_PRODUCED.getValue(), true);
|
||||
this.oilTank.fill(new FluidStack(InitBlocks.fluidOil, produce), true);
|
||||
this.canolaTank.drain(produce, true);
|
||||
this.markDirty();
|
||||
}
|
||||
}
|
||||
|
@ -76,7 +78,7 @@ public class TileEntityFermentingBarrel extends TileEntityInventoryBase implemen
|
|||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getProcessScaled(int i){
|
||||
return this.currentProcessTime*i/ConfigIntValues.BARREL_PROCESSING_TIME.getValue();
|
||||
return this.currentProcessTime*i/PROCESS_TIME;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.tile;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
|
@ -58,7 +57,8 @@ public class TileEntityFishingNet extends TileEntityBase{
|
|||
}
|
||||
}
|
||||
else{
|
||||
this.timeUntilNextDrop = ConfigIntValues.FISHER_TIME.getValue()+Util.RANDOM.nextInt(ConfigIntValues.FISHER_TIME.getValue()/2);
|
||||
int time = 15000;
|
||||
this.timeUntilNextDrop = time+Util.RANDOM.nextInt(time/2);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.tile;
|
|||
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.block.Block;
|
||||
|
@ -126,7 +125,7 @@ public class TileEntityFluidCollector extends TileEntityInventoryBase implements
|
|||
}
|
||||
}
|
||||
else{
|
||||
this.currentTime = ConfigIntValues.BREAKER_TIME_NEEDED.getValue();
|
||||
this.currentTime = 15;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -14,7 +14,6 @@ import cofh.api.energy.EnergyStorage;
|
|||
import cofh.api.energy.IEnergyReceiver;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.item.crafting.FurnaceRecipes;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
@ -34,6 +33,10 @@ public class TileEntityFurnaceDouble extends TileEntityInventoryBase implements
|
|||
private int lastFirstSmelt;
|
||||
private int lastSecondSmelt;
|
||||
|
||||
private static final int SMELT_TIME = 80;
|
||||
|
||||
public static final int ENERGY_USE = 25;
|
||||
|
||||
public TileEntityFurnaceDouble(){
|
||||
super(4, "furnaceDouble");
|
||||
}
|
||||
|
@ -48,11 +51,10 @@ public class TileEntityFurnaceDouble extends TileEntityInventoryBase implements
|
|||
boolean canSmeltOnFirst = this.canSmeltOn(SLOT_INPUT_1, SLOT_OUTPUT_1);
|
||||
boolean canSmeltOnSecond = this.canSmeltOn(SLOT_INPUT_2, SLOT_OUTPUT_2);
|
||||
|
||||
|
||||
if(canSmeltOnFirst){
|
||||
if(this.storage.getEnergyStored() >= ConfigIntValues.FURNACE_ENERGY_USED.getValue()){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE){
|
||||
this.firstSmeltTime++;
|
||||
if(this.firstSmeltTime >= ConfigIntValues.FURNACE_DOUBLE_SMELT_TIME.getValue()){
|
||||
if(this.firstSmeltTime >= SMELT_TIME){
|
||||
this.finishBurning(SLOT_INPUT_1, SLOT_OUTPUT_1);
|
||||
this.firstSmeltTime = 0;
|
||||
}
|
||||
|
@ -63,9 +65,9 @@ public class TileEntityFurnaceDouble extends TileEntityInventoryBase implements
|
|||
}
|
||||
|
||||
if(canSmeltOnSecond){
|
||||
if(this.storage.getEnergyStored() >= ConfigIntValues.FURNACE_ENERGY_USED.getValue()){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE){
|
||||
this.secondSmeltTime++;
|
||||
if(this.secondSmeltTime >= ConfigIntValues.FURNACE_DOUBLE_SMELT_TIME.getValue()){
|
||||
if(this.secondSmeltTime >= SMELT_TIME){
|
||||
this.finishBurning(SLOT_INPUT_2, SLOT_OUTPUT_2);
|
||||
this.secondSmeltTime = 0;
|
||||
}
|
||||
|
@ -75,8 +77,8 @@ public class TileEntityFurnaceDouble extends TileEntityInventoryBase implements
|
|||
this.secondSmeltTime = 0;
|
||||
}
|
||||
|
||||
if(this.storage.getEnergyStored() >= ConfigIntValues.FURNACE_ENERGY_USED.getValue() && (this.firstSmeltTime > 0 || this.secondSmeltTime > 0)){
|
||||
this.storage.extractEnergy(ConfigIntValues.FURNACE_ENERGY_USED.getValue(), false);
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE && (this.firstSmeltTime > 0 || this.secondSmeltTime > 0)){
|
||||
this.storage.extractEnergy(ENERGY_USE, false);
|
||||
}
|
||||
|
||||
if(flag != (this.firstSmeltTime > 0 || this.secondSmeltTime > 0)){
|
||||
|
@ -157,12 +159,12 @@ public class TileEntityFurnaceDouble extends TileEntityInventoryBase implements
|
|||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getFirstTimeToScale(int i){
|
||||
return this.firstSmeltTime*i/ConfigIntValues.FURNACE_DOUBLE_SMELT_TIME.getValue();
|
||||
return this.firstSmeltTime*i/SMELT_TIME;
|
||||
}
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getSecondTimeToScale(int i){
|
||||
return this.secondSmeltTime*i/ConfigIntValues.FURNACE_DOUBLE_SMELT_TIME.getValue();
|
||||
return this.secondSmeltTime*i/SMELT_TIME;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.tile;
|
|||
|
||||
import cofh.api.energy.EnergyStorage;
|
||||
import cofh.api.energy.IEnergyProvider;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
@ -21,6 +20,8 @@ public class TileEntityFurnaceSolar extends TileEntityBase implements IEnergyPro
|
|||
|
||||
public EnergyStorage storage = new EnergyStorage(30000);
|
||||
|
||||
public static final int PRODUCE = 10;
|
||||
|
||||
@Override
|
||||
public int extractEnergy(ForgeDirection from, int maxExtract, boolean simulate){
|
||||
return this.storage.extractEnergy(maxExtract, simulate);
|
||||
|
@ -65,8 +66,8 @@ public class TileEntityFurnaceSolar extends TileEntityBase implements IEnergyPro
|
|||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
if(!this.hasBlockAbove() && worldObj.isDaytime()){
|
||||
if(ConfigIntValues.FURNACE_SOLAR_ENERGY_PRODUCED.getValue() <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN)){
|
||||
this.storage.receiveEnergy(ConfigIntValues.FURNACE_SOLAR_ENERGY_PRODUCED.getValue(), false);
|
||||
if(PRODUCE <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN)){
|
||||
this.storage.receiveEnergy(PRODUCE, false);
|
||||
this.markDirty();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.tile;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
import net.minecraft.block.Block;
|
||||
|
@ -42,7 +41,8 @@ public class TileEntityGreenhouseGlass extends TileEntityBase{
|
|||
}
|
||||
}
|
||||
else{
|
||||
this.timeUntilNextFert = ConfigIntValues.GLASS_TIME_NEEDED.getValue()+Util.RANDOM.nextInt(ConfigIntValues.GLASS_TIME_NEEDED.getValue());
|
||||
int time = 300;
|
||||
this.timeUntilNextFert = time+Util.RANDOM.nextInt(time);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -15,7 +15,6 @@ import cofh.api.energy.EnergyStorage;
|
|||
import cofh.api.energy.IEnergyReceiver;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.recipe.CrusherRecipeRegistry;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
@ -83,7 +82,7 @@ public class TileEntityGrinder extends TileEntityInventoryBase implements IEnerg
|
|||
}
|
||||
|
||||
if(canCrushOnFirst){
|
||||
if(this.storage.getEnergyStored() >= getEnergyUse()){
|
||||
if(this.storage.getEnergyStored() >= getEnergyUse(this.isDouble)){
|
||||
this.firstCrushTime++;
|
||||
if(this.firstCrushTime >= getMaxCrushTime()){
|
||||
this.finishCrushing(SLOT_INPUT_1, SLOT_OUTPUT_1_1, SLOT_OUTPUT_1_2);
|
||||
|
@ -97,7 +96,7 @@ public class TileEntityGrinder extends TileEntityInventoryBase implements IEnerg
|
|||
|
||||
if(this.isDouble){
|
||||
if(canCrushOnSecond){
|
||||
if(this.storage.getEnergyStored() >= getEnergyUse()){
|
||||
if(this.storage.getEnergyStored() >= getEnergyUse(this.isDouble)){
|
||||
this.secondCrushTime++;
|
||||
if(this.secondCrushTime >= getMaxCrushTime()){
|
||||
this.finishCrushing(SLOT_INPUT_2, SLOT_OUTPUT_2_1, SLOT_OUTPUT_2_2);
|
||||
|
@ -110,8 +109,8 @@ public class TileEntityGrinder extends TileEntityInventoryBase implements IEnerg
|
|||
}
|
||||
}
|
||||
|
||||
if(this.storage.getEnergyStored() >= getEnergyUse() && (this.firstCrushTime > 0 || this.secondCrushTime > 0)){
|
||||
this.storage.extractEnergy(getEnergyUse(), false);
|
||||
if(this.storage.getEnergyStored() >= getEnergyUse(this.isDouble) && (this.firstCrushTime > 0 || this.secondCrushTime > 0)){
|
||||
this.storage.extractEnergy(getEnergyUse(this.isDouble), false);
|
||||
}
|
||||
|
||||
if(flag != (this.firstCrushTime > 0 || this.secondCrushTime > 0)){
|
||||
|
@ -152,12 +151,12 @@ public class TileEntityGrinder extends TileEntityInventoryBase implements IEnerg
|
|||
return false;
|
||||
}
|
||||
|
||||
private int getEnergyUse(){
|
||||
return this.isDouble ? ConfigIntValues.GRINDER_DOUBLE_ENERGY_USED.getValue() : ConfigIntValues.GRINDER_ENERGY_USED.getValue();
|
||||
public static int getEnergyUse(boolean isDouble){
|
||||
return isDouble ? 60 : 40;
|
||||
}
|
||||
|
||||
private int getMaxCrushTime(){
|
||||
return this.isDouble ? ConfigIntValues.GRINDER_DOUBLE_CRUSH_TIME.getValue() : ConfigIntValues.GRINDER_CRUSH_TIME.getValue();
|
||||
return this.isDouble ? 150 : 100;
|
||||
}
|
||||
|
||||
public void finishCrushing(int theInput, int theFirstOutput, int theSecondOutput){
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.tile;
|
|||
|
||||
import cofh.api.energy.EnergyStorage;
|
||||
import cofh.api.energy.IEnergyProvider;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
|
@ -27,12 +26,15 @@ public class TileEntityHeatCollector extends TileEntityBase implements IEnergyPr
|
|||
|
||||
public EnergyStorage storage = new EnergyStorage(30000);
|
||||
|
||||
public static final int ENERGY_PRODUCE = 40;
|
||||
public static final int BLOCKS_NEEDED = 4;
|
||||
|
||||
@Override
|
||||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
ArrayList<Integer> blocksAround = new ArrayList<Integer>();
|
||||
if(ConfigIntValues.HEAT_COLLECTOR_ENERGY_PRODUCED.getValue() <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN)){
|
||||
if(ENERGY_PRODUCE <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN)){
|
||||
for(int i = 1; i <= 5; i++){
|
||||
WorldPos coords = WorldUtil.getCoordsFromSide(WorldUtil.getDirectionBySidesInOrder(i), worldObj, xCoord, yCoord, zCoord, 0);
|
||||
if(coords != null){
|
||||
|
@ -43,11 +45,11 @@ public class TileEntityHeatCollector extends TileEntityBase implements IEnergyPr
|
|||
}
|
||||
}
|
||||
|
||||
if(blocksAround.size() >= ConfigIntValues.HEAT_COLLECTOR_BLOCKS.getValue()){
|
||||
this.storage.receiveEnergy(ConfigIntValues.HEAT_COLLECTOR_ENERGY_PRODUCED.getValue(), false);
|
||||
if(blocksAround.size() >= BLOCKS_NEEDED){
|
||||
this.storage.receiveEnergy(ENERGY_PRODUCE, false);
|
||||
this.markDirty();
|
||||
|
||||
if(Util.RANDOM.nextInt(ConfigIntValues.HEAT_COLLECTOR_LAVA_CHANCE.getValue()) == 0){
|
||||
if(Util.RANDOM.nextInt(10) == 0){
|
||||
int randomSide = blocksAround.get(Util.RANDOM.nextInt(blocksAround.size()));
|
||||
WorldUtil.breakBlockAtSide(WorldUtil.getDirectionBySidesInOrder(randomSide), worldObj, xCoord, yCoord, zCoord);
|
||||
}
|
||||
|
|
|
@ -14,7 +14,6 @@ import cofh.api.energy.EnergyStorage;
|
|||
import cofh.api.energy.IEnergyReceiver;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
@ -28,6 +27,8 @@ public class TileEntityItemRepairer extends TileEntityInventoryBase implements I
|
|||
public int nextRepairTick;
|
||||
private int lastEnergy;
|
||||
|
||||
public static final int ENERGY_USE = 1500;
|
||||
|
||||
public TileEntityItemRepairer(){
|
||||
super(2, "repairer");
|
||||
}
|
||||
|
@ -44,10 +45,10 @@ public class TileEntityItemRepairer extends TileEntityInventoryBase implements I
|
|||
this.nextRepairTick = 0;
|
||||
}
|
||||
else{
|
||||
if(this.storage.getEnergyStored() >= ConfigIntValues.REPAIRER_ENERGY_USED.getValue()){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE){
|
||||
this.nextRepairTick++;
|
||||
this.storage.extractEnergy(ConfigIntValues.REPAIRER_ENERGY_USED.getValue(), false);
|
||||
if(this.nextRepairTick >= ConfigIntValues.REPAIRER_SPEED_SLOWDOWN.getValue()){
|
||||
this.storage.extractEnergy(ENERGY_USE, false);
|
||||
if(this.nextRepairTick >= 2){
|
||||
this.nextRepairTick = 0;
|
||||
this.slots[SLOT_INPUT].setItemDamage(this.slots[SLOT_INPUT].getItemDamage()-1);
|
||||
}
|
||||
|
|
|
@ -31,6 +31,8 @@ import net.minecraftforge.common.util.ForgeDirection;
|
|||
|
||||
public class TileEntityLaserRelay extends TileEntityBase implements IEnergyReceiver{
|
||||
|
||||
public static final int MAX_DISTANCE = 15;
|
||||
|
||||
@Override
|
||||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
|
|
|
@ -14,7 +14,6 @@ import cofh.api.energy.EnergyStorage;
|
|||
import cofh.api.energy.IEnergyReceiver;
|
||||
import ellpeck.actuallyadditions.blocks.InitBlocks;
|
||||
import ellpeck.actuallyadditions.blocks.metalists.TheMiscBlocks;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
@ -30,6 +29,8 @@ public class TileEntityLavaFactoryController extends TileEntityBase implements I
|
|||
public EnergyStorage storage = new EnergyStorage(3000000);
|
||||
private int currentWorkTime;
|
||||
|
||||
public static final int ENERGY_USE = 150000;
|
||||
|
||||
@Override
|
||||
public void writeSyncableNBT(NBTTagCompound compound, boolean sync){
|
||||
this.storage.writeToNBT(compound);
|
||||
|
@ -47,12 +48,12 @@ public class TileEntityLavaFactoryController extends TileEntityBase implements I
|
|||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
if(this.storage.getEnergyStored() >= ConfigIntValues.LAVA_FACTORY_ENERGY_USED.getValue() && this.isMultiblock() == HAS_AIR){
|
||||
if(this.storage.getEnergyStored() >= ENERGY_USE && this.isMultiblock() == HAS_AIR){
|
||||
this.currentWorkTime++;
|
||||
if(this.currentWorkTime >= ConfigIntValues.LAVA_FACTORY_TIME.getValue()){
|
||||
if(this.currentWorkTime >= 200){
|
||||
this.currentWorkTime = 0;
|
||||
worldObj.setBlock(xCoord, yCoord+1, zCoord, Blocks.lava);
|
||||
this.storage.extractEnergy(ConfigIntValues.LAVA_FACTORY_ENERGY_USED.getValue(), false);
|
||||
this.storage.extractEnergy(ENERGY_USE, false);
|
||||
}
|
||||
}
|
||||
else{
|
||||
|
|
|
@ -12,7 +12,6 @@ package ellpeck.actuallyadditions.tile;
|
|||
|
||||
import cofh.api.energy.EnergyStorage;
|
||||
import cofh.api.energy.IEnergyProvider;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.block.Block;
|
||||
|
@ -26,6 +25,9 @@ public class TileEntityLeafGenerator extends TileEntityBase implements IEnergyPr
|
|||
|
||||
public EnergyStorage storage = new EnergyStorage(35000);
|
||||
|
||||
public static final int RANGE = 7;
|
||||
public static final int ENERGY_PRODUCED = 300;
|
||||
|
||||
private int nextUseCounter;
|
||||
|
||||
@Override
|
||||
|
@ -45,17 +47,15 @@ public class TileEntityLeafGenerator extends TileEntityBase implements IEnergyPr
|
|||
if(!worldObj.isRemote){
|
||||
if(!this.worldObj.isBlockIndirectlyGettingPowered(this.xCoord, this.yCoord, this.zCoord)){
|
||||
|
||||
if(this.nextUseCounter >= ConfigIntValues.LEAF_GENERATOR_COOLDOWN_TIME.getValue()){
|
||||
if(this.nextUseCounter >= 5){
|
||||
this.nextUseCounter = 0;
|
||||
|
||||
int energyProducedPerLeaf = ConfigIntValues.LEAF_GENERATOR_ENERGY_PRODUCED.getValue();
|
||||
if(energyProducedPerLeaf <= this.storage.getMaxEnergyStored()-this.storage.getEnergyStored()){
|
||||
if(ENERGY_PRODUCED <= this.storage.getMaxEnergyStored()-this.storage.getEnergyStored()){
|
||||
ArrayList<WorldPos> breakPositions = new ArrayList<WorldPos>();
|
||||
|
||||
int range = ConfigIntValues.LEAF_GENERATOR_RANGE.getValue();
|
||||
for(int reachX = -range; reachX < range+1; reachX++){
|
||||
for(int reachZ = -range; reachZ < range+1; reachZ++){
|
||||
for(int reachY = -range; reachY < range+1; reachY++){
|
||||
for(int reachX = -RANGE; reachX < RANGE+1; reachX++){
|
||||
for(int reachZ = -RANGE; reachZ < RANGE+1; reachZ++){
|
||||
for(int reachY = -RANGE; reachY < RANGE+1; reachY++){
|
||||
Block block = this.worldObj.getBlock(this.xCoord+reachX, this.yCoord+reachY, this.zCoord+reachZ);
|
||||
if(block != null && block.isLeaves(this.worldObj, this.xCoord+reachX, this.yCoord+reachY, this.zCoord+reachZ)){
|
||||
breakPositions.add(new WorldPos(this.worldObj, this.xCoord+reachX, this.yCoord+reachY, this.zCoord+reachZ));
|
||||
|
@ -74,7 +74,7 @@ public class TileEntityLeafGenerator extends TileEntityBase implements IEnergyPr
|
|||
|
||||
this.worldObj.setBlockToAir(theCoord.getX(), theCoord.getY(), theCoord.getZ());
|
||||
|
||||
this.storage.receiveEnergy(energyProducedPerLeaf, false);
|
||||
this.storage.receiveEnergy(ENERGY_PRODUCED, false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -15,7 +15,6 @@ import cofh.api.energy.IEnergyProvider;
|
|||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.blocks.InitBlocks;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
@ -31,6 +30,9 @@ public class TileEntityOilGenerator extends TileEntityInventoryBase implements I
|
|||
private int lastTank;
|
||||
private int lastBurnTime;
|
||||
|
||||
public static final int ENERGY_PRODUCED = 76;
|
||||
private static final int BURN_TIME = 100;
|
||||
|
||||
public TileEntityOilGenerator(){
|
||||
super(2, "oilGenerator");
|
||||
}
|
||||
|
@ -44,13 +46,14 @@ public class TileEntityOilGenerator extends TileEntityInventoryBase implements I
|
|||
|
||||
if(this.currentBurnTime > 0){
|
||||
this.currentBurnTime--;
|
||||
this.storage.receiveEnergy(ConfigIntValues.OIL_GEN_ENERGY_PRODUCED.getValue(), false);
|
||||
this.storage.receiveEnergy(ENERGY_PRODUCED, false);
|
||||
}
|
||||
|
||||
if(ConfigIntValues.OIL_GEN_ENERGY_PRODUCED.getValue()*ConfigIntValues.OIL_GEN_BURN_TIME.getValue() <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN)){
|
||||
if(this.currentBurnTime <= 0 && this.tank.getFluidAmount() >= ConfigIntValues.OIL_GEN_FUEL_USED.getValue()){
|
||||
this.currentBurnTime = ConfigIntValues.OIL_GEN_BURN_TIME.getValue();
|
||||
this.tank.drain(ConfigIntValues.OIL_GEN_FUEL_USED.getValue(), true);
|
||||
int fuelUsed = 50;
|
||||
if(ENERGY_PRODUCED*BURN_TIME <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN)){
|
||||
if(this.currentBurnTime <= 0 && this.tank.getFluidAmount() >= fuelUsed){
|
||||
this.currentBurnTime = BURN_TIME;
|
||||
this.tank.drain(fuelUsed, true);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -69,7 +72,7 @@ public class TileEntityOilGenerator extends TileEntityInventoryBase implements I
|
|||
this.markDirty();
|
||||
int meta = worldObj.getBlockMetadata(xCoord, yCoord, zCoord);
|
||||
if(meta == 1){
|
||||
if(!(ConfigIntValues.OIL_GEN_ENERGY_PRODUCED.getValue()*ConfigIntValues.OIL_GEN_BURN_TIME.getValue() <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN) && FluidContainerRegistry.BUCKET_VOLUME <= this.tank.getCapacity()-this.tank.getFluidAmount())){
|
||||
if(!(ENERGY_PRODUCED*BURN_TIME <= this.getMaxEnergyStored(ForgeDirection.UNKNOWN)-this.getEnergyStored(ForgeDirection.UNKNOWN) && FluidContainerRegistry.BUCKET_VOLUME <= this.tank.getCapacity()-this.tank.getFluidAmount())){
|
||||
worldObj.setBlockMetadataWithNotify(xCoord, yCoord, zCoord, 0, 2);
|
||||
}
|
||||
}
|
||||
|
@ -98,7 +101,7 @@ public class TileEntityOilGenerator extends TileEntityInventoryBase implements I
|
|||
|
||||
@SideOnly(Side.CLIENT)
|
||||
public int getBurningScaled(int i){
|
||||
return this.currentBurnTime*i/ConfigIntValues.OIL_GEN_BURN_TIME.getValue();
|
||||
return this.currentBurnTime*i/BURN_TIME;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.tile;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.inventory.GuiHandler;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
|
@ -31,6 +30,8 @@ public class TileEntityPhantomPlacer extends TileEntityInventoryBase implements
|
|||
public int range;
|
||||
public boolean isBreaker;
|
||||
|
||||
public static final int RANGE = 3;
|
||||
|
||||
public TileEntityPhantomPlacer(int slots, String name){
|
||||
super(slots, name);
|
||||
}
|
||||
|
@ -44,7 +45,7 @@ public class TileEntityPhantomPlacer extends TileEntityInventoryBase implements
|
|||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
this.range = TileEntityPhantomface.upgradeRange(ConfigIntValues.PHANTOM_PLACER_RANGE.getValue(), worldObj, xCoord, yCoord, zCoord);
|
||||
this.range = TileEntityPhantomface.upgradeRange(RANGE, worldObj, xCoord, yCoord, zCoord);
|
||||
|
||||
if(!this.hasBoundPosition()){
|
||||
this.boundPosition = null;
|
||||
|
@ -82,7 +83,7 @@ public class TileEntityPhantomPlacer extends TileEntityInventoryBase implements
|
|||
}
|
||||
}
|
||||
else{
|
||||
this.currentTime = ConfigIntValues.PHANTOM_PLACER_TIME.getValue();
|
||||
this.currentTime = 30;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,7 +14,6 @@ import cpw.mods.fml.relauncher.Side;
|
|||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import ellpeck.actuallyadditions.blocks.BlockPhantom;
|
||||
import ellpeck.actuallyadditions.blocks.InitBlocks;
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.util.Util;
|
||||
import ellpeck.actuallyadditions.util.WorldPos;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
|
@ -36,6 +35,8 @@ public class TileEntityPhantomface extends TileEntityInventoryBase implements IP
|
|||
private WorldPos boundPosBefore;
|
||||
private Block boundBlockBefore;
|
||||
|
||||
public static final int RANGE = 16;
|
||||
|
||||
public TileEntityPhantomface(String name){
|
||||
super(0, name);
|
||||
}
|
||||
|
@ -44,7 +45,7 @@ public class TileEntityPhantomface extends TileEntityInventoryBase implements IP
|
|||
public void updateEntity(){
|
||||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
this.range = upgradeRange(ConfigIntValues.PHANTOMFACE_RANGE.getValue(), worldObj, xCoord, yCoord, zCoord);
|
||||
this.range = upgradeRange(RANGE, worldObj, xCoord, yCoord, zCoord);
|
||||
|
||||
if(!this.hasBoundPosition()){
|
||||
this.boundPosition = null;
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
|
||||
package ellpeck.actuallyadditions.tile;
|
||||
|
||||
import ellpeck.actuallyadditions.config.values.ConfigIntValues;
|
||||
import ellpeck.actuallyadditions.network.gui.IButtonReactor;
|
||||
import ellpeck.actuallyadditions.util.WorldUtil;
|
||||
import net.minecraft.entity.item.EntityItem;
|
||||
|
@ -28,6 +27,8 @@ public class TileEntityRangedCollector extends TileEntityInventoryBase implement
|
|||
public boolean isWhitelist = true;
|
||||
private boolean lastWhitelist;
|
||||
|
||||
public static final int RANGE = 6;
|
||||
|
||||
public TileEntityRangedCollector(){
|
||||
super(18, "rangedCollector");
|
||||
}
|
||||
|
@ -38,8 +39,7 @@ public class TileEntityRangedCollector extends TileEntityInventoryBase implement
|
|||
super.updateEntity();
|
||||
if(!worldObj.isRemote){
|
||||
if(!worldObj.isBlockIndirectlyGettingPowered(xCoord, yCoord, zCoord)){
|
||||
int range = ConfigIntValues.RANGED_COLLECTOR_RANGE.getValue();
|
||||
ArrayList<EntityItem> items = (ArrayList<EntityItem>)this.worldObj.getEntitiesWithinAABB(EntityItem.class, AxisAlignedBB.getBoundingBox(this.xCoord-range, this.yCoord-range, this.zCoord-range, this.xCoord+range, this.yCoord+range, this.zCoord+range));
|
||||
ArrayList<EntityItem> items = (ArrayList<EntityItem>)this.worldObj.getEntitiesWithinAABB(EntityItem.class, AxisAlignedBB.getBoundingBox(this.xCoord-RANGE, this.yCoord-RANGE, this.zCoord-RANGE, this.xCoord+RANGE, this.yCoord+RANGE, this.zCoord+RANGE));
|
||||
if(!items.isEmpty()){
|
||||
for(EntityItem item : items){
|
||||
if(!item.isDead && item.getEntityItem() != null){
|
||||
|
|
Loading…
Reference in a new issue