From c3cbf4353d284b1f0f6280a0495085d8221f30e8 Mon Sep 17 00:00:00 2001 From: Roman Masanin <36927roma@gmail.com> Date: Mon, 26 Oct 2020 14:02:11 +0300 Subject: Fix build and use enum in ProcessPlayerMood --- src/audio/AudioLogic.cpp | 16 ++++++---------- 1 file changed, 6 insertions(+), 10 deletions(-) (limited to 'src/audio/AudioLogic.cpp') diff --git a/src/audio/AudioLogic.cpp b/src/audio/AudioLogic.cpp index 40e0ba6c..1fdba82a 100644 --- a/src/audio/AudioLogic.cpp +++ b/src/audio/AudioLogic.cpp @@ -307,20 +307,16 @@ cAudioManager::ProcessPlayerMood() if (m_nPlayerMoodTimer <= curTime) { playerPed = FindPlayerPed(); if (playerPed != nil) { -/* + if (playerPed->m_pWanted->m_nWantedLevel > 3) { - m_nPlayerMood = 2; + m_nPlayerMood = PLAYER_MOOD_ANGRY; return; } if (playerPed->m_pWanted->m_nWantedLevel > 1) { - m_nPlayerMood = 1; - return; - } -*/ - if (playerPed->m_pWanted->m_nWantedLevel > 1) { - m_nPlayerMood = (playerPed->m_pWanted->m_nWantedLevel > 3) ? 2 : 1; + m_nPlayerMood = PLAYER_MOOD_PISSED_OFF; return; } + lastMisstonPassedTime = CTheScripts::GetLastMissionPassedTime(); if (*lastMisstonPassedTime != -1) { if (curTime < *lastMisstonPassedTime) { @@ -328,11 +324,11 @@ cAudioManager::ProcessPlayerMood() return; } if (curTime < *lastMisstonPassedTime + 180000) { - m_nPlayerMood = 3; + m_nPlayerMood = PLAYER_MOOD_WISECRACKING; return; } } - m_nPlayerMood = 0; + m_nPlayerMood = PLAYER_MOOD_CALM; } } } -- cgit v1.2.3