Skip to content

Item Medal Exchange

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.

VersionStatus
v92Full
v90-
v86-

Entity: exchanges Operations: create, update, delete, upsert


spec:
version: "1.0"
exchanges:
create:
- itemId: 11001
medalItemId: 90001
buyPriceMedal: 100

Creates 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: 500

Creates multiple exchange entries. Item 11001 can be purchased with two different medal currencies (90001 and 90002), each at a different price.

spec:
version: "1.0"
exchanges:
update:
- itemId: 11001
medalItemId: 90001
changes:
buyPriceMedal: 150

Updates the medal price for the exchange entry identified by the composite key (itemId=11001, medalItemId=90001).

spec:
version: "1.0"
exchanges:
delete:
- itemId: 11001
medalItemId: 90001
- itemId: 11002
medalItemId: 90001

Removes exchange entries by their composite key (itemId + medalItemId).

spec:
version: "1.0"
exchanges:
upsert:
- itemId: 11004
medalItemId: 90001
buyPriceMedal: 300

Creates the exchange entry if the composite key (itemId=11004, medalItemId=90001) doesn’t exist in the exchange list, or updates it if it does.


PropertyTypeSinceRequiredDescription
itemIdintv92YesItem template ID of the item being sold (composite key part 1)
medalItemIdintv92YesItem template ID of the medal currency used for this exchange (composite key part 2)
buyPriceMedalintv92YesNumber of medals required to purchase this item

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>

  • Composite Key: Each exchange entry is uniquely identified by the pair (itemId, medalItemId). The same itemId can appear multiple times with different medalItemId values, representing the same item purchasable with different medal currencies.

  • Medal Item ID Reference: The medalItemId must reference a valid item in ItemTemplate.xml that 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 buyPriceMedal and medalItemId must 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.