C++自作小游戏 走迷宫(源代码)
大家好,我做了一个走迷宫的c++的源代码,适合初学者,可以交流交流,学习学习
可以拿走,收藏哦!
目前只有一种地图,还会改进,多多关照
实际操作:
按W向上,按S向下,按A向左,按D向右
代码:
#include<stdio.h>
#include<stdlib.h>
#include<string.h>
#include<windows.h>
#include<conio.h>
int main() {
char a[50][50] = {
"######",
"#O # ",
"# # #",
"# # #",
"# #",
"######"};
int i, x, y, p, q;
x