mapbox-unity-sdk icon indicating copy to clipboard operation
mapbox-unity-sdk copied to clipboard

example of setting new latitude longitude at run time for abstract map

Open etown opened this issue 9 years ago • 16 comments

@DanielRakh I have a unity/mapbox embedded into my ios application. I can successfully send a message to an initialized abstract map. I would like to change the map center, however setting _mapCenterLatitudeLongitude seems to have no effect. can you point me in the direction of the proper way to change the map center at runtime?

thanks so much!

etown avatar Sep 20 '17 20:09 etown

@etown Example coming very soon with the next SDK release!

david-rhodes avatar Sep 25 '17 18:09 david-rhodes

@DanielRakh that's great, thank you for all your great work!

do you have an eta for the next release?

etown avatar Sep 25 '17 18:09 etown

My guess is later this week/early next week.

Think you are mentioning the wrong github handle, too 😄 .

david-rhodes avatar Sep 25 '17 19:09 david-rhodes

Oops 😭

Anyway, eagerly awaiting! Thanks for the info!

On Sep 25, 2017, at 12:41 PM, David Rhodes [email protected] wrote:

My guess is later this week/early next week.

Think you are mentioning the wrong github handle, too 😄 .

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

etown avatar Sep 25 '17 20:09 etown

In develop as of now. Please see the new example MapReload and the ReloadMap.cs script.

david-rhodes avatar Sep 26 '17 20:09 david-rhodes

@david-rhodes I just cloned, updated dependencies and imported package. I can run it successfully in unity, but when i've built to ios I get the following xcode error. unity 2017, xcode 9

'MapboxMobileEvents/MapboxMobileEvents.h' file not found

I searched around but couldn't find the solution. if I am importing incorrectly I apologize, do you have any advice?

etown avatar Sep 26 '17 21:09 etown

@etown I'm assuming you've brought this into your own project? What do you mean imported package? Did you create the package yourself?

Ensure you have the file here: Assets/Mapbox/Core/Plugins/iOS/MapboxMobileEvents/include/MapboxMobileEvents and ensure iOS is checked in the inspector.

If that doesn't work for you, can you paste your xcode project Other Linker Flags and Header Search Paths please? Thanks!

david-rhodes avatar Sep 26 '17 22:09 david-rhodes

@david-rhodes I imported the package by first exporting it according to theinstructions in the readme.

the files are present. I'm not sure where to find the ios checkbox in the inspector. could you tell me where to find it?

I was able to get it to build following the changes described here: https://github.com/mapbox/mapbox-unity-sdk/issues/101

screen shot 2017-09-26 at 4 48 37 pm screen shot 2017-09-26 at 4 48 12 pm

etown avatar Sep 26 '17 23:09 etown

@etown Which change specifically? Delete and reinstall?

david-rhodes avatar Sep 26 '17 23:09 david-rhodes

@david-rhodes basically this: 5292853365571584

etown avatar Sep 27 '17 00:09 etown

@boundsj Are you able to offer any insight here? Should this have to be done given the header search path?

david-rhodes avatar Sep 27 '17 00:09 david-rhodes

Should this have to be done given the header search path?

No. As I understand it, we have a script in our Unity SDK that should set up the generated Xcode project correctly so the steps noted above do not need to be done. We have an internal repo to test Unity cloud builds that (I think) needs this to sort itself out correctly in order to pass tests.

boundsj avatar Sep 27 '17 16:09 boundsj

It looks to me, based on the screenshots provided, everything was set properly based on our build script. In other words, looks like the build script did its job, yet manual code changes were still required?

david-rhodes avatar Sep 27 '17 17:09 david-rhodes

Yeah if someone can provide the steps required for me to reproduce this issue I'm happy to take a look. I'm foggy on the Unity bits and can't remember where to start atm! 😬

boundsj avatar Sep 27 '17 18:09 boundsj

I'm having the same issue as well, instructions above fixed it. Simply create a new project, import MapBox, build iOS Xcode project, deploy to device.

thehen avatar Oct 18 '17 14:10 thehen

I discovered that this error occured for me because I had the Symlink Unity Libraries checkbox turned on while building for iOS. Please make sure this is unchecked before building 33154796-e62110da-cf9f-11e7-8010-c7e488e81b6b

apavani avatar Nov 27 '17 19:11 apavani