问题标题: 酷町创新公社:(200豆活动)Tiger6.0实验版发布及5月规划

1
0
已解决
张帆
张帆
中级天翼
中级天翼

首先就是Tiger6.0实验版了,有些功能还没开通,但删去了旁枝末节。

#include<iostream>
#include<cstdio>
#include<cstring>
#include<string>
#include<cstdlib>
#include<cmath>
#include<ctime>
#include<bits/stdc++.h>
#include<windows.h>
#include<fstream>
#include<iomanip>
#include<conio.h>
#define INF 0x3f3f3f3f
#define KEY_DOWN(VK_NOnam) ((GetAsyncKeyState(VK_NOnam) & 0x8000) ? 1:0)

using namespace std;

string name,pass;

int normal_color=15,title_color=14,name_color=1;
int style_color=1;
int color_paint[20][3]={
	{0,0,0},{15,14,1},{95,92,94},{79,78,78}
};

long long coin;

string thing[1000010];
int thing_cnt;
int VIP; 

void player();

void color(int corcorcor){
	SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),corcorcor);
}

void Line(string str){
    int l=str.length(),w=80;
    for(int i=0;i<(w-l)/2;i++) cout<<" ";
    cout<<str;
    return ;
}

void init(){
	system("cls");
	color(normal_color);
	system("cls");
	return ;
}

void ano(){ cout<<endl; }

void showcursor(){
	HANDLE h_GAME =GetStdHandle(STD_OUTPUT_HANDLE);
	CONSOLE_CURSOR_INFO cursor_info;
	GetConsoleCursorInfo(h_GAME,&cursor_info);
	cursor_info.bVisible=true;
	SetConsoleCursorInfo(h_GAME,&cursor_info);
}

void gotoxy(int x, int y)
{
	HANDLE hout;
	COORD coord;
	coord.X = x;
	coord.Y = y;
	hout = GetStdHandle(STD_OUTPUT_HANDLE);
	SetConsoleCursorPosition(hout, coord);
}

void first_out_for_welcome(){
	cout<<"                         ▇▇▇▇▇ ▇▇▇    ▇      ▇▇▇ ▇▇▇ ";ano();
	cout<<"                             ▇       ▇    ▇        ▇     ▇  ▇ ";ano();
	cout<<"                             ▇       ▇   ▇  ▇▇▇ ▇▇▇ ▇▇▇ ";ano();
	cout<<"                             ▇       ▇    ▇   ▇   ▇     ▇▇   ";ano();
	cout<<"                             ▇     ▇▇▇   ▇▇▇   ▇▇▇ ▇  ▇ ";ano();
	return ;
} 

void out(string said){
	for(int i=0;i<said.length();i++){
		cout<<said[i];
		Sleep(10);
	}
	return ;
}



void complete(){
	string fname;
	string fpass;
	MessageBox(NULL,"系统将带您注册一个新账号","tiger系统官方",MB_OK);
	cout<<"请输入您的用户名(不得超过十个字母或汉字):"; 
	ano();
	cin>>fname;
	while(fname.length()>10){
		cout<<"错误,请重新输入:";
		cin>>fname;
	}
	string s1,s2;
	cout<<"请输入您的密码:";
	ano();
	cin>>s1;
	cout<<"请再次输入您的密码:";
	cin>>s2;
	while(s1!=s2){
		cout<<"错误,";
		ano(); 
		cout<<"重新注册密码:";
		ano();
		ano(); 
		cout<<"请输入您的密码:";
		ano();
		cin>>s1;
		cout<<"请再次输入您的密码:";
		cin>>s2;
	}
	ano();
	ano();
	cout<<"注册成功!";
	name=fname;
	pass=s1;
	return ; 
}

void begin(){
	MessageBox(NULL,"欢迎您使用tiger系统","创新公社",MB_OK);
	ifstream fin("TIGER_PLAYER.txt");
	fin>>name;
	if(name==""){
		Line("请注册 TIGER: ");
		ano();
		ano();
		ano();
		complete();
	} else {
		fin>>pass;
		fin>>coin;
		fin>>thing_cnt;
		for(int i=1;i<=thing_cnt;i++){
			fin>>thing[i];
		}
		fin>>VIP;
		fin>>style_color;
		fin>>normal_color>>title_color>>name_color;
		system("cls");
	}
	fin.close();
	return ;
}

string getTime(){
    time_t timep;
    time (&timep);
    char tmp[64];
    strftime(tmp, sizeof(tmp), "系统时间:%Y/%m/%d %H:%M:%S        ",localtime(&timep) );
    return tmp;
}

string GetTime(){
    time_t timep;
    time (&timep);
    char tmp[64];
    strftime(tmp, sizeof(tmp), "%Y%m%d %H%M%S",localtime(&timep) );
    return tmp;
}

string turn(long long num){
	string ret="";
	while(num){
		ret=(char)(num%10-'0')+ret;
		num/=10;
	}
	return ret;
}

void buy();
void main_page();

//-----------扫雷 
const int dir[8][2]={{-1,-1},{-1,0},{-1,1},{0,-1},{0,1},{1,-1},{1,0},{1,1}};
int mmap[40][40],win,lose;
bool vis[40][40],fflag[40][40];
bool pd(int m,int n){
	for(int i=1;i<=m;i++){
		for(int j=1;j<=n;j++){
			if(vis[i][j]==0&&mmap[i][j]!=INF)
				return false;
		}
	}
	return true;
}
bool valid(int x,int y,int m,int n){
	if(x>=1&&x<=m&&y>=1&&y<=n)
		return true;
	return false;
}
void fankai(int x,int y,int m,int n){
	for(int i=0;i<8;i++){
		int nx=x+dir[i][0],ny=y+dir[i][1];
		if(valid(nx,ny,m,n)&&vis[nx][ny]==0){
			if(mmap[nx][ny]!=INF)
				vis[nx][ny]=true;
			if(mmap[nx][ny]==0)
				fankai(nx,ny,m,n);
		}
	}
}
bool saolei_p1(int m,int n){
	memset(vis,0,sizeof(vis));
	memset(fflag,0,sizeof(fflag));
	while(!pd(m,n)){
		system("cls");
		for(int i=1;i<=m;i++){
			for(int j=1;j<=n;j++){
				if(fflag[i][j]){
					color(11);
					cout<<"F ";
				}
				else if(vis[i][j]&&mmap[i][j]!=INF){
					if(mmap[i][j]==0){
						color(13);
					}
					else{
						color(15);
					}
					cout<<mmap[i][j]<<" ";
				}
				else{
					color(12);
					cout<<"? ";
				}
			}
			color(9);
			cout<<left<<setw(2)<<i<<endl;
		}
		color(9);
		for(int j=1;j<=n;j++)
			cout<<left<<setw(2)<<j;
		cout<<"  ←列"<<endl;
		cout<<right<<setw(n*2+2)<<" ↑"<<endl;
		cout<<right<<setw(n*2+2)<<" 行"<<endl;
		Sleep(1000);
		color(14);
		cout<<"输入说明:\n";
		cout<<"先输入两个数,空格隔开,表示你要操作的坐标。\n";
		cout<<"接着,输入一个数,表示操作类型:\n\t1表示翻开,\n\t2表示插旗,\n\t3表示快捷翻开周围的格子(前提是正确插旗)\n\t4表示撤销插旗\n\n\n";
		int xa,xb,caozuo;
		cin>>xa>>xb>>caozuo;
		if(!valid(xa,xb,m,n)||(caozuo<1||caozuo>4)){
			cout<<"输入错误,请重新输入!";
			Sleep(1000);
			system("cls");
			continue;
		}
		if(caozuo==1){
			if(mmap[xa][xb]==INF){
				system("cls");
				cout<<"你踩到地雷了!!!扫雷失败!!!\n这是答案:\n";
				for(int i=1;i<=m;i++){
					for(int j=1;j<=n;j++){
						if(mmap[i][j]==INF){
							color(11);
							cout<<"* ";
						}
						else{
							if(mmap[i][j]==0)
								color(13);
							else
								color(15);
							cout<<mmap[i][j]<<" ";
						}
					}
					cout<<endl;
				}
				color(14);
				system("pause");
				return false;
			}
			vis[xa][xb]=true;
			if(mmap[xa][xb]==0)
				fankai(xa,xb,m,n);
		}
		if(caozuo==2){
			if(vis[xa][xb]){
				cout<<"操作失败!";
				Sleep(1000);
				system("cls");
				continue;
			}
			fflag[xa][xb]=true;
		}
		if(caozuo==3){
			if(!vis[xa][xb]){
				cout<<"操作失败!";
				Sleep(1000);
				system("cls");
				continue;
			}
			int cnt=0,tmp_flag=false;
			for(int i=0;i<8;i++){
				int nx=xa+dir[i][0],ny=xb+dir[i][1];
				if(valid(nx,ny,m,n)&&fflag[nx][ny]){
					cnt++;
					if(mmap[nx][ny]!=INF){
						tmp_flag=true;
					}
				}
			}
			if(cnt!=mmap[xa][xb]){
				cout<<"操作格子周围的雷数不对,请注意。";
				Sleep(1000);
				system("cls");
				continue;
			}
			else if(tmp_flag){
				system("cls");
				cout<<"插旗错误!!!扫雷失败!!!\n这是答案:\n";
				for(int i=1;i<=m;i++){
					for(int j=1;j<=n;j++){
						if(mmap[i][j]==INF){
							color(11);
							cout<<"* ";
						}
						else{
							if(mmap[i][j]==0)
								color(13);
							else
								color(15);
							cout<<mmap[i][j]<<" ";
						}
					}
					cout<<endl;
				}
				color(14);
				system("pause");
				return false;
			}
			else{
				for(int i=0;i<8;i++){
					int nx=xa+dir[i][0],ny=xb+dir[i][1];
					if(valid(nx,ny,m,n)&&mmap[nx][ny]!=INF){
						vis[nx][ny]=true;
						if(mmap[nx][ny]==0){
							fankai(nx,ny,m,n);
						}
					}
				}
			}
		}
		if(caozuo==4){
			if(fflag[xa][xb])
				fflag[xa][xb]=false;
			else{
				cout<<"操作失败!";
				Sleep(1000);
				continue;
			}
		}
		system("cls");
	}
	system("cls");
	cout<<"你完成了扫雷,真厉害!\n这是答案:\n";
	for(int i=1;i<=m;i++){
		for(int j=1;j<=n;j++){
			if(mmap[i][j]==INF){
				color(11);
				cout<<"* ";
			}
			else{
				if(mmap[i][j]==0)
					color(13);
				else
					color(15);
				cout<<mmap[i][j]<<" ";
			}
		}
		cout<<endl;
	}
	color(14);
	system("pause");
	system("cls");
	return true;
}
bool saolei(int m,int n){
	srand(time(NULL));
	memset(mmap,0,sizeof(mmap));
	memset(vis,0,sizeof(vis));
	memset(fflag,0,sizeof(fflag));
	system("cls");
	int cnt_b=m*(n+1)/10+1;
	for(int i=1;i<=cnt_b;i++){
		int x=rand()%m+1,y=rand()%n+1;
		mmap[x][y]=INF;
	}
	cnt_b=0;
	for(int i=1;i<=m;i++){
		for(int j=1;j<=n;j++){
			if(mmap[i][j]==INF){
				cnt_b++;
			}
		}
	}
	for(int i=1;i<=m;i++){
		for(int j=1;j<=n;j++){
			if(mmap[i][j]!=INF){
				for(int k=0;k<8;k++){
					int nx=i+dir[k][0],ny=j+dir[k][1];
					if(valid(nx,ny,m,n)&&mmap[nx][ny]==INF){
						mmap[i][j]++;
					}
				}
			}
		}
	}
	system("cls");
	bool tmp=saolei_p1(m,n);
	system("cls");
	while(tmp==0){
		lose++;
		color(14);
		bool a;
		system("cls");
		cout<<"是否重新开始相同的地图?(1表示是,0表示否)";
		cin>>a;
		if(a){
			cout<<"好的,重新开始。";
			system("cls");
			tmp=saolei_p1(m,n);
		}
		else
			break;
	}
	return tmp;
}
void goto_saolei(){
	system("cls");
	int m,n;
	while(1){
		cout<<"请输入你要玩多少行,多少列的扫雷?\n";
		cin>>m>>n;
		if(!(m>=3&&m<=30&&n>=3&&n<=30)){
			cout<<"输入数据不合理,请重新输入!"<<endl;
			Sleep(1000);
			system("cls");
			continue;
		}
		else{
			break;
		}
	}
	if(saolei(m,n))
		win++;
	system("cls");
}
void ccy(){
	system("cls");
	color(0);
	system("cls");
	color(14);
	MessageBox(NULL,"欢迎来到扫雷1.2版(更上层楼)!\n特别鸣谢:沙宸安","欢迎",MB_OK);
	MessageBox(NULL,"输入是核对一下,输入的内容不要有字母或者\n其他奇奇怪怪的东西,否则会让程序崩溃!!!","注意!",MB_OK);
	system("cls");
	bool cd;
	cout<<"请问您是否使用上一次的存档???(输入1或0)";
	cin>>cd;
	if(cd){
		cout<<"好的,恢复存档。"<<endl;
		ifstream fin("扫雷.txt");
		fin>>win>>lose;
		fin.close();
		Sleep(1000);
	}
	while(1){
		system("cls");
		cout<<"你要玩什么游戏?\n1. 扫雷\n输入-1退出游戏。\n其余在开发中,敬请期待!";
		int g;
		cin>>g;
		if(g==-1)
			break;
		switch(g){
			case 1:goto_saolei();break;
			default:cout<<"输入错误,请重新输入!";Sleep(1000);continue; 
		}
	}
	system("cls");
	bool bc;
	cout<<"你赢了"<<win<<"局,输了"<<lose<<"局。成功率:";
	printf("%.1f",win*100/(double)(win+lose));
	cout<<"%\n";
	Sleep(1500);
	cout<<"是否保存???(输入1或0)";
	cin>>bc;
	if(bc){
		cout<<"好的,保存后请立即退出。"<<endl;
		ofstream fout("益智游戏大全.txt");
		fout<<win<<" "<<lose;
		fout.close();
		Sleep(1000);
	}
	else{
		system("cls");
		cout<<"再见!!!";
		ofstream fout("扫雷.txt");
		fout<<0<<" "<<0;
		fout.close();
		Sleep(1000);
	}
	return ;
}
//-----------扫雷 
//-----------名字竞技场
struct j{
	string fire;//技能名字
	string fine;//对敌人造成的伤害 
	int paint_cor; 
}; 

