Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


transform

The Transform of the object we hit (Read Only).
Read time 1 minuteLast updated 6 days ago

Definition

  • Type: Property
  • Namespace: UnityEngine
  • Assembly: UnityEngine.PhysicsModule
public Transform transform { get; }

Remarks

If we collided against a collider with a Rigidbody, the transform will be the transform attached to the rigidbody. If we collided against a collider without a rigidbody, the transform will be the transform attached to the collider.