Giter Club home page Giter Club logo

discretize / discretize-gear-optimizer Goto Github PK

View Code? Open in Web Editor NEW
12.0 2.0 15.0 249 MB

Gear optimizer for guild wars 2. Optimizes the stat sets for optimal damage/HP/healing depending on selected constraints.

Home Page: https://optimizer.discretize.eu

License: GNU General Public License v3.0

JavaScript 41.56% HTML 0.29% TypeScript 26.08% Rust 8.41% CSS 0.02% Dockerfile 0.10% YAML 23.53%
gw2 guildwars2 gearoptimizer optimizer fractals raids mmorpg

discretize-gear-optimizer's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

discretize-gear-optimizer's Issues

generic performance ideas issue

  • Cache gear stats that were not relevant (see: https://discord.com/channels/301270513093967872/842629146857177098/858132195701293101)
  • Cache a bunch of _testCharacter calls and run them in a web worker
  • Preprocess flat modifiers into settings.baseAttributes during setup; replace preConversionAttributes unnecessary object clone with referencing baseattributes, preprocess additive mods into multiplicative ones, stop storing multipliers as arrays of length 1
  • cache the results of post-conversion [condition damage, expertise] => condition portion of damage, as I don't see any way for that not to have the same result

Open Source this project

I propose to open source the gear optimizer once the react recode is done.

MITM or GPLv2/3 ? I'm personally in favour of GPLv3. Other opinions?

  • Figure out the license
  • get everyones approval for the change of the license
  • Clean up the project (#108 , rework the readme

rewrite addModifiers and updateAttributes

ha I never finished this

  • addModifiers has a ton of unnecessary checks
  • I store a bunch of things in 1-length arrays and "iterate" them, leftover from when they didn't used to be deduplicated
  • flat modifiers and additive modifiers can all be calculated beforehand
  • $.each[] calls are iterating over way too much
  • can probably just remove most of the "does this exist" checks and preset most things

idea: start iteration from the "middle"

Right now, if you select viper/sinister/grieving, the optimizer always starts on full viper and ends on full grieving.

If settings.affixes[i] were instead settings.affixes[slot][i], one could rearrange the affix order on a per-slot basis. So settings.affixes[helm] could be [viper, sinister, grieving], but settings.affixes[chest] could be [grieving sinister, viper]. Every combination would still get iterated through, but the order would be different. This could speed up getting to the interesting combinations of a 3 (or 4+) stat optimization, e.g. so you can cancel earlier when you realize one of the affixes/infusions you have selected is never used.

This may be a performance gain, if getting a higher worstScore earlier reduces shuffling. Especially useful if multithreading the optimizer.

Care must be taken to not break ring/acc/shoulder/glove/boot deduplication.

Fix bugs in gw2-ui

Link: https://github.com/ManuelHaag/gw2-ui

Currently, the performance of gw2-ui is in a terrible state; this should get fixed before we integrate gw2-ui into the optimizer. Check out the project, go to the refactor-build branch, run the develop server and navigate to the performance page in the browser. All of the gw2icons load extremely slow, one at a time.

I've tried to setup a basic implementation of gw2-ui for the optimzer locally, however, I did run into problems. It is possible that also this issue (ManuelHaag/gw2-ui#5) will need to get fixed before we can proceed.

After that, we may integrate it into this project. Minimum setup: ManuelHaag/gw2-ui#5 (comment)
Integration done, see react-recode branch. Bugs remain in gw2-ui.

Set up automated tests

mostly for the calculator output values and not crashing on various combinations of inputs (0 valid results, only one affix selected, etc)

Feature: Allow forcing gear slots to a specific type

UI idea: 14 little text boxes; you can type in the 4-character codes; debounced code will highlight them green if valid affix

implementation idea: in _advanceCalculation, before recycle/clone, if forcedstats[nextSlot], gear[nextSlot] = forcedstats[nextSlot], continue;

will need to split up or rewrite duplicate skipping

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.