struct chacracter{
	string name;
	int HP,G,Z;
	j ay;
	int idx,num;
	string turn_num;
	string wy_num;
	int go_upper=0;
	string kill;
	int times;
	int paint_corff;
}; /*
	HP:血量
	G:攻击力
	Z:智力 
	ay:特技 
	idx:所在队伍 
	num:人物编号 
	*/

int n=1;

chacracter c[110]; 
j how[30]; //技能 


void give_num_to_how_a_fine_work(){
	how[1].fire="火球术",how[1].fine="100",how[1].paint_cor=12;
	how[2].fire="心灵控制",how[2].fine="10+turn",how[2].paint_cor=5;
	how[3].fire="地裂术",how[3].fine="25+every",how[3].paint_cor=6;
	how[4].fire="瘟疫",how[4].fine="20+wy",how[4].paint_cor=5;//wy感染
	how[5].fire="懒癌",how[5].fine="20+wy",how[5].paint_cor=5;//wy感染 
	how[6].fire="终极一击",how[6].fine="200+every+wy",how[6].paint_cor=12;
	how[7].fire="皇天冲击",how[7].fine="230+every+wy",how[7].paint_cor=6;
	how[8].fire="新冠病毒",how[8].fine="280+wy",how[8].fine=3;
	how[9].fire="代码冲击",how[9].fine="290+turn",how[9].paint_cor=11; 
	how[10].fire="文理双翼",how[10].fine="666",how[10].paint_cor=3; 
	return ; 
}
 

void first(){
	out("欢迎来到NC 6.0");
	//ano();
	//ano();
	ano();
	ano();
	cout<<"下面请输入名字,按enter+enter分队,禁止外挂,若系统发现外挂,自动退游,最多支持100个名字对战,超出可能会报错。";
	ano();
	cout<<"按enter+(ctrl+z)+enter(注:分开按)结束输入,开始对战";
	ano();
	system("pause");
	//cout<"\n";
	system("cls");
	return ; 
}//开始对白

void give_num_to_people(int id){
	int x=rand()%5+1;
	c[id].ay.fire=how[x].fire;
	c[id].ay.fine=how[x].fine;
	c[id].paint_corff=how[x].paint_cor;
	if(c[id].name.find("king",0)!=-1){
		c[id].ay.fire=how[6].fire;
		c[id].ay.fine=how[6].fine;
		c[id].paint_corff=how[6].paint_cor;
	} 
	if(c[id].name.find("dragon",0)!=-1){
		c[id].ay.fire=how[7].fire;
		c[id].ay.fine=how[7].fine;
		c[id].paint_corff=how[7].paint_cor;
	} 
	if(c[id].name.find("covid",0)!=-1){
		c[id].ay.fire=how[8].fire;
		c[id].ay.fine=how[8].fine;
		c[id].paint_corff=how[8].paint_cor;
	}
	if(c[id].name.find("coder",0)!=-1){
		c[id].ay.fire=how[9].fire;
		c[id].ay.fine=how[9].fine;
		c[id].paint_corff=how[9].paint_cor;
	}
	if(c[id].name.find("student",0)!=-1){
		c[id].ay.fire=how[10].fire;
		c[id].ay.fine=how[10].fine;
		c[id].paint_corff=how[10].paint_cor;
	}
	c[id].HP=rand()%201+200;
	c[id].G=rand()%41+10;
	c[id].Z=rand()%100+1; 
	return ;
}//对于每一个人物,生成属性。 

void in(){
	int ans=1;
	while(getline(cin,c[n].name)){
		if(c[n].name.empty()){
			ans++;
		} else {
			c[n].idx=ans;
			c[n].num=n; 
			c[n].kill="None";
			give_num_to_people(n); 
			n++;
		}
	
		//give_num_to_people(n); 
		//cout<<n<<" "<<c[n].HP<<" "<<c[n].G<<" "<<c[n].Z<<" "<<c[n].idx<<"\n";
	}
	n--;
	if(n<2||n>100){
		MessageBox(NULL,"WRONG","name-computation",MB_OK);
		MessageBox(NULL,"teams-begong","name-computation",MB_OK);
		system("cls");
		cout<<"the name team has no number to fight\n";
		cout<<"INF\n";
		system("pause");
		system("cls");
		exit(0);
	} 
	if(ans==1){//单斗模式 
		//int poster=1;
		for(int i=1;i<=n;i++){
			c[i].idx=i;
		} 
	}
	return ;
}//输入 

void fight_begin_out(){
	system("cls");
	color(240);
	system("cls");
	for(int i=1;i<=n;i++){
		cout<<(char)(c[i].idx+'A'-1)<<":";
		cout<<c[i].name<<"  ";
		cout<<"HP:"<<c[i].HP<<" ";
		cout<<"攻:"<<c[i].G<<" ";
		cout<<"智:"<<c[i].Z<<" ";
		ano();
	}
	cout<<"_____________________________________________________\n";
	return ;
}//开始输出属性 

bool check(){
	int pos=0,cnt=0;
	for(int i=1;i<=n;i++){
		if(c[i].HP>0){
			if(c[i].idx!=pos){
				pos=c[i].idx;
				cnt++;
			}
		}
	}
	return cnt>1;
}

int turn(string s){
	int sum=0;
	for(int i=0;i<s.length();i++){
		if(!(s[i]>='0'&&s[i]<='9')) break;
		sum=sum*10+(int)(s[i]-'0');
	}
	return sum;
}

void fight(){
	int now_turn;
	now_turn=rand()%n;
	while(check()){
		now_turn=now_turn%n+1;
		if(c[now_turn].HP==0) continue;
		if(c[now_turn].times%7==0){
			c[now_turn].turn_num="";
			c[now_turn].wy_num="";
		}
		int pos=rand()%3+1;//出招与否
		int names_you_go=rand()%n+1;
		while(c[names_you_go].idx==c[now_turn].idx||c[names_you_go].HP<=0) names_you_go=rand()%n+1;
		int yes=rand()%10+1; 
		if(c[now_turn].turn_num=="yes")  names_you_go=now_turn;
		switch(pos){
			case 3:{//出技能 
				cout<<c[now_turn].name<<" 使用了 ";
				color(c[now_turn].paint_corff+240);
				cout<<c[now_turn].ay.fire;
				color(0+240);
				cout<<",\n";
				int flag=c[now_turn].ay.fine.find("every",0);
				if(flag==-1){
					if(yes==1){
						cout<<c[names_you_go].name<<" 回避了攻击 。\n"; 
					} else {
						int fight_num=turn(c[now_turn].ay.fine);
						//if(!c[now_turn].ay.fire) 
						cout<<c[names_you_go].name<<" 受到了 ";
						color(12+240);
						cout<<fight_num;
						color(0+240);
						cout<<"点伤害";
						c[names_you_go].HP-=fight_num;
						if(c[names_you_go].HP<0) c[names_you_go].HP=0;
						if(c[names_you_go].HP==0){
							cout<<"	  "<<c[names_you_go].name<<"被击倒了"; 
							c[now_turn].go_upper++;
							c[names_you_go].kill=c[now_turn].name;
							break;
						}
						if(c[now_turn].ay.fine.find("turn",0)!=-1){
							cout<<","<<c[names_you_go].name<<" 被鬼魅了 ";
							c[names_you_go].turn_num="yes";
						}
						if(c[now_turn].ay.fine.find("wy",0)!=-1){
							cout<<","<<c[names_you_go].name<<" 被感染了 ";
							c[names_you_go].wy_num="yes";
							c[names_you_go].kill=c[now_turn].name;
						}
					}
					ano();
				} else {
					int fight_num=turn(c[now_turn].ay.fine);
					for(int i=1;i<=n;i++){
						if(c[i].HP<=0) continue;
						if(c[i].idx==c[names_you_go].idx){
							cout<<"   "<<c[i].name<<" 受到了 ";
							color(12+240);
							cout<<fight_num;
							color(0+240);
							cout<<"点伤害";
							c[i].HP-=fight_num;
							if(c[i].HP<=0){
								c[i].HP=0;
								cout<<","<<c[i].name<<"被击倒了;\n";
								c[now_turn].go_upper++;
								c[i].kill=c[now_turn].name;
								continue; 
							} 
							if(c[now_turn].ay.fine.find("turn",0)!=-1){
								cout<<","<<c[i].name<<" 被鬼魅了 ";
								c[i].turn_num="yes";
							}
							if(c[now_turn].ay.fine.find("wy",0)!=-1){
								cout<<","<<c[i].name<<" 被感染了 ";
								c[i].wy_num="yes";
								c[i].kill=c[now_turn].name;
							}
							cout<<"\n";
						}
					}
				}
				break;
			}
			default:{//出普通攻击 
				cout<<c[now_turn].name<<"发起攻击,"; 
				if(yes==1){
					cout<<c[names_you_go].name<<" 回避了攻击 。\n"; 
				} else {
					int fight_num=c[now_turn].G;
					//if(!c[now_turn].ay.fire) 
					cout<<"   "<<c[names_you_go].name<<" 受到了 ";
					color(12+240);
					cout<<fight_num;
					color(0+240);
					cout<<"点伤害";
					c[names_you_go].HP-=fight_num;
					if(c[names_you_go].HP<0) c[names_you_go].HP=0;
					if(c[names_you_go].HP==0){
						cout<<"	  "<<c[names_you_go].name<<"被击倒了\n";
						c[now_turn].go_upper++; 
						c[names_you_go].kill=c[now_turn].name;
					}
					ano();
				}
				break;
			} 
		} 
		if(c[now_turn].wy_num=="yes"){
			cout<<"   "<<c[now_turn].name<<"病毒发作,受到了";
			color(12+240);
			cout<<"50";
			color(0+240);
			cout<<"点伤害,";
			c[now_turn].HP-=50;
			if(c[names_you_go].HP==0){
				cout<<c[now_turn].name<<"被击倒了\n";
			}
			ano(); 
		}
		c[now_turn].times++;
		Sleep(500);
		cout<<endl;
	}
	return ;
}

void last_out(){
	ano();
	ano();
	cout<<"输出格式为名字,杀得人数,他被谁杀。";
	ano();
	ano(); 
	cout<<"胜者:";
	int pos=-1;
	ano();
	for(int i=1;i<=n;i++){
		if(c[i].HP>0){
			pos=c[i].idx;
			break;
		}	
	} 
	for(int i=1;i<=n;i++){
		if(c[i].HP>0) c[i].kill="None";
		if(c[i].idx==pos){
			color(c[i].idx+240);
			cout<<(char)(c[i].idx+'A'-1)<<":";
			cout<<c[i].name<<" "<<c[i].go_upper<<" "<<c[i].kill<<"\n";
		}
	}
	ano();
	ano();
	color(0+240);
	cout<<"败者:";
	ano();
	 for(int i=1;i<=n;i++){
	 	if(c[i].HP>0) c[i].kill="None";
		if(c[i].idx!=pos){
			color(c[i].idx+240);
			cout<<(char)(c[i].idx+'A'-1)<<":";
			cout<<c[i].name<<" "<<c[i].go_upper<<" "<<c[i].kill<<"\n";
		}
	}
	color(0+240);
	return ;
}

