summaryrefslogtreecommitdiff
path: root/src/main/kotlin
diff options
context:
space:
mode:
authorLinnea Gräf <nea@nea.moe>2024-05-21 21:51:02 +0200
committerLinnea Gräf <nea@nea.moe>2024-05-21 21:51:02 +0200
commit123bc861062fe28a41d2abd8f5cea50866b8374c (patch)
tree54d8e7f939f6f5bfe72c2e830f0288245f78be58 /src/main/kotlin
parentf25b818d9d41e2bb3969399cfc8bbff976b5aad7 (diff)
downloadultra-notifier-123bc861062fe28a41d2abd8f5cea50866b8374c.tar.gz
ultra-notifier-123bc861062fe28a41d2abd8f5cea50866b8374c.tar.bz2
ultra-notifier-123bc861062fe28a41d2abd8f5cea50866b8374c.zip
Re-add 1.14 support
Diffstat (limited to 'src/main/kotlin')
-rw-r--r--src/main/kotlin/UltraNotifier.kt2
-rw-r--r--src/main/kotlin/UltraNotifierEntryPoint.kt30
-rw-r--r--src/main/kotlin/UltraNotifierEvents.kt2
3 files changed, 19 insertions, 15 deletions
diff --git a/src/main/kotlin/UltraNotifier.kt b/src/main/kotlin/UltraNotifier.kt
index e6ce590..17798cc 100644
--- a/src/main/kotlin/UltraNotifier.kt
+++ b/src/main/kotlin/UltraNotifier.kt
@@ -5,7 +5,7 @@ import java.io.File
object UltraNotifier {
val logger =
-//#if MC == 10809
+//#if MC <= 11404
//$$ org.apache.logging.log4j.LogManager.getLogger("UltraNotifier")!!
//#else
org.slf4j.LoggerFactory.getLogger("UltraNotifier")!!
diff --git a/src/main/kotlin/UltraNotifierEntryPoint.kt b/src/main/kotlin/UltraNotifierEntryPoint.kt
index 34525ea..67dd566 100644
--- a/src/main/kotlin/UltraNotifierEntryPoint.kt
+++ b/src/main/kotlin/UltraNotifierEntryPoint.kt
@@ -1,25 +1,29 @@
package moe.nea.ultranotifier
//#if FORGE
-//$$ import net.minecraftforge.fml.common.Mod
+//$$import net.minecraftforge.fml.common.Mod
//$$
//#if MC == 10809
-//$$ import net.minecraftforge.fml.common.event.FMLInitializationEvent
-//$$ @Mod(modid = Constants.MOD_ID, version = Constants.VERSION, useMetadata = true)
+//$$import net.minecraftforge.fml.common.event.FMLInitializationEvent
+//$$@Mod(modid = Constants.MOD_ID, version = Constants.VERSION, useMetadata = true)
//#else
-//$$ @Mod(Constants.MOD_ID)
+//$$@Mod(Constants.MOD_ID)
//#endif
-//$$ class UltraNotifierEntryPoint {
-//$$ @Mod.EventHandler
-//$$ fun onInit(@Suppress("UNUSED_PARAMETER") event: FMLInitializationEvent) {
-//$$ UltraNotifier.onStartup()
-//$$ }
-//$$ }
+//$$class UltraNotifierEntryPoint {
+//#if MC == 10809
+//$$ @Mod.EventHandler
+//$$ fun onInit(@Suppress("UNUSED_PARAMETER") event: FMLInitializationEvent) {
+//#else
+//$$ init {
+//#endif
+//$$ UltraNotifier.onStartup()
+//$$ }
+//$$}
//#else
import net.fabricmc.api.ModInitializer
object UltraNotifierEntryPoint : ModInitializer {
- override fun onInitialize() {
- UltraNotifier.onStartup()
- }
+ override fun onInitialize() {
+ UltraNotifier.onStartup()
+ }
}
//#endif
diff --git a/src/main/kotlin/UltraNotifierEvents.kt b/src/main/kotlin/UltraNotifierEvents.kt
index eb0d71f..d47a0be 100644
--- a/src/main/kotlin/UltraNotifierEvents.kt
+++ b/src/main/kotlin/UltraNotifierEvents.kt
@@ -17,7 +17,7 @@ object UltraNotifierEvents {
abstract class UltraEvent :
//#if FORGE
-//$$ net.minecraftforge.fml.common.eventhandler.Event()
+//$$ net.minecraftforge.eventbus.api.Event()
//#else
me.bush.eventbus.event.Event()
//#endif