Item Medal Exchange
Overview
Section titled “Overview”ItemMedalExchange.xml defines medal exchange entries: item purchases using medals as currency, specifying the item being sold, the medal cost, and the medal currency type.
Version Support
Section titled “Version Support”| Version | Status |
|---|---|
| v92 | Full |
| v90 | - |
| v86 | - |
DSL Support
Section titled “DSL Support”Entity: exchanges
Operations: create, update, delete, upsert
Quick Recipes
Section titled “Quick Recipes”Create
Section titled “Create”spec: version: "1.0"
exchanges: create: - itemId: 11001 medalItemId: 90001 buyPriceMedal: 100Creates a new exchange entry where item 11001 can be purchased for 100 medals of type 90001.
Create Multiple Entries (Same Item, Different Medals)
Section titled “Create Multiple Entries (Same Item, Different Medals)”spec: version: "1.0"
exchanges: create: - itemId: 11001 medalItemId: 90001 buyPriceMedal: 100 - itemId: 11001 medalItemId: 90002 buyPriceMedal: 250 - itemId: 11002 medalItemId: 90001 buyPriceMedal: 500Creates multiple exchange entries. Item 11001 can be purchased with two different medal currencies (90001 and 90002), each at a different price.
Update
Section titled “Update”spec: version: "1.0"
exchanges: update: - itemId: 11001 medalItemId: 90001 changes: buyPriceMedal: 150Updates the medal price for the exchange entry identified by the composite key (itemId=11001, medalItemId=90001).
Delete
Section titled “Delete”spec: version: "1.0"
exchanges: delete: - itemId: 11001 medalItemId: 90001 - itemId: 11002 medalItemId: 90001Removes exchange entries by their composite key (itemId + medalItemId).
Upsert
Section titled “Upsert”spec: version: "1.0"
exchanges: upsert: - itemId: 11004 medalItemId: 90001 buyPriceMedal: 300Creates the exchange entry if the composite key (itemId=11004, medalItemId=90001) doesn’t exist in the exchange list, or updates it if it does.
Properties Reference
Section titled “Properties Reference”Exchange
Section titled “Exchange”| Property | Type | Since | Required | Description |
|---|---|---|---|---|
itemId | int | v92 | Yes | Item template ID of the item being sold (composite key part 1) |
medalItemId | int | v92 | Yes | Item template ID of the medal currency used for this exchange (composite key part 2) |
buyPriceMedal | int | v92 | Yes | Number of medals required to purchase this item |
XML Structure
Section titled “XML Structure”ItemMedalExchange uses 2-level nesting:
ItemMedalExchange└── ExchangeList └── Exchange (itemId, medalItemId, buyPriceMedal) [max unbounded]Example XML:
<ItemMedalExchange> <ExchangeList> <Exchange itemId="11001" buyPriceMedal="100" medalItemId="90001" /> <Exchange itemId="11001" buyPriceMedal="250" medalItemId="90002" /> <Exchange itemId="11002" buyPriceMedal="500" medalItemId="90001" /> </ExchangeList></ItemMedalExchange>Common Pitfalls
Section titled “Common Pitfalls”-
Composite Key: Each exchange entry is uniquely identified by the pair
(itemId, medalItemId). The sameitemIdcan appear multiple times with differentmedalItemIdvalues, representing the same item purchasable with different medal currencies. -
Medal Item ID Reference: The
medalItemIdmust reference a valid item inItemTemplate.xmlthat serves as the medal currency. Using an invalid ID will cause the exchange to fail at runtime. -
All Fields Required: All three fields (
itemId,buyPriceMedal,medalItemId) are required for every exchange entry. Omitting any field will cause validation errors. -
Regional Variants: ItemMedalExchange supports regional file variants (
_JP,_KR,_NAEU, etc.). Ensure you’re modifying the correct regional file for your target deployment. -
Positive Values Only: Both
buyPriceMedalandmedalItemIdmust be positive integers. Zero or negative values will cause validation failures. -
No Client Sync: This entity does not have a client-side DataCenter equivalent. Changes to ItemMedalExchange only affect server-side data.