Implemented deselecting entity in editor

dev
Shariq Shah 6 years ago
parent 66b72cca73
commit e45c143f52
  1. 9
      src/game/editor.c
  2. 2
      todo.txt

@ -601,6 +601,15 @@ void editor_on_mousebutton(const struct Event* event)
intersected_entity->editor_selected = true;
editor->selected_entity = intersected_entity;
}
else
{
//Deselect the currently selected entity if nothing was found
if(editor->selected_entity)
{
editor->selected_entity->editor_selected = false;
editor->selected_entity = NULL;
}
}
}
}

@ -68,6 +68,7 @@ Bugs:
- Fix light rotation/direction bugs
- Fix lights type not being correctly saved/loaded from file
- Fix culling
- Fix bounding boxes not aligning in editor
Done:
* Input
@ -200,3 +201,4 @@ Done:
* Fixed mouse button press/release behaviour by using event callbacks for editor mouse picking
* Ray picking for editor
* Highlight entity selected in editor in a specific color
* Deselect selected entity in editor when nothing is hit on click and an entity is already selected

Loading…
Cancel
Save