游戏界面



//#include
//struct Flight{
// int no;
// char age;
// char name[20];
// int score[3];
// float average;
//};
//main(){
// struct Flight FG[2];
// int i;
// for(i=0;i<2;i++){
// printf("请输入ID:");scanf("%d",&FG[i].no);
// printf("请输入姓名:");scanf("%d",&FG[i].name);
// printf("请输入性别:");scanf("\n%d",&FG[i].age);
// printf("请输入玩家击落飞机成绩:");scanf("%d",&FG[i].score[0]);
// printf("请输入玩家得分:");scanf("%d",&FG[i].score[1]);
// printf("请输入总得分:");scanf("%d",&FG[i].score[2]);
// }
// printf("\n\tID\t姓名\t性别\t玩家击落飞机成绩\t玩家得分\t总得分\n");
//  
//}
// 登陆界面.cpp : 定义控制台应用程序的入口点。
//
//结构体没有搞懂
//好好分析吧! 
#include
#include
#include
#include
using namespace std;
//设置光标的位置
struct Flight{
char name[20];//用户姓名
int grade[20];//游戏成绩

 
};
void gotoxy(int x, int y)
{
COORD c;
c.X = x - 1;
c.Y = y - 1;
SetConsoleCursorPosition(GetStdHandle(STD_OUTPUT_HANDLE), c);
}
/*登陆界面*/
void Logo(){
system("color 0A");
gotoxy(30, 3);
cout <<"请注册玩家的名字(最多只有三个字)" << endl;
gotoxy(36, 4);
cout << "________________\t\t" << endl;
gotoxy(30, 5);
cout<<"姓名:"< gotoxy(35, 5);
cout << "|" << endl;
gotoxy(52, 5);
cout<<"|";
gotoxy(36, 6);
cout <<"一一一一一一一一"<< endl;
struct Flight FG[2];
for(int i=0;i<2;i++){
// cout<<"请输入相关数据"< gotoxy(39,5);
cin>>FG[i].name;
gotoxy(36,7);
cout<<"注册成功,正在努力加载中"< gotoxy(36,8);
cout<<"用户:"< system("cls"); 
}
}
/*主界面操作*/ 
void cursor(){





}
/**/
int main()
{
Logo();
// show();
cout< //std::cout << "Hello world!" << endl;
//system("pause");
    return 0;
}


你可能感兴趣的:(c)