-
Notifications
You must be signed in to change notification settings - Fork 181
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
Refactored Phenotype Enum; Added ATOW Attributes to Character Generation; Added 'Extra Attribute Randomization' Campaign Option #6564
base: master
Are you sure you want to change the base?
Conversation
- Replaced static resource-based getters in `Phenotype` with dynamic methods using resource bundles (`getLabel`, `getTooltip`, `getShortName`). - Introduced attribute modifiers and bonus traits for `Phenotype`. - Added the `isTrueborn` method for Clan phenotype classification. - Deprecation of legacy methods like `getToolTipText`, `getName`, `parseFromString`, and `getGroupingName`. - Reimplemented parsing logic with the `fromString` method supporting legacy inputs, labels, and ordinal formats. - Implemented and applied random attribute generation in `RandomSkillPreferences` and `DefaultPersonnelGenerator`. - Added UI elements and tooltips for randomizing attributes. - Enhanced unit tests for attribute randomization and label validity.
…tency by formatting component names with `{@code}`.
- Added phenotype-based SPA generation by incorporating bonus traits from a character's phenotype. - Imported `LVL3_ADVANTAGES` and adjusted logic to acquire phenotype traits as abilities. - Refactored minor formatting issues for improved readability.
…ed condition block.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #6564 +/- ##
============================================
+ Coverage 11.57% 11.58% +0.01%
+ Complexity 6401 6393 -8
============================================
Files 1085 1085
Lines 139499 139615 +116
Branches 21514 21546 +32
============================================
+ Hits 16149 16181 +32
- Misses 121776 121863 +87
+ Partials 1574 1571 -3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
…and align with localized key usage. - Refactored and standardized string formatting across affected files for improved readability. - Removed hardcoded personnel role strings from `Personnel.properties` and introduced `PersonnelRole.properties` to centralize localization resources. - Replaced `parseFromString` method with `fromString` for improved method naming and expanded functionality, including handling deprecated names and case variations. - Added unit tests to validate new `getLabel` functionality, `fromString` method, and missing resource keys for roles. - Updated XML generation and parsing methods to utilize the new role localization handling with `getLabel`.
Updated to incorporate the ATOW and ATOW:Companion attributes. I'm going to mark this as draft, as there is one last thing I want to do. |
…te random roleplay attributes for personnel.es.
…Random Roleplay Attributes" to "Reset Roleplay Attributes."
Added a personnel right-click menu GM option to set ATOW Attributes for existing characters. |
Flipping this back to live from draft |
Dev Notes
Phenotypes
Certain phenotypes increase or decrease attributes. Some phenotypes also provide specific Traits (SPAs, in our nomenclature). Both of these cases are now fully implemented. I also went ahead and cleaned up the enum a bit, switching it over to i18n and updating the Unit Tests.
Professions
ATOW includes a few archetypes which offer suggested starting points for each attribute score. I've set up the code so that characters will generate (on average) with those attribute scores. However, a few of the examples provided in the manuals are straight up awful.
The Tanker archetype is the worst example. If I were to implement that Archetype most vehicle crew would spawn with a -1 penalty to both gunnery and piloting. Needless to say, that shan't be happening.So while the code is set up to handle role-based attribute starting points, currently they're all set up to infer no modifier. I'm hoping to encourage a knowledgeable community member into providing some suggested starting attributes for our different professions. Once that's been sourced I can go in an update this (possibly in a separate PR).Edit: This turned out to be an error in the manuals. I've since gone through and updated the Professions to have appropriate starting Attribute scores.
Campaign Options & Character Generation
When a character is generated, they are done so with 5 in every Attribute. A d6 is then rolled for each Attribute. On a roll of 1 the Attribute is decreased by 1; on a roll of 6 the Attribute is increased by 1.
In Campaign Options players can enable 'Extra Random Attributes'. This works identical to the above, however the d6 will 'explode'. What this means is if you roll a 1, you decrease the Attribute by 1 and then roll again. And keep going until you stop rolling 1s (or hit the minimum Attribute score of 1 - this isn't Traveller, nobody is dying in character creation). Conversely, if you roll a 6 you keep increasing the Attribute score by 1 until you stop rolling 6s (or hit the maximum Attribute score of 10).