public void HandleObjs() { int count = transform.childCount; ObjPoses.Clear(); for (int i = 0; i < count; i++) { Transform tr = transform.GetChild(i); if (!tr.name.Contains("home")) { continue; } Vector3 pos = tr.position; IInt3 iPos = new IInt3(pos); ObjPoses.Add(iPos); } }
/** Dot product of the two coordinates */ public static long DotLong(IInt3 a, IInt3 b) { return((long)a.x * (long)b.x + (long)a.y * (long)b.y + (long)a.z * (long)b.z); }
public static IInt3 Max(IInt3 a, IInt3 b) { return(new IInt3(System.Math.Max(a.x, b.x), System.Math.Max(a.y, b.y), System.Math.Max(a.z, b.z))); }