Giter Club home page Giter Club logo

hsr-optimizer's Introduction

About

Tools for optimizing your Honkai Star Rail builds, including the Character Optimizer and Relic Scorer.

image

image

Relic organizer and recommendations

image

Contact

Drop by the discord server for ideas/bugs/questions or just to hang out! https://discord.gg/rDmB4Un7qg

We're happy to have new contributors! Please reach out on the discord server #dev channel - we would love a hand on new features.

Credits

Shout outs to:

hsr-optimizer's People

Contributors

aidanhs avatar andrewngn13 avatar brainor avatar cnojima avatar elegant-jack avatar emmachase avatar faerongaming avatar fi00ds avatar fribbels avatar garfield550 avatar halimtech avatar icedynamix avatar kaixin-hc avatar kamii0909 avatar kasantos2 avatar kenste avatar khisaki avatar kodiecalcs avatar milo-sc avatar reveritas avatar robchendev avatar ronaldpereira avatar sethyboy0 avatar tiffanynwyeung avatar tzheliang avatar wolfbungalow avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

hsr-optimizer's Issues

[Bug] Better duplicate relic control

Repro steps

Currently there are a couple cases where the relic import doesn't dedupe relics correctly - For example, when you roll an item to +15, then run an OCR scan and import, and run the relic scorer import, there will be two copies of the newly rolled relic. The game shuffles the final substats if its a 3 starting stat piece.

Objective

We do deduplication on the order of relics currently, do some testing to evaluate if we really need that restriction or not and if not, fix up the dedupe code to only care about substat values instead of order

Note: I believe the shuffled order is deterministic, maybe we could use that to dedupe

[Feature]: Relic Grid filter UNEQUIPPED relics

Issue Template

Description

When finding/sorting relics, I would like to be able to filter-out equipped relics.

Expected Behavior

Filter checkbox/switch on UI to filter out equipped relics. Maybe enable the inverse as well. Since this infers a non-binary state, a dropdown with 3 options:

  1. All
  2. Equipped
  3. Unequipped

Actual Behavior

Best-case, sort by Character to float unequipped to the top.

Feature: Improve relic/character importer flow

Currently the relic & character importer are combined into one page where the user can select whether they want relics or characters + relics. It does work for now but might be less confusing if they were two different flows, especially since character imports are only supported by Kel-Z's scanner

Goal: Split up character / relic + character imports into different tabs on the Importer menu and specify that character importing only works on Kel-Z import

Feature: Export Data

Description

Implement Data Export. Export should include:

  • all relevant imported data (chars, lc, relics)
  • export: Optimizer settings, per-character
    • i believe this is stored in localStorage

Expected Behavior

Users should be able to import data from Kel-Z scanner/fribbels scanner.
Users should be able to optimize their character (and future teams).
Users should be able to customize optimizer settings (all filters), per character.
Users should be able to export their data.
Users should be able to reimport all data and filter settings.
Users' filter settings, per-character, should be rehydrated.

Actual Behavior

No export exists.

Additional Information

Import should be able to parse out non-scanner data as HSRO metadata and sync/merge with current filter states.

[Feature] Allow multiple save-file databases for swapping between multiple accounts

Motivation

Currently the optimizer only supports one loaded save database at a time. This functionality is OK for now but can be annoying for people with multiple accounts.

Objective

Goal: Allow for swapping between multiple account setups on the Import / Save tab. Also revisit the Save / Load tabs on that page to consolidate the Save / Load buttons together when selecting a DB profile.

Feature: Add a 'Use equipped relics' toggle for optimizer

Currently the way to filter out equipped relics is by using the Rank filter

Goal: Instead of having the rank filter, some people would like to just disable all equipped relics so this toggle would make it easy. Apply the filter to the permutations #s an also to the optimizer relic filters. The filter should not affect the current character's own relics

[Feature] Show roll quality (%) on relics

Motivation

Currently, relics can roll low / mid / high but the optimizer doesn't show them

Objective

