mirror of
https://github.com/halpz/re3.git
synced 2024-12-28 18:35:29 +00:00
Merge pull request #717 from theR4K/miami
Helicopters not ringing, and other audio stuff
This commit is contained in:
commit
e2314c7852
File diff suppressed because it is too large
Load diff
|
@ -241,13 +241,13 @@ public:
|
||||||
// "Should" be in alphabetic order, except "getXTalkSfx"
|
// "Should" be in alphabetic order, except "getXTalkSfx"
|
||||||
void AddDetailsToRequestedOrderList(uint8 sample);
|
void AddDetailsToRequestedOrderList(uint8 sample);
|
||||||
void AddPlayerCarSample(uint8 emittingVolume, int32 freq, uint32 sample, uint8 bank,
|
void AddPlayerCarSample(uint8 emittingVolume, int32 freq, uint32 sample, uint8 bank,
|
||||||
uint8 counter, bool notLooping);
|
uint8 counter, bool notLooping); //done
|
||||||
void AddReflectionsToRequestedQueue();
|
void AddReflectionsToRequestedQueue();
|
||||||
void AddReleasingSounds();
|
void AddReleasingSounds();
|
||||||
void AddSampleToRequestedQueue();
|
void AddSampleToRequestedQueue();
|
||||||
void AgeCrimes();
|
void AgeCrimes();
|
||||||
|
|
||||||
void CalculateDistance(bool &condition, float dist);
|
void CalculateDistance(bool &condition, float dist); //done
|
||||||
bool CheckForAnAudioFileOnCD() const;
|
bool CheckForAnAudioFileOnCD() const;
|
||||||
void ClearActiveSamples();
|
void ClearActiveSamples();
|
||||||
void ClearMissionAudio(uint8 slot);
|
void ClearMissionAudio(uint8 slot);
|
||||||
|
@ -275,7 +275,7 @@ public:
|
||||||
float GetCollisionLoopingRatio(uint32 a, uint32 b, float c) const; // not used
|
float GetCollisionLoopingRatio(uint32 a, uint32 b, float c) const; // not used
|
||||||
float GetCollisionOneShotRatio(int32 a, float b) const;
|
float GetCollisionOneShotRatio(int32 a, float b) const;
|
||||||
float GetCollisionRatio(float a, float b, float c, float d) const;
|
float GetCollisionRatio(float a, float b, float c, float d) const;
|
||||||
float GetDistanceSquared(const CVector &v) const;
|
float GetDistanceSquared(const CVector &v) const; //done
|
||||||
int32 GetJumboTaxiFreq() const;
|
int32 GetJumboTaxiFreq() const;
|
||||||
uint8 GetMissionAudioLoadingStatus(uint8 slot) const;
|
uint8 GetMissionAudioLoadingStatus(uint8 slot) const;
|
||||||
int8 GetMissionScriptPoliceAudioPlayingStatus() const;
|
int8 GetMissionScriptPoliceAudioPlayingStatus() const;
|
||||||
|
@ -287,7 +287,7 @@ public:
|
||||||
float GetVehicleNonDriveWheelSkidValue(uint8 wheel, CAutomobile *automobile,
|
float GetVehicleNonDriveWheelSkidValue(uint8 wheel, CAutomobile *automobile,
|
||||||
cTransmission *transmission, float velocityChange);
|
cTransmission *transmission, float velocityChange);
|
||||||
|
|
||||||
bool HasAirBrakes(int32 model) const;
|
bool HasAirBrakes(int32 model) const; //done
|
||||||
|
|
||||||
void Initialise();
|
void Initialise();
|
||||||
void InitialisePoliceRadio();
|
void InitialisePoliceRadio();
|
||||||
|
@ -302,13 +302,13 @@ public:
|
||||||
void PlayLoadedMissionAudio(uint8 slot);
|
void PlayLoadedMissionAudio(uint8 slot);
|
||||||
void PlayOneShot(int32 index, int16 sound, float vol);
|
void PlayOneShot(int32 index, int16 sound, float vol);
|
||||||
void PlaySuspectLastSeen(float x, float y, float z);
|
void PlaySuspectLastSeen(float x, float y, float z);
|
||||||
void PlayerJustGotInCar() const;
|
void PlayerJustGotInCar() const; //done
|
||||||
void PlayerJustLeftCar() const;
|
void PlayerJustLeftCar() const; //done
|
||||||
void PostInitialiseGameSpecificSetup();
|
void PostInitialiseGameSpecificSetup();
|
||||||
void PostTerminateGameSpecificShutdown();
|
void PostTerminateGameSpecificShutdown(); //done
|
||||||
void PreInitialiseGameSpecificSetup() const;
|
void PreInitialiseGameSpecificSetup() const; //done
|
||||||
void PreloadMissionAudio(uint8 slot, Const char *name);
|
void PreloadMissionAudio(uint8 slot, Const char *name);
|
||||||
void PreTerminateGameSpecificShutdown();
|
void PreTerminateGameSpecificShutdown(); //done
|
||||||
/// processX - main logic of adding new sounds
|
/// processX - main logic of adding new sounds
|
||||||
void ProcessActiveQueues();
|
void ProcessActiveQueues();
|
||||||
bool ProcessAirBrakes(cVehicleParams *params);
|
bool ProcessAirBrakes(cVehicleParams *params);
|
||||||
|
@ -320,17 +320,18 @@ public:
|
||||||
void ProcessBridgeOneShots();
|
void ProcessBridgeOneShots();
|
||||||
void ProcessBridgeWarning();
|
void ProcessBridgeWarning();
|
||||||
#endif
|
#endif
|
||||||
bool ProcessCarBombTick(cVehicleParams *params);
|
bool ProcessCarBombTick(cVehicleParams *params); //done
|
||||||
void ProcessCesna(cVehicleParams *params);
|
void ProcessCesna(cVehicleParams *params);
|
||||||
//void ProcessCrane();
|
//void ProcessCrane();
|
||||||
bool ProcessEngineDamage(cVehicleParams *params);
|
bool ProcessEngineDamage(cVehicleParams *params); //done
|
||||||
void ProcessEntity(int32 sound);
|
void ProcessEntity(int32 sound); //done
|
||||||
void ProcessExplosions(int32 explosion);
|
void ProcessExplosions(int32 explosion);
|
||||||
void ProcessFireHydrant();
|
void ProcessFireHydrant();
|
||||||
void ProcessFires(int32 entity);
|
void ProcessFires(int32 entity);
|
||||||
void ProcessFrontEnd();
|
void ProcessFrontEnd();
|
||||||
void ProcessGarages();
|
void ProcessGarages();
|
||||||
bool ProcessHelicopter(cVehicleParams *params);
|
void ProcessCarHeli(cVehicleParams* params); //done
|
||||||
|
void ProcessVehicleFlatTyre(cVehicleParams* params); //done
|
||||||
void ProcessJumbo(cVehicleParams *);
|
void ProcessJumbo(cVehicleParams *);
|
||||||
void ProcessJumboAccel(CPlane *plane);
|
void ProcessJumboAccel(CPlane *plane);
|
||||||
void ProcessJumboDecel(CPlane *plane);
|
void ProcessJumboDecel(CPlane *plane);
|
||||||
|
@ -345,22 +346,22 @@ public:
|
||||||
void ProcessOneShotScriptObject(uint8 sound);
|
void ProcessOneShotScriptObject(uint8 sound);
|
||||||
void ProcessPed(CPhysical *ped);
|
void ProcessPed(CPhysical *ped);
|
||||||
void ProcessPedOneShots(cPedParams *params);
|
void ProcessPedOneShots(cPedParams *params);
|
||||||
void ProcessPhysical(int32 id);
|
void ProcessPhysical(int32 id); //done
|
||||||
void ProcessPlane(cVehicleParams *params);
|
void ProcessPlane(cVehicleParams *params); //done
|
||||||
void ProcessPlayersVehicleEngine(cVehicleParams *params, CVehicle* veh);
|
void ProcessPlayersVehicleEngine(cVehicleParams *params, CVehicle* veh); //done
|
||||||
void ProcessProjectiles();
|
void ProcessProjectiles();
|
||||||
void ProcessRainOnVehicle(cVehicleParams *params);
|
void ProcessRainOnVehicle(cVehicleParams *params);
|
||||||
void ProcessReverb() const;
|
void ProcessReverb() const;
|
||||||
bool ProcessReverseGear(cVehicleParams *params);
|
bool ProcessReverseGear(cVehicleParams *params); //done
|
||||||
void ProcessScriptObject(int32 id);
|
void ProcessScriptObject(int32 id); //done
|
||||||
void ProcessSpecial();
|
void ProcessSpecial();
|
||||||
#ifdef GTA_TRAIN
|
#ifdef GTA_TRAIN
|
||||||
bool ProcessTrainNoise(cVehicleParams *params);
|
bool ProcessTrainNoise(cVehicleParams *params);
|
||||||
#endif
|
#endif
|
||||||
void ProcessVehicle(CVehicle *vehicle);
|
void ProcessVehicle(CVehicle *vehicle); //done, but need add model functions
|
||||||
bool ProcessVehicleDoors(cVehicleParams *params);
|
bool ProcessVehicleDoors(cVehicleParams *params); //done
|
||||||
void ProcessVehicleEngine(cVehicleParams *params);
|
void ProcessVehicleEngine(cVehicleParams *params); //done
|
||||||
void UpdateGasPedalAudio(CVehicle* veh, int vehType);
|
void UpdateGasPedalAudio(CVehicle* veh, int vehType); //done
|
||||||
void ProcessVehicleHorn(cVehicleParams *params);
|
void ProcessVehicleHorn(cVehicleParams *params);
|
||||||
void ProcessVehicleOneShots(cVehicleParams *params);
|
void ProcessVehicleOneShots(cVehicleParams *params);
|
||||||
bool ProcessVehicleReverseWarning(cVehicleParams *params);
|
bool ProcessVehicleReverseWarning(cVehicleParams *params);
|
||||||
|
@ -368,8 +369,10 @@ public:
|
||||||
bool ProcessVehicleSirenOrAlarm(cVehicleParams *params);
|
bool ProcessVehicleSirenOrAlarm(cVehicleParams *params);
|
||||||
bool ProcessVehicleSkidding(cVehicleParams *params);
|
bool ProcessVehicleSkidding(cVehicleParams *params);
|
||||||
void ProcessWaterCannon(int32);
|
void ProcessWaterCannon(int32);
|
||||||
void ProcessWeather(int32 id);
|
void ProcessWeather(int32 id); //done
|
||||||
bool ProcessWetRoadNoise(cVehicleParams *params);
|
bool ProcessWetRoadNoise(cVehicleParams *params);
|
||||||
|
void ProcessEscalators(); //done
|
||||||
|
void ProcessExtraSounds(); //done
|
||||||
|
|
||||||
int32 RandomDisplacement(uint32 seed) const;
|
int32 RandomDisplacement(uint32 seed) const;
|
||||||
void ReacquireDigitalHandle() const;
|
void ReacquireDigitalHandle() const;
|
||||||
|
@ -414,11 +417,11 @@ public:
|
||||||
void TranslateEntity(Const CVector *v1, CVector *v2) const;
|
void TranslateEntity(Const CVector *v1, CVector *v2) const;
|
||||||
|
|
||||||
void UpdateReflections();
|
void UpdateReflections();
|
||||||
bool UsesReverseWarning(int32 model) const;
|
bool UsesReverseWarning(int32 model) const; //done
|
||||||
bool UsesSiren(int32 model) const;
|
bool UsesSiren(int32 model) const;
|
||||||
bool UsesSirenSwitching(int32 model) const;
|
bool UsesSirenSwitching(int32 model) const;
|
||||||
|
|
||||||
CVehicle *FindVehicleOfPlayer();
|
CVehicle *FindVehicleOfPlayer(); //done
|
||||||
void SetPedTalkingStatus(CPed *ped, uint8 status);
|
void SetPedTalkingStatus(CPed *ped, uint8 status);
|
||||||
void SetPlayersMood(uint8 mood, int32 time);
|
void SetPlayersMood(uint8 mood, int32 time);
|
||||||
|
|
||||||
|
|
|
@ -219,6 +219,8 @@ extern int strncasecmp(const char *str1, const char *str2, size_t len);
|
||||||
|
|
||||||
#define clamp(v, low, high) ((v)<(low) ? (low) : (v)>(high) ? (high) : (v))
|
#define clamp(v, low, high) ((v)<(low) ? (low) : (v)>(high) ? (high) : (v))
|
||||||
|
|
||||||
|
#define clamp2(v, center, radius) ((v) < (center) ? Max(v, center - radius) : Min(v, center + radius))
|
||||||
|
|
||||||
inline float sq(float x) { return x*x; }
|
inline float sq(float x) { return x*x; }
|
||||||
#define SQR(x) ((x) * (x))
|
#define SQR(x) ((x) * (x))
|
||||||
|
|
||||||
|
|
|
@ -103,6 +103,8 @@ public:
|
||||||
void Update(void);
|
void Update(void);
|
||||||
void SwitchOff(void);
|
void SwitchOff(void);
|
||||||
void AddThisOne(CVector pos0, CVector pos1, CVector pos2, CVector pos3, bool b_isMovingDown);
|
void AddThisOne(CVector pos0, CVector pos1, CVector pos2, CVector pos3, bool b_isMovingDown);
|
||||||
|
bool IsActive() const { return m_bIsActive; };
|
||||||
|
const CVector& GetPosition() const { return m_midPoint; };
|
||||||
};
|
};
|
||||||
|
|
||||||
class CEscalators
|
class CEscalators
|
||||||
|
@ -114,6 +116,7 @@ public:
|
||||||
static void Update(void);
|
static void Update(void);
|
||||||
static void AddOne(CVector pos0, CVector pos1, CVector pos2, CVector pos3, bool b_isMovingDown);
|
static void AddOne(CVector pos0, CVector pos1, CVector pos2, CVector pos3, bool b_isMovingDown);
|
||||||
static void Shutdown(void);
|
static void Shutdown(void);
|
||||||
|
static const CEscalator& GetEscalator(int ind) { return aEscalators[ind]; };
|
||||||
};
|
};
|
||||||
|
|
||||||
class CMovingThing
|
class CMovingThing
|
||||||
|
|
|
@ -1489,7 +1489,7 @@ CAutomobile::ProcessControl(void)
|
||||||
CMatrix mat;
|
CMatrix mat;
|
||||||
mat.Attach(RwFrameGetMatrix(m_aCarNodes[CAR_BONNET]));
|
mat.Attach(RwFrameGetMatrix(m_aCarNodes[CAR_BONNET]));
|
||||||
CVector blade = mat.GetRight();
|
CVector blade = mat.GetRight();
|
||||||
blade = GetMatrix() * blade;
|
blade = Multiply3x3(blade, GetMatrix());
|
||||||
camDist /= Max(Sqrt(distSq), 0.01f);
|
camDist /= Max(Sqrt(distSq), 0.01f);
|
||||||
if(Abs(DotProduct(camDist, blade)) > 0.95f){
|
if(Abs(DotProduct(camDist, blade)) > 0.95f){
|
||||||
DMAudio.PlayOneShot(m_audioEntityId, SOUND_31, 0.0f);
|
DMAudio.PlayOneShot(m_audioEntityId, SOUND_31, 0.0f);
|
||||||
|
|
Loading…
Reference in a new issue