Writable files in "Save", read-only files in "Data". This simplifies the installer and packaging.

This commit is contained in:
Chris Danford
2005-10-30 23:08:38 +00:00
parent 226e6fc3d8
commit 0f0caf7972
8 changed files with 9 additions and 11 deletions
+1 -1
View File
@@ -13,7 +13,7 @@
Bookkeeper* BOOKKEEPER = NULL; // global and accessable from anywhere in our program Bookkeeper* BOOKKEEPER = NULL; // global and accessable from anywhere in our program
static const CString COINS_DAT = "Data/Coins.xml"; static const CString COINS_DAT = "Save/Coins.xml";
Bookkeeper::Bookkeeper() Bookkeeper::Bookkeeper()
{ {
+1 -1
View File
@@ -33,7 +33,7 @@
const CString CATALOG_XML = "Catalog.xml"; const CString CATALOG_XML = "Catalog.xml";
const CString CATALOG_XSL = "Catalog.xsl"; const CString CATALOG_XSL = "Catalog.xsl";
const CString CATALOG_XML_FILE = DATA_DIR + "Catalog.xml"; const CString CATALOG_XML_FILE = "Save/" + CATALOG_XML;
void SaveCatalogXml( LoadingWindow *loading_window ) void SaveCatalogXml( LoadingWindow *loading_window )
{ {
-2
View File
@@ -285,8 +285,6 @@ const int NUM_ATTACKS_PER_LEVEL = 3;
const int ITEM_NONE = -1; const int ITEM_NONE = -1;
#define DATA_DIR CString("Data/")
// //
// Coin stuff // Coin stuff
+1 -1
View File
@@ -14,7 +14,7 @@
InputMapper* INPUTMAPPER = NULL; // global and accessable from anywhere in our program InputMapper* INPUTMAPPER = NULL; // global and accessable from anywhere in our program
#define KEYMAPS_PATH "Data/Keymaps.ini" #define KEYMAPS_PATH "Save/Keymaps.ini"
InputMapper::InputMapper() InputMapper::InputMapper()
{ {
+1 -1
View File
@@ -12,7 +12,7 @@
#include "RageLog.h" #include "RageLog.h"
const CString DEFAULTS_INI_PATH = "Data/Defaults.ini"; // these can be overridden const CString DEFAULTS_INI_PATH = "Data/Defaults.ini"; // these can be overridden
const CString STEPMANIA_INI_PATH = "Data/" PRODUCT_NAME ".ini"; // overlay on Defaults.ini, contains the user's choices const CString STEPMANIA_INI_PATH = "Save/" PRODUCT_NAME ".ini"; // overlay on Defaults.ini, contains the user's choices
const CString STATIC_INI_PATH = "Data/Static.ini"; // overlay on the 2 above, can't be overridden const CString STATIC_INI_PATH = "Data/Static.ini"; // overlay on the 2 above, can't be overridden
PrefsManager* PREFSMAN = NULL; // global and accessable from anywhere in our program PrefsManager* PREFSMAN = NULL; // global and accessable from anywhere in our program
+2 -2
View File
@@ -37,8 +37,8 @@ static void DefaultLocalProfileIDInit( size_t /*PlayerNumber*/ i, CString &sName
Preference1D<CString> ProfileManager::m_sDefaultLocalProfileID( DefaultLocalProfileIDInit, NUM_PLAYERS ); Preference1D<CString> ProfileManager::m_sDefaultLocalProfileID( DefaultLocalProfileIDInit, NUM_PLAYERS );
#define NEW_MEM_CARD_NAME "" #define NEW_MEM_CARD_NAME ""
#define USER_PROFILES_DIR "/Data/LocalProfiles/" #define USER_PROFILES_DIR "/Save/LocalProfiles/"
#define MACHINE_PROFILE_DIR "/Data/MachineProfile/" #define MACHINE_PROFILE_DIR "/Save/MachineProfile/"
const CString LAST_GOOD_SUBDIR = "LastGood/"; const CString LAST_GOOD_SUBDIR = "LastGood/";
+2 -2
View File
@@ -258,7 +258,7 @@ void RageFileManager::MountInitialFilesystems()
/* We can almost do this, to have machine profiles be system-global to eg. share /* We can almost do this, to have machine profiles be system-global to eg. share
* scores. It would need to handle permissions properly. */ * scores. It would need to handle permissions properly. */
/* RageFileManager::Mount( "dir", "/var/lib/games/stepmania", "/Data/Profiles" ); */ /* RageFileManager::Mount( "dir", "/var/lib/games/stepmania", "/Save/Profiles" ); */
// CString Home = getenv( "HOME" ) + "/" + PRODUCT_NAME; // CString Home = getenv( "HOME" ) + "/" + PRODUCT_NAME;
@@ -738,7 +738,7 @@ static bool PathUsesSlowFlush( const CString &sPath )
{ {
static const char *FlushPaths[] = static const char *FlushPaths[] =
{ {
"Data/" "Save/"
}; };
for( unsigned i = 0; i < ARRAYSIZE(FlushPaths); ++i ) for( unsigned i = 0; i < ARRAYSIZE(FlushPaths); ++i )
+1 -1
View File
@@ -739,7 +739,7 @@ RageDisplay *CreateDisplay()
RageException::Throw( error ); RageException::Throw( error );
} }
#define STATIC_INI_PATH "Data/Static.ini" extern const CString STATIC_INI_PATH;
void ChangeCurrentGame( const Game* g ) void ChangeCurrentGame( const Game* g )
{ {