mirror of
https://codeberg.org/hkzlab/TK2048.git
synced 2025-12-25 17:52:27 +11:00
Basic game logic
This commit is contained in:
parent
3d38da8915
commit
044c1cf184
1 changed files with 2 additions and 4 deletions
|
|
@ -21,9 +21,7 @@ uint8_t *get_front_grid(void) {
|
|||
return front_grid;
|
||||
}
|
||||
|
||||
uint8_t *step_game(step_direction dir) {
|
||||
// TODO: Update the grid state calculating the new state in the back grid
|
||||
|
||||
uint8_t *step_game(step_direction dir) {
|
||||
uint8_t start_offset;
|
||||
int8_t column_step;
|
||||
int8_t row_step;
|
||||
|
|
@ -37,7 +35,7 @@ uint8_t *step_game(step_direction dir) {
|
|||
|
||||
switch(dir) {
|
||||
case UP:
|
||||
start_offset = GRID_SIDE;
|
||||
start_offset = GRID_SIDE - 1;
|
||||
column_step = GRID_SIDE;
|
||||
row_step = -1;
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue