public void OnValidate()
        {
            switch (ControllerType)
            {
            case LocationControllerType.Debug:
                locationController = new DebugLocationController();
                break;

            case LocationControllerType.GPS:
                if (PlayerComponent != null)
                {
                    locationController = new GpsLocationController(PlayerComponent.Player);
                }
                break;
            }
        }
Example #2
0
 public LocationService()
 {
     _locationController = LocationController.Instance;
 }