本文整理汇总了C#中InputBox.LoadContent方法的典型用法代码示例。如果您正苦于以下问题:C# InputBox.LoadContent方法的具体用法?C# InputBox.LoadContent怎么用?C# InputBox.LoadContent使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类InputBox
的用法示例。
在下文中一共展示了InputBox.LoadContent方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: LoadContent
/// <summary>
/// Load initial game data and assets once.
/// </summary>
public override void LoadContent()
{
//TODO: Offload to initialize
ScreenManager.Game.IsMouseVisible = true;
spriteBatch = ScreenManager.SpriteBatch;
content = new ContentManager(ScreenManager.Game.Services, "Content");
//Load banner Image
//Load Instruction text (also error text)
textMessage = new TextBox(message,
new Vector2(this.ScreenManager.GraphicsDevice.Viewport.Width/2, 290), Color.Black);
textMessage.LoadContent(spriteBatch, ScreenManager.GraphicsDevice,
content);
//Load Input box
inputBox = new InputBox(new Vector2(390, 390), Color.Orange, 10);
inputBox.LoadContent(spriteBatch, ScreenManager.GraphicsDevice, content);
//Load Login Button
loginButton = new Button("Login", new Vector2(390, 500), Color.Aqua);
loginButton.LoadContent(spriteBatch, ScreenManager.GraphicsDevice,
content);
exitButton = new Button("Exit", new Vector2(510, 500), Color.PaleVioletRed);
exitButton.LoadContent(spriteBatch, ScreenManager.GraphicsDevice,
content);
//Load Exit Button
}