aboutsummaryrefslogtreecommitdiff
path: root/fabric/src/main/kotlin
diff options
context:
space:
mode:
authornea <romangraef@gmail.com>2022-07-12 14:20:22 +0200
committernea <romangraef@gmail.com>2022-07-12 14:20:22 +0200
commit372eec27e5e0c8ef796ed9e6bcdc68a10df84718 (patch)
tree425ab1a282196a68819da297c670e9170a8c514a /fabric/src/main/kotlin
downloadfirmament-372eec27e5e0c8ef796ed9e6bcdc68a10df84718.tar.gz
firmament-372eec27e5e0c8ef796ed9e6bcdc68a10df84718.tar.bz2
firmament-372eec27e5e0c8ef796ed9e6bcdc68a10df84718.zip
initial
Diffstat (limited to 'fabric/src/main/kotlin')
-rw-r--r--fabric/src/main/kotlin/net/examplemod/fabric/ExampleExpectPlatformImpl.kt13
-rw-r--r--fabric/src/main/kotlin/net/examplemod/fabric/ExampleModFabric.kt10
2 files changed, 23 insertions, 0 deletions
diff --git a/fabric/src/main/kotlin/net/examplemod/fabric/ExampleExpectPlatformImpl.kt b/fabric/src/main/kotlin/net/examplemod/fabric/ExampleExpectPlatformImpl.kt
new file mode 100644
index 0000000..8982dfc
--- /dev/null
+++ b/fabric/src/main/kotlin/net/examplemod/fabric/ExampleExpectPlatformImpl.kt
@@ -0,0 +1,13 @@
+package net.examplemod.fabric
+
+import net.fabricmc.loader.api.FabricLoader
+import java.nio.file.Path
+import net.examplemod.ExampleExpectPlatform
+
+object ExampleExpectPlatformImpl {
+ /**
+ * This is our actual method to [ExampleExpectPlatform.getConfigDirectory].
+ */
+ @JvmStatic
+ fun getConfigDirectory(): Path = FabricLoader.getInstance().configDir
+} \ No newline at end of file
diff --git a/fabric/src/main/kotlin/net/examplemod/fabric/ExampleModFabric.kt b/fabric/src/main/kotlin/net/examplemod/fabric/ExampleModFabric.kt
new file mode 100644
index 0000000..c11491c
--- /dev/null
+++ b/fabric/src/main/kotlin/net/examplemod/fabric/ExampleModFabric.kt
@@ -0,0 +1,10 @@
+package net.examplemod.fabric
+
+import net.examplemod.ExampleMod.init
+import net.fabricmc.api.ModInitializer
+
+class ExampleModFabric : ModInitializer {
+ override fun onInitialize() {
+ init()
+ }
+} \ No newline at end of file