generated from MrSphay/codex-agent-repository-kit
Fix channel lowpass source shadow
All checks were successful
Build / build (push) Successful in 9m29s
All checks were successful
Build / build (push) Successful in 9m29s
This commit is contained in:
@@ -18,7 +18,7 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfo;
|
||||
public class ChannelLowpassMixin {
|
||||
@Shadow
|
||||
@Final
|
||||
private int f_83642_;
|
||||
private int source;
|
||||
|
||||
@Inject(method={"play"}, at={@At(value="HEAD")})
|
||||
private void onPlay(CallbackInfo ci) {
|
||||
@@ -28,7 +28,7 @@ public class ChannelLowpassMixin {
|
||||
SoundEngineAudioQueue.drainNow();
|
||||
}
|
||||
if (active) {
|
||||
SoundEngineAudioQueue.enqueueAudio(() -> LowPassConcussionEffect.attachFilterToSource(this.f_83642_));
|
||||
SoundEngineAudioQueue.enqueueAudio(() -> LowPassConcussionEffect.attachFilterToSource(this.source));
|
||||
if ("Sound engine".equals(Thread.currentThread().getName())) {
|
||||
SoundEngineAudioQueue.drainNow();
|
||||
}
|
||||
@@ -42,10 +42,10 @@ public class ChannelLowpassMixin {
|
||||
@Inject(method={"stop"}, at={@At(value="HEAD")})
|
||||
private void onStop(CallbackInfo ci) {
|
||||
if (SoundPhysicsCompatibility.isCompatibilityEnabled()) {
|
||||
SoundPhysicsCompatibility.onSourceStop(this.f_83642_);
|
||||
SoundPhysicsCompatibility.onSourceStop(this.source);
|
||||
}
|
||||
try {
|
||||
SoundEngineAudioQueue.enqueueAudio(() -> LowPassConcussionEffect.detachFilterFromSource(this.f_83642_));
|
||||
SoundEngineAudioQueue.enqueueAudio(() -> LowPassConcussionEffect.detachFilterFromSource(this.source));
|
||||
if ("Sound engine".equals(Thread.currentThread().getName())) {
|
||||
SoundEngineAudioQueue.drainNow();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user