2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-07-01 14:13:29 +00:00

CInGameGuiManager: Take std::shared_ptr by const reference in DoStateTransition()

Trivially avoids an atomic reference count increment and decrement.
This commit is contained in:
Lioncash 2020-03-05 20:47:05 -05:00
parent 1092250559
commit 50f8f3e17e

View File

@ -103,8 +103,8 @@ void CInGameGuiManager::DoStateTransition(CStateManager& stateMgr) {
case EInGameGuiState::PauseGame:
case EInGameGuiState::PauseLogBook:
if (!x48_pauseScreen) {
auto pState = stateMgr.GetPlayerState();
CPlayerState::EPlayerSuit suit = pState->GetCurrentSuitRaw();
const auto& pState = stateMgr.GetPlayerState();
const CPlayerState::EPlayerSuit suit = pState->GetCurrentSuitRaw();
int suitResIdx;
if (pState->IsFusionEnabled()) {
switch (suit) {