item distributor recipe and doc

This commit is contained in:
Ellpeck 2016-09-11 13:33:47 +02:00
parent 4b7d9c3fd8
commit 015e5121e2
6 changed files with 28 additions and 27 deletions

View file

@ -21,6 +21,7 @@ import net.minecraft.block.state.IBlockState;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.ScaledResolution;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.EnumRarity;
import net.minecraft.item.ItemStack;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.math.BlockPos;
@ -68,4 +69,9 @@ public class BlockDistributorItem extends BlockContainerBase implements IHudDisp
minecraft.fontRendererObj.drawStringWithShadow(TextFormatting.YELLOW+""+TextFormatting.ITALIC+strg, resolution.getScaledWidth()/2+35, resolution.getScaledHeight()/2-15, StringUtil.DECIMAL_COLOR_WHITE);
}
}
@Override
public EnumRarity getRarity(ItemStack stack){
return EnumRarity.UNCOMMON;
}
}

View file

@ -125,7 +125,8 @@ public final class InitBooklet{
new BookletChapter("phantomRedstoneface", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomRedstoneface), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipePhantomRedstoneface).setNoText());
new BookletChapter("phantomBreaker", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockPhantomBreaker), new PageTextOnly(1).addTextReplacement("<range>", TileEntityPhantomPlacer.RANGE), new PageCrafting(2, BlockCrafting.recipePhantomPlacer).setNoText(), new PageCrafting(3, BlockCrafting.recipePhantomBreaker).setNoText());
new BookletChapter("esd", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockInputterAdvanced), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeESD).setNoText(), new PageCrafting(3, BlockCrafting.recipeAdvancedESD).setNoText()).setSpecial();
new BookletChapter("xpSolidifier", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockXPSolidifier), new PageTextOnly(1).setStacks(new ItemStack(InitItems.itemSolidifiedExperience)), new PageCrafting(2, BlockCrafting.recipeSolidifier).setNoText()).setSpecial();
new BookletChapter("distributorItem", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockDistributorItem), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeDistributorItem).setNoText()).setSpecial();
new BookletChapter("xpSolidifier", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockXPSolidifier), new PageTextOnly(1).setStacks(new ItemStack(InitItems.itemSolidifiedExperience)), new PageCrafting(2, BlockCrafting.recipeSolidifier).setNoText()).setImportant();
new BookletChapter("greenhouseGlass", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockGreenhouseGlass), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeGlass));
new BookletChapter("fishingNet", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockFishingNet), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeFisher).setNoText());
new BookletChapter("feeder", ActuallyAdditionsAPI.entryFunctionalNonRF, new ItemStack(InitBlocks.blockFeeder), new PageTextOnly(1), new PageCrafting(2, BlockCrafting.recipeFeeder).setNoText());

View file

