public void DrawTriangle(JVector pos1, JVector pos2, JVector pos3) { if ((Camera.current.transform.position - pos1.ToVector3()).sqrMagnitude > 625) { return; } Gizmos.DrawLine(pos1.ToVector3(), pos2.ToVector3()); Gizmos.DrawLine(pos2.ToVector3(), pos3.ToVector3()); Gizmos.DrawLine(pos3.ToVector3(), pos1.ToVector3()); }
private void CollisionDetected(JRigidbody body1, JRigidbody body2, JVector point1, JVector point2, JVector normal, float penetration) { var b1 = body1 as Collider.Rigidbody; var b2 = body2 as Collider.Rigidbody; b1.collider.CollisionDetected(b2.collider, point1.ToVector3()); b2.collider.CollisionDetected(b1.collider, point2.ToVector3()); }
public void DrawLine(JVector start, JVector end) { Gizmos.DrawLine(start.ToVector3(), end.ToVector3()); }