Integrate word_9A3684

This commit is contained in:
Marijn van der Werf 2016-08-20 22:20:18 +02:00
parent f862bc8675
commit d51a14e8ca
3 changed files with 39 additions and 1 deletions

View File

@ -4632,7 +4632,7 @@ static void vehicle_update_sound(rct_vehicle *vehicle)
vehicle->sound2_volume = (soundIdVolume >> 8) & 0xFF;
{
int ebx = RCT2_ADDRESS(0x009A3684, sint16)[vehicle->sprite_direction];
int ebx = word_9A3684[vehicle->sprite_direction];
int eax = ((vehicle->velocity >> 14) * ebx) >> 14;
eax = clamp(-127, eax, 127);

View File

@ -882,3 +882,39 @@ const sint32 dword_9A2970[] = {
546342, // 58
-110424, // 59
};
/** rct2: 0x009A3684 */
const sint32 word_9A3684[] = {
-0x4000, // 0
-0x3000, // 1
-0x2000, // 2
-0x1000, // 3
0, // 4
0x1000, // 5
0x2000, // 6
0x3000, // 7
0x4000, // 8
0x4800, // 9
0x4800, // 10
0x4800, // 11
0x4800, // 12
0x4800, // 13
0x4800, // 14
0x4800, // 15
0x4000, // 16
0x3000, // 17
0x2000, // 18
0x1000, // 19
0, // 20
-0x1000, // 21
-0x2000, // 22
-0x3000, // 23
-0x4000, // 24
-0x4800, // 25
-0x4800, // 26
-0x4800, // 27
-0x4800, // 28
-0x4800, // 29
-0x4800, // 30
-0x4800, // 31
};

View File

@ -36,4 +36,6 @@ extern const int MotionSimulatorTimeToSpriteMapCount;
extern const sint32 dword_9A2930[];
extern const sint32 dword_9A2970[];
extern const sint32 word_9A3684[];
#endif