| | |
| | | void OnMouseMoved(PointerInfo pointer) |
| | | { |
| | | // We only respond to mouse info |
| | | var mouseInfo = pointer as MouseCursorInfo; |
| | | // var mouseInfo = pointer as MouseCursorInfo; |
| | | |
| | | if ((mouseInfo != null) && (m_GameUI.isBuilding)) |
| | | { |
| | | m_GameUI.TryMoveGhost(pointer, false); |
| | | } |
| | | // if ((mouseInfo != null) && (m_GameUI.isBuilding)) |
| | | // { |
| | | // m_GameUI.TryMoveGhost(pointer, false); |
| | | // } |
| | | } |
| | | |
| | | float currentTimeScale = 1.0f; |
| | | float dragTime = 0; |
| | | bool isDraging = false; |
| | | |
| | | |
| | | protected virtual void OnStartDrag(PointerActionInfo pointer) |
| | | { |
| | | if (!isDraging) |
| | |
| | | |
| | | this.isInDragState = true; |
| | | AudioSourceManager.Ins.Play(AudioEnum.DragTower); |
| | | m_GameUI.CheckAllCanPlace();//检查上阵宝石有么有可以合成的位置 |
| | | //m_GameUI.CheckAllCanPlace();//检查上阵宝石有么有可以合成的位置 |
| | | |
| | | if (!GameConfig.IsNewbie) |
| | | { |
| | |
| | | if (isDraging && (pointer != null) && (m_GameUI.isBuilding)) |
| | | { |
| | | m_GameUI.TryMoveGhost(pointer, false); |
| | | //m_GameUI.CheckTowerPlace(pointer); |
| | | m_GameUI.CheckTowerPlaceNew(pointer); |
| | | |
| | | m_GameUI.CheckTowerPlace(pointer); |
| | | } |
| | | } |
| | | |