mirror of
https://github.com/thepigeongenerator/tetris_clone.git
synced 2025-12-17 14:05:45 +01:00
fix: a tetromino can't appear twice in a row, and rotation is no longer preserved
Tetrominos can now appear twice in a row, and rotation is no longer preserved for each shape. (if you rotated a specific shape 90°, now whenever you encounter this shape, it spawns with a 90° rotation, and so forth)
This commit is contained in:
@@ -114,8 +114,8 @@ void render_update(void) {
|
||||
if (font) draw_score_text();
|
||||
|
||||
render_level();
|
||||
draw_shape(gdat->pdat.nxt[gdat->pdat.idx], gdat->pdat.sel);
|
||||
draw_shape(gdat->pdat.nxt[gdat->pdat.idx + 1], (i8vec2){COLUMNS + 1, 3});
|
||||
draw_shape(gdat->pdat.cur, gdat->pdat.sel);
|
||||
draw_shape(gdat->pdat.nxt[gdat->pdat.idx], (i8vec2){COLUMNS + 1, 3});
|
||||
|
||||
SDL_RenderPresent(rend);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user