Skip to content

Commit

Permalink
fix(tesseratos): ensure entitySelector doesn't select gizmos
Browse files Browse the repository at this point in the history
  • Loading branch information
tomas7770 committed Feb 2, 2024
1 parent a347008 commit f0fdd61
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/tesseratos/src/tesseratos/entity_selector/plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ void tesseratos::entitySelectorPlugin(Cubos& cubos)
{
if (std::get<MouseButtonEvent>(event).button == cubos::core::io::MouseButton::Left)
{
if (!std::get<MouseButtonEvent>(event).pressed)
if (std::get<MouseButtonEvent>(event).pressed)
{
uint32_t entityId =
screenPicker.at(entitySelector.lastMousePosition.x, entitySelector.lastMousePosition.y);
Expand All @@ -66,7 +66,7 @@ void tesseratos::entitySelectorPlugin(Cubos& cubos)
{
entitySelector.selection = Entity{};
}
else
else if (entityId < static_cast<uint32_t>(1 << 31))
{
entitySelector.selection = Entity{entityId, world.generation(entityId)};
}
Expand Down

0 comments on commit f0fdd61

Please sign in to comment.