mirror of
https://github.com/AxioDL/PrimeWorldEditor.git
synced 2025-12-14 07:36:11 +00:00
Improved error handling and reporting when loading/saving project files; added file lock class to prevent the same project from being opened in multiple PWE instances
This commit is contained in:
@@ -1,15 +1,22 @@
|
||||
#include "CAssetNameMap.h"
|
||||
|
||||
void CAssetNameMap::LoadAssetNames(TString Path /*= gkAssetMapPath*/)
|
||||
bool CAssetNameMap::LoadAssetNames(TString Path /*= gkAssetMapPath*/)
|
||||
{
|
||||
CXMLReader Reader(Path);
|
||||
Serialize(Reader);
|
||||
|
||||
if (Reader.IsValid())
|
||||
{
|
||||
Serialize(Reader);
|
||||
return true;
|
||||
}
|
||||
else return false;
|
||||
}
|
||||
|
||||
void CAssetNameMap::SaveAssetNames(TString Path /*= gkAssetMapPath*/)
|
||||
bool CAssetNameMap::SaveAssetNames(TString Path /*= gkAssetMapPath*/)
|
||||
{
|
||||
CXMLWriter Writer(Path, "AssetNameMap", 0, eUnknownGame);
|
||||
Serialize(Writer);
|
||||
return Writer.Save();
|
||||
}
|
||||
|
||||
bool CAssetNameMap::GetNameInfo(CAssetID ID, TString& rOutDirectory, TString& rOutName)
|
||||
|
||||
Reference in New Issue
Block a user