Exemple #1
0
        private void AddSpecialBatchCmd(object sender, ExecutedRoutedEventArgs e)
        {
            ProgressionEntry entry = navigation.SelectedItem as ProgressionEntry;

            entry.Children.Add(new ProgressionEntry()
            {
                ItemType = ProgressionTreeItemType.SpecialBatch
            });
        }
Exemple #2
0
        private void AddRegularItem(object sender, ExecutedRoutedEventArgs e)
        {
            ProgressionEntry entry = navigation.SelectedItem as ProgressionEntry;

            entry.Children.Add(new ProgressionEntry()
            {
                ItemType = ProgressionTreeItemType.RegularItem
            });
        }
Exemple #3
0
        private void CanAddSpecialBatch(object sender, CanExecuteRoutedEventArgs e)
        {
            ProgressionEntry entry = navigation.SelectedItem as ProgressionEntry;

            if (entry != null)
            {
                e.CanExecute = entry.ItemType == ProgressionTreeItemType.FullBatch;
            }
            else
            {
                e.CanExecute = false;
            }
        }
    void _Activate(ProgressionEntry a)
    {
        foreach (var g in a.EnableGameObjects)
        {
            g.SetActive(true);
        }
        foreach (var g in a.DisableGameObjects)
        {
            g.SetActive(false);
        }

        if (a.AudioSourceToPlay)
        {
            a.AudioSourceToPlay.Play();
        }
        if (a.AudioSourceToStop)
        {
            a.AudioSourceToStop.Stop();
        }
    }