Quantcast Broker Pricing Mod - EQ2Interface
EQ2Interface.com
Search Downloads


Go Back   EQ2Interface > General Discussion > Request

Reply
Thread Tools Search this Thread Display Modes
  #1  
Unread 06-02-2015, 10:44 AM
Sigrdrifa Sigrdrifa is offline
A Rumbleroot Sapling
Interface Author - Click to view interfaces
 
Join Date: Jan 2006
Server: Crushbone
Posts: 69
Default Broker Pricing Mod

Currently, I use DarqUI's broker window because it has the very helpful popup, eq2ui_popup_setprice.xml -- this shows you what the price will look like on the broker at 10%, 20% and 40% broker tax, so so far, so good.

What I'd REALLY like is a slave to go in daily and check all my items on the broker and reprice as needed, but I'm pretty sure that falls under banned automation.

Instead, I'd like a button added to the broker pricing somewhere that just says "price 1g less", and a second that is "price 1p less", referring to the displayed price of the item targeted. The amounts for the two buttons should be configurable. (Some people apparently do 1c less, but I have no use for that).

The calculation needs to know what markup the current broker is showing, so that if you are in Tranquil Sea, for example, it's 2x, so that a 10% tax item shows up as 20%. And it needs to know what the current salescrate markup is (10%, 15%, 20%), which should all be accessible because the broker screen is displaying that info.

Using DarqUI's eq2ui_popup_setprice.xml, there's trial and error involved. I pick a guessed value in plat and manually adjust up or down with the spinner, then do the same as needed for gold:

Reply With Quote
  #2  
Unread 06-02-2015, 04:44 PM
lordebon lordebon is offline
Fetish Core author
This person is a EQ2Map developer.
Featured
 
Join Date: Jun 2005
Server: Antonia Bayle
Posts: 2,633
Default

There's a lot of "should" in there - last time I'd look at it getting the data out of the broker table is not easy (if even possible). Trying to combine multiple pieces of data (the broker markup) and everything on top... honestly if it's even possible I don't know if there's any UI authors left that could put it together.

Maybe someone will take it up as a challenge, but doing that much math and trying to pull that many pieces of data from that window is going to be ugly.
__________________
Reply With Quote
  #3  
Unread 06-06-2015, 12:19 PM
Sigrdrifa Sigrdrifa is offline
A Rumbleroot Sapling
Interface Author - Click to view interfaces
 
Join Date: Jan 2006
Server: Crushbone
Posts: 69
Default

Quote:
Originally Posted by lordebon View Post
...doing that much math and trying to pull that many pieces of data from that window is going to be ugly.
DarqUI's eq2ui_popup_setprice.xml is already doing the math of taking a number and showing it at 10%, 20% and 40%.

eq2ui_inventory_market.xml has:
<Text AbsorbsInput="false" Font="/TextStyles.Normal.NormalStyle" Location="170,26" Margin="0,0,15,0" MaxLines="1" Name="SelectedPrice" PackSize="a,f" ScrollExtent="374,20" Size="374,20" TextAlignmentVertical="Center" TextColor="#F0D080" UserMovable="true">:5f6b97aeaf09212c:[DEVL]N to seller and M to broker</Text>

<Text AbsorbsInput="false" Font="/TextStyles.Normal.NormalStyle" Location="170,43" Margin="0,0,15,0" MaxLines="1" Name="BrokerCommission" PackSize="a,f" ScrollExtent="374,20" Size="374,20" TextAlignmentVertical="Center" TextColor="#F0D080" UserMovable="true">:5f6b97ae8f12816e:[DEVL]15% to broker</Text>
I think that these are the base price and broker commission amounts being listed here. In that ":5f6b97aeaf09212c:[DEVL]N to seller and M to broker", "N" is SellerBasePrice and "M" is CommissionAmt.

The next line has ":5f6b97ae8f12816e:[DEVL]15% to broker", and that value can be harvested to give CommissionPercent. If we can't get CommissionPercent there, then:
IF (M/(N+M) <= 0.10) THEN CommissionPercent = 0.10
ELSE IF ((M/(N+M) > 0.10) AND (M/(N+M) <= 0.15)) THEN CommissionPercent = 0.15

