Skip to content
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 campaign group selector #370

Draft
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

SadPencil
Copy link
Member

@SadPencil SadPencil commented Sep 14, 2022

This PR is backward compatible as by default the option is off. Modders can enable the CampaignTagSelectorEnabled option to use this feature.

This feature enables modders to make a "choose your side" interface before the campaign selector. Choosing among "Act 1/Act 2/..." or any other tags is also possible.

The screenshot below shows the feature. (I am not an expert in beautifying user interfaces so it is only a working example. Fully configurable through ini files.)

img1
img2
img3

The modders define tags for missions in battle.ini and customize the selector window in CampaignTagSelector.ini using the new INItializableWindow ini format.

I use TSC v6 client as an example. The corresponding files are attached here.

TSC.v6.example.zip


Prerequisite of this PR: #364 (merged now) and #367 (requesting merge).

@github-actions
Copy link

github-actions bot commented Sep 14, 2022

Nightly build for this pull request:

@SadPencil SadPencil marked this pull request as draft September 14, 2022 03:35
@SadPencil SadPencil marked this pull request as ready for review September 14, 2022 03:41
@SadPencil SadPencil marked this pull request as draft September 16, 2022 07:34
@SadPencil SadPencil force-pushed the feature-campaign-group branch 2 times, most recently from d377097 to 8a25264 Compare September 30, 2022 20:08
@SadPencil SadPencil marked this pull request as ready for review September 30, 2022 20:11
@SadPencil
Copy link
Member Author

Ready for review now. Prerequisite #367.

@Rampastring
Copy link
Member

I'm not a fan of the design where the Battle.ini is constantly re-read and re-parsed here.

I'd rather read Battle.ini only once, have all the missions in the Missions list, and filter what is actually displayed in the list.

@Metadorius
Copy link
Member

Actually wouldn't it be better to have one INI per window? So separate screens would have different Battle.ini alternatives.

@Rampastring
Copy link
Member

I think the single file gives more control when it comes to the "Show All" view.

@SadPencil SadPencil force-pushed the feature-campaign-group branch 4 times, most recently from c659583 to 51208f1 Compare November 16, 2022 13:43
@SadPencil
Copy link
Member Author

I'm not a fan of the design where the Battle.ini is constantly re-read and re-parsed here.

I'd rather read Battle.ini only once, have all the missions in the Missions list, and filter what is actually displayed in the list.

Thanks for the suggestion. Code updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants