glob2-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [glob2-devel] releasing beta3


From: Bradley Arsenault
Subject: Re: [glob2-devel] releasing beta3
Date: Sun, 20 Apr 2008 13:55:27 -0400

On Sat, Apr 19, 2008 at 9:50 PM, Leo Wandersleb <address@hidden> wrote:
hi guys,

kieran just chatted me about releasing beta3 now but left before i noticed.

bradley you said something about yet another bug you fixed? all the changes you mailed were committed to default as one big change so i can't make out what we would have to back port to beta3.

bradley beeing offline costs us a lot of dynamics i guess. nothing's going on in #glob2. no more testing neither. my german translation isn't complete neither.

Greetings, Leo
 
I fixed a bug yes, and I did so in the beta3 branch. That hg import should have not done it as a large lump change, usually it imports as seperate changesets, thats how it did it for me last time I used hg import. They are listed as seperate changsets in the patch file at the very least.
 
Here is the exact fix. You will have to reproduce this manually in beta 3.
 
@@ -169,28 +169,28 @@ void Game::setMapHeader(const MapHeader&
void Game::setGameHeader(const GameHeader& newGameHeader) { - // set the base players
- for (int i=0; i<gameHeader.getNumberOfPlayers(); i++)
- delete players[i];
-
- gameHeader = newGameHeader;
-
for (int i=0; i<mapHeader.getNumberOfTeams(); ++i)
{
teams[i]->playersMask=0;
teams[i]->numberOfPlayer=0;
}

- for (int i=0; i<gameHeader.getNumberOfPlayers(); i++)
+ for (int i=0; i<newGameHeader.getNumberOfPlayers(); i++)
{
- players[i]=new Player();
- players[i]->setBasePlayer(&gameHeader.getBasePlayer(i), teams);
+ //Don't change AI's
+ if(gameHeader.getBasePlayer(i).type < BasePlayer::P_AI)
+ {
+ delete players[i];
+ players[i]=new Player();
+ players[i]->setBasePlayer(&newGameHeader.getBasePlayer(i), teams);
+ }
teams[players[i]->teamNumber]->numberOfPlayer+=1;
teams[players[i]->teamNumber]->playersMask|=(1<<i);
}

setSyncRandSeed(newGameHeader.getRandomSeed());

+ gameHeader = newGameHeader;
anyPlayerWaited=false;
}

reply via email to

[Prev in Thread] Current Thread [Next in Thread]