From 530f280842a3d58492b7d175d4f41459e70ee6d3 Mon Sep 17 00:00:00 2001 From: TopchetoEU <36534413+TopchetoEU@users.noreply.github.com> Date: Wed, 21 Sep 2022 19:32:17 +0300 Subject: [PATCH] chore: Replace smooth chunks with animated chunks --- build.gradle | 2 +- gradle.properties | 2 +- .../AnimatedChunks.java} | 38 +++++++++--------- .../ConfigManager.java | 6 +-- .../Descriptor.java | 2 +- .../Manager.java | 2 +- .../animation/Animation.java | 2 +- .../animation/FallAnimation.java | 2 +- .../animation/FlyInAnimation.java | 2 +- .../animation/ProgressManager.java | 2 +- .../animation/RiseAnimation.java | 2 +- .../animation/ScaleAnimation.java | 2 +- .../easing/Ease.java | 2 +- .../easing/ElasticEase.java | 2 +- .../easing/LinearEase.java | 2 +- .../easing/QuadraticEase.java | 2 +- .../easing/SineEase.java | 2 +- .../gui/AnimatedChunksScreen.java} | 18 ++++----- .../gui/Boundbox.java | 2 +- .../gui/BoundboxProvider.java | 2 +- .../gui/Button.java | 2 +- .../gui/ChunkPreview.java | 10 ++--- .../gui/HorizontalSection.java | 2 +- .../gui/Label.java | 2 +- .../gui/Section.java | 2 +- .../gui/SelectionScreen.java | 6 +-- .../gui/VerticalSection.java | 2 +- .../mixin/BuiltChunkMixin.java | 6 +-- .../mixin/WorldRendererMixin.java | 12 +++--- ...swidener => animated-chunks.accesswidener} | 0 ...ixins.json => animated-chunks.mixins.json} | 2 +- .../icon.png | Bin src/main/resources/fabric.mod.json | 16 ++++---- 33 files changed, 79 insertions(+), 79 deletions(-) rename src/main/java/me/topchetoeu/{smoothchunks/SmoothChunks.java => animatedchunks/AnimatedChunks.java} (79%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/ConfigManager.java (92%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/Descriptor.java (95%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/Manager.java (95%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/animation/Animation.java (92%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/animation/FallAnimation.java (90%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/animation/FlyInAnimation.java (90%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/animation/ProgressManager.java (96%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/animation/RiseAnimation.java (90%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/animation/ScaleAnimation.java (92%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/easing/Ease.java (93%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/easing/ElasticEase.java (89%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/easing/LinearEase.java (66%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/easing/QuadraticEase.java (69%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/easing/SineEase.java (73%) rename src/main/java/me/topchetoeu/{smoothchunks/gui/SmoothChunksScreen.java => animatedchunks/gui/AnimatedChunksScreen.java} (86%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/Boundbox.java (92%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/BoundboxProvider.java (74%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/Button.java (95%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/ChunkPreview.java (93%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/HorizontalSection.java (98%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/Label.java (94%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/Section.java (99%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/SelectionScreen.java (97%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/gui/VerticalSection.java (98%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/mixin/BuiltChunkMixin.java (75%) rename src/main/java/me/topchetoeu/{smoothchunks => animatedchunks}/mixin/WorldRendererMixin.java (89%) rename src/main/resources/{smooth-chunks.accesswidener => animated-chunks.accesswidener} (100%) rename src/main/resources/{smooth-chunks.mixins.json => animated-chunks.mixins.json} (81%) rename src/main/resources/assets/{smooth-chunks => animated-chunks}/icon.png (100%) diff --git a/build.gradle b/build.gradle index 3ee691b..513b60c 100644 --- a/build.gradle +++ b/build.gradle @@ -96,5 +96,5 @@ publishing { } } loom { - accessWidenerPath = file("src/main/resources/smooth-chunks.accesswidener") + accessWidenerPath = file("src/main/resources/animated-chunks.accesswidener") } diff --git a/gradle.properties b/gradle.properties index 069b53f..2ee8c84 100644 --- a/gradle.properties +++ b/gradle.properties @@ -10,7 +10,7 @@ loader_version=0.13.3 # Mod Properties mod_version=0.2.0 maven_group=me.topchetoeu -archives_base_name=smooth-chunks +archives_base_name=animated-chunks # Dependencies fabric_version=0.47.8+1.18.2 diff --git a/src/main/java/me/topchetoeu/smoothchunks/SmoothChunks.java b/src/main/java/me/topchetoeu/animatedchunks/AnimatedChunks.java similarity index 79% rename from src/main/java/me/topchetoeu/smoothchunks/SmoothChunks.java rename to src/main/java/me/topchetoeu/animatedchunks/AnimatedChunks.java index 9bcd06a..ab7d9a9 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/SmoothChunks.java +++ b/src/main/java/me/topchetoeu/animatedchunks/AnimatedChunks.java @@ -1,32 +1,32 @@ -package me.topchetoeu.smoothchunks; +package me.topchetoeu.animatedchunks; import java.io.File; import com.terraformersmc.modmenu.api.ConfigScreenFactory; import com.terraformersmc.modmenu.api.ModMenuApi; -import me.topchetoeu.smoothchunks.Manager.RegisterEvent; -import me.topchetoeu.smoothchunks.animation.Animation; -import me.topchetoeu.smoothchunks.animation.FallAnimation; -import me.topchetoeu.smoothchunks.animation.FlyInAnimation; -import me.topchetoeu.smoothchunks.animation.ProgressManager; -import me.topchetoeu.smoothchunks.animation.RiseAnimation; -import me.topchetoeu.smoothchunks.animation.ScaleAnimation; -import me.topchetoeu.smoothchunks.easing.Ease; -import me.topchetoeu.smoothchunks.easing.ElasticEase; -import me.topchetoeu.smoothchunks.easing.LinearEase; -import me.topchetoeu.smoothchunks.easing.SineEase; -import me.topchetoeu.smoothchunks.gui.SmoothChunksScreen; -import me.topchetoeu.smoothchunks.easing.QuadraticEase; +import me.topchetoeu.animatedchunks.Manager.RegisterEvent; +import me.topchetoeu.animatedchunks.animation.Animation; +import me.topchetoeu.animatedchunks.animation.FallAnimation; +import me.topchetoeu.animatedchunks.animation.FlyInAnimation; +import me.topchetoeu.animatedchunks.animation.ProgressManager; +import me.topchetoeu.animatedchunks.animation.RiseAnimation; +import me.topchetoeu.animatedchunks.animation.ScaleAnimation; +import me.topchetoeu.animatedchunks.easing.Ease; +import me.topchetoeu.animatedchunks.easing.ElasticEase; +import me.topchetoeu.animatedchunks.easing.LinearEase; +import me.topchetoeu.animatedchunks.easing.QuadraticEase; +import me.topchetoeu.animatedchunks.easing.SineEase; +import me.topchetoeu.animatedchunks.gui.AnimatedChunksScreen; import net.fabricmc.api.ClientModInitializer; import net.fabricmc.fabric.api.client.event.lifecycle.v1.ClientChunkEvents; import net.fabricmc.fabric.api.event.Event; import net.minecraft.client.gui.screen.Screen; import net.minecraft.util.math.BlockPos; -public final class SmoothChunks implements ClientModInitializer, ModMenuApi { - private static SmoothChunks instance; - public static SmoothChunks getInstance() { +public final class AnimatedChunks implements ClientModInitializer, ModMenuApi { + private static AnimatedChunks instance; + public static AnimatedChunks getInstance() { return instance; } @@ -134,7 +134,7 @@ public final class SmoothChunks implements ClientModInitializer, ModMenuApi { registerEases(ease); registerAnimations(animation); - config = new ConfigManager(new File("config/smooth-chunks.dat"), animation, ease); + config = new ConfigManager(new File("config/animated-chunks.dat"), animation, ease); EASES_REGISTERING.invoker().register(ease); ANIMATIONS_REGISTERING.invoker().register(animation); @@ -148,7 +148,7 @@ public final class SmoothChunks implements ClientModInitializer, ModMenuApi { public ConfigScreenFactory getModConfigScreenFactory() { return (Screen parent) -> { var _this = getInstance(); - return new SmoothChunksScreen(parent, _this.animation, _this.ease, _this.config); + return new AnimatedChunksScreen(parent, _this.animation, _this.ease, _this.config); }; } } diff --git a/src/main/java/me/topchetoeu/smoothchunks/ConfigManager.java b/src/main/java/me/topchetoeu/animatedchunks/ConfigManager.java similarity index 92% rename from src/main/java/me/topchetoeu/smoothchunks/ConfigManager.java rename to src/main/java/me/topchetoeu/animatedchunks/ConfigManager.java index 4e7e880..a9bbfe0 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/ConfigManager.java +++ b/src/main/java/me/topchetoeu/animatedchunks/ConfigManager.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks; +package me.topchetoeu.animatedchunks; import java.io.File; import java.io.FileNotFoundException; @@ -8,8 +8,8 @@ import java.io.IOException; import java.io.InputStreamReader; import java.io.OutputStreamWriter; -import me.topchetoeu.smoothchunks.animation.Animation; -import me.topchetoeu.smoothchunks.easing.Ease; +import me.topchetoeu.animatedchunks.animation.Animation; +import me.topchetoeu.animatedchunks.easing.Ease; public class ConfigManager { public final File configFile; diff --git a/src/main/java/me/topchetoeu/smoothchunks/Descriptor.java b/src/main/java/me/topchetoeu/animatedchunks/Descriptor.java similarity index 95% rename from src/main/java/me/topchetoeu/smoothchunks/Descriptor.java rename to src/main/java/me/topchetoeu/animatedchunks/Descriptor.java index 8e147ea..25f5696 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/Descriptor.java +++ b/src/main/java/me/topchetoeu/animatedchunks/Descriptor.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks; +package me.topchetoeu.animatedchunks; import org.apache.commons.lang3.Validate; diff --git a/src/main/java/me/topchetoeu/smoothchunks/Manager.java b/src/main/java/me/topchetoeu/animatedchunks/Manager.java similarity index 95% rename from src/main/java/me/topchetoeu/smoothchunks/Manager.java rename to src/main/java/me/topchetoeu/animatedchunks/Manager.java index d6327ac..ac172ac 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/Manager.java +++ b/src/main/java/me/topchetoeu/animatedchunks/Manager.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks; +package me.topchetoeu.animatedchunks; import java.util.Collection; import java.util.Collections; diff --git a/src/main/java/me/topchetoeu/smoothchunks/animation/Animation.java b/src/main/java/me/topchetoeu/animatedchunks/animation/Animation.java similarity index 92% rename from src/main/java/me/topchetoeu/smoothchunks/animation/Animation.java rename to src/main/java/me/topchetoeu/animatedchunks/animation/Animation.java index f872fca..adf5fcf 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/animation/Animation.java +++ b/src/main/java/me/topchetoeu/animatedchunks/animation/Animation.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.animation; +package me.topchetoeu.animatedchunks.animation; import net.minecraft.client.util.math.MatrixStack; diff --git a/src/main/java/me/topchetoeu/smoothchunks/animation/FallAnimation.java b/src/main/java/me/topchetoeu/animatedchunks/animation/FallAnimation.java similarity index 90% rename from src/main/java/me/topchetoeu/smoothchunks/animation/FallAnimation.java rename to src/main/java/me/topchetoeu/animatedchunks/animation/FallAnimation.java index 0214755..2107e6f 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/animation/FallAnimation.java +++ b/src/main/java/me/topchetoeu/animatedchunks/animation/FallAnimation.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.animation; +package me.topchetoeu.animatedchunks.animation; import net.minecraft.client.util.math.MatrixStack; diff --git a/src/main/java/me/topchetoeu/smoothchunks/animation/FlyInAnimation.java b/src/main/java/me/topchetoeu/animatedchunks/animation/FlyInAnimation.java similarity index 90% rename from src/main/java/me/topchetoeu/smoothchunks/animation/FlyInAnimation.java rename to src/main/java/me/topchetoeu/animatedchunks/animation/FlyInAnimation.java index 4ffa5ff..c907fb7 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/animation/FlyInAnimation.java +++ b/src/main/java/me/topchetoeu/animatedchunks/animation/FlyInAnimation.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.animation; +package me.topchetoeu.animatedchunks.animation; import net.minecraft.client.util.math.MatrixStack; import net.minecraft.util.math.Vec2f; diff --git a/src/main/java/me/topchetoeu/smoothchunks/animation/ProgressManager.java b/src/main/java/me/topchetoeu/animatedchunks/animation/ProgressManager.java similarity index 96% rename from src/main/java/me/topchetoeu/smoothchunks/animation/ProgressManager.java rename to src/main/java/me/topchetoeu/animatedchunks/animation/ProgressManager.java index fd1bc2d..bb39db9 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/animation/ProgressManager.java +++ b/src/main/java/me/topchetoeu/animatedchunks/animation/ProgressManager.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.animation; +package me.topchetoeu.animatedchunks.animation; import java.util.ArrayList; import java.util.HashSet; diff --git a/src/main/java/me/topchetoeu/smoothchunks/animation/RiseAnimation.java b/src/main/java/me/topchetoeu/animatedchunks/animation/RiseAnimation.java similarity index 90% rename from src/main/java/me/topchetoeu/smoothchunks/animation/RiseAnimation.java rename to src/main/java/me/topchetoeu/animatedchunks/animation/RiseAnimation.java index 15185c9..0763bac 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/animation/RiseAnimation.java +++ b/src/main/java/me/topchetoeu/animatedchunks/animation/RiseAnimation.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.animation; +package me.topchetoeu.animatedchunks.animation; import net.minecraft.client.util.math.MatrixStack; diff --git a/src/main/java/me/topchetoeu/smoothchunks/animation/ScaleAnimation.java b/src/main/java/me/topchetoeu/animatedchunks/animation/ScaleAnimation.java similarity index 92% rename from src/main/java/me/topchetoeu/smoothchunks/animation/ScaleAnimation.java rename to src/main/java/me/topchetoeu/animatedchunks/animation/ScaleAnimation.java index a5bd353..a513414 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/animation/ScaleAnimation.java +++ b/src/main/java/me/topchetoeu/animatedchunks/animation/ScaleAnimation.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.animation; +package me.topchetoeu.animatedchunks.animation; import net.minecraft.client.util.math.MatrixStack; diff --git a/src/main/java/me/topchetoeu/smoothchunks/easing/Ease.java b/src/main/java/me/topchetoeu/animatedchunks/easing/Ease.java similarity index 93% rename from src/main/java/me/topchetoeu/smoothchunks/easing/Ease.java rename to src/main/java/me/topchetoeu/animatedchunks/easing/Ease.java index 4948b59..3f092c7 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/easing/Ease.java +++ b/src/main/java/me/topchetoeu/animatedchunks/easing/Ease.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.easing; +package me.topchetoeu.animatedchunks.easing; public interface Ease { /** diff --git a/src/main/java/me/topchetoeu/smoothchunks/easing/ElasticEase.java b/src/main/java/me/topchetoeu/animatedchunks/easing/ElasticEase.java similarity index 89% rename from src/main/java/me/topchetoeu/smoothchunks/easing/ElasticEase.java rename to src/main/java/me/topchetoeu/animatedchunks/easing/ElasticEase.java index 7c0ab25..32d5d8b 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/easing/ElasticEase.java +++ b/src/main/java/me/topchetoeu/animatedchunks/easing/ElasticEase.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.easing; +package me.topchetoeu.animatedchunks.easing; public class ElasticEase implements Ease { private float steepness = 1; diff --git a/src/main/java/me/topchetoeu/smoothchunks/easing/LinearEase.java b/src/main/java/me/topchetoeu/animatedchunks/easing/LinearEase.java similarity index 66% rename from src/main/java/me/topchetoeu/smoothchunks/easing/LinearEase.java rename to src/main/java/me/topchetoeu/animatedchunks/easing/LinearEase.java index 293f4c7..ab3904d 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/easing/LinearEase.java +++ b/src/main/java/me/topchetoeu/animatedchunks/easing/LinearEase.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.easing; +package me.topchetoeu.animatedchunks.easing; public class LinearEase implements Ease { public float ease(float x) { diff --git a/src/main/java/me/topchetoeu/smoothchunks/easing/QuadraticEase.java b/src/main/java/me/topchetoeu/animatedchunks/easing/QuadraticEase.java similarity index 69% rename from src/main/java/me/topchetoeu/smoothchunks/easing/QuadraticEase.java rename to src/main/java/me/topchetoeu/animatedchunks/easing/QuadraticEase.java index 2fe5839..3969ac4 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/easing/QuadraticEase.java +++ b/src/main/java/me/topchetoeu/animatedchunks/easing/QuadraticEase.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.easing; +package me.topchetoeu.animatedchunks.easing; public class QuadraticEase implements Ease { @Override diff --git a/src/main/java/me/topchetoeu/smoothchunks/easing/SineEase.java b/src/main/java/me/topchetoeu/animatedchunks/easing/SineEase.java similarity index 73% rename from src/main/java/me/topchetoeu/smoothchunks/easing/SineEase.java rename to src/main/java/me/topchetoeu/animatedchunks/easing/SineEase.java index f37acbd..3a9ad04 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/easing/SineEase.java +++ b/src/main/java/me/topchetoeu/animatedchunks/easing/SineEase.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.easing; +package me.topchetoeu.animatedchunks.easing; public class SineEase implements Ease { @Override diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/SmoothChunksScreen.java b/src/main/java/me/topchetoeu/animatedchunks/gui/AnimatedChunksScreen.java similarity index 86% rename from src/main/java/me/topchetoeu/smoothchunks/gui/SmoothChunksScreen.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/AnimatedChunksScreen.java index e389dd8..4048a3c 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/SmoothChunksScreen.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/AnimatedChunksScreen.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; import net.minecraft.client.gui.screen.Screen; import net.minecraft.client.sound.PositionedSoundInstance; @@ -8,14 +8,14 @@ import net.minecraft.text.LiteralText; import net.minecraft.text.Text; import net.minecraft.util.Formatting; import net.minecraft.util.math.ColorHelper.Argb; -import me.topchetoeu.smoothchunks.ConfigManager; -import me.topchetoeu.smoothchunks.Manager; -import me.topchetoeu.smoothchunks.animation.Animation; -import me.topchetoeu.smoothchunks.easing.Ease; -import me.topchetoeu.smoothchunks.gui.Section.OrderType; +import me.topchetoeu.animatedchunks.ConfigManager; +import me.topchetoeu.animatedchunks.Manager; +import me.topchetoeu.animatedchunks.animation.Animation; +import me.topchetoeu.animatedchunks.easing.Ease; +import me.topchetoeu.animatedchunks.gui.Section.OrderType; import net.minecraft.client.MinecraftClient; -public class SmoothChunksScreen extends Screen { +public class AnimatedChunksScreen extends Screen { public final Screen parent; private final HorizontalSection mainSection = new HorizontalSection(); private final Manager animation; @@ -105,8 +105,8 @@ public class SmoothChunksScreen extends Screen { res.children.addSelectableChild(selectionSection(ease, "Ease")); return res; } - public SmoothChunksScreen(Screen parent, Manager animation, Manager ease, ConfigManager config) { - super(Text.of("Smooth Chunks Config")); + public AnimatedChunksScreen(Screen parent, Manager animation, Manager ease, ConfigManager config) { + super(Text.of("Animated Chunks Config")); config.reload(); this.animation = animation; this.ease = ease; diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/Boundbox.java b/src/main/java/me/topchetoeu/animatedchunks/gui/Boundbox.java similarity index 92% rename from src/main/java/me/topchetoeu/smoothchunks/gui/Boundbox.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/Boundbox.java index 0b8f393..d096096 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/Boundbox.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/Boundbox.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; public class Boundbox implements BoundboxProvider { public float x, y, width, height; diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/BoundboxProvider.java b/src/main/java/me/topchetoeu/animatedchunks/gui/BoundboxProvider.java similarity index 74% rename from src/main/java/me/topchetoeu/smoothchunks/gui/BoundboxProvider.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/BoundboxProvider.java index a824afe..45f35e0 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/BoundboxProvider.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/BoundboxProvider.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; public interface BoundboxProvider { float getX(); diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/Button.java b/src/main/java/me/topchetoeu/animatedchunks/gui/Button.java similarity index 95% rename from src/main/java/me/topchetoeu/smoothchunks/gui/Button.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/Button.java index ff857a2..69a33f6 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/Button.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/Button.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; import org.apache.commons.lang3.Validate; import org.lwjgl.glfw.GLFW; diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/ChunkPreview.java b/src/main/java/me/topchetoeu/animatedchunks/gui/ChunkPreview.java similarity index 93% rename from src/main/java/me/topchetoeu/smoothchunks/gui/ChunkPreview.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/ChunkPreview.java index cf21da4..486c8b1 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/ChunkPreview.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/ChunkPreview.java @@ -1,11 +1,11 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; import org.lwjgl.glfw.GLFW; import org.lwjgl.opengl.GL11; import com.mojang.blaze3d.systems.RenderSystem; -import me.topchetoeu.smoothchunks.SmoothChunks; +import me.topchetoeu.animatedchunks.AnimatedChunks; import net.minecraft.client.MinecraftClient; import net.minecraft.client.gui.Drawable; import net.minecraft.client.gui.DrawableHelper; @@ -170,8 +170,8 @@ public class ChunkPreview extends DrawableHelper implements Drawable, Element, S if (progress < 0) progress = 0; if (progress > 1) progress = 1; if (progress < 0.999) { - float _progress = SmoothChunks.getInstance().getEaseManager().getValue().ease(progress); - SmoothChunks.getInstance().getAnimationManager().getValue().animate( + float _progress = AnimatedChunks.getInstance().getEaseManager().getValue().ease(progress); + AnimatedChunks.getInstance().getAnimationManager().getValue().animate( _progress, matrices, x * 16, 0, y * 16, 0, 0, 0 ); @@ -187,7 +187,7 @@ public class ChunkPreview extends DrawableHelper implements Drawable, Element, S matrices.pop(); } private void renderChunks(MatrixStack matrices, float delta, int n) { - duration = SmoothChunks.getInstance().getProgressManager().getDuration(); + duration = AnimatedChunks.getInstance().getProgressManager().getDuration(); // globalProgress += (lastTime - (lastTime = System.nanoTime())) / -1000000000f; globalProgress += delta * 0.05f; matrices.push(); diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/HorizontalSection.java b/src/main/java/me/topchetoeu/animatedchunks/gui/HorizontalSection.java similarity index 98% rename from src/main/java/me/topchetoeu/smoothchunks/gui/HorizontalSection.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/HorizontalSection.java index 99d37e5..d4af6ad 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/HorizontalSection.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/HorizontalSection.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; import java.util.ArrayList; import java.util.Hashtable; diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/Label.java b/src/main/java/me/topchetoeu/animatedchunks/gui/Label.java similarity index 94% rename from src/main/java/me/topchetoeu/smoothchunks/gui/Label.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/Label.java index d346390..36b8c10 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/Label.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/Label.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; import org.apache.commons.lang3.Validate; diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/Section.java b/src/main/java/me/topchetoeu/animatedchunks/gui/Section.java similarity index 99% rename from src/main/java/me/topchetoeu/smoothchunks/gui/Section.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/Section.java index 87339a3..a9752a4 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/Section.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/Section.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; import java.util.ArrayList; import java.util.Collections; diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/SelectionScreen.java b/src/main/java/me/topchetoeu/animatedchunks/gui/SelectionScreen.java similarity index 97% rename from src/main/java/me/topchetoeu/smoothchunks/gui/SelectionScreen.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/SelectionScreen.java index dbec8ab..f0ee863 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/SelectionScreen.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/SelectionScreen.java @@ -1,10 +1,10 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; import java.util.LinkedHashMap; import java.util.Map; -import me.topchetoeu.smoothchunks.Descriptor; -import me.topchetoeu.smoothchunks.Manager; +import me.topchetoeu.animatedchunks.Descriptor; +import me.topchetoeu.animatedchunks.Manager; import net.minecraft.client.MinecraftClient; import net.minecraft.client.font.TextRenderer; import net.minecraft.client.gui.screen.Screen; diff --git a/src/main/java/me/topchetoeu/smoothchunks/gui/VerticalSection.java b/src/main/java/me/topchetoeu/animatedchunks/gui/VerticalSection.java similarity index 98% rename from src/main/java/me/topchetoeu/smoothchunks/gui/VerticalSection.java rename to src/main/java/me/topchetoeu/animatedchunks/gui/VerticalSection.java index 6c60c93..b338f85 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/gui/VerticalSection.java +++ b/src/main/java/me/topchetoeu/animatedchunks/gui/VerticalSection.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.gui; +package me.topchetoeu.animatedchunks.gui; import java.util.ArrayList; import java.util.Hashtable; diff --git a/src/main/java/me/topchetoeu/smoothchunks/mixin/BuiltChunkMixin.java b/src/main/java/me/topchetoeu/animatedchunks/mixin/BuiltChunkMixin.java similarity index 75% rename from src/main/java/me/topchetoeu/smoothchunks/mixin/BuiltChunkMixin.java rename to src/main/java/me/topchetoeu/animatedchunks/mixin/BuiltChunkMixin.java index 21b8349..8961917 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/mixin/BuiltChunkMixin.java +++ b/src/main/java/me/topchetoeu/animatedchunks/mixin/BuiltChunkMixin.java @@ -1,11 +1,11 @@ -package me.topchetoeu.smoothchunks.mixin; +package me.topchetoeu.animatedchunks.mixin; 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.CallbackInfo; -import me.topchetoeu.smoothchunks.SmoothChunks; +import me.topchetoeu.animatedchunks.AnimatedChunks; import net.minecraft.client.render.chunk.ChunkBuilder; import net.minecraft.util.math.BlockPos; @@ -17,6 +17,6 @@ abstract class BuiltChunkMixin { // ci.cancel(); // return; BlockPos origin = ((ChunkBuilder.BuiltChunk)(Object)this).getOrigin(); - SmoothChunks.getInstance().getProgressManager().unload(origin.getX(), 0, origin.getZ()); + AnimatedChunks.getInstance().getProgressManager().unload(origin.getX(), 0, origin.getZ()); } } \ No newline at end of file diff --git a/src/main/java/me/topchetoeu/smoothchunks/mixin/WorldRendererMixin.java b/src/main/java/me/topchetoeu/animatedchunks/mixin/WorldRendererMixin.java similarity index 89% rename from src/main/java/me/topchetoeu/smoothchunks/mixin/WorldRendererMixin.java rename to src/main/java/me/topchetoeu/animatedchunks/mixin/WorldRendererMixin.java index ea50187..297d818 100644 --- a/src/main/java/me/topchetoeu/smoothchunks/mixin/WorldRendererMixin.java +++ b/src/main/java/me/topchetoeu/animatedchunks/mixin/WorldRendererMixin.java @@ -1,4 +1,4 @@ -package me.topchetoeu.smoothchunks.mixin; +package me.topchetoeu.animatedchunks.mixin; import net.minecraft.client.gl.GlUniform; import net.minecraft.client.render.BuiltChunkStorage; @@ -21,8 +21,8 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo; import org.spongepowered.asm.mixin.injection.callback.LocalCapture; import it.unimi.dsi.fastutil.objects.ObjectListIterator; -import me.topchetoeu.smoothchunks.SmoothChunks; -import me.topchetoeu.smoothchunks.animation.ProgressManager; +import me.topchetoeu.animatedchunks.AnimatedChunks; +import me.topchetoeu.animatedchunks.animation.ProgressManager; @Mixin(WorldRenderer.class) abstract class WorldRendererMixin { @@ -31,7 +31,7 @@ abstract class WorldRendererMixin { @Accessor abstract BuiltChunkStorage getChunks(); private ProgressManager getProgressManager() { - return SmoothChunks.getInstance().getProgressManager(); + return AnimatedChunks.getInstance().getProgressManager(); } @Inject(method = "render", at = @At(value = "HEAD")) @@ -69,14 +69,14 @@ abstract class WorldRendererMixin { float progress = getProgressManager().getChunkProgress(x, 0, z); if (progress < 0.999) { - progress = SmoothChunks.getInstance().getEaseManager().getValue().ease(progress); + progress = AnimatedChunks.getInstance().getEaseManager().getValue().ease(progress); float centerX = (float)playerX - x; float centerY = (float)playerY - y; float centerZ = (float)playerZ - z; matrices.translate(-centerX, -centerY, -centerZ); - SmoothChunks.getInstance().getAnimationManager().getValue().animate(progress, matrices, x, y, z, (float)playerX, (float)playerY, (float)playerZ); + AnimatedChunks.getInstance().getAnimationManager().getValue().animate(progress, matrices, x, y, z, (float)playerX, (float)playerY, (float)playerZ); matrices.translate(centerX, centerY, centerZ); } } diff --git a/src/main/resources/smooth-chunks.accesswidener b/src/main/resources/animated-chunks.accesswidener similarity index 100% rename from src/main/resources/smooth-chunks.accesswidener rename to src/main/resources/animated-chunks.accesswidener diff --git a/src/main/resources/smooth-chunks.mixins.json b/src/main/resources/animated-chunks.mixins.json similarity index 81% rename from src/main/resources/smooth-chunks.mixins.json rename to src/main/resources/animated-chunks.mixins.json index d7e0296..2d42622 100644 --- a/src/main/resources/smooth-chunks.mixins.json +++ b/src/main/resources/animated-chunks.mixins.json @@ -1,7 +1,7 @@ { "required": true, "minVersion": "0.8", - "package": "me.topchetoeu.smoothchunks.mixin", + "package": "me.topchetoeu.animatedchunks.mixin", "compatibilityLevel": "JAVA_17", "mixins": [], "client": [ diff --git a/src/main/resources/assets/smooth-chunks/icon.png b/src/main/resources/assets/animated-chunks/icon.png similarity index 100% rename from src/main/resources/assets/smooth-chunks/icon.png rename to src/main/resources/assets/animated-chunks/icon.png diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index e6154dd..a971f92 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -1,24 +1,24 @@ { "schemaVersion": 1, - "id": "smooth-chunks", + "id": "animated-chunks", "version": "0.2.0", - "name": "Smooth Chunks", - "description": "Smooth chunk load animations.", + "name": "Animated Chunks", + "description": "animated chunk load animations.", "authors": [ "TopchetoEU" ], "license": "MIT", - "icon": "assets/smooth-chunks/icon.png", + "icon": "assets/animated-chunks/icon.png", "environment": "client", - "accessWidener": "smooth-chunks.accesswidener", + "accessWidener": "animated-chunks.accesswidener", "entrypoints": { "client": [ - "me.topchetoeu.smoothchunks.SmoothChunks" + "me.topchetoeu.animatedchunks.AnimatedChunks" ], "modmenu": [ - "me.topchetoeu.smoothchunks.SmoothChunks" + "me.topchetoeu.animatedchunks.AnimatedChunks" ] }, "mixins": [ - "smooth-chunks.mixins.json" + "animated-chunks.mixins.json" ], "depends": { "fabricloader": ">=0.9.3+build.207",