Commit Graph

200 Commits

Author SHA1 Message Date
27cacb055c fix: S and Z shapes were inverted 2025-07-02 22:38:03 +02:00
b5b51ae555 fix: input dropping sometimes 2025-07-02 15:12:14 +02:00
97f7f05a5c refactor comments 2025-07-02 10:30:59 +02:00
00db0cda7e fix: double input issue 2025-07-01 12:04:30 +02:00
f124076037 code cleanup 2025-07-01 11:44:06 +02:00
9d7d82a9b6 fix: rotation feels rather funky. 2025-07-01 10:45:47 +02:00
43ecb1e0e6 (micro)optimise downwards movement 2025-06-30 11:00:06 +02:00
1ae6d936eb seperate rotation timeout 2025-06-30 10:59:28 +02:00
63f8260140 add input timeout and input keypresses 2025-06-27 13:01:28 +02:00
d42e5c25f4 (re)add placing sound effect 2025-06-27 12:40:48 +02:00
21aca01cba rework audio system to be able to call it from anywhere, rather than having to have access to the audio data. 2025-06-27 12:39:04 +02:00
c4905f2da3 fix: i8vec2 is 4 bytes wide, rather than 2. 2025-06-27 12:35:44 +02:00
7b3b09ebe7 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)
2025-06-27 12:30:11 +02:00
699bc7a547 add comments to pdat 2025-06-26 14:13:00 +02:00
dd8fc37494 re-implement shape dropping 2025-06-26 14:08:34 +02:00
d852eb2283 add capability of VI keybindings 2025-06-26 13:33:51 +02:00
378e5cfd22 fix: shuffle algorithm; was messing up the data 2025-06-26 13:23:34 +02:00
402ef330de optimise Y axis updating 2025-06-26 12:08:21 +02:00
f41f5d3a6e don't use vectorised addition in the parameter; it's not necessary 2025-06-26 11:50:07 +02:00
0f4c9411b0 write constants VX, VY, to make vector component selection more readable 2025-06-26 11:48:15 +02:00
390ca02172 fix: inverted rotation/movement 2025-06-26 11:27:58 +02:00
dba2e102ab fix: moving into collisions, rather than preventing them 2025-06-26 11:27:22 +02:00
7af2bb0050 fix: update roll caused SEGV, also optimised it using XOR 2025-06-26 11:26:22 +02:00
29b190e0f5 simplify movement logic a bit further 2025-06-26 11:09:01 +02:00
0a0e03a769 fix: not initialising TTF module 2025-06-26 11:04:55 +02:00
c1d7f71a02 make window freeing more manual 2025-06-26 11:02:14 +02:00
a94e2d147b fix: memory leak on exit 2025-06-26 10:55:02 +02:00
d7989c5918 fix: wasn't initialising the window properly 2025-06-26 10:54:52 +02:00
937ecedfe3 implement new code, and remove deprecated old code. Overal optimisation.
this code is currently broken, but this'll be fixed in a subsequent
commit
2025-06-25 16:58:58 +02:00
a202442853 write some TODO comments 2025-06-25 15:44:17 +02:00
94cfbdcaad write code for a timing 2025-06-25 15:41:58 +02:00
a7d5f1bb2a write code for input handling 2025-06-25 15:41:49 +02:00
046f7affaf write code for window handling 2025-06-25 15:41:44 +02:00
fc2924d128 add a type definition for SMID-style vectors 2025-06-25 15:40:52 +02:00
9fbc9e0f9a use common integer type in shapes.c/shapes.h, for decreasing namespace pollution 2025-06-25 15:40:52 +02:00
a50b39307a define type definitions for common integer types 2025-06-25 15:40:52 +02:00
6a1b4104cf rework audio handling, since it was flawed 2025-06-25 15:40:52 +02:00
b446a43738 use tabs over spaces 2025-06-25 15:40:52 +02:00
3b306288e9 rename "renderer" to "render" 2025-06-25 15:40:52 +02:00
7c20704990 rename window io 2025-06-25 15:39:23 +02:00
bf62a60710 remove broke option code 2025-06-18 15:43:38 +02:00
18243a23eb clean up code 2025-06-18 15:43:38 +02:00
8449c58ab5 rewrite string accumilation to use a dynamic array instead of many reallocations 2025-04-29 21:53:33 +02:00
d925462c4d add some default options for testing 2025-04-23 16:54:06 +02:00
37d3a8e77f improve error handling 2025-04-23 16:53:49 +02:00
df249f1c35 fix: checking incorrect memory adresses
also updated assertions and remove some in place of attributes
2025-04-23 16:53:15 +02:00
9f6f20f36c fix: invalid memory access due to dereferencing after indexing 2025-04-23 16:53:15 +02:00
f64db135a9 use loaded options for selecting the colour 2025-04-23 16:53:15 +02:00
7ed37afdc5 add some options and loading logic 2025-04-23 16:53:15 +02:00
aee02e3293 fix path initialization
prefixed a `/` character for those I forgot.
And gave `opts` the `cfg` extension, so windows can handle it more
easliy
2025-04-23 16:46:57 +02:00