Skip to content

Commit

Permalink
Use relative position for nametags
Browse files Browse the repository at this point in the history
  • Loading branch information
SmallJoker authored and sfan5 committed Oct 6, 2016
1 parent 009a9f1 commit 997fc59
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/camera.cpp
Expand Up @@ -552,7 +552,7 @@ void Camera::drawNametags()
// shadow can remain.
continue;
}
v3f pos = nametag->parent_node->getPosition() + v3f(0.0, 1.1 * BS, 0.0);
v3f pos = nametag->parent_node->getAbsolutePosition() + v3f(0.0, 1.1 * BS, 0.0);
f32 transformed_pos[4] = { pos.X, pos.Y, pos.Z, 1.0f };
trans.multiplyWith1x4Matrix(transformed_pos);
if (transformed_pos[3] > 0) {
Expand Down

0 comments on commit 997fc59

Please sign in to comment.