feat(stats): Player com a font de veritat de vides/score/tresors i sarcs amb recompensa

This commit is contained in:
JailDesigner committed 2026-05-12 19:51:42 +02:00
1 parent d186f66c2c
commit f5d251c33b
14 files changed
+226 -34

No files matched your search

+6 -6
View File
@@ -157,7 +157,7 @@ namespace {
REQUIRE(sarc->getState() == Sarcophagus::State::CLOSED);
// Visitem un tile que NO és al perímetre: res canvia.
sarc->notifyTilePainted(5, 5);
sarc->notifyTilePainted(5, 5, /*player_id=*/0);
REQUIRE(sarc->getVisitedCount() == 0);
// Visitem tots els del perímetre.
@@ -166,7 +166,7 @@ namespace {
{0, 2}, {1, 2}, {2, 2}, {3, 2}, {4, 2},
{0, 1}, {4, 1},
};
for (const auto& [c, r] : PERIM) { sarc->notifyTilePainted(c, r); }
for (const auto& [c, r] : PERIM) { sarc->notifyTilePainted(c, r, /*player_id=*/0); }
REQUIRE(sarc->getVisitedCount() == 12);
REQUIRE(sarc->getState() == Sarcophagus::State::OPENING);
@@ -204,12 +204,12 @@ namespace {
const int W = s->getTileWidth();
const int H = s->getTileHeight();
for (int dc = -1; dc <= W; ++dc) {
s->notifyTilePainted(COL0 + dc, ROW0 - 1);
s->notifyTilePainted(COL0 + dc, ROW0 + H);
s->notifyTilePainted(COL0 + dc, ROW0 - 1, /*player_id=*/0);
s->notifyTilePainted(COL0 + dc, ROW0 + H, /*player_id=*/0);
}
for (int dr = 0; dr < H; ++dr) {
s->notifyTilePainted(COL0 - 1, ROW0 + dr);
s->notifyTilePainted(COL0 + W, ROW0 + dr);
s->notifyTilePainted(COL0 - 1, ROW0 + dr, /*player_id=*/0);
s->notifyTilePainted(COL0 + W, ROW0 + dr, /*player_id=*/0);
}
};
forceOpen(s1);