Skip to content

refactor Park::CalculateSuggestedMaxGuests#17873

Merged
Gymnasiast merged 3 commits into
OpenRCT2:developfrom
Sadret:sgc_refactor
Sep 3, 2022
Merged

refactor Park::CalculateSuggestedMaxGuests#17873
Gymnasiast merged 3 commits into
OpenRCT2:developfrom
Sadret:sgc_refactor

Conversation

@Sadret

@Sadret Sadret commented Aug 21, 2022

Copy link
Copy Markdown
Contributor

Combines two loops into one.
Also fixes #17865. (With difficult guest generation, tested but unopened rides still contribute to the guest cap.)

uint32_t suggestedMaxGuests = 0;
uint32_t difficultGenerationBonus = 0;

// TODO combine the two ride loops

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think it makes sense to combine the two loops the old code was easier to read imho.

@duncanspumpkin duncanspumpkin added the network version Network version needs updating - double check before merging! label Aug 21, 2022
@duncanspumpkin

Copy link
Copy Markdown
Contributor

This will need a network version bump.

Comment thread src/openrct2/world/Park.cpp Outdated
@Gymnasiast

Copy link
Copy Markdown
Member

Next time, please use separate commits for the fix and for the refactor.

@Gymnasiast Gymnasiast enabled auto-merge September 3, 2022 14:26
@Gymnasiast Gymnasiast merged commit 2476977 into OpenRCT2:develop Sep 3, 2022
@tupaschoal tupaschoal added this to the v0.4.2 milestone Sep 3, 2022
@Sadret Sadret deleted the sgc_refactor branch September 3, 2022 18:12
@Sadret

Sadret commented Sep 3, 2022

Copy link
Copy Markdown
Contributor Author

Next time, please use separate commits for the fix and for the refactor.

Okay.
Thanks for fixing the issues and merging.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

network version Network version needs updating - double check before merging!

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Wrong Calculation of Soft Guest Cap

4 participants