This commit is contained in:
Till Wübbers
2025-04-27 12:00:22 +02:00
parent d75e5627f9
commit 4cdd80977c
8 changed files with 148 additions and 34 deletions

View File

@@ -102,7 +102,7 @@ namespace Game
void Level::Setup(GameData& data)
{
LOG("Level setup");
void* storagePtr = data.EntityStorage;
uint8_t* storagePtr = data.EntityArena.Ptr;
bool needReset = false;
needReset |= Cubes.Setup(storagePtr, needReset);
needReset |= Tests.Setup(storagePtr, needReset);
@@ -419,6 +419,7 @@ namespace Game
UpdateMatrix(camTransform);
Vec3 cameraPos = camTransform.Position;
// TODO: disable warning & check if parentheses make sense like this
Vec2 uiOffset = Vec2{static_cast<float>(Data.WidthTiles / Puzzle::Config::CardSize - 1),
static_cast<float>(Data.HeightTiles / Puzzle::Config::CardSize) - 1};
uiOffset *= -UICardOffset * 0.5f;