//clear canvas private void btnClear_Click(object sender, RoutedEventArgs e) { stepThrough = new StepThrough(); instance.Reset(); dGridDist.ItemsSource = stepThrough.Distances; canvas.Children.Clear(); lblDist.Content = ""; lblPath.Content = ""; foreach (Cave cv in instance.Caves) { DrawCirle(cv.CoordinateX, maxY - cv.CoordinateY, cv.Number); } }
// Start is called before the first frame update void Start() { Debug.Log(parts.Length); if (instance == null) { instance = this; } foreach (GameObject go in parts) { go.SetActive(false); } SetStep(); //Debug.Log("width: " + width.ToString("F5")); }