How to get Non-VPS enabled Wayspots

Hi !
So I was playing around with integration of VPS into my Map (looking at How-To, but had to do much changes since code was ARDS 2.5) and I managed to get it working… It works great when I start it in mock environment (my local Unity), problem is that when I run it on the phone, it doesn’t work, because none of Wayspots around me are VPS enabled (they are just standard Pogo/Ingress Wayspot that haven’t been VPS scanned yet). I checked that with Wayfarer app, I could see Wayspots until I turned on VPS function (then they all disaperaed).

My question is… Is there a way to get Wayspots that are not VPS enabled? If not, is this something that will be available in the future?

Kind regards,
Andy

Hi Andy, I am trying to achieve the same result, but I’m stuck at a lower level. How did you manage to load VPS spots onto your map? As you probably did, I’ve got stuck following the example on the doc, which is not updated to 3.0, rendering it totally unusable due to namespaces and libraries being different. Can you give me a hint or a lead?

@Melazeta Problem is that a lot of “using” namespaces have changed… I will share my script here, and that one acually works… If you run it in playmode you should get some result… In real world only if you have VPS enabled portals near.

using UnityEngine;
using Niantic.Lightship.Maps;
using Niantic.Lightship.AR.VpsCoverage;

using ArdkLatLng = Niantic.Lightship.AR.VpsCoverage.LatLng; 
using MapsLatLng = Niantic.Lightship.Maps.Core.Coordinates.LatLng;
using Niantic.Lightship.Maps.MapLayers.Components;

public class CoverageManager : MonoBehaviour
{
    [SerializeField]
    private LightshipMapView _mapView;

    private CoverageClient _coverageClient;

    [SerializeField]
    private int _queryRadius;

    [SerializeField]
    private LayerLineRenderer _areaBorder;
    
    // Start is called before the first frame update
    void Start() {
        _coverageClient =  CoverageClientFactory.Create();         
       this.RequestAreasAroundMapCenter();
    }

    // Update is called once per frame
    void Update() {
    }

    private ArdkLatLng ConvertArdkLatLng(MapsLatLng mapsLatLng) {
        return new ArdkLatLng(mapsLatLng.Latitude, mapsLatLng.Longitude);
    }

    private MapsLatLng ConvertMapsLatLng(ArdkLatLng ardkLatLng) {
        return new MapsLatLng(ardkLatLng.Latitude, ardkLatLng.Longitude);
    }

    private MapsLatLng[] ConvertMapsLatLng(ArdkLatLng[] ardkLatLng) {
        var results = new MapsLatLng[ardkLatLng.Length];
        for (int i = 0; i < results.Length; i++) {
            results[i] = ConvertMapsLatLng(ardkLatLng[i]);
        }

        return results;
    }

    public void RequestAreasAroundMapCenter() {
        var mapCenter = ConvertArdkLatLng(_mapView.MapCenter);
        _coverageClient.TryGetCoverageAreas(mapCenter, _queryRadius, OnAreasResult );
    }


    public void OnAreasResult(CoverageAreasResult areaResult) {
        if (areaResult.Status != ResponseStatus.Success) {
            return;
        }

        foreach (var area in areaResult.Areas) {
            var areaID = area.LocalizationTargetIdentifiers[0];
            _areaBorder.DrawLoop(ConvertMapsLatLng(area.Shape), areaID);
        }
    }

}

Hope this helps you.
Andy