mirror of
https://github.com/GTAmodding/re3.git
synced 2024-11-15 11:39:03 +00:00
Some fixes for cAudioManager::SetupSuspectLastSeenReport
This commit is contained in:
parent
a2e59564c8
commit
d9c96a76fb
1 changed files with 101 additions and 24 deletions
|
@ -8976,32 +8976,109 @@ cAudioManager::SetupSuspectLastSeenReport()
|
|||
int32 color_post_modifier;
|
||||
|
||||
constexpr int32 gCarColourTable[][3] = {
|
||||
{3032, 248, 3032}, {3032, 249, 3032}, {3032, 250, 3032}, {3032, 251, 3032}, {258, 250, 3032},
|
||||
{3032, 252, 3032}, {3032, 253, 3032}, {260, 250, 3032}, {259, 250, 254}, {259, 3032, 3032},
|
||||
{258, 3032, 3032}, {258, 3032, 3032}, {258, 251, 3032}, {3032, 251, 3032}, {3032, 251, 3032},
|
||||
{3032, 251, 3032}, {3032, 251, 3032}, {3032, 251, 3032}, {3032, 251, 3032}, {259, 3032, 3032},
|
||||
{258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}, {3032, 255, 3032}, {3032, 255, 3032},
|
||||
{3032, 255, 3032}, {3032, 255, 3032}, {3032, 255, 3032}, {3032, 255, 3032}, {259, 3032, 3032},
|
||||
{258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}, {3032, 253, 3032}, {3032, 253, 3032},
|
||||
{3032, 253, 3032}, {3032, 253, 3032}, {3032, 253, 3032}, {3032, 253, 3032}, {259, 3032, 3032},
|
||||
{258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}, {3032, 256, 3032}, {3032, 256, 3032},
|
||||
{3032, 256, 3032}, {3032, 256, 3032}, {3032, 256, 3032}, {3032, 256, 3032}, {259, 3032, 3032},
|
||||
{258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}, {3032, 250, 3032}, {3032, 250, 3032},
|
||||
{3032, 250, 3032}, {3032, 250, 3032}, {3032, 250, 3032}, {3032, 250, 3032}, {259, 3032, 3032},
|
||||
{258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}, {3032, 252, 3032}, {3032, 252, 3032},
|
||||
{3032, 252, 3032}, {3032, 252, 3032}, {3032, 252, 3032}, {3032, 252, 3032}, {259, 3032, 3032},
|
||||
{258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}, {3032, 257, 3032}, {3032, 257, 3032},
|
||||
{3032, 257, 3032}, {3032, 257, 3032}, {3032, 257, 3032}, {3032, 257, 3032}, {259, 3032, 3032},
|
||||
{259, 3032, 3032}, {259, 3032, 3032}, {259, 3032, 3032}, {259, 3032, 3032}, {259, 3032, 3032},
|
||||
{259, 3032, 3032}, {259, 3032, 3032}, {259, 3032, 3032}, {259, 3032, 3032}, {259, 3032, 3032},
|
||||
{258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}, {258, 3032, 3032}};
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_BLACK, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_WHITE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_RED, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_PURPLE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_YELLOW, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_BRIGHT, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, SFX_POLICE_RADIO_BLUE, SFX_POLICE_RADIO_GREY},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, SFX_POLICE_RADIO_RED, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_RED, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_RED, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_RED, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_RED, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_RED, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_RED, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_ORANGE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_ORANGE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_ORANGE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_ORANGE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_ORANGE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_ORANGE, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_YELLOW, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_YELLOW, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_YELLOW, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_YELLOW, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_YELLOW, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_YELLOW, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_GREEN, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_GREEN, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_GREEN, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_GREEN, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_GREEN, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_GREEN, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_BLUE, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_PURPLE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_PURPLE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_PURPLE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_PURPLE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_PURPLE, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_PURPLE, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_SILVER, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_SILVER, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_SILVER, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_SILVER, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_SILVER, TOTAL_AUDIO_SAMPLES},
|
||||
{TOTAL_AUDIO_SAMPLES, SFX_POLICE_RADIO_SILVER, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_LIGHT, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES},
|
||||
{SFX_POLICE_RADIO_DARK, TOTAL_AUDIO_SAMPLES, TOTAL_AUDIO_SAMPLES}
|
||||
};
|
||||
|
||||
if(MusicManager.m_nMusicMode != 2) {
|
||||
if(MusicManager.m_nMusicMode != MUSICMODE_CUTSCENE) {
|
||||
veh = FindPlayerVehicle();
|
||||
if(veh) {
|
||||
if(60 - policeChannelTimer > 9) {
|
||||
color1 = veh->m_currentColour1;
|
||||
if(color1 >= 95) {
|
||||
if(color1 >= ARRAY_SIZE(gCarColourTable)) {
|
||||
debug("\n *** UNKNOWN CAR COLOUR %d *** ", color1);
|
||||
} else {
|
||||
main_color = gCarColourTable[color1][1];
|
||||
|
@ -9094,17 +9171,17 @@ cAudioManager::SetupSuspectLastSeenReport()
|
|||
++policeChannelTimer;
|
||||
policeChannelTimerSeconds = (policeChannelTimerSeconds + 1) % 60;
|
||||
}
|
||||
if(color_pre_modifier != 3032 && policeChannelTimer != 60) {
|
||||
if(color_pre_modifier != TOTAL_AUDIO_SAMPLES && policeChannelTimer != 60) {
|
||||
crimesSamples[policeChannelTimerSeconds] = color_pre_modifier;
|
||||
++policeChannelTimer;
|
||||
policeChannelTimerSeconds = (policeChannelTimerSeconds + 1) % 60;
|
||||
}
|
||||
if(main_color != 3032 && policeChannelTimer != 60) {
|
||||
if(main_color != TOTAL_AUDIO_SAMPLES && policeChannelTimer != 60) {
|
||||
crimesSamples[policeChannelTimerSeconds] = main_color;
|
||||
++policeChannelTimer;
|
||||
policeChannelTimerSeconds = (policeChannelTimerSeconds + 1) % 60;
|
||||
}
|
||||
if(color_post_modifier != 3032 && policeChannelTimer != 60) {
|
||||
if(color_post_modifier != TOTAL_AUDIO_SAMPLES && policeChannelTimer != 60) {
|
||||
crimesSamples[policeChannelTimerSeconds] = color_post_modifier;
|
||||
++policeChannelTimer;
|
||||
policeChannelTimerSeconds = (policeChannelTimerSeconds + 1) % 60;
|
||||
|
|
Loading…
Reference in a new issue