模拟21点扑克牌游戏(C++课设)(3)
cout<<"\t\t取消╳(其它任意键取消)\n\t\t";cin>>enter; if(enter=='y'||enter=='Y') } else }
int Display::showfile()//打开游戏规则文件 {
ifstream in;
in.open("e://c++课设//21点扑克牌游戏//rule",ios::in); if(!in) { }
char s[1000]; while(!in.eof())
cout<<"打开规则失败,请按任意键返回上层"<<endl;; return -1; game.BeginFail(1,0); {
game.Log_in(password); game.RegisterSucceed(); game.RegisterFail(); else
}
void Display::DisplayRule()//3.打印游戏规则界面 {
cout<<"\n\n\n";
cout<<"\t\t\t\t游 戏 规 则\n\n\n"; game.showfile(); cout<<"\n\n\n\n";
cout<<"\t\t\t\t按任意键返回 "; getch(); game.cls();
game.DisplayMenu(); }
void Display::DisplayQuit()//4.退出游戏界面 {
cout<<"\n\n\n\n\n";
cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ 您的选择是明智的,赌博有害身心健康! ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ 适量游戏,放松身心,请勿沉溺游戏 ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ 我们不欢迎你频繁使用本程序! ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷\n"; Sleep(3000); exit(0); }
void Display::RegisterSucceed()//5.打印注册成功界面 {
Rank=0; Money=100; game.StoreUser(); { }
in.close(); return 0;
in.getline(s,sizeof(s)); cout<<s<<endl;
cout<<"\n\n\n\n\n\n";
cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ 注 册 成 功 ! ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ 请按任意键返回登录 ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷"; Sleep(1000); getch(); game.cls();
game.DisplayMenu(); }
void Display::RegisterFail()// {
cout<<"\n\n\n\n\n\n\n\n";
cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ 注 册 失 败 ! ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷可能由于该用户名已存在,或者注册被取消 ∷\n"; cout<<"\t\t∷ 请按任意键返回 ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷"; Sleep(1000); getch(); game.cls();
game.DisplayMenu(); }
void Display::Begin()//6.打印登录成功界面 {
game.cls();
cout<<"\n\n\n\n\n";
cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷\n\n\n"; cout<<"\t\t\t\t登 录 成 功 ! \n\n";
cout<<"\t\t\t尊敬的 "<<playername<<" 您好\n"; cout<<"\t\t\t您一共有现金: "<<Money<<"\t\n"; cout<<"\t\t\t\t\t\t\t\n";
cout<<"\t\t\t\t1.开始游戏 \n"; cout<<"\t\t\t\t2.升级用户 \n"; cout<<"\t\t\t\t3.用户退出 \n"; cout<<"\t\t\t\t4.游戏退出 \n\n\n";
cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷\n"; Sleep(1000); game.InputMenu(); game.cls();
game.SelectMenu2(); }
void Display::BeginFail(int a,int b)// {
game.cls(); cout<<"\n\n\n\n\n";
cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ 登 录 失 败 ! ∷\n"; cout<<"\t\t∷ ∷\n"; if(a) { }
cout<<"\t\t∷ 请按任意键继续 ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷ ∷\n"; cout<<"\t\t∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷∷\n&quo …… 此处隐藏:1388字,全部文档内容请下载后查看。喜欢就下载吧 ……
相关推荐:
- [小学教育]四年级综合实践活动课《衣物的洗涤》教
- [小学教育]2014半年工作总结怎么写
- [小学教育]20世纪外国文学专题综合试题及答案
- [小学教育]TS_1循环使用催化丙烯环氧化反应研究
- [小学教育]最实用的考勤签到表(上下班签到表)
- [小学教育]气候与生态建筑——以新疆民居为例
- [小学教育]二人以上股东有限责任公司章程参考样本
- [小学教育]2014届第一轮复习资料4.1,3美好生活的
- [小学教育]土方开挖、降水方案
- [小学教育]手绘儿童绘本《秋天的图画》(蜡笔)
- [小学教育]2002级硕士研究生卫生统计学考试试题
- [小学教育]环保装备重点发展目录
- [小学教育]金蝶K3合并报表培训教材
- [小学教育]岩浆岩试题及参考答案
- [小学教育]知之深爱之切学习心得
- [小学教育]第十二章 蛋白质的生物合成
- [小学教育]Chapter 2-3 Solid structure and basi
- [小学教育]市政道路雨季专项施工方案
- [小学教育]中国海洋大学2012-2013学年第二学期天
- [小学教育]教育心理学第3章-学习迁移
- 浅谈深化国企改革中加强党管企业
- 2006年中国病理生理学会学术活动安排
- 设计投标工作大纲
- 基于ARP的网络攻击与防御
- 2016届湖北省七市(州)教科研协作体高三
- Google_学术搜索及其检索技巧
- 2019-2020学年七年级地理下册6.3美洲教
- 城市道路可研报告
- 【名师指津】2012高考英语 写作基础技
- 6级知识点培训北京师范大学《幼儿智趣
- 注册会计师会计知识点:金融资产
- 新安装 500 kV 变压器介损分析与判断
- PS2模拟器PCSX2设置及使用教程.
- 医院药事管理与药剂科管理组织机构
- {PPT背景素材}丹巴的醉人美景,免费,一
- NAS网络存储应用解决方案
- 青海省西宁市六年级上学期数学期末考试
- 测量管理体系手册依据ISO10012:2003
- 洞子小学培养骨干教师工作计划
- 浅谈《牛津初中英语》的教材特点及教学




