1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-13 00:25:19 +02:00

Add First Person Attachments (#10360)

Fixes some other third person camera specific attachments.
Implements a single new flag for entities to be forced visible in first person mode.
Old mods do not need to be updated to use the new flag and are fully backwards compatible.
This commit is contained in:
Jordan Snelling
2020-10-04 14:10:34 +01:00
committed by GitHub
parent 0f98b54aa4
commit 3068853e8a
12 changed files with 101 additions and 35 deletions

View File

@@ -2950,7 +2950,8 @@ void Game::updateCamera(u32 busy_time, f32 dtime)
camera->toggleCameraMode();
playercao->setVisible(camera->getCameraMode() > CAMERA_MODE_FIRST);
// Make the player visible depending on camera mode.
playercao->updateMeshCulling();
playercao->setChildrenVisible(camera->getCameraMode() > CAMERA_MODE_FIRST);
}