ELSE IF ((M/(N+M) > 0.15) AND (M/(N+M) <= 0.20)) THEN CommissionPercent = 0.20

ELSE IF (M/(N+M) > 0.20) THEN CommissionPercent = 0.40
END IF
(There's probably a CEILING expression that would do this more neatly, but I am still on my first cup of coffee).

The last bit of information needed is the commission percentage of the sales crate in which the player has an item highlighted. I think I see where the window gets the info on what kind of sales container it is:
<Text AbsorbsInput="false" Font="/TextStyles.VeryLarge.VeryLargeStyle" Location="3,1" Margin="1,-1,1,1" Name="NameText" PackLocation="fixed,fixed" ScrollExtent="382,26" Size="382,26">:5f6b97aedd6c46d8:Pristine strengthened leather backpack</Text>

There are only three sales containers that discount the broker commission, so far as I am aware:
3-year veteran reward, 40-slot, commission 10%:
  • \aITEM -1057013449 1254478062:Veteran's Display Case\/a
  • \aITEM 1865448438 125174344:Veteran's Display Case\/a

9-year veteran reward, 50-slot, commission 10%:
  • \aITEM -1147436452 -800540100:Expanded Veteran's Display Case\/a
  • \aITEM 1453137537 -1753555612:Expanded Veteran's Display Case\/a

LON Loot, 30-slot, commission 15%:
  • \aITEM -1961269843 -1120555058:Legend's Display Case\/a
  • \aITEM -844465566 -201343624:Legend's Display Case\/a
Then all you'd need are these relationships:
TotalSellerPrice = SellerBasePrice + CommissionAmt

TargetSalePrice = TotalSellerPrice - ReduceByAmount

MySalePrice = TargetSalePrice - (TargetSalePrice * MyBoxCommissionAmt)

MyDisplayedPrice = MySalePrice + (MySalePrice * MyBoxCommissionAmt)
Reply With Quote
  #4  
Unread 06-06-2015, 04:58 PM
Drumstix42's Avatar
Drumstix42 Drumstix42 is offline
A Griffon
Featured
 
Join Date: Oct 2004
Server: Antonia Bayle
Posts: 3,279
Send a message via AIM to Drumstix42 Send a message via MSN to Drumstix42 Send a message via Yahoo to Drumstix42
Default

You can't do string modification at all in the UI.

You can't parse for "X", and you can't truncate things you don't want from a string.

There exists tricks for some small situations, but I haven't looked at this closely enough to give a better answer. For example, you could do "full" string comparison, and create checks for every possible combination (usually a lot of work)
__________________
"I'm afraid you're guilty of thought-crime. Don't bother getting the door, we'll let ourselves in..."
<Donate to DrumsUI> < [DrumsUI] Updater > < [DrumsUI] Full Interface> < Drumstix42 on Twitch.tv
>
Reply With Quote
  #5  
Unread 06-07-2015, 02:19 PM
Darqwood's Avatar
Darqwood Darqwood is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Aug 2005
Server: Antonia Bayle
Posts: 177
Default

Sigrdrifa, this is a good idea and a nice challenge. A few things have been done in the attached file:

1) Platinum max was increased to 9999 per your suggestion.

2) Using the spinners past 0 and 99 will roll the other denominations up or down automatically. For example if you have 1p, 0g, 0s, 0c and you spin copper down by one, you will get 0p, 99g, 99s, 99c. This should ease incremental re-pricing in a lot of cases. A not-so-obvious time saver is that once you have the text cursor in one of the denomination boxes, you can use the Tab and Shift-Tab keys to move between the text inputs without having to click the mouse.

3) Commissions are reduced by 50% in the case of the two Veteran's displays, and 25% in the case of the Legends display. Commission percentages turn green whenever there is a reduction due to one of these containers, and you also get an indicator on the window that shows the percentage. If you are in a container that doesn't have a reduction, you get the standard white 10/20/40. The three containers you listed are the only ones that will trigger the reductions. If there are other commission-reducing displays, they will have to be added to the window code manually.