void name_computation(){
	system("cls");
	color(240);
	system("cls");
	srand((unsigned)time(NULL));
	MessageBox(NULL,"      作者:石灰\n      组织:酷町创新公社      ","版权声明",MB_OK); 
	MessageBox(NULL,"欢迎来到Name-computation6.0_c++\n       创新公社官方正版。","石灰×创新公社",MB_OK); 
	MessageBox(NULL,"此版本在5.0版本中基础上优化了用户体验,\n     给您带来更好的游戏感受。","石灰×创新公社:Name-computation",MB_OK);
	give_num_to_how_a_fine_work(); 
	first();
	in();
	fight_begin_out();
	fight();
	last_out();
	return ;
}
//名字竞技场 
void colorf(int corcorcor,int corcorcor2){
    corcorcor2*=16;
    SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),corcorcor+corcorcor2);
}
void cls(){    
    HANDLE hConsole=GetStdHandle(STD_OUTPUT_HANDLE);
    COORD coordScreen={0,0};//home for the cursor
    SetConsoleCursorPosition(hConsole,coordScreen);
    colorf(0,15);
    printf("");
}
void HideCursor(){
    HANDLE handle=GetStdHandle(STD_OUTPUT_HANDLE);
    CONSOLE_CURSOR_INFO CursorInfo;
    GetConsoleCursorInfo(handle,&CursorInfo);//获取控制台光标信息 
    CursorInfo.bVisible=false;//隐藏控制台光标 
    SetConsoleCursorInfo(handle,&CursorInfo);//设置控制台光标状态 
}
void LookCursor(){
    HANDLE handle=GetStdHandle(STD_OUTPUT_HANDLE);
    CONSOLE_CURSOR_INFO CursorInfo;
    GetConsoleCursorInfo(handle,&CursorInfo);//获取控制台光标信息 
    CursorInfo.bVisible=true;//显示控制台光标 
    SetConsoleCursorInfo(handle,&CursorInfo);//设置控制台光标状态 
}
const int N=46;
const string train[50][20]={
{
"  ◢■■■■■■  ", 
"◢■■和谐■■    ",
"◥■■■■■■    ",
"■◥■■■■■■■",
"    ●      ●    "
}
,{
"  ■■■■■■◣  ", 
"    ■■和谐■■◣",
"    ■■■■■■◤",
"■■■■■■■◤■",
"    ●      ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■■■■■■■  ",
"  ■■■■■■■■  ",
"■◥■■■■■■◤■",
"    ●        ●    "
},{
"  ◢■■■■■■◣  ",
"◢■■■和谐■■■◣",
"◥■■■■■■■■◤",
"■◥■■■■■■◤■",
"    ●        ●    "
},{
"                ",
"  ■■■■■■  ",
"  ■■■■■■  ",
"■■■■■■■■",
"    ●    ●    "
},{
"  ▄▄▄▄▄▄▄▄  ",
"  ■■‖■■‖■■  ",
"  ■■‖■■‖■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"    ■■■■■    ",
"    ■■■■■    ",
"    ■■■■■    ",
"■■■■■■■■■",
"    ●      ●    "
},{
"                  ",
"                  ",
"                  ",
"■■■■■■■■■",
"    ●      ●    "
},{
"  ◢■■■■■■■◣  ",
"  ■■■■■■■■■  ",
"  ■■■■■■■■■  ",
"■■■■■■■■■■■",
"    ●          ●    "
},{
"  ◢■■■■■■■◣  ",
"  ■■■■■■■■■  ",
"  ■■■■■■■■■  ",
"■■■■■■■■■■■",
"    ●          ●    "
},{
"  ◢■■■■■■■◣  ",
"  ■■■■■■■■■  ",
"  ■■■■■■■■■  ",
"■■■■■■■■■■■",
"    ●          ●    "
},{
"  ◢■■■■■■■◣  ",
"  ■■■■■■■■■  ",
"  ■■■■■■■■■  ",
"■■■■■■■■■■■",
"    ●◥■■■◤●    "
},{
"  ◢■■■■◣  ",
"  ■■■■■■  ",
"  ◥‖■■‖◤  ",
"■■■■■■■■",
"    ●    ●    "
},{
"  ◢■■■■◣  ",
"  ■■■■■■  ",
"  ◥‖■■‖◤  ",
"■■■■■■■■",
"    ●    ●    "
},{
"  ■■■■■■■    ",
"  ■■■■■■■    ",
"  ■■■■■■■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"    ■■■■■■■  ",
"    ■■■■■■■  ",
"  ■■■■■■■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ◢■■■■■■◣  ",
"◢■■■和谐■■■◣",
"◥■■■■■■■■◤",
"■◥■■■■■■◤■",
"    ●        ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■‖■■‖■■  ",
"  ■■‖■■‖■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"    ■■■■    ",
"  ■■■■■■  ",
"  ■■■■■■  ",
"■■■■■■■■",
"    ●    ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■‖■■‖■■  ",
"  ■■‖■■‖■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ▄▄▄▄▄▄▄▄  ",
"  ■■‖■■‖■■  ",
"  ■■‖■■‖■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ▄▄▄▄▄▄▄▄  ",
"  ■■‖■■‖■■  ",
"  ■■‖■■‖■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■‖■■‖■■  ",
"  ■■‖■■‖■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"                ",
"  ■■■■■■  ",
"  ■■■■■■  ",
"■■■■■■■■",
"    ●    ●    "
},{
"    ■■■■    ",
"  ■■■■■■  ",
"  ■■■■■■  ",
"■■■■■■■■",
"    ●    ●    "
},{
"    ■■■■    ",
"  ■■■■■■  ",
"  ■■■■■■  ",
"■■■■■■■■",
"    ●    ●    "
},{
"                ",
"  ■■■■■■  ",
"  ■■■■■■  ",
"■■■■■■■■",
"    ●    ●    "
},{
"    ■■■■■    ",
"    ■■■■■    ",
"    ■■■■■    ",
"■■■■■■■■■",
"    ●      ●    "
},{
"                  ",
"                  ",
"                  ",
"■■■■■■■■■",
"    ●      ●    "
},{
"  ◢■■■■■■  ■■■■■■◣  ",
"◢■■■和谐■■--■■和谐■■■◣",
"◥■■■■■■■--■■■■■■■◤",
"■◥■■■■■■  ■■■■■■◤■",
"    ●      ●      ●      ●    "
},{
"  ◢■■■■■■  ■■■■■■◣  ",
"◢■■■和谐■■--■■和谐■■■◣",
"◥■■■■■■■--■■■■■■■◤",
"■◥■■■■■■  ■■■■■■◤■",
"    ●      ●      ●      ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■快运专列■■  ",
"  ■■■■■■■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ■■■■■■■■  ",
"  ■■■■■■■■  ",
"  ◥■■■■■■◤  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ◢■■■■◣  ",
"  ■■■■■■  ",
"  ◥‖■■‖◤  ",
"■■■■■■■■",
"    ●    ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■■■■■■■  ",
"  ■■■■■■■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"    ■■■■■■    ",
"  ‖■■■■■■‖  ",
"  ■■■■■■■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ◥■■■■■■■■  ",
"  ‖◥■■■■■■■  ",
"  ‖◢■■■■■■■  ",
"■■■■■■■■■■■",
"    ●          ●    "
},{
"  ■■■■■■■■◤  ",
"  ■■■■■■■◤‖  ",
"  ■■■■■■■◣‖  ",
"■■■■■■■■■■■",
"    ●          ●    "
},{
"                    ",
"  ▄▄▄▄▄▄▄▄  ",
"  ■■■■■■■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ◢■■■■■■◣  ",
"◢■■■和谐■■■◣",
"◥■■■■■■■■◤",
"■◥■■■■■■◤■",
"    ●        ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■■■■■■■  ",
"  ■■■■■■■■  ",
"■◥■■■■■■◤■",
"    ●        ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■‖■■‖■■  ",
"  ■■‖■■‖■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ▄▄▄▄▄▄▄▄  ",
"  ■■■■■■■■  ",
"  ■■■■■■■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"    ■■■■■■    ",
"  ‖■■■■■■‖  ",
"  ■■■■■■■■  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ▄▄▄▄▄▄▄▄  ",
"  ■■■■■■■■  ",
"  ‖◥■■■■◤‖  ",
"■■■■■■■■■■",
"    ●        ●    "
},{
"  ◢■■■■■■◣  ",
"  ■■■■■■■■  ",
"  ■■■■■■■■  ",
"■◥■■■■■■◤■",
"    ●        ●    "
}
};
const int col[50][10][20]={
{//第一个 
{15,2,2,2,2,2,2,2,15},
{2,2,2,4,4,2,2,15,15},
{2,2,2,2,2,2,2,15,15},
{0,2,2,2,2,2,2,2,0},
{15,15,8,15,15,15,8,15,15}
}
,{//第二个 
{15,2,2,2,2,2,2,2,15},
{15,15,2,2,4,4,2,2,2},
{15,15,2,2,2,2,2,2,2},
{0,2,2,2,2,2,2,2,0},
{15,15,8,15,15,15,8,15,15}
},{//第三个 
{15,2,2,2,2,2,2,2,2,15},
{15,2,0,2,2,2,2,0,2,15},
{15,2,2,2,2,2,2,2,2,15}, 
{0,12,2,2,2,2,2,2,12,0},
{15,15,8,15,15,15,15,8,15,15}
},{//第四个 
{15,1,1,1,1,1,1,1,1,15},
{1,1,1,1,4,4,1,1,1,1},
{1,1,1,1,1,1,1,1,1,1}, 
{0,1,1,1,1,1,1,1,1,0},
{15,15,8,15,15,15,15,8,15,15}, 
},{//第五个 
{15,15,15,15,15,15,15,15},
{15,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0},
{15,15,8,15,15,8,15,15}
},{//第六个 
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,15,8,15,15}
},{//第七个 
{15,15,1,1,1,1,1,15,15},
{15,15,1,1,1,1,1,15,15},
{15,15,1,1,1,1,1,15,15},
{0,4,4,4,4,4,4,4,0},
{15,15,8,15,15,15,8,15,15}
},{//第八个 
{15,15,15,15,15,15,15,15,15},
{15,15,15,15,15,15,15,15,15},
{15,15,15,15,15,15,15,15,15},
{0,4,4,4,4,4,4,4,0},
{15,15,8,15,15,15,8,15,15}
},{//第九个 
{15,2,2,2,2,2,2,2,2,2,15},
{15,2,8,2,8,2,8,2,8,2,15},
{15,2,2,2,2,2,2,2,2,2,15},
{0,2,2,2,2,2,2,2,2,2,0},
{15,15,8,15,15,15,15,15,8,15,15}
},{//第十个 
{15,12,12,12,12,12,12,12,12,12,15},
{15,12,8,12,8,12,8,12,8,12,15},
{15,12,12,12,12,12,12,12,12,12,15},
{0,12,12,12,12,12,12,12,12,12,0},
{15,15,8,15,15,15,15,15,8,15,15}
},{//第十一个 
{15,1,1,1,1,1,1,1,1,1,15},
{15,1,8,1,8,1,8,1,8,1,15},
{15,1,1,1,1,1,1,1,1,1,15},
{0,1,1,1,1,1,1,1,1,1,0},
{15,15,8,15,15,15,15,15,8,15,15}
},{//第十二个 
{15,12,12,12,12,12,12,12,12,12,15},
{15,12,12,12,12,12,12,12,12,12,15},
{15,12,12,12,12,12,12,12,12,12,15},
{0,12,12,12,12,12,12,12,12,12,0},
{15,15,8,12,12,12,12,12,8,15,15}
},{//第十三个 
{15,6,6,6,6,6,6,15},
{15,6,6,6,6,6,6,15},
{15,6,0,6,6,0,6,15},
{0,0,0,0,0,0,0,0},
{15,15,8,15,15,8,15,15}
},{
{15,7,7,7,7,7,7,15},
{15,7,7,7,7,7,7,15},
{15,7,0,7,7,0,7,15},
{0,0,0,0,0,0,0,0},
{15,15,8,15,15,8,15,15}
},{//第十四个 
{15,3,3,3,3,3,3,3,15,15},
{15,3,3,3,3,3,0,3,15,15},
{15,3,3,3,3,3,3,3,3,15},
{0,3,3,3,3,3,3,3,3,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,15,3,3,3,3,3,3,3,15},
{15,15,3,0,3,3,3,3,3,15},
{15,3,3,3,3,3,3,3,3,15},
{0,3,3,3,3,3,3,3,3,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,2,2,2,2,2,2,2,2,15},
{2,2,2,2,4,4,2,2,2,2},
{2,2,2,2,2,2,2,2,2,2}, 
{0,2,2,2,2,2,2,2,2,0},
{15,15,8,15,15,15,15,8,15,15}, 
},{
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,15,1,1,1,1,15,15},
{15,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0},
{15,15,8,15,15,8,15,15}
},{
{15,2,2,2,2,2,2,2,2,15},
{15,2,2,2,2,2,2,2,2,15},
{15,2,2,2,2,2,2,2,2,15},
{0,2,2,2,2,2,2,2,2,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,2,2,2,2,2,2,2,2,15},
{15,2,2,2,2,2,2,2,2,15},
{15,2,2,2,2,2,2,2,2,15},
{0,2,2,2,2,2,2,2,2,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,4,4,4,4,4,4,4,4,15},
{15,4,4,4,4,4,4,4,4,15},
{15,4,4,4,4,4,4,4,4,15},
{0,4,4,4,4,4,4,4,4,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,4,4,4,4,4,4,4,4,15},
{15,4,4,4,4,4,4,4,4,15},
{15,4,4,4,4,4,4,4,4,15},
{0,4,4,4,4,4,4,4,4,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,15,15,15,15,15,15,15},
{15,4,4,4,4,4,4,15},
{15,4,4,4,4,4,4,15},
{0,4,4,4,4,4,4,0},
{15,15,8,15,15,8,15,15}
},{
{15,15,1,1,1,1,15,15},
{15,4,4,4,4,4,4,15},
{15,4,4,4,4,4,4,15},
{0,4,4,4,4,4,4,0},
{15,15,8,15,15,8,15,15}
},{
{15,15,1,1,1,1,15,15},
{15,2,2,2,2,2,2,15},
{15,2,2,2,2,2,2,15},
{0,2,2,2,2,2,2,0},
{15,15,8,15,15,8,15,15}
},{
{15,15,15,15,15,15,15,15},
{15,2,2,2,2,2,2,15},
{15,2,2,2,2,2,2,15},
{0,2,2,2,2,2,2,0},
{15,15,8,15,15,8,15,15}
},{
{15,15,1,1,1,1,1,15,15},
{15,15,1,1,1,1,1,15,15},
{15,15,1,1,1,1,1,15,15},
{0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,8,15,15}
},{
{15,15,15,15,15,15,15,15,15},
{15,15,15,15,15,15,15,15,15},
{15,15,15,15,15,15,15,15,15},
{0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,8,15,15}
},{
{15,1,1,1,1,1,1,1,15,1,1,1,1,1,1,1,15},
{1,1,1,1,4,4,1,1,0,1,1,4,4,1,1,1,1},
{1,1,1,1,1,1,1,1,0,1,1,1,1,1,1,1,1},
{0,1,1,1,1,1,1,1,15,1,1,1,1,1,1,1,0},
{15,15,8,15,15,15,8,15,15,15,8,15,15,15,8,15,15}
},{
{15,2,2,2,2,2,2,2,15,2,2,2,2,2,2,2,15},
{2,2,2,2,4,4,2,2,0,2,2,4,4,2,2,2,2},
{2,2,2,2,2,2,2,2,0,2,2,2,2,2,2,2,2},
{0,2,2,2,2,2,2,2,15,2,2,2,2,2,2,2,0},
{15,15,8,15,15,15,8,15,15,15,8,15,15,15,8,15,15}
},{
{15,12,12,12,12,12,12,12,12,15},
{15,12,12,4,4,4,4,12,12,15},
{15,12,12,12,12,12,12,12,12,15},
{0,12,12,12,12,12,12,12,12,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,7,7,7,7,7,7,7,7,15},
{15,7,7,7,7,7,7,7,7,15},
{15,7,7,7,7,7,7,7,7,15},
{0,0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,8,8,8,8,8,8,15},
{15,8,8,8,8,8,8,15},
{15,8,0,8,8,0,8,15},
{0,0,0,0,0,0,0,0},
{15,15,8,15,15,8,15,15}
},{
{15,6,6,6,6,6,6,6,6,15},
{15,6,6,6,6,6,6,6,6,15},
{15,6,6,6,6,6,6,6,6,15},
{0,6,6,6,6,6,6,6,6,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,15,4,4,4,4,4,4,15,15},
{15,0,4,4,4,4,4,4,0,15},
{15,4,4,4,4,4,4,4,4,15},
{0,4,4,4,4,4,4,4,4,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,0,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,15,15,8,15,15}
},{
{15,0,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,15,15,8,15,15}
},{
{15,15,15,15,15,15,15,15,15,15},
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,12,12,12,12,12,12,12,12,15},
{12,12,12,12,4,4,12,12,12,12},
{12,12,12,12,12,12,12,12,12,12}, 
{0,12,12,12,12,12,12,12,12,0},
{15,15,8,15,15,15,15,8,15,15}, 
},{
{15,9,9,9,9,9,9,9,9,15},
{15,9,0,9,9,9,9,0,9,15},
{15,9,9,9,9,9,9,9,9,15}, 
{0,9,9,9,9,9,9,9,9,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,8,8,8,8,8,8,8,8,15},
{15,8,8,8,8,8,8,8,8,15},
{15,8,8,8,8,8,8,8,8,15},
{0,8,8,8,8,8,8,8,8,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,15,9,9,9,9,9,9,15,15},
{15,0,9,9,9,9,9,9,0,15},
{15,9,9,9,9,9,9,9,9,15},
{0,9,9,9,9,9,9,9,9,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{15,0,0,0,0,0,0,0,0,15},
{0,0,0,0,0,0,0,0,0,0},
{15,15,8,15,15,15,15,8,15,15}
},{
{15,12,12,12,12,12,12,12,12,15},
{15,12,0,12,12,12,12,0,12,15},
{15,12,12,12,12,12,12,12,12,15}, 
{0,12,12,12,12,12,12,12,12,0},
{15,15,8,15,15,15,15,8,15,15}
}
};
const int len[50]={9,9,10,10,8,10,9,9,11,11,11,11,8,8,10,10,10,10,8,10,10,10,10,8,8,8,8,9,9,17,17,10,10,8,10,10,11,11,10,10,10,10,10,10,10,10};
int cx[10010],co[10][1000010];
bool way;
char chchchch; 
string str[10],tmp[10];
void trainf(){
    HideCursor();
    SetConsoleTitle("火车模拟器");
    system("cls");
    colorf(0,15);
    system("cls");
    printf("\n\n\n\t\t\t\t");
    colorf(4,15);
    cout<<"火";
    Sleep(1000);
    cls();
    printf("\n\n\n\t\t\t\t");
    colorf(1,15);
    cout<<"火";
    colorf(4,15);
    cout<<"车";
    Sleep(1000);
    cls();
    printf("\n\n\n\t\t\t\t");
    colorf(1,15);
    cout<<"火车";
    colorf(4,15);
    cout<<"模";
    Sleep(1000);
    cls();
    printf("\n\n\n\t\t\t\t");
    colorf(1,15);
    cout<<"火车模";
    colorf(4,15);
    cout<<"拟";
    Sleep(1000);
    cls();
    printf("\n\n\n\t\t\t\t");
    colorf(1,15);
    cout<<"火车模拟";
    colorf(4,15);
    cout<<"器";
    Sleep(1000);
    cls();
    colorf(1,15);
    printf("\n\n\n\t\t\t\t");
    cout<<"火车模拟器";
    Sleep(1000);
    colorf(0,15);
    cout<<"\n\n\t\t\t";
    printf("曹灿阳原创,请勿抄袭!!!");
    Sleep(2000);
    system("cls");
    while(1){
        LookCursor();
        memset(cx,0,sizeof(cx));
        memset(co,0,sizeof(co));
        for(int i=0;i<10;i++){
            str[i]="";
            tmp[i]="";
        }
        system("cls");
        colorf(0,15);
        system("cls");
        colorf(0,15);
        printf("请输入火车的方向:(0表示从左往右,非0表示从右往左,P退出)");
        cin>>chchchch;
        if(chchchch=='P') return ;
        if(chchchch=='0') way=false;
        else way=true;
        system("cls");
        for(int i=0;i<N;i+=2){
            for(int j=0;j<5;j++){
                for(int k=0;k<train[i][j].size();k+=2){
                    colorf(col[i][j][k/2],15);
                    printf("%c%c",train[i][j][k],train[i][j][k+1]);
                }
                cout<<"          ";
                for(int k=0;k<train[i+1][j].size();k+=2){
                    colorf(col[i+1][j][k/2],15);
                    printf("%c%c",train[i+1][j][k],train[i+1][j][k+1]);
                }
                printf("\n");
            }
            colorf(0,15);
            if(i+1>=N){
                if(i>=10)
                    printf("第%d号车厢(包括火车头)\n\n",i);
                else
                    printf("第0%d号车厢(包括火车头)\n\n",i);
            }
            else{
                if(i+1>=10){
                    printf("第%d号车厢(包括火车头)",i);
                    cout<<setw(len[i]*2-12)<<"第"<<i+1<<"号车厢(包括火车头)\n\n";
                }
                else if(i+1>=10&&i<10){
                    printf("第0%d号车厢(包括火车头)",i);
                    cout<<setw(len[i]*2-12)<<"第"<<i+1<<"号车厢(包括火车头)\n\n";
                }
                else{
                    printf("第0%d号车厢(包括火车头)",i);
                    cout<<setw(len[i]*2-12)<<"第"<<0<<i+1<<"号车厢(包括火车头)\n\n";
                }
            }
        }
        colorf(0,15);
        printf("请输入火车车厢编号(车厢数不多于10000,多余的部分自动省略,从左到右依次为车厢从\n左到右的顺序),空格隔开,异常值不读,按-1结束输入。火车方向:");
        printf(way?"从右往左\n":"从左往右\n");
        int idx=1;
        while(1){
            cin>>cx[idx];
            if(cx[idx]==-1||idx==10000)
                break;
            if(cx[idx]>=N||cx[idx]<0){
                continue;
            }
            idx++;
        }
        idx--;
        if(idx==0){
            colorf(0,15);
            cout<<"一节车厢也没有,你在输入寂寞???";
            Sleep(1000);
            continue;
        }
        HideCursor();
        int l=0;
        for(int i=1;i<=idx;i++){
            for(int k=0;k<len[cx[i]];k++){
                for(int j=0;j<5;j++){
                    co[j][l]=col[cx[i]][j][k];  
                }
                l++;
            }
            for(int j=0;j<5;j++){
                str[j]+=train[cx[i]][j];
            }
        }
        l--;
        system("cls");
        colorf(0,15);
        system("cls");
        if(way==0){
            printf("\n\n\n\n\n\n\n\n\n\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓");
            Sleep(500);
            cls();
            for(int i=l;i>=0;i--){
                printf("\n\n\n\n\n\n\n\n\n\n");
                for(int j=0;j<5;j++){
                    //str[j].substr(max(i,0)*2,(min(i+38,l)-i+1)*2);
                    for(int k=max(i,0)*2;k<=min(i+38,l)*2;k+=2){
                        colorf(co[j][k/2],15);
                        //cout<<;
                        cout<<str[j].substr(k,2);
                    }
                    printf("\n");
                }
                colorf(0,15);
                printf("〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓");
                Sleep(25);
                cls();
            }
            string kongge="";
            for(int i=1;i<=38;i++){
                printf("\n\n\n\n\n\n\n\n\n\n");
                kongge+="  ";
                for(int j=0;j<5;j++){
                    cout<<kongge;
                    for(int k=0;k<=min((38-i)*2,l*2);k+=2){
                        colorf(co[j][k/2],15);
                        cout<<str[j].substr(k,2);
                    }
                    printf("\n");
                }
                colorf(0,15);
                printf("〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓");
                Sleep(25);
                cls();
            }
            printf("\n\n\n\n\n\n\n\n\n\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓");
            Sleep(1000);
            system("cls");
        }
        else{
            printf("\n\n\n\n\n\n\n\n\n\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓");
            Sleep(500);
            cls();
            int cnt=-1;
            string kongge="";
            for(int i=38;i>=0;i--){
                cnt++;
                printf("\n\n\n\n\n\n\n\n\n\n");
                for(int j=0;j<5;j++){
                    for(int k=1;k<=i;k++)
                        cout<<"  ";
                    for(int k=0;k<=min(l,38-i)*2;k+=2){
                        colorf(co[j][k/2],15);
                        cout<<str[j].substr(k,2);
                    }
                    if(cnt>l){
                        if(j==0)
                            kongge=kongge+"  ";
                        cout<<kongge;
                    }
                    printf("\n");
                }
                colorf(0,15);
                printf("〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓");
                Sleep(25);
                cls();
            }
            for(int i=1;i<=l;i++){
                cnt++;
                printf("\n\n\n\n\n\n\n\n\n\n");
                //左:i 右:min(l,i+38) 
                for(int j=0;j<5;j++){
                    for(int k=i*2;k<=min(38+i,l)*2;k+=2){
                        colorf(co[j][k/2],15);
                        cout<<str[j].substr(k,2);
                    }
                    if(cnt>l){
                        if(j==0)
                            kongge=kongge+"  ";
                        cout<<kongge;
                    }
                    printf("\n");
                }
                colorf(0,15);
                printf("〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓");
                Sleep(25);
                cls();
            }
            printf("\n\n\n\n\n\n\n\n\n\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n");
            for(int i=1;i<=39;i++)
                printf("  ");
            printf("\n〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓〓");            Sleep(1000);
            system("cls");
            colorf(0,15);
            system("cls");
        }
    }
    return ;
}

