-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmap.cpp
35 lines (33 loc) · 792 Bytes
/
map.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#include "map.h"
#include <ncurses.h>
Map::Map(WINDOW * win) {
char map[22][24] = {
"XXXXXXXXXXXXXXXXXXXXXXX",
"X..........X..........X",
"X.XXX.XXXX.X.XXXX.XXX.X",
"X$XXX.XXXX.X.XXXX.XXX$X",
"X.....................X",
"X.XXX.X.XXXXXXX.X.XXX.X",
"X.....X....X....X.....X",
"XXXXX.XXXX X XXXX.XXXXX",
"XXXXX.X X.XXXXX",
"XXXXX.X XXXXXXX X.XXXXX",
" . X X . ",
"XXXXX.X XxxxxxX X.XXXXX",
"XXXXX.X X.XXXXX",
"XXXXX.X XXXXXXX X.XXXXX",
"X..........X..........X",
"X.XXX.XXXX.X.XXXX.XXX.X",
"X$..X.............X..$X",
"XXX.X.X.XXXXXXX.X.X.XXX",
"X.....X....X....X.....X",
"X.XXXXXXXX.X.XXXXXXXX.X",
"X.....................X",
"XXXXXXXXXXXXXXXXXXXXXXX"
};
for(int i = 0; i < 22; i++) {
for(int j = 0; j < 23; j++) {
mvwaddch(win, i, j, map[i][j]);
}
}
}