|
Digimon World 3 decomp
The European version, SLES_039.36
|
STITSHOP.PRO: the item shop. More...
#include "engine/game.h"Go to the source code of this file.
Data Structures | |
| struct | ItemShop |
| The main task of the shop (STITSHOP_createShop) More... | |
| struct | ItemShopWindows |
| The children of the shop. More... | |
| struct | ShopPartnerInfo |
| What the details panel shows of a partner. More... | |
| struct | ShopStatRow |
| A row of the details panel's stats. More... | |
| struct | ShopInfo |
| The panel with the selected item's details (STITSHOP_createInfo) More... | |
| struct | ShopInfoPartner |
| A partner's rows of the details panel's second page. More... | |
| struct | ShopInfoWindows |
| struct | ShopDialog |
| What ShopBuy and ShopSell start with, and are passed to the item list as: the list shows its selection in it. More... | |
| struct | ShopItemList |
| The list of the items to buy or sell (STITSHOP_createItemList) More... | |
| struct | ShopItemListWindows |
| struct | ShopBuy |
| The dialog to buy an item (STITSHOP_createBuy) More... | |
| struct | ShopBuyWindows |
| struct | ShopSell |
| The dialog to sell an item (STITSHOP_createSell) More... | |
| struct | ShopSellWindows |
| struct | ShopList |
| A shop: the items it sells. More... | |
| struct | ItemShopFuncs |
| The shop's helpers (STITSHOP_funcs) More... | |
Macros | |
| #define | OVL_NAME(name) STITSHOP_##name |
| The name of this overlay's copy of a function of src/shared/. | |
| #define | FILE_SHOP_SPRITES 0x402 |
| The shop's sprite sheet; the next file is its texture archive. | |
Functions | |
| void | STITSHOP_updateScene (Task *task, ItemShop **child) |
| scene.c | |
| void | STITSHOP_startFader (ScreenFade *task, s32 fadeIn, s32 duration) |
| void | STITSHOP_drawFader (ScreenFade *task) |
| void | STITSHOP_updateFader (ScreenFade *task) |
| ScreenFade * | STITSHOP_createFader (void) |
| void | STITSHOP_createBuyWindows (ShopBuy *buy, ShopBuyWindows *win) |
| trade.c | |
| void | STITSHOP_showQuantity (ShopBuy *buy, ShopBuyWindows *win, s32 show) |
| Shows the quantity to buy; or hides it. | |
| void | STITSHOP_showBuyTotal (ShopBuy *buy, ShopBuyWindows *win, s32 show) |
| Shows the total price with yes and no to confirm the purchase; or hides them. | |
| void | STITSHOP_drawBuy (ShopBuy *buy, ShopBuyWindows *win) |
| Draws the buying screen's frames, the quantity's blinking arrows and the marker over a partner. | |
| void | STITSHOP_runBuy (ShopBuy *buy, ShopBuyWindows *win) |
| The buying dialog: pick the item in the list, how many, confirm, then (equipment) whether to equip it and on which partner. | |
| void | STITSHOP_updateBuy (ShopBuy *buy, ShopBuyWindows *win) |
| The buying dialog's task: creates its windows, starting at a quantity of 1, then runs and draws it. | |
| void | STITSHOP_showBuyItem (ShopBuy *buy, s32 item, s32 quantity) |
| Shows the item selected in the list, and the quantity, in the details panel (buy->showItem) | |
| ShopBuy * | STITSHOP_createBuy (ItemShop *shop) |
| Creates the buying dialog (task), when buy is chosen in the shop. | |
| void | STITSHOP_createSellWindows (ShopSell *sell, ShopSellWindows *win) |
| Creates the selling dialog's windows: the cursor, the four kinds of sale, the quantity, the total with its yes and no, and the message. | |
| void | STITSHOP_drawSell (ShopSell *sell, ShopSellWindows *win) |
| Draws the selling screen's frames, and the quantity's blinking arrows. | |
| void | STITSHOP_runSell (ShopSell *sell, ShopSellWindows *win) |
| The selling dialog: pick the kind of item, then the item in the list, how many, and confirm. | |
| void | STITSHOP_updateSell (ShopSell *sell, ShopSellWindows *win) |
| The selling dialog's task: creates its windows, starting at a quantity of 1, then runs and draws it. | |
| void | STITSHOP_showSellItem (ShopSell *sell, s32 item, s32 quantity) |
| Shows the item selected in the list, and the quantity, in the details panel (sell->showItem) | |
| ShopSell * | STITSHOP_createSell (ItemShop *shop) |
| Creates the selling dialog (task), when sell is chosen in the shop. | |
| void | STITSHOP_createItemListWindows (ShopItemList *list, ShopItemListWindows *win) |
| item_list.c | |
| void | STITSHOP_showItemPage (ShopItemList *list, ShopItemListWindows *win, s32 show) |
| Shows the page of items, the page number and the arrows' labels; or hides them. | |
| void | STITSHOP_drawItemList (ShopItemList *list) |
| Draws the list's frame, the items' icons and the blinking page arrows. | |
| void | STITSHOP_runItemList (ShopItemList *list, ShopItemListWindows *win) |
| The list's states: lists the shop's items or the bag's, fades in, then fades out when closed. | |
| void | STITSHOP_updateItemList (ShopItemList *list, ShopItemListWindows *win) |
| The item list: L1 and R1 turn its pages, the d-pad moves in the page, and the dialog shows the selected item. | |
| void | STITSHOP_freezeListCursor (ShopItemList *list, s32 frozen) |
| Freezes the list's cursor (still, in palette 7) and its input, or lets them go again (list->freezeCursor): while the details panel turns its page. | |
| void | STITSHOP_showListCursor (ShopItemList *list, s32 visible) |
| Shows the list's cursor at the selection and takes the d-pad, or hides it and stops (list->showCursor) | |
| void | STITSHOP_startItemList (ShopItemList *list) |
| Runs the list's states again (list->start), to reopen it after the quantity and the yes/no. | |
| void | STITSHOP_closeItemList (ShopItemList *list) |
| Closes the list (list->close): hides the cursor and fades it out. | |
| s32 | STITSHOP_getSelectedItem (ShopItemList *list) |
| The item at the list's selection, of the shop's or of the bag's sellable ones (list->getSelected) | |
| void | STITSHOP_refreshItemList (ShopItemList *list) |
| Lists the sellable items again, shows the page and the selection in the dialog (list->refresh) | |
| void | STITSHOP_listSellable (ShopItemList *list) |
| Lists the bag's items of the list's type that can be sold, those with a sell price (list->listBag, again after a sale) | |
| ShopItemList * | STITSHOP_createItemList (ShopDialog *dialog, s32 type, s32 selling) |
| Creates the item list (task) of a dialog: the items of the shop type when buying, the bag's of the item type when selling. | |
| void | STITSHOP_computeStats (s32 partner, StatBlock *out) |
| info.c | |
| void | STITSHOP_addStat (s16 *p, s32 stat, s32 delta) |
| Adds an item's bonus to a stat, up to 999: 1 to 6 one of the six battle stats, 7 all of them, 8 to 14 a resistance. | |
| void | STITSHOP_showStat (ShopInfo *info, TextWindow *win, ShopStatRow *row) |
| Shows a row's stat of a partner in the details panel: as it is, or with the item equipped when the row compares. | |
| void | STITSHOP_colorStat (ShopInfo *info, TextWindow *win, ShopStatRow *row) |
| Colors a row's stat: palette 1 when the item would raise it, 5 when it would lower it, else 6 when a penalty lowers it (STAT_STRENGTH, STAT_DEFENSE and STAT_SPEED), 0 otherwise. | |
| void | STITSHOP_showOtherChanges (ShopInfo *info, TextWindow **win, ShopStatRow *row) |
| Shows the new values of the other stats the item would change (palette 1 up, 5 down), noting them in the partner's rows; hides the windows left over. | |
| void | STITSHOP_fillPartnerRows (ShopInfo *info, ShopInfoWindows *win, s32 member) |
| Fills a partner's rows of the details panel's second page: the stats of the slot the item goes in, then the others it would change. | |
| void | STITSHOP_createInfoWindows (ShopInfo *info, ShopInfoWindows *win) |
| Creates the details panel's windows: the item's rows, then, when buying, each partner's name, stats and stat changes. | |
| void | STITSHOP_showItemRows (ShopInfo *info, ShopInfoWindows *win, s32 show) |
| Shows the item's name, how many are equipped and in the bag, and its price; or hides them. | |
| void | STITSHOP_showItemDesc (ShopInfo *info, ShopInfoWindows *win, s32 show) |
| Shows the item's description and, for a weapon, its kind; or hides them. | |
| void | STITSHOP_showPartnerStats (ShopInfo *info, ShopInfoWindows *win, s32 show) |
| Shows the party's names and, for those who can equip the item, the stats it changes; or hides them. | |
| void | STITSHOP_drawStatsPage (ShopInfo *info, ShopInfoWindows *win) |
| Draws the second page's frames: the panel, then for each partner its frame and either the icons of the stats the item changes or a cross. | |
| void | STITSHOP_runBuyInfo (ShopInfo *info, ShopInfoWindows *win) |
| The details panel's states when buying: fades in its first page, turns between the pages (10-16), and fades out when closed (50) | |
| void | STITSHOP_runSellInfo (ShopInfo *info, ShopInfoWindows *win) |
| The details panel's first page: fades in, shows the item, then fades out when closed. | |
| void | STITSHOP_updateInfo (ShopInfo *info, ShopInfoWindows *win) |
| The details panel: counts the party, then runs the pages and draws the item's icon and frames. | |
| void | STITSHOP_setInfoItem (ShopInfo *info, s32 item, s32 quantity) |
| Shows an item and the quantity (for the price) in the details panel (info->showItem); the windows are only refreshed while the page is shown. | |
| void | STITSHOP_closeInfo (ShopInfo *info) |
| Closes the details panel (info->close), when it is open and idle. | |
| void | STITSHOP_setKindVisible (ShopInfo *info, s32 visible) |
| Shows or hides the weapon's kind in the details panel (info->setKindVisible) | |
| void | STITSHOP_turnInfoPage (ShopInfo *info) |
| Turns the details panel between the description and the partners' stats (info->turnPage); only for the items of kinds 3 to 5, which have stats. | |
| void | STITSHOP_refreshPartner (ShopInfo *info, s32 member) |
| Refreshes the details panel once the item is equipped on a party member (info->refreshPartner): the item's rows and that partner's. | |
| ShopInfo * | STITSHOP_createInfo (s32 selling, s32 item) |
| Creates the details panel (task) of the item selected, when buying or selling. | |
| void | STITSHOP_createShopWindows (ItemShop *shop, ItemShopWindows *win) |
| shop.c | |
| void | STITSHOP_drawShop (ItemShop *shop, ItemShopWindows *win) |
| Draws the shop's four frames as they open by scaling, and the background, which scrolls one pixel every other frame, wrapping at 96. | |
| void | STITSHOP_runShop (ItemShop *shop, ItemShopWindows *win) |
| Opens the shop's panels, then up/down and cross pick buy or sell and run that dialog, reopening after it; triangle closes the panels and fades out. | |
| void | STITSHOP_updateShop (ItemShop *shop, ItemShopWindows *win) |
| The shop's task: loads its files, then runs it; goes back to the field when killed. | |
| void | STITSHOP_showMoney (ItemShop *shop) |
| Shows the money left (shop->showMoney), after buying or selling. | |
| ItemShop * | STITSHOP_createShop (void) |
| Creates the item shop (task) for the shop of the mode's argument. | |
| void | STITSHOP_loadFiles (void) |
| Loads the shop's textures and requests its strings. | |
| s32 | STITSHOP_filesLoading (void) |
| Whether the shop's strings are still loading. | |
| void | STITSHOP_startFade (PanelAnim *fade, s32 fadeIn) |
| s32 | STITSHOP_updateFade (PanelAnim *fade) |
| void | STITSHOP_startLerp (MenuLerp *lerp, s32 from, s32 to, s32 frames) |
| s32 | STITSHOP_updateLerp (MenuLerp *lerp) |
| s16 * | STITSHOP_getShopItems (s32 shop) |
| equip.c | |
| 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 when both are taken), 4 or 5 for the accessories (the one with the same group, else the weaker one); -1 when it can't. | |
| 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.items and GAME.equippedItems only when fromBag is set. | |
Variables | |
| s32 | STITSHOP_sellLists [] |
| STITSHOP's data (data/stitshop.c), in its order. | |
| Vec2 | STITSHOP_changePos [] |
| Where the stat change arrows go in a partner's column. | |
| s32 | STITSHOP_stats [] |
| the stats the info shows | |
| s32 | STITSHOP_kindStrings [] |
| the strings of the item kinds | |
| s32 | STITSHOP_shopNames [] |
| The shops' names, by ItemShop.shop. | |
| ShopList | STITSHOP_shops [31] |
| STITSHOP_stock0 to 30, the items of each shop, are only STITSHOP_shops'. | |
| ItemShopFuncs | STITSHOP_funcs |
| The shop's helpers. | |
STITSHOP.PRO: the item shop.
The game mode's argument picks the shop (STITSHOP_shops, a list of the items it sells); the player buys items for the money, sells them, and equips what was bought on a partner. Its strings are in file 0x72. Its modules are in src/menus/item_shop/, and the functions below are by module, in the order they link.
Definition in file item_shop.h.
| #define OVL_NAME | ( | name | ) | STITSHOP_##name |
The name of this overlay's copy of a function of src/shared/.
Definition at line 13 of file item_shop.h.
| #define FILE_SHOP_SPRITES 0x402 |
The shop's sprite sheet; the next file is its texture archive.
Definition at line 19 of file item_shop.h.
| void STITSHOP_startFader | ( | ScreenFade * | task, |
| s32 | fadeIn, | ||
| s32 | duration | ||
| ) |
| void STITSHOP_drawFader | ( | ScreenFade * | task | ) |
| void STITSHOP_updateFader | ( | ScreenFade * | task | ) |
| ScreenFade * STITSHOP_createFader | ( | void | ) |
| void STITSHOP_createBuyWindows | ( | ShopBuy * | buy, |
| ShopBuyWindows * | win | ||
| ) |
Definition at line 8 of file trade.c.
Referenced by STITSHOP_updateBuy().
| void STITSHOP_showQuantity | ( | ShopBuy * | buy, |
| ShopBuyWindows * | win, | ||
| s32 | show | ||
| ) |
Shows the quantity to buy; or hides it.
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
Definition at line 20 of file trade.c.
Referenced by STITSHOP_chooseBuyQuantity(), and STITSHOP_runBuy().
| void STITSHOP_showBuyTotal | ( | ShopBuy * | buy, |
| ShopBuyWindows * | win, | ||
| s32 | show | ||
| ) |
Shows the total price with yes and no to confirm the purchase; or hides them.
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
Definition at line 34 of file trade.c.
Referenced by STITSHOP_openBuyTotal(), and STITSHOP_runBuy().
| void STITSHOP_drawBuy | ( | ShopBuy * | buy, |
| ShopBuyWindows * | win | ||
| ) |
Draws the buying screen's frames, the quantity's blinking arrows and the marker over a partner.
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
Definition at line 49 of file trade.c.
Referenced by STITSHOP_updateBuy().
| void STITSHOP_runBuy | ( | ShopBuy * | buy, |
| ShopBuyWindows * | win | ||
| ) |
The buying dialog: pick the item in the list, how many, confirm, then (equipment) whether to equip it and on which partner.
< ITSHOP: STITSHOP's
< SYSTEM07
< SYSTEM07
Definition at line 439 of file trade.c.
Referenced by STITSHOP_updateBuy().
| void STITSHOP_updateBuy | ( | ShopBuy * | buy, |
| ShopBuyWindows * | win | ||
| ) |
The buying dialog's task: creates its windows, starting at a quantity of 1, then runs and draws it.
Definition at line 652 of file trade.c.
Referenced by STITSHOP_createBuy().
Shows the item selected in the list, and the quantity, in the details panel (buy->showItem)
Definition at line 676 of file trade.c.
Referenced by STITSHOP_createBuy().
Creates the buying dialog (task), when buy is chosen in the shop.
Definition at line 683 of file trade.c.
Referenced by STITSHOP_runShop().
| void STITSHOP_createSellWindows | ( | ShopSell * | sell, |
| ShopSellWindows * | win | ||
| ) |
Creates the selling dialog's windows: the cursor, the four kinds of sale, the quantity, the total with its yes and no, and the message.
Definition at line 695 of file trade.c.
Referenced by STITSHOP_updateSell().
| void STITSHOP_drawSell | ( | ShopSell * | sell, |
| ShopSellWindows * | win | ||
| ) |
Draws the selling screen's frames, and the quantity's blinking arrows.
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
Definition at line 713 of file trade.c.
Referenced by STITSHOP_updateSell().
| void STITSHOP_runSell | ( | ShopSell * | sell, |
| ShopSellWindows * | win | ||
| ) |
The selling dialog: pick the kind of item, then the item in the list, how many, and confirm.
< SYSTEM00: a choice is taken
< SYSTEM01
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< SYSTEM07
Definition at line 1007 of file trade.c.
Referenced by STITSHOP_updateSell().
| void STITSHOP_updateSell | ( | ShopSell * | sell, |
| ShopSellWindows * | win | ||
| ) |
The selling dialog's task: creates its windows, starting at a quantity of 1, then runs and draws it.
Definition at line 1174 of file trade.c.
Referenced by STITSHOP_createSell().
Shows the item selected in the list, and the quantity, in the details panel (sell->showItem)
Definition at line 1199 of file trade.c.
Referenced by STITSHOP_createSell().
Creates the selling dialog (task), when sell is chosen in the shop.
Definition at line 1206 of file trade.c.
Referenced by STITSHOP_runShop().
| void STITSHOP_createItemListWindows | ( | ShopItemList * | list, |
| ShopItemListWindows * | win | ||
| ) |
item_list.c
item_list.c
Definition at line 7 of file item_list.c.
Referenced by STITSHOP_updateItemList().
| void STITSHOP_showItemPage | ( | ShopItemList * | list, |
| ShopItemListWindows * | win, | ||
| s32 | show | ||
| ) |
Shows the page of items, the page number and the arrows' labels; or hides them.
< ITMNAM
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
Definition at line 26 of file item_list.c.
Referenced by STITSHOP_refreshItemList(), STITSHOP_runItemList(), and STITSHOP_updateItemList().
| void STITSHOP_drawItemList | ( | ShopItemList * | list | ) |
Draws the list's frame, the items' icons and the blinking page arrows.
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
Definition at line 75 of file item_list.c.
Referenced by STITSHOP_updateItemList().
| void STITSHOP_runItemList | ( | ShopItemList * | list, |
| ShopItemListWindows * | win | ||
| ) |
The list's states: lists the shop's items or the bag's, fades in, then fades out when closed.
Definition at line 133 of file item_list.c.
Referenced by STITSHOP_updateItemList().
| void STITSHOP_updateItemList | ( | ShopItemList * | list, |
| ShopItemListWindows * | win | ||
| ) |
The item list: L1 and R1 turn its pages, the d-pad moves in the page, and the dialog shows the selected item.
< SYSTEM02: a cursor moves
< SYSTEM02: a cursor moves
Definition at line 176 of file item_list.c.
Referenced by STITSHOP_createItemList().
| void STITSHOP_freezeListCursor | ( | ShopItemList * | list, |
| s32 | frozen | ||
| ) |
Freezes the list's cursor (still, in palette 7) and its input, or lets them go again (list->freezeCursor): while the details panel turns its page.
< what is unavailable
Definition at line 271 of file item_list.c.
Referenced by STITSHOP_createItemList().
| void STITSHOP_showListCursor | ( | ShopItemList * | list, |
| s32 | visible | ||
| ) |
Shows the list's cursor at the selection and takes the d-pad, or hides it and stops (list->showCursor)
Definition at line 287 of file item_list.c.
Referenced by STITSHOP_closeItemList(), and STITSHOP_createItemList().
| void STITSHOP_startItemList | ( | ShopItemList * | list | ) |
Runs the list's states again (list->start), to reopen it after the quantity and the yes/no.
Definition at line 299 of file item_list.c.
Referenced by STITSHOP_createItemList().
| void STITSHOP_closeItemList | ( | ShopItemList * | list | ) |
Closes the list (list->close): hides the cursor and fades it out.
Definition at line 304 of file item_list.c.
Referenced by STITSHOP_createItemList().
| s32 STITSHOP_getSelectedItem | ( | ShopItemList * | list | ) |
The item at the list's selection, of the shop's or of the bag's sellable ones (list->getSelected)
Definition at line 312 of file item_list.c.
Referenced by STITSHOP_createItemList().
| void STITSHOP_refreshItemList | ( | ShopItemList * | list | ) |
Lists the sellable items again, shows the page and the selection in the dialog (list->refresh)
Definition at line 321 of file item_list.c.
Referenced by STITSHOP_createItemList().
| void STITSHOP_listSellable | ( | ShopItemList * | list | ) |
Lists the bag's items of the list's type that can be sold, those with a sell price (list->listBag, again after a sale)
Definition at line 331 of file item_list.c.
Referenced by STITSHOP_createItemList(), STITSHOP_refreshItemList(), and STITSHOP_runItemList().
| ShopItemList * STITSHOP_createItemList | ( | ShopDialog * | dialog, |
| s32 | type, | ||
| s32 | selling | ||
| ) |
Creates the item list (task) of a dialog: the items of the shop type when buying, the bag's of the item type when selling.
Definition at line 346 of file item_list.c.
Referenced by STITSHOP_reopenSellList(), STITSHOP_runBuy(), and STITSHOP_runSell().
info.c
info.c
Definition at line 10 of file info.c.
Referenced by STITSHOP_fillPartnerRows().
Adds an item's bonus to a stat, up to 999: 1 to 6 one of the six battle stats, 7 all of them, 8 to 14 a resistance.
< the first of the seven resistances
< the first of the seven resistances
< the first of the seven resistances
Definition at line 87 of file info.c.
Referenced by STITSHOP_computeStats().
| void STITSHOP_showStat | ( | ShopInfo * | info, |
| TextWindow * | win, | ||
| ShopStatRow * | row | ||
| ) |
Shows a row's stat of a partner in the details panel: as it is, or with the item equipped when the row compares.
Definition at line 116 of file info.c.
Referenced by STITSHOP_fillPartnerRows().
| void STITSHOP_colorStat | ( | ShopInfo * | info, |
| TextWindow * | win, | ||
| ShopStatRow * | row | ||
| ) |
Colors a row's stat: palette 1 when the item would raise it, 5 when it would lower it, else 6 when a penalty lowers it (STAT_STRENGTH, STAT_DEFENSE and STAT_SPEED), 0 otherwise.
< a light blue: what is highlighted or current
Definition at line 132 of file info.c.
Referenced by STITSHOP_fillPartnerRows().
| void STITSHOP_showOtherChanges | ( | ShopInfo * | info, |
| TextWindow ** | win, | ||
| ShopStatRow * | row | ||
| ) |
Shows the new values of the other stats the item would change (palette 1 up, 5 down), noting them in the partner's rows; hides the windows left over.
< a light blue: what is highlighted or current
Definition at line 171 of file info.c.
Referenced by STITSHOP_fillPartnerRows().
| void STITSHOP_fillPartnerRows | ( | ShopInfo * | info, |
| ShopInfoWindows * | win, | ||
| s32 | member | ||
| ) |
Fills a partner's rows of the details panel's second page: the stats of the slot the item goes in, then the others it would change.
The item is equipped to compute them and the partner's equipment put back
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
Definition at line 203 of file info.c.
Referenced by STITSHOP_refreshPartner(), and STITSHOP_showPartnerStats().
| void STITSHOP_createInfoWindows | ( | ShopInfo * | info, |
| ShopInfoWindows * | win | ||
| ) |
Creates the details panel's windows: the item's rows, then, when buying, each partner's name, stats and stat changes.
Definition at line 351 of file info.c.
Referenced by STITSHOP_updateInfo().
| void STITSHOP_showItemRows | ( | ShopInfo * | info, |
| ShopInfoWindows * | win, | ||
| s32 | show | ||
| ) |
Shows the item's name, how many are equipped and in the bag, and its price; or hides them.
< ITMNAM
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
Definition at line 398 of file info.c.
Referenced by STITSHOP_closeBuyInfo(), STITSHOP_openBuyInfo(), STITSHOP_refreshPartner(), STITSHOP_runSellInfo(), and STITSHOP_setInfoItem().
| void STITSHOP_showItemDesc | ( | ShopInfo * | info, |
| ShopInfoWindows * | win, | ||
| s32 | show | ||
| ) |
Shows the item's description and, for a weapon, its kind; or hides them.
< ITMINF
< ITSHOP: STITSHOP's
Definition at line 426 of file info.c.
Referenced by STITSHOP_closeBuyInfo(), STITSHOP_hideBuyInfoPage(), STITSHOP_runBuyInfo(), STITSHOP_runSellInfo(), STITSHOP_setInfoItem(), and STITSHOP_startInfoPageTurn().
| void STITSHOP_showPartnerStats | ( | ShopInfo * | info, |
| ShopInfoWindows * | win, | ||
| s32 | show | ||
| ) |
Shows the party's names and, for those who can equip the item, the stats it changes; or hides them.
< what is unavailable
Definition at line 446 of file info.c.
Referenced by STITSHOP_closeBuyInfo(), STITSHOP_runBuyInfo(), STITSHOP_setInfoItem(), and STITSHOP_startInfoPageTurn().
| void STITSHOP_drawStatsPage | ( | ShopInfo * | info, |
| ShopInfoWindows * | win | ||
| ) |
Draws the second page's frames: the panel, then for each partner its frame and either the icons of the stats the item changes or a cross.
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
Definition at line 483 of file info.c.
Referenced by STITSHOP_updateInfo().
| void STITSHOP_runBuyInfo | ( | ShopInfo * | info, |
| ShopInfoWindows * | win | ||
| ) |
The details panel's states when buying: fades in its first page, turns between the pages (10-16), and fades out when closed (50)
Definition at line 603 of file info.c.
Referenced by STITSHOP_updateInfo().
| void STITSHOP_runSellInfo | ( | ShopInfo * | info, |
| ShopInfoWindows * | win | ||
| ) |
The details panel's first page: fades in, shows the item, then fades out when closed.
Definition at line 711 of file info.c.
Referenced by STITSHOP_updateInfo().
| void STITSHOP_updateInfo | ( | ShopInfo * | info, |
| ShopInfoWindows * | win | ||
| ) |
The details panel: counts the party, then runs the pages and draws the item's icon and frames.
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
Definition at line 751 of file info.c.
Referenced by STITSHOP_createInfo().
Shows an item and the quantity (for the price) in the details panel (info->showItem); the windows are only refreshed while the page is shown.
Definition at line 812 of file info.c.
Referenced by STITSHOP_createInfo().
| void STITSHOP_closeInfo | ( | ShopInfo * | info | ) |
Closes the details panel (info->close), when it is open and idle.
Definition at line 829 of file info.c.
Referenced by STITSHOP_createInfo().
Shows or hides the weapon's kind in the details panel (info->setKindVisible)
Definition at line 836 of file info.c.
Referenced by STITSHOP_createInfo().
| void STITSHOP_turnInfoPage | ( | ShopInfo * | info | ) |
Turns the details panel between the description and the partners' stats (info->turnPage); only for the items of kinds 3 to 5, which have stats.
< SYSTEM06
Definition at line 844 of file info.c.
Referenced by STITSHOP_createInfo().
Refreshes the details panel once the item is equipped on a party member (info->refreshPartner): the item's rows and that partner's.
Definition at line 856 of file info.c.
Referenced by STITSHOP_createInfo().
Creates the details panel (task) of the item selected, when buying or selling.
Definition at line 865 of file info.c.
Referenced by STITSHOP_runBuy(), and STITSHOP_runSell().
| void STITSHOP_createShopWindows | ( | ItemShop * | shop, |
| ItemShopWindows * | win | ||
| ) |
shop.c
shop.c
Definition at line 8 of file shop.c.
Referenced by STITSHOP_updateShop().
| void STITSHOP_drawShop | ( | ItemShop * | shop, |
| ItemShopWindows * | win | ||
| ) |
Draws the shop's four frames as they open by scaling, and the background, which scrolls one pixel every other frame, wrapping at 96.
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
< GTE regards 4096 as 1.0
Definition at line 21 of file shop.c.
Referenced by STITSHOP_updateShop().
| void STITSHOP_runShop | ( | ItemShop * | shop, |
| ItemShopWindows * | win | ||
| ) |
Opens the shop's panels, then up/down and cross pick buy or sell and run that dialog, reopening after it; triangle closes the panels and fades out.
< SHPNAM
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< ITSHOP: STITSHOP's
< SYSTEM02: a cursor moves
< SYSTEM00: a choice is taken
< SYSTEM01
Definition at line 60 of file shop.c.
Referenced by STITSHOP_updateShop().
| void STITSHOP_updateShop | ( | ItemShop * | shop, |
| ItemShopWindows * | win | ||
| ) |
The shop's task: loads its files, then runs it; goes back to the field when killed.
Definition at line 171 of file shop.c.
Referenced by STITSHOP_createShop().
| void STITSHOP_showMoney | ( | ItemShop * | shop | ) |
Shows the money left (shop->showMoney), after buying or selling.
Definition at line 206 of file shop.c.
Referenced by STITSHOP_createShop().
| ItemShop * STITSHOP_createShop | ( | void | ) |
| void STITSHOP_loadFiles | ( | void | ) |
| s32 STITSHOP_filesLoading | ( | void | ) |
Which equipment slot a bought item would go in: 2 or 3 for the weapons (the one with the weaker item when both are taken), 4 or 5 for the accessories (the one with the same group, else the weaker one); -1 when it can't.
< takes slots 2 and 3
< takes slots 2 and 3
< one of its group at a time
< one of its group at a time
< one of its group at a time
|
extern |
STITSHOP's data (data/stitshop.c), in its order.
the item list each kind of sale shows
STITSHOP's data (data/stitshop.c), in its order.
Definition at line 6 of file stitshop.c.
Referenced by STITSHOP_reopenSellList(), and STITSHOP_runSell().
|
extern |
Where the stat change arrows go in a partner's column.
Definition at line 10 of file stitshop.c.
Referenced by STITSHOP_drawStatsPage().
|
extern |
the stats the info shows
the stats the info shows
Definition at line 15 of file stitshop.c.
Referenced by STITSHOP_colorStat(), STITSHOP_showOtherChanges(), and STITSHOP_showStat().
|
extern |
the strings of the item kinds
the strings of the item kinds
Definition at line 21 of file stitshop.c.
Referenced by STITSHOP_showItemDesc().
|
extern |
The shops' names, by ItemShop.shop.
Definition at line 27 of file stitshop.c.
Referenced by STITSHOP_runShop().
|
extern |
STITSHOP_stock0 to 30, the items of each shop, are only STITSHOP_shops'.
STITSHOP_stock0 to 30, the items of each shop, are only STITSHOP_shops'.
Definition at line 194 of file stitshop.c.
Referenced by STITSHOP_getShopItems().
|
extern |
The shop's helpers.
Definition at line 228 of file stitshop.c.
Referenced by STITSHOP_chooseEquipPartner(), STITSHOP_closeBuyInfo(), STITSHOP_closeEquipQuestion(), STITSHOP_closeSellQuantity(), STITSHOP_closeSellTotal(), STITSHOP_closeSellTypes(), STITSHOP_drawStatsPage(), STITSHOP_endBuyInfo(), STITSHOP_endBuyTotal(), STITSHOP_endEquipped(), STITSHOP_endEquipQuestion(), STITSHOP_fillPartnerRows(), STITSHOP_getShopItems(), STITSHOP_hideBuyInfoPage(), STITSHOP_openBuyInfo(), STITSHOP_openBuyTotal(), STITSHOP_openEquipQuestion(), STITSHOP_openSellQuantity(), STITSHOP_openSellTotal(), STITSHOP_openSellTypes(), STITSHOP_reopenSellList(), STITSHOP_runBuy(), STITSHOP_runBuyInfo(), STITSHOP_runItemList(), STITSHOP_runSell(), STITSHOP_runSellInfo(), STITSHOP_runShop(), STITSHOP_showEquipMarker(), STITSHOP_showPartnerStats(), STITSHOP_startInfoPageTurn(), and STITSHOP_updateShop().