When changing zoom levels in abstract map inspector, preview mode no longer works
Hi there,
I am using the latest version of Mapbox unity SDK.
I noticed that in my editor under the abstract map component when I change zoom levels it not longer allows me to preview in editor and gives me the following errors;
- ArgumentException: Wrong number of arguments
- Mapbox.Unity.Utilities.Conversions.StringToLatLon (System.String s) (at Assets/Mapbox SDK/Mapbox/Unity/Utilities/Conversions.cs:49)
- Mapbox.Unity.Map.AbstractMap.InitializeMap (Mapbox.Unity.Map.MapOptions options) (at Assets/Mapbox SDK/Mapbox/Unity/Map/AbstractMap.cs:719)
- Mapbox.Unity.Map.AbstractMap.SetUpMap () (at Assets/Mapbox SDK/Mapbox/Unity/Map/AbstractMap.cs:651)
- Mapbox.Unity.Map.AbstractMap.EnableEditorPreview () (at Assets/Mapbox SDK/Mapbox/Unity/Map/AbstractMap.cs:566)
- Mapbox.Editor.MapManagerEditor.OnInspectorGUI () (at Assets/Mapbox SDK/Mapbox/Unity/Editor/MapManagerEditor.cs:171)
- UnityEditor.UIElements.InspectorElement+
c__AnonStorey1.<>m__0 () (at C:/buildslave/unity/build/Editor/Mono/Inspector/InspectorElement.cs:501) - UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)
Bare in mind that I have not augmented the code in any of the above mentioned scripts.
At first I changes zoom level in inspector to 2 and it previewed in editor but when I changed it back to zoom level 16 it stopped previewing in inspector and threw me the above mentioned error.
I am digging deep into the code to understand why this is happening, a bug perhaps?
If anyone could give me assistance or advice within regards to this I would really appreciate it.
Kind regards,
Jesse
Hey @StarKing777 !
I tried to recreate it but it worked on my end. Can you give me a few clear steps?
At first I changes zoom level in inspector to 2 and it previewed in editor but when I changed it back to zoom level 16 it stopped previewing in inspector and threw me the above mentioned error.
I tried this but more clear steps like below would help better; (I tried this but it looked fine to me)
change zoom to 2 enable preview it works disable preview change zoom 16 enable preview
Hey @StarKing777 ! I tried to recreate it but it worked on my end. Can you give me a few clear steps?
At first I changes zoom level in inspector to 2 and it previewed in editor but when I changed it back to zoom level 16 it stopped previewing in inspector and threw me the above mentioned error.I tried this but more clear steps like below would help better; (I tried this but it looked fine to me)change zoom to 2 enable preview it works disable preview change zoom 16 enable preview
Ah man!
to the rescue again!!
I just realized that I was changing the zoom levels multiple times without disabling preview.
so basically my steps were.
- change zoom to x
- enable preview
- change zoom to y
- // I was not disabling preview
makes total sense now.
thanks man really appreciate the assistance!
Kind regards,
Jesse