EchoTrio
 
Loading...
Searching...
No Matches
ActorConfigEditor.cs
Go to the documentation of this file.
1using UnityEditor;
2using UnityEngine;
3
4namespace EchoTrio {
5 [CustomEditor(typeof(ActorConfig))]
6 public class ActorConfigEditor : Editor {
7 public override void OnInspectorGUI() {
8 base.OnInspectorGUI();
9
10 ActorConfig actorConfig = (ActorConfig)target;
11
12 EditorGUILayout.LabelField("Combined Instructions", EditorStyles.boldLabel);
13 string combinedInstructions = actorConfig.GetInstructions();
14 EditorGUILayout.LabelField(combinedInstructions, new UnityEngine.GUILayoutOption[] {
15 GUILayout.MinWidth(GUI.skin.label.CalcSize(new GUIContent(combinedInstructions)).x),
16 GUILayout.MinHeight(GUI.skin.label.CalcSize(new GUIContent(combinedInstructions)).y),
17 });
18 }
19 }
20}
override void OnInspectorGUI()
string GetInstructions()
Definition: ActorConfig.cs:53