25#define ITEM_FLAG_ACTIVE 0x1000
26#define ITEM_FLAG_CRAFTABLE 0x2000
35#define ITEM_FLAG_NOT_LAST 0x4000
41#define ITEM_TYPE_MASK 0x0f00
47#define ITEM_COUNT_MASK 0x00ff
56#define item_get_type_flag( e ) (((e)->flags & ITEM_TYPE_MASK) >> 8)
62#define item_set_type_flag( e, v ) (e)->flags = (((e)->flags & ~ITEM_TYPE_MASK) | (((v) << 8) & ITEM_TYPE_MASK))
68#define item_get_count_flag( e ) ((e)->flags & ITEM_COUNT_MASK)
74#define item_incr_count( e, v ) (e)->flags = (((e)->flags & ~ITEM_COUNT_MASK) | ((item_get_count_flag( e ) + (((v) & ITEM_COUNT_MASK))) & ITEM_COUNT_MASK))
92 RESOURCE_NAME sprite_name;
uint16_t TILEMAP_GID
Globally unique identifier for TILEMAP objects.
Definition: gid.h:26
#define ITEM_NAME_SZ
The maximum characters in an ITEM::name.
Definition: itstruct.h:80
An instance of an item in the world.
Definition: itstruct.h:91
int16_t gid
Arbitrary portion of the GID of the item.
Definition: itstruct.h:107
int16_t sprite_cache_id
Index of the item's sprite loaded in the Unilayer Graphics Cache.
Definition: itstruct.h:97
char name[ITEM_NAME_SZ+1]
Meaningful name of this item displayed in menus, etc.
Definition: itstruct.h:99
uint8_t y
If ITEM::owner is ::ITEM_OWNER_NONE, the Y coord (in tiles) of this item on the TILEMAP referred to b...
Definition: itstruct.h:129
uint8_t data
Qualitative value specific to each ITEM_TYPE_MASK.
Definition: itstruct.h:117
uint16_t flags
Item Flags pertaining to this item.
Definition: itstruct.h:119
int16_t owner
dsekai_items_owners for this particular item.
Definition: itstruct.h:103
TILEMAP_GID map_gid
TILEMAP::gid of the tilemap on which this item is sitting. Only has meaning when ITEM::owner is set t...
Definition: itstruct.h:134
uint8_t x
If ITEM::owner is ::ITEM_OWNER_NONE, the X coord (in tiles) of this item on the TILEMAP referred to b...
Definition: itstruct.h:124