public void Awake()
 {
     _lineCircle = GetComponent <LineCircle>();
     if (_lineCircle == null)
     {
         Debug.LogError("PatternOscillatorAnimator couldn't find attached LineCircle component! Disabling.");
         enabled = false;
         return;
     }
 }
Ejemplo n.º 2
0
        public void OnEnable()
        {
            _camera     = FindObjectOfType <Camera>();
            _lineCircle = GetComponent <LineCircle>();
            if (_lineCircle == null)
            {
                Debug.LogError("SnapToBounds didn't find attached LineCircle component! Disabling.");
                enabled = false;
                return;
            }

            _lineCircle.OnPatternChanged += HandlePatternChange;
        }
        public void OnEnable()
        {
            _lineCircle = GetComponent <LineCircle>();
            if (_lineCircle == null)
            {
                Debug.LogError("TimeStepper couldn't find an attached LineCircle component! Disabling.");
                enabled = false;
                return;
            }
            _lineCircle.OnPatternChanged += HandleNewPattern;

            _shuffler    = GetComponent <Shuffler>();
            _hasShuffler = _shuffler != null;
        }
Ejemplo n.º 4
0
 private void Awake()
 {
     _lineCircle = GetComponent <LineCircle>();
     if (_lineCircle == null)
     {
         Debug.LogError("PatternOverrides couldn't find LineCircle component! Disabling.");
         return;
     }
     LineInterval   = _lineCircle.Pattern.LineInterval;
     TimeStep       = _lineCircle.Pattern.TimeStep;
     DrawLines      = _lineCircle.Pattern.DrawLines;
     LineOpacity    = _lineCircle.Pattern.LineColor.a;
     DrawFill       = _lineCircle.Pattern.DrawFill;
     FillOpacity    = _lineCircle.Pattern.FillColor.a;
     AutoScaleLines = _lineCircle.Pattern.AutoScaleLines;
     TimeToZ        = _lineCircle.Pattern.TimeToZ;
     ZFade          = _lineCircle.Pattern.ZFade;
 }
Ejemplo n.º 5
0
        private void OnEnable()
        {
            Generator.Count = Mathf.CeilToInt(AutoShufflePeriod * 100f);

            Memory = new PatternMemory();
            Memory.Patterns.Add(Generator.GenerateNewPattern());
            Memory.CurrentPosition = Memory.Patterns.Count - 1;

            _lineCircle = GetComponent <LineCircle>();
            if (_lineCircle == null)
            {
                Debug.LogError("Shuffler couldn't find an attached LineCircle component! Disabling.");
                enabled = false;
                return;
            }

            _lineCircle.SetPattern(new LineCirclePattern(Memory.Patterns[Memory.CurrentPosition])
            {
                TimeSpan = StartTimeSpan
            });
        }
 public void Awake()
 {
     _lineCircle = GetComponent <LineCircle>();
 }