mirror of
https://github.com/Outer-Wilds-New-Horizons/new-horizons.git
synced 2025-12-11 20:15:44 +01:00
25 lines
605 B
C#
25 lines
605 B
C#
using UnityEngine;
|
|
namespace NewHorizons.Components.SizeControllers
|
|
{
|
|
public class WaterSizeController : SizeController
|
|
{
|
|
public Material oceanFogMaterial;
|
|
public RadialFluidVolume fluidVolume;
|
|
|
|
private void Start()
|
|
{
|
|
oceanFogMaterial.SetFloat("_Radius2", 0);
|
|
}
|
|
|
|
protected new void FixedUpdate()
|
|
{
|
|
base.FixedUpdate();
|
|
if (oceanFogMaterial)
|
|
{
|
|
oceanFogMaterial.SetFloat("_Radius", CurrentScale);
|
|
}
|
|
fluidVolume._radius = CurrentScale;
|
|
}
|
|
}
|
|
}
|