Fix gravity not being set up before Start

This commit is contained in:
Nick 2022-04-18 03:00:11 -04:00
parent 51a5272ffb
commit e67c93122b

View File

@ -38,8 +38,8 @@ namespace NewHorizons.Components.Orbital
}
else
{
Mass = gv._gravitationalMass;
Power = gv._falloffType == GravityVolume.FalloffType.linear ? 1 : 2;
Mass = gv._surfaceAcceleration * Mathf.Pow(gv._upperSurfaceRadius, Power) / GravityVolume.GRAVITATIONAL_CONSTANT;
}
}
}