# VPS tracking only works on last added AR location

**URL:** <https://community.nianticspatial.com/t/vps-tracking-only-works-on-last-added-ar-location/4028>\
**Category:** I'm Stuck\
**Created:** [November 25, 2023, 1:14pm UTC](https://community.nianticspatial.com/t/vps-tracking-only-works-on-last-added-ar-location/4028 "2023-11-25T13:14:54Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Pavle](https://avatars.discourse-cdn.com/v4/letter/p/e68b1a/32.png) [@Pavle](https://community.nianticspatial.com/u/Pavle)\
**Post date:** [November 25, 2023, 1:14pm UTC](https://community.nianticspatial.com/t/vps-tracking-only-works-on-last-added-ar-location/4028/1 "2023-11-25T13:14:54Z")

</div>

_Include the following details (edit as applicable):_

- **Issue category** : Lightship Maps / Semantic Segmentation / Multiplayer / Real-time Mapping-Depth / ARDK Documentation / Unity Example Package / Sample App aka ‘AR Voyage’ / ARDK Virtual Studio Tools / Developer Tools / Networking / VPS / Scanning Framework
- **Device type & OS version** : Android / iOS / Other Ex. iPhone 8+ on iOS 13
- **Host machine & OS version** : Mac / Windows / Linux / Other Ex. Mac on Big Sur x.x
- **Issue Environment** : Unity Remote / Unity Mock / On Device / Dev Portal
- **Xcode version** :
- **ARDK version** : 3.0
- **Unity version** :

Description of the issue:  
I’m adding AR Locations as in docs, added several locations, however only the last location is tracked. Is it how the location tracking works? Is there a maximum number of tracked locations? I want multiple locations to be localizable in my project.

---

<div class="post-metadata">

**Author:** ![Stacy](https://avatars.discourse-cdn.com/v4/letter/s/e95f7d/32.png) [@Stacy](https://community.nianticspatial.com/u/Stacy)\
**Post date:** [November 29, 2023, 6:23pm UTC](https://community.nianticspatial.com/t/vps-tracking-only-works-on-last-added-ar-location/4028/2 "2023-11-29T18:23:39Z")

</div>

Hello Pavle,

Yes, the current setup allows you to track only one location at a time. You would need to manually switch between locations at this time. I will pass your interest in having multiple locations tracked to the team to consider in the future.

---

<div class="post-metadata">

**Author:** ![Pavle](https://avatars.discourse-cdn.com/v4/letter/p/e68b1a/32.png) [@Pavle](https://community.nianticspatial.com/u/Pavle)\
**Post date:** [November 29, 2023, 9:46pm UTC](https://community.nianticspatial.com/t/vps-tracking-only-works-on-last-added-ar-location/4028/3 "2023-11-29T21:46:52Z")

</div>

Thanks for the answer, Stacy!  
Is it possible to have, for example, 5 nearest locations that can be localized in the area and the one phone is pointing to be localized? I’m trying to make app that allows users to scan wayspots close to each other, so choosing only by it’s location which one user is trying to localize would be impossible.

---

<div class="post-metadata">

**Author:** ![Stacy](https://avatars.discourse-cdn.com/v4/letter/s/e95f7d/32.png) [@Stacy](https://community.nianticspatial.com/u/Stacy)\
**Post date:** [December 7, 2023, 12:05am UTC](https://community.nianticspatial.com/t/vps-tracking-only-works-on-last-added-ar-location/4028/4 "2023-12-07T00:05:31Z")

</div>

Hello Pavle,

You could either specify a location or have Lightship try to localize to the 5 nearest wayspots:

To specify a location, you just need to call `ARLocationManager.SetARLocations(<some_ARLocation>)`.

To try the 5 closest wayspots, just make sure you don’t make that call at all (so that `_targetARLocations` array in ARLocationManager is empty).

Whatever choice you pick will dictate how `StartTracking()` works, so do it before you call that.

You can test this in the RemoteAuthoring scene by adding any AR Location and commenting out line 47 in `PersistentARDemo.cs`. I hope this helps!

---

<div class="post-metadata">

**Author:** ![Maverick\_Niantic](https://avatars.discourse-cdn.com/v4/letter/m/8edcca/32.png) [@Maverick\_Niantic](https://community.nianticspatial.com/u/Maverick_Niantic)\
**Post date:** [March 5, 2026, 11:44pm UTC](https://community.nianticspatial.com/t/vps-tracking-only-works-on-last-added-ar-location/4028/5 "2026-03-05T23:44:36Z")

</div>

Age
