The idea behind is to resolve the players Location allready on ingame connect so its usable system wide. Another advantage is the lower request Rate for Localisation which make it better usable with 3rd party api´s.
Inspiration was given by XLRStats v.2 which show little country flags on the players listings.
However, we resolve the same way (throgh php GeoIP)
Requirements:
-B3 v.1.41 ???
-A Table
Commands aviaible:
!locate <playername>
!friends <km radius>
INSTALL
1.] Download the Plugin Extract to the coresponding Folders
2.] Execute teh Following SQL Query to generate the required Table:
---------------------------------------------------------------
CREATE TABLE /*!32312 IF NOT EXISTS*/ `plugin_localisation` (
`id` int(11) unsigned NOT NULL,
`city` varchar(255) NOT NULL,
`country` varchar(255) NOT NULL,
`countrycode` char(2) NOT NULL default '',
`latitude` varchar(255) NOT NULL,
`longitude` varchar(255) NOT NULL,
PRIMARY KEY (`id`),
KEY `id` (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
---------------------------------------------------------------
3.] Add the following Line to ur b3.xml
- Code: Select all
<plugin name="localisation" priority="##" config="@b3/extplugins/conf/localisation.xml"/>
(where ## is like allways the next free number in the list)
4.] Copy the geoip.php to ur prepared webserwer
5.] Go to the Plugin Configuration in
/extplugins/conf/localisation.xml
and change the "webaddress" to point on the geoip file from 4.
if ure a sucker u can suck from that api thats commented out there
6.] Don´t be silly. Don´t forget to restart the bot.
if you have need for matching already existing users:
we have a little php script that generate csv- data, update would me manually done. just ask if u have need for that...