Rename m_unk0x24 to m_screenXScale

This commit is contained in:
Sebastian Mischke 2026-01-05 13:39:10 +01:00
parent deb70d4882
commit 68b0ac0d16
2 changed files with 3 additions and 3 deletions

View File

@ -50,7 +50,7 @@ class LegoRaceMap : public virtual LegoRaceActor {
// inversely scales the map in y direction (either convert world->screen space or to control the size) // inversely scales the map in y direction (either convert world->screen space or to control the size)
float m_worldYScale; // 0x20 float m_worldYScale; // 0x20
// scales the map in x direction (either convert world->screen space or to change the size) // scales the map in x direction (either convert world->screen space or to change the size)
float m_unk0x24; // 0x24 float m_screenXScale; // 0x24
// scales the map in y direction (either convert world->screen space or to change the size) // scales the map in y direction (either convert world->screen space or to change the size)
float m_unk0x28; // 0x28 float m_unk0x28; // 0x28
// likely an x-offset of the race map in screen space // likely an x-offset of the race map in screen space

View File

@ -74,7 +74,7 @@ void LegoRaceMap::ParseAction(char* p_extra)
token = strtok(NULL, g_parseExtraTokens); token = strtok(NULL, g_parseExtraTokens);
if (token != NULL) { if (token != NULL) {
m_unk0x24 = atof(token); m_screenXScale = atof(token);
} }
token = strtok(NULL, g_parseExtraTokens); token = strtok(NULL, g_parseExtraTokens);
@ -109,7 +109,7 @@ void LegoRaceMap::ParseAction(char* p_extra)
void LegoRaceMap::UpdateMapLocatorPosition() void LegoRaceMap::UpdateMapLocatorPosition()
{ {
if (m_mapEnabled) { if (m_mapEnabled) {
short xPos = (GetWorldPosition()[0] - m_worldXOffset) / m_worldXScale * m_unk0x24; short xPos = (GetWorldPosition()[0] - m_worldXOffset) / m_worldXScale * m_screenXScale;
short yPos = (GetWorldPosition()[2] - m_worldYOffset) / m_worldYScale * m_unk0x28; short yPos = (GetWorldPosition()[2] - m_worldYOffset) / m_worldYScale * m_unk0x28;
m_stillPresenter->SetPosition(xPos + m_unk0x2c, m_unk0x30 - yPos); m_stillPresenter->SetPosition(xPos + m_unk0x2c, m_unk0x30 - yPos);