You are here: Big Brother Bot ForumAdd-OnsPluginsReleases!geowelcome plugin
Pages: [1] 2   Go Down
  Print  
Author Topic: geowelcome plugin  (Read 1332 times)
B3 Contributor
Jr. Member
****
Posts: 18
Offline Offline
« on: January 05, 2010, 05:04:51 AM »

I wrote a simple replacement for the welcome plugin.

When the user connect, it broadcast the location using geoip.

Quote
Connected $name from $country

And also adds this information in the welcome message:

Quote
Everyone welcome back $name, from $country. Player number #$id, played $connections times

$country: is "City (Country)"

Regards.

Available in the download section: http://www.bigbrotherbot.com/forums/downloads/?sa=view;down=51

EDIT: removed attachment. Added to download section.
« Last Edit: February 02, 2010, 03:41:57 AM by sgt » Logged
[ www.xlrstats.com ]
Project leader
Hero Member
*****
OS: Linux
Type: Owner dedicated server(s)
Gameservers: CoD, CoD2, CoD5, UrT
Posts: 1223
Offline Offline
WWW
« Reply #1 on: January 09, 2010, 03:28:50 AM »

Thanks for your contribution.

Please remove this attachment and upload it to our download section, so users may find al plugins in the same section and link it to this topic for support. Let us know when you uploaded it so we can approve it for you.
Logged


Serving: CoD2 | CoD5 | UrT4.1
B3 Contributor
Jr. Member
****
Posts: 18
Offline Offline
« Reply #2 on: January 09, 2010, 05:53:08 AM »

Thanks for your contribution.

Please remove this attachment and upload it to our download section, so users may find al plugins in the same section and link it to this topic for support. Let us know when you uploaded it so we can approve it for you.

Added to the download section. Thanks.
Logged
Newbie
*
Posts: 3
Offline Offline
« Reply #3 on: January 16, 2010, 11:48:03 AM »

im a little confused...
If this uses GeoIP, then how does it know where the GeoIP.dat file is located?
Am I missing something?

Forgive my ignorance, I only just today grabbed geoip and configured xlrstats webfront to use it.
No idea what else i can do with it yet.
Logged
B3 Contributor
Jr. Member
****
Posts: 18
Offline Offline
« Reply #4 on: January 16, 2010, 12:09:50 PM »

im a little confused...
If this uses GeoIP, then how does it know where the GeoIP.dat file is located?
Am I missing something?

Forgive my ignorance, I only just today grabbed geoip and configured xlrstats webfront to use it.
No idea what else i can do with it yet.

It use an external service (ipinfodb.com) for geolocation.
I forgot to add a library, I uploaded the file again because I don't know how to update the previous one.
It also includes a fix when the user disconnects before broadcasting.


« Last Edit: January 16, 2010, 02:04:46 PM by sgt » Logged
Newbie
*
Posts: 3
Offline Offline
« Reply #5 on: January 16, 2010, 01:45:39 PM »

silly question number 2...
Do I simply replace the deafult welcome with this?
what I mean is do I simply change     <plugin name="welcome" priority="9" config="@b3/conf/plugin_welcome.xml"/>
to
    <plugin name="geowelcome" priority="9" config="@b3/extplugins/conf/geowelcome.xml"/> ?

Or do these 2 work along side eachother?
Logged
B3 Contributor
Jr. Member
****
Posts: 18
Offline Offline
« Reply #6 on: January 16, 2010, 02:06:26 PM »

silly question number 2...
Do I simply replace the deafult welcome with this?
what I mean is do I simply change     <plugin name="welcome" priority="9" config="@b3/conf/plugin_welcome.xml"/>
to
    <plugin name="geowelcome" priority="9" config="@b3/extplugins/conf/geowelcome.xml"/> ?

Or do these 2 work along side eachother?

