Removed euler, only quaternion and dirty flag

This commit is contained in:
a.pilote
2022-07-14 17:45:06 -04:00
parent fb6080d734
commit 249e26dcd5
15 changed files with 203 additions and 66 deletions

View File

@@ -122,8 +122,8 @@ namespace Nuake {
if (ImGuizmo::IsUsing())
{
tc.LocalTransform = transform;
tc.GlobalTransform = transform;
tc.SetLocalTransform(transform);
tc.SetGlobalTransform(transform);
//Entity currentParent = Selection.Entity;
//if (parent.HasParent)
@@ -233,7 +233,7 @@ namespace Nuake {
if (ImGui::Selectable("Focus camera"))
{
Ref<EditorCamera> editorCam = Engine::GetCurrentScene()->m_EditorCamera;
editorCam->Translation = entity.GetComponent<TransformComponent>().Translation;
editorCam->Translation = entity.GetComponent<TransformComponent>().GetGlobalPosition();
Vector3 camDirection = entity.GetComponent<CameraComponent>().CameraInstance->GetDirection();
editorCam->SetDirection(camDirection);
}