Keep Entities selected when switching between Play- and Edit-Mode

- Fixed the check whether all selected entities have the same parent
This commit is contained in:
Simon Lübeß
2023-11-29 14:16:36 +01:00
parent 0257b93c7b
commit b68bad5bda
4 changed files with 71 additions and 40 deletions
@@ -45,14 +45,13 @@ namespace GlitchyEditor.EditWindows
ImGui.End();
return;
}
if(_entityHierarchyWindow.SelectedEntities.Count == 1)
{
Entity entity = _entityHierarchyWindow.SelectedEntities.Front;
if (_entityHierarchyWindow.SelectionSize == 1)
{
Entity entity = _entityHierarchyWindow.GetSelectedEntity(0);
ShowComponents(entity);
}
ImGui.PopStyleVar();
ImGui.End();
}