Display roll quality as 80%/90%/100% and a sum of roll quality per relic. Possibly show these numbers when the relic is hovered

[Tech debt] Typescript migration

Now's a good time to start migrating to TS for maintainability - creating a tech debt task to track.

The vite migration has completed, now we're migrating typescript files piecemeal

[Tech debt] Parse trace stats and ability scaling from JSON files instead of hardcoded

Motivation

Currently trace stats are hardcoded in DataParser and the the ability scalings in the conditionals files. While this works, it can be mistake-prone and can get unwieldy to maintain.

Objective

Parse the trace stats out of the src/data/ json files and import the ability scaling values as well.

Low priority since we've already set up most of the characters and adding more isnt too bad

[Feature] Have an option to average out unrolled relics and include them in optimizer search

Motivation

Currently: Unrolled relics (+0, +3 etc) can have their main stats maxed, but their substats are included as-is, which means they are unlikely to be selected in the optimizer search even if they might be BiS if rolled.

Objective

Enable a optimizer toggle to allow 'predicting relic rolls' which really just means averaging out the remaining rolls between the relic's existing substats. Or maybe some other customizable way? Like have the relic preferentially roll into crit/etc as an option

Tech debt: Tab routing cleanup

Current tab switching logic is causing unnecessary rerenders - revisit Tabs.js and see if there are improvements to be made

Currently OptimizerForm rerenders are slowing down the tab nav

UX: Labels for filters after selection is made

In the Optimizer, setting filters for set/planar/main-stat relics removes the prompt-text from view.

As different slots can use the same main stat, the filter card becomes visually confusing:
Screenshot 2024-01-19 at 10 28 14 PM

The filters should have some indicator after selection(s) are made:

  • icon in selection
  • floating label

Feature: Add / Edit character & light cone button on Characters tab

Currently the only way to add new characters other than importing is by going to the Optimizer tab, then pressing Start.

Goal: Add a new button on Characters tab that opens a Modal: where the user can edit an existing character's level / light cone / etc or add a new character and edit their level / light cone / etc

[Feature] Relic substats input validator

Currently the optimizer doesn't validate the substats that the user manually inputs to check if is valid. This could lead to users making some input mistakes.

Goal: Implement a simple roll validation algorithm to check if the substats for the relics are correct.

[Project] Character scoring leaderboards

Could use some help with this one! More details in #dev-projects on discord

Idea: The character scorer is getting increasing amounts of traffic now - we can gather some interesting data here for a leaderboard per character

  • Collects anonymized builds per scorer entry (but allow an opt-in for sharing username?)
  • Rank based on a combat scenario instead of character score
  • Separate tab for leaderboards, link to it from scorer & character

Feature: Multiple saved loadouts per character

Currently characters can only have one loadout of equipped relics and previous builds are remembered unless the user keeps a screenshot. For example, swapping between slow bronya / fast bronya is difficult

Goal: Add a menu on the Character tab to show previously used builds, allow naming the builds, and swapping between builds. Possibly have a global preset so that whole teams' builds can be swapped at once.

Feature: Improve skill descriptions for character & light cone passives

Currently character passives are heavily simplified (e.g. Enhanced skill cd buff)

Goal: Have full descriptions for each skill & talent. These can also be in the form of hoverable tooltips in the interest of space. The description should also include the accurate numeric values by eidolon

[Feature] Tool to calculate # of days / # of runs of a cavern to farm an upgrade to each relic relic

Motivation

Currently some players have a hard time deciding which piece to farm for, or which slot to use Relic Remains on crafting, or the resin for a guaranteed main stat.

Objective

Calculate some sort of measure of the difficulty of farming an upgrade for a particular slot - such that the score ends up higher than the current relic in a slot, show it either on the relics card or an expanded menu

[Feature] Filter light cones by path

Currently any character can equip any light cone

Goal: The light cones menu should be filtered by class so Hunt cant equip Abundance light cones for example

