コード例 #1
0
        private void Update()
        {
            IsoTile _selecedTile = TouchUtility.GetTile(eventType, Cam, exceptionList);

            _selecedTile = FindTopTile(_selecedTile);

            FromTile_Select(_selecedTile);
            FromTile_UnSelectTile();

            UpdateCameraDrag();
        }
コード例 #2
0
        void GhostTile_Update()
        {
            Vector3 position;

            if (toTile != null)
            {
                position = toTile.transform.position;
            }
            else if (!TouchUtility.Raycast_Plane(Cam, Input.mousePosition,
                                                 new Plane(Vector3.down, fromTile.transform.position.y), out position))
            {
                return;
            }

            GhostTile_Update(position);
        }
コード例 #3
0
        void ToTile_Set()
        {
            var newTarget = TouchUtility.GetTile_ScreenPos(Cam, Input.mousePosition, exceptionList);

            newTarget = FindTopTile(newTarget);

            if (newTarget != toTile)
            {
                ToTile_Reset();
                toTile = newTarget;
                if (toTile != null && toTile != fromTile)
                {
                    ColoredObject.Start(toTile.gameObject, destinationGradient);
                }
            }

            GhostTile_Update();
        }