mirror of https://github.com/OpenRCT2/OpenRCT2.git
Rename Peep::peep_is_lost_countdown to PeepIsLostCountdown
This commit is contained in:
parent
7357eeca60
commit
480009c0f6
|
@ -143,7 +143,7 @@ void marketing_set_guest_campaign(Peep* peep, int32_t campaignType)
|
|||
peep->VoucherType = VOUCHER_TYPE_RIDE_FREE;
|
||||
peep->VoucherArguments = campaign->RideId;
|
||||
peep->guest_heading_to_ride_id = campaign->RideId;
|
||||
peep->peep_is_lost_countdown = 240;
|
||||
peep->PeepIsLostCountdown = 240;
|
||||
break;
|
||||
case ADVERTISING_CAMPAIGN_PARK_ENTRY_HALF_PRICE:
|
||||
peep->ItemStandardFlags |= PEEP_ITEM_VOUCHER;
|
||||
|
@ -158,7 +158,7 @@ void marketing_set_guest_campaign(Peep* peep, int32_t campaignType)
|
|||
break;
|
||||
case ADVERTISING_CAMPAIGN_RIDE:
|
||||
peep->guest_heading_to_ride_id = campaign->RideId;
|
||||
peep->peep_is_lost_countdown = 240;
|
||||
peep->PeepIsLostCountdown = 240;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1420,14 +1420,14 @@ void Guest::CheckCantFindRide()
|
|||
return;
|
||||
|
||||
// Peeps will think "I can't find ride X" twice before giving up completely.
|
||||
if (peep_is_lost_countdown == 30 || peep_is_lost_countdown == 60)
|
||||
if (PeepIsLostCountdown == 30 || PeepIsLostCountdown == 60)
|
||||
{
|
||||
InsertNewThought(PEEP_THOUGHT_TYPE_CANT_FIND, guest_heading_to_ride_id);
|
||||
happiness_target = std::max(happiness_target - 30, 0);
|
||||
}
|
||||
|
||||
peep_is_lost_countdown--;
|
||||
if (peep_is_lost_countdown != 0)
|
||||
PeepIsLostCountdown--;
|
||||
if (PeepIsLostCountdown != 0)
|
||||
return;
|
||||
|
||||
guest_heading_to_ride_id = RIDE_ID_NULL;
|
||||
|
@ -1452,14 +1452,14 @@ void Guest::CheckCantFindExit()
|
|||
return;
|
||||
|
||||
// Peeps who can't find the park exit will continue to get less happy until they find it.
|
||||
if (peep_is_lost_countdown == 1)
|
||||
if (PeepIsLostCountdown == 1)
|
||||
{
|
||||
InsertNewThought(PEEP_THOUGHT_TYPE_CANT_FIND_EXIT, PEEP_THOUGHT_ITEM_NONE);
|
||||
happiness_target = std::max(happiness_target - 30, 0);
|
||||
}
|
||||
|
||||
if (--peep_is_lost_countdown == 0)
|
||||
peep_is_lost_countdown = 90;
|
||||
if (--PeepIsLostCountdown == 0)
|
||||
PeepIsLostCountdown = 90;
|
||||
}
|
||||
|
||||
/** Main logic to decide whether a peep should buy an item in question
|
||||
|
@ -1801,7 +1801,7 @@ void Guest::OnExitRide(ride_id_t rideIndex)
|
|||
if (ride != nullptr && peep_should_go_on_ride_again(this, ride))
|
||||
{
|
||||
guest_heading_to_ride_id = rideIndex;
|
||||
peep_is_lost_countdown = 200;
|
||||
PeepIsLostCountdown = 200;
|
||||
peep_reset_pathfind_goal(this);
|
||||
window_invalidate_flags |= PEEP_INVALIDATE_PEEP_ACTION;
|
||||
}
|
||||
|
@ -1864,7 +1864,7 @@ void Guest::PickRideToGoOn()
|
|||
{
|
||||
// Head to that ride
|
||||
guest_heading_to_ride_id = ride->id;
|
||||
peep_is_lost_countdown = 200;
|
||||
PeepIsLostCountdown = 200;
|
||||
peep_reset_pathfind_goal(this);
|
||||
window_invalidate_flags |= PEEP_INVALIDATE_PEEP_ACTION;
|
||||
|
||||
|
@ -3120,14 +3120,14 @@ static void peep_leave_park(Peep* peep)
|
|||
peep->guest_heading_to_ride_id = RIDE_ID_NULL;
|
||||
if (peep->PeepFlags & PEEP_FLAGS_LEAVING_PARK)
|
||||
{
|
||||
if (peep->peep_is_lost_countdown < 60)
|
||||
if (peep->PeepIsLostCountdown < 60)
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
peep->peep_is_lost_countdown = 254;
|
||||
peep->PeepIsLostCountdown = 254;
|
||||
peep->PeepFlags |= PEEP_FLAGS_LEAVING_PARK;
|
||||
peep->PeepFlags &= ~PEEP_FLAGS_PARK_ENTRANCE_CHOSEN;
|
||||
}
|
||||
|
@ -3242,7 +3242,7 @@ template<typename T> static void peep_head_for_nearest_ride(Guest* peep, bool co
|
|||
{
|
||||
// Head to that ride
|
||||
peep->guest_heading_to_ride_id = closestRide->id;
|
||||
peep->peep_is_lost_countdown = 200;
|
||||
peep->PeepIsLostCountdown = 200;
|
||||
peep_reset_pathfind_goal(peep);
|
||||
peep->window_invalidate_flags |= PEEP_INVALIDATE_PEEP_ACTION;
|
||||
peep->TimeLost = 0;
|
||||
|
|
|
@ -450,7 +450,7 @@ static uint8_t peep_pathfind_get_max_number_junctions(Peep* peep)
|
|||
return 8;
|
||||
}
|
||||
|
||||
if (peep->PeepFlags & PEEP_FLAGS_LEAVING_PARK && peep->peep_is_lost_countdown < 90)
|
||||
if (peep->PeepFlags & PEEP_FLAGS_LEAVING_PARK && peep->PeepIsLostCountdown < 90)
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
|
|
@ -694,7 +694,7 @@ struct Peep : SpriteBase
|
|||
union
|
||||
{
|
||||
uint8_t staff_orders;
|
||||
uint8_t peep_is_lost_countdown;
|
||||
uint8_t PeepIsLostCountdown;
|
||||
};
|
||||
uint8_t Photo1RideRef;
|
||||
uint32_t PeepFlags;
|
||||
|
|
|
@ -1528,7 +1528,7 @@ private:
|
|||
dst->path_check_optimisation = 0;
|
||||
dst->guest_heading_to_ride_id = src->guest_heading_to_ride_id;
|
||||
// Doubles as staff orders
|
||||
dst->peep_is_lost_countdown = src->peep_is_lost_countdown;
|
||||
dst->PeepIsLostCountdown = src->peep_is_lost_countdown;
|
||||
// The ID is fixed later
|
||||
dst->next_in_queue = src->next_in_queue;
|
||||
|
||||
|
|
|
@ -1209,7 +1209,7 @@ void S6Exporter::ExportSpritePeep(RCT2SpritePeep* dst, const Peep* src)
|
|||
}
|
||||
dst->path_check_optimisation = src->path_check_optimisation;
|
||||
dst->guest_heading_to_ride_id = src->guest_heading_to_ride_id;
|
||||
dst->peep_is_lost_countdown = src->peep_is_lost_countdown;
|
||||
dst->peep_is_lost_countdown = src->PeepIsLostCountdown;
|
||||
dst->photo1_ride_ref = src->Photo1RideRef;
|
||||
dst->peep_flags = src->PeepFlags;
|
||||
dst->pathfind_goal = src->PathfindGoal;
|
||||
|
|
|
@ -1474,7 +1474,7 @@ public:
|
|||
}
|
||||
dst->path_check_optimisation = src->path_check_optimisation;
|
||||
dst->guest_heading_to_ride_id = src->guest_heading_to_ride_id;
|
||||
dst->peep_is_lost_countdown = src->peep_is_lost_countdown;
|
||||
dst->PeepIsLostCountdown = src->peep_is_lost_countdown;
|
||||
dst->Photo1RideRef = src->photo1_ride_ref;
|
||||
dst->PeepFlags = src->peep_flags;
|
||||
dst->PathfindGoal = src->pathfind_goal;
|
||||
|
|
|
@ -395,7 +395,7 @@ int32_t Park::CalculateParkRating() const
|
|||
{
|
||||
happyGuestCount++;
|
||||
}
|
||||
if ((peep->PeepFlags & PEEP_FLAGS_LEAVING_PARK) && (peep->peep_is_lost_countdown < 90))
|
||||
if ((peep->PeepFlags & PEEP_FLAGS_LEAVING_PARK) && (peep->PeepIsLostCountdown < 90))
|
||||
{
|
||||
lostGuestCount++;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue