Exemplo n.º 1
0
 /// <param name="interpolator">0 - use this object, 1 - use other object</param>
 public MyFogProperties InterpolateWith(MyFogProperties otherProperties, float interpolator)
 {
     var result = new MyFogProperties();
     result.FogNear = MathHelper.Lerp(FogNear, otherProperties.FogNear, interpolator);
     result.FogFar = MathHelper.Lerp(FogFar, otherProperties.FogFar, interpolator);
     result.FogMultiplier = MathHelper.Lerp(FogMultiplier, otherProperties.FogMultiplier, interpolator);
     result.FogBacklightMultiplier = MathHelper.Lerp(FogBacklightMultiplier, otherProperties.FogBacklightMultiplier, interpolator);
     result.FogColor = Vector3.Lerp(FogColor, otherProperties.FogColor, interpolator);
     return result;
 }
Exemplo n.º 2
0
 public static void SetDefaults()
 {
     MySolarSystemArea defaults = MySolarSystemConstants.GetDefaultArea();
     SunProperties = defaults.SectorData.SunProperties;
     FogProperties = defaults.SectorData.FogProperties;
     DebrisProperties = defaults.SectorData.DebrisProperties;
     ImpostorProperties = defaults.SectorData.ImpostorProperties;
     ParticleDustProperties = defaults.SectorData.ParticleDustProperties;
     GodRaysProperties = defaults.SectorData.GodRaysProperties;
     BackgroundTexture = defaults.SectorData.BackgroundTexture;
 }
Exemplo n.º 3
0
        /// <param name="interpolator">0 - use this object, 1 - use other object</param>
        public MyFogProperties InterpolateWith(MyFogProperties otherProperties, float interpolator)
        {
            var result = new MyFogProperties();

            result.FogNear                = MathHelper.Lerp(FogNear, otherProperties.FogNear, interpolator);
            result.FogFar                 = MathHelper.Lerp(FogFar, otherProperties.FogFar, interpolator);
            result.FogMultiplier          = MathHelper.Lerp(FogMultiplier, otherProperties.FogMultiplier, interpolator);
            result.FogBacklightMultiplier = MathHelper.Lerp(FogBacklightMultiplier, otherProperties.FogBacklightMultiplier, interpolator);
            result.FogColor               = Vector3.Lerp(FogColor, otherProperties.FogColor, interpolator);
            return(result);
        }