public void ShootLaser(LaserCollection lasers) { int laserX = X + Width / 2; int laserY = Y - Height; Laser laser = new Laser(laserX, laserY, lasers); laser.DisplayOn(canvas); }
private void gameCanvas_MouseUp(object sender, MouseButtonEventArgs e) { int x = user.X + user.Width / 2; int y = user.Y - user.Height; Laser laser = new Laser(x, y, lasers); laser.DisplayOn(gameCanvas); }