This is the doxygen documentation for gtkboard.
.#include <stdio.h>#include <string.h>#include <assert.h>#include <stdlib.h>#include <math.h>#include <gdk/gdkkeysyms.h>#include "game.h"#include "../pixmaps/memory.xpm"Go to the source code of this file.
Data Structures | |
| struct | Memory_state |
Defines | |
| #define | MEMORY_CELL_SIZE 48 |
| #define | MEMORY_NUM_PIECES 72 |
| #define | MEMORY_BOARD_WID 9 |
| #define | MEMORY_BOARD_HEIT 8 |
| #define | MEMORY_EMPTY 0 |
| #define | MEMORY_ISOPEN(x) ((x)>MEMORY_NUM_PIECES/2) |
| #define | MEMORY_FLIP(x) |
Functions | |
| void | memory_init () |
| int | memory_getmove (Pos *, int, int, GtkboardEventType, Player, byte **, int **) |
| int | memory_animate (Pos *pos, byte **movp) |
| void | memory_set_init_pos (Pos *pos) |
| void* | memory_newstate (Pos *, byte *) |
| ResultType | memory_who_won (Pos *, Player, char **) |
| void | memory_free () |
Variables | |
| char** | memory_pixmaps [] |
| char | memory_colors [9] = {220, 220, 180, 220, 220, 180, 0, 0, 0} |
| int* | memory_init_pos = NULL |
| Game | Memory |
| Memory_state | state = {0, 0} |
| int | waiting = 0 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Value: ((x)>MEMORY_NUM_PIECES/2?\
(x)-MEMORY_NUM_PIECES/2:(x)+MEMORY_NUM_PIECES/2)Definition at line 38 of file memory.c. Referenced by memory_animate(). |
|
|
Definition at line 37 of file memory.c. Referenced by memory_animate(), and memory_getmove(). |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Initial value: { MEMORY_CELL_SIZE, MEMORY_BOARD_WID, MEMORY_BOARD_HEIT,
MEMORY_NUM_PIECES, memory_colors, NULL, memory_pixmaps,
"Memory", memory_init} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|