allow to (multi) select scrap

This commit is contained in:
2026-07-13 21:09:01 +02:00
parent 8c4fb78fc9
commit 535d4f8f24
11 changed files with 403 additions and 19 deletions

View File

@@ -168,6 +168,13 @@ private:
void placeBlueprintAtTile(QPoint center);
std::optional<QVector2D> entityPosition(entt::entity entity) const;
// Clears the scrap selection, emitting an empty ScrapSelectionChangedEvent when
// it was non-empty (REQ-UI-SCRAP-CLICK-SELECT). Used when another selection
// category takes over.
void clearScrapSelection();
// Drops despawned or fully-collected piles from the scrap selection and re-emits
// when it changed (REQ-UI-SCRAP-CLICK-SELECT). Called each frame from onFrame().
void pruneDespawnedScrap();
void stepSpeed(int delta);
void placeAtTile(QPoint tile);
@@ -249,6 +256,7 @@ private:
std::vector<BuildingId> m_selectedBuildingIds;
std::optional<entt::entity> m_selectedEntity;
std::vector<entt::entity> m_selectedScrap;
bool m_boxSelecting;
QPoint m_boxStartTile;
QPoint m_boxCurrentTile;