public void Wlacz(TRYB_TRENINGOWY t, MAGICZNE_ZAKLECIE magia) { this.tryb = t; this.magia = magia; if (magia != null) { magia.efekt_zaklecia(canvas1); } }
public void Wlacz(TRYB_TRENINGOWY t, bool wlacz_kinect, MAGICZNE_ZAKLECIE magia) { this.tryb = t; this.wlacz_kinect = wlacz_kinect; this.magia = magia; if (magia != null) { magia.efekt_zaklecia(canvas1); } tryb.wyswietl_liste_filmow(mediaElement1); muz = new MUZYKA(); muz.lista_odtwarzania(mediaElement2); czas_t = new Thread(czas_treningu); czas_t.Start(); watek_czas = true; media_active = true; }
private void button1_Click(object sender, RoutedEventArgs e) { if (kinect_active) { Thread.Sleep(100); kinectSensor.Stop(); foreach (var potentialSensor in KinectSensor.KinectSensors) { if (potentialSensor.Status == KinectStatus.Disconnected) { kinectSensor = null; break; } } this.kinectSensor.SkeletonFrameReady -= this.nui_SkeletonFrameReady; this.kinectSensor.SkeletonStream.Disable(); kinect_active = false; } for (int i = 0; i < 3; i++) { if (watek[i]) { t1.Abort(); } } TRYB_TRENINGOWY t = new TRYB_TRENINGOWY(); TrybKondycyjnyZestawCwiczen a = new TrybKondycyjnyZestawCwiczen(); a.Wlacz(t, magia); a.Show(); this.Close(); }