Esempio n. 1
0
 public Tank(GameHost game)
     : base(game)
 {
     // Set the default scale and color
     ScaleX = 1;
     ScaleY = 1;
     SpriteColor = Color.White;
 }
 //-------------------------------------------------------------------------------------
 // Class constructors
 /// <summary>
 /// Constructor for the object
 /// </summary>
 /// <param name="game">A reference to the MonoGame Game class inside which the object resides</param>
 public GameObjectBase(GameHost game)
 {
     // Store a reference to the game
     Game = game;
 }
Esempio n. 3
0
 public Tank(GameHost game, Vector2 position, Texture2D texture)
     : this(game, position)
 {
     // Store the provided texture
     SpriteTexture = texture;
 }
Esempio n. 4
0
 public Tank(GameHost game, Vector2 position)
     : this(game)
 {
     // Store the provided position
     Position = position;
 }
 //-------------------------------------------------------------------------------------
 // Class constructors
 public BenchmarkObject(GameHost game, SpriteFont font, Vector2 position, Color textColor)
     : base(game, font, position)
 {
     SpriteColor = textColor;
 }