/
GeekNerd
/
ServerModelingProject
Обзор
Документация
Войти
/
GeekNerd
/
ServerModelingProject
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
master
Assets/Plugins/Zenject/Source/Editor/EditorStaticInstaller.cs
29 строк
786 B
Gorney-Alex
Init
30 май 2026, 19:05
30 май 2026, 19:05
3cdcc49
Код
Авторство
О чём код?
namespace Zenject { // Derive from this class, add [InitializeOnLoad], and then call Install // in a static constructor to add some editor time bindings // For example: // // [InitializeOnLoad] // public class FooInstaller : EditorStaticInstaller<FooInstaller> // { // static FooInstaller() // { // Install(); // } // // public override void InstallBindings() // { // Container.BindInstance("hello world"); // } // } // public abstract class EditorStaticInstaller<T> : InstallerBase where T : EditorStaticInstaller<T> { public static void Install() { StaticContext.Container.Instantiate<T>().InstallBindings(); } } }