From 4a78ab3d3e16d1259747df66b86e807e4e7c49a4 Mon Sep 17 00:00:00 2001 From: Voyager Date: Wed, 19 Aug 2026 10:02:33 -0400 Subject: [PATCH] Fix shoreline water tint continuity --- tests/world_time_validation.gd | 4 ++++ world/materials/stylized_water.gdshader | 8 ++++---- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/tests/world_time_validation.gd b/tests/world_time_validation.gd index a8f4106..b0b36a1 100644 --- a/tests/world_time_validation.gd +++ b/tests/world_time_validation.gd @@ -368,6 +368,10 @@ func _validate_environment_presentation() -> void: assert("weather_fog_near_amount" in water_shader.code) assert("float weather_fog_alpha = mix(" in water_shader.code) assert("ALPHA = clamp(water_alpha, 0.1, weather_fog_alpha)" in water_shader.code) + assert( + "water_alpha *= mix(0.82, 1.0, contact_stability);" + in water_shader.code + ) assert(is_zero_approx(float( SaltWaterMaterial.get_shader_parameter("weather_fog_amount") ))) diff --git a/world/materials/stylized_water.gdshader b/world/materials/stylized_water.gdshader index 998fdc3..669f649 100644 --- a/world/materials/stylized_water.gdshader +++ b/world/materials/stylized_water.gdshader @@ -515,10 +515,10 @@ void fragment() { water_alpha + shoreline_foam * shoreline_opacity_boost, 0.98 ); - // The authored water-body height is also the casting authority. Fade the - // visual layer completely at exact terrain contact so dry land cannot look - // fishable while the stable sub-surface water remains visible. - water_alpha *= contact_stability; + // Keep the water tint visually continuous across authored terrain contact. + // Fully fading here exposes the raised sand edge as a broken tan seam; the + // fishing resolver, rather than this presentation shader, owns castability. + water_alpha *= mix(0.82, 1.0, contact_stability); float surface_mottle = value_noise( world_position.xz * surface_mottle_scale