/
GeekNerd
/
ServerModelingProject
Обзор
Документация
Войти
/
GeekNerd
/
ServerModelingProject
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
master
Assets/Plugins/Zenject/Source/Providers/GameObjectProviders/EmptyGameObjectProvider.cs
51 строка
1 KB
Gorney-Alex
Init
30 май 2026, 19:05
30 май 2026, 19:05
3cdcc49
Код
Авторство
О чём код?
#if !NOT_UNITY3D using System; using System.Collections.Generic; using ModestTree; using UnityEngine; namespace Zenject { [NoReflectionBaking] public class EmptyGameObjectProvider : IProvider { readonly DiContainer _container; readonly GameObjectCreationParameters _gameObjectBindInfo; public EmptyGameObjectProvider( DiContainer container, GameObjectCreationParameters gameObjectBindInfo) { _gameObjectBindInfo = gameObjectBindInfo; _container = container; } public bool IsCached { get { return false; } } public bool TypeVariesBasedOnMemberType { get { return false; } } public Type GetInstanceType(InjectContext context) { return typeof(GameObject); } public void GetAllInstancesWithInjectSplit( InjectContext context, List<TypeValuePair> args, out Action injectAction, List<object> buffer) { Assert.IsEmpty(args); injectAction = null; var gameObj = _container.CreateEmptyGameObject(_gameObjectBindInfo, context); buffer.Add(gameObj); } } } #endif