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 military menu control script #348

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Add military menu control script #348

wants to merge 1 commit into from

Conversation

Hop311
Copy link
Contributor

@Hop311 Hop311 commented Jan 19, 2025

No description provided.

@Hop311 Hop311 added the enhancement New feature or request label Jan 19, 2025
@Hop311 Hop311 force-pushed the military-menu branch 8 times, most recently from 01f366c to d5e626b Compare January 26, 2025 22:37
@Hop311 Hop311 marked this pull request as ready for review January 26, 2025 22:38
@Hop311 Hop311 force-pushed the military-menu branch 2 times, most recently from 252307c to ba92c0e Compare January 27, 2025 17:19
static const StringName morale_localisation_key = "PRESTIGE_MORALE_BONUS";
static const StringName organisation_localisation_key = "PRESTIGE_MAX_ORG_BONUS";

// Morale and organisation bonuses are always green with a + sign, matching the base game's behaviour
Copy link
Contributor

Choose a reason for hiding this comment

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

When negative they shouldn't be green.
Also can't you reuse the code to format modifier effects here?


if constexpr (Branch == LAND) {
// TODO - calculate (max) men and morale properly in ArmyInstance and RegimentInstances and set here
unit_group_dict[military_info_unit_group_men_count_key] = static_cast<uint64_t>(unit_group.get_unit_count() * 3000);
Copy link
Contributor

Choose a reason for hiding this comment

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

What are the 3000's doing here?
This should not be hardcoded.

static const StringName digin_localisation_key = "MILITARY_DIGIN_TOOLTIP";
static const String moving_days_replace_key = "$DAYS$";

int64_t days_spent_digging_in = 4;
Copy link
Contributor

Choose a reason for hiding this comment

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

Again, this should not be hardcoded.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

These are examples so reviewers can see that the UI side works, we don't yet have the SIM side data but I thought better to have something rather than leaving it completely unimplemented.

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

Successfully merging this pull request may close these issues.

2 participants