public override void Render() { SwinGame.FillRectangle(SwinGame.ColorTeal(), X, Y, _width, _height); SwinGame.DrawText(_weapon.Name, SwinGame.ColorBlack(), X, Y + _height / 2); if (GameMain.DEBUG) { SwinGame.DrawRectangle(SwinGame.ColorWhite(), CollisionBox.X, CollisionBox.Y, CollisionBox.Height, CollisionBox.Width); } }
public override void Render() { SwinGame.DrawBitmap(Sprite, X, Y); if (GameMain.DEBUG) { SwinGame.DrawRectangle(SwinGame.ColorWhite(), CollisionBox.X, CollisionBox.Y, CollisionBox.Width, CollisionBox.Height); } }
public void TestCase() { Drawing drawing = new Drawing(); Assert.AreEqual(SwinGame.ColorWhite(), drawing.Colour); Drawing drawing2 = new Drawing(SwinGame.ColorRed()); Assert.AreEqual(SwinGame.ColorRed(), drawing2.Colour); }
public void DisplayGame(GameData game) { SwinGame.ClearScreen(SwinGame.ColorWhite()); SwinGame.DrawBitmap("background", 0, 0); game.ply.drawPlayer(); game.bl.drawBall(game.ball); game.blk.DrawBlocks(game); game.itm.drawItem(game); SwinGame.DrawText("Score: " + game.ply.player.score.ToString() + " Lives: " + game.ply.player.lives.ToString(), SwinGame.ColorBlack(), 0, 0); SwinGame.RefreshScreen(60); }
public Drawing() : this(SwinGame.ColorWhite()) { // Uses constructor initializer if not parameters entered. }