thankyou
Donate to the B3 fund!

"even a small donation helps!"
Donate with PayPal!
Most of the plugins here are made by B3 users and the authors may not visit frequently. If you need support for plugins or if questions remain unanswered, you will have to contact the author directly. Read the full Support Disclaimer here

NOTE: Do not attach plugins to your forumtopics! Attachements are periodically removed by maintenance tasks. Upload your plugins to our Downloads section instead!

Author Topic: RotationManager [CoD|CoD:UO|CoD2|CoD4]  (Read 34471 times)

Offline xlr8or

  • [ www.xlrstats.com ]
  • Project Lead
  • Hero Member
  • *
  • Posts: 2057
    • The Art of Tactical Gaming
RotationManager [CoD|CoD:UO|CoD2|CoD4]
« on: September 19, 2006, 10:46:44 PM »

This plugin adjusts your maprotation based on the current playercount.
The configuration holds 2 switchpoints and 3 rotations. It keeps track of your
playercount and sets a small, medium or large maprotation. The plugin will
automatically create a proper random maprotation to work with.

Quote
###################################################################################
#
# Plugin for B3 (www.bigbrotherbot.com)
# (c) 2006 www.xlr8or.com (mailto:[email protected])
#
# This program is free software and licensed under the terms of
# the GNU General Public License (GPL), version 2.
#
# http://www.gnu.org/copyleft/gpl.html
###################################################################################

RotationManager (v1.3.0) for B3
###################################################################################

This plugin adjusts your maprotation based on the current playercount.
The configuration holds 2 switchpoints and 3 rotations. It keeps track of your
playercount and sets a small, medium or large maprotation. The plugin will
automatically create a proper random maprotation to work with.


Requirements:
###################################################################################

- Call of Duty server
- B3 version 1.1.0 or higher


Installation:
###################################################################################

1. Unzip the contents of this package into your B3 folder. It will
place the .py file in b3/extplugins and the config file .xml in
your b3/extplugins/conf folder.

2. Open the .xml file with your favorit editor and modify the
levels if you want them different. Do not edit the settingnames
for they will not function under a different name.

3. Open your B3.xml file (in b3/conf) and add the next line in the
<plugins> section of the file:

<plugin name="rotationmanager" priority="12" config="@b3/extplugins/conf/rotationmanager.xml"/>

The numer 12 in this just an example. Make sure it fits your
plugin list.


Changelog
###################################################################################
v1.3.0         : Added support for CoD4
v1.2.2 - v1.2.3: Introduced version 11 for UO; generate rotations with all gametypes
v1.2.1 - v1.2.2: Added another safety .strip() when storing _roundstart_mapRotationCurrent
v1.2.0 - v1.2.1: Bugfixversion
v1.1.6 - v1.2.0: Added hysteresis (switchpoint threshold) and internal restore
                 rotation functionality
v1.1.4 - v1.1.5: Bugfix in fast-restart section
v1.1.3 - v1.1.4: Fixed a bug where B3 was unresponsive while in restart-countdown
                 Added CoD1/CoD2 restartcompatibility
v1.1.2 - v1.1.3: Intro copy.deepcopy() to fix empty rotation dict.
v1.1.1 - v1.1.2: Added more debugging info
v1.1.0 - v1.1.1: Added Fallbackrotation and some errorchecking
v1.0.0 - v1.1.0: Added MapDelay and smart/random creation of rotations
v1.2.3 - v1.2.4: Added check for limitation of the maximum stringlength (capped at 980)
v1.0.0         : Initial release


###################################################################################
xlr8or - 28 nov 2007 - www.bigbrotherbot.com // www.xlr8or.com

Download the latest version here: ftp://ftp.snt.utwente.nl/pub/games/bigbrotherbot/plugins/rotationmanager-v1.3.0.zip

Dev. version: http://github.com/xlr8or/b3-plugin-rotationmanager/zipball/master
« Last Edit: November 12, 2010, 08:19:00 PM by xlr8or »

Offline xlr8or

  • [ www.xlrstats.com ]
  • Project Lead
  • Hero Member
  • *
  • Posts: 2057
    • The Art of Tactical Gaming
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #1 on: November 28, 2007, 09:04:36 PM »
Plugin is now compatible with CoD4

Offline Lolzumad

  • Full Member
  • ***
  • Posts: 50
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #2 on: February 03, 2009, 04:23:58 PM »
Would there be a way to add a function to this so that it does not repeat a map that's been played in, say, the last hour?

I know that it is partly my fault because I have the same map in two or three rotations, but that is because some maps really are good to play with a small pop or a large pop on your server.  The problem is, we might play crash with 7 people and then get two more on the server which bumps up the plugin to the next map rotaion set...crash is in that one as well and it might get picked even though we just played it two maps ago.  We'd like to be able to make it so this plugin doesn't pick a map that was played within the past "X" amount of time.

COD4, btw.

