Data structures and functions relative to the behaviour and graphics of Blinds. More...
#include "sprite.h"Go to the source code of this file.
Data Structures | |
| struct | Blind |
| Data structure containing data about a BlindType. More... | |
Macros | |
| #define | MAX_ANTE 8 |
Enumerations | |
| enum | BlindTokens { SMALL_BLIND , BIG_BLIND , BOSS_BLIND , NUM_BLINDS_PER_ANTE } |
| The sprites that display the blinds when in "GAME_BLIND_SELECT" state. There are only 3 blinds per Ante, so we don't need more sprites than that. More... | |
| enum | BlindTokenLayers { PLAYING_BLIND_TOKEN_LAYER , ROUND_END_BLIND_TOKEN_LAYER , SMALL_BLIND_TOKEN_LAYER , BIG_BLIND_TOKEN_LAYER , BOSS_BLIND_TOKEN_LAYER } |
Sprite IDs of the various Blind Tokens used in the game, expressed as an offset relative to BLIND_BASE_LAYER More... | |
| enum | BlindColorIndex { BLIND_TEXT_COLOR_INDEX = 1 , BLIND_SHADOW_COLOR_INDEX , BLIND_HIGHLIGHT_COLOR_INDEX , BLIND_MAIN_COLOR_INDEX , BLIND_BACKGROUND_MAIN_COLOR_INDEX , BLIND_BACKGROUND_SECONDARY_COLOR_INDEX , BLIND_BACKGROUND_SHADOW_COLOR_INDEX } |
| Indices of the Blind sprites' colors as encoded in the files' palettes with Aseprite. More... | |
| enum | BlindType { BLIND_TYPE_SMALL , BLIND_TYPE_BIG , BLIND_TYPE_BOSS , BLIND_TYPE_HOOK = BLIND_TYPE_BOSS , BLIND_TYPE_OX , BLIND_TYPE_HOUSE , BLIND_TYPE_WALL , BLIND_TYPE_WHEEL , BLIND_TYPE_ARM , BLIND_TYPE_CLUB , BLIND_TYPE_FISH , BLIND_TYPE_PSYCHIC , BLIND_TYPE_GOAD , BLIND_TYPE_WATER , BLIND_TYPE_WINDOW , BLIND_TYPE_MANACLE , BLIND_TYPE_EYE , BLIND_TYPE_MOUTH , BLIND_TYPE_PLANT , BLIND_TYPE_SERPENT , BLIND_TYPE_PILLAR , BLIND_TYPE_NEEDLE , BLIND_TYPE_HEAD , BLIND_TYPE_TOOTH , BLIND_TYPE_FLINT , BLIND_TYPE_MARK , BLIND_TYPE_SHOWDOWN , BLIND_TYPE_ACORN = BLIND_TYPE_SHOWDOWN , BLIND_TYPE_LEAF , BLIND_TYPE_VESSEL , BLIND_TYPE_HEART , BLIND_TYPE_BELL , BLIND_TYPE_MAX } |
| All Blind types in the game are listed here. More... | |
| enum | BlindState { BLIND_STATE_CURRENT , BLIND_STATE_UPCOMING , BLIND_STATE_DEFEATED , BLIND_STATE_SKIPPED , BLIND_STATE_MAX } |
| All the possible states an Ante's Blinds can be in when viewed in the "Blind Select" screen. More... | |
Functions | |
| void | blind_init () |
| u32 | blind_get_requirement (enum BlindType type, int ante) |
| Get the score required to beat a certain blind (either the Small, Big, or any Boss/Showdown blind) at a certain Ante. | |
| int | blind_get_reward (enum BlindType type) |
| Get the amount of money gained from beating a certain Blind. | |
| u16 | blind_get_color (enum BlindType type, enum BlindColorIndex index) |
| Get the color associated with a given Blind. | |
| enum BlindType | roll_blind_type (bool showdown) |
| Choose a random Blind among the ones that haven't been beaten yet. | |
| void | init_unbeaten_blinds_lists (void) |
| Initialize Boss and Showdown Blinds lists to roll from. | |
| void | set_blind_beaten (enum BlindType type) |
| Remove the given Blind from the corresponding List so that we don't roll it again in the future. | |
| void | apply_blind_colors (enum BlindType type) |
| Copy the palette associated with the given Blind and copy it in the right spot in the palette memory. | |
| void | apply_blind_tiles (enum BlindType type, enum BlindTokenLayers layer) |
| Change the tiles of the BlindToken Sprite at a given layer to that of the given BlindType. | |
| Sprite * | blind_token_new (enum BlindType type, int x, int y, enum BlindTokenLayers sprite_index) |
| Create a new BlindToken sprite. | |
Data structures and functions relative to the behaviour and graphics of Blinds.
Definition in file blind.h.
| enum BlindColorIndex |
| enum BlindState |
| enum BlindTokenLayers |
| enum BlindTokens |
| enum BlindType |
| void apply_blind_colors | ( | enum BlindType | type | ) |
| void apply_blind_tiles | ( | enum BlindType | type, |
| enum BlindTokenLayers | layer | ||
| ) |
| u16 blind_get_color | ( | enum BlindType | type, |
| enum BlindColorIndex | index | ||
| ) |
| u32 blind_get_requirement | ( | enum BlindType | type, |
| int | ante | ||
| ) |
Get the score required to beat a certain blind (either the Small, Big, or any Boss/Showdown blind) at a certain Ante.
| type | the BlindType value of the blind we need the score requirement of |
| ante | the Ante at which the blind type is encountered |
| int blind_get_reward | ( | enum BlindType | type | ) |
| Sprite * blind_token_new | ( | enum BlindType | type, |
| int | x, | ||
| int | y, | ||
| enum BlindTokenLayers | sprite_index | ||
| ) |
Create a new BlindToken sprite.
| type | of the Blind the token needs to represent |
| x | initial position of the new Sprite on the horizontal axis |
| y | initial position of the new Sprite on the vertical axis |
| sprite_index | layer of the new Sprite |
| void init_unbeaten_blinds_lists | ( | void | ) |
| enum BlindType roll_blind_type | ( | bool | showdown | ) |