mirror of
https://github.com/1dot13/source.git
synced 2026-08-26 14:30:26 +02:00
- moved ja2.set (game settings file) to a custom data directory defined in ja2.ini
git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@748 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
+8
-4
@@ -24,7 +24,7 @@
|
|||||||
|
|
||||||
#include "Text.h"
|
#include "Text.h"
|
||||||
|
|
||||||
#define GAME_SETTINGS_FILE "..\\Ja2.set"
|
#define GAME_SETTINGS_FILE "Ja2.set"
|
||||||
|
|
||||||
#define GAME_INI_FILE "..\\Ja2.ini"
|
#define GAME_INI_FILE "..\\Ja2.ini"
|
||||||
|
|
||||||
@@ -60,10 +60,12 @@ BOOLEAN LoadGameSettings()
|
|||||||
{
|
{
|
||||||
HWFILE hFile;
|
HWFILE hFile;
|
||||||
UINT32 uiNumBytesRead;
|
UINT32 uiNumBytesRead;
|
||||||
|
char gameSettingsFilePath[MAX_PATH];
|
||||||
|
|
||||||
|
sprintf(gameSettingsFilePath, "%s\\%s", gCustomDataCat.GetRootDir().c_str(), GAME_SETTINGS_FILE);
|
||||||
|
|
||||||
//if the game settings file does NOT exist, or if it is smaller then what it should be
|
//if the game settings file does NOT exist, or if it is smaller then what it should be
|
||||||
if( !FileExists( GAME_SETTINGS_FILE ) || FileSize( GAME_SETTINGS_FILE ) != sizeof( GAME_SETTINGS ) )
|
if( !FileExists( gameSettingsFilePath ) || FileSize( gameSettingsFilePath ) != sizeof( GAME_SETTINGS ) )
|
||||||
{
|
{
|
||||||
//Initialize the settings
|
//Initialize the settings
|
||||||
InitGameSettings();
|
InitGameSettings();
|
||||||
@@ -73,7 +75,7 @@ BOOLEAN LoadGameSettings()
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
hFile = FileOpen( GAME_SETTINGS_FILE, FILE_ACCESS_READ | FILE_OPEN_EXISTING, FALSE );
|
hFile = FileOpen( gameSettingsFilePath, FILE_ACCESS_READ | FILE_OPEN_EXISTING, FALSE );
|
||||||
if( !hFile )
|
if( !hFile )
|
||||||
{
|
{
|
||||||
FileClose( hFile );
|
FileClose( hFile );
|
||||||
@@ -161,11 +163,13 @@ BOOLEAN SaveGameSettings()
|
|||||||
{
|
{
|
||||||
HWFILE hFile;
|
HWFILE hFile;
|
||||||
UINT32 uiNumBytesWritten;
|
UINT32 uiNumBytesWritten;
|
||||||
|
char gameSettingsFilePath[MAX_PATH];
|
||||||
|
|
||||||
|
sprintf(gameSettingsFilePath, "%s\\%s", gCustomDataCat.GetRootDir().c_str(), GAME_SETTINGS_FILE);
|
||||||
|
|
||||||
|
|
||||||
//create the file
|
//create the file
|
||||||
hFile = FileOpen( GAME_SETTINGS_FILE, FILE_ACCESS_WRITE | FILE_CREATE_ALWAYS, FALSE );
|
hFile = FileOpen( gameSettingsFilePath, FILE_ACCESS_WRITE | FILE_CREATE_ALWAYS, FALSE );
|
||||||
if( !hFile )
|
if( !hFile )
|
||||||
{
|
{
|
||||||
FileClose( hFile );
|
FileClose( hFile );
|
||||||
|
|||||||
+2
-2
@@ -23,12 +23,12 @@ INT16 zVersionLabel[256] = { L"Beta v. 0.98" };
|
|||||||
#else
|
#else
|
||||||
|
|
||||||
//RELEASE BUILD VERSION
|
//RELEASE BUILD VERSION
|
||||||
INT16 zVersionLabel[256] = { L"Release v1.13.736" };
|
INT16 zVersionLabel[256] = { L"Release v1.13.748" };
|
||||||
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
INT8 czVersionNumber[16] = { "Build 07.02.24" }; //YY.MM.DD
|
INT8 czVersionNumber[16] = { "Build 07.03.01" }; //YY.MM.DD
|
||||||
INT16 zTrackingNumber[16] = { L"Z" };
|
INT16 zTrackingNumber[16] = { L"Z" };
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -546,7 +546,7 @@
|
|||||||
<Tool
|
<Tool
|
||||||
Name="VCLinkerTool"
|
Name="VCLinkerTool"
|
||||||
AdditionalDependencies="libexpatMT.lib winmm.lib smackw32.lib mss32.lib fmodvc.lib"
|
AdditionalDependencies="libexpatMT.lib winmm.lib smackw32.lib mss32.lib fmodvc.lib"
|
||||||
OutputFile="D:\games\Jagged Alliance 2 v1.13\ja2 v1.13.736_EN.exe"
|
OutputFile="D:\games\Jagged Alliance 2 v1.13\ja2 v1.13.748_EN.exe"
|
||||||
LinkIncremental="1"
|
LinkIncremental="1"
|
||||||
SuppressStartupBanner="TRUE"
|
SuppressStartupBanner="TRUE"
|
||||||
AdditionalLibraryDirectories=".\..\..\Standard Gaming Platform\"
|
AdditionalLibraryDirectories=".\..\..\Standard Gaming Platform\"
|
||||||
|
|||||||
Reference in New Issue
Block a user