|
Digimon World 3 decomp
The European version, SLES_039.36
|
CARDGAME's choices: the cards of a hand or a pile, the picks, the deck, the table views and the questions (card_choice.c, hand_pick.c, deck_choice.c, table_view.c and questions.c). More...
#include "cardgame/card_battle/types.h"#include "cardgame/card_battle/screen.h"#include "cardgame/card_battle/battle.h"Go to the source code of this file.
Data Structures | |
| struct | CardBattleStep |
| A step of CARDGAME_windowSteps: once its time is past, CARDGAME_openStepWindows opens windows. More... | |
| struct | CardMarker |
| A blinking marker that opens and closes by scaling (CARDGAME_createMarker): frame 0x47 of the TIM archive's sprite sheet. More... | |
| struct | CardDeckWindow |
| A deck's window (CARDGAME_createDeckWindow): its name and how many cards of each of the six colours it has. More... | |
Functions | |
| s32 | CARDGAME_getTableHeight (CardBattle *battle, CardScreen *screen) |
| The table's height: 8 per card of the longer row of slots (at least 3), and 14. | |
| s32 | CARDGAME_viewTable (CardBattle *battle, CardScreen *screen) |
| Lets the player look over the cards out on the table: the two players' rows and the row of the cards played (up and down change rows, left and right move along one, triangle leaves), each state set up by setUpViewState; 1 once it is over. | |
| void | CARDGAME_moveTableHighlight (CardBattle *battle, CardScreen *screen, s32 kind, s32 delta) |
| Moves the highlight of a row of cards (kind 0, 1 or 2) by delta. | |
| void | CARDGAME_setupCardChoice (CardBattle *battle, CardScreen *screen, s32 side, s32 kind) |
| Sets up CARDGAME_chooseCard's choice of one of a side's cards: kind 0 among its hand, 1 and 2 among its deck, 3 among its discards. | |
| void | CARDGAME_showCardInfo (CardBattle *battle, CardScreen *screen, s32 offset) |
| Fills the information windows with the card of sprite offset + effectStep.cursor (the highlighted one): its colour, name, picture or values, and kind. | |
| void | CARDGAME_addCardPoints (CardBattle *battle, CardScreen *screen, CardPile *pile, s32 arg3, s32 card) |
| Adds a card's points to pile's points of its colour (takes them when add is 0), on the panel. | |
| s16 | CARDGAME_getStepWindowPos (s32 a, s32 b, s32 c) |
| A position of CARDGAME_stepWindowPositions. | |
| s32 | CARDGAME_openStepWindows (CardBattle *battle, CardScreen *screen, s32 layout, s32 text, s32 time, s32 step) |
| Opens the windows of the step CARDGAME_windowSteps[step] once its time is past; the next step. | |
| void | CARDGAME_startQuestion (CardBattle *battle, CardScreen *screen, s32 value) |
| Opens the panels and asks message value; the European and Japanese versions start on the second choice when none of the player's hand can be played. | |
| s32 | CARDGAME_stepYesNo (CardBattle *battle, CardScreen *screen) |
| Runs the yes/no window that CARDGAME_startQuestion sets up: 1 for the first choice, 2 for the second, 0 until then. | |
| void | CARDGAME_clearCardInfo (CardBattle *battle, CardScreen *screen) |
| Empties the card information windows 1-4. | |
| void | CARDGAME_showTableCardInfo (CardBattle *battle, CardScreen *screen, s32 kind) |
| CARDGAME_showCardInfo for the highlighted card of a row (kind 0, 1 or 2, as CARDGAME_moveTableHighlight) | |
| void | CARDGAME_startHandPick (CardBattle *battle, CardScreen *screen, CardPile *pile) |
| Starts a pick from pile's hand: flags (effectStep.eligible) the cards that can be played, and opens the player's panel. | |
| void | CARDGAME_startPick (CardBattle *battle, CardScreen *screen, s32 all, s32 mode) |
| Starts a pick of the cards (all when all > 0) in mode (anim.next) | |
| void | CARDGAME_moveSelection (CardBattle *battle, CardScreen *screen, s32 count, s32 step) |
| Moves the selection by STEP among COUNT cards: the selected card is raised. | |
| void | CARDGAME_movePileSelection (CardBattle *battle, CardScreen *screen, CardPile *pile, s32 step) |
| Moves the selection by STEP among the cards of PILE's hand: the selected card is raised. | |
| void | CARDGAME_flagPlayableCards (CardBattle *battle, CardScreen *screen, CardPile *pile) |
| Flags (effectStep.eligible) the cards of pile's hand that can be played and aren't picked (effectStep.marked), and dims the others. | |
| s32 | CARDGAME_isHandPickDone (CardBattle *battle, CardScreen *screen, CardPile *pile) |
| Whether the pick is over: six cards picked (effectStep.count), or none left that can be played. | |
| s32 | CARDGAME_togglePick (CardBattle *battle, CardScreen *screen, CardPile *pile) |
| Picks or puts back the selected card of PILE's hand: 1 picked, 2 put back, 0 neither. | |
| void | CARDGAME_readChooseInput (CardBattle *battle, CardScreen *screen, CardPile *pile) |
| Reads the pad while a card of PILE's hand is being chosen: Left/Right move, Cross picks, Triangle cancels. | |
| void | CARDGAME_readPickInput (CardBattle *battle, CardScreen *screen, CardPile *pile) |
| Reads the pad while cards of PILE's hand are being picked: Left/Right move, Cross picks or puts back, Square and Circle end. | |
| void | CARDGAME_readCountInput (CardBattle *battle, CardScreen *screen, s32 count) |
| Reads the pad while one of COUNT cards is being chosen: Left/Right move, Triangle cancels. | |
| s32 | CARDGAME_stepPulseCard (CardBattle *battle, CardScreen *screen) |
| Scales the highlighted sprite up to 1.25 and back, 5 frames each; 1 once done. | |
| void | CARDGAME_startPanelsStep (CardBattle *battle, CardScreen *screen) |
| Opens the panels for a step. | |
| s32 | CARDGAME_stepMessage (CardBattle *battle, CardScreen *screen) |
| Waits for window 5 to open, then for Cross or Triangle to close it; 1 once it has closed. | |
| void | CARDGAME_startStepMessage (CardBattle *battle, CardScreen *screen, s32 index) |
| Shows CARDGAME_stepMessages[index]: its message and window 5. | |
| void | CARDGAME_switchCoinCard (CardBattle *battle, CardScreen *screen) |
| Moves the selection to the other one of the two cards that CARDGAME_startFirstPick lays out. | |
| void | CARDGAME_startFirstPick (CardBattle *battle, CardScreen *screen) |
| Who goes first: cards 0x57 and 0x58 face down, in a random order. | |
| s32 | CARDGAME_drawFirstPlayer (CardBattle *battle, CardScreen *screen) |
| The draw for who goes first: the two face-down cards open, the player picks one with left/right and cross and both turn over; 1 once it is over, with effectStep.choice 1 if the player won the draw. | |
| void | CARDGAME_startViewTable (CardBattle *battle, CardScreen *screen) |
| Starts CARDGAME_viewTable. | |
| void | CARDGAME_startPickTableCard (CardBattle *battle, CardScreen *screen, s32 cancelable) |
| Starts CARDGAME_pickTableCard, which triangle backs out of when cancelable (effectStep.vars[4]) | |
| s32 | CARDGAME_getPickTableHeight (CardBattle *battle, CardScreen *screen) |
| CARDGAME_getTableHeight, for CARDGAME_pickTableCard. | |
| void | CARDGAME_movePickHighlight (CardBattle *battle, CardScreen *screen, s32 kind, s32 delta) |
| CARDGAME_moveTableHighlight, for CARDGAME_pickTableCard. | |
| s32 | CARDGAME_pickTableCard (CardBattle *battle, CardScreen *screen) |
| Lets the player pick a card out on the table (effectStep.flags bit 0: in their own row, bit 1: in the opponent's): 2 once one is picked (its sprite in effectStep.choice), 1 if there was none or the player backed out; each state is set up by setUpPickState. | |
| void | CARDGAME_setupSideChoice (CardBattle *battle, CardScreen *screen, s32 side) |
| CARDGAME_setupCardChoice of side, kind 0. | |
| void | CARDGAME_moveHandHighlight (CardBattle *battle, CardScreen *screen, s32 delta) |
| Moves the highlight along the hand by delta, raising the highlighted card. | |
| void | CARDGAME_browseHand (CardBattle *battle, CardScreen *screen) |
| Moves the highlight along the hand with left and right; cross picks a playable card. | |
| s32 | CARDGAME_chooseCard (CardBattle *battle, CardScreen *screen, s32 mode) |
| Lets a player pick a card of a row (set up by CARDGAME_setupCardChoice): 2 once one is picked, 1 if the player backed out with triangle (mode 1), else 0. | |
| s32 | CARDGAME_pickComputerCards (CardBattle *battle, CardScreen *screen) |
| The computer marks (effectStep.marked) the cards of its hand it plays: up to six that can be played, but not its kind 5 ones, paying their points; 1. | |
| void | CARDGAME_pickComputerDeckCard (CardBattle *battle, CardScreen *screen) |
| The computer's pick from its deck: the first card flagged (effectStep.eligible) from its top up to drawEnd, or else the last one flagged. | |
| void | CARDGAME_startPileChoice (CardBattle *battle, CardScreen *screen, s32 flags) |
| Shows the card being played as sprite 15 and the panels with flags, and starts CARDGAME_stepPileChoice's choice. | |
| s32 | CARDGAME_stepChooseCards (CardBattle *battle, CardScreen *screen, CardPile *pile) |
| The steps CARDGAME_runEffectStep starts (CardBattle.effectStep.next) and runs (effectStep.id) | |
| s32 | CARDGAME_stepTally (CardBattle *battle, CardScreen *screen) |
| Turns the opponent's slot cards over, then counts the panels' ap and hp up to each side's pile apTotal and hpTotal; 1 when done. | |
| void | CARDGAME_pickBestPileCard (CardBattle *battle, CardScreen *screen, s32 arg2) |
| Sets effectStep.choice to the effectStep.eligible-marked card of the pile effectStep.vars[4] picks with the highest CardImage.rank, the weakest (the strongest when lowest != 0), or -1. | |
| void | CARDGAME_pickLowestPlayerCard (CardBattle *battle, CardScreen *screen) |
| Picks the player's card with the lowest CardImage.rank, the strongest. | |
| s32 | CARDGAME_stepPileChoice (CardBattle *battle, CardScreen *screen) |
| The steps of CARDGAME_startPileChoice: confirming is allowed when the pile the panel flags (effectStep.vars[4]) pick has cards; 1 then, 0 on leaving with triangle, -1 until then. | |
| void | CARDGAME_startPreviousCardChoice (CardBattle *battle, CardScreen *screen, s32 arg2) |
| Shows the last card played as sprite 15; with mode 0, or mode 1 and a colour 6 card before it, the card before it can be picked too. | |
| s32 | CARDGAME_stepPreviousCardChoice (CardBattle *battle, CardScreen *screen) |
| The steps of CARDGAME_startPreviousCardChoice: confirming takes the card before the last one played, if it can be taken; 1 then, 0 on leaving with triangle, -1 until then. | |
| void | CARDGAME_showTargetSlots (CardBattle *battle, CardScreen *screen, s32 side, s32 arg3) |
| Shows the card being played as sprite 15 and lets the slots out that its target picks (a side of owner's, both, or a card colour) be chosen: effectStep.marked marks them, effectStep.vars[4] is 1 if there are any. | |
| s32 | CARDGAME_stepTargetSlots (CardBattle *battle, CardScreen *screen) |
| The steps of CARDGAME_showTargetSlots: highlights the marked slots (effectStep.marked); confirming needs one (effectStep.vars[4]); 1 then, 0 on leaving with triangle, -1 until then. | |
| void | CARDGAME_drawMarker (CardMarker *marker) |
| Draws the deck marker at its size, cycling its palettes (or running through them once when fast) | |
| void | CARDGAME_updateMarker (CardMarker *marker) |
| The deck marker's task: opens by growing over 10 frames, stays until closed, then shrinks and is drawn every frame. | |
| void | CARDGAME_setMarkerPos (CardMarker *marker, s16 x, s16 y) |
| CardMarker.setPos: moves the marker to x, y. | |
| void | CARDGAME_setMarkerFast (CardMarker *marker) |
| CardMarker.setFast: runs its palettes once from the start (the deck was picked) | |
| void | CARDGAME_closeMarker (CardMarker *marker) |
| CardMarker.close: shrinks it over 5 frames. | |
| CardMarker * | CARDGAME_createMarker (s16 x, s16 y) |
| Creates the deck marker at x, y, which shows the selected deck window. | |
| void | CARDGAME_drawDeckWindow (CardDeckWindow *window) |
| Draws a deck window's frame and icon at its size, the icon running through its palettes once when it blinks. | |
| void | CARDGAME_updateDeckWindow (CardDeckWindow *window, TextWindow **texts) |
| A deck window's task: makes its name and colour counts, opens by widening over 12 frames, shows them while open, and closes by narrowing. | |
| void | CARDGAME_setDeckWindowBlink (CardDeckWindow *window) |
| CardDeckWindow.setBlink: blinks its icon (the deck was picked) | |
| void | CARDGAME_closeDeckWindow (CardDeckWindow *window) |
| CardDeckWindow.close: narrows it over 6 frames. | |
| CardDeckWindow * | CARDGAME_createDeckWindow (s32 deck, s32 x, s32 y) |
| Creates the window of deck deck at x, y, with how many cards of each colour it has. | |
Variables | |
| CardOffset | CARDGAME_deckCountOffsets [] |
| The functions and data the overlay's files share. | |
| s32 | CARDGAME_rowSpriteOffsets [] |
| the sprite offset of each row of CARDGAME_viewTable | |
| s32 | CARDGAME_rowSteps [] |
| the step of each row of CARDGAME_viewTable | |
| s16 | CARDGAME_savedPanelScales [2] |
| the panels' scale states, kept by CARDGAME_viewTable | |
| s32 | CARDGAME_selectionText |
| the message of CARDGAME_chooseCard's selection | |
| s16 | CARDGAME_stepWindowPositions [2][3][4][2] |
| CARDGAME_openStepWindows's window positions, by layout and window, then the same moved for SHIFT_PAL_SCREEN. | |
| u8 | CARDGAME_stepMessages [][2] |
| CARDGAME_startStepMessage's text for window 5 and what screen->openMessage shows, by message. | |
| CardBattleStep | CARDGAME_windowSteps [] |
| s32 | CARDGAME_coinCardPositions [][2] |
| the two cards' x, y (CARDGAME_startFirstPick) | |
| s32 | CARDGAME_promptText |
| the text of window 0 | |
CARDGAME's choices: the cards of a hand or a pile, the picks, the deck, the table views and the questions (card_choice.c, hand_pick.c, deck_choice.c, table_view.c and questions.c).
Definition in file choice.h.
| s32 CARDGAME_getTableHeight | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
The table's height: 8 per card of the longer row of slots (at least 3), and 14.
Definition at line 12 of file table_view.c.
Referenced by CARDGAME_getPickTableHeight(), and setUpViewState().
| s32 CARDGAME_viewTable | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Lets the player look over the cards out on the table: the two players' rows and the row of the cards played (up and down change rows, left and right move along one, triangle leaves), each state set up by setUpViewState; 1 once it is over.
Definition at line 284 of file table_view.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_moveTableHighlight | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | kind, | ||
| s32 | delta | ||
| ) |
Moves the highlight of a row of cards (kind 0, 1 or 2) by delta.
< SYSTEM06
Definition at line 27 of file table_view.c.
Referenced by browseOpponentRow(), browseOwnRow(), browsePlayedRow(), CARDGAME_movePickHighlight(), CARDGAME_viewTable(), pickInOpponentRow(), and pickInOwnRow().
| void CARDGAME_setupCardChoice | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | side, | ||
| s32 | kind | ||
| ) |
Sets up CARDGAME_chooseCard's choice of one of a side's cards: kind 0 among its hand, 1 and 2 among its deck, 3 among its discards.
Definition at line 8 of file card_choice.c.
Referenced by CARDGAME_setupSideChoice(), and startEffectStep().
| void CARDGAME_showCardInfo | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | offset | ||
| ) |
Fills the information windows with the card of sprite offset + effectStep.cursor (the highlighted one): its colour, name, picture or values, and kind.
Definition at line 246 of file questions.c.
Referenced by backToChoosing(), CARDGAME_chooseCard(), CARDGAME_pickTableCard(), CARDGAME_showTableCardInfo(), CARDGAME_stepChooseCards(), and CARDGAME_viewTable().
| void CARDGAME_addCardPoints | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile, | ||
| s32 | arg3, | ||
| s32 | card | ||
| ) |
Adds a card's points to pile's points of its colour (takes them when add is 0), on the panel.
Definition at line 123 of file hand_pick.c.
Referenced by CARDGAME_pickComputerCards(), and CARDGAME_togglePick().
A position of CARDGAME_stepWindowPositions.
Definition at line 6 of file questions.c.
Referenced by CARDGAME_openStepWindows().
| s32 CARDGAME_openStepWindows | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | layout, | ||
| s32 | text, | ||
| s32 | time, | ||
| s32 | step | ||
| ) |
Opens the windows of the step CARDGAME_windowSteps[step] once its time is past; the next step.
Definition at line 15 of file questions.c.
Referenced by CARDGAME_chooseCard(), CARDGAME_pickTableCard(), CARDGAME_stepChooseCards(), CARDGAME_stepPlayCard(), and CARDGAME_viewTable().
| void CARDGAME_startQuestion | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | value | ||
| ) |
Opens the panels and asks message value; the European and Japanese versions start on the second choice when none of the player's hand can be played.
Definition at line 44 of file questions.c.
Referenced by startEffectStep().
| s32 CARDGAME_stepYesNo | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Runs the yes/no window that CARDGAME_startQuestion sets up: 1 for the first choice, 2 for the second, 0 until then.
Definition at line 155 of file questions.c.
Referenced by answerYesNo().
| void CARDGAME_clearCardInfo | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Empties the card information windows 1-4.
Definition at line 236 of file questions.c.
Referenced by CARDGAME_setupCardChoice(), CARDGAME_showCardInfo(), CARDGAME_startHandPick(), CARDGAME_startPick(), setUpPickState(), setUpViewState(), and startTableRow().
| void CARDGAME_showTableCardInfo | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | kind | ||
| ) |
CARDGAME_showCardInfo for the highlighted card of a row (kind 0, 1 or 2, as CARDGAME_moveTableHighlight)
Definition at line 308 of file questions.c.
Referenced by browseOpponentRow(), browseOwnRow(), browsePlayedRow(), pickInOpponentRow(), and pickInOwnRow().
| void CARDGAME_startHandPick | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile | ||
| ) |
Starts a pick from pile's hand: flags (effectStep.eligible) the cards that can be played, and opens the player's panel.
Definition at line 10 of file hand_pick.c.
Referenced by startEffectStep().
| void CARDGAME_startPick | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | all, | ||
| s32 | mode | ||
| ) |
Starts a pick of the cards (all when all > 0) in mode (anim.next)
Definition at line 43 of file hand_pick.c.
Referenced by startEffectStep().
| void CARDGAME_moveSelection | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | count, | ||
| s32 | step | ||
| ) |
Moves the selection by STEP among COUNT cards: the selected card is raised.
< SYSTEM06
Definition at line 61 of file hand_pick.c.
Referenced by CARDGAME_readCountInput().
| void CARDGAME_movePileSelection | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile, | ||
| s32 | step | ||
| ) |
Moves the selection by STEP among the cards of PILE's hand: the selected card is raised.
< SYSTEM06
Definition at line 73 of file hand_pick.c.
Referenced by CARDGAME_readChooseInput(), and CARDGAME_readPickInput().
| void CARDGAME_flagPlayableCards | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile | ||
| ) |
Flags (effectStep.eligible) the cards of pile's hand that can be played and aren't picked (effectStep.marked), and dims the others.
Definition at line 86 of file hand_pick.c.
Referenced by CARDGAME_stepChooseCards().
| s32 CARDGAME_isHandPickDone | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile | ||
| ) |
Whether the pick is over: six cards picked (effectStep.count), or none left that can be played.
Definition at line 106 of file hand_pick.c.
Referenced by CARDGAME_stepChooseCards().
| s32 CARDGAME_togglePick | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile | ||
| ) |
Picks or puts back the selected card of PILE's hand: 1 picked, 2 put back, 0 neither.
Definition at line 139 of file hand_pick.c.
Referenced by CARDGAME_readPickInput().
| void CARDGAME_readChooseInput | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile | ||
| ) |
Reads the pad while a card of PILE's hand is being chosen: Left/Right move, Cross picks, Triangle cancels.
< SYSTEM01
Definition at line 162 of file hand_pick.c.
Referenced by CARDGAME_stepChooseCards().
| void CARDGAME_readPickInput | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile | ||
| ) |
Reads the pad while cards of PILE's hand are being picked: Left/Right move, Cross picks or puts back, Square and Circle end.
Definition at line 193 of file hand_pick.c.
Referenced by CARDGAME_stepChooseCards().
| void CARDGAME_readCountInput | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | count | ||
| ) |
Reads the pad while one of COUNT cards is being chosen: Left/Right move, Triangle cancels.
< SYSTEM01
Definition at line 220 of file hand_pick.c.
Referenced by CARDGAME_stepChooseCards().
| s32 CARDGAME_stepPulseCard | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Scales the highlighted sprite up to 1.25 and back, 5 frames each; 1 once done.
Definition at line 244 of file hand_pick.c.
Referenced by CARDGAME_chooseCard(), CARDGAME_drawFirstPlayer(), and CARDGAME_stepChooseCards().
| void CARDGAME_startPanelsStep | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Opens the panels for a step.
Definition at line 685 of file hand_pick.c.
Referenced by startEffectStep().
| s32 CARDGAME_stepMessage | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Waits for window 5 to open, then for Cross or Triangle to close it; 1 once it has closed.
Definition at line 817 of file hand_pick.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_startStepMessage | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | index | ||
| ) |
Shows CARDGAME_stepMessages[index]: its message and window 5.
Definition at line 808 of file hand_pick.c.
Referenced by startEffectStep().
| void CARDGAME_switchCoinCard | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Moves the selection to the other one of the two cards that CARDGAME_startFirstPick lays out.
< SYSTEM06
Definition at line 846 of file hand_pick.c.
Referenced by CARDGAME_drawFirstPlayer().
| void CARDGAME_startFirstPick | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Who goes first: cards 0x57 and 0x58 face down, in a random order.
Definition at line 858 of file hand_pick.c.
Referenced by startEffectStep().
| s32 CARDGAME_drawFirstPlayer | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
The draw for who goes first: the two face-down cards open, the player picks one with left/right and cross and both turn over; 1 once it is over, with effectStep.choice 1 if the player won the draw.
< SYSTEM07
< SYSTEM03
Definition at line 891 of file hand_pick.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_startViewTable | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Starts CARDGAME_viewTable.
Definition at line 6 of file table_view.c.
Referenced by startEffectStep().
| void CARDGAME_startPickTableCard | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | cancelable | ||
| ) |
Starts CARDGAME_pickTableCard, which triangle backs out of when cancelable (effectStep.vars[4])
Definition at line 356 of file table_view.c.
Referenced by startEffectStep().
| s32 CARDGAME_getPickTableHeight | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
CARDGAME_getTableHeight, for CARDGAME_pickTableCard.
Definition at line 362 of file table_view.c.
Referenced by setUpPickState().
| void CARDGAME_movePickHighlight | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | kind, | ||
| s32 | delta | ||
| ) |
CARDGAME_moveTableHighlight, for CARDGAME_pickTableCard.
Definition at line 367 of file table_view.c.
Referenced by CARDGAME_pickTableCard().
| s32 CARDGAME_pickTableCard | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Lets the player pick a card out on the table (effectStep.flags bit 0: in their own row, bit 1: in the opponent's): 2 once one is picked (its sprite in effectStep.choice), 1 if there was none or the player backed out; each state is set up by setUpPickState.
< SYSTEM01
Definition at line 535 of file table_view.c.
Referenced by answerTableCardPick(), and CARDGAME_runEffectStep().
| void CARDGAME_setupSideChoice | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | side | ||
| ) |
CARDGAME_setupCardChoice of side, kind 0.
Definition at line 51 of file card_choice.c.
Referenced by startEffectStep().
| void CARDGAME_moveHandHighlight | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | delta | ||
| ) |
Moves the highlight along the hand by delta, raising the highlighted card.
< SYSTEM06
Definition at line 56 of file card_choice.c.
Referenced by CARDGAME_browseHand().
| void CARDGAME_browseHand | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Moves the highlight along the hand with left and right; cross picks a playable card.
Definition at line 68 of file card_choice.c.
Referenced by CARDGAME_chooseCard().
| s32 CARDGAME_chooseCard | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | mode | ||
| ) |
Lets a player pick a card of a row (set up by CARDGAME_setupCardChoice): 2 once one is picked, 1 if the player backed out with triangle (mode 1), else 0.
< SYSTEM07
< SYSTEM01
Definition at line 122 of file card_choice.c.
Referenced by answerHandCardPick(), and CARDGAME_runEffectStep().
| s32 CARDGAME_pickComputerCards | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
The computer marks (effectStep.marked) the cards of its hand it plays: up to six that can be played, but not its kind 5 ones, paying their points; 1.
Definition at line 232 of file card_choice.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_pickComputerDeckCard | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
The computer's pick from its deck: the first card flagged (effectStep.eligible) from its top up to drawEnd, or else the last one flagged.
Definition at line 331 of file card_choice.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_startPileChoice | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | flags | ||
| ) |
Shows the card being played as sprite 15 and the panels with flags, and starts CARDGAME_stepPileChoice's choice.
Definition at line 374 of file card_choice.c.
Referenced by startEffectStep().
| s32 CARDGAME_stepChooseCards | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| CardPile * | pile | ||
| ) |
The steps CARDGAME_runEffectStep starts (CardBattle.effectStep.next) and runs (effectStep.id)
The steps CARDGAME_runEffectStep starts (CardBattle.effectStep.next) and runs (effectStep.id)
-1 while it runs, then 0 or 1
Definition at line 564 of file hand_pick.c.
Referenced by CARDGAME_runEffectStep().
| s32 CARDGAME_stepTally | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Turns the opponent's slot cards over, then counts the panels' ap and hp up to each side's pile apTotal and hpTotal; 1 when done.
< SYSTEM10: a number counts up or down
Definition at line 696 of file hand_pick.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_pickBestPileCard | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | arg2 | ||
| ) |
Sets effectStep.choice to the effectStep.eligible-marked card of the pile effectStep.vars[4] picks with the highest CardImage.rank, the weakest (the strongest when lowest != 0), or -1.
Definition at line 251 of file card_choice.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_pickLowestPlayerCard | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
Picks the player's card with the lowest CardImage.rank, the strongest.
Definition at line 354 of file card_choice.c.
Referenced by CARDGAME_runEffectStep().
| s32 CARDGAME_stepPileChoice | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
The steps of CARDGAME_startPileChoice: confirming is allowed when the pile the panel flags (effectStep.vars[4]) pick has cards; 1 then, 0 on leaving with triangle, -1 until then.
< SYSTEM07
< SYSTEM01
Definition at line 396 of file card_choice.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_startPreviousCardChoice | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | arg2 | ||
| ) |
Shows the last card played as sprite 15; with mode 0, or mode 1 and a colour 6 card before it, the card before it can be picked too.
Definition at line 462 of file card_choice.c.
Referenced by startEffectStep().
| s32 CARDGAME_stepPreviousCardChoice | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
The steps of CARDGAME_startPreviousCardChoice: confirming takes the card before the last one played, if it can be taken; 1 then, 0 on leaving with triangle, -1 until then.
< SYSTEM07
< SYSTEM01
Definition at line 509 of file card_choice.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_showTargetSlots | ( | CardBattle * | battle, |
| CardScreen * | screen, | ||
| s32 | side, | ||
| s32 | arg3 | ||
| ) |
Shows the card being played as sprite 15 and lets the slots out that its target picks (a side of owner's, both, or a card colour) be chosen: effectStep.marked marks them, effectStep.vars[4] is 1 if there are any.
Definition at line 553 of file card_choice.c.
Referenced by startEffectStep().
| s32 CARDGAME_stepTargetSlots | ( | CardBattle * | battle, |
| CardScreen * | screen | ||
| ) |
The steps of CARDGAME_showTargetSlots: highlights the marked slots (effectStep.marked); confirming needs one (effectStep.vars[4]); 1 then, 0 on leaving with triangle, -1 until then.
< SYSTEM07
< SYSTEM01
Definition at line 645 of file card_choice.c.
Referenced by CARDGAME_runEffectStep().
| void CARDGAME_drawMarker | ( | CardMarker * | marker | ) |
Draws the deck marker at its size, cycling its palettes (or running through them once when fast)
Definition at line 8 of file deck_choice.c.
Referenced by CARDGAME_updateMarker().
| void CARDGAME_updateMarker | ( | CardMarker * | marker | ) |
The deck marker's task: opens by growing over 10 frames, stays until closed, then shrinks and is drawn every frame.
Definition at line 34 of file deck_choice.c.
Referenced by CARDGAME_createMarker().
| void CARDGAME_setMarkerPos | ( | CardMarker * | marker, |
| s16 | x, | ||
| s16 | y | ||
| ) |
CardMarker.setPos: moves the marker to x, y.
Definition at line 77 of file deck_choice.c.
Referenced by CARDGAME_createMarker().
| void CARDGAME_setMarkerFast | ( | CardMarker * | marker | ) |
CardMarker.setFast: runs its palettes once from the start (the deck was picked)
Definition at line 84 of file deck_choice.c.
Referenced by CARDGAME_createMarker().
| void CARDGAME_closeMarker | ( | CardMarker * | marker | ) |
CardMarker.close: shrinks it over 5 frames.
Definition at line 90 of file deck_choice.c.
Referenced by CARDGAME_createMarker().
| CardMarker * CARDGAME_createMarker | ( | s16 | x, |
| s16 | y | ||
| ) |
Creates the deck marker at x, y, which shows the selected deck window.
Definition at line 98 of file deck_choice.c.
Referenced by CARDGAME_chooseDeck().
| void CARDGAME_drawDeckWindow | ( | CardDeckWindow * | window | ) |
Draws a deck window's frame and icon at its size, the icon running through its palettes once when it blinks.
Definition at line 112 of file deck_choice.c.
Referenced by CARDGAME_updateDeckWindow().
| void CARDGAME_updateDeckWindow | ( | CardDeckWindow * | window, |
| TextWindow ** | texts | ||
| ) |
A deck window's task: makes its name and colour counts, opens by widening over 12 frames, shows them while open, and closes by narrowing.
Definition at line 144 of file deck_choice.c.
Referenced by CARDGAME_createDeckWindow().
| void CARDGAME_setDeckWindowBlink | ( | CardDeckWindow * | window | ) |
CardDeckWindow.setBlink: blinks its icon (the deck was picked)
Definition at line 211 of file deck_choice.c.
Referenced by CARDGAME_createDeckWindow().
| void CARDGAME_closeDeckWindow | ( | CardDeckWindow * | window | ) |
CardDeckWindow.close: narrows it over 6 frames.
Definition at line 217 of file deck_choice.c.
Referenced by CARDGAME_createDeckWindow().
| CardDeckWindow * CARDGAME_createDeckWindow | ( | s32 | deck, |
| s32 | x, | ||
| s32 | y | ||
| ) |
Creates the window of deck deck at x, y, with how many cards of each colour it has.
Definition at line 226 of file deck_choice.c.
Referenced by CARDGAME_chooseDeck(), and openDeckWindow().
|
extern |
The functions and data the overlay's files share.
The functions and data the overlay's files share.
Definition at line 10 of file cardgame_3.c.
Referenced by CARDGAME_updateDeckWindow().
|
extern |
the sprite offset of each row of CARDGAME_viewTable
Definition at line 18 of file cardgame_2.c.
Referenced by CARDGAME_pickTableCard(), and CARDGAME_viewTable().
|
extern |
the step of each row of CARDGAME_viewTable
Definition at line 27 of file cardgame_2.c.
Referenced by CARDGAME_viewTable().
|
extern |
the panels' scale states, kept by CARDGAME_viewTable
Definition at line 180 of file cardgame_3.c.
Referenced by CARDGAME_viewTable(), and setUpViewState().
|
extern |
the message of CARDGAME_chooseCard's selection
Definition at line 181 of file cardgame_3.c.
Referenced by CARDGAME_chooseCard().
|
extern |
CARDGAME_openStepWindows's window positions, by layout and window, then the same moved for SHIFT_PAL_SCREEN.
CARDGAME_openStepWindows's window positions, by layout and window, then the same moved for SHIFT_PAL_SCREEN.
Definition at line 6 of file cardgame_2.c.
Referenced by CARDGAME_getStepWindowPos().
|
extern |
CARDGAME_startStepMessage's text for window 5 and what screen->openMessage shows, by message.
Definition at line 22 of file cardgame_2.c.
Referenced by CARDGAME_startStepMessage().
|
extern |
Definition at line 21 of file cardgame_2.c.
Referenced by CARDGAME_openStepWindows().
|
extern |
the two cards' x, y (CARDGAME_startFirstPick)
Definition at line 26 of file cardgame_2.c.
Referenced by CARDGAME_switchCoinCard().
|
extern |
the text of window 0
Definition at line 179 of file cardgame_3.c.
Referenced by backToChoosing(), CARDGAME_stepChooseCards(), hideHandForMenu(), showHandAfterMenu(), and startChooseState().