diff --git a/build/assets/include/js.h b/build/assets/include/js.h index cbf9900..df40458 100644 --- a/build/assets/include/js.h +++ b/build/assets/include/js.h @@ -4,5 +4,3 @@ #define EXPORT(name) __attribute__((export_name(#name))) IMPORT(log) int console_log(const char* format, ...); - -EXPORT(__srand) void srand(long long seed); diff --git a/src/games/life/life.c b/src/games/life/life.c index 993855f..efb6097 100644 --- a/src/games/life/life.c +++ b/src/games/life/life.c @@ -1,3 +1,4 @@ +#include #include #include #include @@ -16,7 +17,7 @@ EXPORT(step) void step(void) { for (int x = 0; x < WIDTH; x++) { int count = count_neighbours(x, y); uint8_t current_cell = field[x + y * WIDTH]; - int next_cell = current_cell; + uint8_t next_cell = current_cell; if (current_cell && count < 2) { next_cell = 0; } else if (current_cell && count > 3) {