/// <summary> /// The main entry point for the application. /// </summary> static void Main(string[] args) { using (Game1 game = new Game1()) { game.Run(); } }
public HUD(Game game, SpriteFont font) : base(game) { // TODO: Construct any child components here this.game = game as Game1; fn = font; }
private char[] separator = { ' ' }; // consts and arrays are bugging me - grr #endregion Fields #region Constructors public Dispatcher(Game game) : base(game) { this.game = (Game1)game; // I guess this might not be conventional style? // but game.whatever seems easier than typing ((Game1)Game).whatever all the damn time rand = new Random(); // TODO: Construct any child components here // pfft, as if. }
public SkyBox(Game game) : base(game) { this.game = (Game1)game; }
public MainMenu(Game game) : base(game) { // TODO: Construct any child components here this.game = (Game1)game; // frightening up-cast }
public Game1() { graphics = new GraphicsDeviceManager(this); screen = new Stack<gameScreen>(42); // new state stack with more than enough space for all game screens Content.RootDirectory = "Content"; main_instance = this; }