Extend map camera controller

This commit is contained in:
Georg Hagen
2024-08-11 01:16:24 +02:00
parent 1e16b0ab48
commit 398074cad8
2 changed files with 10 additions and 1 deletions

View File

@@ -44,6 +44,13 @@ namespace OpenVulkano
CURRENT_FRAME.needsRedraw = true;
}
}
void MapCameraController::SetSliceHeight(float height)
{
float diff = height - GetCamera()->GetPosition().y;
GetCamera()->SetMatrix(Math::Utils::translate(Math::Vector3f_SIMD{0,diff,0}) * GetCamera()->GetMatrix());
CURRENT_FRAME.needsRedraw = true;
}
void MapCameraController::SetDefaultKeybindings()
{