Change all invalidate_sprite_2(Vehicle*) to Vehicle->Invalidate() (#11935)

This commit is contained in:
hdpoliveira authored and GitHub committed 2020-06-11 20:42:11 +01:00
1 parent 2743629142
commit 55bb2eaec9
4 files changed
+13 -13

No files matched your search

+2 -2
View File
@@ -4088,7 +4088,7 @@ void Guest::UpdateRideEnterVehicle()
ride->cur_num_customers++;
vehicle->mass += Mass;
invalidate_sprite_2(vehicle);
vehicle->Invalidate();
MoveTo({ LOCATION_NULL, 0, 0 });
@@ -4134,7 +4134,7 @@ void Guest::UpdateRideLeaveVehicle()
vehicle->num_peeps--;
vehicle->mass -= Mass;
invalidate_sprite_2(vehicle);
vehicle->Invalidate();
if (ride_station >= MAX_STATIONS)
{
+2 -2
View File
@@ -393,7 +393,7 @@ int32_t Vehicle::CableLiftUpdateTrackMotion()
unk_F64E20.x = vehicle->x;
unk_F64E20.y = vehicle->y;
unk_F64E20.z = vehicle->z;
invalidate_sprite_2(vehicle);
vehicle->Invalidate();
while (true)
{
@@ -431,7 +431,7 @@ int32_t Vehicle::CableLiftUpdateTrackMotion()
}
vehicle->MoveTo(unk_F64E20);
invalidate_sprite_2(vehicle);
vehicle->Invalidate();
}
vehicle->acceleration /= _vehicleUnkF64E10;
if (_vehicleVelocityF64E08 >= 0)
+3 -3
View File
@@ -1004,7 +1004,7 @@ static void ride_remove_cable_lift(Ride* ride)
do
{
Vehicle* vehicle = GET_VEHICLE(spriteIndex);
invalidate_sprite_2(vehicle);
vehicle->Invalidate();
sprite_remove(vehicle);
spriteIndex = vehicle->next_vehicle_on_train;
} while (spriteIndex != SPRITE_INDEX_NULL);
@@ -1028,7 +1028,7 @@ static void ride_remove_vehicles(Ride* ride)
while (spriteIndex != SPRITE_INDEX_NULL)
{
Vehicle* vehicle = GET_VEHICLE(spriteIndex);
invalidate_sprite_2(vehicle);
vehicle->Invalidate();
sprite_remove(vehicle);
spriteIndex = vehicle->next_vehicle_on_train;
}
@@ -6435,7 +6435,7 @@ void ride_update_vehicle_colours(Ride* ride)
vehicle->colours.body_colour = colours.Body;
vehicle->colours.trim_colour = colours.Trim;
vehicle->colours_extended = colours.Ternary;
invalidate_sprite_2(vehicle);
vehicle->Invalidate();
spriteIndex = vehicle->next_vehicle_on_train;
carIndex++;
}
+6 -6
View File
@@ -3633,7 +3633,7 @@ void Vehicle::UpdateCollisionSetup()
train->sprite_height_positive = 5;
train->MoveTo({ train->x, train->y, train->z });
invalidate_sprite_2(train);
train->Invalidate();
train->SwingSpeed = 0;
}
@@ -5453,7 +5453,7 @@ void Vehicle::UpdateCrash()
curVehicle->animation_frame++;
if (curVehicle->animation_frame >= 8)
curVehicle->animation_frame = 0;
invalidate_sprite_2(curVehicle);
curVehicle->Invalidate();
}
curVehicle->var_C8 += 7281;
continue;
@@ -5490,7 +5490,7 @@ void Vehicle::UpdateCrash()
continue;
}
invalidate_sprite_2(curVehicle);
curVehicle->Invalidate();
CoordsXYZ curPosition = { curVehicle->x, curVehicle->y, curVehicle->z };
@@ -5506,7 +5506,7 @@ void Vehicle::UpdateCrash()
}
curVehicle->MoveTo(curPosition);
invalidate_sprite_2(curVehicle);
curVehicle->Invalidate();
if (curVehicle->sub_state == 1)
{
@@ -9587,7 +9587,7 @@ int32_t Vehicle::UpdateTrackMotion(int32_t* outStation)
unk_F64E20.x = car->x;
unk_F64E20.y = car->y;
unk_F64E20.z = car->z;
invalidate_sprite_2(car);
car->Invalidate();
while (true)
{
@@ -9633,7 +9633,7 @@ int32_t Vehicle::UpdateTrackMotion(int32_t* outStation)
}
// loc_6DBF20
car->MoveTo(unk_F64E20);
invalidate_sprite_2(car);
car->Invalidate();
loc_6DBF3E:
sub_6DBF3E(car);