Last active
July 7, 2021 03:12
-
-
Save baba-s/3bfec070abb4255b165ef490990208a2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEditor; | |
using UnityEngine; | |
[InitializeOnLoad] | |
internal static class Example | |
{ | |
private static readonly Color COLOR = new Color32( 40, 40, 40, 255 ); | |
static Example() | |
{ | |
EditorApplication.hierarchyWindowItemOnGUI += OnGUI; | |
} | |
private static void OnGUI( int instanceID, Rect rect ) | |
{ | |
var xMax = rect.xMax; | |
rect.x = 32; | |
rect.xMax = xMax + 16; | |
rect.y += 15; | |
rect.height = 1; | |
EditorGUI.DrawRect( rect, COLOR ); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment