diff --git a/src/object_gui.cpp b/src/object_gui.cpp index c295abcf02..8e687b8360 100644 --- a/src/object_gui.cpp +++ b/src/object_gui.cpp @@ -107,7 +107,7 @@ public: this->FindWindowPlacementAndResize(this->width, this->height); } - if (_selected_object_index != -1) matrix->SetClicked(_selected_object_index); + if (_selected_object_index != -1) matrix->SetClicked(ObjectClass::Get(_selected_object_class)->GetUIFromIndex(_selected_object_index)); } virtual ~BuildObjectWindow()