From a40a51cd71c48885e2e34c94ee91a422fdbaab32 Mon Sep 17 00:00:00 2001 From: gewlitys Date: Fri, 17 Oct 2008 20:49:24 +0000 Subject: [PATCH] Mounting packed ani/font files does not actually need to be relative to content mount. git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@3091 8092fc87-c524-0410-9efc-e669fe64eaf9 --- sc2/src/options.c | 3 ++- sc2/src/options.h | 2 -- sc2/src/sc2code/libs/graphics/sdl/3do_getbody.c | 8 ++++---- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/sc2/src/options.c b/sc2/src/options.c index a55d9e623..34db6b44f 100644 --- a/sc2/src/options.c +++ b/sc2/src/options.c @@ -60,7 +60,6 @@ uio_DirHandle *contentDir; uio_DirHandle *configDir; uio_DirHandle *saveDir; uio_DirHandle *meleeDir; -uio_MountHandle *contentMountHandle; char baseContentPath[PATH_MAX]; @@ -315,6 +314,8 @@ mountContentDir (uio_Repository *repository, const char *contentPath) { uio_DirHandle *packagesDir, *addonsDir; static uio_AutoMount *autoMount[] = { NULL }; + uio_MountHandle *contentMountHandle; + availableAddons = NULL; contentMountHandle = uio_mountDir (repository, "/", diff --git a/sc2/src/options.h b/sc2/src/options.h index a941bb280..d482d7617 100644 --- a/sc2/src/options.h +++ b/sc2/src/options.h @@ -50,8 +50,6 @@ extern uio_DirHandle *saveDir; extern uio_DirHandle *meleeDir; extern char baseContentPath[PATH_MAX]; -extern uio_MountHandle *contentMountHandle; - extern uio_DirList *availableAddons; extern const char **optAddons; diff --git a/sc2/src/sc2code/libs/graphics/sdl/3do_getbody.c b/sc2/src/sc2code/libs/graphics/sdl/3do_getbody.c index 6855a7c8c..65290b68d 100644 --- a/sc2/src/sc2code/libs/graphics/sdl/3do_getbody.c +++ b/sc2/src/sc2code/libs/graphics/sdl/3do_getbody.c @@ -426,8 +426,8 @@ _GetCelData (uio_Stream *fp, DWORD length) aniDir = uio_openDir (repository, aniDirName, 0); aniMount = uio_mountDir (repository, aniDirName, uio_FSTYPE_ZIP, aniDir, aniFileName, "/", autoMount, - uio_MOUNT_RDONLY | uio_MOUNT_ABOVE, - contentMountHandle); + uio_MOUNT_RDONLY | uio_MOUNT_TOP, + NULL); aniFile = uio_fopen (aniDir, aniFileName, "r"); opos = 0; n = 0; @@ -631,8 +631,8 @@ _GetFontData (uio_Stream *fp, DWORD length) fontDirHandle = uio_openDir (repository, fontDirName, 0); fontMount = uio_mountDir (repository, _cur_resfile_name, uio_FSTYPE_ZIP, fontDirHandle, fontZipName, "/", autoMount, - uio_MOUNT_RDONLY | uio_MOUNT_ABOVE, - contentMountHandle); + uio_MOUNT_RDONLY | uio_MOUNT_TOP, + NULL); uio_closeDir (fontDirHandle); }