2016-03-07 09:54:09

So the first thing i'm going to say, is I did not, I repeat not! write this with any bad intent and/or to hack! I actually wrote this with a couple cool ideas and mostly for experimentation. Any bad use of this script shall not be my fault, as I did not write this with any bad purposes and if someone goes off and does something bad with it, that's not really my fault. Ok, mini disclaimer thinggy over.

Anyway, this is a class that uses an accessable API to retrieve basic geolocation data from an IP address. I mostly wrote it for experimentation to see if it would work, but I had a few intresting ideas. If there was more than 1 multiplayer server in your game, you could use this to automaticly connect your player to the closest server. Also, something I thought of that might be fun, is showing a little map of whare players have been recently playing your game. I think that last one would be really wierd but kind of cool in a way. Take stw for example, if I had a map of just locations, anonymous locations, I could see that my game has like 65 percent Thai players, and I should really consider an admin there. It's just an example. Another extremely great use for this would be as an admin of an MP game, you could catch all of your impersonaters really really fast. If you knew whare the real person was from and someone comes on impersonating, it's pretty easy to get proof of an impersonation and rightfully ban the impersonater. It's just a fiew ways you could actually get use out of this, and plus it's just kind of cool. Of course it's not anything big or needed or anything, but why not share this little thinggy. It get's it's geolocation data from www.ipinfodb.com which isn't completely acurate but is free when it comes to a basic ip to location converter. So no, I don't provide the data, but I am providing a server for those of you who wanna use this but don't have there own server with php support. It's really simple to use. You have to get an ApiKey from there, but that's not hard, only takes a fiew mins at most, and should be a 1 time thing. Anyway, if this scemes at all intresting to you, you can download it with a full readme and source and stuff at the following link.
http://www.samtupy.com/dev/ip_locale.zip
I hope you enjoy and remember I did not write this script for any bad purpases what so ever, and with that being said, enjoy and have fun!

I am a web designer, and a game developer. If you wish see me at http://www.samtupy.com

2016-03-14 23:15:43

Awesome job dude.

If you like what I do, Feel free to check me out on GitHub, or follow me on Twitter