Exemplo n.º 1
0
 void GameOver_Loaded(object sender, RoutedEventArgs e)
 {
     sbRock.Completed            += new EventHandler(sbRock_Completed);
     tbAgain.MouseLeftButtonDown += new MouseButtonEventHandler(tbAgain_MouseLeftButtonDown);
     tbAgain.MouseEnter          += new MouseEventHandler(tbAgain_MouseEnter);
     ms = new MouseSound("Sound/click.mp3");
 }
Exemplo n.º 2
0
 public MainPage()
 {
     InitializeComponent();
     MouseMove += new MouseEventHandler(MainPage_MouseMove);
     MouseLeftButtonDown += new MouseButtonEventHandler(MainPage_MouseLeftButtonDown);
     MouseLeftButtonUp += new MouseButtonEventHandler(MainPage_MouseLeftButtonUp);
     Cursor = Cursors.None;
     Instance = this;
     msAttack = new MouseSound("Sound/attack.mp3");
 }
Exemplo n.º 3
0
 public MainPage()
 {
     InitializeComponent();
     MouseMove           += new MouseEventHandler(MainPage_MouseMove);
     MouseLeftButtonDown += new MouseButtonEventHandler(MainPage_MouseLeftButtonDown);
     MouseLeftButtonUp   += new MouseButtonEventHandler(MainPage_MouseLeftButtonUp);
     Cursor   = Cursors.None;
     Instance = this;
     msAttack = new MouseSound("Sound/attack.mp3");
 }
Exemplo n.º 4
0
 void GameMain_Loaded(object sender, RoutedEventArgs e)
 {
     gameLoop.Tick    += new EventHandler(gameLoop_Tick);
     gameLoop.Interval = TimeSpan.FromMilliseconds(currentSpeed);
     //gameLoop.Start();
     foreach (var uie in gridHoles.Children)
     {
         if (uie is Hole)
         {
             var oneHole = uie as Hole;
             holes.Add(oneHole);
             oneHole.mouse.EvInjured += new Action(mouse_EvInjured);
         }
     }
     msInjured = new MouseSound("Sound/injured.mp3");
 }
Exemplo n.º 5
0
 void GameMain_Loaded(object sender, RoutedEventArgs e)
 {
     gameLoop.Tick += new EventHandler(gameLoop_Tick);
     gameLoop.Interval = TimeSpan.FromMilliseconds(currentSpeed);
     //gameLoop.Start();
     foreach (var uie in gridHoles.Children)
     {
         if (uie is Hole)
         {
             var oneHole = uie as Hole;
             holes.Add(oneHole);
             oneHole.mouse.EvInjured += new Action(mouse_EvInjured);
         }
     }
     msInjured = new MouseSound("Sound/injured.mp3");
 }