Normal Blending Curve BugFix

This commit is contained in:
Josef 2025-07-15 11:46:37 +02:00
parent afdf5e115f
commit fe2460239f
1 changed files with 1 additions and 1 deletions

View File

@ -496,7 +496,7 @@ namespace Rokojori
for ( int i = 0; i < normals.Count; i++ )
{
var yPositionAmount = MathX.RemapClamped( vertices[ i ].Y, startY, endY, 0, 1 );
var blendAmount = curve.Sample( yPositionAmount ) * amount;
var blendAmount = ( curve == null ? 1f : curve.Sample( yPositionAmount ) ) * amount;
blendAmount = MathX.Clamp01( blendAmount );
normals[ i ] = Math3D.BlendNormals( normals[ i ], direction, blendAmount );
}