Use SDL_GetBasePath() on macOS
This commit is contained in:
parent
48348ac09f
commit
374d8f7b63
1 changed files with 3 additions and 1 deletions
|
@ -6,7 +6,9 @@
|
||||||
|
|
||||||
void prism::set_domain_path(const prism::domain domain, const prism::path& path) {
|
void prism::set_domain_path(const prism::domain domain, const prism::path& path) {
|
||||||
#ifdef PLATFORM_MACOS
|
#ifdef PLATFORM_MACOS
|
||||||
domain_data[(int)domain] = replace_substring(path.string(), "{resource_dir}/", "../Resources/");
|
char* base_path = SDL_GetBasePath();
|
||||||
|
|
||||||
|
domain_data[(int)domain] = replace_substring(path.string(), "{resource_dir}/", base_path);
|
||||||
#else
|
#else
|
||||||
domain_data[(int)domain] = replace_substring(path.string(), "{resource_dir}/", "");
|
domain_data[(int)domain] = replace_substring(path.string(), "{resource_dir}/", "");
|
||||||
#endif
|
#endif
|
||||||
|
|
Reference in a new issue