Game server admin's helping the community setup and maintain great dedicated game servers.
----Home----Submit News ----Forum--------Guides----


Go Back   FPSadmin.com > BattleField > Bad Company 2 > BC2: Remote Admin Tool Support

Reply
 
Thread Tools Display Modes
  #1  
Old 03-24-2011, 03:14 PM
Boney Boney is offline
Junior Member
 
Join Date: Mar 2011
Posts: 4
Rep Power: 0
Boney is on a distinguished road
Help.. BFBC2 Remote Administration Protocol

Need help with The “ BFBC2 PC Remote Administration Protocol” to end the game in BFBC2.

After looking on the Web for a week I need some help please.

I have a 8 man BC2 server. I would like the round/map section to end after a given amount of tickets.

I know I can set the Tickets a 40 for example, but when the next section of the map starts it changes to 75. And 75 for the following sections. It looks like that is the way it is in BC2. The attackers will win almost all the time with that amount of tickets.

So I have been ending the round manually at 40 tickets via BC2cc.


Looking at the BFBC2 PC Remote Administration Protocol I thought this would be an easy task, and it probably is. However the syntax is not so clear. I can load the example CommandConsole.py and make some commands work and not others.


This is the command I would like to try to make,

if x tickets = 40 (or some value)
then
admin.endRound <teamID>


I can not figure how to get the number of tickets left.


I see the section

Team scores
This describes the number of tickets, or kills, for each team in the current round.
<number of entries : integer> - number of team scores that follow
N x <score : integer> - score for all teams
<target score : integer> - when any team reaches this score, the match ends


But do not know how get the information I need.


I have downloaded all of t he Rcon type programs and source codes but just cant get the info I need to get this done. I know this is not Rocket Science but I need some hints to keep me working at it.


Thanks
Boney






Last edited by Boney; 03-24-2011 at 03:19 PM.
Reply With Quote
  #2  
Old 03-24-2011, 06:02 PM
sgTsTuFz's Avatar
sgTsTuFz sgTsTuFz is offline
Senior Member
 
Join Date: Aug 2004
Location: Coralville, Iowa
Posts: 909
Rep Power: 14
sgTsTuFz is on a distinguished road
Dunno bout BC2cc or which gamemode you're playing, but I use procon, and in my GS cp's startup.txt, I put this when I want a single ticket value for all maps:

levelVars.set gamemode CONQUEST tickets 100

100 being the default amount - set by percentage, so if one map is 250 tickets, and another map is 350 tickets, then they'll both play at their default ticket value.

So to do an individual map setting, provided that you're playing maps that have different default values, I run this in my startup.txt instead of the above:

levelVars.set level levels/mp_012cq tickets 150
levelVars.set level levels/bc1_oasis_cq tickets 150
levelVars.set level levels/mp_sp_005cq tickets 150
levelVars.set level levels/mp_006cq tickets 86
levelVars.set level levels/mp_001 tickets 150
levelVars.set level levels/mp_005 tickets 120
levelVars.set level levels/bc1_harvest_day_cq tickets 150

I can't recall off hand whether this works for other game modes, good luck !
Reply With Quote
  #3  
Old 03-24-2011, 06:31 PM
PsycX0r PsycX0r is offline
Member
 
Join Date: Apr 2010
Posts: 37
Rep Power: 0
PsycX0r is on a distinguished road
Sounds like problem is (haven't tested/noticed it myself) that in rush mode the extra tickets given in each phase is not scaled by the ticket ratio.

You can get the current tickets as part of the response for the serverInfo command
(name, numplayers, maxplayers, gamemode, map, roundsplayed, roundstotal, tickets1 tickets2)
Reply With Quote
  #4  
Old 03-24-2011, 07:08 PM
Boney Boney is offline
Junior Member
 
Join Date: Mar 2011
Posts: 4
Rep Power: 0
Boney is on a distinguished road
Sorry, I did not make it clear, this is for the Rush mode.
Reply With Quote
  #5  
Old 03-24-2011, 07:36 PM
Boney Boney is offline
Junior Member
 
Join Date: Mar 2011
Posts: 4
Rep Power: 0
Boney is on a distinguished road
Quote:
Originally Posted by PsycX0r View Post
Sounds like problem is (haven't tested/noticed it myself) that in rush mode the extra tickets given in each phase is not scaled by the ticket ratio.

You can get the current tickets as part of the response for the serverInfo command
Quote:
Originally Posted by PsycX0r View Post

(name, numplayers, maxplayers, gamemode, map, roundsplayed, roundstotal, tickets1 tickets2)


Thanks.
I deciphered the serveInfo today.

<serverName: string> "=OMG= Old Man Gang "
<current playercount: integer> "0"
<max playercount: integer> "8"
<current gamemode: string> "RUSH"
<current map: string> "Levels/MP_005GR"
<roundsPlayed: integer> "1"
<roundsTotal: string> "2"

<scores: team scores>

<number of entries : integer>??? "2"
N x <score : integer> "40"
N x <score : integer> "1500"
<target score : integer> "0"
<onlineState: online state> "AcceptingPlayers"
<ranked: boolean> "true"
<punkBuster: boolean> "true"
<hasGamePassword: boolean> "false"
<serverUpTime: seconds> "534761"
<roundTime: seconds> "6513"
<gameMod: GameModId> "BC2"
<mapPack: integer> "8"
<externalGameIpAndPort: IpPortPair> "8.6.8.32:19567"





please correct if I made an error.

I assume 1500 below is so the defending team has infinite tickets?
Does not matter, I can get the info I need but I am trying to understand every thing the server has sent back. Its a personal challenge now...lol

<scores: team scores>
<number of entries : integer> ??? "2"
N x <score : integer> "40"
N x <score : integer> "1500"
<target score : integer> "0"


Reply With Quote
  #6  
Old 03-25-2011, 12:05 PM
Boney Boney is offline
Junior Member
 
Join Date: Mar 2011
Posts: 4
Rep Power: 0
Boney is on a distinguished road
Now I can see the data I need to use any ideas on how to parse it out?

The CommandConsole.py uses key board input.

Any ideas on how to make it ask for serverIno on a regular basis and write to a file.

Or use a loop to get the data?
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 08:16 PM.


Powered by: vBulletin Copyright ©2000, Jelsoft Enterprises Ltd.