mirror of
https://github.com/ZDoom/Raze.git
synced 2025-03-22 17:01:08 +00:00
- got rid of a few more picnum references in Blood.
This commit is contained in:
parent
76c0de2ef1
commit
f115f9427d
7 changed files with 12 additions and 11 deletions
|
@ -2287,7 +2287,8 @@ bool genDudePrepare(DBloodActor* actor, int propId)
|
|||
case kGenDudePropertyMass: {
|
||||
// to ensure mass gets updated, let's clear all cache
|
||||
SPRITEMASS* pMass = &actor->spriteMass;
|
||||
pMass->seqId = pMass->picnum = 0;
|
||||
pMass->seqId = 0;
|
||||
pMass->texid = FNullTextureID();
|
||||
pMass->scale.Zero();
|
||||
pMass->clipDist = 0;
|
||||
pMass->mass = pMass->airVel = pMass->fraction = 0;
|
||||
|
|
|
@ -656,7 +656,7 @@ void viewProcessSprites(tspriteArray& tsprites, const DVector3& cPos, DAngle cA,
|
|||
}
|
||||
while (nAnim > 0)
|
||||
{
|
||||
pTSprite->picnum += GetExtInfo(pTSprite->spritetexture()).picanm.num + 1;
|
||||
pTSprite->setspritetexture(pTSprite->spritetexture() + GetExtInfo(pTSprite->spritetexture()).picanm.num + 1);
|
||||
nAnim--;
|
||||
}
|
||||
|
||||
|
@ -940,7 +940,7 @@ void viewProcessSprites(tspriteArray& tsprites, const DVector3& cPos, DAngle cA,
|
|||
}
|
||||
while (nAnim > 0)
|
||||
{
|
||||
pTSprite->picnum += GetExtInfo(pTSprite->spritetexture()).picanm.num + 1;
|
||||
pTSprite->setspritetexture(pTSprite->spritetexture() + GetExtInfo(pTSprite->spritetexture()).picanm.num + 1);
|
||||
nAnim--;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -482,7 +482,7 @@ void dbLoadMap(const char* pPath, DVector3& pos, short* pAngle, sectortype** cur
|
|||
*pSprite = {};
|
||||
pSprite->SetMapPos(LittleLong(load.x), LittleLong(load.y), LittleLong(load.z));
|
||||
pSprite->cstat = ESpriteFlags::FromInt(LittleShort(load.cstat));
|
||||
pSprite->picnum = LittleShort(load.picnum);
|
||||
pSprite->picnum = LittleShort(load.pic);
|
||||
int secno = LittleShort(load.sectnum);
|
||||
pSprite->statnum = LittleShort(load.statnum);
|
||||
pSprite->Angles.Yaw = mapangle(LittleShort(load.ang));
|
||||
|
|
|
@ -9,7 +9,7 @@ struct spritetypedisk
|
|||
{
|
||||
int32_t x, y, z;
|
||||
uint16_t cstat;
|
||||
int16_t picnum;
|
||||
int16_t pic;
|
||||
int8_t shade;
|
||||
uint8_t pal, clipdist, detail;
|
||||
uint8_t xrepeat, yrepeat;
|
||||
|
|
|
@ -117,7 +117,7 @@ void InitMirrors(void)
|
|||
auto sectj = link2->sector();
|
||||
int j = sectindex(sectj);
|
||||
if (sectj->ceilingtexture != mirrortile)
|
||||
I_Error("Lower link sector %d doesn't have mirror picnum\n", j);
|
||||
I_Error("Lower link sector %d doesn't have mirror pic\n", j);
|
||||
mirror[mirrorcnt].type = 2;
|
||||
mirror[mirrorcnt].diff = link2->spr.pos - link->spr.pos;
|
||||
mirror[mirrorcnt].mynum = i;
|
||||
|
|
|
@ -1416,7 +1416,7 @@ int getSpriteMassBySize(DBloodActor* actor)
|
|||
}
|
||||
|
||||
SPRITEMASS* cached = &actor->spriteMass;
|
||||
if (((seqId >= 0 && seqId == cached->seqId) || actor->spr.picnum == cached->picnum) && actor->spr.scale.X == cached->scale.X &&
|
||||
if (((seqId >= 0 && seqId == cached->seqId) || actor->spr.spritetexture() == cached->texid) && actor->spr.scale.X == cached->scale.X &&
|
||||
actor->spr.scale.Y == cached->scale.Y && clipDist == cached->clipDist)
|
||||
{
|
||||
return cached->mass;
|
||||
|
@ -1499,7 +1499,7 @@ int getSpriteMassBySize(DBloodActor* actor)
|
|||
|
||||
cached->scale.X = actor->spr.scale.X;
|
||||
cached->scale.Y = actor->spr.scale.Y;
|
||||
cached->picnum = actor->spr.picnum;
|
||||
cached->texid = actor->spr.spritetexture();
|
||||
cached->seqId = seqId;
|
||||
cached->clipDist = actor->clipdist;
|
||||
|
||||
|
@ -9178,7 +9178,7 @@ void callbackUniMissileBurst(DBloodActor* actor, sectortype*) // 22
|
|||
|
||||
burstactor->spr.type = actor->spr.type;
|
||||
burstactor->spr.shade = actor->spr.shade;
|
||||
burstactor->spr.picnum = actor->spr.picnum;
|
||||
burstactor->spr.setspritetexture(actor->spr.spritetexture());
|
||||
|
||||
|
||||
burstactor->spr.cstat = actor->spr.cstat;
|
||||
|
@ -9413,7 +9413,7 @@ FSerializer& Serialize(FSerializer& arc, const char* keyname, SPRITEMASS& w, SPR
|
|||
if (arc.BeginObject(keyname))
|
||||
{
|
||||
arc("seq", w.seqId, &nul.seqId)
|
||||
("picnum", w.picnum, &nul.picnum)
|
||||
("texid", w.texid, &nul.texid)
|
||||
("scale", w.scale, &nul.scale)
|
||||
("clipdist", w.clipDist)
|
||||
("mass", w.mass)
|
||||
|
|
|
@ -194,7 +194,7 @@ enum {
|
|||
// - STRUCTS ------------------------------------------------------------------
|
||||
struct SPRITEMASS { // sprite mass info for getSpriteMassBySize();
|
||||
int seqId;
|
||||
int16_t picnum; // mainly needs for moving debris
|
||||
FTextureID texid; // mainly needs for moving debris
|
||||
DVector2 scale;
|
||||
int16_t airVel; // mainly needs for moving debris
|
||||
double clipDist; // mass multiplier
|
||||
|
|
Loading…
Reference in a new issue