/// @param localDirector /// The local director owner of the Controller /// @param view /// The view of the scene /// @param cameraController /// The camera controller /// public LevelEditorController(LocalDirector localDirector, LevelEditorView view) : base(localDirector, view) { m_view = view; m_popupService = GlobalDirector.Service <PopupService>(); m_levelService = GlobalDirector.Service <LevelService>(); m_levelLoader = GlobalDirector.Service <MetadataService>().GetLoader <LevelData>() as LevelDataLoader; m_fsm.RegisterStateCallback(k_stateInit, EnterStateInit, null, null); m_fsm.RegisterStateCallback(k_stateLoad, EnterStateLoad, null, null); m_fsm.RegisterStateCallback(k_stateIdle, EnterStateIdle, null, ExitStateIdle); m_fsm.ExecuteAction(k_actionNext); }
/// Used to complete the initialisation in case the service depends /// on other Services /// public override void OnCompleteInitialisation() { m_sceneService = GlobalDirector.Service <SceneService>(); m_levelLoader = GlobalDirector.Service <MetadataService>().GetLoader <LevelData>() as LevelDataLoader; this.RegisterCaching(); }