Веб-сайт самохостера Lotigara

summaryrefslogtreecommitdiff
path: root/source/game/items
diff options
context:
space:
mode:
authorKae <80987908+Novaenia@users.noreply.github.com>2024-04-25 02:09:10 +1000
committerKae <80987908+Novaenia@users.noreply.github.com>2024-04-25 02:09:10 +1000
commit1b86da7f3634b8bc19473fde10b0a9079b0f4580 (patch)
treec57e49c70b796230b79ef812ba20f078470ec402 /source/game/items
parentf547774c5cf7613c9e68c8e8f6a2d1dea4e5aeeb (diff)
fix: PaintingBeamTool turning invisible after switching color
Diffstat (limited to 'source/game/items')
-rw-r--r--source/game/items/StarTools.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/source/game/items/StarTools.cpp b/source/game/items/StarTools.cpp
index cde44b8..6c84c12 100644
--- a/source/game/items/StarTools.cpp
+++ b/source/game/items/StarTools.cpp
@@ -620,8 +620,10 @@ ItemPtr PaintingBeamTool::clone() const {
List<Drawable> PaintingBeamTool::drawables() const {
auto result = BeamItem::drawables();
for (auto& entry : result) {
- if (entry.isImage())
- entry.imagePart().image.directives += m_colorKeys[m_colorIndex];
+ if (entry.isImage()) {
+ auto& image = entry.imagePart().image;
+ image.subPath = image.subPath.value("0") + m_colorKeys[m_colorIndex];
+ }
}
return result;
}