public void SelectDrone(ClientDrone drone)
        {
            _selectedDrone = drone;
            _canvas.SetActiveDrone(drone);

            SelectedDroneChanged?.Invoke(drone);
        }
Exemplo n.º 2
0
 private void OnSelectedDroneChanged(ClientDrone selected)
 {
     if (this == selected)
     {
         _display.sharedMaterial = _selectedMaterial;
     }
     else
     {
         _display.sharedMaterial = IsOwned ? _playerMaterial : _defaultMaterial;
     }
 }
Exemplo n.º 3
0
        public void SetActiveDrone(ClientDrone drone)
        {
            _droneText.gameObject.SetActive(true);

            if (drone.IsOwned)
            {
                _droneText.text = $"Your drone";
            }
            else
            {
                _droneText.text = $"Drone belonging to {drone.Owner}";
            }
        }