Page 1 of 1

[PATCH] Show Level in Broker Window

Posted: Sun May 30, 2010 12:44 am
by Rhas
This patch displays the item adventure_default_level in the broker window. In revision 437, no level is displayed. It appears that "unknown8" in the WS_BrokerItems struct is what the client uses for the level column in the broker window. I did not rename the field in WorldStructs.xml. I'll leave that up to you if you decide to commit this change.

I believe on Live it displays the required level and not recommended level. If some logic needs to be added to show the tradeskill_default_level for tradeskill items, I can change that.

Tested on my server using client 6118L.

Code: Select all

--- client.cpp (revision 437)
+++ client.cpp	(working copy)
@@ -4705,6 +4705,8 @@
 						packet->setArrayDataByName("quantity", item->stack_count, i);
 					packet->setArrayDataByName("stack_size", item->stack_count, i);
 					packet->setArrayDataByName("item_name", item->name.c_str(), i);
+					packet->setArrayDataByName("unknown8", item->generic_info.adventure_default_level, i);
+					
 					//QueuePacket(item->serialize(GetVersion(), false, GetPlayer()));
 				}
 			}
Before and after screenshots:
broker_level_before.jpg
broker_level_after.jpg

Re: [PATCH] Show Level in Broker Window

Posted: Sun May 30, 2010 8:24 am
by Scatman
Cool. :) Again, later on today I'll give this a whirl. Being dragged to the beach soon :evil:

Re: [PATCH] Show Level in Broker Window

Posted: Sun May 30, 2010 9:48 am
by Zcoretri
Scatman wrote:Cool. :) Again, later on today I'll give this a whirl. Being dragged to the beach soon :evil:
They have beaches on the right coast? :mrgreen:

Re: [PATCH] Show Level in Broker Window

Posted: Sun May 30, 2010 1:14 pm
by Scatman
Yeah unfortunately I live right next to Atlantic City so it's becoming tourist season :(