Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


distance

The distance between the closest points. This is calculated from _sqrDistance on each access, so prefer that when a squared distance will do.
Read time 1 minuteLast updated 12 days ago

Definition

  • Type: Property
  • Namespace: Unity.U2D.Physics
  • Assembly: UnityEngine.PhysicsCore2DModule
public float distance { get; }