Get Real GPS not WiFi GPS

Hi!

I figuered out that the Input.location has nothing to do with the built in GPS function of andoid! It is just the position of that last wifi you have been at. Is there a way to access the GPS function of android?

It might me late for an answer but just in case somebody else might look for something like this in the future I would like to add that Input.location.lastdata actually uses the GPS function on android and gives pretty accurate results as well (for the latitude and longtitude at least).


I am using the code that the documendation has with the Input.location to retrieve the information without having wifi or 3g enabled on my phone.

There’s a thorough guide on how to write a plugin to obtain data from the GPS sensor on Android here: Unity GPS plugin development tutorial: building a Android plugin for Unity with Eclipse and Ant | Matthieu Deru - Mat-D.com