-
Notifications
You must be signed in to change notification settings - Fork 78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for campaign status #1681
base: master
Are you sure you want to change the base?
Conversation
Either I'm blind or the implementation is somewhere else? What is |
Edit: For roman-style campaigns it shows the "You have successfully completed chapter X." screen after ending the game. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome, the last bit for campaigns! Review inline.
General hint: Try to make best use of the type system. E.g. "unsigned char" is/should be a (text-)character (although only since C++11 introduced uint8_t
) And using this narrow width number-type as parameters likely introduces overhead (registers are wider so often need to be masked) so it is even faster to just use unsigned
there.
Similar for string
which should be text. It can be stored in the config as a string for brevity but converted during load/save to a more appropriate type, especially when (scoped) enums can be used.
In general I like the changes, thanks! :)
|
||
BOOST_FIXTURE_TEST_CASE(Chapters0and1AreEnabledByDefault, CampaignSaveDataFixture) | ||
{ | ||
saveData[uid] = CampaignSaveCodes::defaultChaptersEnabled; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So the default is to enable the first 2 chapters? Why that? Wouldn't (only) the first one be a more sensible default?
I'm also a bit confused as you seem to be using indices and 1-based values for chapters
Maybe stick to indices and use an optional instead of zero
Rework in progress - converting to draft, will notify when ready for review. Resolving some conversations since they will not be relevant. |
Adds support for Roman-style (video) campaigns and the world campaign (video).
Fixed world campaign scripts to unlock the same continents as it was in S2.
Related to issues #1639 and #1177