当前位置: 首页>>代码示例>>C#>>正文


C# IScene.FinishedStartup方法代码示例

本文整理汇总了C#中IScene.FinishedStartup方法的典型用法代码示例。如果您正苦于以下问题:C# IScene.FinishedStartup方法的具体用法?C# IScene.FinishedStartup怎么用?C# IScene.FinishedStartup使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IScene的用法示例。


在下文中一共展示了IScene.FinishedStartup方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: StartNewRegion

        /// <summary>
        /// Execute the region creation process.  This includes setting up scene infrastructure.
        /// </summary>
        /// <param name="regionInfo"></param>
        /// <param name="portadd_flag"></param>
        /// <param name="do_post_init"></param>
        /// <returns></returns>
        public void StartNewRegion(IScene scene)
        {
            //Do this here so that we don't have issues later when startup complete messages start coming in
            m_localScenes.Add (scene);

            // set the initial ports
            scene.RegionInfo.HttpPort = MainServer.Instance.Port;

            StartModules (scene);

            //Start the heartbeats
            scene.StartHeartbeat();
            //Tell the scene that the startup is complete 
            // Note: this event is added in the scene constructor
            scene.FinishedStartup("Startup", new List<string>());
        }
开发者ID:NickyPerian,项目名称:Aurora-Sim,代码行数:23,代码来源:SceneManager.cs

示例2: StartRegion

        public void StartRegion(out bool newRegion)
        {
            RegionInfo regionInfo = m_simulationDataService.LoadRegionInfo(m_OpenSimBase, out newRegion);
            MainConsole.Instance.InfoFormat("[SceneManager]: Starting region \"{0}\" at @ {1},{2}",
                                            regionInfo.RegionName,
                                            regionInfo.RegionLocX/256, regionInfo.RegionLocY/256);
            ISceneLoader sceneLoader = m_OpenSimBase.ApplicationRegistry.RequestModuleInterface<ISceneLoader>();
            if (sceneLoader == null)
                throw new Exception("No Scene Loader Interface!");

            //Get the new scene from the interface
            m_scene = sceneLoader.CreateScene(regionInfo);

            MainConsole.Instance.ConsoleScene = m_scene;
            m_simulationDataService.SetRegion(m_scene);

            if (OnAddedScene != null)
                OnAddedScene(m_scene);

            StartModules(m_scene);

            if (OnFinishedAddingScene != null)
                OnFinishedAddingScene(m_scene);

            //Start the heartbeats
            m_scene.StartHeartbeat();
            //Tell the scene that the startup is complete 
            // Note: this event is added in the scene constructor
            m_scene.FinishedStartup("Startup", new List<string>());
        }
开发者ID:velus,项目名称:Async-Sim-Testing,代码行数:30,代码来源:SceneManager.cs


注:本文中的IScene.FinishedStartup方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。