/// <summary> /// Allows the game to perform any initialization it needs to before starting to run. /// This is where it can query for any required services and attackLoad any non-graphic /// related content. Calling base.Initialize will enumerate through any components /// and initialize them as well. /// </summary> protected override void Initialize() { // TODO: Add your initialization logic here base.Initialize(); GameEnigine.Init(); }
public Game1() { graphics = new GraphicsDeviceManager(this); Content.RootDirectory = "Content"; ArrayList objects = new ArrayList() { this, graphics, Content, GraphicsDevice, GraphicsDevice }; GameEnigine.InitGameEngine(objects); }
/// <summary> /// LoadContent will be called once per game and is the place to attackLoad /// all of your content. /// </summary> protected override void LoadContent() { spriteBatch = new SpriteBatch(GraphicsDevice); GameEnigine.loadContent(spriteBatch); // TODO: use this.Content to attackLoad your game content here }
/// <summary> /// This is called when the game should draw itself. /// </summary> /// <param name="gameTime">Provides a snapshot of timing values.</param> protected override void Draw(GameTime gameTime) { GraphicsDevice.Clear(Color.CornflowerBlue); // TODO: Add your drawing code here GameEnigine.render(gameTime); base.Draw(gameTime); }
/// <summary> /// Allows the game to run logic such as updating the world, /// checking for collisions, gathering input, and playing audio. /// </summary> /// <param name="gameTime">Provides a snapshot of timing values.</param> protected override void Update(GameTime gameTime) { // Allows the game to exit if (GamePad.GetState(PlayerIndex.One).Buttons.Back == ButtonState.Pressed) { this.Exit(); } // TODO: Add your update logic here GameEnigine.Input(); GameEnigine.update(gameTime); base.Update(gameTime); }