CashShop.xml

Defines every item, package, and banner shown in the in-game cash shop. Covers three currencies (WCoin C, WCoin P, Goblin Points), category hierarchy, per-product options, and time-boxed banners.

File Location#

Data/CashShop/CashShop.xml

Loaded at GameServer startup. /reload cashshop (or reload.cashshop in the Server Manager) reloads it, together with the cash shop settings in GameServerInfo - Common.dat, without a restart.

Structure#

<CashShop>
    <Categories>
        <Category .../>
    </Categories>
    <Packages>
        <Package ...>
            <Products>
                <Ref Base="..." Main="..."/>
            </Products>
        </Package>
    </Packages>
    <Products>
        <Product .../>
    </Products>
    <Banners>
        <Banner .../>
    </Banners>
</CashShop>

Four top-level blocks. Each <Category> is a tab or sub-tab. Each <Package> is a grouped purchase that contains references to individual <Product> entries. Standalone <Product> entries are single-item purchases. <Banner> entries are promotional tiles.

Currencies and Flag Enums#

Coin indices (CoinIndex on packages)#

ValueCurrency
508WCoin (C)
509WCoin (P)
0Goblin Points

CoinIndex lives on <Package> only. Standalone <Product> entries do not carry a CoinIndex attribute - the package that references them dictates the currency.

Common flag values#

FlagValues
SalesFlag182 = Purchasable, 183 = Not Purchasable
GiftFlag184 = Giftable, 185 = Not Giftable
EventFlag199 = Event, 200 = Normal
OpenFlag201 = Open (default), other values close the category
CapsuleFlag176 = Capsule, 177 = Normal
DeleteFlag180 = Deleted, 181 = Active

Product types#

ProductType is stored and relayed to the client; it classifies how the client renders and categorises the entry. Default is 170 for <Package>, 140 for <Product>.

ValueMeaning
135Fixed amount. TODO: verify
136Fixed quantity. TODO: verify
137Premium. TODO: verify
138Consumption. TODO: verify
139Eternity (permanent)
140Period (time-limited, pairs with Duration)
170Package container (used on <Package>, not standalone products)
406Premium item. TODO: verify
515Goblin point pack. TODO: verify

Category Attributes#

AttributeTypeDefaultEffect
Seqint(required)Unique category ID. Packages and products reference this
Namestring(required)Display name on the tab
Parentint0Parent category's Seq. 0 = root tab
Orderint0Sort order within its parent. Lower shows first
Root0 or 111 = top-level tab, 0 = sub-category
EventFlagenum200199 marks category as event-only
OpenFlagenum201201 = open, any other value hides the category

Package Attributes#

Packages group multiple products behind one purchase. Each <Package> holds a <Products> block with <Ref> entries pointing at the actual items.

AttributeTypeDefaultEffect
Categoryint(required)Seq of the owning category
BaseIndexint(required)Package identifier, part 1. Unique per shop
MainIndexint(required)Package identifier, part 2
Namestring(required)Display name
Descriptionstring(empty)Tooltip text
ItemIndexint(required)Primary item index shown as the package icon
CoinIndex508/509/00Currency used. Must match the client's coin-type field in the purchase packet or the buy is rejected
CoinValueint0Price in that currency
BonusGPint0Extra Goblin Points credited on purchase
ProductTypeenum170Usually 170 for packages
SalesFlagenum182182 = purchasable
GiftFlagenum184184 = giftable
CapsuleFlagenum177176 marks as a random-contents capsule
EventFlagenum200199 = event-only
DeleteFlagenum181181 = active, 180 = soft-deleted
CashTypeint0Internal cash type classification
CashTypeFlagint668Internal cash type flag

<Ref> children#

Inside <Products>, each <Ref Base="..." Main="..."/> points at a <Product> entry by its BaseIndex + MainIndex. The loader caps the number of refs per package; extras beyond the cap are silently dropped.

