本文整理汇总了C#中Game1.Run方法的典型用法代码示例。如果您正苦于以下问题:C# Game1.Run方法的具体用法?C# Game1.Run怎么用?C# Game1.Run使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Game1
的用法示例。
在下文中一共展示了Game1.Run方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Main
/// <summary>
/// The main entry point for the application.
/// </summary>
static void Main(string[] args)
{
string levelFile = "";
if (args.Length > 0)
{
levelFile = @"" + args[0];
}
else
{
levelFile = "level1.xml";
}
if (levelFile.Length > 0)
{
using (Game1 game = new Game1(levelFile))
{
game.Run();
}
}
}
示例2: Main
/// <summary>
/// The main entry point for the application.
/// </summary>
static void Main(string[] args)
{
using (Game1 game = new Game1())
{
game.Run();
}
}
示例3: Main
/// <summary>
/// The main entry point for the application.
/// </summary>
static void Main()
{
using (var game = new Game1())
{
game.Run();
}
}
示例4: Main
// ReSharper restore UnusedParameter.Local
/// <summary>
/// The main entry point for the application.
/// </summary>
// ReSharper disable UnusedParameter.Local
private static void Main(string[] args)
{
using (var game = new Game1())
{
game.Run();
}
}
示例5: Main
/// <summary>
/// The main entry point for the application.
/// </summary>
static void Main(string[] args)
{
int width = 600, height = 600;
bool inv = false;
if (args.Length >= 1)
{
int offset = 0;
if (args[0] == "white" || args[0] == "black")
{
inv = args[0] == "white";
offset++;
}
if (args.Length >= 2)
{
width = height = int.Parse(args[1]);
if (args.Length >= 3)
height = int.Parse(args[2]);
}
}
using (Game1 game = new Game1(inv, width, height))
{
game.Run();
}
}
示例6: bStart_Click
private void bStart_Click(object sender, EventArgs e)
{
//Begin a new game
ServerEngine si = new ServerEngine(int.Parse(tbPort.Text), 8/*TODO : change*/);
Game1 game = new Game1(si);
game.Run();
}
示例7: btnPlay_Click
private void btnPlay_Click(object sender, EventArgs e)
{
this.Hide();
DatabaseConnector.GetSettings(Login.PlayerId);
using (var game = new Game1())
game.Run();
}
示例8: Main
/// <summary>
/// The main entry point for the application.
/// </summary>
/// <param name="args">Have to be there</param>
public static void Main(string[] args)
{
Game1 game;
using (game = new Game1())
{
game.Run();
}
}
示例9: OnCreate
protected override void OnCreate (Bundle bundle)
{
base.OnCreate (bundle);
var g = new Game1 ();
SetContentView (g.Services.GetService<View> ());
g.Run ();
}
示例10: Main
/// <summary>
/// The main entry point for the application.
/// </summary>
static void Main(string[] args)
{
CommandLineArguments options = CommandLineArguments.Parse(args);
using (Game1 game = new Game1(options.Host, options.Port))
{
game.Run();
}
}
示例11: OnCreate
protected override void OnCreate (Bundle bundle)
{
base.OnCreate (bundle);
var g = new Game1();
SetContentView((View)g.Services.GetService(typeof(View)));
g.Run();
}
示例12: OnCreate
protected override void OnCreate (Bundle bundle)
{
base.OnCreate (bundle);
// Create our OpenGL view, and display it
var g = new Game1 ();
SetContentView((View)g.Services.GetService(typeof(View)));
g.Run ();
}
示例13: Main
/// <summary>
/// The main entry point for the application.
/// </summary>
public static void Main(string[] args)
{
{
using (var game = new Game1())
{
game.Run();
}
}
}
示例14: Main
static void Main(string[] args)
{
using (Game1 game = new Game1())
{
Application.EnableVisualStyles();
Application.Run(new Login.Form1());
game.Run();
}
}
示例15: OnCreate
protected override void OnCreate(Bundle bundle)
{
base.OnCreate (bundle);
// Create our OpenGL view, and display it
Game1.Activity = this;
var g = new Game1 ();
SetContentView (g.Window);
g.Run ();
}