private static List <float> NormalizeWeights(List <float> weights)
        {
            List <float> list = new List <float>(weights.Count);
            float        num  = WaterProfileBlend.WeightSum(weights);

            for (int i = 0; i < weights.Count; i++)
            {
                list.Add(weights[i] / num);
            }
            return(list);
        }
 private void OnValidate()
 {
     if (Application.isPlaying && this.Water != null && this.Water.WindWaves != null)
     {
         this.Water.ProfilesManager.SetProfiles(WaterProfileBlend.CreateProfiles(this._Profiles, this._Weights));
     }
     if (WaterProfileBlend.WeightSum(this._Weights) == 0f)
     {
         this._Weights[0] = 1f;
     }
 }