Skip to content

Commit

Permalink
Resolve compiling warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
bibendovsky committed Jan 21, 2017
1 parent 1909aea commit 1395154
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
6 changes: 3 additions & 3 deletions src/3d_act1.cpp
Expand Up @@ -774,7 +774,7 @@ void SpawnDoor(
}

// consider it a solid wall
actorat[tilex][tiley] = reinterpret_cast<objtype*>(doornum | 0x80);
actorat[tilex][tiley] = reinterpret_cast<objtype*>(static_cast<size_t>(doornum | 0x80));

//
// make the door tile a special tile, and mark the adjacent tiles
Expand Down Expand Up @@ -979,7 +979,7 @@ void CloseDoor(
// make the door space solid
//

actorat[tilex][tiley] = reinterpret_cast<objtype*>(door | 0x80);
actorat[tilex][tiley] = reinterpret_cast<objtype*>(static_cast<size_t>(door | 0x80));

CheckLinkedDoors(door, dr_closing);

Expand Down Expand Up @@ -1371,7 +1371,7 @@ void DoorClosing(
tilex = doorobjlist[door].tilex;
tiley = doorobjlist[door].tiley;

if ((actorat[tilex][tiley] != reinterpret_cast<objtype*>(door | 0x80)) ||
if ((actorat[tilex][tiley] != reinterpret_cast<objtype*>(static_cast<size_t>(door | 0x80))) ||
(player->tilex == tilex && player->tiley == tiley))
{
// something got inside the door
Expand Down
4 changes: 2 additions & 2 deletions src/3d_main.cpp
Expand Up @@ -7125,7 +7125,7 @@ bool LoadLevel(
if (value < 0) {
actorat[i][j] = &objlist[-value];
} else {
actorat[i][j] = reinterpret_cast<objtype*>(value);
actorat[i][j] = reinterpret_cast<objtype*>(static_cast<size_t>(value));
}
}
}
Expand Down Expand Up @@ -7969,7 +7969,7 @@ void ClearNClose()
::doorposition[door_index] = 0; // draw it closed!

// make it solid!
::actorat[tx][ty] = reinterpret_cast<objtype*>(door_index | 0x80);
::actorat[tx][ty] = reinterpret_cast<objtype*>(static_cast<size_t>(door_index | 0x80));
}
}

Expand Down

0 comments on commit 1395154

Please sign in to comment.