mirror of
https://gitea.wildfiregames.com/0ad/0ad
synced 2026-08-15 14:43:32 -07:00
Fix doubleclicking if the unit died between the clicks following 8f36ca47a1, refs #4414, https://code.wildfiregames.com/D326
Differential Revision: https://code.wildfiregames.com/D469 Patch By: causative This was SVN commit r19583.
This commit is contained in:
parent
a73d59720e
commit
1eae8d0a95
1 changed files with 3 additions and 1 deletions
|
|
@ -968,8 +968,10 @@ function handleInputAfterGui(ev)
|
|||
{
|
||||
if (clickedEntity == INVALID_ENTITY)
|
||||
clickedEntity = Engine.PickEntityAtPoint(ev.x, ev.y);
|
||||
if (clickedEntity == INVALID_ENTITY)
|
||||
// Abort if we didn't click on an entity or if the entity was removed before the mousebuttonup event.
|
||||
if (clickedEntity == INVALID_ENTITY || !GetEntityState(clickedEntity))
|
||||
{
|
||||
clickedEntity = INVALID_ENTITY;
|
||||
if (!Engine.HotkeyIsPressed("selection.add") && !Engine.HotkeyIsPressed("selection.remove"))
|
||||
{
|
||||
g_Selection.reset();
|
||||
|
|
|
|||
Loading…
Reference in a new issue