diff --git a/app/main.c b/app/main.c index a3c7811..f562ccf 100644 --- a/app/main.c +++ b/app/main.c @@ -34,6 +34,7 @@ int main(int argc, char *argv[]) return 1; } + // Set up SDL window int err = SDL_Init(SDL_INIT_VIDEO); assert(0 == err); window = SDL_CreateWindow( @@ -43,6 +44,7 @@ int main(int argc, char *argv[]) renderer = SDL_CreateRenderer(window, -1, 0); assert(NULL != renderer); + // Find chunk nodes in map XML xmlDocPtr doc; xmlNodePtr node; assert(strlen(argv[1]) + strlen(MAP_ASSET) < MAX_PATH_LEN); @@ -63,6 +65,7 @@ int main(int argc, char *argv[]) node = node->next; assert(NULL != node); + // Iterate through chunks and populate map array. xmlNodePtr chunk_contents; for (node = node->xmlChildrenNode; NULL != node; node = node->next) { if (0 != xmlStrcmp(node->name, (const xmlChar *)"chunk"))