Skip to content
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.

Commit

Permalink
avoid errors when double clicking on a unit
Browse files Browse the repository at this point in the history
the boongui_fullupdate_interval adds a small delay to what is displayed on the UI, if a unit has already died it will still be listed there till the next update, double clicking would cause an error.
  • Loading branch information
LangLangBart committed Nov 21, 2022
1 parent 8a6cc16 commit a65ef02
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion gui/session/stats/BoonGUIStatsModesRowItem.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ class BoonGUIStatsModesRowItem {
if (move)
{
const entState = GetEntityState(entities[0]);
Engine.CameraMoveTo(entState.position.x, entState.position.z);
if (entState)
Engine.CameraMoveTo(entState.position.x, entState.position.z);
}
}

Expand Down

0 comments on commit a65ef02

Please sign in to comment.