@ -29,13 +29,11 @@ public enum ConfigCrafting{
DOUBLE_FURNACE("Double Furnace", ConfigCategories.BLOCKS_CRAFTING),
FEEDER("Feeder", ConfigCategories.BLOCKS_CRAFTING),
GIANT_CHEST("Storage Crate", ConfigCategories.BLOCKS_CRAFTING),
GREENHOUSE_GLASS("Greenhouse Glass", ConfigCategories.BLOCKS_CRAFTING),
BREAKER("Breaker", ConfigCategories.BLOCKS_CRAFTING),
PLACER("Placer", ConfigCategories.BLOCKS_CRAFTING),
DROPPER("Dropper", ConfigCategories.BLOCKS_CRAFTING),
SPEED_UPGRADE("Speed Upgrade", ConfigCategories.BLOCKS_CRAFTING),
BAGUETTE("Baguette", ConfigCategories.FOOD_CRAFTING),
PIZZA("Pizza", ConfigCategories.FOOD_CRAFTING),
HAMBURGER("Hamburger", ConfigCategories.FOOD_CRAFTING),
@ -53,7 +51,6 @@ public enum ConfigCrafting{
CHOCOLATE_CAKE("Chocolate Cake", ConfigCategories.FOOD_CRAFTING),
TOAST("Toast", ConfigCategories.FOOD_CRAFTING),
CHOCOLATE_TOAST("Chocolate Toast", ConfigCategories.FOOD_CRAFTING),
LEAF_BLOWER("Leaf Blower", ConfigCategories.ITEMS_CRAFTING),
LEAF_BLOWER_ADVANCED("Advanced Leaf Blower", ConfigCategories.ITEMS_CRAFTING),
COIL("Coil", ConfigCategories.ITEMS_CRAFTING),
@ -62,7 +59,6 @@ public enum ConfigCrafting{
STICK_CRAFTER("Crafting Table On A Stick", ConfigCategories.ITEMS_CRAFTING),
MASHED_FOOD("Mashed Food", ConfigCategories.ITEMS_CRAFTING),
RARMOR_RECONSTRUCTOR_MODULE("Rarmor Reconstructor Module", ConfigCategories.ITEMS_CRAFTING),
RING_SPEED("Speed Ring", ConfigCategories.POTION_RING_CRAFTING),
RING_HASTE("Haste Ring", ConfigCategories.POTION_RING_CRAFTING),
RING_STRENGTH("Strength Ring", ConfigCategories.POTION_RING_CRAFTING),
@ -73,12 +69,10 @@ public enum ConfigCrafting{
RING_WATER_BREATHING("Water Breathing Ring", ConfigCategories.POTION_RING_CRAFTING),
RING_INVISIBILITY("Invisibility Ring", ConfigCategories.POTION_RING_CRAFTING),
RING_NIGHT_VISION("Night Vision Ring", ConfigCategories.POTION_RING_CRAFTING),
DOUGH("Dough", ConfigCategories.ITEMS_CRAFTING),
PAPER_CONE("Paper Cone", ConfigCategories.ITEMS_CRAFTING),
KNIFE_HANDLE("Knife Handle", ConfigCategories.ITEMS_CRAFTING),
KNIFE_BLADE("Knife Blade", ConfigCategories.ITEMS_CRAFTING),
TOOL_EMERALD("Emerald Tools", ConfigCategories.ITEMS_CRAFTING),
TOOL_OBSIDIAN("Obsidian Tools", ConfigCategories.ITEMS_CRAFTING),
TOOL_QUARTZ("Quartz Tools", ConfigCategories.ITEMS_CRAFTING),
@ -86,10 +80,8 @@ public enum ConfigCrafting{
RICE_BREAD("Rice Bread", ConfigCategories.FOOD_CRAFTING),
RICE_DOUGH("Rice Dough", ConfigCategories.FOOD_CRAFTING),
BACON("Bacon", ConfigCategories.FOOD_CRAFTING),
RICE_GADGETS("Rice Gadgets", ConfigCategories.ITEMS_CRAFTING),
RESONANT_RICE("Resonant Rice", ConfigCategories.ITEMS_CRAFTING),
CANOLA_PRESS("Canola Press", ConfigCategories.BLOCKS_CRAFTING),
FERMENTING_BARREL("Fermenting Barrel", ConfigCategories.BLOCKS_CRAFTING),
COAL_GENERATOR("Coal Generator", ConfigCategories.BLOCKS_CRAFTING),
@ -99,7 +91,6 @@ public enum ConfigCrafting{
PHANTOM_CONNECTOR("Phantom Connector", ConfigCategories.ITEMS_CRAFTING),
PLAYER_INTERFACE("Player Interface", ConfigCategories.BLOCKS_CRAFTING),
PLAYER_PROBE("Player Probe", ConfigCategories.ITEMS_CRAFTING),
PHANTOM_ENERGYFACE("Phantom Energyface", ConfigCategories.BLOCKS_CRAFTING),
PHANTOM_REDSTONEFACE("Phantom Redstoneface", ConfigCategories.BLOCKS_CRAFTING),
PHANTOM_LIQUIFACE("Phantom Liquiface", ConfigCategories.BLOCKS_CRAFTING),
@ -107,16 +98,12 @@ public enum ConfigCrafting{
PHANTOM_BREAKER("Phantom Breaker", ConfigCategories.BLOCKS_CRAFTING),
LIQUID_PLACER("Liquid Placer", ConfigCategories.BLOCKS_CRAFTING),
LIQUID_BREAKER("Liquid Collector", ConfigCategories.BLOCKS_CRAFTING),
CUP("Cup", ConfigCategories.ITEMS_CRAFTING),
PAXELS("Paxels", ConfigCategories.ITEMS_CRAFTING),
ENDER_CASING("Ender Casing", ConfigCategories.BLOCKS_CRAFTING),
PHANTOM_BOOSTER("Phantom Booster", ConfigCategories.BLOCKS_CRAFTING),
COFFEE_MACHINE("Coffee Machine", ConfigCategories.BLOCKS_CRAFTING),
LAVA_FACTORY("Lava Factory", ConfigCategories.BLOCKS_CRAFTING),
DRILL("Drill", ConfigCategories.ITEMS_CRAFTING),
DRILL_SPEED("Drill Speed Upgrades", ConfigCategories.ITEMS_CRAFTING),
DRILL_FORTUNE("Drill Fortune Upgrades", ConfigCategories.ITEMS_CRAFTING),
@ -129,21 +116,15 @@ public enum ConfigCrafting{
QUADRUPLE_BATTERY("Quadruple Battery", ConfigCategories.ITEMS_CRAFTING),
QUINTUPLE_BATTERY("Quintuple Battery", ConfigCategories.ITEMS_CRAFTING),
BAT_WINGS("Wings Of The Bats", ConfigCategories.ITEMS_CRAFTING),
ENERGIZER("Energizer", ConfigCategories.BLOCKS_CRAFTING),
ENERVATOR("Enervator", ConfigCategories.BLOCKS_CRAFTING),
QUARTZ("Black Quartz in a Crafting Table", ConfigCategories.ITEMS_CRAFTING),
LAMPS("Lamps", ConfigCategories.BLOCKS_CRAFTING),
HORSE_ARMORS("Horse Armor -> Raw Materials (Crusher)", ConfigCategories.OTHER),
RECONSTRUCTOR_MISC("Misc. Recipes like Soul Sand (Reconstructor)", ConfigCategories.OTHER),
RECONSTRUCTOR_EXPLOSION_LENS("Lens of Detonation (Reconstructor)", ConfigCategories.OTHER),
TELE_STAFF("Tele Staff", ConfigCategories.ITEMS_CRAFTING),
CASING("Casing", ConfigCategories.BLOCKS_CRAFTING),
MAGNET_RING("Magnet Ring", ConfigCategories.ITEMS_CRAFTING),
WATER_RING("Water Ring", ConfigCategories.ITEMS_CRAFTING),
GROWTH_RING("Growth Ring", ConfigCategories.ITEMS_CRAFTING),
@ -154,7 +135,6 @@ public enum ConfigCrafting{
LASER_RELAY_ITEM_WHITELIST("Advanced Item Laser Relay", ConfigCategories.BLOCKS_CRAFTING),
LASER_WRENCH("Laser Wrench", ConfigCategories.ITEMS_CRAFTING),
LASER_RELAY_FLUIDS("Fluid Laser Relay", ConfigCategories.BLOCKS_CRAFTING),
CHEST_TO_CRATE_UPGRADE("Chest To Crate Upgrade", ConfigCategories.ITEMS_CRAFTING),
DISENCHANTING_LENS("Disenchanting Lens", ConfigCategories.ITEMS_CRAFTING),
CRATE_KEEPER("Crate Keeper", ConfigCategories.ITEMS_CRAFTING),
@ -168,13 +148,12 @@ public enum ConfigCrafting{
ITEM_INTERFACE("Item Interface", ConfigCategories.BLOCKS_CRAFTING),
DISPLAY_STAND("Display Stand", ConfigCategories.BLOCKS_CRAFTING),
FILTER("Item Filter", ConfigCategories.ITEMS_CRAFTING),
CHARCOAL_BLOCK("Charcoal Block", ConfigCategories.BLOCKS_CRAFTING),
TINY_COAL("Tiny Coal", ConfigCategories.ITEMS_CRAFTING),
BAG("Bag", ConfigCategories.ITEMS_CRAFTING),
VOID_BAG("Void Bag", ConfigCategories.ITEMS_CRAFTING),
EMPOWERER("Empowerer", ConfigCategories.BLOCKS_CRAFTING);
EMPOWERER("Empowerer", ConfigCategories.BLOCKS_CRAFTING),
DISTRIBUTOR_ITEM("Item Distributor", ConfigCategories.BLOCKS_CRAFTING);
public final String name;
public final String category;

View file

@ -96,6 +96,7 @@ public final class BlockCrafting{
public static IRecipe recipeEmpowerer;
public static IRecipe[] recipesTinyTorch = new IRecipe[2];
public static IRecipe recipeFluidLaser;
public static IRecipe recipeDistributorItem;
public static void init(){
@ -134,6 +135,16 @@ public final class BlockCrafting{
recipeFireworkBox = RecipeUtil.lastIRecipe();
}
//Item Distributor
if(ConfigCrafting.DISTRIBUTOR_ITEM.isEnabled()){
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(InitBlocks.blockDistributorItem),
"WHW", "HCH", "WHW",
'W', "plankWood",
'H', new ItemStack(Blocks.HOPPER),
'C', new ItemStack(InitBlocks.blockMisc, 1, TheMiscBlocks.WOOD_CASING.ordinal())));
recipeDistributorItem = RecipeUtil.lastIRecipe();
}
//Shock Suppressor
if(ConfigCrafting.SHOCK_SUPPRESSOR.isEnabled()){
GameRegistry.addRecipe(new ShapedOreRecipe(new ItemStack(InitBlocks.blockShockSuppressor),

View file

@ -41,9 +41,9 @@ public class TileEntityDistributorItem extends TileEntityInventoryBase{
if(handlerUp != null){
for(int i = 0; i < handlerUp.getSlots(); i++){
ItemStack pullable = handlerUp.extractItem(i, Integer.MAX_VALUE, true);
ItemStack pullable = handlerUp.extractItem(i, 1, true);
if(pullable != null && (this.slots[0] == null || ItemUtil.canBeStacked(this.slots[0], pullable))){
ItemStack pulled = handlerUp.extractItem(i, this.slots[0] != null ? this.slots[0].getMaxStackSize()-this.slots[0].stackSize : Integer.MAX_VALUE, false);
ItemStack pulled = handlerUp.extractItem(i, 1, false);
if(pulled != null){
if(this.slots[0] == null){
this.slots[0] = pulled.copy();

View file

@ -227,6 +227,7 @@ tile.actuallyadditions.blockDisplayStand.name=Display Stand
tile.actuallyadditions.blockShockSuppressor.name=Shock Absorber
tile.actuallyadditions.blockTinyTorch.name=Tiny Torch
tile.actuallyadditions.blockEmpowerer.name=Empowerer
tile.actuallyadditions.blockDistributorItem.name=Item Distributor
#ESD
tile.actuallyadditions.blockInputter.name=ESD
@ -1016,4 +1017,7 @@ booklet.actuallyadditions.chapter.empowerer.text.3=<n><n><n><i>Because every mod
booklet.actuallyadditions.chapter.empowerer.text.4=The <item>Display Stand<r> can also be used for other things! See the <imp>Blocks that use RF<r> section for more info about it!
booklet.actuallyadditions.chapter.fluidLaser.name=Fluid Laser Relays
booklet.actuallyadditions.chapter.fluidLaser.text.1=The <item>Fluid Laser Relays<r> work much in the same way that normal Laser Relays do, so if you want to know anything about them, visit the <imp>Blocks that use RF<r> section of the manual. <n><n>The thing that makes the <item>Fluid Laser Relay<r> different from the <item>Energy Laser Relay<r>, however, is that it transfers <imp>fluids<r> from internal tanks of blocks into other blocks.
booklet.actuallyadditions.chapter.fluidLaser.text.1=The <item>Fluid Laser Relays<r> work much in the same way that normal Laser Relays do, so if you want to know anything about them, visit the <imp>Blocks that use RF<r> section of the manual. <n><n>The thing that makes the <item>Fluid Laser Relay<r> different from the <item>Energy Laser Relay<r>, however, is that it transfers <imp>fluids<r> from internal tanks of blocks into other blocks.
booklet.actuallyadditions.chapter.distributorItem.name=Item Distributor
booklet.actuallyadditions.chapter.distributorItem.text.1=The <item>Item Distributor<r> is a simple way to split up items and make them go <imp>in different directions<r>. <n><n>The distributor will <imp>pull items into it from the top<r> by itself, and then split them up and <imp>put them<r> out into inventories connected to all of the <imp>other sides<r> of it. <n>It tries to do split the items <imp>equally<r>, however this works best when inputting <imp>one item at a time<r>, which its pulling feature does automatically.