LockboxKey
Overview
Section titled “Overview”Gacha.xml defines lockbox key entries: mappings between key items and the gacha lockbox items they can open, with a configurable open multiplier.
Version Support
Section titled “Version Support”| Version | Status |
|---|---|
| v92 | Full |
| v90 | - |
| v86 | - |
DSL Support
Section titled “DSL Support”Entity: lockboxKeys
Operations: create, update, delete, upsert
File Organization: Regional variants (Gacha_JP.xml, Gacha_KR.xml, Gacha_NAEU.xml, etc.)
Quick Recipes
Section titled “Quick Recipes”Create
Section titled “Create”spec: version: "1.0"
lockboxKeys: create: - itemTemplateId: 300001 lockboxTemplateId: "200001"Creates a lockbox key that opens gacha item 200001. The multiple attribute defaults to 1.
Create with Custom Multiplier
Section titled “Create with Custom Multiplier”spec: version: "1.0"
lockboxKeys: create: - itemTemplateId: 300002 lockboxTemplateId: "200001" multiple: 10Creates a lockbox key that opens gacha item 200001 ten times per use.
Update
Section titled “Update”spec: version: "1.0"
lockboxKeys: update: - itemTemplateId: 300001 changes: lockboxTemplateId: "200002"Changes which gacha item this key opens.
Update Multiplier
Section titled “Update Multiplier”spec: version: "1.0"
lockboxKeys: update: - itemTemplateId: 300001 changes: multiple: 5Changes the open multiplier for an existing key.
Delete
Section titled “Delete”spec: version: "1.0"
lockboxKeys: delete: - 300001 - 300002Removes lockbox key entries by their itemTemplateId.
Upsert
Section titled “Upsert”spec: version: "1.0"
lockboxKeys: upsert: - itemTemplateId: 300003 lockboxTemplateId: "200001" multiple: 1Creates the lockbox key if itemTemplateId 300003 doesn’t exist, or leaves the existing entry unchanged if it does.
Properties Reference
Section titled “Properties Reference”LockboxKey
Section titled “LockboxKey”| Property | Type | Since | Required | Description |
|---|---|---|---|---|
itemTemplateId | int | v92 | Yes | Key item template ID (primary key) |
lockboxTemplateId | string | v92 | Yes | Item template ID of the gacha lockbox this key opens |
multiple | int | v92 | No | Number of times the lockbox is opened per key use. Defaults to 1 |
XML Structure
Section titled “XML Structure”LockboxKey uses flat nesting within the shared Gacha root:
Gacha└── LockboxKey (itemTemplateId, lockboxTemplateId, multiple)Example XML:
<Gacha> <LockboxKey itemTemplateId="300001" lockboxTemplateId="200001" multiple="1" /> <LockboxKey itemTemplateId="300002" lockboxTemplateId="200001" multiple="10" /></Gacha>Common Pitfalls
Section titled “Common Pitfalls”-
Shared XML File: LockboxKey and GachaItem share the same
Gacha.xmlfile. Both entity types coexist as sibling elements under the<Gacha>root. -
Regional Variants: Gacha uses regional file variants (
Gacha_JP.xml,Gacha_KR.xml,Gacha_NAEU.xml, etc.). Ensure you’re modifying the correct regional file for your target deployment. -
lockboxTemplateIdIs a String: Unlike most ID fields,lockboxTemplateIdis astringtype in the XML schema. Always quote the value in YAML. -
Default Multiple: The
multipleattribute defaults to1on create. This means one key opens the lockbox once. Only specifymultiplewhen a different value is needed. -
Cross-Reference to GachaItem: The
lockboxTemplateIdshould reference a valid GachaItem’sitemTemplateIdthat hasisLockbox: true. The DSL does not validate this cross-reference at compile time.