OnDrawGizmos function

The last function is an optional visual aid used primarily for debugging. Gizmos are very useful for visualizing vector information. In this case, we are using a red GizmoDrawLine to illustrate the direction of the hit ray:

  • Save the script and return to Unity.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.147.54.6