diff --git a/src/main/java/com/jozufozu/flywheel/backend/instancing/InstancedRenderDispatcher.java b/src/main/java/com/jozufozu/flywheel/backend/instancing/InstancedRenderDispatcher.java index 6df479ddc..e1525c919 100644 --- a/src/main/java/com/jozufozu/flywheel/backend/instancing/InstancedRenderDispatcher.java +++ b/src/main/java/com/jozufozu/flywheel/backend/instancing/InstancedRenderDispatcher.java @@ -17,7 +17,6 @@ import com.jozufozu.flywheel.backend.instancing.entity.EntityInstanceManager; import com.jozufozu.flywheel.backend.instancing.tile.TileInstanceManager; import com.jozufozu.flywheel.core.Contexts; import com.jozufozu.flywheel.core.crumbling.CrumblingInstanceManager; -import com.jozufozu.flywheel.core.crumbling.CrumblingProgram; import com.jozufozu.flywheel.event.BeginFrameEvent; import com.jozufozu.flywheel.event.ReloadRenderersEvent; import com.jozufozu.flywheel.event.RenderLayerEvent; diff --git a/src/main/java/com/jozufozu/flywheel/backend/instancing/entity/EntityInstanceManager.java b/src/main/java/com/jozufozu/flywheel/backend/instancing/entity/EntityInstanceManager.java index a2b5bc186..5c6a533f5 100644 --- a/src/main/java/com/jozufozu/flywheel/backend/instancing/entity/EntityInstanceManager.java +++ b/src/main/java/com/jozufozu/flywheel/backend/instancing/entity/EntityInstanceManager.java @@ -7,7 +7,6 @@ import com.jozufozu.flywheel.backend.instancing.InstancedRenderRegistry; import com.jozufozu.flywheel.backend.instancing.MaterialManager; import net.minecraft.entity.Entity; -import net.minecraft.tileentity.TileEntity; import net.minecraft.util.math.BlockPos; import net.minecraft.world.IBlockReader; import net.minecraft.world.World; diff --git a/src/main/java/com/jozufozu/flywheel/core/atlas/AtlasInfo.java b/src/main/java/com/jozufozu/flywheel/core/atlas/AtlasInfo.java index 91333f875..5875e6136 100644 --- a/src/main/java/com/jozufozu/flywheel/core/atlas/AtlasInfo.java +++ b/src/main/java/com/jozufozu/flywheel/core/atlas/AtlasInfo.java @@ -1,5 +1,8 @@ package com.jozufozu.flywheel.core.atlas; +import java.util.HashMap; +import java.util.Map; + import com.jozufozu.flywheel.mixin.atlas.SheetDataAccessor; import net.minecraft.client.Minecraft; @@ -8,9 +11,6 @@ import net.minecraft.client.renderer.texture.Texture; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.util.ResourceLocation; -import java.util.HashMap; -import java.util.Map; - public class AtlasInfo { private static final Map sheetData = new HashMap<>(); diff --git a/src/main/java/com/jozufozu/flywheel/core/atlas/SheetData.java b/src/main/java/com/jozufozu/flywheel/core/atlas/SheetData.java index 9841e6899..e015ab5cf 100644 --- a/src/main/java/com/jozufozu/flywheel/core/atlas/SheetData.java +++ b/src/main/java/com/jozufozu/flywheel/core/atlas/SheetData.java @@ -1,11 +1,5 @@ package com.jozufozu.flywheel.core.atlas; -import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.util.ResourceLocation; - -import java.util.List; -import java.util.Set; - public class SheetData { public final int width; public final int height; diff --git a/src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingInstanceManager.java b/src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingInstanceManager.java index 8d2cbc8eb..708f800ab 100644 --- a/src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingInstanceManager.java +++ b/src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingInstanceManager.java @@ -1,10 +1,7 @@ package com.jozufozu.flywheel.core.crumbling; -import com.jozufozu.flywheel.backend.instancing.MaterialManager; import com.jozufozu.flywheel.backend.instancing.tile.TileInstanceManager; -import com.jozufozu.flywheel.core.Contexts; - import net.minecraft.util.math.BlockPos; public class CrumblingInstanceManager extends TileInstanceManager { diff --git a/src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingMaterialManager.java b/src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingMaterialManager.java index 2d8a6a8cb..5d9a01754 100644 --- a/src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingMaterialManager.java +++ b/src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingMaterialManager.java @@ -1,13 +1,19 @@ package com.jozufozu.flywheel.core.crumbling; +import static org.lwjgl.opengl.GL11.GL_TEXTURE_2D; +import static org.lwjgl.opengl.GL11.glBindTexture; +import static org.lwjgl.opengl.GL13.GL_TEXTURE0; +import static org.lwjgl.opengl.GL13.glActiveTexture; + +import java.util.ArrayList; +import java.util.Map; + import com.jozufozu.flywheel.backend.instancing.MaterialManager; import com.jozufozu.flywheel.backend.instancing.MaterialRenderer; import com.jozufozu.flywheel.core.Contexts; -import com.jozufozu.flywheel.core.WorldContext; import com.jozufozu.flywheel.core.atlas.AtlasInfo; import com.jozufozu.flywheel.core.atlas.SheetData; import com.jozufozu.flywheel.core.shader.IProgramCallback; -import com.jozufozu.flywheel.core.shader.WorldProgram; import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.RenderType; @@ -16,14 +22,6 @@ import net.minecraft.inventory.container.PlayerContainer; import net.minecraft.util.ResourceLocation; import net.minecraft.util.math.vector.Matrix4f; -import java.util.ArrayList; -import java.util.Map; - -import static org.lwjgl.opengl.GL11.GL_TEXTURE_2D; -import static org.lwjgl.opengl.GL11.glBindTexture; -import static org.lwjgl.opengl.GL13.GL_TEXTURE0; -import static org.lwjgl.opengl.GL13.glActiveTexture; - public class CrumblingMaterialManager extends MaterialManager { public CrumblingMaterialManager() { diff --git a/src/main/java/com/jozufozu/flywheel/core/materials/OrientedData.java b/src/main/java/com/jozufozu/flywheel/core/materials/OrientedData.java index 92e8f8a7c..a74bf3a73 100644 --- a/src/main/java/com/jozufozu/flywheel/core/materials/OrientedData.java +++ b/src/main/java/com/jozufozu/flywheel/core/materials/OrientedData.java @@ -2,7 +2,6 @@ package com.jozufozu.flywheel.core.materials; import com.jozufozu.flywheel.backend.gl.buffer.MappedBuffer; import com.jozufozu.flywheel.backend.instancing.Instancer; - import com.jozufozu.flywheel.util.vec.Vec3; import net.minecraft.util.math.BlockPos; diff --git a/src/main/java/com/jozufozu/flywheel/core/model/PartBuilder.java b/src/main/java/com/jozufozu/flywheel/core/model/PartBuilder.java index 721355dc2..5aa2e92d9 100644 --- a/src/main/java/com/jozufozu/flywheel/core/model/PartBuilder.java +++ b/src/main/java/com/jozufozu/flywheel/core/model/PartBuilder.java @@ -1,25 +1,21 @@ package com.jozufozu.flywheel.core.model; -import static com.jozufozu.flywheel.util.RenderMath.*; - -import com.jozufozu.flywheel.backend.gl.buffer.VecBuffer; -import com.jozufozu.flywheel.backend.model.BufferedModel; - -import com.jozufozu.flywheel.backend.model.IndexedModel; - -import com.jozufozu.flywheel.core.Formats; - -import com.jozufozu.flywheel.core.atlas.AtlasInfo; - -import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.util.Direction; -import net.minecraft.util.math.vector.Vector3f; +import static com.jozufozu.flywheel.util.RenderMath.nb; import java.util.ArrayList; import java.util.EnumSet; import java.util.List; import java.util.Set; +import com.jozufozu.flywheel.backend.gl.buffer.VecBuffer; +import com.jozufozu.flywheel.backend.model.BufferedModel; +import com.jozufozu.flywheel.backend.model.IndexedModel; +import com.jozufozu.flywheel.core.Formats; + +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.util.Direction; +import net.minecraft.util.math.vector.Vector3f; + public class PartBuilder { private float sizeU = 64.0F; diff --git a/src/main/java/com/jozufozu/flywheel/mixin/CancelEntityRenderMixin.java b/src/main/java/com/jozufozu/flywheel/mixin/CancelEntityRenderMixin.java index 1042fccc7..84e78bee5 100644 --- a/src/main/java/com/jozufozu/flywheel/mixin/CancelEntityRenderMixin.java +++ b/src/main/java/com/jozufozu/flywheel/mixin/CancelEntityRenderMixin.java @@ -3,8 +3,6 @@ package com.jozufozu.flywheel.mixin; import java.util.ArrayList; import java.util.Iterator; -import com.jozufozu.flywheel.backend.instancing.InstancedRenderRegistry; - import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.injection.At; import org.spongepowered.asm.mixin.injection.Group; @@ -12,6 +10,7 @@ import org.spongepowered.asm.mixin.injection.Redirect; import com.google.common.collect.Lists; import com.jozufozu.flywheel.backend.Backend; +import com.jozufozu.flywheel.backend.instancing.InstancedRenderRegistry; import net.minecraft.client.renderer.WorldRenderer; import net.minecraft.client.world.ClientWorld; diff --git a/src/main/java/com/jozufozu/flywheel/mixin/CancelTileEntityRenderMixin.java b/src/main/java/com/jozufozu/flywheel/mixin/CancelTileEntityRenderMixin.java index 7a73e73ee..e26f9ef79 100644 --- a/src/main/java/com/jozufozu/flywheel/mixin/CancelTileEntityRenderMixin.java +++ b/src/main/java/com/jozufozu/flywheel/mixin/CancelTileEntityRenderMixin.java @@ -2,14 +2,13 @@ package com.jozufozu.flywheel.mixin; import java.util.List; -import com.jozufozu.flywheel.backend.instancing.InstancedRenderRegistry; - import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.injection.At; import org.spongepowered.asm.mixin.injection.Inject; import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; import com.jozufozu.flywheel.backend.Backend; +import com.jozufozu.flywheel.backend.instancing.InstancedRenderRegistry; import net.minecraft.client.renderer.chunk.ChunkRenderDispatcher; import net.minecraft.tileentity.TileEntity; diff --git a/src/main/java/com/jozufozu/flywheel/mixin/TileWorldHookMixin.java b/src/main/java/com/jozufozu/flywheel/mixin/TileWorldHookMixin.java index 33b86d182..071709622 100644 --- a/src/main/java/com/jozufozu/flywheel/mixin/TileWorldHookMixin.java +++ b/src/main/java/com/jozufozu/flywheel/mixin/TileWorldHookMixin.java @@ -12,7 +12,6 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; import com.jozufozu.flywheel.backend.instancing.InstanceManager; import com.jozufozu.flywheel.backend.instancing.InstancedRenderDispatcher; -import com.jozufozu.flywheel.backend.instancing.tile.TileInstanceManager; import net.minecraft.tileentity.TileEntity; import net.minecraft.world.World; diff --git a/src/main/java/com/jozufozu/flywheel/mixin/atlas/AtlasDataMixin.java b/src/main/java/com/jozufozu/flywheel/mixin/atlas/AtlasDataMixin.java index 27c5eb5c8..d458c21f3 100644 --- a/src/main/java/com/jozufozu/flywheel/mixin/atlas/AtlasDataMixin.java +++ b/src/main/java/com/jozufozu/flywheel/mixin/atlas/AtlasDataMixin.java @@ -1,12 +1,6 @@ package com.jozufozu.flywheel.mixin.atlas; -import com.jozufozu.flywheel.core.atlas.AtlasInfo; - -import net.minecraft.client.renderer.texture.AtlasTexture; - -import net.minecraft.profiler.IProfiler; -import net.minecraft.resources.IResourceManager; -import net.minecraft.util.ResourceLocation; +import java.util.stream.Stream; import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.Shadow; @@ -14,7 +8,12 @@ import org.spongepowered.asm.mixin.injection.At; import org.spongepowered.asm.mixin.injection.Inject; import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable; -import java.util.stream.Stream; +import com.jozufozu.flywheel.core.atlas.AtlasInfo; + +import net.minecraft.client.renderer.texture.AtlasTexture; +import net.minecraft.profiler.IProfiler; +import net.minecraft.resources.IResourceManager; +import net.minecraft.util.ResourceLocation; @Mixin(AtlasTexture.class) public abstract class AtlasDataMixin { diff --git a/src/main/java/com/jozufozu/flywheel/mixin/atlas/SheetDataAccessor.java b/src/main/java/com/jozufozu/flywheel/mixin/atlas/SheetDataAccessor.java index daa4fdd8e..d959b088f 100644 --- a/src/main/java/com/jozufozu/flywheel/mixin/atlas/SheetDataAccessor.java +++ b/src/main/java/com/jozufozu/flywheel/mixin/atlas/SheetDataAccessor.java @@ -1,10 +1,10 @@ package com.jozufozu.flywheel.mixin.atlas; -import net.minecraft.client.renderer.texture.AtlasTexture; - import org.spongepowered.asm.mixin.Mixin; import org.spongepowered.asm.mixin.gen.Accessor; +import net.minecraft.client.renderer.texture.AtlasTexture; + @Mixin(AtlasTexture.SheetData.class) public interface SheetDataAccessor { diff --git a/src/main/java/com/jozufozu/flywheel/mixin/light/LightUpdateMixin.java b/src/main/java/com/jozufozu/flywheel/mixin/light/LightUpdateMixin.java index 8168e7d46..2c5cddc0b 100644 --- a/src/main/java/com/jozufozu/flywheel/mixin/light/LightUpdateMixin.java +++ b/src/main/java/com/jozufozu/flywheel/mixin/light/LightUpdateMixin.java @@ -9,8 +9,6 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; import com.jozufozu.flywheel.backend.instancing.InstanceManager; import com.jozufozu.flywheel.backend.instancing.InstancedRenderDispatcher; -import com.jozufozu.flywheel.backend.instancing.entity.EntityInstanceManager; -import com.jozufozu.flywheel.backend.instancing.tile.TileInstanceManager; import com.jozufozu.flywheel.light.LightUpdater; import com.jozufozu.flywheel.util.ChunkUtil; diff --git a/src/main/java/com/jozufozu/flywheel/util/transform/QuaternionTransformStack.java b/src/main/java/com/jozufozu/flywheel/util/transform/QuaternionTransformStack.java index 7e4fb84b0..364371b72 100644 --- a/src/main/java/com/jozufozu/flywheel/util/transform/QuaternionTransformStack.java +++ b/src/main/java/com/jozufozu/flywheel/util/transform/QuaternionTransformStack.java @@ -1,16 +1,9 @@ package com.jozufozu.flywheel.util.transform; -import com.google.common.collect.Lists; +import java.util.ArrayDeque; +import java.util.Deque; import net.minecraft.util.math.vector.Quaternion; -import net.minecraft.util.math.vector.Vector3d; -import net.minecraft.util.math.vector.Vector3f; - -import java.util.ArrayDeque; -import java.util.ArrayList; -import java.util.Deque; -import java.util.Stack; -import java.util.Vector; public class QuaternionTransformStack implements TransformStack { diff --git a/src/main/java/com/jozufozu/flywheel/util/vec/Vec4.java b/src/main/java/com/jozufozu/flywheel/util/vec/Vec4.java index 668751fa9..3b2dbd185 100644 --- a/src/main/java/com/jozufozu/flywheel/util/vec/Vec4.java +++ b/src/main/java/com/jozufozu/flywheel/util/vec/Vec4.java @@ -1,7 +1,6 @@ package com.jozufozu.flywheel.util.vec; import net.minecraft.util.math.vector.Quaternion; -import net.minecraft.util.math.vector.Vector3f; public class Vec4 { diff --git a/src/main/java/com/jozufozu/flywheel/vanilla/BellInstance.java b/src/main/java/com/jozufozu/flywheel/vanilla/BellInstance.java index 6380e49e2..3502222b3 100644 --- a/src/main/java/com/jozufozu/flywheel/vanilla/BellInstance.java +++ b/src/main/java/com/jozufozu/flywheel/vanilla/BellInstance.java @@ -2,23 +2,16 @@ package com.jozufozu.flywheel.vanilla; import com.jozufozu.flywheel.backend.instancing.IDynamicInstance; import com.jozufozu.flywheel.backend.instancing.MaterialManager; -import com.jozufozu.flywheel.backend.instancing.MaterialSpec; import com.jozufozu.flywheel.backend.instancing.tile.TileEntityInstance; - import com.jozufozu.flywheel.backend.model.BufferedModel; import com.jozufozu.flywheel.core.Materials; import com.jozufozu.flywheel.core.materials.OrientedData; - import com.jozufozu.flywheel.core.model.ModelPart; -import com.jozufozu.flywheel.core.model.PartBuilder; - import com.jozufozu.flywheel.util.AnimationTickHolder; import net.minecraft.client.renderer.tileentity.BellTileEntityRenderer; import net.minecraft.tileentity.BellTileEntity; -import net.minecraft.util.Direction; import net.minecraft.util.math.MathHelper; -import net.minecraft.util.math.vector.Quaternion; import net.minecraft.util.math.vector.Vector3f; public class BellInstance extends TileEntityInstance implements IDynamicInstance { diff --git a/src/main/java/com/jozufozu/flywheel/vanilla/ChestInstance.java b/src/main/java/com/jozufozu/flywheel/vanilla/ChestInstance.java index f8108ebdc..14d4e57bd 100644 --- a/src/main/java/com/jozufozu/flywheel/vanilla/ChestInstance.java +++ b/src/main/java/com/jozufozu/flywheel/vanilla/ChestInstance.java @@ -1,21 +1,19 @@ package com.jozufozu.flywheel.vanilla; +import java.util.Calendar; + +import javax.annotation.Nonnull; + import com.jozufozu.flywheel.backend.instancing.IDynamicInstance; import com.jozufozu.flywheel.backend.instancing.MaterialManager; import com.jozufozu.flywheel.backend.instancing.tile.TileEntityInstance; - import com.jozufozu.flywheel.backend.model.BufferedModel; import com.jozufozu.flywheel.core.Materials; import com.jozufozu.flywheel.core.materials.ModelData; import com.jozufozu.flywheel.core.materials.OrientedData; - import com.jozufozu.flywheel.core.model.ModelPart; import com.jozufozu.flywheel.util.AnimationTickHolder; - import com.jozufozu.flywheel.util.transform.MatrixTransformStack; -import com.jozufozu.flywheel.util.vec.Vec3; -import com.jozufozu.flywheel.util.vec.Vec4; -import com.mojang.blaze3d.matrix.MatrixStack; import it.unimi.dsi.fastutil.floats.Float2FloatFunction; import net.minecraft.block.AbstractChestBlock; @@ -29,13 +27,7 @@ import net.minecraft.tileentity.IChestLid; import net.minecraft.tileentity.TileEntity; import net.minecraft.tileentity.TileEntityMerger; import net.minecraft.util.math.vector.Quaternion; -import net.minecraft.util.math.vector.Vector3d; import net.minecraft.util.math.vector.Vector3f; -import net.minecraft.util.math.vector.Vector4f; - -import javax.annotation.Nonnull; - -import java.util.Calendar; public class ChestInstance extends TileEntityInstance implements IDynamicInstance {