- Home /
How to Find location lat/long in web player (desktop, not mobile)
Hi,
just i want to know how to find the location, latitude and longitude, in web player games?
am not using any iphone and android devices.
Answer by ramonfr · Jul 23, 2015 at 12:51 AM
If you're running the game on a regular computer you'll never know, because you simply can't get the exact location of a computer (under normal circumstances) automatically. All you can do is get the approximate location of the IP address.
The easier way is: make the user request a web page which displays the IP location of the request as a text, then get the text of the page as a string variable.
Answer by Hadid · Jul 23, 2015 at 12:20 AM
Input.Location.LastState.latitude Input.Location.LastState.longitutde
these will give you the current location status
He said he's not using any mobile device...so I guess that won't work.