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

Unneeded items list not working right #285

Open
mbeyers opened this issue Sep 27, 2021 · 4 comments
Open

Unneeded items list not working right #285

mbeyers opened this issue Sep 27, 2021 · 4 comments

Comments

@mbeyers
Copy link

mbeyers commented Sep 27, 2021

The un-needed items list appears to be broken. It lists un-needed ship schematics and potentially needed items, but no longer lists items you can safely discard. For instance, I have a Kirk's tribble tray in my inventory, but have a FF Tribble Kirk, so this should be extraneous and should be displayed in the discardable area.

@ussjohnjay
Copy link
Contributor

It's possible that the tool might miss some unneeded items. My guess here is that your Tribble Kirk is not immortalized? That's one of the conditions it looks for currently, though this might be something we can fix.

Also, to be clear, are you saying that the tool also identifies items as unneeded even when you know you need them? That's definitely not the intended behavior and we'll have to look into that one with more urgency.

@MagForceSeven
Copy link

I have an example of it identifying items as unneeded when they are. I have two items: 2* Riker's Uniform and 2* Yar's Phaser. It reports those as "used to equip specific crew you already equipped" which is probably true. However, both of those items are used as components for equipment I'm in the process of building for Armus.

@wathou6
Copy link

wathou6 commented Oct 12, 2021

I have noticed this bug for months and ignored the unneeded items tab because of it.
I've gone through each item that's been identified as unneeded but half of the choices are inaccurate. It also hasn't identified unneeded items for crew that I have already FF.

@ussjohnjay
Copy link
Contributor

I can confirm that equipment might be listed as unneeded when they're actually needed subcomponents of a higher-level item, as @MagForceSeven pointed out.

@wathou6 The algorithm as written doesn't consider all items, so there's a good chance it will miss out on some equipment that is no longer needed. I think this was generally acceptable because it was better to list too few items than too many. But given the glaring oversight of needed subcomponents, we'll probably have to find a new approach for this tool and we might as well make it more comprehensive in the process.

Thanks for all the feedback. They're much appreciated!

ussjohnjay added a commit that referenced this issue Apr 3, 2022
Adds another filter to the fodder check that assumes an item is needed if a higher quality item of the same name is needed. For example, 3* Kira's Pistol (which is unneeded on its own for any crew on my roster) will no longer be listed because it's similar in name to 4* Kira's Pistol (which is needed on my roster by an unequipped Decoy Kira).

This will lead to some false positives (e.g. some 2* items are not actually building blocks of their equivalent 3* builds), but that's okay because it's better to be too conservative in recommendations than the alternative. Plus, the false positives will resolve themselves when the relevant crew become fully equipped.

Unfortunately, the tool still cannot account for partial builds by different names, e.g. 3* Tuvix's Uniform needs 2* Starfleet Security Uniform (VOY), in which case the latter might still be listed as fodder even if Tuvix is unequipped. This is also the case first raised in #285 about Yar's Phaser being a building block of Armus' Skin. To reduce the chances of this, lower quality equipment (i.e. 0* and 1*) remain ignored by the final tier of recommendations (Other Equipment). The new disclaimer is hopefully enough to warn users of this possibility.

If DataCore's items.json template gets updated with an incremental recipe tree, the `needsHigherQuality` function can be replaced with one that properly checks higher-level recipes for needed building blocks.

Made small changes to some variable names and the disclaimer for clarity.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants