- Fixed GCC and Clang compilation errors.

This commit is contained in:
Edoardo Prezioso 2016-04-02 23:01:32 +02:00
parent 6ffb5fa164
commit 28ac65b25b
3 changed files with 7 additions and 4 deletions

View File

@ -1086,7 +1086,7 @@ CCMD(currentpos)
if(mo)
{
Printf("Current player position: (%1.3f,%1.3f,%1.3f), angle: %1.3f, floorheight: %1.3f, sector:%d, lightlevel: %d\n",
mo->X(), mo->Y(), mo->Z(), mo->Angles.Yaw, mo->floorz, mo->Sector->sectornum, mo->Sector->lightlevel);
mo->X(), mo->Y(), mo->Z(), mo->Angles.Yaw.Normalized360().Degrees, mo->floorz, mo->Sector->sectornum, mo->Sector->lightlevel);
}
else
{

View File

@ -2122,8 +2122,10 @@ bool P_TryMove(AActor *thing, const DVector2 &pos,
// it slopes or the player's eyes are bobbing in and out.
bool oldAboveFakeFloor, oldAboveFakeCeiling;
double viewheight = thing->player ? thing->player->viewheight : thing->Height / 2;
oldAboveFakeFloor = oldAboveFakeCeiling = false; // pacify GCC
double viewheight;
// pacify GCC
viewheight = thing->player ? thing->player->viewheight : thing->Height / 2;
oldAboveFakeFloor = oldAboveFakeCeiling = false;
if (oldsec->heightsec)
{

View File

@ -3169,7 +3169,8 @@ static void R_RenderDecal (side_t *wall, DBaseDecal *decal, drawseg_t *clipper,
break;
}
fixed_t fzpos = FLOAT2FIXED(zpos);
fixed_t fzpos;
fzpos = FLOAT2FIXED(zpos); // pacify GCC
topoff = WallSpriteTile->TopOffset << FRACBITS;
dc_texturemid = topoff + FixedDiv (fzpos - viewz, yscale);