mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-10 23:02:08 +00:00
- Fixed: Blood's sprite rotations were broken.
SVN r2228 (trunk)
This commit is contained in:
parent
9d8a9bc981
commit
226a513e6e
3 changed files with 14 additions and 12 deletions
|
@ -158,7 +158,7 @@ const BYTE *FBuildTexture::GetColumn (unsigned int column, const Span **spans_ou
|
||||||
//
|
//
|
||||||
//===========================================================================
|
//===========================================================================
|
||||||
|
|
||||||
static void AddTiles (void *tiles)
|
void AddTiles (void *tiles)
|
||||||
{
|
{
|
||||||
// int numtiles = LittleLong(((DWORD *)tiles)[1]); // This value is not reliable
|
// int numtiles = LittleLong(((DWORD *)tiles)[1]); // This value is not reliable
|
||||||
int tilestart = LittleLong(((DWORD *)tiles)[2]);
|
int tilestart = LittleLong(((DWORD *)tiles)[2]);
|
||||||
|
@ -224,29 +224,29 @@ static void AddTiles (void *tiles)
|
||||||
if (rotType == 1)
|
if (rotType == 1)
|
||||||
{
|
{
|
||||||
spriteframe_t rot;
|
spriteframe_t rot;
|
||||||
rot.Texture[0] = texnum;
|
rot.Texture[0] =
|
||||||
rot.Texture[1] = texnum;
|
rot.Texture[1] = texnum;
|
||||||
for (int j = 1; j < 4; ++j)
|
for (int j = 1; j < 4; ++j)
|
||||||
{
|
{
|
||||||
rot.Texture[j*2] = texnum + j;
|
rot.Texture[j*2] =
|
||||||
rot.Texture[j*2+1] = texnum + j;
|
rot.Texture[j*2+1] =
|
||||||
rot.Texture[16-j*2] = texnum + j;
|
rot.Texture[16-j*2] =
|
||||||
rot.Texture[17-j*2] = texnum + j;
|
rot.Texture[17-j*2] = texnum.GetIndex() + j;
|
||||||
}
|
}
|
||||||
rot.Texture[8] = texnum + 4;
|
rot.Texture[8] =
|
||||||
rot.Texture[9] = texnum + 4;
|
rot.Texture[9] = texnum.GetIndex() + 4;
|
||||||
rot.Flip = 0x00FC;
|
rot.Flip = 0x00FC;
|
||||||
tex->Rotations = SpriteFrames.Push (rot);
|
tex->Rotations = SpriteFrames.Push (rot);
|
||||||
}
|
}
|
||||||
else if (rotType == 2)
|
else if (rotType == 2)
|
||||||
{
|
{
|
||||||
spriteframe_t rot;
|
spriteframe_t rot;
|
||||||
rot.Texture[0] = texnum;
|
rot.Texture[0] =
|
||||||
rot.Texture[1] = texnum;
|
rot.Texture[1] = texnum;
|
||||||
for (int j = 1; j < 8; ++j)
|
for (int j = 1; j < 8; ++j)
|
||||||
{
|
{
|
||||||
rot.Texture[16-j*2] = texnum + j;
|
rot.Texture[16-j*2] =
|
||||||
rot.Texture[17-j*2] = texnum + j;
|
rot.Texture[17-j*2] = texnum.GetIndex() + j;
|
||||||
}
|
}
|
||||||
rot.Flip = 0;
|
rot.Flip = 0;
|
||||||
tex->Rotations = SpriteFrames.Push (rot);
|
tex->Rotations = SpriteFrames.Push (rot);
|
||||||
|
|
|
@ -1005,7 +1005,7 @@ FArchive &operator<< (FArchive &arc, FTextureID &tex)
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
//
|
//
|
||||||
// FTextureID::operator+
|
// FTextureID::operator+
|
||||||
// Does not return incvalid texture IDs
|
// Does not return invalid texture IDs
|
||||||
//
|
//
|
||||||
//==========================================================================
|
//==========================================================================
|
||||||
|
|
||||||
|
|
|
@ -41,6 +41,8 @@ protected:
|
||||||
FTextureID(int num) { texnum = num; }
|
FTextureID(int num) { texnum = num; }
|
||||||
private:
|
private:
|
||||||
int texnum;
|
int texnum;
|
||||||
|
|
||||||
|
friend void AddTiles (void *tiles);
|
||||||
};
|
};
|
||||||
|
|
||||||
class FNullTextureID : public FTextureID
|
class FNullTextureID : public FTextureID
|
||||||
|
|
Loading…
Reference in a new issue