Beyond_Beyaan.Screens.ColonizeScreen.MouseDown C# (CSharp) Метод

MouseDown() публичный Метод

public MouseDown ( int x, int y ) : bool
x int
y int
Результат bool
        public override bool MouseDown(int x, int y)
        {
            if (!_colonizing)
            {
                for (int i = 0; i < _maxShips; i++)
                {
                    _shipButtons[i].MouseDown(x, y);
                }
                _cancelButton.MouseDown(x, y);
                _colonizeButton.MouseDown(x, y);
            }
            else if (_showingText)
            {
                _nameTextBox.MouseDown(x, y);
            }
            return false;
        }

Usage Example

 public void MouseDown(int x, int y, int whichButton)
 {
     if (whichButton != 1)
     {
         return;
     }
     if (_colonizableFleetsThisTurn.Count > 0)
     {
         _colonizeScreen.MouseDown(x, y);
     }
     if (_newResearchTopicsNeeded.Count > 0)
     {
         _researchPrompt.MouseDown(x, y);
     }
 }