mirror of
https://github.com/1dot13/source.git
synced 2026-07-22 13:40:22 +02:00
- turned off compiler warning in VS2010
- fixed compiler error in VS2010 git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@8317 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
+9
-9
@@ -15,9 +15,9 @@
|
||||
#ifdef JA2EDITOR
|
||||
|
||||
#ifdef JA2UB
|
||||
CHAR16 zVersionLabel[256] = { L"Unfinished Business - Map Editor v1.13.8297 (Development Build)" };
|
||||
CHAR16 zVersionLabel[256] = { L"Unfinished Business - Map Editor v1.13.8317 (Development Build)" };
|
||||
#else
|
||||
CHAR16 zVersionLabel[256] = { L"Map Editor v1.13.8297 (Development Build)" };
|
||||
CHAR16 zVersionLabel[256] = { L"Map Editor v1.13.8317 (Development Build)" };
|
||||
#endif
|
||||
|
||||
// ------------------------------
|
||||
@@ -27,11 +27,11 @@
|
||||
|
||||
//DEBUG BUILD VERSION
|
||||
#ifdef JA2UB
|
||||
CHAR16 zVersionLabel[256] = { L"Debug: Unfinished Business - v1.13.8297 (Development Build)" };
|
||||
CHAR16 zVersionLabel[256] = { L"Debug: Unfinished Business - v1.13.8317 (Development Build)" };
|
||||
#elif defined (JA113DEMO)
|
||||
CHAR16 zVersionLabel[256] = { L"Debug: JA2 Demo - v1.13.8297 (Development Build)" };
|
||||
CHAR16 zVersionLabel[256] = { L"Debug: JA2 Demo - v1.13.8317 (Development Build)" };
|
||||
#else
|
||||
CHAR16 zVersionLabel[256] = { L"Debug: v1.13.8297 (Development Build)" };
|
||||
CHAR16 zVersionLabel[256] = { L"Debug: v1.13.8317 (Development Build)" };
|
||||
#endif
|
||||
|
||||
#elif defined CRIPPLED_VERSION
|
||||
@@ -46,16 +46,16 @@
|
||||
|
||||
//RELEASE BUILD VERSION
|
||||
#ifdef JA2UB
|
||||
CHAR16 zVersionLabel[256] = { L"Release Unfinished Business - v1.13.8297 (Development Build)" };
|
||||
CHAR16 zVersionLabel[256] = { L"Release Unfinished Business - v1.13.8317 (Development Build)" };
|
||||
#elif defined (JA113DEMO)
|
||||
CHAR16 zVersionLabel[256] = { L"Release JA2 Demo - v1.13.8297 (Development Build)" };
|
||||
CHAR16 zVersionLabel[256] = { L"Release JA2 Demo - v1.13.8317 (Development Build)" };
|
||||
#else
|
||||
CHAR16 zVersionLabel[256] = { L"Release v1.13.8297 (Development Build)" };
|
||||
CHAR16 zVersionLabel[256] = { L"Release v1.13.8317 (Development Build)" };
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
CHAR8 czVersionNumber[16] = { "Build 16.09.12" }; //YY.MM.DD
|
||||
CHAR8 czVersionNumber[16] = { "Build 16.10.15" }; //YY.MM.DD
|
||||
CHAR16 zTrackingNumber[16] = { L"Z" };
|
||||
|
||||
// SAVE_GAME_VERSION is defined in header, change it there
|
||||
|
||||
@@ -5344,7 +5344,7 @@ FLOAT GetSAMMaxDistanceToCoveredSector( UINT8 usSam )
|
||||
{
|
||||
if ( ubSAMControlledSectors[y][x] & (1 << usSam) )
|
||||
{
|
||||
FLOAT dist = std::sqrt( (sam_x - x)*(sam_x - x) + (sam_y - y)*(sam_y - y) );
|
||||
FLOAT dist = std::sqrt( FLOAT((sam_x - x)*(sam_x - x) + (sam_y - y)*(sam_y - y)) );
|
||||
|
||||
if ( maxdist < dist )
|
||||
maxdist = dist;
|
||||
@@ -5375,7 +5375,7 @@ BOOLEAN DoesSamCoverSector( UINT8 usSam, UINT8 usSector, BOOLEAN* apSamIsWorking
|
||||
*apSamIsWorking = TRUE;
|
||||
}
|
||||
|
||||
FLOAT dist = std::sqrt( (SECTORX( samsector ) - SECTORX( usSector ))*(SECTORX( samsector ) - SECTORX( usSector )) + (SECTORY( samsector ) - SECTORY( usSector ))*(SECTORY( samsector ) - SECTORY( usSector )) );
|
||||
FLOAT dist = std::sqrt( FLOAT((SECTORX( samsector ) - SECTORX( usSector ))*(SECTORX( samsector ) - SECTORX( usSector )) + (SECTORY( samsector ) - SECTORY( usSector ))*(SECTORY( samsector ) - SECTORY( usSector ))) );
|
||||
|
||||
// determine max distance SAM has to cover
|
||||
FLOAT sammaxdistance = GetSAMMaxDistanceToCoveredSector( usSam );
|
||||
|
||||
@@ -79,6 +79,10 @@ typedef struct
|
||||
|
||||
} ITEM_POOL_LOCATOR;
|
||||
|
||||
// silversurfer: added this to prevent tons of compiler warnings in VS2010 because of new behaviour for array initialization used in below structs
|
||||
// see https://msdn.microsoft.com/en-us/library/1ywe7hcy.aspx
|
||||
#pragma warning( disable : 4351 )
|
||||
|
||||
// Flugente: we can construct and deconstruct map structures via items.
|
||||
typedef struct STRUCTURE_DECONSTRUCT {
|
||||
STRUCTURE_DECONSTRUCT()
|
||||
|
||||
Reference in New Issue
Block a user