diff --git a/desktop_version/src/FileSystemUtils.cpp b/desktop_version/src/FileSystemUtils.cpp index df41432f..e8b0ba4b 100644 --- a/desktop_version/src/FileSystemUtils.cpp +++ b/desktop_version/src/FileSystemUtils.cpp @@ -441,6 +441,19 @@ void FILESYSTEM_loadFileToMemory( PHYSFS_close(handle); } +void FILESYSTEM_loadAssetToMemory( + const char* name, + unsigned char** mem, + size_t* len, + const bool addnull +) { + const char* path; + + path = name; + + FILESYSTEM_loadFileToMemory(path, mem, len, addnull); +} + void FILESYSTEM_freeMemory(unsigned char **mem) { SDL_free(*mem); diff --git a/desktop_version/src/FileSystemUtils.h b/desktop_version/src/FileSystemUtils.h index 0e2fe794..ea6902ad 100644 --- a/desktop_version/src/FileSystemUtils.h +++ b/desktop_version/src/FileSystemUtils.h @@ -22,6 +22,12 @@ bool FILESYSTEM_isAssetMounted(const char* filename); void FILESYSTEM_loadFileToMemory(const char *name, unsigned char **mem, size_t *len, bool addnull); +void FILESYSTEM_loadAssetToMemory( + const char* name, + unsigned char** mem, + size_t* len, + const bool addnull +); void FILESYSTEM_freeMemory(unsigned char **mem); bool FILESYSTEM_saveTiXml2Document(const char *name, tinyxml2::XMLDocument& doc); bool FILESYSTEM_loadTiXml2Document(const char *name, tinyxml2::XMLDocument& doc);