Feature: Default preloaded filters for a character based on their desired sets and main stats

Currently, a new character being optimized will have blank stats / filters / sets / etc. Requires the user to input everything

Goal: Define preselected main stats at the very least for new characters by default. Possibly have a big visible button that says "Use recommended settings" and then when clicked it just fills out the form with the presets. Useful for new-user experience

hardcoded data in funtion getOverrideTraces seems to be wrong

When I was calculating today,I found the [Effect RES] value of Set that I had equipped became lower in the result table.
pic

Then I debugged the code and found that the hardcoded data was inaccurately defined in the function getOverrideTraces.

So I rechecked the data:
I just can't understand why you multiply RES by 2/3, but not all characters do that.

Luocha
[Constants.Stats.ATK_P]: 0.3, =should be=》 [Constants.Stats.ATK_P]: 0.28,

March 7th、Himeko、Welt、Serval、Sampo、Bailu
[Constants.Stats.RES]: 0.067, =should be=》 [Constants.Stats.RES]: 0.10,

Gepard\Natasha
[Constants.Stats.RES]: 0.12, =should be=》 [Constants.Stats.RES]: 0.18,

[Feature] Remove the Enemy HP slider and instead trigger passive effects based on the toggle

Motivation

Currently the way to trigger an enemy HP based toggle (+X% dmg when enemy < 50% hp) is to enable the toggle and then also select Enemy HP = 49%

Objective

Goal: This adds confusion for the user so its easier to just have the toggle control it instead of having to activate two things

Can search through the codebase for any references to enemy hp and update the conditionals

[Feature] Enable i18n/l10n Support

Current statically defined labels, strings, char/relic/LC, etc. are hard-coded en-US.

To enable international support, refactor app, DB, components, etc. to support locale-based display.

These changes may necessitate a UI/UX pass as non-latin languages will take less/more horizontal space in tables, cards, etc.

Feature: Improve the Relic Sets filter menu

Currently there is some confusion about how to use the Relic Sets filter since the in the 2+2 case, the second column isnt clickable.

Goal: Move to three sections:

4 Piece
2 Piece + Any
2 Piece + 2 Piece

This would better allow users to aim for rainbow builds with 2 + Any

[Feature] Single-relic OCR tool for importing

Motivation

Current we only have the Full-account import (takes a while), and the relic scorer import (limited to 24 characters, have to manually assign relics to characters)

Objective

Build an OCR tool on the optimizer site where users can paste their clipboard screenshot of a relic and have it OCR'd and imported.

Other thoughts: there's two different relic displays, handle both?

Image

Image

[Project] Expanded panel below the optimizer grid for more details about the selected build

Motivation

Currently a lot of the math is hidden - For example, skill damage increase, def shred, res pen, etc. Part of the reason is to minimize the amount of data transfer from threadworker buffers to the main thread.

Objective

A panel under the optimizer grid to show these hidden numbers would be useful for more detailed investigation into the effect of buffs / etc. To do this would most likely require refactoring the optimizerWorker.js so it can be called from the main thread on each click of the grid, and display the expanded numbers from a single row instead of calculating them all for the whole grid.

[Feature] Damage calculations should better take into account hit-based attacks

Motivation

Currently damage calcs for the most part assume the attacks are a single hit. The per-hit stacking mechanics of the ashblazing set are calculated by averaging the ATK buff out so it looks like it's ramping up, but is actually still counted as a single hit

We are probably OK for a while but Acheron seems to be heavily hit-count-based so that might be a good time to revisit

Objective

Have the calculations consider hit based attacks for each skill based on hit split https://honkai-star-rail.fandom.com/wiki/Damage#Hit_Split

Note: This should wait til after the optimization engine redesign

Feature: Add teammate buffs as a new optimizer panel

Currently teammate buffs can only be accounted for using the Combat Buffs section, which requires the user to add up Crit Dmg/Atk buffs etc

Goal: Add new optimizer cards for selecting teammate buffs and calculate buffs directly with sliders & toggles. Possibly import existing characters stats for buffs based on the buffer's stats like tingyun atk

