Skip to content

Instantly share code, notes, and snippets.

View craigmc08's full-sized avatar

Craig McIlwrath craigmc08

  • 03:00 (UTC -04:00)
View GitHub Profile
using UnityEngine;
// Some helper math methods
public static class Math {
public static bool almost_equal(float x, float y, float precision=1e-4f)
{
return Mathf.Abs(x - y) < precision;
}
public static bool almost_equal(Vector2 a, Vector2 b, float precision = 1e-4f)
{