mirror of
https://github.com/Ellpeck/ActuallyAdditions.git
synced 2024-11-22 23:28:35 +01:00
Cleanup~
This commit is contained in:
parent
e538ab5cad
commit
c05cdc1ec6
37 changed files with 59 additions and 83 deletions
|
@ -14,8 +14,8 @@ import io.netty.util.internal.ConcurrentSet;
|
||||||
|
|
||||||
public class Network{
|
public class Network{
|
||||||
|
|
||||||
public int changeAmount;
|
|
||||||
public final ConcurrentSet<IConnectionPair> connections = new ConcurrentSet<IConnectionPair>();
|
public final ConcurrentSet<IConnectionPair> connections = new ConcurrentSet<IConnectionPair>();
|
||||||
|
public int changeAmount;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString(){
|
public String toString(){
|
||||||
|
|
|
@ -30,7 +30,10 @@ import de.ellpeck.actuallyadditions.mod.items.lens.LensRecipeHandler;
|
||||||
import de.ellpeck.actuallyadditions.mod.items.lens.Lenses;
|
import de.ellpeck.actuallyadditions.mod.items.lens.Lenses;
|
||||||
import de.ellpeck.actuallyadditions.mod.material.InitArmorMaterials;
|
import de.ellpeck.actuallyadditions.mod.material.InitArmorMaterials;
|
||||||
import de.ellpeck.actuallyadditions.mod.material.InitToolMaterials;
|
import de.ellpeck.actuallyadditions.mod.material.InitToolMaterials;
|
||||||
import de.ellpeck.actuallyadditions.mod.misc.*;
|
import de.ellpeck.actuallyadditions.mod.misc.BannerHelper;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.misc.LaserRelayConnectionHandler;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.misc.MethodHandler;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.misc.SoundHandler;
|
||||||
import de.ellpeck.actuallyadditions.mod.network.PacketHandler;
|
import de.ellpeck.actuallyadditions.mod.network.PacketHandler;
|
||||||
import de.ellpeck.actuallyadditions.mod.ore.InitOreDict;
|
import de.ellpeck.actuallyadditions.mod.ore.InitOreDict;
|
||||||
import de.ellpeck.actuallyadditions.mod.proxy.IProxy;
|
import de.ellpeck.actuallyadditions.mod.proxy.IProxy;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("BlockDistributor.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("BlockDistributorItem.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("BlockQuartzInfuser.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("BlockEmpowerer.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -13,10 +13,7 @@ package de.ellpeck.actuallyadditions.mod.blocks;
|
||||||
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
|
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.base.BlockContainerBase;
|
import de.ellpeck.actuallyadditions.mod.blocks.base.BlockContainerBase;
|
||||||
import de.ellpeck.actuallyadditions.mod.inventory.GuiHandler;
|
import de.ellpeck.actuallyadditions.mod.inventory.GuiHandler;
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityBreaker;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityFarmer;
|
import de.ellpeck.actuallyadditions.mod.tile.TileEntityFarmer;
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityPlacer;
|
|
||||||
import net.minecraft.block.BlockPistonBase;
|
|
||||||
import net.minecraft.block.SoundType;
|
import net.minecraft.block.SoundType;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
import net.minecraft.block.properties.PropertyInteger;
|
import net.minecraft.block.properties.PropertyInteger;
|
||||||
|
|
|
@ -14,7 +14,6 @@ import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
|
||||||
import de.ellpeck.actuallyadditions.api.booklet.BookletPage;
|
import de.ellpeck.actuallyadditions.api.booklet.BookletPage;
|
||||||
import de.ellpeck.actuallyadditions.api.booklet.IBookletChapter;
|
import de.ellpeck.actuallyadditions.api.booklet.IBookletChapter;
|
||||||
import de.ellpeck.actuallyadditions.api.booklet.IBookletEntry;
|
import de.ellpeck.actuallyadditions.api.booklet.IBookletEntry;
|
||||||
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.metalists.TheColoredLampColors;
|
import de.ellpeck.actuallyadditions.mod.blocks.metalists.TheColoredLampColors;
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.metalists.TheMiscBlocks;
|
import de.ellpeck.actuallyadditions.mod.blocks.metalists.TheMiscBlocks;
|
||||||
|
|
|
@ -14,7 +14,6 @@ import de.ellpeck.actuallyadditions.api.booklet.BookletPage;
|
||||||
import de.ellpeck.actuallyadditions.api.internal.IBookletGui;
|
import de.ellpeck.actuallyadditions.api.internal.IBookletGui;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.text.TextFormatting;
|
import net.minecraft.util.text.TextFormatting;
|
||||||
import net.minecraftforge.fluids.Fluid;
|
import net.minecraftforge.fluids.Fluid;
|
||||||
import net.minecraftforge.fluids.FluidStack;
|
import net.minecraftforge.fluids.FluidStack;
|
||||||
|
@ -25,8 +24,8 @@ import java.util.Map;
|
||||||
|
|
||||||
public class BookletPageAA extends BookletPage{
|
public class BookletPageAA extends BookletPage{
|
||||||
|
|
||||||
protected List<FluidStack> fluidsForPage = new ArrayList<FluidStack>();
|
|
||||||
protected final int localizationKey;
|
protected final int localizationKey;
|
||||||
|
protected List<FluidStack> fluidsForPage = new ArrayList<FluidStack>();
|
||||||
|
|
||||||
public BookletPageAA(int localizationKey){
|
public BookletPageAA(int localizationKey){
|
||||||
this.localizationKey = localizationKey;
|
this.localizationKey = localizationKey;
|
||||||
|
|
|
@ -13,15 +13,16 @@ package de.ellpeck.actuallyadditions.mod.booklet.page;
|
||||||
import de.ellpeck.actuallyadditions.api.internal.IBookletGui;
|
import de.ellpeck.actuallyadditions.api.internal.IBookletGui;
|
||||||
import de.ellpeck.actuallyadditions.api.recipe.CrusherRecipe;
|
import de.ellpeck.actuallyadditions.api.recipe.CrusherRecipe;
|
||||||
import de.ellpeck.actuallyadditions.mod.booklet.GuiBooklet;
|
import de.ellpeck.actuallyadditions.mod.booklet.GuiBooklet;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.*;
|
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.util.Util;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.text.TextFormatting;
|
import net.minecraft.util.text.TextFormatting;
|
||||||
import net.minecraftforge.fml.relauncher.Side;
|
import net.minecraftforge.fml.relauncher.Side;
|
||||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
|
|
||||||
public class PageCrusherRecipe extends BookletPageAA{
|
public class PageCrusherRecipe extends BookletPageAA{
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,10 @@ import de.ellpeck.actuallyadditions.api.internal.IBookletGui;
|
||||||
import de.ellpeck.actuallyadditions.api.recipe.LensConversionRecipe;
|
import de.ellpeck.actuallyadditions.api.recipe.LensConversionRecipe;
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
||||||
import de.ellpeck.actuallyadditions.mod.booklet.GuiBooklet;
|
import de.ellpeck.actuallyadditions.mod.booklet.GuiBooklet;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.*;
|
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
|
import de.ellpeck.actuallyadditions.mod.util.Util;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.util.text.TextFormatting;
|
import net.minecraft.util.text.TextFormatting;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("RecipeKeepNBT.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("RecipeKeepDataShaped.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("RecipeKeepNBTShapeless.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("RecipeKeepDataShapeless.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -10,18 +10,14 @@
|
||||||
|
|
||||||
package de.ellpeck.actuallyadditions.mod.event;
|
package de.ellpeck.actuallyadditions.mod.event;
|
||||||
|
|
||||||
import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
|
|
||||||
import de.ellpeck.actuallyadditions.api.laser.LaserType;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.achievement.InitAchievements;
|
import de.ellpeck.actuallyadditions.mod.achievement.InitAchievements;
|
||||||
import de.ellpeck.actuallyadditions.mod.achievement.TheAchievements;
|
import de.ellpeck.actuallyadditions.mod.achievement.TheAchievements;
|
||||||
import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues;
|
import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues;
|
||||||
import de.ellpeck.actuallyadditions.mod.data.PlayerData;
|
import de.ellpeck.actuallyadditions.mod.data.PlayerData;
|
||||||
import de.ellpeck.actuallyadditions.mod.data.WorldData;
|
import de.ellpeck.actuallyadditions.mod.data.WorldData;
|
||||||
import de.ellpeck.actuallyadditions.mod.items.InitItems;
|
import de.ellpeck.actuallyadditions.mod.items.InitItems;
|
||||||
import de.ellpeck.actuallyadditions.mod.misc.ConnectionPair;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.misc.DungeonLoot;
|
import de.ellpeck.actuallyadditions.mod.misc.DungeonLoot;
|
||||||
import de.ellpeck.actuallyadditions.mod.network.PacketHandlerHelper;
|
import de.ellpeck.actuallyadditions.mod.network.PacketHandlerHelper;
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityLaserRelay;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.util.ItemUtil;
|
import de.ellpeck.actuallyadditions.mod.util.ItemUtil;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.Util;
|
import de.ellpeck.actuallyadditions.mod.util.Util;
|
||||||
|
@ -33,7 +29,6 @@ import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.nbt.NBTTagList;
|
import net.minecraft.nbt.NBTTagList;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
import net.minecraftforge.common.MinecraftForge;
|
import net.minecraftforge.common.MinecraftForge;
|
||||||
import net.minecraftforge.event.entity.living.LivingDeathEvent;
|
import net.minecraftforge.event.entity.living.LivingDeathEvent;
|
||||||
import net.minecraftforge.event.entity.living.LivingDropsEvent;
|
import net.minecraftforge.event.entity.living.LivingDropsEvent;
|
||||||
|
|
|
@ -14,10 +14,7 @@ import de.ellpeck.actuallyadditions.mod.misc.DungeonLoot;
|
||||||
import net.minecraft.block.*;
|
import net.minecraft.block.*;
|
||||||
import net.minecraft.block.state.IBlockState;
|
import net.minecraft.block.state.IBlockState;
|
||||||
import net.minecraft.init.Blocks;
|
import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
|
||||||
import net.minecraft.tileentity.TileEntityChest;
|
|
||||||
import net.minecraft.util.EnumFacing;
|
import net.minecraft.util.EnumFacing;
|
||||||
import net.minecraft.util.math.BlockPos;
|
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.gen.structure.StructureBoundingBox;
|
import net.minecraft.world.gen.structure.StructureBoundingBox;
|
||||||
import net.minecraft.world.gen.structure.StructureComponent;
|
import net.minecraft.world.gen.structure.StructureComponent;
|
||||||
|
|
|
@ -10,10 +10,8 @@
|
||||||
|
|
||||||
package de.ellpeck.actuallyadditions.mod.gen;
|
package de.ellpeck.actuallyadditions.mod.gen;
|
||||||
|
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.misc.DungeonLoot;
|
import de.ellpeck.actuallyadditions.mod.misc.DungeonLoot;
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.BlockLeaves;
|
|
||||||
import net.minecraft.block.state.IBlockState;
|
import net.minecraft.block.state.IBlockState;
|
||||||
import net.minecraft.init.Blocks;
|
import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
|
|
|
@ -12,7 +12,6 @@ package de.ellpeck.actuallyadditions.mod.inventory;
|
||||||
|
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityBase;
|
import de.ellpeck.actuallyadditions.mod.tile.TileEntityBase;
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityFarmer;
|
import de.ellpeck.actuallyadditions.mod.tile.TileEntityFarmer;
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityFurnaceDouble;
|
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.entity.player.InventoryPlayer;
|
import net.minecraft.entity.player.InventoryPlayer;
|
||||||
import net.minecraft.inventory.Container;
|
import net.minecraft.inventory.Container;
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
package de.ellpeck.actuallyadditions.mod.inventory.gui;
|
package de.ellpeck.actuallyadditions.mod.inventory.gui;
|
||||||
|
|
||||||
import de.ellpeck.actuallyadditions.mod.inventory.ContainerBioReactor;
|
import de.ellpeck.actuallyadditions.mod.inventory.ContainerBioReactor;
|
||||||
import de.ellpeck.actuallyadditions.mod.inventory.ContainerBreaker;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityBase;
|
import de.ellpeck.actuallyadditions.mod.tile.TileEntityBase;
|
||||||
import de.ellpeck.actuallyadditions.mod.tile.TileEntityBioReactor;
|
import de.ellpeck.actuallyadditions.mod.tile.TileEntityBioReactor;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
||||||
|
|
|
@ -20,7 +20,6 @@ import net.minecraft.entity.player.EntityPlayer;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.world.World;
|
|
||||||
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
import net.minecraftforge.common.capabilities.ICapabilityProvider;
|
||||||
import net.minecraftforge.fml.relauncher.Side;
|
import net.minecraftforge.fml.relauncher.Side;
|
||||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||||
|
|
|
@ -74,6 +74,10 @@ public class LensMining extends Lens{
|
||||||
add(NETHERRACK_ORES, "oreArdite", 50);
|
add(NETHERRACK_ORES, "oreArdite", 50);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private static void add(List<WeightedOre> list, String name, int weight){
|
||||||
|
list.add(new WeightedOre(name, weight));
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean invoke(IBlockState hitState, BlockPos hitPos, IAtomicReconstructor tile){
|
public boolean invoke(IBlockState hitState, BlockPos hitPos, IAtomicReconstructor tile){
|
||||||
if(!tile.getWorldObject().isAirBlock(hitPos)){
|
if(!tile.getWorldObject().isAirBlock(hitPos)){
|
||||||
|
@ -146,10 +150,6 @@ public class LensMining extends Lens{
|
||||||
return 10;
|
return 10;
|
||||||
}
|
}
|
||||||
|
|
||||||
private static void add(List<WeightedOre> list, String name, int weight){
|
|
||||||
list.add(new WeightedOre(name, weight));
|
|
||||||
}
|
|
||||||
|
|
||||||
private static class WeightedOre extends WeightedRandom.Item{
|
private static class WeightedOre extends WeightedRandom.Item{
|
||||||
|
|
||||||
public final String name;
|
public final String name;
|
||||||
|
|
|
@ -22,7 +22,6 @@ import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.util.text.TextFormatting;
|
import net.minecraft.util.text.TextFormatting;
|
||||||
import net.minecraftforge.fluids.FluidStack;
|
import net.minecraftforge.fluids.FluidStack;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
package de.ellpeck.actuallyadditions.mod.jei.crusher;
|
package de.ellpeck.actuallyadditions.mod.jei.crusher;
|
||||||
|
|
||||||
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.RecipeUtil;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
import mezz.jei.api.IGuiHelper;
|
import mezz.jei.api.IGuiHelper;
|
||||||
import mezz.jei.api.gui.IDrawable;
|
import mezz.jei.api.gui.IDrawable;
|
||||||
|
@ -20,9 +19,6 @@ import mezz.jei.api.ingredients.IIngredients;
|
||||||
import mezz.jei.api.recipe.IRecipeCategory;
|
import mezz.jei.api.recipe.IRecipeCategory;
|
||||||
import mezz.jei.api.recipe.IRecipeWrapper;
|
import mezz.jei.api.recipe.IRecipeWrapper;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public class CrusherRecipeCategory implements IRecipeCategory{
|
public class CrusherRecipeCategory implements IRecipeCategory{
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,6 @@ import de.ellpeck.actuallyadditions.api.recipe.CrusherRecipe;
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
||||||
import de.ellpeck.actuallyadditions.mod.booklet.BookletUtils;
|
import de.ellpeck.actuallyadditions.mod.booklet.BookletUtils;
|
||||||
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.RecipeUtil;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
import mezz.jei.api.recipe.IRecipeWrapper;
|
import mezz.jei.api.recipe.IRecipeWrapper;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("ReconstructorRecipeCategory.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("EmpowererRecipeCategory.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("ReconstructorRecipeHandler.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("EmpowererRecipeHandler.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("ReconstructorRecipeWrapper.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("EmpowererRecipeWrapper.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -12,7 +12,6 @@ package de.ellpeck.actuallyadditions.mod.jei.reconstructor;
|
||||||
|
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
import de.ellpeck.actuallyadditions.mod.util.AssetUtil;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.RecipeUtil;
|
|
||||||
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
import de.ellpeck.actuallyadditions.mod.util.StringUtil;
|
||||||
import mezz.jei.api.IGuiHelper;
|
import mezz.jei.api.IGuiHelper;
|
||||||
import mezz.jei.api.gui.IDrawable;
|
import mezz.jei.api.gui.IDrawable;
|
||||||
|
|
|
@ -15,7 +15,6 @@ import de.ellpeck.actuallyadditions.api.recipe.LensConversionRecipe;
|
||||||
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
|
||||||
import de.ellpeck.actuallyadditions.mod.booklet.BookletUtils;
|
import de.ellpeck.actuallyadditions.mod.booklet.BookletUtils;
|
||||||
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
import de.ellpeck.actuallyadditions.mod.jei.RecipeWrapperWithButton;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.RecipeUtil;
|
|
||||||
import mezz.jei.api.ingredients.IIngredients;
|
import mezz.jei.api.ingredients.IIngredients;
|
||||||
import mezz.jei.api.recipe.IRecipeWrapper;
|
import mezz.jei.api.recipe.IRecipeWrapper;
|
||||||
import net.minecraft.client.Minecraft;
|
import net.minecraft.client.Minecraft;
|
||||||
|
|
|
@ -19,7 +19,6 @@ import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
|
||||||
import net.minecraft.init.Items;
|
import net.minecraft.init.Items;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
import net.minecraft.item.ItemStack;
|
|
||||||
import net.minecraft.util.ResourceLocation;
|
import net.minecraft.util.ResourceLocation;
|
||||||
import net.minecraft.world.storage.loot.*;
|
import net.minecraft.world.storage.loot.*;
|
||||||
import net.minecraft.world.storage.loot.conditions.LootCondition;
|
import net.minecraft.world.storage.loot.conditions.LootCondition;
|
||||||
|
|
|
@ -26,7 +26,6 @@ import de.ellpeck.actuallyadditions.mod.booklet.page.PageTextOnly;
|
||||||
import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues;
|
import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues;
|
||||||
import de.ellpeck.actuallyadditions.mod.items.lens.LensRecipeHandler;
|
import de.ellpeck.actuallyadditions.mod.items.lens.LensRecipeHandler;
|
||||||
import de.ellpeck.actuallyadditions.mod.recipe.CrusherRecipeRegistry;
|
import de.ellpeck.actuallyadditions.mod.recipe.CrusherRecipeRegistry;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.RecipeUtil;
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.state.IBlockState;
|
import net.minecraft.block.state.IBlockState;
|
||||||
import net.minecraft.entity.item.EntityItem;
|
import net.minecraft.entity.item.EntityItem;
|
||||||
|
|
|
@ -19,7 +19,6 @@ import de.ellpeck.actuallyadditions.mod.items.metalists.TheMiscItems;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.RecipeUtil;
|
import de.ellpeck.actuallyadditions.mod.util.RecipeUtil;
|
||||||
import net.minecraft.init.Blocks;
|
import net.minecraft.init.Blocks;
|
||||||
import net.minecraft.init.Items;
|
import net.minecraft.init.Items;
|
||||||
import net.minecraft.item.EnumDyeColor;
|
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraftforge.oredict.OreDictionary;
|
import net.minecraftforge.oredict.OreDictionary;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("IDontWannaUseRFReceiver.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("ICustomEnergyReceiver.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* This file ("IEnergyProviderBetter.java") is part of the Actually Additions mod for Minecraft.
|
* This file ("ISharingEnergyProvider.java") is part of the Actually Additions mod for Minecraft.
|
||||||
* It is created and owned by Ellpeck and distributed
|
* It is created and owned by Ellpeck and distributed
|
||||||
* under the Actually Additions License to be found at
|
* under the Actually Additions License to be found at
|
||||||
* http://ellpeck.de/actaddlicense
|
* http://ellpeck.de/actaddlicense
|
||||||
|
|
|
@ -39,6 +39,23 @@ public class TileEntityBioReactor extends TileEntityInventoryBase implements ISh
|
||||||
super(8, "bioReactor");
|
super(8, "bioReactor");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static boolean isValidItem(ItemStack stack){
|
||||||
|
if(stack != null){
|
||||||
|
Item item = stack.getItem();
|
||||||
|
if(isValid(item)){
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if(item instanceof ItemBlock){
|
||||||
|
return isValid(Block.getBlockFromItem(item));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static boolean isValid(Object o){
|
||||||
|
return o instanceof IPlantable || o instanceof IGrowable || o instanceof ItemFood;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void updateEntity(){
|
public void updateEntity(){
|
||||||
super.updateEntity();
|
super.updateEntity();
|
||||||
|
@ -112,23 +129,6 @@ public class TileEntityBioReactor extends TileEntityInventoryBase implements ISh
|
||||||
this.producePerTick = compound.getInteger("ProducePerTick");
|
this.producePerTick = compound.getInteger("ProducePerTick");
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isValidItem(ItemStack stack){
|
|
||||||
if(stack != null){
|
|
||||||
Item item = stack.getItem();
|
|
||||||
if(isValid(item)){
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
else if(item instanceof ItemBlock){
|
|
||||||
return isValid(Block.getBlockFromItem(item));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static boolean isValid(Object o){
|
|
||||||
return o instanceof IPlantable || o instanceof IGrowable || o instanceof ItemFood;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean canInsertItem(int index, ItemStack stack, EnumFacing direction){
|
public boolean canInsertItem(int index, ItemStack stack, EnumFacing direction){
|
||||||
return this.isItemValidForSlot(index, stack);
|
return this.isItemValidForSlot(index, stack);
|
||||||
|
|
|
@ -15,7 +15,6 @@ import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.Util;
|
import de.ellpeck.actuallyadditions.mod.util.Util;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.WorldUtil;
|
import de.ellpeck.actuallyadditions.mod.util.WorldUtil;
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.BlockAir;
|
|
||||||
import net.minecraft.block.BlockLiquid;
|
import net.minecraft.block.BlockLiquid;
|
||||||
import net.minecraft.block.state.IBlockState;
|
import net.minecraft.block.state.IBlockState;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
|
@ -15,7 +15,6 @@ import de.ellpeck.actuallyadditions.mod.config.values.ConfigBoolValues;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.Util;
|
import de.ellpeck.actuallyadditions.mod.util.Util;
|
||||||
import de.ellpeck.actuallyadditions.mod.util.WorldUtil;
|
import de.ellpeck.actuallyadditions.mod.util.WorldUtil;
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.BlockAir;
|
|
||||||
import net.minecraft.block.state.IBlockState;
|
import net.minecraft.block.state.IBlockState;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
|
|
@ -35,12 +35,6 @@ public abstract class TileEntityInventoryBase extends TileEntityBase implements
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void getInvWrappers(SidedInvWrapper[] wrappers){
|
|
||||||
for(int i = 0; i < wrappers.length; i++){
|
|
||||||
wrappers[i] = new SidedInvWrapper(this, EnumFacing.values()[i]);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void saveSlots(ItemStack[] slots, NBTTagCompound compound){
|
public static void saveSlots(ItemStack[] slots, NBTTagCompound compound){
|
||||||
if(slots != null && slots.length > 0){
|
if(slots != null && slots.length > 0){
|
||||||
NBTTagList tagList = new NBTTagList();
|
NBTTagList tagList = new NBTTagList();
|
||||||
|
@ -65,6 +59,12 @@ public abstract class TileEntityInventoryBase extends TileEntityBase implements
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected void getInvWrappers(SidedInvWrapper[] wrappers){
|
||||||
|
for(int i = 0; i < wrappers.length; i++){
|
||||||
|
wrappers[i] = new SidedInvWrapper(this, EnumFacing.values()[i]);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void writeSyncableNBT(NBTTagCompound compound, NBTType type){
|
public void writeSyncableNBT(NBTTagCompound compound, NBTType type){
|
||||||
super.writeSyncableNBT(compound, type);
|
super.writeSyncableNBT(compound, type);
|
||||||
|
|
|
@ -24,10 +24,9 @@ import java.util.*;
|
||||||
|
|
||||||
public class TileEntityItemViewer extends TileEntityInventoryBase{
|
public class TileEntityItemViewer extends TileEntityInventoryBase{
|
||||||
|
|
||||||
public TileEntityLaserRelayItem connectedRelay;
|
|
||||||
|
|
||||||
private final List<GenericItemHandlerInfo> genericInfos = new ArrayList<GenericItemHandlerInfo>();
|
private final List<GenericItemHandlerInfo> genericInfos = new ArrayList<GenericItemHandlerInfo>();
|
||||||
private final Map<Integer, SpecificItemHandlerInfo> specificInfos = new HashMap<Integer, SpecificItemHandlerInfo>();
|
private final Map<Integer, SpecificItemHandlerInfo> specificInfos = new HashMap<Integer, SpecificItemHandlerInfo>();
|
||||||
|
public TileEntityLaserRelayItem connectedRelay;
|
||||||
private int lastNetworkChangeAmount = -1;
|
private int lastNetworkChangeAmount = -1;
|
||||||
|
|
||||||
public TileEntityItemViewer(){
|
public TileEntityItemViewer(){
|
||||||
|
|
|
@ -16,6 +16,7 @@ import de.ellpeck.actuallyadditions.api.recipe.EmpowererRecipe;
|
||||||
import de.ellpeck.actuallyadditions.api.recipe.LensConversionRecipe;
|
import de.ellpeck.actuallyadditions.api.recipe.LensConversionRecipe;
|
||||||
import net.minecraft.item.crafting.CraftingManager;
|
import net.minecraft.item.crafting.CraftingManager;
|
||||||
import net.minecraft.item.crafting.IRecipe;
|
import net.minecraft.item.crafting.IRecipe;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
public final class RecipeUtil{
|
public final class RecipeUtil{
|
||||||
|
|
Loading…
Reference in a new issue