Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice

Handles.Label - No example in C#

Discussion in 'Documentation' started by Uber6, Jul 6, 2015.

  1. Uber6

    Uber6

    Joined:
    Sep 30, 2013
    Posts:
    25
  2. aleks_unity

    aleks_unity

    Unity tech writer/programmer

    Joined:
    Jan 12, 2012
    Posts:
    25
    Thank you for reporting this. We have made a bug and it will be addressed.
     
  3. Uber6

    Uber6

    Joined:
    Sep 30, 2013
    Posts:
    25
    What I ended up doing is this (in a MonoBehaviour derived script, not Editor derived):

    Code (CSharp):
    1. #if UNITY_EDITOR
    2. void OnDrawGizmos()
    3. {
    4.      Handles.Label(transform.position, myString);
    5. }
    6. #endif
     
    Last edited: Jul 7, 2015