8000 Transmute All Gems by badbrad2889 · Pull Request #736 · aeon0/botty · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Jul 1, 2022. It is now read-only.

Transmute All Gems #736

Merged
merged 10 commits into from
Jun 7, 2022
Merged

Transmute All Gems #736

merged 10 commits into from
Jun 7, 2022

Conversation

badbrad2889
Copy link
Contributor

I added the ability to transmute all gems and select which kind of gems you would like to transmute in the params.ini file

@D2RLegit
Copy link
Contributor

Can't we make it as "transmute gems" as one line instead of having them all seperate in params?

@TallenKerl
Copy link

Can't we make it as "transmute gems" as one line instead of having them all seperate in params?

That's not a good idea because some people keep specific gems for upgrading specific runes or (in my case) rerolling certain items with chips is more effective than with perfect

@badbrad2889
Copy link
Contributor Author

@D2RLegit As TallenKerl said I built it this way so the user has the choice which gems they want to keep.

@VladimirMakaev
Copy link
Collaborator

It actually quite a cool coding exercise to implement it in a way it does everything in one go. Imagine picking up a batch of gems: 6 chipped, 1 flawed, 2 standard, 2 flawless and produce 1 perfect one out of it. Not required to merge but if you're up for a challenge

@badbrad2889
Copy link
Contributor Author

it does it in order the way written already and yes I can change the "STD" to "standard" in the assets and the files if needed

@badbrad2889
Copy link
Contributor Author

@VladimirMakaev so it will already do that to make all the perfect, Thanks!

@badbrad2889
Copy link
Contributor Author

@VladimirMakaev I reread and now think I understand what you are asking. You want it to be able to pick up all the gems at the same time instead of looping through?

@VladimirMakaev
Copy link
Collaborator
VladimirMakaev commented Apr 26, 2022

The original implementation was focused on optimizing manipulations you do with your stash. E.g. you have X number of slots in your inventory and you have gems of different colors on 4 tabs of your stash. So the algorithm would be picking somewhat optimal amount of gems of different colors to fill that X number of slots to add up to Y number of perfect gems.

The problem with your implementation that you'd

  1. cycle through every tab of the inventory R number of times. (where R is different qualities you nominated)
  2. potentially underutilise space in your inventory for the transmute and picking things more often in lower quantities (extending the whole transmute session and negatively affect your loot/h stats)

So going back to my example:
6 chipped, 1 flawed, 2 standard, 2 flawless. with your algorithm you'd

  1. cycle through every tab and pick 6 chipped gems -> transmute, put back
  2. cycle through every tab and pick 3 flawed gems -> transmute, put back
  3. cycle through every tab and pick 3 standard gems -> transmute, put back
    ....

While in essense you can pick them all up in 1 go and keep transmuting until you get 1 flawless gem in the end. Which would be quite cool. But if you're not up for this challenge let me know and we can probably merge as is.

@badbrad2889
Copy link
Contributor Author

@VladimirMakaev im trying to resubmit the required changes. I completely understand what you are asking now so I will work on that for version 2. Thanks for the help and recomendations ;)

; flawed
; standard
; flawless
transmute=chipped, flawed, standard, flawless
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leave default as 'flawless' please. As it's not "free" to have a wider option

@badbrad2889
Copy link
Contributor Author

I made the requested change Thanks.

Copy link
Collaborator
@VladimirMakaev VladimirMakaev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can somebody test this before merging?

@badbrad2889
Copy link
Contributor Author

@mgleed @VladimirMakaev I made another change and optimize the gem transmute per recommendation. This is to decrease the "cost" and optimize the use of the inventory.

@badbrad2889
Copy link
Contributor Author

@mgleed Thank you for running the test again,
@VladimirMakaev who is able to merge this request?

8000
@aliig
Copy link
Collaborator
aliig commented May 6, 2022

If one of the contributors can test this I'd be willing to merge. Not able to get on d2 til sunday to test myself

@badbrad2889
Copy link
Contributor Author

@mgleed ok sounds good, I appreciate it!

aliig
aliig previously requested changes May 9, 2022
Copy link
Collaborator
@aliig aliig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nevermind

@aliig aliig dismissed their stale review June 7, 2022 03:16

i fixed

@aliig
Copy link
Collaborator
aliig commented Jun 7, 2022

I had tested this initially but realized the test case I'd contrived was wrong, leading to error. Deleted my video post from earlier. Tested this about three times with a variety of gems and it works nicely.

One way this could be improved is to include logic starting from chipped --> flawless for the number of gems to bring over to be cubed. I.e. if it knows we have 3 flawed gems and 2 normal gems, bring them all over and cube them into each other to make 1 flawless gem. But I don't think that needs to be included in this PR. Nice job @badbrad2889

@aliig aliig merged commit 9978c23 into aeon0:master Jun 7, 2022
@badbrad2889
Copy link
Contributor Author
badbrad2889 commented Jun 7, 2022 628C

@mgleed Thanks for retesting I greatly appreciate it! next implementation I will work on is going to be runes. after I will work on trying to have it grab all the gems at once if you are using that gem and the one above.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants
0