polyadvent

A game engine from scratch in C
git clone git://jb55.com/polyadvent
Log | Files | Refs | README

commit 21df97e0cbc1d9333d7291000fe11c78047794e3
parent a408cf280e6a2dec7d30fd901c5addee1329b804
Author: William Casarin <jb55@jb55.com>
Date:   Thu, 25 Oct 2018 15:18:52 -0700

more warning messages

Diffstat:
Msrc/game.c | 2+-
Msrc/ply.c | 4++++
2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/src/game.c b/src/game.c @@ -65,7 +65,7 @@ void game_init(struct game *game) { node_init(&terrain->entity.node); // player init - ok = load_model(&player->model, "palm-tree"); + ok = load_model(&player->model, "ship"); assert(ok); player->model.program = res->program.handle; player->node.label = "player"; diff --git a/src/ply.c b/src/ply.c @@ -60,6 +60,8 @@ static inline int parse_vertex(const char **cursor, float *v, float *n, u8 *c) { &st[0], &st[1], &c[0], &c[1], &c[2]); + + return matched == 11; } @@ -142,6 +144,7 @@ int parse_ply(const char *filename, struct geometry *geom) { case PLY_VERTICES: res = parse_vertex(&p, vert, norm, color); if (!res) { + printf("failed parsing verts\n"); done = 1; break; } @@ -167,6 +170,7 @@ int parse_ply(const char *filename, struct geometry *geom) { case PLY_INDICES: res = parse_indices(&p, inds); if (!res) { + printf("failed parsing indices\n"); done = 1; break; }