Reformatting code: First attempt

This commit is contained in:
OneEyeMaker 2017-09-23 10:00:11 +03:00
parent caa8677693
commit 37ab0f0dfb
19 changed files with 54 additions and 56 deletions

View file

@ -10,8 +10,6 @@
package de.ellpeck.actuallyadditions.mod.blocks;
import java.util.List;
import de.ellpeck.actuallyadditions.api.lens.ILensItem;
import de.ellpeck.actuallyadditions.mod.blocks.base.BlockContainerBase;
import de.ellpeck.actuallyadditions.mod.blocks.base.ItemBlockBase;
@ -49,11 +47,12 @@ import net.minecraft.world.World;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import java.util.List;
public class BlockAtomicReconstructor extends BlockContainerBase implements IHudDisplay{
public static final int NAME_FLAVOR_AMOUNTS_1 = 12;
public static final int NAME_FLAVOR_AMOUNTS_2 = 14;
public BlockAtomicReconstructor(String name){
super(Material.ROCK, name);
this.setHarvestLevel("pickaxe", 0);

View file

@ -10,8 +10,6 @@
package de.ellpeck.actuallyadditions.mod.booklet;
import java.util.*;
import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
import de.ellpeck.actuallyadditions.api.booklet.IBookletChapter;
import de.ellpeck.actuallyadditions.api.booklet.IBookletEntry;
@ -51,6 +49,8 @@ import net.minecraftforge.fluids.Fluid;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.FluidUtil;
import java.util.*;
public final class InitBooklet{
public static BookletChapter[] chaptersIntroduction = new BookletChapter[11];

View file

@ -10,10 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
import com.google.common.collect.Multimap;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import de.ellpeck.actuallyadditions.mod.blocks.metalists.TheColoredLampColors;
@ -48,6 +44,10 @@ import net.minecraftforge.common.ForgeHooks;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
public class ItemDrill extends ItemEnergy{
public static final int HARVEST_LEVEL = 4;

View file

@ -10,8 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items;
import java.util.List;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
import de.ellpeck.actuallyadditions.mod.items.base.ItemEnergy;
import de.ellpeck.actuallyadditions.mod.util.ModUtil;
@ -36,6 +34,8 @@ import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.RayTraceResult;
import net.minecraft.world.World;
import java.util.List;
public class ItemFillingWand extends ItemEnergy{
public ItemFillingWand(String name){

View file

@ -10,9 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items;
import java.util.ArrayList;
import java.util.List;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
import de.ellpeck.actuallyadditions.mod.items.base.ItemEnergy;
import de.ellpeck.actuallyadditions.mod.util.StackUtil;
@ -29,6 +26,9 @@ import net.minecraft.util.math.MathHelper;
import net.minecraft.world.World;
import net.minecraftforge.common.IPlantable;
import java.util.ArrayList;
import java.util.List;
public class ItemGrowthRing extends ItemEnergy{
public ItemGrowthRing(String name){

View file

@ -10,9 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items;
import java.util.ArrayList;
import java.util.Collections;
import de.ellpeck.actuallyadditions.api.misc.IDisplayStandItem;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
import de.ellpeck.actuallyadditions.mod.items.base.ItemBase;
@ -35,6 +32,9 @@ import net.minecraft.util.math.MathHelper;
import net.minecraft.world.World;
import net.minecraftforge.common.IShearable;
import java.util.ArrayList;
import java.util.Collections;
public class ItemLeafBlower extends ItemBase implements IDisplayStandItem{
private final boolean isAdvanced;
@ -108,8 +108,7 @@ public class ItemLeafBlower extends ItemBase implements IDisplayStandItem{
BlockPos pos = new BlockPos(x+reachX, y+reachY, z+reachZ);
Block block = world.getBlockState(pos).getBlock();
if((block instanceof BlockBush || block instanceof IShearable) &&
(this.isAdvanced || !block.isLeaves(world.getBlockState(pos), world, pos))){
if((block instanceof BlockBush || block instanceof IShearable) && (this.isAdvanced || !block.isLeaves(world.getBlockState(pos), world, pos))){
breakPositions.add(pos);
}
}

View file

@ -10,8 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items;
import java.util.ArrayList;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
import de.ellpeck.actuallyadditions.mod.items.base.ItemEnergy;
import de.ellpeck.actuallyadditions.mod.util.ItemUtil;
@ -27,6 +25,8 @@ import net.minecraft.util.EnumHand;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.world.World;
import java.util.ArrayList;
public class ItemMagnetRing extends ItemEnergy{
public ItemMagnetRing(String name){

View file

@ -10,10 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items;
import java.util.Collections;
import java.util.List;
import javax.annotation.Nullable;
import de.ellpeck.actuallyadditions.api.misc.IDisplayStandItem;
import de.ellpeck.actuallyadditions.mod.ActuallyAdditions;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
@ -39,6 +35,10 @@ import net.minecraft.world.World;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;
import javax.annotation.Nullable;
import java.util.Collections;
import java.util.List;
public class ItemPotionRing extends ItemBase implements IColorProvidingItem, IDisplayStandItem{
public static final ThePotionRings[] ALL_RINGS = ThePotionRings.values();

View file

@ -44,7 +44,7 @@ public class ItemTeleStaff extends ItemEnergy{
double y = pos.hitVec.y-(side == 0 ? 2.0 : 0)+(side == 1 ? 0.5 : 0);
double z = pos.hitVec.z-(side == 2 ? 0.5 : 0)+(side == 3 ? 0.5 : 0);
int baseUse = ConfigIntValues.TELEPORT_STAFF_ENERGY_USE.getValue();
int use = baseUse + (int)(baseUse * pos.hitVec.distanceTo(new Vec3d(player.posX, player.posY + (player.getEyeHeight() - player.getDefaultEyeHeight()), player.posZ)));
int use = baseUse+(int)(baseUse*pos.hitVec.distanceTo(new Vec3d(player.posX, player.posY+(player.getEyeHeight()-player.getDefaultEyeHeight()), player.posZ)));
if(this.getEnergyStored(stack) >= use){
((EntityPlayerMP)player).connection.setPlayerLocation(x, y, z, player.rotationYaw, player.rotationPitch);
player.dismountRidingEntity();

View file

@ -11,10 +11,6 @@
package de.ellpeck.actuallyadditions.mod.items.lens;
import java.util.ArrayList;
import java.util.Map;
import java.util.Random;
import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
import de.ellpeck.actuallyadditions.api.internal.IAtomicReconstructor;
import de.ellpeck.actuallyadditions.api.lens.Lens;
@ -34,6 +30,10 @@ import net.minecraft.util.math.BlockPos;
import net.minecraft.world.WorldServer;
import net.minecraftforge.common.util.FakePlayerFactory;
import java.util.ArrayList;
import java.util.Map;
import java.util.Random;
public class LensColor extends Lens{
//Thanks to xdjackiexd for this, as I couldn't be bothered

View file

@ -10,8 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items.lens;
import java.util.ArrayList;
import de.ellpeck.actuallyadditions.api.internal.IAtomicReconstructor;
import de.ellpeck.actuallyadditions.api.lens.Lens;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
@ -21,6 +19,8 @@ import net.minecraft.entity.EntityLivingBase;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import java.util.ArrayList;
public class LensDeath extends Lens{
@Override

View file

@ -10,9 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items.lens;
import java.util.List;
import java.util.Map;
import de.ellpeck.actuallyadditions.api.internal.IAtomicReconstructor;
import de.ellpeck.actuallyadditions.api.lens.Lens;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
@ -31,6 +28,9 @@ import net.minecraft.util.EnumFacing;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import java.util.List;
import java.util.Map;
public class LensDisenchanting extends Lens{
@Override

View file

@ -10,8 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items.lens;
import java.util.ArrayList;
import de.ellpeck.actuallyadditions.api.internal.IAtomicReconstructor;
import de.ellpeck.actuallyadditions.api.lens.Lens;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
@ -27,6 +25,8 @@ import net.minecraft.util.EnumFacing;
import net.minecraft.util.math.AxisAlignedBB;
import net.minecraft.util.math.BlockPos;
import java.util.ArrayList;
public class LensDisruption extends Lens{
@Override

View file

@ -10,8 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items.lens;
import java.util.List;
import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
import de.ellpeck.actuallyadditions.api.internal.IAtomicReconstructor;
import de.ellpeck.actuallyadditions.api.lens.Lens;
@ -37,6 +35,8 @@ import net.minecraft.world.WorldServer;
import net.minecraftforge.common.util.FakePlayerFactory;
import net.minecraftforge.oredict.OreDictionary;
import java.util.List;
public class LensMining extends Lens{

View file

@ -10,8 +10,6 @@
package de.ellpeck.actuallyadditions.mod.items.lens;
import java.util.ArrayList;
import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
import de.ellpeck.actuallyadditions.api.recipe.ColorLensChangerByDyeMeta;
import de.ellpeck.actuallyadditions.api.recipe.IColorLensChanger;
@ -28,6 +26,8 @@ import net.minecraft.init.Items;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import java.util.ArrayList;
public final class LensRecipeHandler{
public static final ArrayList<LensConversionRecipe> MAIN_PAGE_RECIPES = new ArrayList<LensConversionRecipe>();

View file

@ -10,9 +10,6 @@
package de.ellpeck.actuallyadditions.mod.misc.apiimpl;
import java.util.ArrayList;
import java.util.List;
import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
import de.ellpeck.actuallyadditions.api.booklet.IBookletChapter;
import de.ellpeck.actuallyadditions.api.booklet.IBookletEntry;
@ -51,6 +48,9 @@ import net.minecraft.util.math.BlockPos;
import net.minecraft.world.WorldServer;
import net.minecraftforge.common.util.FakePlayerFactory;
import java.util.ArrayList;
import java.util.List;
public class MethodHandler implements IMethodHandler{
@Override

View file

@ -10,9 +10,6 @@
package de.ellpeck.actuallyadditions.mod.recipe;
import java.util.ArrayList;
import java.util.List;
import de.ellpeck.actuallyadditions.api.ActuallyAdditionsAPI;
import de.ellpeck.actuallyadditions.api.recipe.EmpowererRecipe;
import de.ellpeck.actuallyadditions.mod.blocks.InitBlocks;
@ -26,6 +23,9 @@ import net.minecraft.init.Items;
import net.minecraft.item.ItemStack;
import net.minecraftforge.oredict.OreDictionary;
import java.util.ArrayList;
import java.util.List;
public final class EmpowererHandler{
public static final ArrayList<EmpowererRecipe> MAIN_PAGE_RECIPES = new ArrayList<EmpowererRecipe>();

View file

@ -10,9 +10,6 @@
package de.ellpeck.actuallyadditions.mod.tile;
import java.util.ArrayList;
import java.util.List;
import de.ellpeck.actuallyadditions.mod.config.values.ConfigIntValues;
import de.ellpeck.actuallyadditions.mod.util.StackUtil;
import net.minecraft.block.Block;
@ -27,6 +24,9 @@ import net.minecraft.util.EnumFacing;
import net.minecraftforge.common.IPlantable;
import net.minecraftforge.energy.IEnergyStorage;
import java.util.ArrayList;
import java.util.List;
public class TileEntityBioReactor extends TileEntityInventoryBase implements ISharingEnergyProvider{
public final CustomEnergyStorage storage;