This commit is contained in:
2025-04-30 19:01:44 +02:00
parent 451e80f750
commit 429627c095
10 changed files with 100 additions and 73 deletions

10
main.c
View File

@@ -6,6 +6,7 @@
#include "tiles/tile.h"
#include "tiles/belt.h"
#include "items/item.h"
#include "stdlib.h"
#include "player/player.h"
//Screen dimension constants
@@ -42,6 +43,9 @@ void msleep(unsigned int milliseconds) {
int init() {
//Initialize SDL
srand(0);
SDL_SetHint(SDL_HINT_RENDER_SCALE_QUALITY, NULL);
SDL_SetHint(SDL_HINT_VIDEO_HIGHDPI_DISABLED, "1");
SDL_SetHint(SDL_HINT_RENDER_DRIVER, "opengl");
@@ -181,9 +185,9 @@ int main(__attribute__((unused)) int argc, __attribute__((unused)) char *args[])
}
uint8_t type = 0;
for (int x = 149; x < 152; x++) {
for(int y = 87; y < 90; y++) {
putItem(x, y, type++);
for (int x = 142; x < 154; x+=3) {
for(int y = 80; y < 94; y+=3) {
putItem(x, y, type++ % ITEMREGISTRY_SIZE, 0, 0);
}
}