-
-
Notifications
You must be signed in to change notification settings - Fork 182
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
Items stack listing #233
Items stack listing #233
Conversation
I would also like to add that this feature has been working for me for months without any issues! |
@Nuklon, could you please review this PR if you have time? |
code.user.js
Outdated
@@ -1313,11 +1321,11 @@ | |||
const callback = () => setTimeout(() => next(), getRandomInt(1000, 1500)); | |||
|
|||
if (success) { | |||
logDOM(`${padLeft} - ${itemName} listed for ${formatPrice(market.getPriceIncludingFees(task.sellPrice))}, you will receive ${formatPrice(task.sellPrice)}.`); | |||
logDOM(`${padLeft} - ${itemName}${getAmountString(task.item.amount)} listed for ${formatPrice(market.getPriceIncludingFees(task.sellPrice) * task.item.amount)}, you will receive ${formatPrice(task.sellPrice * task.item.amount)}.`); |
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 this would be better to have in front. In your example: 34x Hexagonana
We can probably also avoid the function, it's pretty much a one-liner, e.g. const amount = task.item.amount == 1 ? '' : task.item.amount + 'x ';
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.
Capability to list stacked items and math formulas to correctly display the price for such items.
"My Market Count" example
"Sell All" example
Unfortunately, I couldn't find a good solution to fix the ugliest line to find the amount of items.
If we take a pure HTML string, it will cause problems with items that have a number at the beginning of the name.