mirror of
https://github.com/UberGames/GtkRadiant.git
synced 2024-11-28 14:42:02 +00:00
Quake Live PK3 support - FIXED
This commit is contained in:
parent
ef1697925f
commit
fcdbd268ed
3 changed files with 21 additions and 11 deletions
|
@ -1,3 +1,11 @@
|
|||
/*****************************************************************************
|
||||
* name: qlvfs.cpp
|
||||
*
|
||||
* desc: QL VFS functions for unzip.cpp
|
||||
*
|
||||
* QBall147 - 18/06/2012
|
||||
*****************************************************************************/
|
||||
|
||||
#include "stdio.h"
|
||||
#include "qlvfs.h"
|
||||
|
||||
|
|
|
@ -6,11 +6,11 @@ See https://github.com/TTimo/GtkRadiant/issues/33
|
|||
|
||||
|
||||
/*****************************************************************************
|
||||
* name: unzip.c
|
||||
*
|
||||
* desc: IO on .zip files using portions of zlib
|
||||
* name: unzip.cpp
|
||||
*
|
||||
* desc: IO on (ql encoded) .zip files using portions of zlib
|
||||
*
|
||||
* QBall147 - 18/06/2012
|
||||
*****************************************************************************/
|
||||
|
||||
#include <stdlib.h>
|
||||
|
@ -1223,7 +1223,7 @@ void zcfree OF((voidp opaque, voidp ptr));
|
|||
static int unzlocal_getByte(FILE *fin,int *pi)
|
||||
{
|
||||
unsigned char c;
|
||||
int err = fread(&c, 1, 1, fin);
|
||||
int err = fread_ql(&c, 1, 1, fin);
|
||||
if (err==1)
|
||||
{
|
||||
*pi = (int)c;
|
||||
|
@ -1246,7 +1246,7 @@ static int unzlocal_getShort (FILE* fin, uLong *pX)
|
|||
{
|
||||
short v;
|
||||
|
||||
fread( &v, sizeof(v), 1, fin );
|
||||
fread_ql( &v, sizeof(v), 1, fin );
|
||||
|
||||
*pX = __LittleShort( v);
|
||||
return UNZ_OK;
|
||||
|
@ -1275,7 +1275,7 @@ static int unzlocal_getLong (FILE *fin, uLong *pX)
|
|||
{
|
||||
int v;
|
||||
|
||||
fread( &v, sizeof(v), 1, fin );
|
||||
fread_ql( &v, sizeof(v), 1, fin );
|
||||
|
||||
*pX = __LittleLong( v);
|
||||
return UNZ_OK;
|
||||
|
|
|
@ -28,11 +28,13 @@
|
|||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
//
|
||||
// Quake Live Virtual FileSystem - reads files from different dirs and inside pak files
|
||||
//
|
||||
// QBall147
|
||||
//
|
||||
/*****************************************************************************
|
||||
* name: vfsqlpk3.cpp
|
||||
*
|
||||
* desc: Quake Live Virtual FileSystem - reads files from different dirs and inside pak files
|
||||
*
|
||||
* QBall147 - 18/06/2012
|
||||
*****************************************************************************/
|
||||
|
||||
#ifdef _WIN32
|
||||
#include <wtypes.h>
|
||||
|
|
Loading…
Reference in a new issue