Move EndTickMixin to fabric, to replace it using a ClientTickEvent in neoforge
Signed-off-by: Username404-59 <w.iron.zombie@gmail.com>
This commit is contained in:
parent
b4574ef5b8
commit
febeddb093
|
@ -5,7 +5,6 @@
|
|||
"client": [
|
||||
"KeysAccessor",
|
||||
"KeyMappings",
|
||||
"EndTickMixin",
|
||||
"TitleScreenMixin",
|
||||
"OptionValueAccessor"
|
||||
],
|
||||
|
|
|
@ -3,6 +3,7 @@
|
|||
"package": "fr.username404.snowygui.mixins",
|
||||
"compatibilityLevel": "JAVA_18",
|
||||
"client": [
|
||||
"EndTickMixin",
|
||||
"ZoomMixin",
|
||||
"OkZoomerAlternativeMixin"
|
||||
],
|
||||
|
|
|
@ -0,0 +1,11 @@
|
|||
package fr.username404.snowygui.forge
|
||||
|
||||
import fr.username404.snowygui.EventSnowy
|
||||
import net.neoforged.bus.api.SubscribeEvent
|
||||
import net.neoforged.neoforge.client.event.ClientTickEvent
|
||||
|
||||
object EndTickHandler: EventSnowy {
|
||||
override val type: String = "EndTick"
|
||||
@SubscribeEvent
|
||||
fun handleEndTick(event: ClientTickEvent.Post) = fire<Any>()
|
||||
}
|
|
@ -29,6 +29,7 @@ class ForgeInit(container: ModContainer): Snowy() {
|
|||
init {
|
||||
container.eventBus!!.run {
|
||||
addListener(this@ForgeInit::initSetup)
|
||||
register(EndTickHandler)
|
||||
register(HudHandler)
|
||||
register(ZoomHandler)
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue