diff options
Diffstat (limited to 'source/gameengine/GamePlayer/ghost/GPG_ghost.cpp')
-rw-r--r-- | source/gameengine/GamePlayer/ghost/GPG_ghost.cpp | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp index 78ea2aac8ce..f5439ba4f64 100644 --- a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp +++ b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp @@ -76,9 +76,6 @@ extern "C" int GHOST_HACK_getFirstFile(char buf[]); -extern char bprogname[]; /* holds a copy of argv[0], from creator.c */ -extern char btempdir[]; /* use this to store a valid temp directory */ - // For BLF #include "BLF_api.h" #include "BLF_translation.h" @@ -116,9 +113,6 @@ extern char datatoc_bfont_ttf[]; const int kMinWindowWidth = 100; const int kMinWindowHeight = 100; -char bprogname[FILE_MAX]; -char bprogdir[FILE_MAX]; - static void mem_error_cb(const char *errorStr) { fprintf(stderr, "%s", errorStr); @@ -380,8 +374,8 @@ int main(int argc, char** argv) signal (SIGFPE, SIG_IGN); #endif /* __alpha__ */ #endif /* __linux__ */ - BLI_where_am_i(bprogname, sizeof(bprogname), argv[0]); - BLI_split_dir_part(bprogname, bprogdir, sizeof(bprogdir)); + BLI_init_program_path(argv[0]); + BLI_init_temporary_dir(NULL); #ifdef __APPLE__ // Can't use Carbon right now because of double defined type ID (In Carbon.h and DNA_ID.h, sigh) /* @@ -786,7 +780,7 @@ int main(int argc, char** argv) } else { - bfd = load_game_data(bprogname, filename[0]? filename: NULL); + bfd = load_game_data(BLI_program_path(), filename[0]? filename: NULL); } //::printf("game data loaded from %s\n", filename); |