GenerateIntegerRandomNumberTable

This commit is contained in:
Filip Gawin 2019-06-30 22:06:38 +02:00
parent e0eb0d991f
commit c6256aab4f
2 changed files with 9 additions and 0 deletions

View File

@ -9,6 +9,12 @@
cAudioManager &AudioManager = *(cAudioManager *)0x880FC0;
void
cAudioManager::GenerateIntegerRandomNumberTable()
{
for(int32 i = 0; i < 5; i++) { m_anRandomTable[i] = rand(); }
}
void
cAudioManager::PlayerJustLeftCar(void)
{
@ -2682,6 +2688,7 @@ cAudioManager::Service()
}
STARTPATCHES
InjectHook(0x57C290, &cAudioManager::GenerateIntegerRandomNumberTable, PATCH_JUMP);
InjectHook(0x56AD20, &cAudioManager::PlayerJustLeftCar, PATCH_JUMP);
InjectHook(0x570DB0, &cAudioManager::GetPhrase, PATCH_JUMP);

View File

@ -216,6 +216,8 @@ public:
char field_19195;
int m_nTimeOfRecentCrime;
void GenerateIntegerRandomNumberTable();
void PlayerJustLeftCar(void);
void Service();
void GetPhrase(uint32 *phrase, uint32 *prevPhrase, uint32 sample,