36 if (stats->
equip[2] > 0) {
37 equipped[0] = stats->
equip[2];
38 if (stats->
equip[3] > 0) {
39 equipped[1] = stats->
equip[3];
46 for (i = 0; i < 2; i++) {
48 if (info->
type < 2 || info->
type > 14) {
67 if (stats->
equip[4] > 0) {
68 equipped[0] = stats->
equip[4];
69 if (stats->
equip[5] > 0) {
70 equipped[1] = stats->
equip[5];
86 if (stats->
equip[4] > 0) {
87 equipped[0] = stats->
equip[4];
88 if (stats->
equip[5] <= 0) {
91 equipped[1] = stats->
equip[5];
125 old = *(stats->
equip + slot);
136 *(stats->
equip + slot) = 0;
142 pair = &stats->
equip[2];
143 if (stats->
equip[2] == 0) {
145 if (stats->
equip[3] != 0) {
146 pair = &stats->
equip[3];
158 for (i = 0; i < 2; i++) {
159 equip = &stats->
equip[i + 4];
178 stats->
equip[2] = id;
179 stats->
equip[3] = id;
181 *(stats->
equip + slot) =
id;
GameState GAME
The save data, the game mode and the methods.
s16 * STITSHOP_getShopItems(s32 shop)
The items a shop sells (up to 0), noting how many in STITSHOP_funcs.count; NULL for none.
void STITSHOP_equip(s32 partner, s32 slot, s32 item, s32 fromBag)
Puts an item in a partner's equipment slot like STSTATUS_equip, moving the counts between GAME....
s32 STITSHOP_canEquip(s32 partner, s32 item)
1 when a partner can equip an item: the partner's bit in its partners
s32 STITSHOP_compareEquip(s32 partner, s32 item)
Which equipment slot a bought item would go in: 2 or 3 for the weapons (the one with the weaker item ...
#define EQUIP_KIND_RIGHT_HAND
Where an equipment item goes (its record's kind), as the shop's and STSTATUS's strings name the kinds...
#define EQUIP_KIND_LEFT_HAND
#define EQUIP_KIND_GROUP_ACCESSORY
one of its group at a time
#define EQUIP_KIND_EITHER_HAND
#define EQUIP_KIND_ACCESSORY
#define EQUIP_KIND_BOTH_HANDS
takes slots 2 and 3
STITSHOP.PRO: the item shop.
ItemShopFuncs STITSHOP_funcs
The shop's helpers.
ShopList STITSHOP_shops[31]
The shops, by ItemShop.shop.
u8 kind
EQUIP_KIND_ACCESSORY or EQUIP_KIND_GROUP_ACCESSORY.
struct PartnerStats *(* getPartnerStats)(s32 partner)
s8 items[0x193]
counts, up to 99
struct ItemInfo *(* get)(s32 item)
getItem
An item (ITEMS, ITEM_FUNCS)
u8 type
2-14 weapons, 15-20 armour, 21-24 accessories
ItemRecord data
the type's record, or the usable items' effect
s32 count
the items of the shop getShopItems returned
A partner Digimon from its name on (Partner.info), as getPartnerStats gives it.
u8 partners
1 << partner for each partner who can equip it (STSTATUS_canEquip)
ItemInfo.data's record, by ItemInfo.type.