CWX-mods/Live/CWX_WeatherPatcher/TodScatteringPatch.cs

21 lines
583 B
C#
Raw Normal View History

2022-05-14 19:53:00 +01:00
using Aki.Reflection.Patching;
using System.Reflection;
namespace CWX_WeatherPatcher
{
public class TodScatteringPatch : ModulePatch // MAKES CHANGES TO TOD_SCATTERING FOG
2022-05-14 19:53:00 +01:00
{
protected override MethodBase GetTargetMethod()
{
return typeof(TOD_Scattering).GetMethod("Start", BindingFlags.NonPublic | BindingFlags.Instance);
}
[PatchPostfix]
private static void PostFixPatch(ref TOD_Scattering __instance)
{
__instance.GlobalDensity = 0f;
__instance.HeightFalloff = 0f;
}
}
}