ItemStack

Defines which items can stack and their maximum stack sizes

This configuration file defines which items can be stacked in inventory and their maximum stack sizes, with optional item transformation when reaching max stack.

File Location

GameServer/Data/Item/ItemStack.xml

Dependencies

Depends On
Purpose

Item.xml

Item definitions

Depended On By
Purpose

ItemValue.xml

Uses stack count for price calculation

How It Works

  1. When items are picked up or received, server checks ItemStack

  2. If item is stackable, multiple items combine into one slot

  3. Stack count shown in inventory (up to MaxStack)

  4. Optionally, when MaxStack is reached, item transforms to another

Structure

Old Format (Backward Compatible)

Attributes

Attribute
Type
Description

Type

int

Item category (0-15) - New format only

Index

int

Item type within category, or calculated index in old format

Level

string

* for all levels, or 0-15 for specific level

MaxStack

int

Maximum stack size (1-255)

CreateType

string

* for no transform, or category of created item

CreateIndex

int

Index of created item (when MaxStack reached)

CreateLevel

string

* for same level, or specific level for created item

Name

string

Human-readable name (optional)

Index Calculation (Old Format)

Category Reference

Category
Item Type

0-5

Weapons (cannot stack)

6

Shields (cannot stack)

7-11

Armor (cannot stack)

12

Wings, Scrolls, Orbs

13

Rings, Pendants, Quest Items

14

Potions, Jewels, Consumables

15

Scrolls, Books

Examples

When CreateType="*", items simply stack without transforming.

Important Behavior

circle-info

Equipment Cannot Stack: Categories 0-11 (weapons, shields, armor) are hardcoded to never stack regardless of configuration. While Bolts (Type 4, Index 7) and Arrows (Type 4, Index 15) are defined in ItemStack.xml with MaxStack=255, they do NOT actually stack in inventory because Type 4 is in the non-stackable range. The config entries exist only for special shop price calculation logic.

circle-info

Level Matching: When Level is specified, only items of that exact level stack together. Level="*" allows all levels to stack together.

circle-info

Price Calculation: ItemValue.xml multiplies Value by stack count for stackable items.

circle-exclamation
circle-exclamation

Common Issues

circle-exclamation
circle-exclamation
triangle-exclamation

Last updated