//XA_codingtang v3.0.1
#define KEY_DOWN(VK_NOnam) ((GetAsyncKeyState(VK_NOnam) & 0x8000) ? 1:0)

struct xa{
	string nam,pas;
	int num,typ;
	/*
	typ=
	-x 已被删除的文件
	1  文件夹
	2  文本文档
	3  图片文件	
	*/
};
xa doc[256][256];
int checkf=1,top=1,toptxt=0,toppic=0,i,j,k,pictime=1000,cleartime=100,nod,ne1=3,ne2=0,ne3=0;
string xf_ap,txt[256],shoo[256];
char appe[71];
int file[256][256],filestd[256],pic[256][21][39],filetop[256]={0};
bool sho[256];
// sho[x]= 1 XAWPS 2 XAT.A.
void sav(){
	ofstream fout("XA文件系统.xadata");
	fout<<ne1<<" "<<ne2<<" "<<ne3;
	if(ne1==3 && ne2==0 && ne3==0){
		fout<<endl<<top<<" "<<toptxt<<" "<<toppic<<" "<<pictime<<" "<<cleartime<<" "<<nod<<endl;
		for(i=0;i<=255;i++){
			for(j=0;j<=255;j++){
				fout<<file[i][j]<<endl;
			}
		}
		fout<<endl;
		for(i=0;i<=255;i++){
			fout<<filestd[i]<<endl;
		}
		fout<<endl;
		for(i=0;i<=255;i++){
			for(j=0;j<=20;j++){
				for(k=0;k<=38;k++){
					fout<<pic[i][j][k]<<endl;
				}
			}
		}
		fout<<endl;
		for(i=0;i<=255;i++){
			fout<<filetop[i]<<endl;
		}
		fout<<endl;
		for(i=0;i<=255;i++){
			fout<<sho[i]<<endl;
		}
		for(i=0;i<=255;i++){
			for(j=0;j<=255;j++){
				fout<<doc[i][j].num<<endl<<doc[i][j].typ<<endl;
			}
		}
		for(i=0;i<=255;i++){
			for(j=0;j<=255;j++){
				fout<<doc[i][j].nam<<endl<<doc[i][j].pas<<endl;
			}
		}
		for(i=0;i<=255;i++){
			fout<<txt[i]<<endl;
		}
	}
	fout.close();
}

