Join Jesse Freeman for an in-depth discussion in this video Modify the layout of a custom editor, part of Building Custom Tools to Extend the Unity IDE.
- [Voiceover] Now that we've covered the basics…of creating input fields and buttons,…let's talk a little bit about layout…inside of our Inspector.…Let's open up our HelloWorldEditor,…and take a look at our button.…Right now, we're using the GUILayout.…Previously, we were using…the EditorGUILayout class as well.…Some of these components existed…from the previous GUI system in Unity.…Editor's specific UI, such as the slider…and the object field, exist in the EditorGUILayout class.…
The GUILayout class will contain things…like buttons and labels and other things…that were exposed in the old GUI system.…There's one other way that we can actually layout elements,…and that's by explicitly stating where they go…inside of the Window itself.…If we go ahead and change GUILayout…to simply say GUI and call the button,…we can now pass in a Rect that'll define the position…and the size of where the button should go.…
Let's create a new Rect, and inside of it,…we'll set the X and Y to zero,…and the width and height to 100.…The second parameter we'll leave the same for Click Me,…
- Exposing variables to the Inspector
- Providing attributes to Inspector fields
- Extending the base editor
- Creating custom UI elements
- Modifying the layout of a custom editor
- Building a custom window
- Saving and loading data
- Creating a reorderable list
- Skinning custom inspectors
- Exporting assets as Unity packages
Skill Level Intermediate
Unity 5: 2D Essential Training (2015)with Jesse Freeman3h 22m Intermediate
Unity 5: 2D Generate Procedural Terrainwith Dan Violet Sagmiller4h 4m Intermediate
1. Introduction to the Inspector
2. Build Custom Editors in Unity
3. Create Custom UI Elements in Unity
4. Build a Custom Window in Unity
5. Saving and Loading Data in Unity
6. Advanced UI
7. Skinning Custom Inspectors
8. Export Custom Code
Code organization4m 35s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.