Merge branch 'drop-decimal-use-cannyfastmath' into 20-06-18-merge

This commit is contained in:
Pieter-Jan Briers
2020-06-18 02:34:47 +02:00
25 changed files with 71 additions and 66 deletions

View File

@@ -12,6 +12,9 @@ using Robust.Shared.IoC;
using Robust.Shared.Maths;
using System;
using System.Linq;
using CannyFastMath;
using Math = CannyFastMath.Math;
using MathF = CannyFastMath.MathF;
namespace Content.Server.GameObjects.EntitySystems
{
@@ -77,7 +80,7 @@ namespace Content.Server.GameObjects.EntitySystems
{
EntityQuery = new TypeEntityQuery(typeof(SolarPanelComponent));
// Initialize the sun to something random
TowardsSun = Math.PI * 2 * _robustRandom.NextDouble();
TowardsSun = Math.TAU * _robustRandom.NextDouble();
SunAngularVelocity = Angle.FromDegrees(0.1 + ((_robustRandom.NextDouble() - 0.5) * 0.05));
}