int kd(char ccc){
	if(!KEY_DOWN(ccc)) return 0;
	else return 1;
}
int shut_down(){
	if(kd('M')){
		checkf=0;
	}
}
void sp(int uuu){
	system("cls");
	sho[uuu]=1;
	cout<<"'"<<shoo[uuu]<<"'正在载入到您的XA中"<<endl;
	Sleep(2000);
	system("cls");
	return ;
}
void xatxt(int uuu){
	while(!kd('M')){
		system("cls");
		cout<<"您已进入文本编辑模式"<<endl<<"原文件:"<<txt[uuu]<<endl<<">>XA系统 Q-修改文本 M-退出编辑"<<endl;
		Sleep(500); 
		if(kd('Q')){
			cout<<"编辑:";
			getline(cin,xf_ap);
			cout<<">>XA系统 您确定要修改吗? T-确定 F-取消"<<endl;
			bool flag=0;
			while(!flag){
				if(kd('T')){
					flag=1;
					txt[uuu]=xf_ap;
				}
				Sleep(100);
				if(kd('F')){
					flag=1;
				}
				Sleep(100);
			}
		}
	}
}
void xapic(int uuu){
	int xx=1,yy=1,cr=7;
	bool pen=0;
	while(!kd('M')){
		system("cls");
		color(7);
		cout<<"您已进入图片(39x21)编辑模式"<<endl<<"原文件:"<<endl;
		for(i=1;i<=21;i++){
			for(j=1;j<=39;j++){
				color(pic[uuu][i][j]);
				cout<<"▇";
			}
			cout<<endl;
		}
		color(7);
		cout<<">>XA系统 (长按3-4秒,按键更新较慢)Q-修改图片 C-修改更新速度 M-退出编辑"<<endl;
		if(kd('C')){
			system("cls");
			cout<<">>注册表:更新速度(默认100毫秒)"<<endl<<"输入时间(毫秒):";
			cin>>cleartime;
			system("cls");
			cout<<"修改中。。。"<<endl; 
		}
		Sleep(3000);
		if(kd('Q'))while(!kd('M')){
			system("cls");
			color(7);
			cout<<"您已进入图片(39x21)编辑模式";
			cout<<" x:"<<xx<<" y:"<<yy<<endl;
			for(i=1;i<=21;i++){
				for(j=1;j<=39;j++){
					color(pic[uuu][i][j]);
					cout<<"▇";
				}
				cout<<endl;
			}
			color(7);
			cout<<">>XA系统 WASD-操作画笔 E-";
			if(pen) cout<<"抬起画笔 ";
			else cout<<"放下画笔 ";
			cout<<"R-更改颜色 M-保存并退出"<<endl;
			bool kdown=0;
			while(!kdown){
			Sleep(cleartime);
			if(kd('E')){
				pen=!pen;
				kdown=1;
			}
			if(kd('W') && xx!=1){
				xx--;
				kdown=1;
			}
			if(kd('S') && xx!=21){
				xx++;
				kdown=1;
			}
			if(kd('A') && yy!=1){
				yy--;
				kdown=1;
			}
			if(kd('D') && yy!=39){
				yy++;
				kdown=1;
			}
			if(pen) pic[uuu][xx][yy]=cr;
			if(kd('R')){
				system("cls");
				cout<<"更改色号:";
				for(i=0;i<=15;i++){
					color(i);
					cout<<"▇ ";
				}
				color(7);
				cout<<endl<<"色号编码:";
				for(i=0;i<=15;i++){
					if(i<10)cout<<i<<"  ";
					else cout<<i<<" ";
				}
				cout<<endl;
				cin>>cr;
				cr=cr%16;
				kdown=1;
			}
			if(kd('M')){
				kdown=1;
			}
			}
		}
	}
}
void findesktop(int cmmmd){
	if(cmmmd==1){
		cout<<"桌面";
		return ;
	}
	else{
		findesktop(file[cmmmd][0]);
		cout<<">>"<<cmmmd;
		return ;
	} 
}
int jsq1()
{
	double a1,b1;
	char x;
	cout<<">>XA系统 请依次输入:[一个整数或一个有限小数][四则运算符号][一个整数或一个有限小数]"<<endl;
	cin>>a1>>x>>b1;
	if(x=='+')
		cout<<a1+b1<<endl;
	if(x=='-')
		cout<<a1-b1<<endl;
	if(x=='*')
		cout<<a1*b1<<endl;
	if(x=='/')
	{
		if(b1==0)
			cout<<">>XA系统 除数不能为0!"<<endl;
		else cout<<a1/b1<<endl;
	}
	return 0;
}
int guo(int h1,int h2){
	int xxxxx,mm1,mm2,bxxxxxggest=0;
	mm1=h1;
	mm2=h2;
	bxxxxxggest=h1>h2? h1:h2;
	for(xxxxx=2;xxxxx<bxxxxxggest;xxxxx++)
		{			
		if(mm1%xxxxx==0 && mm2%xxxxx==0)
		{
			mm1=mm1/xxxxx;
			mm2=mm2/xxxxx;
		xxxxx=xxxxx-1;
		}
	}
	if(mm1%mm2==0)
	{
		cout<<mm1/mm2<<endl;
	}
	else cout<<mm1<<"/"<<mm2<<endl;
}
int jsq2()
{
	int a1,a2,b1,b2,i1,i2,j1,j2,e1,e2,ccccccccccccccccccccccccc;
	char ccccc,fff; 
	cout<<">>XA系统 请依次输入:"<<endl<<"(正号或负号)[第一个数的分子]/[第一个数的分母]"<<endl<<"[四则运算符号]"<<endl<<"(正号或负号)[第二个数的分子]/[第二个数的分母]"<<endl;
	cin>>a1>>fff>>a2;
	cin>>ccccc;
	cin>>b1>>fff>>b2;
	if(ccccc=='+')
	{
		i1=a1*b2;
		i2=b1*a2;
		j1=a2*b2;
		j2=a2*b2;
		e1=i1+i2;
		e2=j1;
	}
	if(ccccc=='-')
	{
		i1=a1*b2;
		i2=b1*a2;
		j1=a2*b2;
		j2=a2*b2;
		e1=i1-i2;
		e2=j1;
	}
	if(ccccc=='/')
	{
		ccccccccccccccccccccccccc=b2;
		b2=b1;
		b1=ccccccccccccccccccccccccc;
		ccccc='*';
	}
	if(ccccc=='*')
	{
		e1=a1*b1;
		e2=a2*b2;
	}
	guo(e1,e2);
	return 0;
}
//应用商店软件分割线(始) 
int nans[11][60][60];
string nand[11];
void saves(){
	ofstream fout("地图存档.txt");
	for(i=1;i<=10;i++){
		fout<<nand[i]<<endl;
		for(j=0;j<=59;j++){
			for(k=0;k<=59;k++){
				fout<<nans[i][j][k]<<" ";
			}
			fout<<endl;
		}
	}
	fout.close();
}
void reads(){
	ifstream fin("地图存档.txt");
	for(i=1;i<=10;i++){
		fin>>nand[i];
		for(j=0;j<=59;j++){
			for(k=0;k<=59;k++){
				fin>>nans[i][j][k];
			}
		}
	}
	fin.close();
}
void xamaps(int uuu){
	int xx=0,yy=0,cr=7;
	bool pen=0;
	while(!kd('M')){
		system("cls");
		color(7);
		cout<<"您已进入图片(60x60)编辑模式"<<endl<<"原文件:"<<endl;
		for(i=0;i<=59;i++){
			for(j=0;j<=59;j++){
				color(nans[uuu][i][j]);
				cout<<"@";
			}
			cout<<endl;
		}
		color(7);
		cout<<">>XA系统 (长按3-4秒,按键更新较慢)Q-修改图片 M-退出编辑"<<endl;
		Sleep(3000);
		if(kd('Q'))while(!kd('M')){
			system("cls");
			color(7);
			cout<<"您已进入图片(60x60)编辑模式";
			cout<<" x:"<<xx<<" y:"<<yy<<endl;
			for(i=0;i<=59;i++){
				for(j=0;j<=59;j++){
					color(nans[uuu][i][j]);
					cout<<"@";
				}
				cout<<endl;
			}
			color(7);
			cout<<">>XA系统 WASD-操作画笔 E-";
			if(pen) cout<<"抬起画笔 ";
			else cout<<"放下画笔 ";
			cout<<"R-更改颜色 M-保存并退出"<<endl;
			bool kdown=0;
			while(!kdown){
			if(kd('E')){
				pen=!pen;
				kdown=1;
			}
			if(kd('W') && xx!=0){
				xx--;
				kdown=1;
			}
			if(kd('S') && xx!=59){
				xx++;
				kdown=1;
			}
			if(kd('A') && yy!=0){
				yy--;
				kdown=1;
			}
			if(kd('D') && yy!=59){
				yy++;
				kdown=1;
			}
			if(pen) nans[uuu][xx][yy]=cr;
			if(kd('R')){
				system("cls");
				cout<<"更改色号:";
				for(i=0;i<=15;i++){
					color(i);
					cout<<"▇ ";
				}
				color(7);
				cout<<endl<<"色号编码:";
				for(i=0;i<=15;i++){
					if(i<10)cout<<i<<"  ";
					else cout<<i<<" ";
				}
				cout<<endl;
				cin>>cr;
				cr=cr%16;
				kdown=1;
			}
			if(kd('M')){
				kdown=1;
			}
			}
		}
	}
}
int kdwd_map(){
	while(!kd('M')){
	int cmmmd=0;
	bool kb=0;
	reads();
	color(14);
	system("cls");
	cout<<"酷町问答地形绘制"<<endl; 
	color(7);
	cout<<"O-打开图层"<<endl<<"R-保存"<<endl<<"E-格式化当前存档(第一次打开也需启动)"<<endl<<"N-重命名图层"<<endl<<"M-退出"<<endl;
	while(!kb){
		if(kd('E')){
			system("cls");
			cout<<">>XA系统 [危险警告]您真的要格式化当前工程吗?"<<endl<<"Y-确定 N-取消"<<endl;
			bool ked=0;
			while(!kb){
				if(kd('Y')){
					ofstream fout("地图存档.txt");
			int i,j,k;
			for(i=1;i<=10;i++){
			fout<<"图层"<<i<<endl;
			for(j=0;j<=59;j++){
				for(k=0;k<=59;k++){
					fout<<7<<" ";
				}
				fout<<endl;
				}
				kb=1;
			} 
			fout.close();
				}
				if(kd('N')){
					kb=1;
				}
				Sleep(50);
			}
			Sleep(1000);
		}
		if(kd('O')){
			for(i=1;i<=10;i++){
				cout<<i<<":"<<nand[i]<<endl;
			}
			cout<<"输入图层:"<<endl;
			cin>>i;
			xamaps(i);
			saves();
			system("cls");
			cout<<"正在退出。。。"<<endl;
			Sleep(1000);
			kb=1;
		}
		if(kd('R')){
			sav();
			system("cls");
			cout<<"保存成功"<<endl;
			Sleep(1000);
			kb=1;
		}
		if(kd('N')){
			system("cls");
			for(i=1;i<=10;i++){
				cout<<i<<":"<<nand[i]<<endl;
			}
			cout<<"输入图层:";
			cin>>i;	
			cout<<endl;
			cout<<"新名字:";
			cin>>nand[i];
			cout<<"改名成功"<<endl;
			Sleep(1000);
			kb=1;
			saves();
		}
	}} 
}
void xawps(){
	while(!kd('M')){
		system("cls");
		cout<<"XAWPS v1.0.0"<<endl;
	}
}
string xatarun(string cmmmmd,int be,int en){
	for(i=be;i<=en;i++){
		if(cmmmmd[i]=='>') nod++;
		if(cmmmmd[i]=='<') nod--;
		if(cmmmmd[i]=='+') appe[nod]++;
		if(cmmmmd[i]=='-') appe[nod]--;
		if(cmmmmd[i]=='['){
			j=i+1;
			int runs=0,fir=0,lat=0;
			while(cmmmmd[j]!=']'){
				int spe=cmmmmd[j]-'0';
				runs=runs*10+spe;
				j++;
			}
			fir=j+1;
			lat=fir;
			while(cmmmmd[lat]!='}'){
				lat++;
			}
			for(j=1;j<=runs;j++){
				xatarun(cmmmmd,fir,lat);
			}
		}
	}
	return appe;
}
void xata(){
	nod=0;
	while(!kd('M')){
		system("cls");
		color(14);
		cout<<"XA Text Appender v1.0.1"<<endl;
		color(7);
		cout<<"Q-打开工程"<<endl<<"W-显示ASCII码表"<<endl<<"E-格式化工程"<<endl<<"M-退出"<<endl;
		if(kd('E')){
			system("cls");
			cout<<">>XA系统 [危险警告]您真的要格式化当前工程吗?"<<endl<<"Y-确定 N-取消"<<endl;
			bool ked=0;
			while(!ked){
				if(kd('Y')){
					ked=1;
					nod=0;
					memset(appe,0,sizeof(appe));
				}
				if(kd('N')){
					ked=1;
				}
				Sleep(50);
			}
		}
		if(kd('W')){
			system("cls");
			char ascii2=1;
			for(i=1;i<=128;i++){
				if(i!=10){
					printf("%03d ",i);
					cout<<ascii2<<endl;
				}else{
					printf("%03d [换行符]\n",i);
				}
				ascii2++;
			}
			while(!kd('M')){
				Sleep(100);
			}
			cout<<">>XA系统 正在退出,请勿再按“M”键"<<endl;
			Sleep(1000);
		}
		if(kd('Q')){
			string cmmmd;
			while(cmmmd!="E"){
				system("cls");
				color(14);
				for(i=0;i<=70;i++) cout<<i/10;
				cout<<endl;
				for(i=0;i<=70;i++) cout<<i%10;
				cout<<endl;
				color(7);
				for(i=0;i<=70;i++) cout<<appe[i];
				cout<<endl<<"CMD:";
				cin>>cmmmd;
				system("cls");
				color(7);
				cout<<endl<<"正在进行语法性检查。。。";
				int aa=0,bb=0;
				int flag=0;
				for(i=0;i<=cmmmd.length();i++){
					if(cmmmd[i]=='{') aa++;
					if(cmmmd[i]=='}') bb++;
					if(cmmmd[i]=='['){
						j=i+1;
						while(cmmmd[j]!=']'){
							if(cmmmd[j]<'0' || cmmmd[j]>'9') flag=1;
							j++;
						}
						if(cmmmd[j+1]!='{') flag=2;
						j=0;
					}
				}
				if(aa!=bb) flag=3;
				int xxxxx=cmmmd.length();
				if(flag==0) cout<<endl<<"编译通过:"<<xatarun(cmmmd,0,xxxxx)<<endl;
				else cout<<endl<<"编译不通过"<<endl;
				Sleep(3000);
			}
		}
		Sleep(500);
	}
}
//应用商店软件分割线(终)
void app(){
	while(!kd('M')){
		system("cls");
		color(14);
		cout<<"XA应用"<<endl;
		color(7);
		cout<<"M-退出"<<endl<<"O-打开"<<endl;
		for(i=1;i<=256;i++){
			if(sho[i]) cout<<i<<":"<<shoo[i]<<endl;
		}
		if(kd('O')){
			system("cls");
			color(14);
			cout<<"选择应用"<<endl;
			color(7);
			for(i=1;i<=256;i++){
				if(sho[i]) cout<<i<<":"<<shoo[i]<<endl;
			}
			cout<<"输入=0 - 退出"<<endl<<"打开编号为( )的应用:"; 
			cin>>i;
			if(sho[i]){
				if(i==1) xawps();
				if(i==2) xata();
				if(i==3) kdwd_map();
			}
			system("cls");
		}
		Sleep(100);
	}
}
void desktop(int cmmd){
	while(!kd('M'))
	{
		system("cls");
		color(9);
		cout<<"操作系统:XA-codingtang v3.0.1"<<endl;
		color(7);
		//string time=getTime();
		//cout<<time<<endl;
		color(14);
		cout<<"文件夹路径:";
		color(7);
		findesktop(cmmd);
		cout<<endl;	
		for(i=1;i<=filestd[cmmd];i++){
			if(1){
				cout<<i<<" : "<<file[cmmd][i]<<endl;
			}
		}
		color(14);
		cout<<"基本操作:"<<endl;
		color(7);
		cout<<"C-打开功能栏"<<endl<<"O-打开小工具"<<endl<<"A-打开应用"<<endl<<"I-应用商店"<<endl<<"T-投诉&反馈"<<endl;
		color(14);
		cout<<"XA应用:"<<endl;
		color(7);
		for(i=1;i<=200;i++) if(sho[i]) cout<<shoo[i]<<endl;
		Sleep(1000);
		system("cls");
		shut_down();
		if(kd('T')){
			while(!kd('M')){
				system("cls");
				cout<<">>XA系统 若要投诉&反馈,请访问网址https://wenda.codingtang.com/questions/11059/ !M-退出"<<endl;
				Sleep(1000);
			}
		}
		if(kd('A')){
			app();
		}
		if(kd('I')){
			while(!kd('M')){
				system("cls");
				color(14);
				cout<<"--------------XA应用商店--------------"<<endl;
				color(7);
				cout<<"M-退出应用商店"<<endl<<">>XA系统 按下对应的数字代表您想下载这款应用"<<endl;
				color(10);
				cout<<"最新上架"<<endl; 
				color(14);
				cout<<"  应用名称 开发者   发布时间   版本号"<<endl;
				color(7);
				cout<<"1-XAWPS    兴安科技 2020.10.21 1.0.0"<<endl;
				cout<<"2-XAT.A.   兴安科技 2020.11.01 1.0.1"<<endl;
				cout<<"3-KDWD_map 兴安科技 2020.11.29 1.0.1"<<endl;
				cout<<""<<endl;
				color(10);
				cout<<"推荐应用"<<endl;
				color(14);
				cout<<"  应用名称 开发者   发布时间   版本号"<<endl;
				color(7);
				cout<<"Q-XAWPS    兴安科技 2020.10.21 1.0.0"<<endl;
				cout<<"W-XAT.A.   兴安科技 2020.11.01 1.0.1"<<endl;
				if(kd('1')) sp(1);
				if(kd('Q')) sp(1);
				if(kd('2')) sp(2);
				if(kd('W')) sp(2);
				if(kd('3')) sp(3);
				Sleep(500); 
			}
			sav();
		}
		if(kd('O')) 
		while(!kd('M')){
			system("cls");
			cout<<"Q-计算器"<<endl<<"W-分数计算器"<<endl<<"E-计时器"<<endl<<"R-倒计时"<<endl<<"M-退出小工具"<<endl;
			Sleep(500);
			if(kd('Q')){
				system("cls");
				jsq1();
				Sleep(1500);
			}
			if(kd('W')){
				system("cls");
				jsq2();
				Sleep(1500);
			}
			if(kd('E')){
				system("cls");
				int ddddd=0,hhhhh=0,mmmmm=0,sssss=0;
				bool se=0;
				while(!kd('M')){
					system("cls");
					color(9);
					cout<<"操作系统:XA-codingtang v3.0.1"<<endl;
					color(14);
					cout<<"XA计时器"<<endl<<"当前计时:";
					color(7);
					printf("%02d:%02d:%02d:%02d",ddddd,hhhhh,mmmmm,sssss);
					if((ddddd!=0 || hhhhh!=0 || mmmmm!=0 || sssss!=0) && !se){
						color(14);
						cout<<" 暂停中";
						color(7);
					}
					cout<<endl<<">>XA系统 T-开始/继续/暂停计时 Y-清零 M-退出"<<endl;
					Sleep(1000);
					if(kd('T')) se=!se;
					if(kd('Y')){
						ddddd=0;
						hhhhh=0;
						mmmmm=0;
						sssss=0;
					}
					if(se){
						sssss++;
						if(sssss==60){
							sssss=0;
							mmmmm++;
						}
						if(mmmmm==60){
							mmmmm=0;
							hhhhh++;
						}
						if(hhhhh==24){
							hhhhh=0;
							ddddd++;
						}
					}	
				}
				system("cls");
				cout<<">>XA系统 正在退出,请勿再按“M”键"<<endl;
				Sleep(1500);
			}
			if(kd('R')){
				system("cls");
				int ddddd=0,hhhhh=0,mmmmm=0,sssss=0;
				bool se=0,flag=1;
				cout<<"输入倒计时的 日 时 分 秒"<<endl;
				cin>>ddddd>>hhhhh>>mmmmm>>sssss;
				if((hhhhh>23 || mmmmm>59 || sssss>59)||(ddddd==0 && hhhhh==0 && mmmmm==0 && sssss==0)||(!(ddddd>0 || hhhhh>0 || mmmmm>0 || sssss>0))){
					flag=0;
					cout<<">>XA系统 输入错误!"<<endl;
					Sleep(500);
				}
				while(!kd('M') && flag){
					system("cls");
					color(9);
					cout<<"操作系统:XA-codingtang v3.0.1"<<endl;
					color(14);
					cout<<"XA倒计时"<<endl<<"当前计时:";
					color(7);
					printf("%02d:%02d:%02d:%02d",ddddd,hhhhh,mmmmm,sssss);
					if(!se){
						color(14);
						cout<<" 暂停中";
						color(7);
					}
					if(ddddd==0 && hhhhh==0 && mmmmm==0 && sssss==0){
						cout<<endl<<">>XA系统 倒计时结束,3秒后退出倒计时。";
						Sleep(3000);
						break; 
					}
					cout<<endl<<">>XA系统 T-开始/继续/暂停计时 M-退出"<<endl;
					Sleep(1000);
					if(kd('T')) se=!se;
					if(se){
						sssss--;
						if(sssss==-1){
							sssss=59;
							mmmmm--;
						}
						if(mmmmm==-1){
							mmmmm=59;
							hhhhh--;
						}
						if(hhhhh==-1){
							hhhhh=23;
							ddddd--;
						}
					}	
				}
				system("cls");
				cout<<">>XA系统 正在退出,请勿再按“M”键"<<endl;
				Sleep(1500);
			}
		}
		if(kd('C')) 
		while(!kd('N')){
			system("cls");
			cout<<"Q-新建文件夹"<<endl<<"W-打开文件夹"<<endl<<"E-新建文本文档"<<endl<<"R-新建图片"<<endl<<"O-打开文件"<<endl<<"I-重命名文件"<<endl<<"T-加密文件"<<endl<<"N-退出功能区"<<endl<<"M-退至上一个文件夹"<<endl;
			Sleep(500);
			if(kd('Q')){
				system("cls");
				cout<<">>XA系统 正在建立,请勿再按“Q”键"<<endl;
				top++;
				filetop[top]=0;
				file[top][0]=cmmd;
				filestd[cmmd]++;
				file[cmmd][filestd[cmmd]]=top;
				sav();
			}
			if(kd('E')){
				system("cls");
				cout<<">>XA系统 正在建立,请勿再按“E”键"<<endl;
				toptxt++;
				filetop[cmmd]++;
				doc[cmmd][0].num++;
				doc[cmmd][doc[cmmd][0].num].typ=2;
				doc[cmmd][doc[cmmd][0].num].num=toptxt;
				doc[cmmd][doc[cmmd][0].num].nam="XAtext";
				sav();
			}
			if(kd('R')){
				system("cls");
				cout<<">>XA系统 正在建立,请勿再按“R”键"<<endl;
				toppic++;
				filetop[cmmd]++;
				doc[cmmd][0].num++;
				doc[cmmd][doc[cmmd][0].num].typ=3;
				doc[cmmd][doc[cmmd][0].num].num=toppic;
				doc[cmmd][doc[cmmd][0].num].nam="XApicture";
				sav();
			}
			if(kd('W')){
				system("cls");
				for(i=1;i<=filestd[cmmd];i++){
					if(1){
					cout<<i<<" : "<<file[cmmd][i]<<endl;
					}
				}
				cout<<"输入=0 - 退出"<<endl<<"打开第( )个文件夹:"; 
				cin>>i;
				if(i>0) desktop(file[cmmd][i]);
				sav();
			}
			if(kd('O')){
				system("cls");
				for(i=1;i<=doc[cmmd][0].num;i++){
					if(1){
					cout<<i<<" : "<<doc[cmmd][i].nam<<endl;
					}
				}
				cout<<"输入=0 - 退出"<<endl<<"打开第( )个文件:"; 
				cin>>i;
				if(i>0 && filetop[cmmd]>=i){
					if(doc[cmmd][i].typ==2){
						bool flag=1;
						if(doc[cmmd][i].pas!="" && doc[cmmd][i].pas!="/"){
							system("cls");
							cout<<"'"<<doc[cmmd][i].nam<<"'已被加密,输入密码以打开文件:";
							string a11;
							cin>>a11;
							if(a11!=doc[cmmd][i].pas) flag=0;
						}
						if(flag){
							xatxt(doc[cmmd][i].num);
							cout<<">>XA系统 正在退出,请勿再按“M”键"<<endl;
						}
						if(!flag){
							cout<<">>XA系统 无法打开'"<<doc[cmmd][i].nam<<"',密码不正确。";
						}
					}
					if(doc[cmmd][i].typ==3){
						bool flag=1;
						if(doc[cmmd][i].pas!="" && doc[cmmd][i].pas!="/"){
							system("cls");
							cout<<"'"<<doc[cmmd][i].nam<<"'已被加密,输入密码以打开文件:";
							string a11;
							cin>>a11;
							if(a11!=doc[cmmd][i].pas) flag=0;
						}
						if(flag){
							xapic(doc[cmmd][i].num);
							cout<<">>XA系统 正在退出,请勿再按“M”键"<<endl;
						}
						if(!flag){
							cout<<">>XA系统 无法打开'"<<doc[cmmd][i].nam<<"',密码不正确。";
						}
					} 
				} 
				sav();
			}
			if(kd('I')){
				system("cls");
				for(i=1;i<=doc[cmmd][0].num;i++){
					if(1){
					cout<<i<<" : "<<doc[cmmd][i].nam<<endl;
					}
				}
				cout<<"输入=0 - 退出"<<endl<<"重命名第( )个文件:"; 
				cin>>i;
				if(i>0 && filetop[cmmd]>=i){
					cout<<"重命名:";
					cin>>doc[cmmd][i].nam;
					cout<<">>XA系统 改名成功!"<<endl; 
				}
				sav();
			}
			if(kd('T')){
				system("cls");
				for(i=1;i<=doc[cmmd][0].num;i++){
					if(1){
					cout<<i<<" : "<<doc[cmmd][i].nam<<endl;
					}
				}
				cout<<"输入=0 - 退出"<<endl<<"加密第( )个文件:"; 
				cin>>i;
				if(i>0 && filetop[cmmd]>=i){
					system("cls");
					string a11,a22;
					if(doc[cmmd][i].pas!="" && doc[cmmd][i].pas!="/"){
						cout<<"输入旧密码:";
						cin>>a11;
						if(a11==doc[cmmd][i].pas){
							cout<<"输入密码:";
						cin>>a11;
						system("cls");
						cout<<"确认密码:";
						cin>>a22;
						system("cls");
						if(a11==a22){
							cout<<">>XA系统 加密成功!"<<endl;
							doc[cmmd][i].pas=a11;
						}else cout<<">>XA系统 加密失败!"<<endl;	
							}	
					}else{
						cout<<"输入密码:";
						cin>>a11;
						system("cls");
						cout<<"确认密码:"; 
						cin>>a22;
						system("cls");
						if(a11==a22){
							cout<<">>XA系统 加密成功!"<<endl;
							doc[cmmd][i].pas=a11;
						}else cout<<">>XA系统 加密失败!"<<endl;
					}
				}
				sav();
			}
			if(kd('M')){
				system("cls");
				cout<<">>XA系统 正在退出,请勿再按“M”键"<<endl;
				Sleep(500);
				return ;
			}
		}
	}
}
void XAscience()
{
	shoo[1]="XAWPS";
	shoo[2]="XAT.A.";
	shoo[3]="KDWD_map";
	int bb1,bb2,bb3;
	ifstream fin("XA文件系统.xadata");
	fin>>bb1>>bb2>>bb3;
	if(bb1==3 && bb2==0 && bb3==0){
		fin>>top>>toptxt>>toppic>>pictime>>cleartime>>nod;
		for(i=0;i<=255;i++){
			for(j=0;j<=255;j++){
				fin>>file[i][j];
			}
		}
		for(i=0;i<=255;i++){
			fin>>filestd[i];
		}
		for(i=0;i<=255;i++){
			for(j=0;j<=20;j++){
				for(k=0;k<=38;k++){
					fin>>pic[i][j][k];
				}
			}
		}
		for(i=0;i<=255;i++){
			fin>>filetop[i];
		}
		for(i=0;i<=255;i++){
			fin>>sho[i];
		}
		for(i=0;i<=255;i++){
			for(j=0;j<=255;j++){
				fin>>doc[i][j].num>>doc[i][j].typ;
			}
		}
		for(i=0;i<=255;i++){
			for(j=0;j<=255;j++){
				fin>>doc[i][j].nam;
				fin>>doc[i][j].pas;
			}
		}
		for(i=0;i<=255;i++){
			fin>>txt[i];
		}
	}
	fin.close();
	sav();
	while(checkf){
		desktop(1);
	}
	system("cls");
		cout<<"XA-codingtang v3.0.1 正在关机..."<<endl;
		Sleep(3000);
		checkf=0;
		cout<<"关机完毕,欢迎下次使用。"<<endl;
	i=0,j=0; 
    return ;
}

void main_page();

void player(){
	playerf:
	init();
	cout<<getTime();
	cout<<"\n您想玩什么游戏:\n";
	cout<<"1-益智游戏\n";
	cout<<"2-name-computation5.0 win7兼容版\n";
	cout<<"3-火车模拟器\n";
	cout<<"4-XAv3.0.1虚拟机\n";
	cout<<"*-退出此页面\n"; 
	cout<<"您想玩什么游戏,做出选择:";
	char choice;
	cin>>choice;
	if(choice=='1'){
		system("cls");
		ccy();
	} else if(choice=='2'){
		system("cls");
		name_computation();
	} else if(choice=='3'){
		system("cls");
		trainf();
	} else if(choice=='4'){
		system("cls");
		cout<<"Copyright by XAscience."; 
		system("pause");
		system("cls");
		XAscience();
	} else {
		main_page();
	}
	goto playerf;
	return ;
}

void things(){
	thingsf:
	system("cls");
	Line("仓库"); 
	cout<<"\n\n";
	for(int i=1;i<=thing_cnt;i++){
		cout<<i<<"."<<thing[i]<<"\t";
	}
	cout<<"\n*-退出仓库\n";
	cout<<"请输入你的选择:"; 
	char choice;
	cin>>choice;
	if(choice=='*'){
		main_page();
	} else {
		system("cls");
		goto thingsf;
	}
	return ;
}
/* 
void diary(){
	system("cls");
	Line("金币流油");
	cout<<"\n";
	if(VIP<8){
		cout<<"VIP等级不足。"; 
		system("pause");
		main_page();
		return ;
	} 
	int every_money=rand()%100+50;
	coin=coin+every_money*100;
	cout<<"恭喜获得"<<every_money<<"金币";
	system("pause"); 
	main_page();
	return ;
}//暂时关闭*/