This is everything but your "1p less/1g less" pricing feature, which I'm still thinking about. Please give the updated window a try and let me know if anything is wonky. It's definitely beta code until I'm sure everything is functioning 100%.
Attached Files
File Type: zip darqui_setprice_sigrdrifa.zip (10.7 KB, 126 views)

Last edited by Darqwood : 06-07-2015 at 02:24 PM.
Reply With Quote
  #6  
Unread 06-09-2015, 09:15 AM
Sigrdrifa Sigrdrifa is offline
A Rumbleroot Sapling
Interface Author - Click to view interfaces
 
Join Date: Jan 2006
Server: Crushbone
Posts: 69
Default

Quote:
Originally Posted by Darqwood View Post
Please give the updated window a try and let me know if anything is wonky. It's definitely beta code until I'm sure everything is functioning 100%.
Will do! I make my in-game living these days mostly by harvesting and then selling shinies I have collected along the way, and I reprice those suckers every day at least once It's sad but true that spiders from Stormhold have been financing my 100 conjy's master-spell purchases.
Reply With Quote
  #7  
Unread 06-09-2015, 10:51 AM
Sigrdrifa Sigrdrifa is offline
A Rumbleroot Sapling
Interface Author - Click to view interfaces
 
Join Date: Jan 2006
Server: Crushbone
Posts: 69
Default

Quote:
Originally Posted by Darqwood View Post
2) Using the spinners past 0 and 99 will roll the other denominations up or down automatically. For example if you have 1p, 0g, 0s, 0c and you spin copper down by one, you will get 0p, 99g, 99s, 99c. This should ease incremental re-pricing in a lot of cases....

3) Commissions are reduced by 50% in the case of the two Veteran's displays, and 25% in the case of the Legends display. Commission percentages turn green whenever there is a reduction due to one of these containers, and you also get an indicator on the window that shows the percentage. If you are in a container that doesn't have a reduction, you get the standard white 10/20/40. The three containers you listed are the only ones that will trigger the reductions. If there are other commission-reducing displays, they will have to be added to the window code manually.
The change to the spinners is utterly brill! That helps a lot more than you'd think. I'd been tabbing between the boxes. The special sales displays are showing pricing exactly as you described, so this looks good to me so far!
Reply With Quote
  #8  
Unread 06-10-2015, 07:11 PM
Darqwood's Avatar
Darqwood Darqwood is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Aug 2005
Server: Antonia Bayle
Posts: 177
Default

Here are some more changes to the commission calculator attached below:

1) A new button next to the coin area gives you an optional keypad to enter prices.

2) After entering a price, you can click the green gem next to a commission amount to convert the displayed price based upon the commission percentage. For example, if you want the final price of an item in a 20% container to display as 12p 60g, enter 12p 60g as normal and then click the gem next to the 20% commission line. The price will convert down to 10p 50g to accommodate the container markup. Press the Set Price button and then OK, and your item will be priced correctly for the container.

Note that because of the way the game rounds numbers, many converted values will need to be tweaked up or down a bit with the spinners to make the price more accurate before applying. For example, enter 10p and then press the 40% markup gem. The conversion results in 10p 4c. In this case, use the copper spinner to manually remove 4c from the result before applying. There is nothing I can do to avoid rounding oddities like this. Also remember that some values will never round out properly -- for example you can never get a 40% container to display 1p. It will either be 1p 1c or 99g 99s 99c.


Attached Files
File Type: zip darqui_setprice_sigrdrifa2.zip (13.3 KB, 106 views)
Reply With Quote
  #9  
Unread 06-11-2015, 11:38 AM
Sigrdrifa Sigrdrifa is offline
A Rumbleroot Sapling
Interface Author - Click to view interfaces
 
Join Date: Jan 2006
Server: Crushbone
Posts: 69
Default

Quote:
Originally Posted by Darqwood View Post
Here are some more changes to the commission calculator attached below
Downloading it now. Since the numeric keypad on the keyboard will already work, I doubt I'll need a keypad in the UI, but we'll see. I'll report back!

EDIT: I really like it. The only thing more I could suggest is a "clear all" button on the popup so that if I have odd amounts in all the currency spinner windows I can zero everything and start again without having to tab over, select the numeric text, then type 0.

