Brick Game v1.0
Implementation of the game Tetris in the C programming language with a terminal user interface.
Loading...
Searching...
No Matches
field.h
Go to the documentation of this file.
1
3
4#ifndef BRICK_GAME_V1_0_BRICK_GAME_TETRIS_FIELD_H_
5#define BRICK_GAME_V1_0_BRICK_GAME_TETRIS_FIELD_H_
6
7#include <stdbool.h>
8
9#include "piece.h"
10
12#define PLAYFIELD_ROWS 20
14#define PLAYFIELD_COLS 10
15
17typedef struct {
22} PlayField;
23
27bool field_line_filled(const PlayField *field, int index);
28
32bool piece_collides_with_playfield(const PlayField *field, PlayedPiece piece);
33
37PlayField playfield_merge_piece(const PlayField *field, PlayedPiece piece);
38
39#endif // BRICK_GAME_V1_0_BRICK_GAME_TETRIS_FIELD_H_
#define PLAYFIELD_COLS
Number of columns in the PlayField.
Definition field.h:14
#define PLAYFIELD_ROWS
Number of rows in the PlayField.
Definition field.h:12
Defines pieces and operations on them.
State of the playfield.
Definition field.h:17
State of the currently played piece.
Definition piece.h:34