Hi,
in length.h findest du
PHP Code:
typedef struct SItemPos
{
BYTE window_type;
WORD cell;
SItemPos ()
{
window_type = INVENTORY;
cell = WORD_MAX;
}
SItemPos (BYTE _window_type, WORD _cell)
{
window_type = _window_type;
cell = _cell;
}
bool IsValidItemPosition() const
{
switch (window_type)
{
case RESERVED_WINDOW:
return false;
case INVENTORY:
case EQUIPMENT:
case BELT_INVENTORY:
return cell < INVENTORY_AND_EQUIP_SLOT_MAX;
case DRAGON_SOUL_INVENTORY:
return cell < (DRAGON_SOUL_INVENTORY_MAX_NUM);
// µ¿ÀûÀ¸·Î Å©±â°¡ Á¤ÇØÁö´Â window´Â valid üũ¸¦ ÇÒ ¼ö°¡ ¾ø´Ù.
case SAFEBOX:
case MALL:
return false;
default:
return false;
}
return false;
}
bool IsEquipPosition() const
{
return ((INVENTORY == window_type || EQUIPMENT == window_type) && cell >= INVENTORY_MAX_NUM && cell < INVENTORY_MAX_NUM + WEAR_MAX_NUM)
|| IsDragonSoulEquipPosition();
}
bool IsDragonSoulEquipPosition() const
{
return (DRAGON_SOUL_EQUIP_SLOT_START <= cell) && (DRAGON_SOUL_EQUIP_SLOT_END > cell);
}
bool IsBeltInventoryPosition() const
{
return (BELT_INVENTORY_SLOT_START <= cell) && (BELT_INVENTORY_SLOT_END > cell);
}
bool IsDefaultInventoryPosition() const
{
return INVENTORY == window_type && cell < INVENTORY_MAX_NUM;
}
bool operator==(const struct SItemPos& rhs) const
{
return (window_type == rhs.window_type) && (cell == rhs.cell);
}
bool operator<(const struct SItemPos& rhs) const
{
return (window_type < rhs.window_type) || ((window_type == rhs.window_type) && (cell < rhs.cell));
}
} TItemPos;