- Generalized Hexen's class-based spawning to be a property of the player class
so now it is available in all games. - Replaced the call to A_FlameSnd in the HereticPlayer's burn death sequence with A_FireScream and defined *burndeath for Heretic. - Added Grubber's custom player class support. SVN r250 (trunk)
This commit is contained in:
parent
38a073626f
commit
31c749058b
45 changed files with 1728 additions and 819 deletions
|
|
@ -1636,6 +1636,31 @@ FMemLump FWadCollection::ReadLump (int lump)
|
|||
return FMemLump (dest);
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
// SetLumpAddress
|
||||
//
|
||||
//==========================================================================
|
||||
|
||||
void FWadCollection::SetLumpAddress(LumpRecord *l)
|
||||
{
|
||||
// This file is inside a zip and has not been opened before.
|
||||
// Position points to the start of the local file header, which we must
|
||||
// read and skip so that we can get to the actual file data.
|
||||
FZipLocalHeader localHeader;
|
||||
int skiplen;
|
||||
int address;
|
||||
|
||||
WadFileRecord *wad = Wads[l->wadnum];
|
||||
|
||||
address = wad->Tell();
|
||||
wad->Seek (l->position, SEEK_SET);
|
||||
wad->Read (&localHeader, sizeof(localHeader));
|
||||
skiplen = LittleShort(localHeader.wFileNameSize) + LittleShort(localHeader.wExtraSize);
|
||||
l->position += sizeof(localHeader) + skiplen;
|
||||
l->flags &= ~LUMPF_NEEDFILESTART;
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
//
|
||||
// OpenLumpNum
|
||||
|
|
@ -1660,23 +1685,10 @@ FWadLump FWadCollection::OpenLumpNum (int lump)
|
|||
|
||||
if (l->flags & LUMPF_NEEDFILESTART)
|
||||
{
|
||||
// This file is inside a zip and has not been opened before.
|
||||
// Position points to the start of the local file header, which we must
|
||||
// read and skip so that we can get to the actual file data.
|
||||
FZipLocalHeader localHeader;
|
||||
int skiplen;
|
||||
SetLumpAddress(l);
|
||||
}
|
||||
|
||||
wad->Seek (l->position, SEEK_SET);
|
||||
wad->Read (&localHeader, sizeof(localHeader));
|
||||
skiplen = LittleShort(localHeader.wFileNameSize) + LittleShort(localHeader.wExtraSize);
|
||||
l->position += sizeof(localHeader) + skiplen;
|
||||
wad->Seek (skiplen, SEEK_CUR);
|
||||
l->flags &= ~LUMPF_NEEDFILESTART;
|
||||
}
|
||||
else
|
||||
{
|
||||
wad->Seek (l->position, SEEK_SET);
|
||||
}
|
||||
wad->Seek (l->position, SEEK_SET);
|
||||
|
||||
if (l->flags & LUMPF_COMPRESSED)
|
||||
{
|
||||
|
|
@ -1728,20 +1740,7 @@ FWadLump *FWadCollection::ReopenLumpNum (int lump)
|
|||
|
||||
if (l->flags & LUMPF_NEEDFILESTART)
|
||||
{
|
||||
// This file is inside a zip and has not been opened before.
|
||||
// Position points to the start of the local file header, which we must
|
||||
// read and skip so that we can get to the actual file data.
|
||||
FZipLocalHeader localHeader;
|
||||
int skiplen;
|
||||
int address;
|
||||
|
||||
address = wad->Tell();
|
||||
wad->Seek (l->position, SEEK_SET);
|
||||
wad->Read (&localHeader, sizeof(localHeader));
|
||||
skiplen = LittleShort(localHeader.wFileNameSize) + LittleShort(localHeader.wExtraSize);
|
||||
l->position += sizeof(localHeader) + skiplen;
|
||||
l->flags &= ~LUMPF_NEEDFILESTART;
|
||||
wad->Seek (address, SEEK_SET);
|
||||
SetLumpAddress(l);
|
||||
}
|
||||
|
||||
if (l->flags & LUMPF_COMPRESSED)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue