Add some block comments
This commit is contained in:
parent
eaf8df0fb1
commit
4151ca5717
@ -34,6 +34,7 @@ int main(int argc, char *argv[])
|
|||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Set up SDL window
|
||||||
int err = SDL_Init(SDL_INIT_VIDEO);
|
int err = SDL_Init(SDL_INIT_VIDEO);
|
||||||
assert(0 == err);
|
assert(0 == err);
|
||||||
window = SDL_CreateWindow(
|
window = SDL_CreateWindow(
|
||||||
@ -43,6 +44,7 @@ int main(int argc, char *argv[])
|
|||||||
renderer = SDL_CreateRenderer(window, -1, 0);
|
renderer = SDL_CreateRenderer(window, -1, 0);
|
||||||
assert(NULL != renderer);
|
assert(NULL != renderer);
|
||||||
|
|
||||||
|
// Find chunk nodes in map XML
|
||||||
xmlDocPtr doc;
|
xmlDocPtr doc;
|
||||||
xmlNodePtr node;
|
xmlNodePtr node;
|
||||||
assert(strlen(argv[1]) + strlen(MAP_ASSET) < MAX_PATH_LEN);
|
assert(strlen(argv[1]) + strlen(MAP_ASSET) < MAX_PATH_LEN);
|
||||||
@ -63,6 +65,7 @@ int main(int argc, char *argv[])
|
|||||||
node = node->next;
|
node = node->next;
|
||||||
assert(NULL != node);
|
assert(NULL != node);
|
||||||
|
|
||||||
|
// Iterate through chunks and populate map array.
|
||||||
xmlNodePtr chunk_contents;
|
xmlNodePtr chunk_contents;
|
||||||
for (node = node->xmlChildrenNode; NULL != node; node = node->next) {
|
for (node = node->xmlChildrenNode; NULL != node; node = node->next) {
|
||||||
if (0 != xmlStrcmp(node->name, (const xmlChar *)"chunk"))
|
if (0 != xmlStrcmp(node->name, (const xmlChar *)"chunk"))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user