Archon.SwissArmyLib.Utils Namespace |
Class | Description | |
---|---|---|
BetterTime |
A simple wrapper for Unity's Time that caches values to avoid the marshal overhead of each call.
The performance benefit is very small, but completely free.
Only readonly Time properties (except for FixedDeltaTime) are cached, but everything is wrapped anyway so you don't have to use multiple time classes.
Since this is just a wrapper just refer to Unity's documentation about what each property does.
| |
ColorUtils |
Utility methods for Color.
| |
LazyT |
Provides support for lazy initialization.
If you're on .NET 4.0 or higher you might want to use System.Lazy instead.
| |
ServiceLocator |
A (somewhat) simple implementation of the service locator pattern.
The ServiceLocator knows about MonoBehaviours and how to work with them.
Creating scene-specific resolvers that only live as long as their respective scene is also supported.
Remarks
Please note that when you load a new scene, the MonoBehaviours in that scene will have their Awake()
method called before their scene becomes the active one. This means you can't rely on
SceneManager.GetActiveScene() to return the scene they're in, so you might want to use GameObject.scene
to specify which scene to register the resolver for.
|
Enumeration | Description | |
---|---|---|
UpdateLoop |
Unity's update loops.
|