- disable implicit conversions from float to TAngle

This commit is contained in:
Christoph Oelckers 2022-08-26 00:56:53 +02:00
commit f0fbdba593
66 changed files with 425 additions and 374 deletions

View file

@ -140,7 +140,7 @@ static bool isBright(DPSprite *psp)
if (psp != nullptr && psp->GetState() != nullptr)
{
bool disablefullbright = false;
FTextureID lump = sprites[psp->GetSprite()].GetSpriteFrame(psp->GetFrame(), 0, 0., nullptr);
FTextureID lump = sprites[psp->GetSprite()].GetSpriteFrame(psp->GetFrame(), 0, nullAngle, nullptr);
if (lump.isValid())
{
auto tex = TexMan.GetGameTexture(lump, true);
@ -416,7 +416,7 @@ bool HUDSprite::GetWeaponRect(HWDrawInfo *di, DPSprite *psp, float sx, float sy,
// decide which patch to use
bool mirror;
FTextureID lump = sprites[psp->GetSprite()].GetSpriteFrame(psp->GetFrame(), 0, 0., &mirror);
FTextureID lump = sprites[psp->GetSprite()].GetSpriteFrame(psp->GetFrame(), 0, nullAngle, &mirror);
if (!lump.isValid()) return false;
auto tex = TexMan.GetGameTexture(lump, false);
@ -508,7 +508,7 @@ bool HUDSprite::GetWeaponRect(HWDrawInfo *di, DPSprite *psp, float sx, float sy,
// Handle PSPF_FLIP.
if (flip) anchorx = 1.0 - anchorx;
FAngle rot = float((flip) ? -psp->rotation.Degrees : psp->rotation.Degrees);
FAngle rot = FAngle::fromDeg(float((flip) ? -psp->rotation.Degrees : psp->rotation.Degrees));
const float cosang = rot.Cos();
const float sinang = rot.Sin();