Added namespace structs for pld's

This commit is contained in:
_
2018-04-17 19:37:59 -07:00
parent 7964563396
commit 9bfc125158
3 changed files with 18 additions and 9 deletions

View File

@@ -67,7 +67,7 @@ bool unpackpld(const char *filedata,
return false;
}
struct PldHeader h;
getpldh(&h, filedata);
DEVIL1PLD.getheader(&h, filedata);
char *fn = NULL;
fn = (char*)malloc(strlen(filename) + 3 + 4);
int size = 0;
@@ -75,7 +75,7 @@ bool unpackpld(const char *filedata,
char textureid[TYPE_ID_LENGTH] = {'\0', '2', '3', 'T'};
for (i = 0; i < h.numOffset; i++) {
const char * currentfile = filedata + h.offsets[i];
size = sizeofpldstruct(&h, i, filesize);
size = DEVIL1PLD.sizeofsector(&h, i, filesize);
if (strncmp( currentfile, textureid, TYPE_ID_LENGTH ) == 0)
sprintf(fn, "%s_%d.txp", filename, i);
else