Project

General

Profile

Statistics
| Revision:

root / proj / src / maps / map1.h @ 385

History | View | Annotate | Download (713 Bytes)

1 216 up20180642
#ifndef MAP1_H_INCLUDED
2
#define MAP1_H_INCLUDED
3
4 359 up20180642
#include "libs.h"
5 217 up20180642
6 321 up20180642
static map_t* get_map1(void){
7 370 up20180642
    char **ret         = xpm_load_xpm2("/home/lcom/labs/proj/src/maps/xpm2/map1.xpm2");
8
    char **ret_collide = xpm_load_xpm2("/home/lcom/labs/proj/src/maps/xpm2/map1_collide.xpm2");
9 359 up20180642
    map_t *r = NULL;
10
    if(ret != NULL && ret_collide != NULL){
11
        r = map_ctor((const char *const *)ret, (const char *const *)ret_collide);
12
    }else{
13
        if(ret         == NULL) printf("%s: map is NULL\n", __func__);
14
        if(ret_collide == NULL) printf("%s: collide is NULL\n", __func__);
15
    }
16 352 up20180642
    free(ret); free(ret_collide);
17 359 up20180642
    return r;
18 216 up20180642
}
19
20
#endif /* end of include guard: MAP_H_INCLUDED */