Compiles again

This commit is contained in:
2026-06-18 10:17:53 -05:00
parent 857c6b3d47
commit 9810fd51ab
4 changed files with 13 additions and 4 deletions
+2
View File
@@ -11,6 +11,8 @@
#define ENTITY_ANIM_TURN_DURATION 0.06f
#define ENTITY_ANIM_WALK_DURATION 0.1f
typedef struct entity_s entity_t;
typedef enum {
ENTITY_ANIM_IDLE,
ENTITY_ANIM_TURN,
+2 -2
View File
@@ -30,7 +30,7 @@ void entityDirGetRelative(
switch(from) {
case ENTITY_DIR_NORTH:
*outX = 0;
*outY = -1;
*outY = 1;
break;
case ENTITY_DIR_EAST:
@@ -40,7 +40,7 @@ void entityDirGetRelative(
case ENTITY_DIR_SOUTH:
*outX = 0;
*outY = 1;
*outY = -1;
break;
case ENTITY_DIR_WEST:
+7
View File
@@ -8,6 +8,9 @@
#pragma once
#include "dusk.h"
#define TILE_POS_MIN -128
#define TILE_POS_MAX 127
#define CHUNK_WIDTH 16
#define CHUNK_HEIGHT CHUNK_WIDTH
#define CHUNK_DEPTH 8
@@ -39,6 +42,10 @@ typedef struct chunkpos_t {
chunkunit_t x, y, z;
} chunkpos_t;
typedef struct tilepos_s {
tileunit_t x, y, z;
} tilepos_t;
/**
* Compares two world positions for equality.
*
+2 -2
View File
@@ -62,7 +62,7 @@ errorret_t sceneOverworldRender(scenedata_t *sceneData) {
float_t worldH = (float)SCREEN.height / pixelsPerUnit;
float_t z = (worldH * 0.5f) / tanf(fov * 0.5f);
worldpos_t worldPos = rpgCameraGetPosition();
float_t offset = 16.0f;
float_t offset = -16.0f;
vec3 worldPosVec = {
worldPos.x,
@@ -78,7 +78,7 @@ errorret_t sceneOverworldRender(scenedata_t *sceneData) {
worldPosVec[2] + z
},
worldPosVec,
(vec3){ 0, -1, 0 }, // up
(vec3){ 0, 1, 0 }, // up
eye
);
errorChain(shaderSetMatrix(&SHADER_UNLIT, SHADER_UNLIT_VIEW, eye));