本文整理汇总了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>());
}
示例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>());
}