EDIT 2: This is exactly what I needed. I can easily control what the price looks like when viewed on the broker. This is easy to use and I'm doing a lot less guessing now. You are today's superhero for me!

EDIT 3: Another suggestion: mouse focus should be inside the plat spinner box when the popup opens.

Last edited by Sigrdrifa : 06-11-2015 at 01:51 PM.
Reply With Quote
  #10  
Unread 06-11-2015, 02:12 PM
Sigrdrifa Sigrdrifa is offline
A Rumbleroot Sapling
Interface Author - Click to view interfaces
 
Join Date: Jan 2006
Server: Crushbone
Posts: 69
Default

Oops, bug! I entered 371p in the spinners, then clicked the button next to 10%, and adjusted the spinners to get 337p 27g 27s 27c, then hit "Set Price".

On the way back to the initial price popup, the plat part got lost. I was only able to get it in there by typing 337 and clicking the plat button.

Same problem when I entered 258p in the spinners, then clicked the button next to 10%, and adjusted the spinners to get 234p 54g 54s 54c, then hit "Set Price". Again, the plat part was lost and had to be manually entered.

I'm going to guess that the math doesn't play nicely with >99p.
Attached Thumbnails
Click image for larger version

Name:	bug01.jpg
Views:	172
Size:	33.8 KB
ID:	8249  
Reply With Quote
  #11  
Unread 06-11-2015, 03:55 PM
Darqwood's Avatar
Darqwood Darqwood is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Aug 2005
Server: Antonia Bayle
Posts: 177
Default

Quote:
Originally Posted by Sigrdrifa View Post
Oops, bug! I entered 371p in the spinners, then clicked the button next to 10%, and adjusted the spinners to get 337p 27g 27s 27c, then hit "Set Price".

On the way back to the initial price popup, the plat part got lost. I was only able to get it in there by typing 337 and clicking the plat button.

Same problem when I entered 258p in the spinners, then clicked the button next to 10%, and adjusted the spinners to get 234p 54g 54s 54c, then hit "Set Price". Again, the plat part was lost and had to be manually entered.

I'm going to guess that the math doesn't play nicely with >99p.


Yep good catch on that, thank you. The routine that transfers coin values to the default pricing window still maxes at 99. In the meantime the Clear All button and plat textbox focus mods are below.


Also, one quick question: On your top image, choosing the 10% commission should light up the green gem next to 10%, but it looks like the red gem is still selected -- see my image. Are your gems messing up?


Attached Files
File Type: zip darqui_setprice_sigrdrifa3.zip (13.5 KB, 112 views)

Last edited by Darqwood : 06-11-2015 at 04:04 PM.
Reply With Quote
  #12  
Unread 06-11-2015, 04:56 PM
Sigrdrifa Sigrdrifa is offline
A Rumbleroot Sapling
Interface Author - Click to view interfaces
 
Join Date: Jan 2006
Server: Crushbone
Posts: 69
Default

I've downloaded and will play with it later tonight when I get back from adventuring. The green gem is fine, I was moving back and forth between screens to get screens shots and reproduce the effect, which I suspect resulted in the whacky gem lighting.
Reply With Quote
  #13  
Unread 06-11-2015, 05:34 PM
Darqwood's Avatar
Darqwood Darqwood is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Aug 2005
Server: Antonia Bayle
Posts: 177
Default

Never mind about the gems, I found what you had done and corrected it. Also the calculator will now insert plat values above 99. Thanks for the suggestions and the help with testing, the setprice mod is 14x better now. (10x better with a 40% markup.)
Attached Files
File Type: zip darqui_setprice_sigrdrifa4.zip (13.8 KB, 116 views)
Reply With Quote
  #14  
Unread 06-11-2015, 11:26 PM
Sigrdrifa Sigrdrifa is offline
A Rumbleroot Sapling
Interface Author - Click to view interfaces
 
Join Date: Jan 2006
Server: Crushbone
Posts: 69
Default

Thank you so much! It works very well, and people like nice round numbers at the broker. My sales tonight were staggeringly good. Yay!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 03:22 PM.


Our Network
EQInterface | EQ2Interface | War.MMOUI | WoWInterface | VGInterface | LoTROInterface | MMOInterface