#include<bits/stdc++.h>
#include<time.h>
#include<windows.h>
using namespace std;
int know=0,cnt=0,x=50,y=50,rw=0;
string a[101]={
"******************************** ******************************** ********************************",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"*************** *************** *************** *************** **************** **************",
" ",
" ",
"*************** *************** **************** **************",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"* * * *",
"*************** *************** *************** ***************",
" ",
" ",
"*************** *************** *************** *************** *************** ***************",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"* * * * * *",
"******************************** ******************************** ********************************"};
void slowout(char *p){
while(1){
if(*p!=0)printf("%c",*p++);
else break;
Sleep(5);
}
}
void SetPos(int x,int y){
COORD pos;
pos.X=y*2,pos.Y=x;
SetConsoleCursorPosition(GetStdHandle(STD_OUTPUT_HANDLE),pos);
}
int js(int x,int y){
if(0<=x&&x<=31){
if(y<=31)return 1;
else if(34<=y&&y<=65)return 2;
else if(y>=68)return 3;
}else if(34<=x&&x<=65){
if(y<=31)return 4;
else if(y>=68)return 5;
}else if(68<=x&&x<=99){
if(y<=31)return 6;
else if(34<=y&&y<=65)return 7;
else if(y>=68)return 8;
}
return 0;
}
void game1(){
Sleep(1000);
slowout("你TM好啊!来领乐器的吧?\n");
slowout("1、新年好!\n");
slowout("2、是的\n");
slowout("注:以第二次为准\n");
string c;cin>>c;
int p;cin>>p;
if(p==1){
slowout("操你妈!\n");
system("pause");
system("cls");
return;
}else if(p==2){
slowout("好~~~那,开始吧!这里一共10种乐器,你随机拿一个,拿对了,就可以走啦!\n");
slowout("请输入你要拿第几个乐器:");
cin>>p;int tmp=rand()%10+1;
if(p==20270003){
slowout("开始调试吧?\n");
rw=-1;
system("pause");
system("cls");
return;
}
if(p==tmp){
slowout("\n霍!~~竟然对了!走吧!\n");
slowout("去空地演奏吧!!\n");
rw=-1;
}else{
slowout("菜,就多练!\n");
slowout("是:第");
Sleep(200);
cout<<tmp;
slowout("个!\n");
}
system("pause");
system("cls");
}else{
slowout("吃鸡吧!\n");
system("pause");
system("cls");
return;
}
}
void game_1(){
slowout("你……拿到乐器了,对吧?\n");
system("pause");
system("cls");
slowout("现在,开始演奏吧?\n");
system("pause");
system("cls");
slowout("等下我会把谱子告诉你,你需要在十秒钟内背完,然后输出哦?\n");
system("pause");
system("cls");
slowout("背诵……开始!\n");
int rd=rand()%31+10;
string ans,gbt;
for(int i=1;i<=rd;++i){
char p=(char)(rand()%26+'A');
ans+=p;
}
cout<<ans<<endl;
Sleep(10000);
system("cls");
slowout("现在,开始输出吧!\n");
cin>>gbt;
if(ans==gbt){
slowout("你好牛逼啊!!\n");
slowout("现在,去二号楼放松一下吧!\n");
rw=2;
}else{
slowout("菜,就多练!\n");
}
system("pause");
system("cls");
}
int yu,fang,shan,quan[6],ji[6],ma[6],zhu[6],chuo[6],dian[6],ha,shuai,deng,zhong,fei[3],jiao[3],zhan[3],dong[3],sg=0,zz=0;
bool vis[1000];
void game2(){
slowout("你好~~我是二号楼的理!你是来放松的吧?\n");
slowout("1、是\n");
slowout("2、什么勾八名字?\n");
slowout("注:以第二次为准\n");
string c;cin>>c;
int p;cin>>p;
if(p==1){
slowout("ok!\n");
slowout("首先,我们的这个游戏呢……叫储器,你需要规则吗?\n");
slowout("1、显然啊!\n");
slowout("2、不用,我了解\n");
int kkk;cin>>kkk;
if(kkk==1){
system("start http://hfoj.net/blog/1981/680b945094662a9af6d24893");
system("start http://10.80.74.11/blog/1981/680b945094662a9af6d24893");
slowout("发你了~~看到了吗?\n");
}else{
slowout("好吧,游戏……开始!\n");
}
}else if(p==2){
slowout("显然,这个名字很好听啊?\n");
slowout("1、是……这样吗?\n");
slowout("2、是……这样吗?\n");
slowout("3、是……这样吗?\n");
int kkk;cin>>kkk;
if(kkk==1||kkk==2||kkk==3){
slowout("那可不!\n");
}
if(kkk==20270003){
slowout("额……其实一号楼的那位叫H,奇怪不?\n");
}
system("pause");
system("cls");
return;
}
system("pause");
system("cls");
slowout("首先~~就是首先~~\n");
slowout("啊!串台了。你现在需要进行一轮训练:击杀一个有20个钟的靶子,对方每回合都会举报你(乐)。\n");
slowout("同时,你不可以绝杀,它被禁了(悲)\n");
system("pause");
system("cls");
int dz=20,dd=0;
while(dz+dd>0){
int jb=0;
double g=0;
cout<<"这回合,你可以:"<<endl;
cout<<"1、玉"<<endl,vis[1]=true;
cout<<"2、防"<<endl,vis[2]=true;
cout<<"3、闪"<<endl,vis[3]=true;
cout<<"4、甩剑"<<endl,vis[4]=true;
if(ha!=3)cout<<"5、哈哈"<<endl,vis[5]=true;
if(sg==0)cout<<"6、上挂"<<endl,vis[6]=true;
else cout<<"7、下挂"<<endl,vis[7]=true;
cout<<"8、举报"<<endl,vis[8]=true;
if(yu>=3)cout<<"9、重拳"<<endl,vis[9]=true;
if(quan[1]>=2)cout<<"10、天地"<<endl,vis[10]=true;
if(quan[2]>=2)cout<<"11、无相"<<endl,vis[11]=true;
if(yu>=2&&fang>=2)cout<<"12、暴击"<<endl,vis[12]=true;
if(ji[1]>=2)cout<<"13、重击"<<endl,vis[13]=true;
if(ji[2]>=2)cout<<"14、痛击"<<endl,vis[14]=true;
if(quan[3]>=1||ji[3]>=1)cout<<"15、马丁"<<endl,vis[15]=true;
if(ma[1]==1)cout<<"16、百变马丁"<<endl,vis[16]=true;
if(yu>=2)cout<<"17、小猪"<<endl,vis[17]=true;
if(zhu[1]>=2)cout<<"18、中猪"<<endl,vis[18]=true;
if(zhu[2]>=2)cout<<"19、大猪"<<endl,vis[19]=true;
if(zhu[3]>=1)cout<<"20、吴猪"<<endl,vis[20]=true;
if(zhu[4]==1)cout<<"21、聪明吴猪"<<endl,vis[21]=true;
if(yu>=1)cout<<"22、戳"<<endl,vis[22]=true;
if(chuo[1]>=2)cout<<"23、千年"<<endl,vis[23]=true;
if(chuo[2]==1)cout<<"24、万年"<<endl,vis[24]=true;
if(chuo[3]==1)cout<<"25、亿年"<<endl,vis[25]=true;
if(shan>=3)cout<<"26、小电"<<endl,vis[26]=true;
if(dian[1]>=2)cout<<"27、中电"<<endl,vis[27]=true;
if(dian[2]>=2)cout<<"28、大电"<<endl,vis[28]=true;
if(dian[3]==1)cout<<"29、雷神"<<endl,vis[29]=true;
if(shuai>=5)cout<<"30、狒狒"<<endl,vis[30]=true;
if(fei[1]>=2)cout<<"31、暗黑狒狒"<<endl,vis[31]=true;
if(jiao[1]>=1)cout<<"32、蕉蕉"<<endl,vis[32]=true;
if(jiao[2]>=1)cout<<"33、暗黑蕉蕉"<<endl,vis[33]=true;
if(yu>=1&&fang>=1)cout<<"34、斩"<<endl,vis[34]=true;
if(zhan[1]>=2)cout<<"35、元气"<<endl,vis[35]=true;
if(zhan[2]>=1&&zz==1)cout<<"36、猪油斩"<<endl,vis[36]=true;
if(yu>=4)cout<<"37、黑洞"<<endl,vis[37]=true;
if(dong[1]>=1&&shuai>=2)cout<<"38、白洞"<<endl,vis[38]=true;
if(dong[2]>=1&&dong[1]>=1)cout<<"39、虫洞"<<endl,vis[39]=true;
if(fang>=2)cout<<"40、盾"<<endl,vis[40]=true;
if(deng>=2)cout<<"41、钟"<<endl,vis[41]=true;
int p;
while(true){
cin>>p;
if(p>=1&&p<=41){
if(vis[p])break;
}
cout<<"傻逼!"<<endl;
system("pause");
}
if(p!=5)ha=0;
if(p==1)cout<<"千年的古玉被你握在了手中……保护好它"<<endl,yu+=2;
else if(p==2)cout<<"无形的屏障展开……不要辜负祂的好心"<<endl,fang+=2;
else if(p==3)cout<<"你感到全身都轻盈起来……步伐都快了"<<endl,shan+=2;
else if(p==4)cout<<"那沉重的大剑导致你破绽百出……"<<endl,shuai+=2;
else if(p==5)cout<<"对!继续挑衅!"<<endl,ha++;
else if(p==6)cout<<"嘿!接着!这力量可不是没有代价地~~"<<endl,sg=1;
else if(p==7)cout<<"这一步棋确实不错"<<endl,sg=0;
else if(p==8)cout<<"可以成功吗?"<<endl,jb=1;
else if(p==9)cout<<"重拳出击!"<<endl,g=0.5,quan[1]++,yu-=3;
else if(p==10)cout<<"你打出了蕴含天地之力的一拳!"<<endl,g=1,quan[2]++,quan[1]-=2;
else if(p==11)cout<<"这可是神话中的力量——无相!"<<endl,g=2,quan[3]++,quan[2]-=2;
else if(p==12)cout<<"你的攻击带着爆炸性的力量打了过去……"<<endl,g=0.51,ji[1]++,yu-=2,fang-=2;
else if(p==13)cout<<"这一下,七千斤重量!"<<endl,g=1,ji[2]++,ji[1]-=2;
else if(p==14)cout<<"撕——之前我被这一击打过,很疼"<<endl,g=2,ji[3]++,ji[2]-=2;
else if(p==15){
cout<<"下一步,你要打出那一击吗?"<<endl;
g=4,ma[1]=1;
if(quan[3]!=0)quan[3]--;
else ji[3]--;
}else if(p==16)cout<<"恐怖的力量杀了出来!!!"<<endl,g=8;
else if(p==17)cout<<"这是一头……小肥猪!"<<endl,zhu[1]++,yu-=2,g=0.5;
else if(p==18)cout<<"这是一头……中等大小的肥猪"<<endl,zhu[2]++,zhu[1]-=2,g=1;
else if(p==19)cout<<"这是一头……大肥猪!"<<endl,zhu[3]++,zhu[2]-=2,g=2;
else if(p==20)cout<<"这是一头吴国神猪!"<<endl,zhu[4]=1,zhu[3]--,g=4;
else if(p==21)cout<<"这是一头聪明的吴国肥猪!"<<endl,g=8;
else if(p==22)cout<<"来来来,我与你插"<<endl,chuo[1]++,yu--,g=0.5;
else if(p==23)cout<<"你向着他的要害攻去"<<endl,chuog=0.5;
e
system("pause");
system("cls");
}
}
void game(){
if(know==0){
if(cnt==0){
SetPos(20,18),cout<<"空地"<<endl;
}else{
SetPos(20,18),cout<<cnt<<" 号楼"<<endl;
}
know=1;
Sleep(1000);
system("cls");
}
while(rw==cnt||(cnt==0&&rw<0)){
if(rw==1)game1();
else if(rw==-1)game_1();
else if(rw==2)game2();
}
while(true){
if(GetAsyncKeyState(77)&0x8000&&x!=0){
cout<<"******** ******** ********"<<endl;
cout<<"* * * * * *"<<endl;
cout<<"* * * * * *"<<endl;
cout<<"*一号楼* *二号楼* *三号楼*"<<endl;
cout<<"* * * * * *"<<endl;
cout<<"* * * * * *"<<endl;
cout<<"***门*** ***门*** ***门***"<<endl;
cout<<" "<<endl;
cout<<"***门*** ***门***"<<endl;
cout<<"* * * *"<<endl;
cout<<"* * * *"<<endl;
cout<<"*四号楼* *五号楼*"<<endl;
cout<<"* * * *"<<endl;
cout<<"* * * *"<<endl;
cout<<"***门*** ***门***"<<endl;
cout<<" "<<endl;
cout<<"***门*** ***门*** ***门***"<<endl;
cout<<"* * * * * *"<<endl;
cout<<"* * * * * *"<<endl;
cout<<"*六号楼* *七号楼* *八号楼*"<<endl;
cout<<"* * * * * *"<<endl;
cout<<"* * * * * *"<<endl;
cout<<"******** ******** ********"<<endl;
cout<<" "<<endl;
cout<<endl<<endl;;
cout<<"按WDSA可以移动"<<endl;
Sleep(100);
system("cls");
continue;
}
if(GetAsyncKeyState(87)&0x8000&&x!=0){
if(a[x-1][y]!='*')x--;
}
if(GetAsyncKeyState(83)&0x8000&&x!=99){
if(a[x+1][y]!='*')x++;
}
if(GetAsyncKeyState(65)&0x8000&&y!=0){
if(a[x][y-1]!='*')y--;
}
if(GetAsyncKeyState(68)&0x8000&&y!=99){
if(a[x][y+1]!='*')y++;
}
int tmp=js(x,y);
if(cnt!=js(x,y)){
cnt=js(x,y);know=0;
return;
}
int cntx=x-20,cnty=y-40;//偏移率
for(int i=0;i<40;++i){
for(int j=0;j<80;++j){
int nx=i+cntx,ny=j+cnty;
if(nx<0||ny<0||nx>=100||ny>=100)cout<<" ";
else cout<<a[nx][ny];
}
if(i!=39)cout<<endl;
}
SetPos(20,20),cout<<"#";
Sleep(10);
system("cls");
}
}
int main(){
srand(time(0));
CONSOLE_CURSOR_INFO cursor_info={1,0};
SetConsoleCursorInfo(GetStdHandle(STD_OUTPUT_HANDLE),&cursor_info);
system("mode con cols=80 lines=40");
slowout("无心之举\n");
slowout(" ——CMY\n");
system("pause");
system("cls");
slowout("0:额……这里……是哪啊…………\n");
slowout("0:为什么……脑子这么晕啊……\n");
system("pause");
system("cls");
slowout("演出开始!你又在等什么呢?\n");
slowout("1:我的乐器呢??!\n");
slowout("2:你他妈是谁???\n");
int tmp;cin>>tmp;
if(tmp==1){
slowout("咳咳……请你到 1 号楼领取乐器\n");
}else if(tmp==2){
slowout("额……请文明一点,请到 1 号楼领取乐器\n");
slowout("还有,我叫K\n");
}else{
slowout("你……好牛逼啊!\n");
Sleep(2000);
while(true)malloc(114514);
}
system("pause");
system("cls");
rw=2;
slowout("哦,对了。由于你是初来乍到,所以你按 M 可以看规则与地图\n");
system("pause");
system("cls");
while(true)game();
return 0;
}