mirror of
https://github.com/ZDoom/Raze.git
synced 2025-06-01 09:42:27 +00:00
- define several of RR's fullbright decorative sprites via spawnclasses remapping.
This commit is contained in:
parent
bdc474d04f
commit
23640988db
7 changed files with 52 additions and 45 deletions
|
@ -184,6 +184,7 @@ enum ESpriteBits2
|
||||||
CSTAT2_SPRITE_MAPPED = 2, // sprite was mapped for automap
|
CSTAT2_SPRITE_MAPPED = 2, // sprite was mapped for automap
|
||||||
CSTAT2_SPRITE_NOSHADOW = 4, // cast no shadow.
|
CSTAT2_SPRITE_NOSHADOW = 4, // cast no shadow.
|
||||||
CSTAT2_SPRITE_DECAL = 8, // always attached to a wall.
|
CSTAT2_SPRITE_DECAL = 8, // always attached to a wall.
|
||||||
|
CSTAT2_SPRITE_FULLBRIGHT = 16, // always draw fullbright with shade -127
|
||||||
};
|
};
|
||||||
|
|
||||||
// tsprite flags use the otherwise unused clipdist field.
|
// tsprite flags use the otherwise unused clipdist field.
|
||||||
|
|
|
@ -285,6 +285,8 @@ void HWDrawInfo::DispatchSprites()
|
||||||
|
|
||||||
if ((tspr->cstat & CSTAT_SPRITE_ALIGNMENT_MASK) != CSTAT_SPRITE_ALIGNMENT_SLAB)
|
if ((tspr->cstat & CSTAT_SPRITE_ALIGNMENT_MASK) != CSTAT_SPRITE_ALIGNMENT_SLAB)
|
||||||
tileUpdatePicnum(&tilenum, false, (actor->GetIndex() & 16383));
|
tileUpdatePicnum(&tilenum, false, (actor->GetIndex() & 16383));
|
||||||
|
if (tspr->cstat2 & CSTAT2_SPRITE_FULLBRIGHT)
|
||||||
|
tspr->shade = -127;
|
||||||
tspr->picnum = tilenum;
|
tspr->picnum = tilenum;
|
||||||
gotpic.Set(tilenum);
|
gotpic.Set(tilenum);
|
||||||
|
|
||||||
|
|
|
@ -552,49 +552,6 @@ void animatesprites_r(tspriteArray& tsprites, const DVector2& viewVec, DAngle vi
|
||||||
t->pos.Z = t->sectp->floorz;
|
t->pos.Z = t->sectp->floorz;
|
||||||
t->shade = -127;
|
t->shade = -127;
|
||||||
break;
|
break;
|
||||||
case WALLLIGHT3:
|
|
||||||
case WALLLIGHT1:
|
|
||||||
|
|
||||||
// none of these are active
|
|
||||||
case RRTILE3668:
|
|
||||||
case RRTILE3795:
|
|
||||||
case RRTILE7505:
|
|
||||||
case RRTILE7506:
|
|
||||||
if (!isRRRA()) break;
|
|
||||||
[[fallthrough]];
|
|
||||||
case RRTILE1878:
|
|
||||||
case RRTILE1952:
|
|
||||||
case RRTILE1953:
|
|
||||||
case RRTILE1990:
|
|
||||||
case RRTILE2050:
|
|
||||||
case RRTILE2056:
|
|
||||||
case RRTILE2072:
|
|
||||||
case RRTILE2075:
|
|
||||||
case RRTILE2083:
|
|
||||||
case RRTILE2097:
|
|
||||||
case RRTILE2357:
|
|
||||||
case RRTILE2564:
|
|
||||||
case RRTILE2573:
|
|
||||||
case RRTILE2574:
|
|
||||||
case RRTILE2583:
|
|
||||||
case RRTILE2604:
|
|
||||||
case RRTILE2689:
|
|
||||||
case RRTILE2893:
|
|
||||||
case RRTILE2894:
|
|
||||||
case RRTILE2915:
|
|
||||||
case RRTILE2945:
|
|
||||||
case RRTILE2946:
|
|
||||||
case RRTILE2947:
|
|
||||||
case RRTILE2948:
|
|
||||||
case RRTILE2949:
|
|
||||||
case RRTILE2977:
|
|
||||||
case RRTILE2978:
|
|
||||||
case RRTILE3116:
|
|
||||||
case RRTILE3171:
|
|
||||||
case RRTILE3216:
|
|
||||||
case RRTILE3720:
|
|
||||||
t->shade = -127;
|
|
||||||
break;
|
|
||||||
case CHEER:
|
case CHEER:
|
||||||
if (!isRRRA()) break;
|
if (!isRRRA()) break;
|
||||||
if (t->picnum >= CHEER + 102 && t->picnum <= CHEER + 151)
|
if (t->picnum >= CHEER + 102 && t->picnum <= CHEER + 151)
|
||||||
|
|
|
@ -3672,6 +3672,7 @@ void LoadActor(DDukeActor *actor, int p, int x)
|
||||||
s.g_ac = actor;
|
s.g_ac = actor;
|
||||||
s.g_t = &s.g_ac->temp_data[0]; // Sprite's 'extra' data
|
s.g_t = &s.g_ac->temp_data[0]; // Sprite's 'extra' data
|
||||||
|
|
||||||
|
if (actor->spr.picnum < 0 || actor->spr.picnum >= MAXTILES) return;
|
||||||
auto addr = gs.tileinfo[actor->spr.picnum].loadeventscriptptr;
|
auto addr = gs.tileinfo[actor->spr.picnum].loadeventscriptptr;
|
||||||
if (addr == 0) return;
|
if (addr == 0) return;
|
||||||
|
|
||||||
|
|
|
@ -59,6 +59,11 @@ void setFromSpawnRec(DDukeActor* act, SpawnRec* info)
|
||||||
act->spr.inittype = info->flags;
|
act->spr.inittype = info->flags;
|
||||||
if (info->clipdist > 0) act->spr.clipdist = info->clipdist;
|
if (info->clipdist > 0) act->spr.clipdist = info->clipdist;
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (info->basetex >= 0 && info->basetex < MAXTILES) act->spr.picnum = info->basetex;
|
||||||
|
if (info->fullbright & 1) act->spr.cstat2 |= CSTAT2_SPRITE_FULLBRIGHT;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -150,6 +150,13 @@ spawnclasses
|
||||||
8462 = DukeGenericDestructible, "RRTILE8462", "RRTILE5074", "GLASS_HEAVYBREAK"
|
8462 = DukeGenericDestructible, "RRTILE8462", "RRTILE5074", "GLASS_HEAVYBREAK"
|
||||||
8682 = DukeGenericDestructible, "RRTILE8682", "RRTILE8683", "GLASS_HEAVYBREAK"
|
8682 = DukeGenericDestructible, "RRTILE8682", "RRTILE8683", "GLASS_HEAVYBREAK"
|
||||||
1824 = DukeGenericDestructible, "YELLOWBOTTLE", "", "GLASS_HEAVYBREAK", spawnglass2
|
1824 = DukeGenericDestructible, "YELLOWBOTTLE", "", "GLASS_HEAVYBREAK", spawnglass2
|
||||||
|
244 = DukeActor, "*WALLLIGHT3"
|
||||||
|
246 = DukeActor, "*WALLLIGHT1"
|
||||||
|
3668 = DukeActor, "*RRTILE3668"
|
||||||
|
3795 = DukeActor, "*RRTILE3795"
|
||||||
|
7505 = DukeActor, "*RRTILE7505"
|
||||||
|
7506 = DukeActor, "*RRTILE7506"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
tileflag TFLAG_WALLSWITCH {
|
tileflag TFLAG_WALLSWITCH {
|
||||||
|
@ -182,3 +189,4 @@ tileflag TFLAG_BLOCKDOOR {
|
||||||
RRTILE8565
|
RRTILE8565
|
||||||
RRTILE8605
|
RRTILE8605
|
||||||
}
|
}
|
||||||
|
|
|
@ -227,6 +227,39 @@ spawnclasses
|
||||||
2654 = DukeGenericDestructible, "RRTILE2654", "", "GLASS_BREAKING", spawnglass
|
2654 = DukeGenericDestructible, "RRTILE2654", "", "GLASS_BREAKING", spawnglass
|
||||||
2656 = DukeGenericDestructible, "RRTILE2656", "", "GLASS_BREAKING", spawnglass
|
2656 = DukeGenericDestructible, "RRTILE2656", "", "GLASS_BREAKING", spawnglass
|
||||||
3172 = DukeGenericDestructible, "RRTILE3172", "", "GLASS_BREAKING", spawnglass
|
3172 = DukeGenericDestructible, "RRTILE3172", "", "GLASS_BREAKING", spawnglass
|
||||||
|
|
||||||
|
1878 = DukeActor, "*RRTILE1878"
|
||||||
|
1952 = DukeActor, "*RRTILE1952"
|
||||||
|
1953 = DukeActor, "*RRTILE1953"
|
||||||
|
1990 = DukeActor, "*RRTILE1990"
|
||||||
|
2050 = DukeActor, "*RRTILE2050"
|
||||||
|
2056 = DukeActor, "*RRTILE2056"
|
||||||
|
2072 = DukeActor, "*RRTILE2072"
|
||||||
|
2075 = DukeActor, "*RRTILE2075"
|
||||||
|
2083 = DukeActor, "*RRTILE2083"
|
||||||
|
2097 = DukeActor, "*RRTILE2097"
|
||||||
|
2357 = DukeActor, "*RRTILE2357"
|
||||||
|
2564 = DukeActor, "*RRTILE2564"
|
||||||
|
2573 = DukeActor, "*RRTILE2573"
|
||||||
|
2574 = DukeActor, "*RRTILE2574"
|
||||||
|
2583 = DukeActor, "*RRTILE2583"
|
||||||
|
2604 = DukeActor, "*RRTILE2604"
|
||||||
|
2689 = DukeActor, "*RRTILE2689"
|
||||||
|
2893 = DukeActor, "*RRTILE2893"
|
||||||
|
2894 = DukeActor, "*RRTILE2894"
|
||||||
|
2915 = DukeActor, "*RRTILE2915"
|
||||||
|
2945 = DukeActor, "*RRTILE2945"
|
||||||
|
2946 = DukeActor, "*RRTILE2946"
|
||||||
|
2947 = DukeActor, "*RRTILE2947"
|
||||||
|
2948 = DukeActor, "*RRTILE2948"
|
||||||
|
2949 = DukeActor, "*RRTILE2949"
|
||||||
|
2977 = DukeActor, "*RRTILE2977"
|
||||||
|
2978 = DukeActor, "*RRTILE2978"
|
||||||
|
3116 = DukeActor, "*RRTILE3116"
|
||||||
|
3171 = DukeActor, "*RRTILE3171"
|
||||||
|
3216 = DukeActor, "*RRTILE3216"
|
||||||
|
3720 = DukeActor, "*RRTILE3720"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue