mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-28 07:58:08 +01:00
save gameSeconds even if timer not enabled. Means stream version change.
This commit is contained in:
parent
bbfa375dfe
commit
4ce0a30b2d
2 changed files with 5 additions and 5 deletions
|
@ -438,7 +438,7 @@ gi_readFromStream( MPFORMAL XWStreamCtxt* stream, CurGameInfo* gi )
|
|||
}
|
||||
|
||||
gi->gameID = stream_getU16( stream );
|
||||
if ( gi->timerEnabled ) {
|
||||
if ( gi->timerEnabled || strVersion >= STREAM_VERS_GAMESECONDS ) {
|
||||
gi->gameSeconds = stream_getU16( stream );
|
||||
}
|
||||
|
||||
|
@ -481,9 +481,7 @@ gi_writeToStream( XWStreamCtxt* stream, const CurGameInfo* gi )
|
|||
stream_putBits( stream, 1, gi->confirmBTConnect );
|
||||
|
||||
stream_putU16( stream, gi->gameID );
|
||||
if ( gi->timerEnabled) {
|
||||
stream_putU16( stream, gi->gameSeconds );
|
||||
}
|
||||
stream_putU16( stream, gi->gameSeconds );
|
||||
|
||||
for ( pl = gi->players, i = 0; i < gi->nPlayers; ++pl, ++i ) {
|
||||
stringToStream( stream, pl->name );
|
||||
|
|
|
@ -31,6 +31,8 @@
|
|||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define STREAM_VERS_GAMESECONDS 0x0B /* save gameSeconds whether or not
|
||||
timer's enabled */
|
||||
#define STREAM_VERS_4YOFFSET 0x0A /* 4 bits for yOffset on board */
|
||||
#define STREAM_VERS_CHANNELSEED 0x09 /* new short in relay connect must be
|
||||
saved in comms */
|
||||
|
@ -44,7 +46,7 @@ extern "C" {
|
|||
#define STREAM_VERS_41B4 0x02
|
||||
#define STREAM_VERS_405 0x01
|
||||
|
||||
#define CUR_STREAM_VERS STREAM_VERS_4YOFFSET
|
||||
#define CUR_STREAM_VERS STREAM_VERS_GAMESECONDS
|
||||
|
||||
typedef struct LocalPlayer {
|
||||
XP_UCHAR* name;
|
||||
|
|
Loading…
Add table
Reference in a new issue