Files
tarrot/main/tarot_deck.h
2026-06-23 06:03:19 -07:00

45 lines
841 B
C

#pragma once
#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>
#ifdef __cplusplus
extern "C" {
#endif
#define TAROT_DECK_SIZE 78
typedef enum {
TAROT_ARCANA_MAJOR = 0,
TAROT_ARCANA_MINOR,
} tarot_arcana_t;
typedef enum {
TAROT_SUIT_NONE = 0,
TAROT_SUIT_WANDS,
TAROT_SUIT_CUPS,
TAROT_SUIT_SWORDS,
TAROT_SUIT_PENTACLES,
} tarot_suit_t;
typedef struct {
uint8_t id;
const char *name;
const char *image_filename;
tarot_arcana_t arcana;
tarot_suit_t suit;
const char *upright_meaning;
const char *reversed_meaning;
} tarot_card_t;
extern const tarot_card_t tarot_deck[TAROT_DECK_SIZE];
const tarot_card_t *tarot_deck_get_by_id(uint8_t id);
const char *tarot_arcana_name(tarot_arcana_t arcana);
const char *tarot_suit_name(tarot_suit_t suit);
#ifdef __cplusplus
}
#endif