-
Notifications
You must be signed in to change notification settings - Fork 61
fix: correct weapon type classifications in itemTypes.json #805
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
base: master
Are you sure you want to change the base?
fix: correct weapon type classifications in itemTypes.json #805
Conversation
WalkthroughAdded many new weapon ID→category mappings to config/itemTypes.json and updated public TypeScript unions in index.d.ts to reflect new/changed weapon type literals. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20–30 minutes
Suggested labels
Suggested reviewers
Poem
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
155b4dd to
0cb49cb
Compare
|
@Reuzehagel please rebase. (DO NOT MERGE UPSTREAM INTO YOUR BRANCH) |
0cb49cb to
19fc989
Compare
|
@Reuzehagel i just rebased it, you'll want to pull |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (2)
index.d.ts (1)
940-956: WeaponType expansion aligns with data; note TS surface-area changeAdding
Bow,Crossbow,Launcher,Sniper Rifle, andSpeargun(while retainingKitgunandCompanion Weapon) looks correct and matches the new item type mappings, soRivenMod['type']can now express the intended categories via${WeaponType} Riven Mod. This is a widening of the exported union, so TS consumers doing exhaustiveswitch/neverchecks may see new compile-time cases; worth calling out in release notes or a minor/major bump depending on your versioning policy.config/itemTypes.json (1)
966-1177: Primary weapon subclass mappings match design; verify ordering and coverageThis block cleanly encodes the intended primary subclasses:
- Shotguns: Kuva/Vaykor Hek, Kuva Sobek/Drakgoon/Kohm, Drakgoon/Kohm bases, Sancti/Tigris Prime, Astilla/Corinth/Cedo primes, Tenet Arca Plasmor, Mk1-Strun, Bubonico (
InfArmCannon), Convectrix (CrpSplitLaser).- Bows: Mk1-Paris, all
/Bows/and/Bow/paths.- Crossbows: Zhuge/Zhuge Prime, Attica, Nagantaka/Nagantaka Prime.
- Launchers: Ogris/Kuva Ogris, Tonkor/Kuva Tonkor, Penta/Secura/Carmine Penta, Zarr/Kuva Zarr, Torid, Tenet Envoy.
- Spearguns: Afentis, Scourge/Scourge Prime, Javlok (incl. Grineer flame spear variants), Tenet Ferrox.
- Sniper rifles: Rubico/Rubico Prime, Vectis/Vectis Prime, Lanka, Vulkar/Vulkar Wraith, Snipetron/Vandal, Komorex, Sporothrix/Coda Sporothrix, Perigale, plus the generic sniper paths.
The placements before
/LongGuns→RifleandClanTech/.*Weapon→Riflelook correct to ensure these don’t get typed as generic Rifles instead.Two follow-ups to consider:
- Confirm the matcher truly stops on the first hit for non-
appendentries; if it keeps scanning and overwriting, later generic patterns could still re-type these asRifle.- Double-check whether any base variants (e.g., non-Tenet Ferrox, any newer launcher/speargun/sniper with slightly different paths) are missing and should also get explicit entries alongside these.
If both checks pass, this block should fix the reported mis-typings without collateral reclassification.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
config/itemTypes.json(2 hunks)index.d.ts(1 hunks)
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: SlayerOrnstein
Repo: WFCD/warframe-items PR: 663
File: config/masterableCategories.json:1-2
Timestamp: 2024-12-03T23:47:24.677Z
Learning: In the 'warframe-items' repository, when suggesting changes to regex patterns in 'config/masterableCategories.json', ensure that added patterns only include items relevant to the current PR context, and avoid adding items not present in the context.
📚 Learning: 2024-12-03T23:47:24.677Z
Learnt from: SlayerOrnstein
Repo: WFCD/warframe-items PR: 663
File: config/masterableCategories.json:1-2
Timestamp: 2024-12-03T23:47:24.677Z
Learning: In the 'warframe-items' repository, when suggesting changes to regex patterns in 'config/masterableCategories.json', ensure that added patterns only include items relevant to the current PR context, and avoid adding items not present in the context.
Applied to files:
config/itemTypes.json
🔇 Additional comments (1)
config/itemTypes.json (1)
906-931: Secondary classifications look right; confirm Grimoire/Tome intentThe new mappings here look consistent with in-game behavior:
/KuvaLich/Secondaries/,VTDetron, andMK1Furis→PistolMK1Kunai→Throwing- Entrati wrist gun and Twin Grakatas →
Pistol/Dual PistolsrespectivelyThe only subtle point is
/Tenno/Grimoire/→PistolwhileTenno/Grimoirelater in the file still maps toTome. Depending on how the matcher walks this array (first-match vs last-match, substring vs regex), one of these will dominate. Please double-check which type you actually want exposed for Grimoire indata/json/Secondary.jsonand that the matching logic won’t silently pick the unintended one.
|
Thanks for the PR always good to fix some mistakes in the data, it seems the type checks were not happy though, gonna check it tomorrow |
|
well, just on the last error in the list, it's a Bow Mod and it's getting |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
First good job i know it takes some time to add these things (if you didn't use ai), most of the additions are okay and could be merged fast but the ones that add a new data type we're gonna to have to discuss them first.
The short and long format for id are not really a thing in the itemTypes.json but using the long format helps in knowing that entry refers to a single item, so long id format should be used here in most entries.
Let's just agree on the already defined types:
Shotgun is basically reserved for weapons that shoots a lot of pellets, that's a shotgun in warframe.
The rifle is a weapon that (in general) shoots one pellet per round and for pratical purposes is basically any weapon that doesn't have a more defined type.
We should discuss the following:
Sniper Rifle should we use just Sniper or Sniper Rifle? Would a sniper be a rifle that has a scope (right click to zoom)?
Pistol would be basically a secondary rifle
Launcher a rifle that shoots a projectile that explodes?
What would the need be in adding speargun and crossbow?
Dont merge the suggestions until @TobiTenno (need your help on this one) puts a thumbs up emoji on them
In retrospect i should have done fewer suggestions with more code in it, it seems github doesnt handle very well this amount of suggestions.
| { | ||
| "id": "/Bows/", | ||
| "name": "Bow" | ||
| }, | ||
| { | ||
| "id": "/Bow/", | ||
| "name": "Bow" | ||
| }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| { | |
| "id": "/Bows/", | |
| "name": "Bow" | |
| }, | |
| { | |
| "id": "/Bow/", | |
| "name": "Bow" | |
| }, | |
| { | |
| "id": "/(Tenno|Grineer|Corpus)/Bows?", | |
| "regex": true, | |
| "name": "Bow" | |
| }, | |
| { | |
| "id": "/Syndicates/[a-zA-Z]+/Bows?", | |
| "regex": true, | |
| "name": "Bow" | |
| }, |
config/itemTypes.json
Outdated
| "name": "Sniper Rifle" | ||
| }, | ||
| { | ||
| "id": "/LongGuns/PrimeLightningGun/", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does vadarya have scope?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes it does it has a scoped mode and unscoped mode iirc. Wiki also classifies it as a sniper.
|
i agree with the overall suggestions for change, i'm worried that these are all going to perpetuate a pattern of adding individual items into this itemTypes file, which is not the intention. Commonalities in unique names should be found and summarized, and every item should not need to be overridden to have the right type |
|
I agree with you and i think the same but it's pretty messy sometimes that make any pattern out of it basically impossible, as long as we can figure out a pattern it should take precedence otherwise it's gonna to be messy and there's basically nothing we can do about it (other than not adding these because we dont like it) |
|
@Reuzehagel please refactor the ids that are meant to a single weapon and ill delete the suggestions, its killing browser performance. |
|
For weapon type definitions:
I'll also refactor the IDs to use the full format as suggested when I get around to it tomorrow. |
|
Lowkey no idea what happened... let me try again |
Primary weapons: - Add Shotgun type for Kuva/Syndicate shotguns, Prime shotguns, Bubonico, Convectrix - Add Bow type for all bow weapons including Mk1-Paris - Add Crossbow type for Zhuge, Attica, Nagantaka variants - Add Launcher type for Ogris, Tonkor, Penta, Zarr variants, Torid, Tenet Envoy - Add Speargun type for Scourge, Ferrox, Javlok, Afentis - Add Sniper Rifle type for Rubico, Vectis, Lanka, Vulkar, etc. These weapons previously used the generic "Rifle" type (the default for Primary weapons). Adding specific types improves mod compatibility matching in build tools and community apps. Also add these weapon types to the WeaponType union in index.d.ts for proper RivenMod typing.
6231275 to
7d3d59a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please the full format should include the entire uniqueName, don't do rebases with upstream at this point and do not squash commits yet. Also see the previous review i already updated it.
| { | ||
| "id": "/Lotus/Weapons/Corpus/LongGuns/CrpSentAmlgSniper/", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/ClanTech/Energy/Railgun", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Tenno/LongGuns/TnQuadSniper/", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Tenno/LongGuns/FiveShotSniper/", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Tenno/LongGuns/RubicoPrime/", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Tenno/Rifle/SniperRifle", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Tenno/Rifle/VandalSniperRifle", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Infested/LongGuns/InfSniperRifle/", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Infested/InfestedLich/LongGuns/CodaSporothrix", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Tenno/LongGuns/PrimeLightningGun/", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Tenno/Rifle/TennoSniperRifle", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Tenno/LongGuns/PrimeVectis/", | ||
| "name": "Sniper" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Grineer/LongGuns/GrineerSniperRifle/", | ||
| "name": "Sniper" | ||
| }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| { | |
| "id": "/Lotus/Weapons/Corpus/LongGuns/CrpSentAmlgSniper/", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/ClanTech/Energy/Railgun", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/LongGuns/TnQuadSniper/", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/LongGuns/FiveShotSniper/", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/LongGuns/RubicoPrime/", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/Rifle/SniperRifle", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/Rifle/VandalSniperRifle", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Infested/LongGuns/InfSniperRifle/", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Infested/InfestedLich/LongGuns/CodaSporothrix", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/LongGuns/PrimeLightningGun/", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/Rifle/TennoSniperRifle", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/LongGuns/PrimeVectis/", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/LongGuns/GrineerSniperRifle/", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/LongGuns/[a-zA-Z]*Sniper(Rifle)?/", | |
| "regex": true, | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/(Tenno|Grineer|Corpus)/Rifle/[a-zA-Z]*Sniper(Rifle)?", | |
| "regex": true, | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/ClanTech/Energy/Railgun", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/LongGuns/RubicoPrime/RubicoPrimeWeapon", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Infested/InfestedLich/LongGuns/CodaSporothrix", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/LongGuns/PrimeLightningGun/PrimeLightningGun", | |
| "name": "Sniper" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Tenno/LongGuns/PrimeVectis/PrimeVectisRifle", | |
| "name": "Sniper" | |
| }, |
| { | ||
| "id": "/Lotus/Weapons/Corpus/LongGuns/CrpBriefcaseLauncher/", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/ClanTech/Chemical/RocketLauncher", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/ClanTech/Bio/BioWeapon", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Corpus/LongGuns/GrenadeLauncher/", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Syndicates/PerrinSequence/LongGuns/PSPenta", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Grineer/LongGuns/GrnGrenadeLauncher/", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Tonkor/", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Ogris/", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Zarr/", | ||
| "name": "Launcher" | ||
| }, | ||
| { | ||
| "id": "/Lotus/Weapons/Grineer/LongGuns/GrnCannon/", | ||
| "name": "Launcher" | ||
| }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| { | |
| "id": "/Lotus/Weapons/Corpus/LongGuns/CrpBriefcaseLauncher/", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/ClanTech/Chemical/RocketLauncher", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/ClanTech/Bio/BioWeapon", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Corpus/LongGuns/GrenadeLauncher/", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Syndicates/PerrinSequence/LongGuns/PSPenta", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/LongGuns/GrnGrenadeLauncher/", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Tonkor/", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Ogris/", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Zarr/", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/LongGuns/GrnCannon/", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/LongGuns/(Grn)?(Grenade|Cannon)[a-zA-Z]*/", | |
| "regex": true, | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Corpus/LongGuns/CrpBriefcaseLauncher/CrpBriefcaseLauncher", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/ClanTech/Chemical/RocketLauncher", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/ClanTech/Bio/BioWeapon", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Syndicates/PerrinSequence/LongGuns/PSPenta", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Tonkor/KuvaTonkor", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Ogris/KuvaOgris", | |
| "name": "Launcher" | |
| }, | |
| { | |
| "id": "/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Zarr/KuvaZarr", | |
| "name": "Launcher" | |
| }, |
{
"id": "/HeavyWeapons/GrnHeavyGrenadeLauncher",
"name": "Launcher"
},Can you see for me if kuva-ayanga supports adhesive blast? i dont have it.
I dont know what to do with the tenet ferrox https://wiki.warframe.com/w/Adhesive_Blast
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Kuva Ayanga does not support adhesive blast. The wiki classifies it as a 'Archgun'.
Tenet Ferrox I think is an edge case I think... Warframe doing Warframe things...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we treat those either as 'Archgun' or 'Heavy Gun', can't remember which
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mausolon:
"type": "Arch-gun"
See line 690266 in All.json.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's just ignore the tenet ferrox and the kuva-ayanga.
…d partial weapon paths to use complete paths
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (1)
config/itemTypes.json (1)
967-1043: Consider consolidating individual weapon IDs with regex patterns for performance and maintainability.This section introduces many entries with individual, fully-qualified weapon paths (e.g.,
/Lotus/Weapons/Grineer/KuvaLich/LongGuns/Hek/KuvaHekWeapon). While this approach ensures precise matching, it creates maintenance overhead and was flagged by reviewers as potentially harmful to browser performance when representing single weapons.The code already uses broader pattern-based entries elsewhere in the file (e.g., line 1031–1036 with trailing slashes like
/Lotus/Weapons/Tenno/Bows/). Consolidating similar weapon families with regex patterns would improve performance and reduce duplication.Examples of potential consolidation opportunities:
- Lines 971–985 (Kuva variants: Hek, Sobek, Drakgoon, Kohm) could use a regex pattern like
/(Tenno|Grineer)/KuvaLich/LongGuns/.*withregex: true- Lines 1067–1085 (Launcher entries) include several individual paths that might benefit from broader patterns
Consider reviewing the regex suggestions from prior review comments (e.g., AyAyEm's Bow pattern suggestion) and applying similar consolidation here.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
config/itemTypes.json(3 hunks)
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: SlayerOrnstein
Repo: WFCD/warframe-items PR: 663
File: config/masterableCategories.json:1-2
Timestamp: 2024-12-03T23:47:24.677Z
Learning: In the 'warframe-items' repository, when suggesting changes to regex patterns in 'config/masterableCategories.json', ensure that added patterns only include items relevant to the current PR context, and avoid adding items not present in the context.
📚 Learning: 2024-12-03T23:47:24.677Z
Learnt from: SlayerOrnstein
Repo: WFCD/warframe-items PR: 663
File: config/masterableCategories.json:1-2
Timestamp: 2024-12-03T23:47:24.677Z
Learning: In the 'warframe-items' repository, when suggesting changes to regex patterns in 'config/masterableCategories.json', ensure that added patterns only include items relevant to the current PR context, and avoid adding items not present in the context.
Applied to files:
config/itemTypes.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Agent
🔇 Additional comments (1)
config/itemTypes.json (1)
1087-1137: Verify individual Sniper rifle IDs match game data and cannot be consolidated further.The Sniper entries mix specific full-path IDs (e.g., lines 1103–1104, 1131–1132) with regex patterns (e.g., lines 1107–1108). Confirm that each individual entry is necessary and that there isn't a shared naming pattern that would allow consolidation (e.g., paths containing
SniperorSniperRifle).This aligns with the earlier feedback about avoiding per-item overrides where patterns are available.
|
Sorry for making some mistakes btw. Ive never really used Git, besides having a single branch for some personal things. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR fixes weapon type classifications in the itemTypes.json configuration file to correctly categorize primary weapons by their specific weapon classes (Shotgun, Bow, Sniper, Launcher) instead of defaulting all of them to "Rifle". This is important for mod compatibility in Warframe, as different weapon classes accept different sets of mods. The changes include updates to TypeScript type definitions to add new weapon types ('Bow', 'Launcher', 'Sniper') to the WeaponType union, rename 'Sniper Rifle' to 'Sniper', and remove unused types ('Crossbow', 'Speargun').
Key changes:
- Added ~230 explicit weapon path mappings for Shotguns, Bows, Launchers, and Snipers that were previously falling through to the generic "Rifle" classification
- Added 'Bow', 'Launcher', 'Sniper', 'Companion Weapon', and 'Kitgun' to the WeaponType union
- Renamed 'Sniper Rifle' to 'Sniper' and removed 'Crossbow' and 'Speargun' from ItemType
- Corrected PrimeStrun path from partial to full weapon path
- Added explicit mappings for secondary weapons including Kuva Lich variants, MK1 series, Grimoires, and Twin Grakatas
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| index.d.ts | Updates TypeScript type definitions: adds weapon types to WeaponType union, renames 'Sniper Rifle' to 'Sniper', removes 'Crossbow' and 'Speargun' types |
| config/itemTypes.json | Adds ~240 explicit weapon path mappings to correctly classify Shotguns, Bows, Launchers, Snipers, and various secondary weapons instead of defaulting to "Rifle" |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "id": "/Lotus/Weapons/Tenno/LongGuns/PrimeStrun/PrimeStrunWeapon", | ||
| "name": "Shotgun" | ||
| }, |
Copilot
AI
Dec 3, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The path for PrimeStrun has been changed from a partial path "/LongGuns/PrimeStrun" to a full path "/Lotus/Weapons/Tenno/LongGuns/PrimeStrun/PrimeStrunWeapon". Verify that the old shorter path was indeed incorrect and that this longer path is the actual path used in the game data. If both paths are valid, consider whether the shorter path should be retained for backward compatibility or if it was never functional.
|
@Reuzehagel when you have time, take at the requested changes. |
What did you fix?
Primary weapons were incorrectly typed as "Rifle" when they should have specific weapon class types for mod compatibility:
These weapons were falling through to the itemType patterns which assigned them "Rifle" type.
Reproduction steps
npm run builddata/json/Primary.jsonfor weapons like "Kuva Hek", "Paris", "Ogris""type": "Rifle"instead of their correct weapon classEvidence/screenshot/link to line
Reference: https://wiki.warframe.com/w/Template:WeaponNav#Primary
And Discord messages sent by Reuzehagel (Nov 27th 20:48)
The Wiki categorizes these weapons into classes (Shotguns, Bows, Sniper Rifles, etc.) which affects mod compatibility.
Considerations
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.