diff --git a/.idea/artifacts/TerrarumBuild.xml b/.idea/artifacts/TerrarumBuild.xml
index c6f61dd0f..b1b085a26 100644
--- a/.idea/artifacts/TerrarumBuild.xml
+++ b/.idea/artifacts/TerrarumBuild.xml
@@ -6,49 +6,11 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -66,6 +28,61 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/badlogicgames_gdx.xml b/.idea/libraries/badlogicgames_gdx.xml
new file mode 100644
index 000000000..ce2942db8
--- /dev/null
+++ b/.idea/libraries/badlogicgames_gdx.xml
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/badlogicgames_gdx_backend_lwjgl3.xml b/.idea/libraries/badlogicgames_gdx_backend_lwjgl3.xml
new file mode 100644
index 000000000..4a0b0fdd5
--- /dev/null
+++ b/.idea/libraries/badlogicgames_gdx_backend_lwjgl3.xml
@@ -0,0 +1,170 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/.idea/libraries/com_badlogicgames_gdx_gdx_1_10_0.xml b/.idea/libraries/com_badlogicgames_gdx_gdx_1_10_0.xml
deleted file mode 100644
index 7a8c6607d..000000000
--- a/.idea/libraries/com_badlogicgames_gdx_gdx_1_10_0.xml
+++ /dev/null
@@ -1,14 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/com_badlogicgames_gdx_gdx_backend_lwjgl3_1_10_0.xml b/.idea/libraries/com_badlogicgames_gdx_gdx_backend_lwjgl3_1_10_0.xml
deleted file mode 100644
index 520d8796b..000000000
--- a/.idea/libraries/com_badlogicgames_gdx_gdx_backend_lwjgl3_1_10_0.xml
+++ /dev/null
@@ -1,128 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/gdx_platform_1_10_0_natives_desktop.xml b/.idea/libraries/gdx_platform_1_10_0_natives_desktop.xml
deleted file mode 100644
index 9938aa858..000000000
--- a/.idea/libraries/gdx_platform_1_10_0_natives_desktop.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/libraries/gdx_platform_1_11_0_natives.xml b/.idea/libraries/gdx_platform_1_11_0_natives.xml
new file mode 100644
index 000000000..b253aba6d
--- /dev/null
+++ b/.idea/libraries/gdx_platform_1_11_0_natives.xml
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/ModuleComputers/ModuleComputers.iml b/ModuleComputers/ModuleComputers.iml
index d8119fd9c..7c20b41bc 100644
--- a/ModuleComputers/ModuleComputers.iml
+++ b/ModuleComputers/ModuleComputers.iml
@@ -9,10 +9,10 @@
-
-
+
+
\ No newline at end of file
diff --git a/TerrarumBuild.iml b/TerrarumBuild.iml
index b09d72d6b..9fcb8d490 100644
--- a/TerrarumBuild.iml
+++ b/TerrarumBuild.iml
@@ -8,8 +8,6 @@
-
-
@@ -19,8 +17,10 @@
-
+
+
+
\ No newline at end of file
diff --git a/lib/gdx-1.10.0-javadoc.jar b/lib/gdx-1.10.0-javadoc.jar
deleted file mode 100644
index e371794c3..000000000
Binary files a/lib/gdx-1.10.0-javadoc.jar and /dev/null differ
diff --git a/lib/gdx-1.10.0-sources.jar b/lib/gdx-1.10.0-sources.jar
deleted file mode 100644
index 90f2677ed..000000000
Binary files a/lib/gdx-1.10.0-sources.jar and /dev/null differ
diff --git a/lib/gdx-1.11.0-javadoc.jar b/lib/gdx-1.11.0-javadoc.jar
new file mode 100644
index 000000000..c8482fa7f
Binary files /dev/null and b/lib/gdx-1.11.0-javadoc.jar differ
diff --git a/lib/gdx-1.11.0-sources.jar b/lib/gdx-1.11.0-sources.jar
new file mode 100644
index 000000000..22d94b503
Binary files /dev/null and b/lib/gdx-1.11.0-sources.jar differ
diff --git a/lib/gdx-1.10.0.jar b/lib/gdx-1.11.0.jar
similarity index 54%
rename from lib/gdx-1.10.0.jar
rename to lib/gdx-1.11.0.jar
index d40d51795..1a0381b85 100644
Binary files a/lib/gdx-1.10.0.jar and b/lib/gdx-1.11.0.jar differ
diff --git a/lib/gdx-backend-lwjgl3-1.10.0-javadoc.jar b/lib/gdx-backend-lwjgl3-1.10.0-javadoc.jar
deleted file mode 100644
index 488eed8a8..000000000
Binary files a/lib/gdx-backend-lwjgl3-1.10.0-javadoc.jar and /dev/null differ
diff --git a/lib/gdx-backend-lwjgl3-1.10.0-sources.jar b/lib/gdx-backend-lwjgl3-1.10.0-sources.jar
deleted file mode 100644
index 412affa04..000000000
Binary files a/lib/gdx-backend-lwjgl3-1.10.0-sources.jar and /dev/null differ
diff --git a/lib/gdx-backend-lwjgl3-1.10.0.jar b/lib/gdx-backend-lwjgl3-1.10.0.jar
deleted file mode 100644
index 69bd2d769..000000000
Binary files a/lib/gdx-backend-lwjgl3-1.10.0.jar and /dev/null differ
diff --git a/lib/gdx-backend-lwjgl3-1.11.0-javadoc.jar b/lib/gdx-backend-lwjgl3-1.11.0-javadoc.jar
new file mode 100644
index 000000000..266008abd
Binary files /dev/null and b/lib/gdx-backend-lwjgl3-1.11.0-javadoc.jar differ
diff --git a/lib/gdx-backend-lwjgl3-1.11.0-sources.jar b/lib/gdx-backend-lwjgl3-1.11.0-sources.jar
new file mode 100644
index 000000000..d3e9d2596
Binary files /dev/null and b/lib/gdx-backend-lwjgl3-1.11.0-sources.jar differ
diff --git a/lib/gdx-backend-lwjgl3-1.11.0.jar b/lib/gdx-backend-lwjgl3-1.11.0.jar
new file mode 100644
index 000000000..66778d90d
Binary files /dev/null and b/lib/gdx-backend-lwjgl3-1.11.0.jar differ
diff --git a/lib/gdx-jnigen-loader-2.3.1-javadoc.jar b/lib/gdx-jnigen-loader-2.3.1-javadoc.jar
new file mode 100644
index 000000000..f06569e93
Binary files /dev/null and b/lib/gdx-jnigen-loader-2.3.1-javadoc.jar differ
diff --git a/lib/gdx-jnigen-loader-2.3.1-sources.jar b/lib/gdx-jnigen-loader-2.3.1-sources.jar
new file mode 100644
index 000000000..e1baeeb7e
Binary files /dev/null and b/lib/gdx-jnigen-loader-2.3.1-sources.jar differ
diff --git a/lib/gdx-jnigen-loader-2.3.1.jar b/lib/gdx-jnigen-loader-2.3.1.jar
new file mode 100644
index 000000000..e87826788
Binary files /dev/null and b/lib/gdx-jnigen-loader-2.3.1.jar differ
diff --git a/lib/gdx-platform-1.10.0-natives-desktop.jar b/lib/gdx-platform-1.10.0-natives-desktop.jar
deleted file mode 100644
index d5d8a907d..000000000
Binary files a/lib/gdx-platform-1.10.0-natives-desktop.jar and /dev/null differ
diff --git a/lib/gdx-platform-1.10.0.jar b/lib/gdx-platform-1.10.0.jar
deleted file mode 100644
index 761e6ac1d..000000000
Binary files a/lib/gdx-platform-1.10.0.jar and /dev/null differ
diff --git a/lib/gdx-platform-1.11.0-natives-arm64-v8a.jar b/lib/gdx-platform-1.11.0-natives-arm64-v8a.jar
new file mode 100644
index 000000000..5b4782484
Binary files /dev/null and b/lib/gdx-platform-1.11.0-natives-arm64-v8a.jar differ
diff --git a/lib/gdx-platform-1.11.0-natives-armeabi-v7a.jar b/lib/gdx-platform-1.11.0-natives-armeabi-v7a.jar
new file mode 100644
index 000000000..18f864e9d
Binary files /dev/null and b/lib/gdx-platform-1.11.0-natives-armeabi-v7a.jar differ
diff --git a/lib/gdx-platform-1.11.0-natives-desktop.jar b/lib/gdx-platform-1.11.0-natives-desktop.jar
new file mode 100644
index 000000000..10d0a113c
Binary files /dev/null and b/lib/gdx-platform-1.11.0-natives-desktop.jar differ
diff --git a/lib/gdx-platform-1.11.0-natives-x86_64.jar b/lib/gdx-platform-1.11.0-natives-x86_64.jar
new file mode 100644
index 000000000..17ec2031d
Binary files /dev/null and b/lib/gdx-platform-1.11.0-natives-x86_64.jar differ
diff --git a/lib/lwjgl-3.2.3-javadoc.jar b/lib/lwjgl-3.2.3-javadoc.jar
deleted file mode 100644
index 6751cba7c..000000000
Binary files a/lib/lwjgl-3.2.3-javadoc.jar and /dev/null differ
diff --git a/lib/lwjgl-3.2.3-natives-linux-arm32.jar b/lib/lwjgl-3.2.3-natives-linux-arm32.jar
deleted file mode 100644
index 25a176a18..000000000
Binary files a/lib/lwjgl-3.2.3-natives-linux-arm32.jar and /dev/null differ
diff --git a/lib/lwjgl-3.2.3-natives-linux-arm64.jar b/lib/lwjgl-3.2.3-natives-linux-arm64.jar
deleted file mode 100644
index c32df86e4..000000000
Binary files a/lib/lwjgl-3.2.3-natives-linux-arm64.jar and /dev/null differ
diff --git a/lib/lwjgl-3.2.3-natives-linux.jar b/lib/lwjgl-3.2.3-natives-linux.jar
deleted file mode 100644
index f6509cf5d..000000000
Binary files a/lib/lwjgl-3.2.3-natives-linux.jar and /dev/null differ
diff --git a/lib/lwjgl-3.2.3-natives-macos.jar b/lib/lwjgl-3.2.3-natives-macos.jar
deleted file mode 100644
index a7f9872ad..000000000
Binary files a/lib/lwjgl-3.2.3-natives-macos.jar and /dev/null differ
diff --git a/lib/lwjgl-3.2.3-natives-windows-x86.jar b/lib/lwjgl-3.2.3-natives-windows-x86.jar
deleted file mode 100644
index 82fbbd02c..000000000
Binary files a/lib/lwjgl-3.2.3-natives-windows-x86.jar and /dev/null differ
diff --git a/lib/lwjgl-3.2.3-natives-windows.jar b/lib/lwjgl-3.2.3-natives-windows.jar
deleted file mode 100644
index 78a762000..000000000
Binary files a/lib/lwjgl-3.2.3-natives-windows.jar and /dev/null differ
diff --git a/lib/lwjgl-3.2.3-sources.jar b/lib/lwjgl-3.2.3-sources.jar
deleted file mode 100644
index 1360c5096..000000000
Binary files a/lib/lwjgl-3.2.3-sources.jar and /dev/null differ
diff --git a/lib/lwjgl-3.2.3.jar b/lib/lwjgl-3.2.3.jar
deleted file mode 100644
index e2f71fbda..000000000
Binary files a/lib/lwjgl-3.2.3.jar and /dev/null differ
diff --git a/lib/lwjgl-3.3.1-javadoc.jar b/lib/lwjgl-3.3.1-javadoc.jar
new file mode 100644
index 000000000..abe70ffaf
Binary files /dev/null and b/lib/lwjgl-3.3.1-javadoc.jar differ
diff --git a/lib/lwjgl-3.3.1-natives-linux-arm32.jar b/lib/lwjgl-3.3.1-natives-linux-arm32.jar
new file mode 100644
index 000000000..2156f90c4
Binary files /dev/null and b/lib/lwjgl-3.3.1-natives-linux-arm32.jar differ
diff --git a/lib/lwjgl-3.3.1-natives-linux-arm64.jar b/lib/lwjgl-3.3.1-natives-linux-arm64.jar
new file mode 100644
index 000000000..28b2a23e2
Binary files /dev/null and b/lib/lwjgl-3.3.1-natives-linux-arm64.jar differ
diff --git a/lib/lwjgl-3.3.1-natives-linux.jar b/lib/lwjgl-3.3.1-natives-linux.jar
new file mode 100644
index 000000000..4bc45091c
Binary files /dev/null and b/lib/lwjgl-3.3.1-natives-linux.jar differ
diff --git a/lib/lwjgl-3.3.1-natives-macos-arm64.jar b/lib/lwjgl-3.3.1-natives-macos-arm64.jar
new file mode 100644
index 000000000..c529058ae
Binary files /dev/null and b/lib/lwjgl-3.3.1-natives-macos-arm64.jar differ
diff --git a/lib/lwjgl-3.3.1-natives-macos.jar b/lib/lwjgl-3.3.1-natives-macos.jar
new file mode 100644
index 000000000..aad7d1989
Binary files /dev/null and b/lib/lwjgl-3.3.1-natives-macos.jar differ
diff --git a/lib/lwjgl-3.3.1-natives-windows-x86.jar b/lib/lwjgl-3.3.1-natives-windows-x86.jar
new file mode 100644
index 000000000..29fa98bea
Binary files /dev/null and b/lib/lwjgl-3.3.1-natives-windows-x86.jar differ
diff --git a/lib/lwjgl-3.3.1-natives-windows.jar b/lib/lwjgl-3.3.1-natives-windows.jar
new file mode 100644
index 000000000..11b7d3539
Binary files /dev/null and b/lib/lwjgl-3.3.1-natives-windows.jar differ
diff --git a/lib/lwjgl-3.3.1-sources.jar b/lib/lwjgl-3.3.1-sources.jar
new file mode 100644
index 000000000..02a4bece5
Binary files /dev/null and b/lib/lwjgl-3.3.1-sources.jar differ
diff --git a/lib/lwjgl-3.3.1.jar b/lib/lwjgl-3.3.1.jar
new file mode 100644
index 000000000..2d84fdc2e
Binary files /dev/null and b/lib/lwjgl-3.3.1.jar differ
diff --git a/lib/lwjgl-glfw-3.2.3-javadoc.jar b/lib/lwjgl-glfw-3.2.3-javadoc.jar
deleted file mode 100644
index 5e328ce90..000000000
Binary files a/lib/lwjgl-glfw-3.2.3-javadoc.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.2.3-natives-linux-arm32.jar b/lib/lwjgl-glfw-3.2.3-natives-linux-arm32.jar
deleted file mode 100644
index 54441cd9d..000000000
Binary files a/lib/lwjgl-glfw-3.2.3-natives-linux-arm32.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.2.3-natives-linux-arm64.jar b/lib/lwjgl-glfw-3.2.3-natives-linux-arm64.jar
deleted file mode 100644
index 9f5bbf365..000000000
Binary files a/lib/lwjgl-glfw-3.2.3-natives-linux-arm64.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.2.3-natives-linux.jar b/lib/lwjgl-glfw-3.2.3-natives-linux.jar
deleted file mode 100644
index 2f48c4978..000000000
Binary files a/lib/lwjgl-glfw-3.2.3-natives-linux.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.2.3-natives-macos.jar b/lib/lwjgl-glfw-3.2.3-natives-macos.jar
deleted file mode 100644
index 148ea4174..000000000
Binary files a/lib/lwjgl-glfw-3.2.3-natives-macos.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.2.3-natives-windows-x86.jar b/lib/lwjgl-glfw-3.2.3-natives-windows-x86.jar
deleted file mode 100644
index 0b6172111..000000000
Binary files a/lib/lwjgl-glfw-3.2.3-natives-windows-x86.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.2.3-natives-windows.jar b/lib/lwjgl-glfw-3.2.3-natives-windows.jar
deleted file mode 100644
index ba29a1482..000000000
Binary files a/lib/lwjgl-glfw-3.2.3-natives-windows.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.2.3-sources.jar b/lib/lwjgl-glfw-3.2.3-sources.jar
deleted file mode 100644
index 3f11673de..000000000
Binary files a/lib/lwjgl-glfw-3.2.3-sources.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.2.3.jar b/lib/lwjgl-glfw-3.2.3.jar
deleted file mode 100644
index 5408c4d92..000000000
Binary files a/lib/lwjgl-glfw-3.2.3.jar and /dev/null differ
diff --git a/lib/lwjgl-glfw-3.3.1-javadoc.jar b/lib/lwjgl-glfw-3.3.1-javadoc.jar
new file mode 100644
index 000000000..9c456020a
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-javadoc.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1-natives-linux-arm32.jar b/lib/lwjgl-glfw-3.3.1-natives-linux-arm32.jar
new file mode 100644
index 000000000..9931a42b8
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-natives-linux-arm32.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1-natives-linux-arm64.jar b/lib/lwjgl-glfw-3.3.1-natives-linux-arm64.jar
new file mode 100644
index 000000000..9fc7cb759
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-natives-linux-arm64.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1-natives-linux.jar b/lib/lwjgl-glfw-3.3.1-natives-linux.jar
new file mode 100644
index 000000000..f86908a62
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-natives-linux.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1-natives-macos-arm64.jar b/lib/lwjgl-glfw-3.3.1-natives-macos-arm64.jar
new file mode 100644
index 000000000..4341de388
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-natives-macos-arm64.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1-natives-macos.jar b/lib/lwjgl-glfw-3.3.1-natives-macos.jar
new file mode 100644
index 000000000..3159b5857
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-natives-macos.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1-natives-windows-x86.jar b/lib/lwjgl-glfw-3.3.1-natives-windows-x86.jar
new file mode 100644
index 000000000..4048dbba0
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-natives-windows-x86.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1-natives-windows.jar b/lib/lwjgl-glfw-3.3.1-natives-windows.jar
new file mode 100644
index 000000000..0ab2fa777
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-natives-windows.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1-sources.jar b/lib/lwjgl-glfw-3.3.1-sources.jar
new file mode 100644
index 000000000..ed7edb96f
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1-sources.jar differ
diff --git a/lib/lwjgl-glfw-3.3.1.jar b/lib/lwjgl-glfw-3.3.1.jar
new file mode 100644
index 000000000..f3961acb9
Binary files /dev/null and b/lib/lwjgl-glfw-3.3.1.jar differ
diff --git a/lib/lwjgl-jemalloc-3.2.3-natives-linux-arm32.jar b/lib/lwjgl-jemalloc-3.2.3-natives-linux-arm32.jar
deleted file mode 100644
index c95a2513c..000000000
Binary files a/lib/lwjgl-jemalloc-3.2.3-natives-linux-arm32.jar and /dev/null differ
diff --git a/lib/lwjgl-jemalloc-3.2.3-natives-linux-arm64.jar b/lib/lwjgl-jemalloc-3.2.3-natives-linux-arm64.jar
deleted file mode 100644
index dbc114372..000000000
Binary files a/lib/lwjgl-jemalloc-3.2.3-natives-linux-arm64.jar and /dev/null differ
diff --git a/lib/lwjgl-jemalloc-3.2.3-natives-linux.jar b/lib/lwjgl-jemalloc-3.2.3-natives-linux.jar
deleted file mode 100644
index 396941dfc..000000000
Binary files a/lib/lwjgl-jemalloc-3.2.3-natives-linux.jar and /dev/null differ
diff --git a/lib/lwjgl-jemalloc-3.2.3-natives-macos.jar b/lib/lwjgl-jemalloc-3.2.3-natives-macos.jar
deleted file mode 100644
index ad4ede746..000000000
Binary files a/lib/lwjgl-jemalloc-3.2.3-natives-macos.jar and /dev/null differ
diff --git a/lib/lwjgl-jemalloc-3.2.3-natives-windows-x86.jar b/lib/lwjgl-jemalloc-3.2.3-natives-windows-x86.jar
deleted file mode 100644
index 2fd051c44..000000000
Binary files a/lib/lwjgl-jemalloc-3.2.3-natives-windows-x86.jar and /dev/null differ
diff --git a/lib/lwjgl-jemalloc-3.2.3-natives-windows.jar b/lib/lwjgl-jemalloc-3.2.3-natives-windows.jar
deleted file mode 100644
index a6526486a..000000000
Binary files a/lib/lwjgl-jemalloc-3.2.3-natives-windows.jar and /dev/null differ
diff --git a/lib/lwjgl-jemalloc-3.2.3-sources.jar b/lib/lwjgl-jemalloc-3.2.3-sources.jar
deleted file mode 100644
index fa7056896..000000000
Binary files a/lib/lwjgl-jemalloc-3.2.3-sources.jar and /dev/null differ
diff --git a/lib/lwjgl-jemalloc-3.2.3.jar b/lib/lwjgl-jemalloc-3.2.3.jar
deleted file mode 100644
index 07029fc00..000000000
Binary files a/lib/lwjgl-jemalloc-3.2.3.jar and /dev/null differ
diff --git a/lib/lwjgl-jemalloc-3.2.3-javadoc.jar b/lib/lwjgl-jemalloc-3.3.1-javadoc.jar
similarity index 74%
rename from lib/lwjgl-jemalloc-3.2.3-javadoc.jar
rename to lib/lwjgl-jemalloc-3.3.1-javadoc.jar
index adb48bcef..80a167b0b 100644
Binary files a/lib/lwjgl-jemalloc-3.2.3-javadoc.jar and b/lib/lwjgl-jemalloc-3.3.1-javadoc.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1-natives-linux-arm32.jar b/lib/lwjgl-jemalloc-3.3.1-natives-linux-arm32.jar
new file mode 100644
index 000000000..95a13dcab
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1-natives-linux-arm32.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1-natives-linux-arm64.jar b/lib/lwjgl-jemalloc-3.3.1-natives-linux-arm64.jar
new file mode 100644
index 000000000..cc4dc0298
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1-natives-linux-arm64.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1-natives-linux.jar b/lib/lwjgl-jemalloc-3.3.1-natives-linux.jar
new file mode 100644
index 000000000..df249fa9f
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1-natives-linux.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1-natives-macos-arm64.jar b/lib/lwjgl-jemalloc-3.3.1-natives-macos-arm64.jar
new file mode 100644
index 000000000..a667c8777
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1-natives-macos-arm64.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1-natives-macos.jar b/lib/lwjgl-jemalloc-3.3.1-natives-macos.jar
new file mode 100644
index 000000000..f74296d67
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1-natives-macos.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1-natives-windows-x86.jar b/lib/lwjgl-jemalloc-3.3.1-natives-windows-x86.jar
new file mode 100644
index 000000000..9ad2a9177
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1-natives-windows-x86.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1-natives-windows.jar b/lib/lwjgl-jemalloc-3.3.1-natives-windows.jar
new file mode 100644
index 000000000..8c3de2175
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1-natives-windows.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1-sources.jar b/lib/lwjgl-jemalloc-3.3.1-sources.jar
new file mode 100644
index 000000000..adc5a39b5
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1-sources.jar differ
diff --git a/lib/lwjgl-jemalloc-3.3.1.jar b/lib/lwjgl-jemalloc-3.3.1.jar
new file mode 100644
index 000000000..3ef88622f
Binary files /dev/null and b/lib/lwjgl-jemalloc-3.3.1.jar differ
diff --git a/lib/lwjgl-openal-3.2.3-natives-linux-arm32.jar b/lib/lwjgl-openal-3.2.3-natives-linux-arm32.jar
deleted file mode 100644
index fce5eb9dd..000000000
Binary files a/lib/lwjgl-openal-3.2.3-natives-linux-arm32.jar and /dev/null differ
diff --git a/lib/lwjgl-openal-3.2.3-natives-linux-arm64.jar b/lib/lwjgl-openal-3.2.3-natives-linux-arm64.jar
deleted file mode 100644
index 65ebedb5e..000000000
Binary files a/lib/lwjgl-openal-3.2.3-natives-linux-arm64.jar and /dev/null differ
diff --git a/lib/lwjgl-openal-3.2.3-natives-linux.jar b/lib/lwjgl-openal-3.2.3-natives-linux.jar
deleted file mode 100644
index 383bf3fa2..000000000
Binary files a/lib/lwjgl-openal-3.2.3-natives-linux.jar and /dev/null differ
diff --git a/lib/lwjgl-openal-3.2.3-natives-macos.jar b/lib/lwjgl-openal-3.2.3-natives-macos.jar
deleted file mode 100644
index f690b9241..000000000
Binary files a/lib/lwjgl-openal-3.2.3-natives-macos.jar and /dev/null differ
diff --git a/lib/lwjgl-openal-3.2.3-natives-windows-x86.jar b/lib/lwjgl-openal-3.2.3-natives-windows-x86.jar
deleted file mode 100644
index 34633e605..000000000
Binary files a/lib/lwjgl-openal-3.2.3-natives-windows-x86.jar and /dev/null differ
diff --git a/lib/lwjgl-openal-3.2.3-natives-windows.jar b/lib/lwjgl-openal-3.2.3-natives-windows.jar
deleted file mode 100644
index 56adadf21..000000000
Binary files a/lib/lwjgl-openal-3.2.3-natives-windows.jar and /dev/null differ
diff --git a/lib/lwjgl-openal-3.2.3-sources.jar b/lib/lwjgl-openal-3.2.3-sources.jar
deleted file mode 100644
index 6ca1e29fd..000000000
Binary files a/lib/lwjgl-openal-3.2.3-sources.jar and /dev/null differ
diff --git a/lib/lwjgl-openal-3.2.3.jar b/lib/lwjgl-openal-3.2.3.jar
deleted file mode 100644
index 8f5f39d9d..000000000
Binary files a/lib/lwjgl-openal-3.2.3.jar and /dev/null differ
diff --git a/lib/lwjgl-openal-3.2.3-javadoc.jar b/lib/lwjgl-openal-3.3.1-javadoc.jar
similarity index 56%
rename from lib/lwjgl-openal-3.2.3-javadoc.jar
rename to lib/lwjgl-openal-3.3.1-javadoc.jar
index 7152d1533..d515e03f0 100644
Binary files a/lib/lwjgl-openal-3.2.3-javadoc.jar and b/lib/lwjgl-openal-3.3.1-javadoc.jar differ
diff --git a/lib/lwjgl-openal-3.3.1-natives-linux-arm32.jar b/lib/lwjgl-openal-3.3.1-natives-linux-arm32.jar
new file mode 100644
index 000000000..897c1237d
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1-natives-linux-arm32.jar differ
diff --git a/lib/lwjgl-openal-3.3.1-natives-linux-arm64.jar b/lib/lwjgl-openal-3.3.1-natives-linux-arm64.jar
new file mode 100644
index 000000000..322f5eff1
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1-natives-linux-arm64.jar differ
diff --git a/lib/lwjgl-openal-3.3.1-natives-linux.jar b/lib/lwjgl-openal-3.3.1-natives-linux.jar
new file mode 100644
index 000000000..4bc6bc96f
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1-natives-linux.jar differ
diff --git a/lib/lwjgl-openal-3.3.1-natives-macos-arm64.jar b/lib/lwjgl-openal-3.3.1-natives-macos-arm64.jar
new file mode 100644
index 000000000..d021df01f
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1-natives-macos-arm64.jar differ
diff --git a/lib/lwjgl-openal-3.3.1-natives-macos.jar b/lib/lwjgl-openal-3.3.1-natives-macos.jar
new file mode 100644
index 000000000..0f4570f71
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1-natives-macos.jar differ
diff --git a/lib/lwjgl-openal-3.3.1-natives-windows-x86.jar b/lib/lwjgl-openal-3.3.1-natives-windows-x86.jar
new file mode 100644
index 000000000..5f4952fca
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1-natives-windows-x86.jar differ
diff --git a/lib/lwjgl-openal-3.3.1-natives-windows.jar b/lib/lwjgl-openal-3.3.1-natives-windows.jar
new file mode 100644
index 000000000..0172f5c22
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1-natives-windows.jar differ
diff --git a/lib/lwjgl-openal-3.3.1-sources.jar b/lib/lwjgl-openal-3.3.1-sources.jar
new file mode 100644
index 000000000..5f17394aa
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1-sources.jar differ
diff --git a/lib/lwjgl-openal-3.3.1.jar b/lib/lwjgl-openal-3.3.1.jar
new file mode 100644
index 000000000..97595e344
Binary files /dev/null and b/lib/lwjgl-openal-3.3.1.jar differ
diff --git a/lib/lwjgl-opengl-3.2.3-javadoc.jar b/lib/lwjgl-opengl-3.2.3-javadoc.jar
deleted file mode 100644
index 5e5ba8302..000000000
Binary files a/lib/lwjgl-opengl-3.2.3-javadoc.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.2.3-natives-linux-arm32.jar b/lib/lwjgl-opengl-3.2.3-natives-linux-arm32.jar
deleted file mode 100644
index cebb76767..000000000
Binary files a/lib/lwjgl-opengl-3.2.3-natives-linux-arm32.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.2.3-natives-linux-arm64.jar b/lib/lwjgl-opengl-3.2.3-natives-linux-arm64.jar
deleted file mode 100644
index 6aa076935..000000000
Binary files a/lib/lwjgl-opengl-3.2.3-natives-linux-arm64.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.2.3-natives-linux.jar b/lib/lwjgl-opengl-3.2.3-natives-linux.jar
deleted file mode 100644
index bbe45383c..000000000
Binary files a/lib/lwjgl-opengl-3.2.3-natives-linux.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.2.3-natives-macos.jar b/lib/lwjgl-opengl-3.2.3-natives-macos.jar
deleted file mode 100644
index 084072e41..000000000
Binary files a/lib/lwjgl-opengl-3.2.3-natives-macos.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.2.3-natives-windows-x86.jar b/lib/lwjgl-opengl-3.2.3-natives-windows-x86.jar
deleted file mode 100644
index c7da8fe91..000000000
Binary files a/lib/lwjgl-opengl-3.2.3-natives-windows-x86.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.2.3-natives-windows.jar b/lib/lwjgl-opengl-3.2.3-natives-windows.jar
deleted file mode 100644
index 977cfcb12..000000000
Binary files a/lib/lwjgl-opengl-3.2.3-natives-windows.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.2.3-sources.jar b/lib/lwjgl-opengl-3.2.3-sources.jar
deleted file mode 100644
index 17ff783ec..000000000
Binary files a/lib/lwjgl-opengl-3.2.3-sources.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.2.3.jar b/lib/lwjgl-opengl-3.2.3.jar
deleted file mode 100644
index b7dcfa363..000000000
Binary files a/lib/lwjgl-opengl-3.2.3.jar and /dev/null differ
diff --git a/lib/lwjgl-opengl-3.3.1-javadoc.jar b/lib/lwjgl-opengl-3.3.1-javadoc.jar
new file mode 100644
index 000000000..925a83ea0
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-javadoc.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1-natives-linux-arm32.jar b/lib/lwjgl-opengl-3.3.1-natives-linux-arm32.jar
new file mode 100644
index 000000000..d566ceebf
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-natives-linux-arm32.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1-natives-linux-arm64.jar b/lib/lwjgl-opengl-3.3.1-natives-linux-arm64.jar
new file mode 100644
index 000000000..aef590661
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-natives-linux-arm64.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1-natives-linux.jar b/lib/lwjgl-opengl-3.3.1-natives-linux.jar
new file mode 100644
index 000000000..f9ea471aa
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-natives-linux.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1-natives-macos-arm64.jar b/lib/lwjgl-opengl-3.3.1-natives-macos-arm64.jar
new file mode 100644
index 000000000..b1abd6ea6
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-natives-macos-arm64.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1-natives-macos.jar b/lib/lwjgl-opengl-3.3.1-natives-macos.jar
new file mode 100644
index 000000000..24c160492
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-natives-macos.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1-natives-windows-x86.jar b/lib/lwjgl-opengl-3.3.1-natives-windows-x86.jar
new file mode 100644
index 000000000..c710602c9
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-natives-windows-x86.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1-natives-windows.jar b/lib/lwjgl-opengl-3.3.1-natives-windows.jar
new file mode 100644
index 000000000..07ebba5fb
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-natives-windows.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1-sources.jar b/lib/lwjgl-opengl-3.3.1-sources.jar
new file mode 100644
index 000000000..31f4261f1
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1-sources.jar differ
diff --git a/lib/lwjgl-opengl-3.3.1.jar b/lib/lwjgl-opengl-3.3.1.jar
new file mode 100644
index 000000000..0a61e4e65
Binary files /dev/null and b/lib/lwjgl-opengl-3.3.1.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-javadoc.jar b/lib/lwjgl-stb-3.3.1-javadoc.jar
new file mode 100644
index 000000000..7a2f0e539
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-javadoc.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-natives-linux-arm32.jar b/lib/lwjgl-stb-3.3.1-natives-linux-arm32.jar
new file mode 100644
index 000000000..caab71583
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-natives-linux-arm32.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-natives-linux-arm64.jar b/lib/lwjgl-stb-3.3.1-natives-linux-arm64.jar
new file mode 100644
index 000000000..fc8d7d236
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-natives-linux-arm64.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-natives-linux.jar b/lib/lwjgl-stb-3.3.1-natives-linux.jar
new file mode 100644
index 000000000..75f02ae5b
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-natives-linux.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-natives-macos-arm64.jar b/lib/lwjgl-stb-3.3.1-natives-macos-arm64.jar
new file mode 100644
index 000000000..342f5f9a7
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-natives-macos-arm64.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-natives-macos.jar b/lib/lwjgl-stb-3.3.1-natives-macos.jar
new file mode 100644
index 000000000..40422e2e4
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-natives-macos.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-natives-windows-x86.jar b/lib/lwjgl-stb-3.3.1-natives-windows-x86.jar
new file mode 100644
index 000000000..7bee5602f
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-natives-windows-x86.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-natives-windows.jar b/lib/lwjgl-stb-3.3.1-natives-windows.jar
new file mode 100644
index 000000000..0f6876a93
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-natives-windows.jar differ
diff --git a/lib/lwjgl-stb-3.3.1-sources.jar b/lib/lwjgl-stb-3.3.1-sources.jar
new file mode 100644
index 000000000..fc8c6f89c
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1-sources.jar differ
diff --git a/lib/lwjgl-stb-3.3.1.jar b/lib/lwjgl-stb-3.3.1.jar
new file mode 100644
index 000000000..db8b94dd2
Binary files /dev/null and b/lib/lwjgl-stb-3.3.1.jar differ
diff --git a/src/net/torvald/terrarum/App.java b/src/net/torvald/terrarum/App.java
index 188c09316..c89933927 100644
--- a/src/net/torvald/terrarum/App.java
+++ b/src/net/torvald/terrarum/App.java
@@ -353,7 +353,7 @@ public class App implements ApplicationListener {
Lwjgl3ApplicationConfiguration appConfig = new Lwjgl3ApplicationConfiguration();
//appConfig.useGL30 = false; // https://stackoverflow.com/questions/46753218/libgdx-should-i-use-gl30
- appConfig.useOpenGL3(true, 3, 2);
+ appConfig.setOpenGLEmulation(Lwjgl3ApplicationConfiguration.GLEmulation.GL30, 3, 2);
appConfig.useVsync(getConfigBoolean("usevsync"));
appConfig.setResizable(false);
appConfig.setWindowedMode(width, height);
diff --git a/src/net/torvald/terrarum/modulebasegame/gameactors/FixtureTapestry.kt b/src/net/torvald/terrarum/modulebasegame/gameactors/FixtureTapestry.kt
index 39e3d52b9..cc9c0dc31 100644
--- a/src/net/torvald/terrarum/modulebasegame/gameactors/FixtureTapestry.kt
+++ b/src/net/torvald/terrarum/modulebasegame/gameactors/FixtureTapestry.kt
@@ -1,3 +1,4 @@
+
package net.torvald.terrarum.modulebasegame.gameactors
import com.badlogic.gdx.graphics.Pixmap
diff --git a/src/net/torvald/terrarum/tests/UITestPad1.kt b/src/net/torvald/terrarum/tests/UITestPad1.kt
index d4ee5c476..d6e5b757a 100644
--- a/src/net/torvald/terrarum/tests/UITestPad1.kt
+++ b/src/net/torvald/terrarum/tests/UITestPad1.kt
@@ -2,7 +2,6 @@ package net.torvald.terrarum.tests
import com.badlogic.gdx.Gdx
import com.badlogic.gdx.InputAdapter
-import com.badlogic.gdx.ScreenAdapter
import com.badlogic.gdx.backends.lwjgl3.Lwjgl3Application
import com.badlogic.gdx.backends.lwjgl3.Lwjgl3ApplicationConfiguration
import com.badlogic.gdx.graphics.Color
@@ -16,8 +15,6 @@ import net.torvald.colourutil.HUSLColorConverter
import net.torvald.terrarum.*
import net.torvald.terrarum.gamecontroller.TerrarumKeyboardEvent
import net.torvald.terrarum.modulebasegame.TerrarumIngame
-import net.torvald.terrarum.ui.Toolkit
-import net.torvald.terrarum.ui.UINSMenu
val UITEST1_WIDTH = 1280
val UITEST1_HEIGHT = 720
@@ -133,7 +130,8 @@ fun main(args: Array) {
appConfig.useVsync(false)
appConfig.setResizable(false)
appConfig.setWindowedMode(UITEST1_WIDTH, UITEST1_HEIGHT)
- appConfig.useOpenGL3(true, 3, 2)
+ //appConfig.useGL30 = false; // https://stackoverflow.com/questions/46753218/libgdx-should-i-use-gl30
+ appConfig.setOpenGLEmulation(Lwjgl3ApplicationConfiguration.GLEmulation.GL30, 3, 2)
App.scr = TerrarumScreenSize(UITEST1_WIDTH, UITEST1_HEIGHT)
diff --git a/src/net/torvald/terrarum/worlddrawer/CreateTileAtlas.kt b/src/net/torvald/terrarum/worlddrawer/CreateTileAtlas.kt
index f5bea1057..e03193a7b 100644
--- a/src/net/torvald/terrarum/worlddrawer/CreateTileAtlas.kt
+++ b/src/net/torvald/terrarum/worlddrawer/CreateTileAtlas.kt
@@ -13,6 +13,7 @@ import net.torvald.terrarum.TerrarumAppConfiguration.TILE_SIZE
import net.torvald.terrarum.blockproperties.Fluid
import net.torvald.terrarum.gameitems.ItemID
import net.torvald.terrarum.gameworld.GameWorld
+import net.torvald.terrarum.worlddrawer.CreateTileAtlas.AtlasSource.*
import kotlin.math.roundToInt
/**
@@ -319,17 +320,17 @@ class CreateTileAtlas {
// different texture for different seasons (224x224)
if (seasonal) {
val i = if (i < 41) i else i + 1 // to compensate the discontinuity between 40th and 41st tile
- _drawToAtlantes(matte, atlasCursor, i % 7, i / 7, 1)
- _drawToAtlantes(matte, atlasCursor, i % 7 + 7, i / 7, 2)
- _drawToAtlantes(matte, atlasCursor, i % 7 + 7, i / 7 + 7, 3)
- _drawToAtlantes(matte, atlasCursor, i % 7, i / 7 + 7, 4)
- _drawToAtlantes(glow, atlasCursor, i % 7, i / 7, 6)
+ _drawToAtlantes(matte, atlasCursor, i % 7, i / 7, SUMMER)
+ _drawToAtlantes(matte, atlasCursor, i % 7 + 7, i / 7, AUTUMN)
+ _drawToAtlantes(matte, atlasCursor, i % 7 + 7, i / 7 + 7, WINTER)
+ _drawToAtlantes(matte, atlasCursor, i % 7, i / 7 + 7, SPRING)
+ _drawToAtlantes(glow, atlasCursor, i % 7, i / 7, GLOW)
atlasCursor += 1
}
else {
val i = if (i < 41) i else i + 1 // to compensate the discontinuity between 40th and 41st tile
- _drawToAtlantes(matte, atlasCursor, i % txOfPixmap, i / txOfPixmap, 0)
- _drawToAtlantes(glow, atlasCursor, i % txOfPixmapGlow, i / txOfPixmapGlow, 6)
+ _drawToAtlantes(matte, atlasCursor, i % txOfPixmap, i / txOfPixmap, FOUR_SEASONS)
+ _drawToAtlantes(glow, atlasCursor, i % txOfPixmapGlow, i / txOfPixmapGlow, GLOW)
atlasCursor += 1
}
}
@@ -338,12 +339,12 @@ class CreateTileAtlas {
/**
* mode: 0 for all the atlantes, 1-4 for summer/autumn/winter/spring atlas
*/
- private fun _drawToAtlantes(pixmap: Pixmap, destTileNum: Int, srcTileX: Int, srcTileY: Int, mode: Int) {
- if (mode == 0) {
- _drawToAtlantes(pixmap, destTileNum, srcTileX, srcTileY, 1)
- _drawToAtlantes(pixmap, destTileNum, srcTileX, srcTileY, 2)
- _drawToAtlantes(pixmap, destTileNum, srcTileX, srcTileY, 3)
- _drawToAtlantes(pixmap, destTileNum, srcTileX, srcTileY, 4)
+ private fun _drawToAtlantes(pixmap: Pixmap, destTileNum: Int, srcTileX: Int, srcTileY: Int, source: AtlasSource) {
+ if (source == FOUR_SEASONS) {
+ _drawToAtlantes(pixmap, destTileNum, srcTileX, srcTileY, SUMMER)
+ _drawToAtlantes(pixmap, destTileNum, srcTileX, srcTileY, AUTUMN)
+ _drawToAtlantes(pixmap, destTileNum, srcTileX, srcTileY, WINTER)
+ _drawToAtlantes(pixmap, destTileNum, srcTileX, srcTileY, SPRING)
}
else {
val atlasX = (destTileNum % TILES_IN_X) * TILE_SIZE
@@ -353,13 +354,14 @@ class CreateTileAtlas {
//if (mode == 1) printdbg(this, "atlaspos: ($atlasX, $atlasY), srcpos: ($sourceX, $sourceY), srcpixmap = $pixmap")
- when (mode) {
- 1 -> atlas.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
- 2 -> atlasAutumn.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
- 3 -> atlasWinter.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
- 4 -> atlasSpring.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
- 5 -> atlasFluid.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
- 6 -> atlasGlow.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
+ when (source) {
+ SUMMER -> atlas.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
+ AUTUMN -> atlasAutumn.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
+ WINTER -> atlasWinter.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
+ SPRING -> atlasSpring.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
+ FLUID -> atlasFluid.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
+ GLOW -> atlasGlow.drawPixmap(pixmap, sourceX, sourceY, TILE_SIZE, TILE_SIZE, atlasX, atlasY, TILE_SIZE, TILE_SIZE)
+ else -> throw IllegalArgumentException("Unknown draw source $source")
}
}
}
@@ -407,4 +409,8 @@ class CreateTileAtlas {
nullTile.dispose()
}
+
+ private enum class AtlasSource {
+ FOUR_SEASONS, SUMMER, AUTUMN, WINTER, SPRING, FLUID, GLOW
+ }
}
\ No newline at end of file