Unity Assets from Kronnect

World Map Strategy Kit => Support => Topic started by: nalincy on May 11, 2019, 09:29:35 AM

Title: World Map 2D Lite Edition - using with unity and vuforia
Post by: nalincy on May 11, 2019, 09:29:35 AM
Hello!
I am trying to make an AR application using unity and vuforia. I am thinking to use World Map 2D Lite Edition to show world map on a scene with some selection of countries. As per the instructions from World Map 2D Lite Edition, I dragged the prefab “WorldMap2D” from “Resources/Prefabs” folder to my scene.
I am getting two errors,

1. NullReferenceException: Object reference not set to an instance of an object
WPMF.CityScaler.ScaleCities () (at Assets/WPMap2DLiteEdition/Scripts/Core/CityScaler.cs:38)

2. NullReferenceException: Object reference not set to an instance of an object
WPMF.WorldMap2D.Update () (at Assets/WPMap2DLiteEdition/Scripts/Core/WorldMap2DPrivate.cs:260)

These two errors are raised when code is trying to read "Camera.main". As it is an AR app, I am not using main camera. I am using ARCamera from Vuforia.

Is there a way to fix these errors and use the World Map 2D Lite Edition with AR app (using Unity and Vuforia)?
Title: Re: World Map 2D Lite Edition - using with unity and vuforia
Post by: Kronnect on May 11, 2019, 11:40:13 AM
The Lite version expects a camera tagged with MainCamera - it will be improved in next beta to pick up any camera in case it doesn't find the main camera.
Title: Re: World Map 2D Lite Edition - using with unity and vuforia
Post by: nalincy on May 15, 2019, 12:32:52 AM
Thanks for the information. When can we expect next beta release of World Map 2D Lite Edition?
Title: Re: World Map 2D Lite Edition - using with unity and vuforia
Post by: Kronnect on May 15, 2019, 02:19:44 AM
Check out lates beta - the new update now dynamically looks for a valid camera if none has the CameraMain tag.