Skip to content

Commit

Permalink
Added lambda return type.
Browse files Browse the repository at this point in the history
The MSVC 2013 compiler doesn't know whether to return a VoxelData or
const VoxelData&, so an explicit return type is needed.
  • Loading branch information
afritz1 committed Aug 17, 2017
1 parent 7684fec commit 89932ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion OpenTESArena/src/Entities/Player.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ void Player::lookAt(const Double3 &point)

void Player::handleCollision(const VoxelGrid &voxelGrid, double dt)
{
auto getVoxel = [&voxelGrid](int x, int y, int z)
auto getVoxel = [&voxelGrid](int x, int y, int z) -> VoxelData
{
// Voxels outside the world are air.
if ((x < 0) || (x >= voxelGrid.getWidth()) ||
Expand Down

0 comments on commit 89932ae

Please sign in to comment.