AttributeTypeEffect
BaseintTarget product's BaseIndex
MainintTarget product's MainIndex

Product Attributes#

Individual items. Either standalone purchases (appear in the shop directly) or referenced by packages via <Ref>.

AttributeTypeDefaultEffect
BaseIndexint(required)Product identifier part 1
MainIndexint(required)Product identifier part 2
Namestring(required)Display name
ItemIndexint(required)Item index from Item.xml
ItemLevelint0Item +level at grant
CoinValueint0Price. Only charged when the product is purchased standalone; package-referenced products apply this as the per-product cost inside the package flow and must be balanced against the <Package> CoinValue
ProductTypeenum140See Product types
PropertyTypeint142Internal property flag
StorageGroupint0Inventory storage bucket
Opt1 / Opt2 / Opt3int0Item options 1-3
NewOptint0Modern item option
SetOptint0Set option
HarmonyOptint0Jewel of Harmony option
OptExint0Excellent option bitmask
Sock1 ... Sock5int255Socket options (255 = empty socket slot)
Quantityint0Quantity granted per purchase
Durationint0Duration in seconds for time-limited items (pairs with ProductType="140"). 0 = permanent

Promotional tiles shown at the top of the shop.

AttributeTypeEffect
SeqintUnique banner ID
NamestringInternal name
ImageFilestringClient-side image filename
LinkURLstringClick destination URL
OrderintSort order
DirectionintRotation direction for animated banners
StartDatestringYYYY-MM-DD start date. Banner hidden before this
EndDatestringYYYY-MM-DD end date. Banner hidden after this

Examples#

CashShop.xml fragment
<Products>
    <Product BaseIndex="281" MainIndex="349"
             Name="Magic Backpack (Permanent)"
             ItemIndex="7330" ItemLevel="0"
             CoinValue="690" ProductType="139"
             PropertyType="142" Quantity="1" Duration="0"/>
</Products>

Standalone +0 Magic Backpack for 690 WCoin(C). ProductType 139 = Eternity (permanent).

Cross-File Dependencies#

AttributeRelated in
ItemIndexMust exist in Item.xml
Opt* / NewOpt / SetOpt / HarmonyOptEffects defined in ItemOption.xml, SetItemOption.xml, JewelOfHarmonyOption.xml
Sock1-5Socket option indices from SocketItemOption.xml
CoinIndex / CoinValueWCoin (C), WCoin (P), Goblin Point balances maintained by DataServer. Master toggle: Common.dat CashShopSwitch
BonusGPRelated to Common.dat CashShopGoblinPointValue_AL0-3 (per-tier GP tick reward). TODO: verify whether BonusGP is capped by those values or applied independently
Gift flagGift purchases are audit-logged; controlled by Common.dat WriteCashShopLog
Wallet top-up by GMsCommand.xml /setcoin (dispatched to the CommandSetCoin handler). GM authority comes from GameMaster.xml

Common Issues#

  • Product shows in shop but cannot be purchased - SalesFlag="183" (not purchasable) on the package, or DeleteFlag="180" (soft-deleted)
  • Package contains broken items - one of the <Ref Base Main> pairs does not match any <Product> entry. Extras beyond the per-package ref cap are dropped silently at load
  • Gift button greyed out - GiftFlag="185" (not giftable) on the package
  • Category empty in-game - no packages or products reference that Seq, or OpenFlag is not 201
  • Event category always visible - EventFlag on category should be 199 for event-only visibility; setting 199 alone does not schedule show/hide
  • Banner never appears - current date is outside StartDate..EndDate range, or the ImageFile is missing from the client
  • "Loaded 0 categories" - XML syntax error, or root node is not <CashShop>. The loader logs category / package / product / banner counts at startup
  • Wrong currency charged - the client sends a CoinIndex with the purchase; the server rejects the buy if it does not match the package's CoinIndex

Last updated October 1, 2026