void make_sth();

void make_sth_a(){
	make_sth_af:
	init();
	Line("直算计算器");
	ano();
	cout<<"请输入一个四则运算式,输入exit退出直算计算器,不要包含空格和等号\n";
	cout<<"请输入:"; 
	string str;
	cin>>str;
	if((str.find("exit",0)+1)) {
		make_sth();
	} 
	char opp='+';
	int id_now=-1;
	double sum=0;
	long long num=0;
	str+=" ";
	for(int i=0;i<str.length();i++){
		if(!(str[i]>='0'&&str[i]<='9')){
			switch(opp){
				case '+':{
					sum+=(double)num;
					break;
				}
				case '-':{
					sum-=(double)num;
					break;
				}
				case '*':{
					sum*=(double)num;
					break;
				}
				case '/':{
					if(num==0){
						cout<<"wrong";
						system("pause");
						goto make_sth_af;
					}
					sum/=num;
					break;
				}
			}
			opp=str[i];
			num=0;
		} else {
			num=num*10+str[i]-'0';
		}	
	}
	printf("%.2f\n",sum);
	system("pause");
	goto make_sth_af;
	return ;
}

void make_sth_b(){
	init();
	Line("未开放\n");
	system("pause");
	return ; 
}

void make_sth_c(){
	init();
	Line("未开放\n");
	system("pause");
	return ; 
}

void make_sth_d(){
	init();
	Line("未开放\n");
	system("pause");
	return ; 
}

void softs();

void make_sth(){
	makef:
	init();
	Line("Title计算工具"); 
	cout<<"\n";
	cout<<"请选择您需要计算的:";
	cout<<"1-直算计算器\n";
	cout<<"2-整数四则计算器(暂未开放)\n";
	cout<<"3-前缀式求值(暂未开放)\n";
	cout<<"4-后缀式求值(暂未开放)\n";
	cout<<"*-退出Title计算工具\n"; 
	cout<<"备注:2,3,4功能作者已经实现,但由于此为实验版,暂缓开放,敬请谅解。\n"; 
	cout<<"请输入您的选择:";
	char choice;
	cin>>choice;
	switch(choice){
		case '1':{
			make_sth_a();
			break;
		}
		case '2':{
			make_sth_b(); 
			break;
		}
		case '3':{
			make_sth_c();
			break;
		}
		case '4':{
			make_sth_d();
			break;
		}
		case '*':{
			softs();
			break;
		}
		default:{
			goto makef;
			break;
		}
	} 
	goto makef;
	return ;
}

void tree_name(){
	init();
	Line("<特别鸣谢>");
	ano();
	Line("沙宸安 王子逸 汪恺恒");
	ano();
	Line("李致远 陈曦");
	ano(); 
	Line("~开发者~");
	ano();
	Line("张帆 曹灿阳");
	ano();
	Line("-开发公司-");
	ano();
	Line("创新公社游戏工坊");
	ano();
	ano();
	cout<<"*如果想加入名单,问答或者洛谷私信张帆。\n"; 
	system("pause");
	main_page();
	return ; 
}

void tellf(){
	init();
	Line("公告栏");
	color(normal_color);
	ano();
	cout<<"一,Tiger的XA和XACRTF\n";
	cout<<"    皆由兴安科技授权转载。\n";
	cout<<"二,由于某种原因,XACRTF在此系统中删除\n"; 
	cout<<"三,BW体验版已经公布,庆祝!\n";
	cout<<"\n";
	cout<<"暂无其他公告。\n";
	system("pause");
	main_page(); 
	return ;
}

void Controler(){
	controlerff:
	init();
	string passss;
	cout<<"请输入管理密码:";
	cin>>passss;
	if(passss!="controler"){
		return ;
	} 
	system("cls");
	cout<<"1-修改金额\n";
	cout<<"2-退出\n";
	char choice;
	cin>>choice;
	switch(choice){
		case '1':{
			long long pos;
			cout<<"增加数目:" ;
			cin>>pos;
			coin+=pos*100;
			cout<<"OK";
			break;
		}
		case '2':{
			main_page();
			break;
		}
	}
	goto controlerff;
	return ;
}

void Foreground_scenery(){
	cout<<"前景色\n";
	cout<<"0    黑色\n";
	cout<<"1	深蓝色\n";
	cout<<"2	深绿色\n";
	cout<<"3	深青色\n";
	cout<<"4	深红色\n";
	cout<<"5	深粉色\n";
	cout<<"6	黄色\n";
	cout<<"7	深白色\n";
	cout<<"8	灰色\n";
	cout<<"9	浅蓝色\n";
	cout<<"10	浅绿色\n";
	cout<<"11	浅青色\n";
	cout<<"12	浅红色\n";
	cout<<"13	浅粉色\n";
	cout<<"14	浅黄色\n";
	cout<<"15	浅白色\n"; 
	return ;	 
}

void style(){
	styleff:
	init();
	color(title_color);
	Line("风格商城");
	color(normal_color);
	ano();
	ano();
	cout<<"1-默认\n";
	cout<<"2-粉色少女\n";
	cout<<"3-烈火刚燃\n";
	cout<<"4-自定义\n";
	cout<<"*-退出风格商城\n"; 
	cout<<"请输入您的选择:";
	char choice;
	cin>>choice;
	switch(choice){
		case '1':{
			normal_color=color_paint[1][0],title_color=color_paint[1][1],name_color=color_paint[1][2];
			style_color=1;
			break;
		}
		case '2':{
			normal_color=color_paint[2][0],title_color=color_paint[2][1],name_color=color_paint[2][2];
			style_color=2;
			break;
		}
		case '3':{
			normal_color=color_paint[3][0],title_color=color_paint[3][1],name_color=color_paint[3][2];
			style_color=3;
			break;
		}
		case '4':{
			system("cls");
			cout<<"请选择正常前景色:\n";
			Foreground_scenery();
			cout<<"选择:";
			int choice;
			cin>>choice;
			if(!(choice>=0&&choice<=15)){
				cout<<"wrong";
				break;
			} 
			normal_color=choice;
			ano();
			ano();
			cout<<"请选择正常背景色:\n";
			Foreground_scenery();
			cout<<"选择:";
			cin>>choice;
			if(!(choice>=0&&choice<=15)){
				cout<<"wrong";
				break;
			} 
			normal_color=normal_color+max(1,choice*16);
			ano();
			ano();
			cout<<"请选择标题前景色:\n";
			Foreground_scenery();
			cout<<"选择:";
			cin>>choice;
			if(!(choice>=0&&choice<=15)){
				cout<<"wrong";
				break;
			} 
			title_color=choice;
			ano();
			ano();
			cout<<"请选择标题背景色:\n";
			Foreground_scenery();
			cout<<"选择:";
			cin>>choice;
			if(!(choice>=0&&choice<=15)){
				cout<<"wrong";
				break;
			} 
			title_color=title_color+max(1,choice*16);
			ano();
			ano();
			cout<<"请选择名字前景色:\n";
			Foreground_scenery();
			cout<<"选择:";
			cin>>choice;
			if(!(choice>=0&&choice<=15)){
				cout<<"wrong";
				break;
			} 
			name_color=choice;
			ano();
			ano();
			cout<<"请选择名字背景色:\n";
			Foreground_scenery();
			cout<<"选择:";
			cin>>choice;
			if(!(choice>=0&&choice<=15)){
				cout<<"wrong";
				break;
			} 
			name_color=name_color+max(1,choice*16);
			break;
		}
		case '*':{
			main_page();
			break;
		}
		default:{
			goto styleff;
			break;
		}
	} 
	goto styleff;
	return ;
}

void attribute(){
	system("cls");
	cout<<"Normal_color:"<<normal_color<<endl;
	cout<<"Title_color:"<<title_color<<endl;
	cout<<"Name_color:"<<name_color<<endl;
	cout<<"Version:"<<"6.0 of experimental Edition"<<endl;
	system("pause");
	return ;
}

//---Tigersoft浏览器

int WEBSITE_cnt=1;
string website_information[210][2010]={
	{""},
	{"Innovation.Commue.tig.cn","创新公社:","酷町问答组织之一", "包含创新实验室",
	"欢迎加入" ,"END$$$"
	}
}; 

void TIGERsoftsIC(){
	ICsoftsf:
	init();
	color(title_color);
	Line("Tigersoft浏览器"); 
	color(normal_color);
	ano();
	cout<<"请输入网址,输入EXIT退出Tigersoft浏览器,输入SEE查看所有网址列表\n";
	cout<<"现在,请输入:\n";
	cout<<"+---------------------------------------------------------+\n";
	cout<<"Tiger://"; 
	string website;
	cin>>website;
	if(website=="EXIT"){
		softs();
		return ;
	} else if(website=="SEE") {
		init();
		Line("网址列表");
		ano();
		cout<<"Tiger://Inovation.Commue.tig.cn : 关于创新公社\n";
		cout<<"可以投稿网址by洛谷私信张帆,内容可包括个人信息,信息宣传……内容在2000行及以内,有意者欢迎投稿\n"; 
		system("pause"); 
		goto ICsoftsf;
	} else {
		cout<<"+---------------------------------------------------------+\n";
		bool find=false;
		for(int i=1;i<=WEBSITE_cnt;i++){
			if(website_information[i][0]==website){
				find=true;
				int now_pos_cnt=0;
				do{
					now_pos_cnt++;
					if(website_information[i][now_pos_cnt]=="END$$$") break;
					cout<<website_information[i][now_pos_cnt]<<endl;
				}while(true);
			}
		}
		if(!find){
			cout<<"未找到\n";
		}
		system("pause");
		goto ICsoftsf;
	}
	goto ICsoftsf;
	return ;
}


//------------------ 

void softs(){
	softsff:
	init();
	Line("应用");
	ano();
	cout<<"1-Tigersoft浏览器\n";
	cout<<"2-Title计算工具\n";
	cout<<"*-退出应用栏\n";
	cout<<"请输入您的选择:";
	char choice; 
	cin>>choice;
	switch(choice){
		case '1':{
			TIGERsoftsIC();
			break;
		}
		case '2':{
			make_sth();
			break;
		}
		case '*':{
			main_page();
			break;
		}
		default:{
			goto softsff;
			break;
		}
	}
	goto softsff;
	return ;
}

void main_page(){
	pagef:
	ofstream fout("TIGER_PLAYER.txt");
	showcursor();
	fout<<name<<"\n"<<pass<<"\n";
	fout<<coin<<"\n";
	fout<<thing_cnt<<"\n";
	for(int i=1;i<=thing_cnt;i++) fout<<thing[i]<<"\n";
	fout<<VIP<<"\n";
	fout<<style_color<<"\n";
	fout<<normal_color<<" "<<title_color<<" "<<name_color;
	fout.close();
	while(true){
		init();
		color(name_color);
		cout<<"|--------------------------------------------";
		for(int spa=0;spa<10;spa++) cout<<"-";
		cout<<"|";
		ano();
		cout<<"|T                                           "<<setw(10)<<name;
		color(normal_color);
		cout<<"|";
		ano();
		cout<<"|-------------------------------------------";
		for(int spa=0;spa<10;spa++) cout<<"-";
		cout<<"-|";
		ano();
		cout<<"|                                                      |";
		ano();
		cout<<"|                                                      |";
		ano();
		cout<<"|";
		color(title_color);
		cout<<"      "<<getTime()<<"           |";
		color(normal_color);
		ano();
		cout<<"|                                                      |";
		ano();
		cout<<"|----------------------                                |\n";
		cout<<"||1-应用游戏          |                                |\n";
		//cout<<"||2-仓库              |                                |\n";
		cout<<"||2-特别榜单          |                                |\n";
		cout<<"||3-应用              |                                |\n";
		cout<<"||4-公告栏            |                                |\n"; 
		cout<<"||5-风格商城          |                                |\n"; 
		cout<<"||6-属性              |                                |\n";
		cout<<"||7-退出登录          |                                |\n";
		cout<<"||E-退出系统          |                                |\n";
		cout<<"|----------------------                                |\n";
		cout<<"|                                                      |";
		ano();
		cout<<"|";
		cout<<"请输入你的选择:                                      |";
		cout<<"\n";
		cout<<"|------------------------------------------------------|";
		gotoxy(17,18); 
		char choice;
		cin>>choice;
		//cout<<choice<<"\n";
		//GetAsyncKeyState()
		//cls();
		if(choice=='1'){
			player();
			break;
		}
		else if(choice=='2'){
			tree_name();
			break;
		} 
		else if(choice=='3'){
			softs();
			break;
		}
		else if(choice=='4'){
			MessageBox(NULL,"关于tiger系统的最新消息都会在此呈现","tiger系统官方",MB_OK);
			system("cls");
			tellf();
			break;
		}
		else if(choice=='5'){
			style();
			break;
		}
		else if(choice=='6'){
			attribute();
			break;
		}
		else if(choice=='7'){
			init();
			begin();
			break;
		}
		else if(choice=='E'){
			system("cls");
			Line("Tiger系统正在保存数据并退出……");
			cout<<"\n";
			Sleep(1000);
			system("pause");
			exit(0);
			break;
		}
		else if(choice=='#'){
			Controler();
			break;
		}
		else {
			system("cls");
			goto pagef;
			break;
		}
	}
	main_page(); 
	return ;
}
/*
void buy(){
	MessageBox(NULL,"您即将进入购物宝,请确保您的周围环境安全。","tiger系统官方",MB_OK);
	buyf:
	system("cls");
	cout<<getTime();
	ano();
	ano(); 
	cout<<"余额:\n"; 
	printf("%.2f\n\n",coin/100.0);
	cout<<"r-返回主页,l-购买物品";
	ano();
	cout<<"请输入你的选择:"; 
	char choice;
	cin>>choice;
	switch(choice){
		case 'r':{
			system("cls");
			main_page();
			break;
		}
		case 'l':{
			storef:
			system("cls");
			cout<<"余额:\n"; 
			printf("%.2f\n\n",coin/100.0);
			cout<<"a-战甲_90money\n";
			cout<<"b-利剑_99.9money\n";
			cout<<"c-VIP_30money\n";
			cout<<"d-SVIP_100money\n";
			cout<<"*-退出商店\n";
			cout<<"请输入你的选择:";
			char choose;
			cin>>choose;
			switch(choose){
				case 'a':{
					if(coin>9000){
						cout<<"购买成功!!!";
						system("pause");
						string nan="战甲";
						thing[++thing_cnt]=nan;
						coin-=9000; 
					} else {
						cout<<"买不起!!!";
						system("pause");
					}
					goto storef;
					break;
				}
				case 'b':{
					if(coin>9999){
						cout<<"购买成功!!!";
						system("pause");
						string nan="利剑";
						thing[++thing_cnt]=nan;
						coin-=9999; 
					} else {
						cout<<"买不起!!!";
						system("pause");
					}
					goto storef;
					break;
				}
                case 'c':{
                                        if(coin>1500){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,1);
                                                coin-=1500;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'd':{
                                        if(coin>3000){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,2);
                                                coin-=3000;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'e':{
                                        if(coin>4500){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,3);
                                                coin-=4500;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'f':{
                                        if(coin>6000){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,4);
                                                coin-=6000;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'g':{
                                        if(coin>7500){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,5);
                                                coin-=7500;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'h':{
                                        if(coin>9000){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,6);
                                                coin-=9000;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'i':{
                                        if(coin>10500){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,7);
                                                coin-=10500;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'j':{
                                        if(coin>12000){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,8);
                                                coin-=12000;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'k':{
                                        if(coin>13500){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,9);
                                                coin-=13500;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
                                case 'l':{
                                        if(coin>15000){
                                                cout<<"购买成功!!!";
                                                system("pause");
                                                VIP=max(VIP,10);
                                                coin-=15000;
                                        } else {
                                                cout<<"买不起!!!";
                                                system("pause");
                                        }
                                        goto storef;
                                        break;
                                }
				case '*':{
					main_page();
					break;
				}
				default:{
					goto storef;
					break;
				}
			} 
			break;
		}
		default:{
			system("cls");
			goto buyf;
			break;
		}
	}
	return ;
}*/

int main(){
	SetConsoleTitle("Tiger6.0实验版系统 By石灰X云峰X创新公社");
	init();
	first_out_for_welcome();
	Sleep(10); 
	system("cls"); 
	begin();
	system("cls");
	first_out_for_welcome();
	Sleep(10);
	main_page();
	return 0;
}

这了有一个活动,就是在主页->风格商城->自定义风格中创造自定义风格,

发出主页和主页->属性的截图,并为你的风格取个名字,如果可以(协调)将会择优加入系统并获得此200豆。

——————————分割线—————————————————————————————————

未来规划

1.完成Tiger6.0正式版的开发

2.完成Title计算工具1.0的开发

张帆在2021-05-01 12:35:45追加了内容

ding

张帆在2021-05-01 12:35:50追加了内容

ding

张帆在2021-05-04 12:39:58追加了内容

ding

张帆在2021-05-04 12:40:04追加了内容

ding

张帆在2021-05-04 12:40:50追加了内容

ddd


0
已采纳
谭迪元
谭迪元
资深光能
资深光能

nb nb

希望越来越好!!!!

谭迪元在2021-05-01 08:40:47追加了内容

可以加入BW的不闪屏

0
0
0
我要回答