Offline xlr8or

  • [ www.xlrstats.com ]
  • Project Lead
  • Hero Member
  • *
  • Posts: 2057
    • The Art of Tactical Gaming
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #3 on: February 04, 2009, 02:23:39 PM »
Latest version (1.3.2) should do that already:
Code: [Select]
# 1.3.2        : only add maps that have not been added in the last 4 passes, no more double maps
Line 68 in the plugin makes it 4:
Code: [Select]
  _hmm = 4                              # HowManyMaps to keep as a maphistory
You may change that at your own risk. Just never make it as big as your shortest rotation (or bigger)

Offline Lolzumad

  • Full Member
  • ***
  • Posts: 50
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #4 on: February 04, 2009, 02:28:59 PM »
Ah, you are right..never noticed that.  Spent too much time arguing over which maps to put in which rotations, I guess!

Thanks!

Offline Lolzumad

  • Full Member
  • ***
  • Posts: 50
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #5 on: February 05, 2009, 07:13:51 PM »
I thought maybe I had seen this line before, and then I thought I had an older version....but only version 1.3.0 is up on your repository.

Can I add this line to the .py?


Offline Bakes

  • B3 Contrib/Support
  • Hero Member
  • *
  • Posts: 1226
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #6 on: February 05, 2009, 07:20:51 PM »
Try http://xlr8or.snt.utwente.nl/hg/rotationmanager?ca=4a4b24fcc612;type=zip
that's the latest version in the repository :)

Offline Lolzumad

  • Full Member
  • ***
  • Posts: 50
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #7 on: February 05, 2009, 07:43:26 PM »
When I upload the new version, I get this error:

Quote
File "b3/extplugins/rotationmanager.py", line 246
     for m in self._recentmaps
                                             ^
 SyntaxError: invalid syntax

EDIT:  The ^ symbol is messed up, it should be right under the space after the "s" in "recentmaps"
« Last Edit: February 05, 2009, 07:53:00 PM by Lolzumad »

Offline Bakes

  • B3 Contrib/Support
  • Hero Member
  • *
  • Posts: 1226
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #8 on: February 06, 2009, 11:12:25 AM »
add a : after the s.

Offline Lolzumad

  • Full Member
  • ***
  • Posts: 50
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #9 on: February 06, 2009, 02:07:48 PM »
Thanks, that worked perfect!

In case anyone else is having this problem, you will also have to add another ":" at the end of line 247.

Offline Bakes

  • B3 Contrib/Support
  • Hero Member
  • *
  • Posts: 1226
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #10 on: February 06, 2009, 02:48:54 PM »
good to hear :)

*cough* update it in the repo xlr8or! */cough*

Offline xlr8or

  • [ www.xlrstats.com ]
  • Project Lead
  • Hero Member
  • *
  • Posts: 2057
    • The Art of Tactical Gaming
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #11 on: February 07, 2009, 04:34:38 PM »
got it...

Offline leonpadi

  • Full Member
  • ***
  • Posts: 53
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #12 on: March 04, 2009, 11:50:13 AM »
I have installed too :)
Nice plugin, meanwhile i am testing it's random "creativity" :)
Of course i have to inform you that the current 246-247 lines of rotationmanager.py has...

Code: [Select]
            for m in self._recentmaps
              if maplist[c-1] == m

which is mispelled and need to be

Code: [Select]
            for m in self._recentmaps:
              if maplist[c-1] == m:
(added : at the end of each line)


Now my idea...
I would like to propose something even better, if it's an easy task.
What if b3 could record which maps and in which gametypes, the hourly-daily even monthly rotation was ?
I mean, an sql table in which the played rotations should be placed ... so the admin knows exactly which maps were played, which times etc...
This could be as fascinating as in some circumstances some Cod4 mods use end map voting, so...administrators could possibly know which maps people love most... ;)

I know...this maybe will be too hard to be true, but i suppose impossible is nothing :)
« Last Edit: March 04, 2009, 11:55:08 AM by leonpadi »

Offline xlr8or

  • [ www.xlrstats.com ]
  • Project Lead
  • Hero Member
  • *
  • Posts: 2057
    • The Art of Tactical Gaming
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #13 on: March 04, 2009, 03:18:36 PM »
The repo was already updated. Look for that version here: http://xlr8or.snt.utwente.nl/hg/

Your idea is not impossible, but if you install XLRstats and the webfront you can already see how many rounds have been played in what map... and how many kills were made in it.

Example: http://gs2.snt.utwente.nl/xlr/xlrstats/index.php?func=show&page=5

Offline leonpadi

  • Full Member
  • ***
  • Posts: 53
Re: RotationManager [CoD|CoD:UO|CoD2|CoD4]
« Reply #14 on: March 04, 2009, 06:41:15 PM »
It should be even better if you see timestamps about when played each map in which gametype and so on...
Thanks for reading my req :)

 


Rate this page +1 at Google Search

anything