Feat/add weapon type bonus - #3698
Open
LPfontes wants to merge 3 commits into
Open
Conversation
…ctor validation - Add ADD_WEAPON_TYPE bonus definition to bonus_dictionary and BonusController - Dynamically evaluate add_weapon_type bonuses in MechWeapon.getWeaponTypes() - Update _ModSelector and Mech.HasCompatibleMods() to check all evaluated weapon types against allowed mod types
👷 Deploy request for cc-dev-preview pending review.Visit the deploys page to approve it
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR adds support for the
add_weapon_typebonus in COMP/CON to dynamically grant additional weapon types to weapons based on active frame traits or bonuses (e.g., the SSC Viceroy frame from Dustgrave, which treatsLauncherweapons as also beingCQBweapons).Key changes:
add_weapon_typebonus inbonus_dictionary.tsandBonusController.ts.add_weapon_typebonuses insideMechWeapon.getWeaponTypes(mech)._ModSelector.vueandMech.HasCompatibleMods()to validate weapon mods against all dynamically evaluated weapon types instead of just the static base type._WeaponSlotCard.vueand_mechWeaponCard.vue) to display dynamically evaluated weapon types (e.g.,Launcher / CQB).{
"name": "Near-Threat Targeting Processor",
"description": "The Viceroy treats its LAUNCHER weapons as though they are also CQB weapons with THREAT 3.",
"bonuses": [
{
"id": "add_weapon_type",
"val": "CQB",
"weapon_types": ["Launcher"]
},
{
"id": "threat",
"val": 3,
"weapon_types": ["Launcher"],
"replace": true
}
],
"synergies": [
{
"locations": ["weapon"],
"weapon_types": ["Launcher"],
"weapon_sizes": ["any"],
"detail": "This weapon is treated as though it were also a CQB weapon with THREAT 3."
}
]
},
Closes #3439
Type of Change
fix:)feat:)refactor:)docs:)chore:/build:/ci:)Checklist
Screenshots (if UI change)