Integrate 0x00F1AD14, 0x00F1AD18

This commit is contained in:
Michał Janiszewski 2016-03-05 00:36:45 +01:00
parent fc2d48d0bb
commit 6dbe78b318
1 changed files with 8 additions and 8 deletions

View File

@ -2096,7 +2096,7 @@ void viewport_paint_setup()
void sub_688217_helper(uint16 ax, uint8 flag) void sub_688217_helper(uint16 ax, uint8 flag)
{ {
paint_struct *ps; paint_struct *ps, *ps_temp;
paint_struct *ps_next = RCT2_GLOBAL(0x00EE7884, paint_struct*); paint_struct *ps_next = RCT2_GLOBAL(0x00EE7884, paint_struct*);
do { do {
@ -2105,7 +2105,7 @@ void sub_688217_helper(uint16 ax, uint8 flag)
if (ps_next == NULL) return; if (ps_next == NULL) return;
} while (ax > ps_next->var_18); } while (ax > ps_next->var_18);
RCT2_GLOBAL(0x00F1AD14, paint_struct*) = ps; ps_temp = ps;
do { do {
ps = ps->next_quadrant_ps; ps = ps->next_quadrant_ps;
@ -2120,7 +2120,7 @@ void sub_688217_helper(uint16 ax, uint8 flag)
} }
} while (ps->var_18 <= ax + 1); } while (ps->var_18 <= ax + 1);
ps = RCT2_GLOBAL(0x00F1AD14, paint_struct*); ps = ps_temp;
uint8 rotation = get_current_rotation(); uint8 rotation = get_current_rotation();
while (true) { while (true) {
@ -2133,7 +2133,7 @@ void sub_688217_helper(uint16 ax, uint8 flag)
} }
ps_next->var_1B &= ~(1 << 0); ps_next->var_1B &= ~(1 << 0);
RCT2_GLOBAL(0x00F1AD18, paint_struct*) = ps; ps_temp = ps;
uint16 my_attached_x = ps_next->attached_x; uint16 my_attached_x = ps_next->attached_x;
uint16 my_attached_y = ps_next->attached_y; uint16 my_attached_y = ps_next->attached_y;
@ -2175,14 +2175,14 @@ void sub_688217_helper(uint16 ax, uint8 flag)
if (yes) { if (yes) {
ps->next_quadrant_ps = ps_next->next_quadrant_ps; ps->next_quadrant_ps = ps_next->next_quadrant_ps;
paint_struct *ps_temp = RCT2_GLOBAL(0x00F1AD18, paint_struct*)->next_quadrant_ps; paint_struct *ps_temp2 = ps_temp->next_quadrant_ps;
RCT2_GLOBAL(0x00F1AD18, paint_struct*)->next_quadrant_ps = ps_next; ps_temp->next_quadrant_ps = ps_next;
ps_next->next_quadrant_ps = ps_temp; ps_next->next_quadrant_ps = ps_temp2;
ps_next = ps; ps_next = ps;
} }
} }
ps = RCT2_GLOBAL(0x00F1AD18, paint_struct*); ps = ps_temp;
} }
} }