Пример #1
0
    public void OnCellClick(Vector3Int position)
    {
        if (_trapActivated != null)
        {
            _trapActivated.DisactiveMenu();
        }
        var trap = m_traps.FirstOrDefault((c) => c.Position.Equals(Helper.ToVector2Int(position)));

        if (trap != null)
        {
            trap.ActivateMenu();
            _trapActivated = trap;
        }
    }