From 76b990f133382811d2cc6e8de61c42dc5bf2ba75 Mon Sep 17 00:00:00 2001 From: Wanne Date: Wed, 10 Jun 2009 10:13:02 +0000 Subject: [PATCH] - Fixed compilation errors in VS 2005 - Updated Revision number: 2996 git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@2996 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- GameVersion.cpp | 8 ++++---- Strategic/Campaign Init.cpp | 21 ++++++++++++++++++++- Strategic/strategicmap.cpp | 4 ++-- ja2_2005Express.vcproj | 8 ++++---- ja2_VS2008.vcproj | 10 +++++----- 5 files changed, 35 insertions(+), 16 deletions(-) diff --git a/GameVersion.cpp b/GameVersion.cpp index c34b572e..99abcfd6 100644 --- a/GameVersion.cpp +++ b/GameVersion.cpp @@ -13,12 +13,12 @@ #ifdef JA2EDITOR //MAP EDITOR BUILD VERSION -CHAR16 zVersionLabel[256] = { L"Map Editor v1.13.2993" }; +CHAR16 zVersionLabel[256] = { L"Map Editor v1.13.2996" }; #elif defined JA2BETAVERSION //BETA/TEST BUILD VERSION -CHAR16 zVersionLabel[256] = { L"Debug v1.13.2993" }; +CHAR16 zVersionLabel[256] = { L"Debug v1.13.2996" }; #elif defined CRIPPLED_VERSION @@ -28,11 +28,11 @@ CHAR16 zVersionLabel[256] = { L"Beta v. 0.98" }; #else //RELEASE BUILD VERSION - CHAR16 zVersionLabel[256] = { L"Release v1.13.2963" }; + CHAR16 zVersionLabel[256] = { L"Release v1.13.2996" }; #endif -CHAR8 czVersionNumber[16] = { "Build 09.06.09" }; //YY.MM.DD +CHAR8 czVersionNumber[16] = { "Build 09.06.10" }; //YY.MM.DD CHAR16 zTrackingNumber[16] = { L"Z" }; diff --git a/Strategic/Campaign Init.cpp b/Strategic/Campaign Init.cpp index 337f057d..e32d4ea9 100644 --- a/Strategic/Campaign Init.cpp +++ b/Strategic/Campaign Init.cpp @@ -20,6 +20,8 @@ #endif #include "connect.h" +#include "VFS/vfs.h" +#include "XMLWriter.h" extern BOOLEAN InitStrategicMovementCosts(); void InitKnowFacilitiesFlags( ); @@ -205,6 +207,7 @@ BOOLEAN ReadInAltSectors(STR fileName) BOOLEAN WriteInAltSectors(STR fileName) { +#ifndef USE_VFS // Lets output the current Strategic map format using the XML structure I've devised. FILE *outfile = fopen(fileName, "wt"); @@ -223,7 +226,23 @@ BOOLEAN WriteInAltSectors(STR fileName) fprintf (outfile, "\n"); fclose(outfile); - +#else + XMLWriter xmlw; + xmlw.OpenNode(L"ALT_SECTORS_LIST"); + UINT32 x, y; + for(y = 1;y <= 16;y++) + { + xmlw.AddAttributeToNextValue(L"y",(char)(y+0x40)); + std::stringstream ss; + for(x = 1;x <= 16; x++) + { + ss << " " << RandomSector[ ((y - 1) * 16) + (x - 1) ]; + } + xmlw.AddValue(L"ROW", ss.str()); + } + xmlw.CloseNode(); + xmlw.WriteToFile(fileName); +#endif return (TRUE); } diff --git a/Strategic/strategicmap.cpp b/Strategic/strategicmap.cpp index 8a460f97..d05b3093 100644 --- a/Strategic/strategicmap.cpp +++ b/Strategic/strategicmap.cpp @@ -109,8 +109,8 @@ #include "connect.h" //hayden added alot ""'s to get around client spawing random/different placed AI #include "SaveLoadGame.h" -#include "vfs.h" -#include "PropertyContainer.h" +#include "VFS/vfs.h" +#include "VFS/Tools/Log.h" //forward declarations of common classes to eliminate includes class OBJECTTYPE; diff --git a/ja2_2005Express.vcproj b/ja2_2005Express.vcproj index 977171f0..816cf895 100644 --- a/ja2_2005Express.vcproj +++ b/ja2_2005Express.vcproj @@ -66,7 +66,7 @@