/// <summary> /// Creates a new UIScreen instance. /// </summary> /// <param name="Manager">A ScreenManager instance.</param> /// <param name="Name">The name of this UIScreen instance.</param> /// <param name="SBatch">A SpriteBatch instance.</param> /// <param name="ScreenPosition">Position of this UIScreen instance.</param> /// <param name="ScreenSize">Size of this UIScreen instance.</param> /// <param name="UIScriptPath">Path of script (*.uis) from which to create UI elements.</param> public UIScreen(ScreenManager Manager, string Name, SpriteBatch SBatch, Vector2 ScreenPosition, Vector2 ScreenSize, string UIScriptPath = "") { m_Manager = Manager; m_SBatch = SBatch; Position = ScreenPosition; m_Size = ScreenSize; m_Walker = new TreeWalker(this); if (UIScriptPath != "") m_Walker.Initialize(UIScriptPath); }
/// <summary> /// Creates a new UIScreen instance. /// </summary> /// <param name="Manager">A ScreenManager instance.</param> /// <param name="Name">The name of this UIScreen instance.</param> /// <param name="SBatch">A SpriteBatch instance.</param> /// <param name="ScreenPosition">Position of this UIScreen instance.</param> /// <param name="ScreenSize">Size of this UIScreen instance.</param> /// <param name="UIScriptPath">Path of script (*.uis) from which to create UI elements.</param> public UIScreen(ScreenManager Manager, string Name, SpriteBatch SBatch, Vector2 ScreenPosition, Vector2 ScreenSize, string UIScriptPath = "") { m_Manager = Manager; m_SBatch = SBatch; Position = ScreenPosition; m_Size = ScreenSize; m_Walker = new TreeWalker(this); if (UIScriptPath != "") { m_Walker.Initialize(UIScriptPath, ref m_PResult); } }