using RebootKit.Engine.Foundation; using UnityEngine; namespace RebootKit.Engine { public class MainSceneInstaller : SceneDependencyInstaller { public override void Install(DIContext context) { foreach (GameObject rootGameObject in gameObject.scene.GetRootGameObjects()) { IService[] services = rootGameObject.GetComponentsInParent(); foreach (IService service in services) { context.Bind(service.GetType(), service); } } } } }