转和平精英(改编完善版)(C++做的吃鸡小游戏)!!!

CPP 刷题王 2021-08-14 15:58:45 2024-07-18 9:07:38 77
#include <bits/stdc++.h>
using namespace std;
int main() {
	cout << "温馨提示:" << endl;
	cout << "沉迷游戏伤眼" << endl;
	cout << "适当游戏益脑" << endl;
	puts("类似这样:");
	system("start https://s1.ax1x.com/2018/07/12/PKp28S.png");
	system("pause");
	cout << "每日签到:1个华贵君主套装,50000枚金币、10000个服饰币和1000点券。敲1签到,敲2退出每日签到。" << endl;
	cout << "答案: " << endl;
	int a;
	cin >> a;
	if (a == 1) {
		cout << "\033 [30m";
		cout << "选择海岛地图敲1,选择沙漠地图敲2,选择雪地地图敲3,选择雨林地图敲4。" << endl;
		cout << "答案: "  << endl;
		int gf;
		cin >> gf;
		if (gf == 1) {
			cout << "飞机很快就要起飞了," << endl;
			cout << "各位特种兵请准备";
			cout << "小队集结!" << endl;
		} else if (gf == 2) {
			cout << "飞机很快就要起飞了," << endl;
			cout << "各位特种兵请准备" << endl;
			cout << "小队集结!" << endl;
		} else if (gf == 3) {
			cout << "飞机很快就要起飞了," << endl;
			cout << "各位特种兵请准备" << endl;
			cout << "小队集结!" << endl;
		} else if (gf == 4) {
			cout << "飞机很快就要起飞了," << endl;
			cout << "各位特种兵请准备" << endl;
			cout << "小队集结!" << endl;
		}
	} else if (a == 2) {
		cout  << "\033 [30m";
		cout  << "选择海岛地图敲1,选择沙漠地图敲2,选择雪地地图敲3,选择雨林地图敲4。"   << endl;
		cout  << "答案"  << endl;
		int  gf;
		if ( gf  ==   1  ) {
			cout  << "飞机很快就要起飞了,"  << endl;
			cout  << "各位特种兵请准备"  << endl;
			cout  << "小队集结!"  << endl;
		}   else   if ( gf  ==   2  ) {
			cout  << "飞机很快就要起飞了,"  << endl;
			cout  << "各位特种兵请准备"  << endl;
			cout  << "小队集结!"  << endl;
		}   else   if ( gf  ==   3  ) {
			cout  << "飞机很快就要起飞了,"  << endl;
			cout  << "各位特种兵请准备"  << endl;
			cout  << "小队集结!"  << endl;
		}   else   if ( gf  ==   4  ) {
			cout  << "飞机很快就要起飞了,"  << endl;
			cout  << "各位特种兵请准备"  << endl;
			cout  << "小队集结!"  << endl;
		}
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout << "是否跳伞? " << endl;
	cout << "跳伞敲1,不跳伞敲2"  << endl;
	cout << "答案: " << endl;
	int  eq;
	cin >> eq;
	if (  eq  ==   1  ) {
		cout  << "根据航线,你落军事基地。"  << endl;
	}   else   if  (  eq  ==   2  ) {
		cout  << "\033 [309m";
		cout  << "你已飞出地图!" << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}
	cout  << "\033 [37m";
	cout  << "你已到军事基地门前。"  << endl;
	cout  << "前面是军事基地,你进不进去。"  << endl;
	cout  << "进去选1,不进去选2。"  << endl;
	cout  << "答案:"  << endl;
	int  b;
	cin >> b;
	if ( b  ==   1  ) {
		cout  << "\033 [32m";
		cout  << "你进去了,顺便也躲过了敌人的追击。"  << endl;
	}   else   if ( b  ==   2  ) {
		cout  << "\033 [31m";
		cout  << "你站在门前,被敌人用AKM突击步枪射死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "\033 [32m";
	cout  << "现在,你看到军事基地桌子上有一把M24狙击枪,可是他在一间教室里面,你怎么进去进去?"  << endl;
	cout  << "直接从门口进选1,翻窗进选2。"  << endl;
	cout  << "答案:"  << endl;
	int  c;
	cin >> c;
	if ( c  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "那是敌人的埋伏,你刚进去就被敌人用平底锅敲死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else   if ( c  ==   2  ) {
		cout  << "\033 [34m";
		cout  << "那是敌人的埋伏,翻窗进是个明智的选择。"  << endl;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,你看见敌人,敌人却没发现你。"  << endl;
	cout  << "你悄悄地走过去打他选1,先滚过去拿M24狙击枪选2。"  << endl;
	cout  << "答案:"  << endl;
	int  d;
	cin >> d;
	if ( d  ==   1  ) {
		cout  << "敌人没发现你,你用镰刀砍死了他"  << endl;
	}   else   if ( d  ==   2  ) {
		cout  << "\033 [31m";
		cout  << "你滚过去,敌人发现了你,而且M24狙击枪也没子弹。你被敌人用M416突击步枪杀死了!"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,你要出军事基地,突然,你听到军事基地大门有脚步声。"  << endl;
	cout  << "翻窗逃跑选1,从正门逃跑选2。"  << endl;
	cout  << "答案:"  << endl;
	int  e;
	cin >> e;
	if ( e  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "窗户外有埋伏,你被敌人用平底锅敲死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else   if ( e  ==   2  ) {
		cout  << "正门前面是两个人机,身上只有一把沙漠之鹰。被你用平底锅干掉了。"  << endl;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,你出不出去?"  << endl;
	cout  << "出去选1,不出去选2。"  << endl;
	cout  << "答案:"  << endl;
	int  f;
	cin >> f;
	if ( f  ==   1  ) {
		cout  << "有人在军事基地的所有房子上沾了C4炸药,你躲过了C4的轰炸。"  << endl;
	}   else   if ( f  ==   2  ) {
		cout  << "\033 [31m";
		cout  << "有人在军事基地沾上了C4,你被炸死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,毒圈来了,你要去安全区里面的R城,军事基地的前方有一辆特斯拉和一辆玛莎拉蒂。"  << endl;
	cout  << "坐特斯拉去选1,坐玛莎拉蒂选2。"  << endl;
	cout  << "答案:"  << endl;
	int  g;
	cin >> g;
	if ( g  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "特斯拉下有手雷,你刚踩油门特斯拉就爆炸了。你被炸死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else   if ( g  ==   2  ) {
		cout  << "你开玛莎拉蒂顺利地到达了R城。"  << endl;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,你在R城。"  << endl;
	cout  << "消灭敌人选1,寻找物资选2。"  << endl;
	cout  << "答案:"  << endl;
	int  h;
	cin >> h;
	if ( h  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "你现在紧缺补给品,没解决敌人,反而被敌人解决了你。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else   if ( h  ==   2  ) {
		cout  << "你现在紧缺物资,寻找物资是第一步。"  << endl;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,有一栋洋房,你进不进去?"  << endl;
	cout  << "进去选1,不进去选2。"  << endl;
	cout  << "答案:"  << endl;
	int  i;
	cin >> i;
	if ( i  ==   1  ) {
		cout  << "外面有敌人开着阿斯顿马丁,你真幸运。"  << endl;
	}   else   if ( i  ==   2  ) {
		cout  << "\033 [31m";
		cout  << "突然,一个人开着阿斯顿马丁,把你给压死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,你在房子里找到了一把98K狙击枪,200发7.62子弹,9个绷带,2个医疗箱,3瓶止疼药和3瓶能量饮料。突然,有一个全副武装的人冲进了来。"  << endl;
	cout  << "你直接跟他硬刚选1,翻窗逃跑选2。"  << endl;
	cout  << "答案:"  << endl;
	int  j;
	cin >> j;
	if ( j  ==   1  ) {
		cout  << "那个人是个新手,不知道怎么开枪,被你干掉了。你得到了他的三级套和AWM狙击枪。"  << endl;
	}   else   if ( j  ==   2  ) {
		cout  << "\033 [31m";
		cout  << "你刚落地,就被人开车轧死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,你已经拥有足够的补给品和装备。"  << endl;
	cout  << "去消灭敌人选1,苟分选2。"  << endl;
	cout  << "答案:"  << endl;
	int  k;
	cin >> k;
	if ( k  ==   1  ) {
		cout  << "你已经拥有足够的物品,消灭敌人才是胜利的关键。"  << endl;
	}   else   if ( k  ==   2  ) {
		cout  << "\033 [31m";
		cout  << "你没去消灭敌人,突然门开了,你被敌人消灭了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout << "谢谢!" << endl;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在一个空投降落在了距离你只有423米的地方。"  << endl;
	cout  << "舔选1,不舔选2。"  << endl;
	cout  << "答案:"  << endl;
	int  n;
	cin >> n;
	if ( n  ==   1  ) {
		cout  << "你在舔空投的时候,你原来的地方正在被其他玩家使用四连火箭筒轰炸,你真好运,不仅得到了吉利服,而且还躲过了轰炸。"  << endl;
	}   else   if ( n  ==   2  ) {
		cout  << "\033 [31m";
		cout  << "突然,四个火箭弹把你给炸没了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "突然,你发现那边有一群人在打杀,你现在需要采用什么方法消灭他们?"  << endl;
	cout  << "做当伏地魔捡漏选1,直接冲上去和他们刚枪选2。"  << endl;
	cout  << "答案:"  << endl;
	int  l;
	cin >> l;
	if ( l  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "突然,一辆车冲过来,把你给压死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else   if ( l  ==   2  ) {
		cout  << "敌人们还没发现你,就被你的一颗手雷炸死了。"  << endl;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在还剩15个人,突然一个空投降落在了一个离你不远的地方,你去不去舔?"  << endl;
	cout  << "舔选1,不舔选2。"  << endl;
	cout  << "答案:"  << endl;
	int  m;
	cin >> m;
	if ( m  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "突然轰炸区刷新在了那里,把你和其他舔空投的人都炸死了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else   if ( m  ==   2  ) {
		cout  << "突然轰炸区刷新在了那里,把那儿的人给炸死了。你真幸运!"  << endl;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "在一栋红色的二层楼的楼顶上有四个盒子,你去不去舔?"  << endl;
	cout  << "管他丫的直接舔选1,先观察一下再说选2。"  << endl;
	cout  << "答案:"  << endl;
	int  z;
	cin >> z;
	if ( z  ==   2  ) {
		cout  << "你在观察中,发现了有四个满编队非法组队,你及时举报了他们,他们最后都被封号了5年,你把他们都消灭了。"  << endl;
	}   else   if ( z  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "突然,你们队的右边,前面和后面的玩家把你们团灭了。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "你已成为第一个淘汰王!"  << endl;
	cout  << "现在,毒圈又刷新了,安全区离你只有250米,你要不要去安全区?"  << endl;
	cout  << "去选1,不去选2。"  << endl;
	cout  << "答案:"  << endl;
	int  o;
	cin >> o;
	if ( o  ==   1  ) {
		cout  << "你成功爬到了安全区。"  << endl;
	}   else   if ( o  ==   2  ) {
		cout  << "\033 [31m";
		cout  << "毒圈里的毒很痛,所有人都到达了安全区!你在毒圈里还没有来得及打药就挂了!"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,你看见一个身穿火箭少女的玩家在一栋楼的旁边,你怎么消灭他?"  << endl;
	cout  << "直接莽选1,信仰之跃选2。"  << endl;
	cout  << "答案:"  << endl;
	int  p;
	cin >> p;
	if ( p  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "你成为了敌人的猎物,敌人用手雷让你去坐了下一班飞机。"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;

	}   else   if ( p  ==   2  ) {
		cout  << "敌人没发现你,你不仅把他击杀了还获得了你一直想要的套装---火箭少女。"  << endl;
	}   else {
		cout  << "\033 [31m";
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "现在,毒圈又要来了,你要跑毒吗?"  << endl;
	cout  << "跑选1,不跑选2。"  << endl;
	cout  << "答案:"  << endl;
	int  r;
	cin >> r;
	if ( r  ==   1  ) {
		cout  << "\033 [31m";
		cout  << "安全区那儿是轰炸区,你被炸死了!最终只吃了个鸡屁股!"  << endl;
		cout  << "再接再厉,下次吃鸡。"  << endl;
		cout  << "谢谢!"  << endl;
		return 0;
	}   else   if ( r  ==   2  ) {
		cout  << "安全区那儿是轰炸区,肯定不能进去。"  << endl;
		cout  << "因为所有人都去跑毒了,所以全被炸死了,你掐鸡了。"  << endl;
	}   else {
		cout  << "游戏自动判错,"  << endl;
		cout  << "请重做!"  << endl;
		return 0;
	}
	cout  << "你不仅第二次又吃鸡了,还打破了纪录---你淘汰了39个人,真棒。"  << endl;
	cout  << endl;
	cout  << "你原本还差5分就上了无敌战神段位,你这次掐了鸡,所以你上了无敌战神段位!!!" << endl;
	cout  << endl;
	cout  << "恭喜!!!"  << endl;
	cout  << endl;
	cout  << "再见!下次再来!!!"  << endl;
	cout  << endl;
	return 0;
}
{{ vote && vote.total.up }}

共 13 条回复

root 站长

自己去看我给你代码加了啥。

test 测试

6牛逼

CPP 刷题王

我做的好吗??