From c7e05c74b9b38c90bdb6d3c85c5ffc73bdf88f66 Mon Sep 17 00:00:00 2001 From: Sergeanur Date: Mon, 16 Aug 2021 10:00:10 +0300 Subject: Fix cAudioManager::ProcessVehicleEngine return type, rename Sound Intensity --- src/audio/AudioManager.h | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'src/audio/AudioManager.h') diff --git a/src/audio/AudioManager.h b/src/audio/AudioManager.h index 526df1f8..383644e0 100644 --- a/src/audio/AudioManager.h +++ b/src/audio/AudioManager.h @@ -27,10 +27,12 @@ public: uint8 m_nEmittingVolume; #endif float m_fSpeedMultiplier; - float m_fSoundIntensity; + float m_SoundIntensity; bool8 m_bReleasingSoundFlag; CVector m_vecPos; - bool8 m_bReverbFlag; +#ifndef GTA_PS2 + bool8 m_bReverbFlag; // TODO: ifdef all the occurrences +#endif uint8 m_nLoopsRemaining; bool8 m_bRequireReflection; // Used for oneshots uint8 m_nOffset; @@ -219,10 +221,8 @@ public: tAudioEntity m_asAudioEntities[NUM_AUDIOENTITIES]; int32 m_anAudioEntityIndices[NUM_AUDIOENTITIES]; int32 m_nAudioEntitiesTotal; -#ifdef GTA_PC CVector m_avecReflectionsPos[NUM_AUDIO_REFLECTIONS]; float m_afReflectionsDistances[NUM_AUDIO_REFLECTIONS]; -#endif cAudioScriptObjectManager m_sAudioScriptObjectManager; // miami @@ -301,10 +301,8 @@ public: void InterrogateAudioEntities(); // inlined void AddSampleToRequestedQueue(); void AddDetailsToRequestedOrderList(uint8 sample); // inlined in vc -#ifdef GTA_PC void AddReflectionsToRequestedQueue(); void UpdateReflections(); -#endif void AddReleasingSounds(); void ProcessActiveQueues(); void ClearRequestedQueue(); // inlined in vc @@ -341,7 +339,7 @@ public: void ProcessVehicleFlatTyre(cVehicleParams ¶ms); bool8 ProcessVehicleRoadNoise(cVehicleParams ¶ms); bool8 ProcessWetRoadNoise(cVehicleParams ¶ms); - void ProcessVehicleEngine(cVehicleParams ¶ms); + bool8 ProcessVehicleEngine(cVehicleParams ¶ms); void UpdateGasPedalAudio(CVehicle *veh, int vehType); void PlayerJustGotInCar(); void PlayerJustLeftCar(); -- cgit v1.2.3 From d6fbf9fbe775ea838e8e8d8d607b88562f1c695b Mon Sep 17 00:00:00 2001 From: Sergeanur Date: Mon, 16 Aug 2021 10:02:29 +0300 Subject: PS2 audio reflections --- src/audio/AudioManager.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) (limited to 'src/audio/AudioManager.h') diff --git a/src/audio/AudioManager.h b/src/audio/AudioManager.h index 383644e0..c52eef8f 100644 --- a/src/audio/AudioManager.h +++ b/src/audio/AudioManager.h @@ -184,6 +184,24 @@ public: VALIDATE_SIZE(cVehicleParams, 0x1C); +#if GTA_VERSION < GTAVC_PC_10 +enum { + /* + REFLECTION_YMAX = 0, top + REFLECTION_YMIN = 1, bottom + REFLECTION_XMIN = 2, left + REFLECTION_XMAX = 3, right + REFLECTION_ZMAX = 4, + */ + + REFLECTION_TOP = 0, + REFLECTION_BOTTOM, + REFLECTION_LEFT, + REFLECTION_RIGHT, + REFLECTION_UP, + MAX_REFLECTIONS, +}; +#else enum { REFLECTION_NORTH = 0, REFLECTION_SOUTH, @@ -195,6 +213,7 @@ enum { REFLECTION_CEIL_EAST, MAX_REFLECTIONS, }; +#endif enum PLAY_STATUS { PLAY_STATUS_STOPPED = 0, PLAY_STATUS_PLAYING, PLAY_STATUS_FINISHED }; enum LOADING_STATUS { LOADING_STATUS_NOT_LOADED = 0, LOADING_STATUS_LOADED, LOADING_STATUS_FAILED }; -- cgit v1.2.3