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

Ship search target numbers excessively low with Campaign Operations rating system #3753

Closed
SuperStucco opened this issue Sep 2, 2023 · 1 comment · Fixed by #3933
Closed

Comments

@SuperStucco
Copy link

Similar to #3729, doing a ship search with the Campaign Operations overall unit rating is blowing out the numbers with a long running campaign. Due to the calculation using the uncapped Campaign Operations rating number, as opposed to the old Field Manual: Mercenaries fixed values, it ends up with vastly off-base target numbers:

public TargetRoll getShipSearchTarget(Campaign campaign, boolean jumpship) {
TargetRoll target = new TargetRoll(jumpship ? 12 : 10, "Base");
Person adminLog = campaign.findBestInRole(PersonnelRole.ADMINISTRATOR_LOGISTICS, SkillType.S_ADMIN);
int adminLogExp = (adminLog == null) ? SkillType.EXP_ULTRA_GREEN
: adminLog.getSkill(SkillType.S_ADMIN).getExperienceLevel();
for (Person p : campaign.getAdmins()) {
if ((p.getPrimaryRole().isAdministratorLogistics() || p.getSecondaryRole().isAdministratorLogistics())
&& p.getSkill(SkillType.S_ADMIN).getExperienceLevel() > adminLogExp) {
adminLogExp = p.getSkill(SkillType.S_ADMIN).getExperienceLevel();
}
}
target.addModifier(SkillType.EXP_REGULAR - adminLogExp, "Admin/Logistics");
target.addModifier(IUnitRating.DRAGOON_C - campaign.getUnitRatingMod(), "Unit Rating");
return target;
}
}

As with #3729 this could be handled with clamping the rating value to the Dragoon rating enums, or separate calculations for the two unit rating systems.

@pheonixstorm
Copy link
Collaborator

CO uses a different formula for calculating availability for Large Craft. CO p17

CO also does not care about Logistics, Command, etc admin or unit rating.

AtB was not designed for use with CO rules at all as it wasn't even released at the time AtB as a ruleset was written. The code for AtB was designed the same way for the most part. At some point Stratcon may change that but that is a question for @NickAragua

IllianiCBT added a commit to IllianiCBT/mekhq that referenced this issue Mar 26, 2024
HammerGS added a commit that referenced this issue Apr 6, 2024
+ PR #3922: Add missing cockpit costs and weights
+ PR #3944: Added Nag Dialog for Pregnant Combatants
+ Fix #3943: Unmaintained Unit Nag Dialog Suppressed for Units set to
Salvage
+ PR #3933: Fixes for #3729,#3817,#3753: Clamped Unit Rating Mod for
CamOps (redux)
+ PR #3923: Hide Toughness When 0
+ PR #3915: Added Dialog to Confirm New Campaign (redux)
+ PR #3908: Adjusted Default Tech Counts
+ PR #3967: Adjusted Zoom Speed on Interstellar Map Panel
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants