Skip to Content
The Alchemy Project

src/menu/menu_item.c

The item menu: the field menu's Item screen, the command loop, the party member and item lists, and Use, Equip, Give, Drop, Remove and Details. More…

Included by menu.c.

Macros

NameDescription
#defineITEM_MODAL_SHORT_X JAPANESE_OR(15, 14)Where the edition's text goes.
#defineITEM_MODAL_REMOVED_X JAPANESE_OR(17, 14)
#defineITEM_CANNOT_TRADE_X FRENCH_OR(11, 15)The x of the small message window "Can't trade it!".
#defineITEM_TRADED_X ITALIAN_OR(13, 15)The x of the small message window "Traded".
#defineITEM_TRADE_PROMPT_X JAPANESE_OR(16, 0)The x of "Trade for what?" in its window, in pixels.
#defineITEM_COMMAND_TEXT_X JAPANESE_OR(40, 32)The x of the command grid's middle column.
#defineITEM_QUANTITY_WINDOW_WIDTH JAPANESE_OR(13, 30)The quantity chooser's window width, in tiles.
#defineITEM_GIVE_CURSOR_X JAPANESE_OR(88, 128)The hand cursor and the "How many?" question of the quantity chooser.
#defineITEM_GIVE_ASK_X JAPANESE_OR(0, 32)
#defineITEM_GIVE_ASK_Y JAPANESE_OR(32, 0)
#defineITEM_DROP_QUESTION_X JAPANESE_OR(8, 0)The x of the drop question ("Are you sure you...") in its window, in pixels.
#defineITEM_LIST_PAGE_ICONS_X JAPANESE_OR(120, 116)The item list's icon column and name column.
#defineITEM_LIST_NAME_X JAPANESE_OR(32, 24)
#defineSAVED_WINDOW_TILE_BYTES 8192The bytes of window tiles (BG character block 1) the menu draws over, which it saves while it is open and puts back as it closes.
#defineITEM_COMMAND_COLUMNS 3The command grid's size: three commands to a row, two rows (ITEM_MENU_COMMAND counts them row by row).
#defineITEM_COMMAND_ROWS 2
#defineITEM_COMMAND_CURSOR_Y (row) ((row) * 8 + 30)The item command cursor on the command grid's rows, 8 pixels apart from y 30, and in Japanese on its columns, 40 pixels apart from x 86.
#defineITEM_COMMAND_CURSOR_X (column) ((column) * 40 + 86)
#defineITEM_COMMAND_STATE_DISABLED (-1)Each item command's state in the grid.
#defineITEM_COMMAND_STATE_AVAILABLE 1
#defineTEXT_COLOR_DISABLED

Enumerations

NameDescription
enumITEM_MENU_STEP { ITEM_STEP_MEMBER, ITEM_STEP_ITEM, ITEM_STEP_USE, ITEM_STEP_E … }The steps of the item menu's command loop (mnItemMenuRunCommands).

Functions

NameDescription
Sint32mnItemMenuRun (void)The field menu's Item screen (mnFieldMenuRun, FIELD_MENU_ITEM): choose a party member, one of their items and a command.
Sint32mnItemMenuRunCommands (Sint32 *memberOut, Sint32 *targetOut, Sint32 *itemOut)Runs the item menu: choose a party member, one of their items and a command (Use, Equip, Give, Drop, Remove or Details), then carry it out, until the player backs out or presses Start.
Sint32mnItemMenuUse (void)Uses the selected item from the party member in side 0 on the one in side 1.
voidmnItemMenuInit (Sint32 x, Sint32 y, Sint32 mode, Sint32 columns)Sets up the item menu's first screen: the cursor window with the party's figures, the info window along the bottom, and an 8 by 2 cursor grid. x, y, mode and columns are not used.
voidmnSpawnIconEntries (ITEM_MENU_STATE *menu, WINDOW *window)Creates the 32 item icon sprites in window, off screen until placed: slots 0 to 7 at MENU_ICON_HIDDEN_X, the rest 8 pixels further, all at MENU_ICON_HIDDEN_Y, each showing item graphic slot of the same number.
voidmnItemMenuHideAllIcons (void)Hides all the item icons.
voidmnItemMenuHidePageIcons (void)Hides the item icons in the first column of the five-wide item grid.
voidmnItemMenuClose (void)Closes the item menu: releases the party figures, hides the icons and the status panel's portrait (the state's cursor), and closes every window the menu opened.
Sint32mnItemMenuSelectMember (Sint32 side)Lets the player choose a party member in side (0 or 1), starting from the party member chosen last.
Sint32mnItemMenuRunMemberSelection (Uint16 *memberIds, Uint16 *items)The item menu's party member row: Left and Right choose whose items to look at, showing their items and status, R held shows their equipment and stats instead, L and A sorts their items into the next of the four orders, and A chooses a party member who has items.
voidmnItemMenuShowEquipment (Sint32 memberId)Shows the equipment view of party member memberId's items in the item window.
Sint32mnItemMenuSelectTarget (Sint32 mode)Chooses the party member to use or give the selected item (enum ITEM_TARGET_MODE) to.
voidmnEquipmentMenuUpdateCompatibilityIndicators (void)Event while mnItemMenuSelectTarget chooses a party member to use or give the item to, and while the command grid's cursor is on Give: every 32 ticks, has each party figure nod (ANIM_NOD) if that party member can equip the item, or stand (ANIM_STAND) if not.
voidmnEquipmentMenuStopCompatibilityIndicators (void)Ends mnEquipmentMenuUpdateCompatibilityIndicators: puts every party figure back to ANIM_STAND and removes the event.
BoolmnItemMenuIsStatRaisingItem (Sint32 itemId)Returns TRUE for the items that raise a stat for good (Apple, Hard Nut, Mint and Lucky Pepper), whose use shows the stats panel instead of HP and PP.
voidmnItemMenuDrawMessage (Sint32 unused, Sint32 msg)Clears the message window and writes message into it.
voidmnHideEmptyEntryIcons (const Uint16 *items)Hides the icon of each of the 32 list entries whose item is 0.
Sint32mnItemMenuCountItems (Sint32 memberId)Returns how many of party member memberId's 15 inventory slots hold an item.
Sint32mnItemMenuGetItemQuantity (Sint32 memberId, Sint32 itemId)Returns how many of itemId the unit memberId holds: the quantity of its first stack, or 0.
Sint32mnItemMenuCollectItems (UNIT *unit, Uint16 *items, Sint32 unused)Copies the unit's items into the list items (32 entries), skipping empty slots and clearing the rest.
voidmnItemMenuDrawIcons (Uint16 *inventoryEntries, Sint32 iconStyle)Loads each listed item's icon into its item icon sprite, the first 15 entries of inventoryEntries, and hides the icons of empty entries. iconStyle 0 draws the list's icons (ICON_KIND_ITEM); any other iconStyle the equipment view's (ICON_KIND_EQUIPMENT_ITEM).
voidmnItemMenuRefreshMember (Sint32 memberId, Sint32 mode)Shows party member memberId's items in the item window, laid out for layout mode (see mnItemMenuPlaceIcons), or "no items" when there are none.
voidmnItemMenuNoOperation (void)
voidmnItemMenuDrawEquipPreview (Sint32 member, Sint32 slot, Sint32 mode, Sint32 target)Shows in the status panel what the item in member's inventory slot would mean to member target: for a usable item, target's status; for equipment, target's stats with it equipped; for a Psynergy item, the Psynergy it teaches.
Sint32mnInventoryMakeRoom (Sint32 memberId)Makes room in memberId's inventory for a preview: if no slot is free, removes the whole stack in the first slot that is not equipped.
Sint32mnItemMenuCommandCursorX (Sint32 column, Sint32 row)Returns the x of the item command cursor on column and row of the command grid (three commands to a row), or 0 when column or row is outside 0 to 2.
Sint32mnItemMenuCommandCursorY (Sint32 column, Sint32 row)Returns the y of the item command cursor: its top row, or the row below for any other row.
Sint32mnItemMenuChooseCommand (void)The item command grid: Use, Equip and Details on the top row, Give, Remove and Drop below.
voidmnItemMenuBuildCommands (Sint8 *commandStates)Fills commandStates (indexed by ITEM_MENU_COMMAND) with ITEM_COMMAND_STATE_AVAILABLE or _DISABLED for the selected item: Use for items mnItemClassifyUseMode accepts and are not broken, and for field items, Equip for equipment the party member can wear and is not wearing, Remove for worn equipment that is not cursed, Give with someone to give to, Drop unless the item is indispensable, and neither for cursed equipment being worn.
voidmnItemMenuDrawCommands (const Sint8 *commandStates, WINDOW *window)Writes the six command names into window, the disabled ones in grey.
Sint32mnItemClassifyUseMode (Sint32 memberId, Sint32 inventoryEntry)Says how memberId can use inventoryEntry from the item menu (enum ITEM_USE_MODE).
voidmnItemMenuTryBreak (void)After the selected item is used: an item that may break (ITEM_USE_MAY_BREAK) breaks one time in eight, with the break sound and "It broke!" in the info window.
Sint32mnItemMenuOpenDetail (Sint32 itemIndex)Opens the details window (top left, 13 by 10 tiles) and describes the item in side itemIndex there.
Sint32mnItemMenuShowDetails (Sint32 inventoryEntry)The item menu's Details screen: describes inventoryEntry in a window over the top half (13 tiles wide in Japanese) and waits for A or B.
voidmnItemMenuDrawItemDetails (WINDOW *window, Sint32 inventoryEntry)Writes the description of the inventoryEntry into window, one line a row: for equipment its Attack and Defense bonuses, then each of its effects (flat bonuses, rates as multipliers, elemental Power and Resist with the element's icon, and the effects that are only text), whether it is cursed or bestows Psynergy, whether it is used up or may break, and for a stack how many there are.
voidmnItemMenuDrawStat ( Sint32 statChange, Sint32 unused, WINDOW *window, Sint32 x, Sint32 y)Writes a signed stat change at (x, y) of window: the number, with a plus or minus sign just before its first digit.
voidmnItemMenuPlaceItemWindowBelowItemQuestion (void)Moves the item window to row 5 of the right-hand side, below a question headed by the item.
voidmnItemMenuPlaceItemWindowBelowQuestion (void)Moves the item window to row 3 of the right-hand side, below a one-line question.
voidmnItemMenuFitMessageWindowToItemQuestion (void)Makes the message window, along the top right, 5 rows tall: the item's name and a question below it.
voidmnItemMenuFitMessageWindowToLongItemQuestion (void)Makes the message window 6 rows tall, for the longer questions outside Japanese.
voidmnItemMenuFitMessageWindowToItemChoices (void)Makes the message window 7 rows tall: the item's name above the command grid or the quantity dial.
voidmnItemMenuFitMessageWindowToQuestion (void)Makes the message window 3 rows tall, for a one-line question.
Sint32mnItemMenuSelectGiveQuantity (Sint32 baseQuantity, Sint32 quantityRange, Sint32 dropMode)Asks how many of the selected item stack to give or drop: Left and Right choose a number from 1 to quantityRange (shown as baseQuantity + 1 up to baseQuantity + quantityRange on a dial of digit sprites), with the party member's remaining count and, when giving (dropMode 0), the receiver's new count beside their names.
voidmnItemMenuDrawItemHead (void)Shows the selected item at the top of the message window: its icon, its party member's name and its name.
Sint32mnItemMenuConfirmDrop (Sint32 item)Asks whether to drop item (an inventory entry): its name, the question, and Yes or No, No first.
Sint32mnItemMenuConfirmEquip (Sint32 unused)After giving or trading the selected item to the party member in side 1, offers to equip it there, showing the stats it would give.
voidmnLoadStatArrows (void)Loads the stat arrows (up and down) into two free VRAM blocks, kept in the menu state's resource slots.
Sint32mnItemMenuBuildPagedList (PAGED_LIST *result, Sint32 index)Fills result with the item list of the party member in side index: their unit, how many items they hold, and the page and row of the item chosen last for them (kept within the list), five items to a page.
Sint32mnItemMenuShowSelectedRow (WINDOW *window, void *memberState, PAGED_LIST *pageState)Updates the item list for the row under the cursor: puts the selected item's plain name in the info window and highlights its row of the five. window and memberState are not used.
Sint32mnItemMenuDrawListPage (WINDOW *window, Sint32 unused, const PAGED_LIST *pageState)Draws one page of the item list into window: up to five item names with their icons, and the page numbers when there is more than one page.
Sint32mnItemMenuItemNamePageReturnTrue (void)
voidmnItemMenuItemNamePageNoOperation (void)
Sint32mnItemMenuRunList (Sint32 sideIndex)The item list of the party member in sideIndex (0: the holder, 1: the receiver of a trade), five items a page: Up and Down choose, Left and Right turn the page, L and R go to the previous or next party member with items (side 0 only), and A chooses.

Description

The item menu: the field menu's Item screen, the command loop, the party member and item lists, and Use, Equip, Give, Drop, Remove and Details. Part of menu.c.

Macros in detail

ITEM_MODAL_SHORT_X

#define ITEM_MODAL_SHORT_X JAPANESE_OR(15, 14)

Where the edition's text goes. The international editions have longer words, and some languages move a message to fit its own.

The x of the small message windows "Dropped it.", "You were cursed!" and "Removed".

Referenced by mnItemMenuRunCommands().

Definition at line 13 of file menu_item.c.

ITEM_MODAL_REMOVED_X

#define ITEM_MODAL_REMOVED_X JAPANESE_OR(17, 14)

Referenced by mnItemMenuRunCommands().

Definition at line 14 of file menu_item.c.

ITEM_CANNOT_TRADE_X

#define ITEM_CANNOT_TRADE_X FRENCH_OR(11, 15)

The x of the small message window "Can't trade it!".

Referenced by mnItemMenuRunCommands().

Definition at line 17 of file menu_item.c.

ITEM_TRADED_X

#define ITEM_TRADED_X ITALIAN_OR(13, 15)

The x of the small message window "Traded".

Referenced by mnItemMenuRunCommands().

Definition at line 20 of file menu_item.c.

ITEM_TRADE_PROMPT_X

#define ITEM_TRADE_PROMPT_X JAPANESE_OR(16, 0)

The x of "Trade for what?" in its window, in pixels.

Definition at line 23 of file menu_item.c.

ITEM_COMMAND_TEXT_X

#define ITEM_COMMAND_TEXT_X JAPANESE_OR(40, 32)

The x of the command grid's middle column.

Referenced by mnItemMenuDrawCommands().

Definition at line 26 of file menu_item.c.

ITEM_QUANTITY_WINDOW_WIDTH

#define ITEM_QUANTITY_WINDOW_WIDTH JAPANESE_OR(13, 30)

The quantity chooser's window width, in tiles.

Referenced by mnItemMenuShowDetails().

Definition at line 29 of file menu_item.c.

ITEM_GIVE_CURSOR_X

#define ITEM_GIVE_CURSOR_X JAPANESE_OR(88, 128)

The hand cursor and the "How many?" question of the quantity chooser.

Referenced by mnItemMenuSelectGiveQuantity().

Definition at line 32 of file menu_item.c.

ITEM_GIVE_ASK_X

#define ITEM_GIVE_ASK_X JAPANESE_OR(0, 32)

Referenced by mnItemMenuSelectGiveQuantity().

Definition at line 33 of file menu_item.c.

ITEM_GIVE_ASK_Y

#define ITEM_GIVE_ASK_Y JAPANESE_OR(32, 0)

Referenced by mnItemMenuSelectGiveQuantity().

Definition at line 34 of file menu_item.c.

ITEM_DROP_QUESTION_X

#define ITEM_DROP_QUESTION_X JAPANESE_OR(8, 0)

The x of the drop question ("Are you sure you...") in its window, in pixels.

Referenced by mnItemMenuConfirmDrop().

Definition at line 37 of file menu_item.c.

ITEM_LIST_PAGE_ICONS_X

#define ITEM_LIST_PAGE_ICONS_X JAPANESE_OR(120, 116)

The item list's icon column and name column.

Referenced by mnItemMenuDrawListPage().

Definition at line 40 of file menu_item.c.

ITEM_LIST_NAME_X

#define ITEM_LIST_NAME_X JAPANESE_OR(32, 24)

Referenced by mnItemMenuDrawListPage().

Definition at line 41 of file menu_item.c.

SAVED_WINDOW_TILE_BYTES

#define SAVED_WINDOW_TILE_BYTES 8192

The bytes of window tiles (BG character block 1) the menu draws over, which it saves while it is open and puts back as it closes.

Referenced by mnItemMenuRun().

Definition at line 45 of file menu_item.c.

ITEM_COMMAND_COLUMNS

#define ITEM_COMMAND_COLUMNS 3

The command grid's size: three commands to a row, two rows (ITEM_MENU_COMMAND counts them row by row).

Referenced by mnItemMenuChooseCommand() and mnItemMenuCommandCursorX().

Definition at line 1827 of file menu_item.c.

ITEM_COMMAND_ROWS

#define ITEM_COMMAND_ROWS 2

Referenced by mnItemMenuChooseCommand().

Definition at line 1828 of file menu_item.c.

ITEM_COMMAND_CURSOR_Y

#define ITEM_COMMAND_CURSOR_Y(row) ((row) * 8 + 30)

The item command cursor on the command grid's rows, 8 pixels apart from y 30, and in Japanese on its columns, 40 pixels apart from x 86.

Referenced by mnItemMenuCommandCursorY().

Definition at line 1832 of file menu_item.c.

ITEM_COMMAND_CURSOR_X

#define ITEM_COMMAND_CURSOR_X(column) ((column) * 40 + 86)

Definition at line 1834 of file menu_item.c.

ITEM_COMMAND_STATE_DISABLED

#define ITEM_COMMAND_STATE_DISABLED (-1)

Each item command's state in the grid.

Referenced by mnItemMenuBuildCommands(), mnItemMenuChooseCommand() and mnItemMenuDrawCommands().

Definition at line 1865 of file menu_item.c.

ITEM_COMMAND_STATE_AVAILABLE

#define ITEM_COMMAND_STATE_AVAILABLE 1

Referenced by mnItemMenuBuildCommands() and mnItemMenuChooseCommand().

Definition at line 1866 of file menu_item.c.

TEXT_COLOR_DISABLED

#define TEXT_COLOR_DISABLED

Referenced by mnItemMenuDrawCommands().

Definition at line 2155 of file menu_item.c.

Enumerations in detail

ITEM_MENU_STEP

enum ITEM_MENU_STEP

The steps of the item menu's command loop (mnItemMenuRunCommands).

EnumeratorValueDescription
ITEM_STEP_MEMBER0
ITEM_STEP_ITEM1
ITEM_STEP_USE2
ITEM_STEP_EQUIP3
ITEM_STEP_GIVE4
ITEM_STEP_DROP5
ITEM_STEP_TARGET6Give: choose whom to give it to
ITEM_STEP_TRADE7the receiver is full: choose what they give back
ITEM_STEP_IDLE8nothing sets it
ITEM_STEP_COMMAND9
ITEM_STEP_DETAILS10Details (mnItemMenuShowDetails)
ITEM_STEP_REMOVE11
ITEM_STEP_QUANTITY12nothing sets it

Definition at line 125 of file menu_item.c.

Functions in detail

mnItemMenuRun

Sint32 mnItemMenuRun(void)

The field menu's Item screen (mnFieldMenuRun, FIELD_MENU_ITEM): choose a party member, one of their items and a command.

References fdPartyClearUnusableShortcutsStub(), gmPartyListMembersStub(), mnIconMenuReleaseArrows(), mnInitState(), mnItemMenuClose(), mnItemMenuInit(), mnItemMenuRunCommands(), mnLoadStatArrows(), mnPageArrowsDrawStub(), mnPaletteLightenHighlight(), mnResumeFieldEvents(), mnStartWatchingStart(), mnStopWatchingStart(), mnSuspendFieldEvents(), mnTextUseExtraTilesStub(), mnWindowCreateStub(), mnWindowDrawBorderStub(), mnWindowEraseBorderRectStub(), mnWindowMarkVisibleTextTilesStub(), mnWindowSpriteClearListStub(), Sint32, syHeapAllocateEWRAM(), syHeapRelease(), syHeapSlotAllocate(), syHeapSlotRelease(), sySynch(), syWordsCopy() and syWordsFill().

Definition at line 49 of file menu_item.c.

mnItemMenuRunCommands

Sint32 mnItemMenuRunCommands(Sint32 *memberOut, Sint32 *targetOut, Sint32 *itemOut)

Runs the item menu: choose a party member, one of their items and a command (Use, Equip, Give, Drop, Remove or Details), then carry it out, until the player backs out or presses Start. Returns 1 when an item is to be used from the field, with its user, target and item through the three pointers, or -1.

References fdHasItemCueStub(), fdPartyClearUnusableShortcutsStub(), gmFlagGetStub(), gmInventoryAddItemStub(), gmInventoryEquipStub(), gmInventoryRemoveStub(), gmItemAdjustRareItemStockStub(), gmItemGetDefinitionStub(), gmUnitCalculateStub(), gmUnitGetStub(), gmUnitRefreshPsynergyStub(), mnDrawCoins(), mnIconShow(), mnItemClassifyUseMode(), mnItemMenuChooseCommand(), mnItemMenuCollectItems(), mnItemMenuConfirmDrop(), mnItemMenuConfirmEquip(), mnItemMenuCountItems(), mnItemMenuDrawEquipPreview(), mnItemMenuDrawIcons(), mnItemMenuDrawItemHead(), mnItemMenuDrawMessage(), mnItemMenuFitMessageWindowToItemQuestion(), mnItemMenuFitMessageWindowToLongItemQuestion(), mnItemMenuFitMessageWindowToQuestion(), mnItemMenuGetItemQuantity(), mnItemMenuHideAllIcons(), mnItemMenuHidePageIcons(), mnItemMenuIsStatRaisingItem(), mnItemMenuPlaceItemWindowBelowItemQuestion(), mnItemMenuPlaceItemWindowBelowQuestion(), mnItemMenuRefreshMember(), mnItemMenuRunList(), mnItemMenuSelectGiveQuantity(), mnItemMenuSelectMember(), mnItemMenuSelectTarget(), mnItemMenuShowDetails(), mnItemMenuShowMessage(), mnItemMenuTryBreak(), mnItemMenuUse(), mnSelectionIconLoadIntoSlotStub(), mnStatusPanelDraw(), mnTextDrawMessageAsTilesStub(), mnWindowClearInteriorTilesStub(), mnWindowSpriteClearListStub(), mnWindowSpriteRedrawSavedRectStub(), Sint32, syHeapAllocate(), syHeapRelease() and 3 more.

Referenced by mnItemMenuRun().

Definition at line 146 of file menu_item.c.

mnItemMenuUse

Sint32 mnItemMenuUse(void)

Uses the selected item from the party member in side 0 on the one in side 1.

References gmUnitCalculateStub(), mnItemMenuShowMessage(), mnItemPlayUseSound(), mnItemUse(), mnWindowSpriteClearListStub(), mnWindowSpriteRedrawSavedRectStub(), Sint32 and sySoundPlayStub().

Referenced by mnItemMenuRunCommands().

Definition at line 923 of file menu_item.c.

mnItemMenuInit

void mnItemMenuInit(Sint32 x, Sint32 y, Sint32 mode, Sint32 columns)

Sets up the item menu's first screen: the cursor window with the party's figures, the info window along the bottom, and an 8 by 2 cursor grid. x, y, mode and columns are not used.

References mnCreatePartyFigures(), mnCursorCreate(), mnWindowCreateStub() and Sint32.

Referenced by mnDjinnMenuRun(), mnItemMenuRun() and mnPsynergyMenuRun().

Definition at line 954 of file menu_item.c.

mnSpawnIconEntries

void mnSpawnIconEntries(ITEM_MENU_STATE *menu, WINDOW *window)

Creates the 32 item icon sprites in window, off screen until placed: slots 0 to 7 at MENU_ICON_HIDDEN_X, the rest 8 pixels further, all at MENU_ICON_HIDDEN_Y, each showing item graphic slot of the same number.

References mnWindowSpriteCreateFromResourceStub() and Sint32.

Referenced by mnItemMenuRunMemberSelection(), mnPsynergyMenuSelectMember(), mnStatusScreenRunEquipmentPage(), mnStatusScreenRunPsynergyPage() and mnStatusScreenShowMemberStatus().

Definition at line 979 of file menu_item.c.

mnItemMenuHideAllIcons

void mnItemMenuHideAllIcons(void)

Hides all the item icons.

References Sint32.

Referenced by mnItemMenuChooseCommand(), mnItemMenuClose(), mnItemMenuDrawEquipment(), mnItemMenuRunCommands(), mnPsynergyMenuDrawPreparedPsynergyIcons(), mnStatusScreenRunEquipmentPage() and mnStatusScreenRunPsynergyPage().

Definition at line 1030 of file menu_item.c.

mnItemMenuHidePageIcons

void mnItemMenuHidePageIcons(void)

Hides the item icons in the first column of the five-wide item grid.

References Sint32.

Referenced by mnItemMenuRunCommands().

Definition at line 1047 of file menu_item.c.

mnItemMenuClose

void mnItemMenuClose(void)

Closes the item menu: releases the party figures, hides the icons and the status panel's portrait (the state's cursor), and closes every window the menu opened.

References mnItemMenuHideAllIcons(), mnReleasePartyFigures(), mnWindowCloseIfOpen() and sySynch().

Referenced by mnDjinnMenuRun(), mnItemMenuRun(), mnPartyMemberChooserOpen(), mnPsynergyMenuRun() and mnStatusScreenRun().

Definition at line 1068 of file menu_item.c.

mnItemMenuSelectMember

Sint32 mnItemMenuSelectMember(Sint32 side)

Lets the player choose a party member in side (0 or 1), starting from the party member chosen last.

References gmUnitGetStub(), mnCursorSlide(), mnIconShow(), mnItemMenuCollectItems(), mnItemMenuRunMemberSelection(), mnWindowSpriteClearListStub(), Sint32 and sySynch().

Referenced by mnItemMenuRunCommands().

Definition at line 1094 of file menu_item.c.

mnItemMenuRunMemberSelection

Sint32 mnItemMenuRunMemberSelection(Uint16 *memberIds, Uint16 *items)

The item menu's party member row: Left and Right choose whose items to look at, showing their items and status, R held shows their equipment and stats instead, L and A sorts their items into the next of the four orders, and A chooses a party member who has items. Returns their id, or -1 for B.

References gmFlagGetStub(), gmUnitGetStub(), mnCursorPos(), mnItemMenuCollectItems(), mnItemMenuCountItems(), mnItemMenuRefreshMember(), mnItemMenuShowEquipment(), mnItemMenuSort(), mnSpawnIconEntries(), mnStatusPanelDraw(), mnTextDrawMessageAsTilesStub(), mnWindowSpriteCreateFromResourceStub(), mnWindowUpdateOrCreate(), PerData, PerPush, PerRepeat, Sint32, sySoundPlayStub() and sySynch().

Referenced by mnItemMenuSelectMember().

Definition at line 1125 of file menu_item.c.

mnItemMenuShowEquipment

void mnItemMenuShowEquipment(Sint32 memberId)

Shows the equipment view of party member memberId's items in the item window.

References mnHideEntryIcons(), mnItemMenuDrawEquipment(), mnWindowSpriteRedrawSavedRectStub() and Sint32.

Referenced by mnItemMenuRunMemberSelection().

Definition at line 1261 of file menu_item.c.

mnItemMenuSelectTarget

Sint32 mnItemMenuSelectTarget(Sint32 mode)

Chooses the party member to use or give the selected item (enum ITEM_TARGET_MODE) to.

References gmFlagClearStub(), gmFlagGetStub(), gmUnitGetStub(), mnCursorPos(), mnEquipmentMenuStopCompatibilityIndicators(), mnEquipmentMenuUpdateCompatibilityIndicators(), mnIconShow(), mnItemMenuCountItems(), mnItemMenuDrawEquipPreview(), mnItemMenuGetItemQuantity(), mnItemMenuIsStatRaisingItem(), mnItemMenuRefreshMember(), mnStatusPanelDraw(), mnTextDrawMessageAsTilesStub(), mnTextDrawNumberInWindowStub(), mnWindowClearInteriorTilesStub(), mnWindowDrawDividerLineStub(), mnWindowSetBounds(), mnWindowSpriteRedrawSavedRectStub(), PerPush, PerRepeat, Sint32, sySetEvent(), sySoundPlayStub() and sySynch().

Referenced by mnItemMenuRunCommands().

Definition at line 1273 of file menu_item.c.

mnEquipmentMenuUpdateCompatibilityIndicators

void mnEquipmentMenuUpdateCompatibilityIndicators(void)

Event while mnItemMenuSelectTarget chooses a party member to use or give the item to, and while the command grid's cursor is on Give: every 32 ticks, has each party figure nod (ANIM_NOD) if that party member can equip the item, or stand (ANIM_STAND) if not.

References fdSpriteStartAnimationStub(), gmItemCanUnitEquipStub() and TickCount.

Referenced by mnEquipmentMenuStopCompatibilityIndicators(), mnItemMenuChooseCommand() and mnItemMenuSelectTarget().

Definition at line 1446 of file menu_item.c.

mnEquipmentMenuStopCompatibilityIndicators

void mnEquipmentMenuStopCompatibilityIndicators(void)

Ends mnEquipmentMenuUpdateCompatibilityIndicators: puts every party figure back to ANIM_STAND and removes the event.

References fdSpriteStartAnimationStub(), mnEquipmentMenuUpdateCompatibilityIndicators() and syCloseEvent().

Referenced by mnItemMenuChooseCommand() and mnItemMenuSelectTarget().

Definition at line 1477 of file menu_item.c.

mnItemMenuIsStatRaisingItem

Bool mnItemMenuIsStatRaisingItem(Sint32 itemId)

Returns TRUE for the items that raise a stat for good (Apple, Hard Nut, Mint and Lucky Pepper), whose use shows the stats panel instead of HP and PP.

References Sint32.

Referenced by mnItemMenuRunCommands() and mnItemMenuSelectTarget().

Definition at line 1498 of file menu_item.c.

mnItemMenuDrawMessage

void mnItemMenuDrawMessage(Sint32 unused, Sint32 msg)

Clears the message window and writes message into it.

References mnTextDrawMessageAsTilesStub(), mnWindowSpriteRedrawSavedRectStub() and Sint32.

Referenced by mnItemMenuRunCommands() and mnPsynergyMenuRunSteps().

Definition at line 1511 of file menu_item.c.

mnHideEmptyEntryIcons

void mnHideEmptyEntryIcons(const Uint16 *items)

Hides the icon of each of the 32 list entries whose item is 0. Each of the 32 icon slots must hold a sprite (mnSpawnIconEntries).

References mnIconShow() and Sint32.

Referenced by mnItemMenuDrawIcons(), mnPartyMemberChooserChooseMember() and mnPsynergyMenuDrawPsynergyIcons().

Definition at line 1522 of file menu_item.c.

mnItemMenuCountItems

Sint32 mnItemMenuCountItems(Sint32 memberId)

Returns how many of party member memberId's 15 inventory slots hold an item.

References gmUnitGetStub() and Sint32.

Referenced by mnItemMenuBuildPagedList(), mnItemMenuRefreshMember(), mnItemMenuRunCommands(), mnItemMenuRunMemberSelection() and mnItemMenuSelectTarget().

Definition at line 1538 of file menu_item.c.

mnItemMenuGetItemQuantity

Sint32 mnItemMenuGetItemQuantity(Sint32 memberId, Sint32 itemId)

Returns how many of itemId the unit memberId holds: the quantity of its first stack, or 0. The Spanish and Italian editions add up every stack of it.

References gmUnitGetStub() and Sint32.

Referenced by mnItemMenuRunCommands(), mnItemMenuSelectGiveQuantity() and mnItemMenuSelectTarget().

Definition at line 1554 of file menu_item.c.

mnItemMenuCollectItems

Sint32 mnItemMenuCollectItems(UNIT *unit, Uint16 *items, Sint32 unused)

Copies the unit's items into the list items (32 entries), skipping empty slots and clearing the rest. Returns how many there are.

References Sint32.

Referenced by mnItemMenuRefreshMember(), mnItemMenuRunCommands(), mnItemMenuRunList(), mnItemMenuRunMemberSelection(), mnItemMenuSelectMember(), mnItemUse() and mnStatusScreenRunEquipmentPage().

Definition at line 1584 of file menu_item.c.

mnItemMenuDrawIcons

void mnItemMenuDrawIcons(Uint16 *inventoryEntries, Sint32 iconStyle)

Loads each listed item's icon into its item icon sprite, the first 15 entries of inventoryEntries, and hides the icons of empty entries. iconStyle 0 draws the list's icons (ICON_KIND_ITEM); any other iconStyle the equipment view's (ICON_KIND_EQUIPMENT_ITEM).

References mnHideEmptyEntryIcons(), mnSelectionIconLoadIntoSlotStub() and Sint32.

Referenced by mnItemMenuDrawEquipment(), mnItemMenuRefreshMember(), mnItemMenuRunCommands(), mnItemMenuRunList() and mnStatusScreenRunEquipmentPage().

Definition at line 1610 of file menu_item.c.

mnItemMenuRefreshMember

void mnItemMenuRefreshMember(Sint32 memberId, Sint32 mode)

Shows party member memberId's items in the item window, laid out for layout mode (see mnItemMenuPlaceIcons), or "no items" when there are none.

References gmUnitGetStub(), mnItemMenuCollectItems(), mnItemMenuCountItems(), mnItemMenuDrawIcons(), mnItemMenuPlaceIcons(), mnTextDrawMessageAsTilesStub(), mnWindowSpriteRedrawSavedRectStub() and Sint32.

Referenced by mnItemMenuRunCommands(), mnItemMenuRunMemberSelection() and mnItemMenuSelectTarget().

Definition at line 1644 of file menu_item.c.

mnItemMenuNoOperation

void mnItemMenuNoOperation(void)

Definition at line 1661 of file menu_item.c.

mnItemMenuDrawEquipPreview

void mnItemMenuDrawEquipPreview(Sint32 member, Sint32 slot, Sint32 mode, Sint32 target)

Shows in the status panel what the item in member's inventory slot would mean to member target: for a usable item, target's status; for equipment, target's stats with it equipped; for a Psynergy item, the Psynergy it teaches.

References gmInventoryAddItemStub(), gmItemGetDefinitionStub(), gmUnitGetStub(), mnInventoryMakeRoom(), mnStatusPanelDraw(), Sint32, syHeapAllocate(), syHeapRelease() and syWordsCopy().

Referenced by mnItemMenuChooseCommand(), mnItemMenuConfirmEquip(), mnItemMenuRunCommands(), mnItemMenuRunList() and mnItemMenuSelectTarget().

Definition at line 1668 of file menu_item.c.

mnInventoryMakeRoom

Sint32 mnInventoryMakeRoom(Sint32 memberId)

Makes room in memberId's inventory for a preview: if no slot is free, removes the whole stack in the first slot that is not equipped. Returns 1 when there is room, else 0.

References gmInventoryRemoveStub(), gmUnitGetStub() and Sint32.

Referenced by mnItemMenuDrawEquipPreview().

Definition at line 1792 of file menu_item.c.

mnItemMenuCommandCursorX

Sint32 mnItemMenuCommandCursorX(Sint32 column, Sint32 row)

Returns the x of the item command cursor on column and row of the command grid (three commands to a row), or 0 when column or row is outside 0 to 2.

References ItemMenuCommandColumnXTable and Sint32.

Referenced by mnItemMenuChooseCommand().

Definition at line 1841 of file menu_item.c.

mnItemMenuCommandCursorY

Sint32 mnItemMenuCommandCursorY(Sint32 column, Sint32 row)

Returns the y of the item command cursor: its top row, or the row below for any other row.

References Sint32.

Referenced by mnItemMenuChooseCommand().

Definition at line 1850 of file menu_item.c.

mnItemMenuChooseCommand

Sint32 mnItemMenuChooseCommand(void)

The item command grid: Use, Equip and Details on the top row, Give, Remove and Drop below. Returns the ITEM_MENU_COMMAND chosen, or -1 for B.

References gmFlagGetStub(), mnCursorPos(), mnCursorSlide(), mnEquipmentMenuStopCompatibilityIndicators(), mnEquipmentMenuUpdateCompatibilityIndicators(), mnItemMenuBuildCommands(), mnItemMenuCommandCursorX(), mnItemMenuCommandCursorY(), mnItemMenuDrawCommands(), mnItemMenuDrawEquipPreview(), mnItemMenuDrawItemHead(), mnItemMenuFitMessageWindowToItemChoices(), mnItemMenuHideAllIcons(), mnStatusPanelDraw(), mnWindowDrawDividerLineStub(), mnWindowSpriteRedrawSavedRectStub(), PerPush, PerRepeat, Sint32, sySetEvent(), sySoundPlayStub() and sySynch().

Referenced by mnItemMenuRunCommands().

Definition at line 1870 of file menu_item.c.

mnItemMenuBuildCommands

void mnItemMenuBuildCommands(Sint8 *commandStates)

Fills commandStates (indexed by ITEM_MENU_COMMAND) with ITEM_COMMAND_STATE_AVAILABLE or _DISABLED for the selected item: Use for items mnItemClassifyUseMode accepts and are not broken, and for field items, Equip for equipment the party member can wear and is not wearing, Remove for worn equipment that is not cursed, Give with someone to give to, Drop unless the item is indispensable, and neither for cursed equipment being worn.

References fdHasItemCueStub(), gmItemCanUnitEquipStub(), gmItemGetDefinitionStub() and mnItemClassifyUseMode().

Referenced by mnItemMenuChooseCommand().

Definition at line 2085 of file menu_item.c.

mnItemMenuDrawCommands

void mnItemMenuDrawCommands(const Sint8 *commandStates, WINDOW *window)

Writes the six command names into window, the disabled ones in grey.

References mnTextDrawMessageAsTilesStub(), mnTextSetColorStub() and Sint32.

Referenced by mnItemMenuChooseCommand().

Definition at line 2159 of file menu_item.c.

mnItemClassifyUseMode

Sint32 mnItemClassifyUseMode(Sint32 memberId, Sint32 inventoryEntry)

Says how memberId can use inventoryEntry from the item menu (enum ITEM_USE_MODE).

References fdHasItemCueStub(), gmAbilityGetDefinitionStub(), gmItemCanUnitEquipStub(), gmItemGetDefinitionStub() and Sint32.

Referenced by mnItemMenuBuildCommands() and mnItemMenuRunCommands().

Definition at line 2204 of file menu_item.c.

mnItemMenuTryBreak

void mnItemMenuTryBreak(void)

After the selected item is used: an item that may break (ITEM_USE_MAY_BREAK) breaks one time in eight, with the break sound and "It broke!" in the info window. Called only after a successful use on a chosen party member.

References gmInventoryBreakStub(), gmItemGetDefinitionStub(), mnItemMenuShowMessage(), mnWindowSpriteRedrawSavedRectStub(), syRandom() and sySoundPlayStub().

Referenced by mnItemMenuRunCommands().

Definition at line 2266 of file menu_item.c.

mnItemMenuOpenDetail

Sint32 mnItemMenuOpenDetail(Sint32 itemIndex)

Opens the details window (top left, 13 by 10 tiles) and describes the item in side itemIndex there. Returns 1.

References mnItemMenuDrawItemDetails(), mnPaletteLoadIconsIntoHighlight(), mnWindowUpdateOrCreate() and Sint32.

Definition at line 2289 of file menu_item.c.

mnItemMenuShowDetails

Sint32 mnItemMenuShowDetails(Sint32 inventoryEntry)

The item menu's Details screen: describes inventoryEntry in a window over the top half (13 tiles wide in Japanese) and waits for A or B. Up and Down step a page from 0 to 4 that nothing draws; returns that page, or -1 for B.

