This repository contains a collection of helpful runtime and editor classes for Unity.
It can be installed from Unity's Package Manager using the following Git URL:
It can also be installed by cloning this repository into a Unity project's Packages/
folder. This will allow for changes to be made to the package, but updates will need to be done manually using Git instead of Unity's Package Manager.
Documentation for these classes can be found below and in various articles on HextantStudios.com.
A ScriptableObject
-based singleton that can be used for GUI-less editor plug-ins. By deriving from ScriptableObject
, non-static fields are persisted between script recompiles (domain reloads).
- See Singletons in Unity for additional details and several runtime implementations.
This editor plug-in derives from the EditorSingleton
class allowing it to maintain a small history of recently selected objects that can be moved backward or forward through by pressing F1
and Shift+F1
(customize in Edit/Shortcuts).
- See Selection History for Unity's Editor for additional details.
This simple plug-in for Unity's Editor logs how long it takes to compile script changes and perform domain reloads to quickly spot potential issues that can affect iteration times.
- See Log Compile Times in Unity's Editor for additional details.
A ScriptableObject
-based singleton that can be used to store project-wide or user-specific settings for editor plug-ins or project-wide settings for use at runtime. Settings can be easily exposed to the Edit/Preferences and Edit/Project Settings dialogs or modified manually by plug-ins.
Notes:
-
The derived settings class must be placed in a file with the same name as the class (
ScriptableObject
requirement). -
The user settings folder
Assets/Settings/Editor/User/
should be excluded from source control.