You have to replace the existing welcome plugin with this one.
Please, download the updated version attached to the first post.
Logged
[ www.xlrstats.com ]
Project leader
Hero Member
*****
OS: Linux
Type: Owner dedicated server(s)
Gameservers: CoD, CoD2, CoD5, UrT
Posts: 1223
Offline Offline
WWW
« Reply #7 on: January 17, 2010, 01:17:29 AM »

Quote
You have to replace the existing welcome plugin with this one.
This doesn't mean that you have to delete the original plugin! Just replace it in your b3.xml config file under plugins.

Nice service by the way, didn't know about ipinfodb.com before. Is it a reliable free service, or will it be 'paid only' in some time?
Logged


Serving: CoD2 | CoD5 | UrT4.1
B3 Contributor
Jr. Member
****
Posts: 18
Offline Offline
« Reply #8 on: January 17, 2010, 04:32:58 AM »

Nice service by the way, didn't know about ipinfodb.com before. Is it a reliable free service, or will it be 'paid only' in some time?

Good question  Smiley they are maintained by donations.
I hope they keep this service free, though everything can happen  Undecided

I'll implement a cache for next version, to decrease the number of queries.
Logged
Jr. Member
**
Posts: 13
Offline Offline
« Reply #9 on: January 23, 2010, 01:19:58 AM »

i get this error message

Quote
100123 10:05:06   BOT       Loading Plugin #8 geowelcome [/gameserver/servers/10681/urbanterror/b3/extplugins/conf/geowelcome.xml]
100123 10:05:06   INFO   Could not find built in plugin geowelcome, trying external plugin directories.
No module named geowelcome
100123 10:05:06   CRITICAL   Error loading plugin: No module named simplejson
Traceback (most recent call last):
  File "/gameserver/servers/10681/urbanterror/b3/parser.py", line 330, in loadPlugins
    pluginModule = self.pluginImport(p)
  File "/gameserver/servers/10681/urbanterror/b3/parser.py", line 355, in pluginImport
    return imp.load_module(name, fp, pathname, description)
  File "b3/extplugins/geowelcome.py", line 31, in <module>
    from b3 import geoip
  File "/gameserver/servers/10681/urbanterror/b3/geoip.py", line 2, in <module>
    import simplejson
ImportError: No module named simplejson

any ideas? i need simplejson package?
« Last Edit: January 23, 2010, 01:27:56 AM by hEmI » Logged
Dev. Team
Hero Member
*****
OS: Linux
Type: Owner dedicated server(s)
Gameservers: UrT, SmG
Posts: 1165
Offline Offline
WWW
« Reply #10 on: January 23, 2010, 02:17:05 AM »

If you are using the win32 standalone version of B3, then you cannot use plugins that requires additionnal python modules (such as simplejson)
Logged


Jr. Member
**
Posts: 13
Offline Offline
« Reply #11 on: January 23, 2010, 02:35:15 AM »

hmm..i dont really know which version is running on server, cause the bot was already installed.

When this "simplejson" is missing i have win32?

Sad pity

thank you for reply.
Logged
Dev. Team
Hero Member
*****
OS: Linux
Type: Owner dedicated server(s)
Gameservers: UrT, SmG
Posts: 1165
Offline Offline
WWW
« Reply #12 on: January 23, 2010, 02:37:31 AM »

if you are running the bot with "b3_run.exe" instead of "python b3_run.py" then you are using the win32 standalone.
« Last Edit: January 23, 2010, 02:43:27 AM by Courgette » Logged


Jr. Member
**
Posts: 13
Offline Offline
« Reply #13 on: January 23, 2010, 03:05:39 AM »

uh yes, b3_run.py

very pity

thank you for help Smiley
Logged
Dev. Team
Hero Member
*****
OS: Linux
Type: Owner dedicated server(s)
Gameservers: UrT, SmG
Posts: 1165
Offline Offline
WWW
« Reply #14 on: January 23, 2010, 04:23:28 AM »

you are not running the standalone version. Thus you can install the new dependencies.

Ask the plugin developper about what dependencies are required for this plugin to work
Logged


Tags:
Pages: [1] 2   Go Up
  Print  
 
Jump to: