generated from MrSphay/codex-agent-repository-kit
This commit is contained in:
@@ -4,7 +4,7 @@
|
||||
package com.vinlanx.explosionoverhaul;
|
||||
|
||||
import net.neoforged.neoforge.client.event.sound.PlaySoundEvent;
|
||||
import com.vinlanx.explosionoverhaul.compat.TickEvent;
|
||||
import net.neoforged.neoforge.client.event.ClientTickEvent;
|
||||
import net.neoforged.bus.api.EventPriority;
|
||||
import net.neoforged.bus.api.SubscribeEvent;
|
||||
|
||||
@@ -18,13 +18,11 @@ public class ClientSoundHandler {
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public void onClientTick(TickEvent.ClientTickEvent event) {
|
||||
if (event.phase == TickEvent.Phase.END) {
|
||||
if (suppressionTicksRemaining > 0) {
|
||||
--suppressionTicksRemaining;
|
||||
} else if (suppressionTicksRemaining == 0 && suppressVanillaExplosionSound) {
|
||||
suppressVanillaExplosionSound = false;
|
||||
}
|
||||
public void onClientTick(ClientTickEvent.Post event) {
|
||||
if (suppressionTicksRemaining > 0) {
|
||||
--suppressionTicksRemaining;
|
||||
} else if (suppressionTicksRemaining == 0 && suppressVanillaExplosionSound) {
|
||||
suppressVanillaExplosionSound = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@ import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.screens.Screen;
|
||||
import net.minecraft.client.gui.screens.TitleScreen;
|
||||
import net.neoforged.api.distmarker.Dist;
|
||||
import com.vinlanx.explosionoverhaul.compat.TickEvent;
|
||||
import net.neoforged.neoforge.client.event.ClientTickEvent;
|
||||
import net.neoforged.bus.api.SubscribeEvent;
|
||||
import net.neoforged.fml.common.Mod;
|
||||
import net.neoforged.fml.common.EventBusSubscriber;
|
||||
@@ -21,7 +21,7 @@ public class FirstTimeSetupHandler {
|
||||
private static boolean pendingShowIntro = false;
|
||||
|
||||
@SubscribeEvent
|
||||
public static void onClientTick(TickEvent.ClientTickEvent event) {
|
||||
public static void onClientTick(ClientTickEvent.Post event) {
|
||||
}
|
||||
|
||||
static {
|
||||
|
||||
@@ -5,7 +5,7 @@ package com.vinlanx.explosionoverhaul.client;
|
||||
|
||||
import com.vinlanx.explosionoverhaul.client.IntroMusicManager;
|
||||
import net.neoforged.api.distmarker.Dist;
|
||||
import com.vinlanx.explosionoverhaul.compat.TickEvent;
|
||||
import net.neoforged.neoforge.client.event.ClientTickEvent;
|
||||
import net.neoforged.bus.api.SubscribeEvent;
|
||||
import net.neoforged.fml.common.Mod;
|
||||
import net.neoforged.fml.common.EventBusSubscriber;
|
||||
@@ -15,10 +15,7 @@ public class IntroMusicTickHandler {
|
||||
private static long lastTickTime = System.currentTimeMillis();
|
||||
|
||||
@SubscribeEvent
|
||||
public static void onClientTick(TickEvent.ClientTickEvent event) {
|
||||
if (event.phase != TickEvent.Phase.END) {
|
||||
return;
|
||||
}
|
||||
public static void onClientTick(ClientTickEvent.Post event) {
|
||||
IntroMusicManager musicManager = IntroMusicManager.getInstance();
|
||||
if (musicManager.isPlaying() || musicManager.isFadingOut()) {
|
||||
long currentTime = System.currentTimeMillis();
|
||||
|
||||
Reference in New Issue
Block a user