diff options
| author | yum <yum.food.vr@gmail.com> | 2024-10-26 15:51:30 -0700 |
|---|---|---|
| committer | yum <yum.food.vr@gmail.com> | 2024-10-26 15:52:43 -0700 |
| commit | 07b1aca3f096a520cbae1d4cca18692fc69d2944 (patch) | |
| tree | 652dccb4daeb2c9c93153d902ede60169605d1ef /gerstner.cginc | |
| parent | 94f37fa8dd94137a910df4ebc80f98db2d685f08 (diff) | |
Update cloning
Optimize cloning logic, and make each clone rotate independently of the
others when the explosion effect is active.
Diffstat (limited to 'gerstner.cginc')
| -rw-r--r-- | gerstner.cginc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gerstner.cginc b/gerstner.cginc index 47843a7..a5f7db2 100644 --- a/gerstner.cginc +++ b/gerstner.cginc @@ -148,9 +148,9 @@ GerstnerInternalResult compute_gerstner(float3 pp, GerstnerParams p) float3 result_obj = mul(unity_WorldToObject, float4(result_world, 1)).xyz; result_obj = lerp(result_obj, raw_result, - // If within 3m cylindrical distance, apply 100m wide damping. + // If within cylindrical distance, apply damping. // TODO parameterize this! - dsaturate((length(raw_result_world.xz) - 20), 1) * + dsaturate((length(raw_result_world.xz) - 15), 1) * // Only enable if mesh is on the wrong side of the damping vector. // TODO make this differentiable. As is, there's a visible seam. dsaturate(-(raw_result_world.y - _Gimmick_Gerstner_Water_Origin_Damping_Direction) * sign(_Gimmick_Gerstner_Water_Origin_Damping_Direction), 1)); |
