コード例 #1
0
        private void Start()
        {
            _graph = UnityUtility.FindParent <Graph>(this);

            _filterListener = UnityUtility.FindParent <GraphFilterListener>(this);
            if (_filterListener)
            {
                _filterListener.OnFilterUpdate += OnFilterUpdate;
                OnFilterUpdate();
            }

            _rotationAnimation.Init(Quaternion.identity);
            _colorAnimation.Init(new Color32(255, 255, 255, 0));
            StartCoroutine(RunUpdates());
        }
コード例 #2
0
ファイル: GraphPosition.cs プロジェクト: SebiH/ART
        public void Init(float pos, float height, float offset)
        {
            _position = pos;
            _positionAnimation.Init(_position);

            _height = height;
            _heightAnimation.Init(_height);

            _offset = offset;
            _offsetAnimation.Init(_offset);

            var rotation = Quaternion.Euler(0, 90, 0);

            _rotationAnimation.Init(rotation);

            transform.localPosition = new Vector3(_position, _height, _offset);
            transform.localRotation = rotation;
        }