Skip to content

Commit

Permalink
Fixed submerging in liquid crashing the game in the Fabric loader ver…
Browse files Browse the repository at this point in the history
…sion (#2291)
  • Loading branch information
SlimyFrog123 authored Nov 29, 2024
1 parent 45fdcc9 commit 9bf3c10
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
@Mixin(FogRenderer.class)
public abstract class MixinBloodFluid
{
@Inject(method = "computeFogColor", at = @At(value = "RETURN"))
@Inject(method = "computeFogColor", at = @At(value = "RETURN"), cancellable = true)
private static void modifyFogColors(Camera camera, float f, ClientLevel level, int i, float g, CallbackInfoReturnable<Vector4f> cir)
{
BlockPos blockPos = camera.getBlockPosition();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
@Mixin(FogRenderer.class)
public abstract class MixinLiquidNullFluid
{
@Inject(method = "computeFogColor", at = @At(value = "RETURN"))
@Inject(method = "computeFogColor", at = @At(value = "RETURN"), cancellable = true)
private static void modifyFogColors(Camera camera, float f, ClientLevel level, int i, float g, CallbackInfoReturnable<Vector4f> cir)
{
BlockPos blockPos = camera.getBlockPosition();
Expand All @@ -46,7 +46,7 @@ private static void modifyFogColors(Camera camera, float f, ClientLevel level, i

if(BOPFluids.LIQUID_NULL.isSame(fluid))
{
cir.setReturnValue(new Vector4f(0.0F, 0.0F, 0.0F, 0.0F));
cir.setReturnValue(new Vector4f(0.6274509803921569F, 0.12549019607843137F, 0.9411764705882353F, 0.5F));
}
}

Expand Down

0 comments on commit 9bf3c10

Please sign in to comment.