References gmFlagGetStub(), mnItemMenuDrawItemDetails(), mnPaletteLightenHighlight(), mnPaletteLoadIconsIntoHighlight(), mnPlacePartyFigures(), mnWindowCloseStub(), mnWindowCreateStub(), mnWindowDrawBorderStub(), mnWindowSpriteRedrawSavedRectStub(), PerPush, PerRepeat, Sint32, syCloseEvent(), sySetEvent() and sySynch().

Referenced by mnItemMenuRunCommands().

Definition at line 2307 of file menu_item.c.

mnItemMenuDrawItemDetails

void mnItemMenuDrawItemDetails(WINDOW *window, Sint32 inventoryEntry)

Writes the description of the inventoryEntry into window, one line a row: for equipment its Attack and Defense bonuses, then each of its effects (flat bonuses, rates as multipliers, elemental Power and Resist with the element's icon, and the effects that are only text), whether it is cursed or bestows Psynergy, whether it is used up or may break, and for a stack how many there are.

References gmItemGetDefinitionStub(), MenuPointString, MenuTimesString, mnItemMenuDrawStat(), mnMessageArgumentPushStub(), mnTextDrawMessageAsTilesStub(), mnTextDrawNumberInWindowStub(), mnTextDrawStringInWindowStub(), mnWindowSetTilemapEntryStub() and Sint32.

Referenced by dbIncreaseItemAndLevelSelectItem(), dbMenuTestSelectItem(), mnItemMenuOpenDetail() and mnItemMenuShowDetails().

Definition at line 2409 of file menu_item.c.

mnItemMenuDrawStat

void mnItemMenuDrawStat( Sint32 statChange, Sint32 unused, WINDOW *window, Sint32 x, Sint32 y)

Writes a signed stat change at (x, y) of window: the number, with a plus or minus sign just before its first digit.

References MenuMinusSignString, MenuPlusSignString, mnTextDrawNumberInWindowStub(), mnTextDrawStringInWindowStub() and Sint32.

Referenced by mnItemMenuDrawItemDetails().

Definition at line 2671 of file menu_item.c.

mnItemMenuPlaceItemWindowBelowItemQuestion

void mnItemMenuPlaceItemWindowBelowItemQuestion(void)

Moves the item window to row 5 of the right-hand side, below a question headed by the item.

References mnWindowSetBounds().

Referenced by mnItemMenuRunCommands().

Definition at line 2712 of file menu_item.c.

mnItemMenuPlaceItemWindowBelowQuestion

void mnItemMenuPlaceItemWindowBelowQuestion(void)

Moves the item window to row 3 of the right-hand side, below a one-line question.

References mnWindowSetBounds().

Referenced by mnItemMenuRunCommands().

Definition at line 2720 of file menu_item.c.

mnItemMenuFitMessageWindowToItemQuestion

void mnItemMenuFitMessageWindowToItemQuestion(void)

Makes the message window, along the top right, 5 rows tall: the item's name and a question below it.

References mnWindowSetBounds().

Referenced by mnItemMenuRunCommands().

Definition at line 2728 of file menu_item.c.

mnItemMenuFitMessageWindowToLongItemQuestion

void mnItemMenuFitMessageWindowToLongItemQuestion(void)

Makes the message window 6 rows tall, for the longer questions outside Japanese.

References mnWindowSetBounds().

Referenced by mnItemMenuRunCommands().

Definition at line 2736 of file menu_item.c.

mnItemMenuFitMessageWindowToItemChoices

void mnItemMenuFitMessageWindowToItemChoices(void)

Makes the message window 7 rows tall: the item's name above the command grid or the quantity dial.

References mnWindowSetBounds().

Referenced by mnItemMenuChooseCommand() and mnItemMenuSelectGiveQuantity().

Definition at line 2744 of file menu_item.c.

mnItemMenuFitMessageWindowToQuestion

void mnItemMenuFitMessageWindowToQuestion(void)

Makes the message window 3 rows tall, for a one-line question.

References mnWindowSetBounds().

Referenced by mnItemMenuRunCommands().

Definition at line 2751 of file menu_item.c.

mnItemMenuSelectGiveQuantity

Sint32 mnItemMenuSelectGiveQuantity(Sint32 baseQuantity, Sint32 quantityRange, Sint32 dropMode)

Asks how many of the selected item stack to give or drop: Left and Right choose a number from 1 to quantityRange (shown as baseQuantity + 1 up to baseQuantity + quantityRange on a dial of digit sprites), with the party member's remaining count and, when giving (dropMode 0), the receiver's new count beside their names.

References gmFlagGetStub(), gmUnitGetStub(), MenuQuantityTiles, mnCursorPos(), mnCursorSlide(), mnItemMenuFitMessageWindowToItemChoices(), mnItemMenuGetItemQuantity(), mnQuantityBarFillStub(), mnTextDrawMessageAsTilesStub(), mnTextDrawNumberInWindowStub(), mnTextDrawStringAtOffsetStub(), mnWindowSpriteClearListStub(), mnWindowSpriteCreateStub(), mnWindowSpriteRedrawSavedRectStub(), PerPush, PerRepeat, Sint32, syDMAXCopy(), syHeapSlotAllocateEWRAM(), syHeapSlotRelease(), sySoundPlayStub(), sySynch(), syVRAMCacheFindFreeEntry() and syVRAMCacheLoad().

Referenced by mnItemMenuRunCommands().

Definition at line 2762 of file menu_item.c.

mnItemMenuDrawItemHead

void mnItemMenuDrawItemHead(void)

Shows the selected item at the top of the message window: its icon, its party member's name and its name.

References gmUnitGetStub(), mnIconShow(), mnSelectionIconLoadIntoSlotStub(), mnTextDrawMessageAsTilesStub() and mnTextDrawStringAtOffsetStub().

Referenced by mnItemMenuChooseCommand() and mnItemMenuRunCommands().

Definition at line 2893 of file menu_item.c.

mnItemMenuConfirmDrop

Sint32 mnItemMenuConfirmDrop(Sint32 item)

Asks whether to drop item (an inventory entry): its name, the question, and Yes or No, No first. Returns 0 for Yes and 1 for No, B or Start.

References gmFlagGetStub(), gmItemGetDefinitionStub(), mnCursorPos(), mnCursorSlide(), mnTextDrawMessageAsTilesStub(), mnWindowCloseStub(), mnWindowCreateStub(), PerPush, PerRepeat, Sint32, sySoundPlayStub() and sySynch().

Referenced by mnItemMenuRunCommands().

Definition at line 2916 of file menu_item.c.

mnItemMenuConfirmEquip

Sint32 mnItemMenuConfirmEquip(Sint32 unused)

After giving or trading the selected item to the party member in side 1, offers to equip it there, showing the stats it would give.

References gmFlagGetStub(), gmInventoryEquipStub(), gmUnitCalculateStub(), gmUnitGetStub(), gmUnitRefreshPsynergyStub(), mnCursorPos(), mnCursorSlide(), mnItemMenuDrawEquipPreview(), mnTextDrawMessageAsTilesStub(), mnWindowClearInteriorTilesStub(), PerPush, PerRepeat, Sint32, syHeapAllocate(), syHeapRelease(), sySoundPlayStub(), sySynch() and syWordsCopy().

Referenced by mnItemMenuRunCommands().

Definition at line 2984 of file menu_item.c.

mnLoadStatArrows

void mnLoadStatArrows(void)

Loads the stat arrows (up and down) into two free VRAM blocks, kept in the menu state's resource slots.

References MenuArrowTiles, MenuSmallDownArrowTiles, Sint32, syVRAMCacheFindFreeEntry() and syVRAMCacheLoad().

Referenced by mnItemMenuRun().

Definition at line 3086 of file menu_item.c.

mnItemMenuBuildPagedList

Sint32 mnItemMenuBuildPagedList(PAGED_LIST *result, Sint32 index)

Fills result with the item list of the party member in side index: their unit, how many items they hold, and the page and row of the item chosen last for them (kept within the list), five items to a page. Returns 1.

References gmUnitGetStub(), mnItemMenuCountItems() and Sint32.

Referenced by mnItemMenuRunList().

Definition at line 3101 of file menu_item.c.

mnItemMenuShowSelectedRow

Sint32 mnItemMenuShowSelectedRow(WINDOW *window, void *memberState, PAGED_LIST *pageState)

Updates the item list for the row under the cursor: puts the selected item's plain name in the info window and highlights its row of the five. window and memberState are not used.

References mnWindowSetHighlightRect(), Sint32 and sySynch().

Referenced by mnItemMenuRunList().

Definition at line 3137 of file menu_item.c.

mnItemMenuDrawListPage

Sint32 mnItemMenuDrawListPage(WINDOW *window, Sint32 unused, const PAGED_LIST *pageState)

Draws one page of the item list into window: up to five item names with their icons, and the page numbers when there is more than one page.

References mnPagedListDrawPageNumbers(), mnSetPageIcons(), mnTextDrawMessageAsTilesStub(), mnWindowDrawDividerLineStub(), mnWindowSpriteRedrawSavedRectStub() and Sint32.

Referenced by mnItemMenuRunList().

Definition at line 3191 of file menu_item.c.

mnItemMenuItemNamePageReturnTrue

Sint32 mnItemMenuItemNamePageReturnTrue(void)

References Sint32.

Definition at line 3242 of file menu_item.c.

mnItemMenuItemNamePageNoOperation

void mnItemMenuItemNamePageNoOperation(void)

Definition at line 3247 of file menu_item.c.

mnItemMenuRunList

Sint32 mnItemMenuRunList(Sint32 sideIndex)

The item list of the party member in sideIndex (0: the holder, 1: the receiver of a trade), five items a page: Up and Down choose, Left and Right turn the page, L and R go to the previous or next party member with items (side 0 only), and A chooses. Returns the chosen inventory entry, or -1 for B.

References fdSpriteStartAnimationStub(), gmFlagGetStub(), gmItemCanUnitEquipStub(), gmUnitGetStub(), mnCursorPos(), mnIconShow(), mnItemMenuBuildPagedList(), mnItemMenuCollectItems(), mnItemMenuDrawEquipPreview(), mnItemMenuDrawIcons(), mnItemMenuDrawListPage(), mnItemMenuShowSelectedRow(), mnPagedListHandleInput(), mnTextDrawMessageAsTilesStub(), mnWindowClearInteriorTilesStub(), mnWindowUpdateOrCreate(), PerPush, PerRepeat, Sint32, state, sySoundPlayStub(), sySynch() and TickCount.

Referenced by mnItemMenuRunCommands().

Definition at line 3256 of file menu_item.c.

On this page

MacrosEnumerationsFunctionsDescriptionMacros in detailITEM_MODAL_SHORT_XITEM_MODAL_REMOVED_XITEM_CANNOT_TRADE_XITEM_TRADED_XITEM_TRADE_PROMPT_XITEM_COMMAND_TEXT_XITEM_QUANTITY_WINDOW_WIDTHITEM_GIVE_CURSOR_XITEM_GIVE_ASK_XITEM_GIVE_ASK_YITEM_DROP_QUESTION_XITEM_LIST_PAGE_ICONS_XITEM_LIST_NAME_XSAVED_WINDOW_TILE_BYTESITEM_COMMAND_COLUMNSITEM_COMMAND_ROWSITEM_COMMAND_CURSOR_YITEM_COMMAND_CURSOR_XITEM_COMMAND_STATE_DISABLEDITEM_COMMAND_STATE_AVAILABLETEXT_COLOR_DISABLEDEnumerations in detailITEM_MENU_STEPFunctions in detailmnItemMenuRunmnItemMenuRunCommandsmnItemMenuUsemnItemMenuInitmnSpawnIconEntriesmnItemMenuHideAllIconsmnItemMenuHidePageIconsmnItemMenuClosemnItemMenuSelectMembermnItemMenuRunMemberSelectionmnItemMenuShowEquipmentmnItemMenuSelectTargetmnEquipmentMenuUpdateCompatibilityIndicatorsmnEquipmentMenuStopCompatibilityIndicatorsmnItemMenuIsStatRaisingItemmnItemMenuDrawMessagemnHideEmptyEntryIconsmnItemMenuCountItemsmnItemMenuGetItemQuantitymnItemMenuCollectItemsmnItemMenuDrawIconsmnItemMenuRefreshMembermnItemMenuNoOperationmnItemMenuDrawEquipPreviewmnInventoryMakeRoommnItemMenuCommandCursorXmnItemMenuCommandCursorYmnItemMenuChooseCommandmnItemMenuBuildCommandsmnItemMenuDrawCommandsmnItemClassifyUseModemnItemMenuTryBreakmnItemMenuOpenDetailmnItemMenuShowDetailsmnItemMenuDrawItemDetailsmnItemMenuDrawStatmnItemMenuPlaceItemWindowBelowItemQuestionmnItemMenuPlaceItemWindowBelowQuestionmnItemMenuFitMessageWindowToItemQuestionmnItemMenuFitMessageWindowToLongItemQuestionmnItemMenuFitMessageWindowToItemChoicesmnItemMenuFitMessageWindowToQuestionmnItemMenuSelectGiveQuantitymnItemMenuDrawItemHeadmnItemMenuConfirmDropmnItemMenuConfirmEquipmnLoadStatArrowsmnItemMenuBuildPagedListmnItemMenuShowSelectedRowmnItemMenuDrawListPagemnItemMenuItemNamePageReturnTruemnItemMenuItemNamePageNoOperationmnItemMenuRunList