Split mcping and mctools, fixed geoip loading, removed CTCP finer (do we really need to reveal the bots username?)

This commit is contained in:
Luke Rogers 2013-07-15 23:01:01 +12:00
parent b0e43c0aea
commit f230439c56
4 changed files with 96 additions and 101 deletions

View file

@ -22,6 +22,8 @@ else:
output.write(geoip_file.read())
output.close()
geo = pygeoip.GeoIP(os.path.abspath("./plugins/data/GeoLiteCity.dat"))
@hook.command
def geoip(inp):
@ -48,4 +50,3 @@ def geoip(inp):
data["country"] = record["country_name"] or "Unknown"
data["city"] = record["city"] or "Unknown"
return "\x02Country:\x02 {country} ({cc}), \x02City:\x02 {city}{region}".format(**data)