[Feature] Online save file syncing/backup system

Motivation

Currently saves are only stored by browser storage, so the only way to transfer saves is by creating a save file and transferring it to diff computer

Objective

Some sort of discord / google / etc account system that syncs save files between computers, also opens the door for other account based features

Feature: Make main stat non-editable on the relic editing modal

Currently both the enhance (e.g. +12) and main stat are editable

Goal: Level and grade should be enough to calculate the main stat so users shouldn't be able to edit main stats directly.

Other manual relic entry improvements are welcome too -> Auto setting main stat on Hands / Head piece for example

[Feature] Relic locking / exclusion filter

Motivation

Currently the only way to exclude a specific relic is to equip it to a lower ranked character and enable the rank filter. Sometimes some users want to avoid using a specific relic because its reserved (for swapping onto fast bronya for example)

Objective

Allow relics to be 'locked' and excluded from optimization searches, or allow some other way to exclude a specific relic. The locked status should be displayed on the relic preview and in a Relics tab column / be filterable

Formatting issue with screenshots

Issue Template

Description

Using Firefox, when I download the screenshot the formatting for substats is broken. Please see the screenshots. Cleared cache, didn't fix. Tried on google chrome with the same data and it worked fine, so looks like it might have to do with the browser.

Steps to Reproduce

  1. Open the optimizer on Firefox
  2. Go to characters
  3. Click on the download button next to the "copy screenshot button"

Expected Behavior

Screenshot downloads and the formatting is correct

Actual Behavior

Screenshot downloads but the substat formatting is incorrect

Screenshots

Pela_2024-02-08_10-55-39
Topaz   Numby_2024-02-08_10-54-29
fribbels-optimizer-save(1).json

Additional Information

Tried it on different screen resolutions as well but had no effect.

[Project] Damage simulation with rotation based calculations

Motivation

Currently the optimizer only simulates a single event in combat, like a skill activation or followup attack. This is fine for finding builds, but when it comes to considering things like action advance, teammate buff duration, etc, there's more to it than just a single action.

Objective

This is an open ended milestone project that needs more discussion - but there might be some ways we can add team based simulations For example, simulate an skill - skill - ult rotation for x turns, or until the boss dies or something.

Feature: Allow double-click navigation in grids

Currently optimizing a character requires clicking the Optimizer tab and selecting the character name.

Goal: Double clicking a character on the Characters tab should open the Optimizer tab and auto-switch to the double clicked character. A similar effect can be enabled for the Relics grid to edit the relic

Feature: Split elemental damage into 7 elements

Currently the damage calculation assumes all damage corresponds to the selected character's element. This doesn't always work when there are buffs invovled, such as Tingyun's skill adding Lightning damage

Goal: Split elemental damage into all the different elements and apply elemental RES + buff separately

[Feature] Allow multiple weight profiles for each character

Motivation

Currently we have one weight profile per character - which can be edited but the scoring weights don't fully work for every build/playstyle: for example crit vs dot kafka / crit vs support silverwolf

Objective

How to actually do this is pretty open ended and have pros and cons, but some options to discuss:

  • Make the scoring conditional: if CV > 50 then use crit scoring profile, else use dot profile
  • Allow users to select a weight profile from the characters menu or the scoring modal. So you could have SW (support) or SW (DPS)

Note: This work is related to the leaderboards project

[Feature] Default preloaded enemy stats per content type

Motivation

Currently the user has to specify an enemy level and RES %.

Objective

Allow the user to preselect a type of boss, like "MoC 12 Kafka" or something and fill out the boss's corresponding stats by default without having to look it up

Note: Low priority since there's only a couple types of content right now and endgame is just level 95

Feature: Changelog page on optimizer site

Currently the changelog is only published to the discord server

Goal: Have the changelog displayed to users on a Changelog page, and also track their last visited date so it can pop up a modal showing the new updates on their next visit.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.