生活大冒险
seanxlx
·
·
个人记录
#include<bits/stdc++.h>
#include<windows.h>
#include<conio.h>
using namespace std;
long long hp, ap, dp;
long long hf, dx, fs, hd; //恢复 毒性 附伤 护盾
long long level; //星空殿堂等级 1-5行星 6-10恒星 11-15宇宙 16-20不朽
long long yl; //原力强度 (护盾 防止对生命造成的伤害)
double BJ; //攻击暴击概率(100%以上视为100%)(攻击伤害x4且无视50%敌方护甲)
double FH; //死亡复活概率(100%以上视为100%)(只能复活一次且复活血量为50%)
long long t[6][6]; //副本(t[i][j] = 第i章i-j关已击败的敌人数量)
long long tx; //轮回副本通关层数(每层有12个敌人 需要一次性打完)
long long gold, tlt, ss; //金币 天赋点 神识
long long talent[3]; //天赋(攻 防 血)等级
long long jc; //冒险剧场章节数
long long pkp;
bool boss1; //时空碎片一层BOSS
void SetPos(int x, int y)
{
COORD pos = {x, y};
HANDLE hOut = GetStdHandle(STD_OUTPUT_HANDLE);
SetConsoleCursorPosition(hOut, pos);
}
long long random(long long a, long long b)
{
return (((long long)rand() * rand() * rand() * rand()) % (a - b)) + a;
}
double random_01()
{
return rand() % 100 / float(100);
}
void Color(long long a)
{
//白
if(a==0) SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),FOREGROUND_INTENSITY|FOREGROUND_RED|FOREGROUND_GREEN|FOREGROUND_BLUE);
//绿
if(a==1) SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),FOREGROUND_INTENSITY|FOREGROUND_GREEN);
//红
if(a==2) SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),FOREGROUND_INTENSITY|FOREGROUND_RED);
//蓝
if(a==3) SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),FOREGROUND_INTENSITY|FOREGROUND_BLUE);
//粉
if(a==4) SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),FOREGROUND_INTENSITY|FOREGROUND_RED|FOREGROUND_BLUE);
//黄
if(a==5) SetConsoleTextAttribute(GetStdHandle(STD_OUTPUT_HANDLE),FOREGROUND_INTENSITY|FOREGROUND_RED|FOREGROUND_GREEN);
}
char input()
{
while(1)
{
if(_kbhit())
{
return _getch();
}
}
}
char input(char left, char right)
{
while(1)
{
char x = input();
if(x >= left && x <= right) return x;
}
}
void init()
{
hp = 0;
ap = 0;
dp = 0;
hf = 0;
dx = 0;
fs = 0;
hd = 0;
BJ = 0.0;
FH = 0.0;
yl = 0;
gold = tlt = ss = 0;
for(long long i = 0;i < 6;i++)
{
for(long long j = 0;j < 6;j++) t[i][j] = 0;
}
for(long long i = 0;i < 3;i++) talent[i] = 0;
tx = jc = 0;
boss1 = false;
}
void INS()
{
ifstream findt("data.txt");
ifstream fintm("temple.txt");
ifstream fintl("talent.txt");
ifstream finth("theater.txt");
ifstream finmj("mijing.txt");
if(findt.is_open() && fintm.is_open() && fintl.is_open()
&& finth.is_open())
{
findt >> hp >> ap >> dp >> hf >> dx >> fs >> hd >> BJ >> FH >> level;
findt >> gold >> tlt >> ss;
findt >> yl;
for(long long i = 1;i < 6;i++)
{
for(long long j = 0;j < 6;j++)
{
fintm >> t[i][j];
}
}
fintm >> tx;
for(long long i = 0;i < 3;i++) fintl >> talent[i];
finth >> jc;
finmj >> boss1;
}
else
{
cout << "ERROR IN" << endl;
system("pause");
exit(1);
}
}
void OUTS()
{
ofstream foutdt("data.txt");
ofstream fouttm("temple.txt");
ofstream fouttl("talent.txt");
ofstream foutth("theater.txt");
ofstream foutmj("mijing.txt");
if(foutdt.is_open() && fouttm.is_open() && fouttl.is_open()
&& foutth.is_open())
{
foutdt << hp << endl << ap << endl << dp << endl << hf << endl << dx << endl << fs << endl << hd << endl << BJ << endl << FH << endl;
foutdt << level << endl << gold << endl << tlt << endl << ss << endl;
foutdt << yl << endl;
for(long long i = 1;i < 6;i++)
{
for(long long j = 0;j < 6;j++)
{
fouttm << t[i][j] << endl;
}
}
fouttm << tx << endl;
for(long long i = 0;i < 3;i++) fouttl << talent[i] << endl;
foutth << jc << endl;
foutmj << boss1 << endl;
}
else
{
cout << "ERROR OUT" << endl;
system("pause");
exit(1);
}
}
bool pk(long long ehp, long long eap, long long edp, long long ehf, long long edx, long long efs, long long ehd, double eFH)
{
long long ehp_h = ehp, hhp_h = hp;
long long hyl = yl; //剩余的原力
long long hyl_hh = 4; //原力剩余的回合数
long long hdsycs = hd, ehdsycs = ehd; //护盾剩余次数
bool fh = false, efh = false; //是否已经复活过
long long hhp = hp, hap = ap, hdp = dp;
while(hhp >= 0 && ehp >= 0)
{
Sleep(200);
if(hyl_hh >= 0) hyl_hh--;
system("cls");
SetPos(0, 0);
if(hyl_hh > 0 && hyl >= 0)
{
cout << "我方原力";
for(long long i = 0;i < max(0ll, hyl / (yl / 20)) && i < 20;i++)
{
Color(3), cout << "█";
}
for(long long i = max(0ll, hyl / (yl / 20));i < 20;i++)
{
Color(1), cout << "█";
}
}
else
{
cout << "我方血量";
for(long long i = 0;i < max(0ll, hhp / (hhp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, hhp / (hhp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
}
cout << endl;
Color(0);
cout << "敌方血量";
for(long long i = 0;i < max(0ll, ehp / (ehp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, ehp / (ehp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
cout << endl;
Color(0);
Sleep(200);
cout << endl;
SetPos(0, 3);
if(random_01() <= BJ) //特判暴击
{
ehp -= (hap * 4 - edp / 2) + fs;
Color(5), cout << "我方对敌方发起暴击 威力无比 造成伤害" << (hap * 4 - edp / 2) << "点" << endl;
Color(0);
if(fs >= 1) cout << "附加伤害" << fs << "点" << endl;
}
else if(ehdsycs != 0)
{
ehp -= fs;
Color(2), cout << "敌方使用护盾挡下了我方的攻击" << endl;
Color(0);
if(fs >= 1) cout << "附加伤害" << fs << "点" << endl;
ehdsycs--;
}
else
{
ehp -= (hap - edp) + fs;
cout << "我方对敌方发起攻击 造成伤害" << (hap - edp) << "点" << endl;
if(fs >= 1) cout << "附加伤害" << fs << "点" << endl;
}
Sleep(200);
SetPos(0, 0);
if(hyl_hh > 0 && hyl >= 0)
{
cout << "我方原力";
for(long long i = 0;i < max(0ll, hyl / (yl / 20)) && i < 20;i++)
{
Color(3), cout << "█";
}
for(long long i = max(0ll, hyl / (yl / 20));i < 20;i++)
{
Color(1), cout << "█";
}
}
else
{
cout << "我方血量";
for(long long i = 0;i < max(0ll, hhp / (hhp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, hhp / (hhp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
}
cout << endl;
Color(0);
cout << "敌方血量";
for(long long i = 0;i < max(0ll, ehp / (ehp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, ehp / (ehp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
cout << endl;
Color(0);
SetPos(0, 6);
if(hyl_hh > 0 && hyl > 0)
{
hyl -= (eap - hdp) + efs;
Color(3), cout << "我方使用原力挡下了敌方的攻击" << endl;
Color(0);
cout << "原力总消耗 " << (eap - hdp) + efs << " 点";
}
else if(hdsycs != 0)
{
hhp -= efs;
Color(2), cout << "我方使用护盾挡下了敌方的攻击" << endl;
Color(0);
if(efs >= 1) cout << "附加伤害" << efs << "点" << endl;
hdsycs--;
}
else
{
hhp -= (eap - hdp) + efs;
cout << "敌方对我方发起攻击 造成伤害" << (eap - hdp) << "点" << endl;
if(efs >= 1) cout << "附加伤害" << efs << "点" << endl;
}
Sleep(200);
SetPos(0, 0);
if(hyl_hh > 0 && hyl >= 0)
{
cout << "我方原力";
for(long long i = 0;i < max(0ll, hyl / (yl / 20)) && i < 20;i++)
{
Color(3), cout << "█";
}
for(long long i = max(0ll, hyl / (yl / 20));i < 20;i++)
{
Color(1), cout << "█";
}
}
else
{
cout << "我方血量";
for(long long i = 0;i < max(0ll, hhp / (hhp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, hhp / (hhp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
}
cout << endl;
Color(0);
cout << "敌方血量";
for(long long i = 0;i < max(0ll, ehp / (ehp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, ehp / (ehp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
cout << endl;
Color(0);
SetPos(0, 9);
ehp -= dx;
if(dx >= 1) Color(1), cout << "敌方受到毒伤害" << dx << "点" << endl;
hhp -= edx;
if(edx >= 1 && (hyl_hh == 0 || hyl < 0)) Color(1), cout << "我方受到毒伤害" << edx << "点" << endl;
else if(hyl_hh > 0 && hyl >= 0) Color(3), cout << "我方存有原力 百毒不侵!!!" << endl;
Color(0);
Sleep(200);
SetPos(0, 0);
if(hyl_hh > 0 && hyl >= 0)
{
cout << "我方原力";
for(long long i = 0;i < max(0ll, hyl / (yl / 20)) && i < 20;i++)
{
Color(3), cout << "█";
}
for(long long i = max(0ll, hyl / (yl / 20));i < 20;i++)
{
Color(1), cout << "█";
}
}
else
{
cout << "我方血量";
for(long long i = 0;i < max(0ll, hhp / (hhp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, hhp / (hhp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
}
cout << endl;
Color(0);
cout << "敌方血量";
for(long long i = 0;i < max(0ll, ehp / (ehp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, ehp / (ehp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
cout << endl;
Color(0);
SetPos(0, 12);
hhp += hf;
if(hf >= 1) cout << "我方恢复血量" << hf << "点" << endl;
ehp += ehf;
if(ehf >= 1) cout << "敌方恢复血量" << ehf << "点" << endl;
Sleep(200);
SetPos(0, 0);
if(hyl_hh > 0 && hyl >= 0)
{
cout << "我方原力";
for(long long i = 0;i < max(0ll, hyl / (yl / 20)) && i < 20;i++)
{
Color(3), cout << "█";
}
for(long long i = max(0ll, hyl / (yl / 20));i < 20;i++)
{
Color(1), cout << "█";
}
}
else
{
cout << "我方血量";
for(long long i = 0;i < max(0ll, hhp / (hhp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, hhp / (hhp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
}
cout << endl;
Color(0);
cout << "敌方血量";
for(long long i = 0;i < max(0ll, ehp / (ehp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, ehp / (ehp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
cout << endl;
Color(0);
SetPos(0, 15);
//判定复活
if(hhp < 0)
{
if(random_01() < FH && !fh)
{
Color(5), cout << "我方复活 血量恢复到50%" << endl;
hhp = hhp_h / 2;
fh = true;
}
}
if(ehp < 0)
{
if(random_01() < eFH && !efh)
{
Color(5), cout << "敌方复活 血量恢复到50%" << endl;
ehp = ehp_h / 2;
efh = true;
}
}
SetPos(0, 0);
if(hyl_hh > 0 && hyl >= 0)
{
cout << "我方原力";
for(long long i = 0;i < max(0ll, hyl / (yl / 20)) && i < 20;i++)
{
Color(3), cout << "█";
}
for(long long i = max(0ll, hyl / (yl / 20));i < 20;i++)
{
Color(1), cout << "█";
}
}
else
{
cout << "我方血量";
for(long long i = 0;i < max(0ll, hhp / (hhp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, hhp / (hhp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
}
cout << endl;
Color(0);
cout << "敌方血量";
for(long long i = 0;i < max(0ll, ehp / (ehp_h / 20)) && i < 20;i++)
{
Color(1), cout << "█";
}
for(long long i = max(0ll, ehp / (ehp_h / 20));i < 20;i++)
{
Color(0), cout << "█";
}
cout << endl;
Color(0);
}
SetPos(0, 15);
if(hhp < 0) return false;
else return true;
}
void temple1(long long x)
{
if(x == 0 && t[1][0] < 1)
{
bool win = pk(100, 40, 20, 0, 0, 0, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x1000" << endl;
gold += 1000;
t[1][0]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 1 && t[1][0] == 1 && t[1][1] < 1)
{
bool win = pk(145, 65, 30, 0, 5, 5, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x1000" << endl;
gold += 1000;
t[1][1]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 2 && t[1][1] == 1 && t[1][2] < 1)
{
bool win = pk(180, 90, 45, 0, 10, 10, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x10000" << endl;
gold += 10000;
t[1][2]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 3 && t[1][2] == 1 && t[1][3] < 1)
{
bool win = pk(250, 125, 60, 5, 15, 15, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x5000" << endl;
gold += 5000;
t[1][3]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 4 && t[1][3] == 1 && t[1][4] < 1)
{
bool win = pk(400, 200, 100, 25, 25, 25, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x5000" << endl;
gold += 5000;
t[1][4]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 5 && t[1][4] == 1 && t[1][5] < 1)
{
bool win = pk(660, 330, 165, 40, 35, 35, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x10000" << endl;
gold += 10000;
t[1][5]++;
}
else
{
cout << "战斗失败" << endl;
}
}
system("pause");
}
void temple2(long long x)
{
if(x == 0 && t[1][5] == 1 && t[2][0] < 3)
{
bool win = pk(1000, 500, 250, 60, 50, 50, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x10000" << endl;
gold += 10000;
t[2][0]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 1 && t[2][0] == 3 && t[2][1] < 3)
{
bool win = pk(1400, 700, 350, 80, 75, 75, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x10000" << endl;
gold += 10000;
t[2][1]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 2 && t[2][1] == 3 && t[2][2] < 3)
{
bool win = pk(2400, 1200, 600, 120, 150, 150, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x10000" << endl;
gold += 10000;
t[2][2]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 3 && t[2][2] == 3 && t[2][3] < 3)
{
bool win = pk(4000, 2000, 1000, 180, 250, 250, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x10000" << endl;
gold += 10000;
t[2][3]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 4 && t[2][3] == 3 && t[2][4] < 3)
{
bool win = pk(5000, 2500, 1250, 210, 300, 300, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x10000" << endl;
gold += 10000;
t[2][4]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 5 && t[2][4] == 3 && t[2][5] < 3)
{
bool win = pk(7200, 3600, 1800, 280, 360, 360, 0, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x10000" << endl;
gold += 10000;
t[2][5]++;
}
else
{
cout << "战斗失败" << endl;
}
}
system("pause");
}
void temple3(long long x)
{
if(x == 0 && t[2][5] == 3 && t[3][0] < 5)
{
bool win = pk(9000, 9000, 2250, 1400, 450, 450, 1, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x15000" << endl;
gold += 15000;
t[3][0]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 1 && t[3][0] == 5 && t[3][1] < 5)
{
bool win = pk(12000, 12000, 3000, 1680, 500, 500, 1, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x15000" << endl;
gold += 15000;
t[3][1]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 2 && t[3][1] == 5 && t[3][2] < 5)
{
bool win = pk(15400, 15400, 3850, 3200, 600, 600, 1, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x15000" << endl;
gold += 15000;
t[3][2]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 3 && t[3][2] == 5 && t[3][3] < 5)
{
bool win = pk(24000, 24000, 6000, 4000, 720, 720, 1, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x15000" << endl;
gold += 15000;
t[3][3]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 4 && t[3][3] == 5 && t[3][4] < 5)
{
bool win = pk(30000, 30000, 7500, 5600, 900, 900, 1, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x20000" << endl;
gold += 20000;
t[3][4]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 5 && t[3][4] == 5 && t[3][5] < 5)
{
bool win = pk(48000, 32000, 16000, 8800, 1400, 1400, 1, 0.0);
if(win)
{
cout << "战斗胜利 获得金币x20000" << endl;
gold += 20000;
t[3][5]++;
}
else
{
cout << "战斗失败" << endl;
}
}
system("pause");
}
void temple4(long long x)
{
if(x == 0 && t[3][5] == 5 && t[4][0] < 5)
{
bool win = pk(60000, 40000, 20000, 12400, 1600, 1600, 1, 0.03);
if(win)
{
cout << "战斗胜利 获得金币x30000" << endl;
gold += 30000;
t[4][0]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 1 && t[4][0] == 5 && t[4][1] < 5)
{
bool win = pk(78000, 52000, 26000, 16800, 2000, 2000, 1, 0.05);
if(win)
{
cout << "战斗胜利 获得金币x30000" << endl;
gold += 30000;
t[4][1]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 2 && t[4][1] == 5 && t[4][2] < 5)
{
bool win = pk(96000, 64000, 32000, 21400, 2500, 2500, 1, 0.07);
if(win)
{
cout << "战斗胜利 获得金币x30000" << endl;
gold += 30000;
t[4][2]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 3 && t[4][2] == 5 && t[4][3] < 5)
{
bool win = pk(120000, 80000, 40000, 28800, 2800, 2800, 1, 0.09);
if(win)
{
cout << "战斗胜利 获得金币x40000" << endl;
gold += 40000;
t[4][3]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 4 && t[4][3] == 5 && t[4][4] < 5)
{
bool win = pk(162000, 108000, 54000, 37600, 3280, 3280, 1, 0.1);
if(win)
{
cout << "战斗胜利 获得金币x40000" << endl;
gold += 40000;
t[4][4]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 5 && t[4][4] == 5 && t[4][5] < 5)
{
bool win = pk(210000, 140000, 70000, 52000, 3840, 3840, 1, 0.1);
if(win)
{
cout << "战斗胜利 获得金币x40000" << endl;
gold += 40000;
t[4][5]++;
}
else
{
cout << "战斗失败" << endl;
}
}
system("pause");
}
void temple5(long long x)
{
if(x == 0 && t[4][5] == 5 && t[5][0] < 5)
{
bool win = pk(1200000, 300000, 200000, 69000, 40000, 40000, 1, 0.1);
if(win)
{
cout << "战斗胜利 获得金币x50000 天赋点x2" << endl;
gold += 50000;
tlt += 2;
t[5][0]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 1 && t[5][0] == 5 && t[5][1] < 5)
{
bool win = pk(1800000, 450000, 300000, 92000, 56000, 56000, 1, 0.1);
if(win)
{
cout << "战斗胜利 获得金币x50000 天赋点x2" << endl;
gold += 50000;
tlt += 2;
t[5][1]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 2 && t[5][1] == 5 && t[5][2] < 5)
{
bool win = pk(3600000, 900000, 600000, 176000, 88000, 88000, 1, 0.1);
if(win)
{
cout << "战斗胜利 获得金币x50000 天赋点x3" << endl;
gold += 50000;
tlt += 2;
t[5][2]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 3 && t[5][2] == 5 && t[5][3] < 5)
{
bool win = pk(7200000, 1800000, 1200000, 456000, 276000, 276000, 1, 0.1);
if(win)
{
cout << "战斗胜利 获得金币x50000 天赋点x2" << endl;
gold += 50000;
tlt += 2;
t[5][3]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 4 && t[5][3] == 5 && t[5][4] < 5)
{
bool win = pk(10800000, 2700000, 1800000, 960000, 744000, 744000, 1, 0.1);
if(win)
{
cout << "战斗胜利 获得金币x50000 天赋点x2" << endl;
gold += 50000;
tlt += 2;
t[5][4]++;
}
else
{
cout << "战斗失败" << endl;
}
}
else if(x == 5 && t[5][4] == 5 && t[5][5] < 5)
{
bool win = pk(18000000, 4500000, 3000000, 1500000, 1200000, 1200000, 1, 0.1);
if(win)
{
cout << "战斗胜利 获得金币x50000 天赋点x2" << endl;
gold += 50000;
tlt += 2;
t[5][5]++;
if(t[5][5] == 5)
{
system("cls");
string s = "恭喜你通关挑战副本 获得轮回副本挑战权限";
s.append("\n挑战轮回副本可以完成成就 升级神识强度");
s.append("\n神识升级可以增加附加伤害");
s.append("\n好了 现在 打破轮回获得那一片远古神识吧");
s.append("\n\n生与灭-轮回不止");
s.append("\n你与我-渡向无限");
for(long long i = 0;i < s.size();i++)
{
Sleep(50);
Color(i % 3 == 0 ? 1 : (i % 3 == 1 ? 2 : 5));
cout << s[i];
}
Color(0);
cout << endl << endl;
system("pause");
}
}
else
{
cout << "战斗失败" << endl;
}
}
system("pause");
}
string get_jc_name(int zhang)
{
switch(zhang)
{
case -3:
return "无";
case -2:
return "无";
case -1:
return "无";
case 0:
return "地球异变";
case 1:
return "灾难来临";
case 2:
return "战线阻击";
case 3:
return "一夫当关";
case 4:
return "异军突起";
case 5:
return "联盟海湾";
case 6:
return "联合舰队";
case 7:
return "天基武器";
case 8:
return "浩荡大战";
case 9:
return "神秘波动";
case 10:
return "邪恶来客";
case 11:
return "天外之战";
case 12:
return "世界危机";
case 13:
return "星球防御";
case 14:
return "地球联邦";
case 15:
return "疯狂事变";
case 16:
return "十万火急";
case 17:
return "广播纪元";
case 18:
return "全球骚乱";
case 19:
return "千钧一发";
case 20:
return "破碎恒星";
case 21:
return "逃亡战争";
case 22:
return "重锤打击";
case 23:
return "如梦初醒";
case 24:
return "生存死局";
case 25:
return "寒冬守望";
case 26:
return "一战封神";
case 27:
return "外星遗迹";
case 28:
return "宇宙奇观";
case 29:
return "毁灭之最";
case 30:
return "决战凯歌";
default:
return "未完待续";
}
}
void mxjc()
{
system("cls");
cout << "当前 第" << jc << "章" << endl;
Color(1), cout << jc - 3 << " " << get_jc_name(jc - 3) << endl;
Color(1), cout << jc - 2 << " " << get_jc_name(jc - 2) << endl;
Color(1), cout << jc - 1 << " " << get_jc_name(jc - 1) << endl;
Color(5), cout << jc << " " << get_jc_name(jc) << endl;
Color(4), cout << jc + 1 << " " << get_jc_name(jc + 1) << endl;
Color(4), cout << jc + 2 << " " << get_jc_name(jc + 2) << endl;
Color(4), cout << jc + 3 << " " << get_jc_name(jc + 3) << endl;
Color(2), cout << "按K键开启新的一章! L键返回" << endl;
Color(0);
char x = input('k', 'l');
if(x == 'l') return;
cout << "冒险剧场第" << jc << "章" << endl;
cout << ">>> " << get_jc_name(jc) << " <<<" << endl;
string s = "";
//对话
if(jc == 0)
{
s.append("2077年10月 地球大西洋遭遇了大灾难\n");
s.append("无数幽灵从大西洋海岸登陆欧洲\n");
s.append("英国人们拼死抵抗 最终几乎被完全消灭\n");
s.append("幽灵队伍进入法国 屠杀百姓\n");
s.append("大家纷纷逃往俄罗斯避难\n");
s.append("\n");
s.append("俄罗斯总统: 战况如何?\n");
s.append("电话后方: 总统先生 我们的军队正在赶往现场\n");
s.append("总统: 调集俄罗斯全部300万士兵 务必击败敌人!\n");
s.append("电话后方: 好的 我们马上行动\n");
s.append("秘书: 总统先生 不好了!\n");
s.append("总统: 怎么回事?\n");
s.append("秘书: 前线的12万将士已经全部牺牲 敌人打入境内了!\n");
s.append("总统: 什么?!!海军舰队呢?\n");
s.append("秘书: 他们......\n");
s.append("总统: 支支吾吾什么 快说!\n");
s.append("秘书: 他们与幽灵军团战至最后一刻 已经全部牺牲\n");
s.append("总统: 调集航母编队 立即攻击 快!\n");
s.append("秘书: 好的\n");
s.append("\n");
s.append("你作为中国援俄罗斯舰队的一员踏上了征途\n");
s.append("前方便是幽灵大军 战斗一触即发\n");
}
else if(jc == 1)
{
s.append("战斗进行了一个多月 陷入胶着\n");
s.append("你的舰队在幽灵的轮番攻击之下难以为继\n");
s.append("全世界的兵力集中在大西洋东岸\n");
s.append("但这些幽灵数量太多 几乎无法全部歼灭\n");
s.append("终于 舰队再也不能支持下去\n");
s.append("\n");
s.append("中国主席: 今天是极为沉痛的日子\n");
s.append("主席: 我宣布 中国援俄罗斯军队已经覆灭\n");
s.append("国防部长: 3艘航母 约1000艘舰船 彻底被敌人消灭\n");
s.append("记者: 那么 我们还有没有希望?\n");
s.append("主席: 这就是恐怖之处:他们正越来越多\n");
s.append("国防部长: 欧洲快要沦陷了 很快 灾难将会席卷全球\n");
s.append("记者: 那么 中国也会沦陷吗?\n");
s.append("国防部长: 以现在的攻势 他们将在一年内到达中国\n");
s.append("记者: 好的 我们了解到 航母编队还有一人幸存\n");
s.append("主席: 什么?还有人能够幸存?\n");
s.append("记者: 他从大西洋荒岛而来 能力极强 成功突围幸存\n");
s.append("主席: 哦 他太厉害了!!!\n");
s.append("\n");
s.append("事实上 你突围之后又遇到了大量的敌人\n");
s.append("他们没完没了地追击着你\n");
}
else if(jc == 2)
{
s.append("浩荡的幽灵大军在俄罗斯海战之后再无敌手\n");
s.append("他们在欧洲内陆无往不利\n");
s.append("很多国家将战斗进行到了最后一刻\n");
s.append("但是它们最终都被轻易攻破\n");
s.append("终于 幽灵们到达了重要关隘:喜马拉雅关\n");
s.append("它矗立于喜马拉雅山脉中 易守难攻\n");
s.append("你在一个月前到达喜马拉雅关 替中国抵御幽灵军团\n");
s.append("2078年8月 你看到了下方的幽灵潮水\n");
s.append("你决定战斗到最后一刻 与祖国同在\n");
s.append("\n");
s.append("就在你难以为继的时候 援军到来\n");
s.append("百万大军与你同生死 共患难\n");
s.append("一条条战线排成长龙 与敌人决战\n");
s.append("今日 敌人不死 也别想活!\n");
}
else if(jc == 3)
{
s.append("幽灵大军开始进攻喜马拉雅关了!!!\n");
s.append("你见到了浩浩荡荡的景象\n");
s.append("但你坚信 一夫当关 万夫莫开!\n");
s.append("于是 战斗的号角打响了\n");
s.append("你让援军休养生息 而自己与幽灵一战\n");
s.append("前方 便是战场\n");
s.append("敌人不死 谁 死 ? ! !\n");
}
else if(jc == 4)
{
s.append("幽灵大军的攻势渐渐开始减退了\n");
s.append("百万大军气势如虹 与敌人近身交战\n");
s.append("渐渐地 我国获得了压倒性的优势\n");
s.append("但也就在这时 幽灵突然反攻\n");
s.append("精锐部队出动 战斗陷入僵局\n");
s.append("喜马拉雅山的温度上升到冰点以上\n");
s.append("火焰凶猛 而你决定再战\n");
s.append("你直接找到了幽灵的一名大将\n");
s.append("擒贼先擒王\n");
}
else if(jc == 5)
{
s.append("随着敌人的溃败 胜利的号角吹响了\n");
s.append("你和50万精锐部队成为了中国的英雄\n");
s.append("但好景不长 幽灵军队很快东山再起\n");
s.append("2083年 欧洲遭遇幽灵入侵\n");
s.append("这次的敌人武装精良 已经打入英吉利海峡\n");
s.append("联盟港湾上 到处都是哭爹喊娘的士兵\n");
s.append("你作为援助军的一员 奋战在一线\n");
s.append("周围的士兵一个个死亡 你依旧战斗\n");
s.append("源源不断的敌人将所有士兵牵制在一线战场上\n");
s.append("但敌人的精锐士兵早已绕道而行......\n");
s.append("战争基地的炮火催醒了你 敌人又来了\n");
s.append("基地的存亡 在此一举\n");
}
else
{
s.append("未完待续\n");
}
for(int i = 0;i < s.size();i++)
{
Sleep(60);
cout << s[i];
if(s[i] == '\n') Sleep(30);
}
Color(2), system("pause");
Color(0);
bool y = false;
//战斗
if(jc == 0)
{
y = pk(60000, 60000, 30000, 2000, 0, 2000, 0, 0.1);
}
else if(jc == 1)
{
y = pk(70000, 70000, 35000, 3000, 0, 3000, 0, 0.1);
}
else if(jc == 2)
{
y = pk(80000, 80000, 40000, 4000, 0, 4000, 0, 0.1);
}
else if(jc == 3)
{
y = pk(90000, 90000, 45000, 4500, 0, 4500, 0, 0.1);
}
else if(jc == 4)
{
y = pk(100000, 100000, 50000, 5000, 0, 5000, 0, 0.1);
}
else if(jc == 5)
{
y = pk(100000, 120000, 60000, 6000, 0, 6000, 0, 0.1);
}
else if(jc == 6)
{
y = pk(140000, 140000, 70000, 7000, 0, 7000, 0, 0.1);
}
else if(jc == 7)
{
y = pk(160000, 160000, 80000, 8000, 0, 8000, 0, 0.1);
}
else if(jc == 8)
{
y = pk(180000, 180000, 90000, 9000, 0, 9000, 0, 0.1);
}
else if(jc == 9)
{
y = pk(200000, 200000, 100000, 10000, 0, 10000, 0, 0.1);
}
else if(jc == 10)
{
y = pk(220000, 220000, 110000, 11000, 0, 11000, 1, 0.1);
}
else if(jc == 11)
{
y = pk(240000, 240000, 120000, 12000, 0, 12000, 1, 0.1);
}
else if(jc == 12)
{
y = pk(260000, 260000, 130000, 13000, 0, 13000, 1, 0.1);
}
else if(jc == 13)
{
y = pk(280000, 280000, 140000, 14000, 0, 14000, 1, 0.1);
}
else if(jc == 14)
{
y = pk(300000, 300000, 150000, 15000, 0, 15000, 1, 0.1);
}
else if(jc == 15)
{
y = pk(330000, 330000, 165000, 16500, 0, 16500, 1, 0.1);
}
else if(jc == 16)
{
y = pk(360000, 360000, 180000, 18000, 0, 18000, 1, 0.1);
}
else if(jc == 17)
{
y = pk(390000, 390000, 195000, 19500, 0, 19500, 1, 0.1);
}
else if(jc == 18)
{
y = pk(420000, 420000, 210000, 21000, 0, 21000, 1, 0.1);
}
else if(jc == 19)
{
y = pk(450000, 450000, 225000, 22500, 0, 22500, 1, 0.1);
}
else if(jc == 20)
{
y = pk(480000, 480000, 240000, 24000, 0, 24000, 2, 0.1);
}
else if(jc == 21)
{
y = pk(510000, 510000, 255000, 25500, 0, 25500, 2, 0.1);
}
else if(jc == 22)
{
y = pk(540000, 540000, 270000, 27000, 0, 27000, 2, 0.1);
}
else
{
y = pk(1e16, 1e16, 1e16, 1e12, 1e12, 1e12, 0, 1.0);
}
if(y)
{
cout << "战斗胜利 属性提升" << endl;
jc++;
hp += 4500;
ap += 2250;
dp += 2250;
yl += 9000;
system("pause");
mxjc();
}
else
{
cout << "战斗失败" << endl;
system("pause");
}
}
void jm(long long num)
{
if(num == 1)
{
if(pkp == 160 && dx == 0)
{
cout << "0 1-0: 荒岛坠落(通关0/1)" << endl;
Color(2), cout << "选择你要挑战的关卡" << endl;
Color(0);
long long x = input('0', '0');
temple1(0);
return;
}
cout << "副本" << endl;
cout << "1 第一章 荒岛大涅槃" << endl;
cout << "2 第二章 战争与号角" << endl;
cout << "3 第三章 生存的战役" << endl;
cout << "4 第四章 三圣封轮回" << endl;
cout << "5 第五章 冥界永恒归" << endl;
char c = input('1', '5');
if(c == '1')
{
cout << "0 1-0: 荒岛坠落(通关" << t[1][0] << "/1)" << endl;
cout << "1 1-1: 天空之坑(通关" << t[1][1] << "/1)" << endl;
cout << "2 1-2: 野人军团(通关" << t[1][2] << "/1)" << endl;
cout << "3 1-3: 全力抵挡(通关" << t[1][3] << "/1)" << endl;
cout << "4 1-4: 浴火重生(通关" << t[1][4] << "/1)" << endl;
cout << "5 1-5: 疯狂之战(通关" << t[1][5] << "/1)" << endl;
Color(2), cout << "选择你要挑战的关卡" << endl;
Color(0);
long long x = input('0', '5') - '0';
temple1(x);
}
else if(c == '2')
{
cout << "0 2-0: 野人集结(通关" << t[2][0] << "/3)" << endl;
cout << "1 2-1: 战争前兆(通关" << t[2][1] << "/3)" << endl;
cout << "2 2-2: 战争大军(通关" << t[2][2] << "/3)" << endl;
cout << "3 2-3: 艰难抵抗(通关" << t[2][3] << "/3)" << endl;
cout << "4 2-4: 求援巫师(通关" << t[2][4] << "/3)" << endl;
cout << "5 2-5: 两面夹击(通关" << t[2][5] << "/3)" << endl;
Color(2), cout << "选择你要挑战的关卡" << endl;
Color(0);
long long x = input('0', '5') - '0';
temple2(x);
}
else if(c == '3')
{
cout << "0 3-0: 巫师倒戈(通关" << t[3][0] << "/5)" << endl;
cout << "1 3-1: 不利局势(通关" << t[3][1] << "/5)" << endl;
cout << "2 3-2: 夜袭敌营(通关" << t[3][2] << "/5)" << endl;
cout << "3 3-3: 站稳脚跟(通关" << t[3][3] << "/5)" << endl;
cout << "4 3-4: 野人反扑(通关" << t[3][4] << "/5)" << endl;
cout << "5 3-5: 孤注一掷(通关" << t[3][5] << "/5)" << endl;
Color(2), cout << "选择你要挑战的关卡" << endl;
Color(0);
long long x = input('0', '5') - '0';
temple3(x);
}
else if(c == '4')
{
cout << "0 4-0: 野王报复(通关" << t[4][0] << "/5)" << endl;
cout << "1 4-1: 天赋神殿(通关" << t[4][1] << "/5)" << endl;
cout << "2 4-2: 神魂争夺(通关" << t[4][2] << "/5)" << endl;
cout << "3 4-3: 三神会审(通关" << t[4][3] << "/5)" << endl;
cout << "4 4-4: 挑战真神(通关" << t[4][4] << "/5)" << endl;
cout << "5 4-5: 圣峰轮回(通关" << t[4][5] << "/5)" << endl;
Color(2), cout << "选择你要挑战的关卡" << endl;
Color(0);
long long x = input('0', '5') - '0';
temple4(x);
}
else if(c == '5')
{
cout << "0 5-0: 巅峰之战(通关" << t[5][0] << "/5)" << endl;
cout << "1 5-1: 王者之路(通关" << t[5][1] << "/5)" << endl;
cout << "2 5-2: 路的尽头(通关" << t[5][2] << "/5)" << endl;
cout << "3 5-3: 冥界重生(通关" << t[5][3] << "/5)" << endl;
cout << "4 5-4: 魂归之战(通关" << t[5][4] << "/5)" << endl;
cout << "5 5-5: 最终胜利(通关" << t[5][5] << "/5)" << endl;
Color(2), cout << "选择你要挑战的关卡" << endl;
Color(0);
long long x = input('0', '5') - '0';
temple5(x);
}
}
else if(num == 2)
{
cout << "能力提升" << endl;
cout << "花费1000金币 提升如下属性:" << endl;
cout << "生命+200 攻击+50" << endl;
cout << "防御+20 恢复+20" << endl;
cout << "按1 提升属性";
if(pkp != 0) cout << "按2 十连提升 按3 百连提升按其他键退出" << endl;
if(pkp == 0)
{
long long n = input('1', '1');
if(gold == 1000)
{
gold = 0;
Color(5), cout << "花费1000金币 增加属性" << endl;
Color(0);
hp += 200;
ap += 50;
dp += 20;
hf += 20;
system("pause");
}
else
{
Color(2), cout << "异常!!请重置存档!!" << endl;
Color(0);
system("pause");
}
}
else
{
char n = input();
if(n == '1')
{
if(gold >= 1000)
{
gold -= 1000;
Color(5), cout << "花费1000金币 增加属性" << endl;
Color(0);
hp += 200;
ap += 50;
dp += 20;
hf += 20;
system("pause");
jm(2);
}
}
else if(n == '2')
{
if(gold >= 10000)
{
gold -= 10000;
Color(5), cout << "花费10000金币 增加属性(x10)" << endl;
Color(0);
hp += 2000;
ap += 500;
dp += 200;
hf += 200;
system("pause");
jm(2);
}
}
else if(n == '3')
{
if(gold >= 100000)
{
gold -= 100000;
Color(5), cout << "花费100000金币 增加属性(x100)" << endl;
Color(0);
hp += 20000;
ap += 5000;
dp += 2000;
hf += 2000;
system("pause");
jm(2);
}
}
return;
}
}
else if(num == 3)
{
cout << "护盾强化" << endl;
cout << "花费100000金币 获得如下属性:" << endl;
cout << "生命+200 攻击+50" << endl;
cout << "防御+20 护盾+1" << endl;
cout << "按1 提升属性";
if(pkp != 80) cout << "按其他键退出" << endl;
cout << "(护盾属性最高提升到4)";
if(pkp == 80)
{
long long n = input('1', '1');
if(gold == 100000)
{
gold = 0;
Color(5), cout << "花费100000金币 增加属性" << endl;
Color(0);
hp += 200;
ap += 50;
dp += 20;
hd += 1;
system("pause");
}
else
{
Color(2), cout << "异常!!请重置存档!!" << endl;
Color(0);
system("pause");
}
}
else
{
char n = input();
if(n == '1')
{
if(gold >= 100000)
{
gold -= 100000;
Color(5), cout << "花费100000金币 增加属性" << endl;
Color(0);
hp += 200;
ap += 50;
dp += 20;
if(hd < 4) hd += 1;
else { Color(2), cout << "护盾属性已提升到极限不再提升" << endl; }
Color(0);
system("pause");
jm(3);
}
return;
}
}
}
else if(num == 4)
{
cout << "毒性淬炼" << endl;
cout << "花费1000金币 获得如下属性:" << endl;
cout << "生命+0 攻击+0" << endl;
cout << "防御+0 毒性+5" << endl;
cout << "按1 提升属性";
if(pkp != 160) cout << "按其他键退出" << endl;
if(pkp == 160)
{
long long n = input('1', '1');
if(gold == 1000)
{
gold = 0;
Color(5), cout << "花费1000金币 增加属性" << endl;
Color(0);
dx += 5;
system("pause");
}
else
{
Color(2), cout << "异常!!请重置存档!!" << endl;
Color(0);
system("pause");
}
}
else
{
char n = input();
if(n == '1')
{
if(gold >= 1000)
{
gold -= 1000;
Color(5), cout << "花费1000金币 增加属性" << endl;
Color(0);
dx += 5;
system("pause");
return;
}
jm(4);
}
}
}
else if(num == 5)
{
cout << "暴击试炼" << endl;
cout << "花费10000金币 获得如下属性:" << endl;
cout << "生命+200 攻击+50" << endl;
cout << "防御+25 暴击+0.2%" << endl;
cout << "按1 提升属性";
cout << "按其他键退出" << endl;
{
char n = input();
if(n == '1')
{
if(gold >= 10000)
{
gold -= 10000;
Color(5), cout << "花费10000金币 增加属性" << endl;
Color(0);
hp += 200;
ap += 50;
dp += 25;
BJ += 0.002;
system("pause");
jm(5);
}
return;
}
}
}
else if(num == 6)
{
cout << "复活祈祷" << endl;
cout << "花费5000金币 获得如下属性:" << endl;
cout << "生命+100 攻击+25" << endl;
cout << "防御+10 复活+0.1%" << endl;
cout << "按1 提升属性";
cout << "按其他键退出" << endl;
{
char n = input();
if(n == '1')
{
if(gold >= 5000)
{
gold -= 5000;
Color(5), cout << "花费5000金币 增加属性" << endl;
Color(0);
hp += 100;
ap += 25;
dp += 10;
FH += 0.001;
system("pause");
jm(6);
}
return;
}
}
}
else if(num == 7)
{
cout << "天赋副本" << endl;
cout << "选择副本层数" << endl;
cout << "1 天赋副本-精良 ";
Color(0), cout << "奖励天赋点1~2" << endl;
Color(0);
cout << "2 天赋副本-稀有 ";
Color(1), cout << "奖励天赋点3~5" << endl;
Color(0);
cout << "3 天赋副本-史诗 ";
Color(3), cout << "奖励天赋点7~11" << endl;
Color(0);
cout << "4 天赋副本-传说 ";
Color(2), cout << "奖励天赋点15~24" << endl;
Color(0);
cout << "5 天赋副本-神话 ";
Color(5), cout << "奖励天赋点40~69" << endl;
Color(0);
cout << "6 天赋副本-轮回 ";
Color(4), cout << "奖励天赋点90~129" << endl;
Color(0);
cout << "天赋副本的BOSS血量极高 请耐心等待" << endl;
char n = input('1', '6');
if(n == '1')
{
bool win = pk(1e6, 44000, 22000, 0, 6000, 6000, 3, 0);
if(win)
{
long long r = random(1, 3);
cout << "胜利 获得金币x20000 + 天赋点x" << r << endl;
gold += 20000;
tlt += r;
}
else
{
cout << "失败" << endl;
}
}
else if(n == '2')
{
bool win = pk(1e7, 90000, 45000, 0, 12000, 12000, 3, 0);
if(win)
{
long long r = random(3, 6);
cout << "胜利 获得金币x100000 + 天赋点x" << r << endl;
gold += 100000;
tlt += r;
}
else
{
cout << "失败" << endl;
}
}
else if(n == '3')
{
bool win = pk(1e8, 225000, 112500, 0, 30000, 30000, 3, 0);
if(win)
{
long long r = random(7, 12);
cout << "胜利 获得金币x350000 + 天赋点x" << r << endl;
gold += 350000;
tlt += r;
}
else
{
cout << "失败" << endl;
}
}
else if(n == '4')
{
bool win = pk(1e9, 360000, 180000, 0, 51000, 51000, 3, 0);
if(win)
{
long long r = random(15, 25);
cout << "胜利 获得金币x750000 + 天赋点x" << r << endl;
gold += 750000;
tlt += r;
}
else
{
cout << "失败" << endl;
}
}
else if(n == '5')
{
bool win = pk(1e10, 630000, 315000, 0, 75000, 75000, 3, 0);
if(win)
{
long long r = random(40, 70);
cout << "胜利 获得金币x1200000 + 天赋点x" << r << endl;
gold += 1200000;
tlt += r;
}
else
{
cout << "失败" << endl;
}
}
else if(n == '6')
{
bool win = pk(1e11, 2000000, 1000000, 0, 300000, 300000, 3, 0.3);
if(win)
{
long long r = random(90, 130);
cout << "胜利 获得金币x1800000 + 天赋点x" << r << endl;
gold += 1800000;
tlt += r;
}
else
{
cout << "失败" << endl;
}
}
system("pause");
}
else if(num == 8)
{
if(t[3][5] == 5)
{
Color(2), cout << "星空殿堂" << endl;
cout << "在这里可以通过考核提升星空能量等级" << endl;
cout << "1-5级 行星级\t6-10级 恒星级\t11-15级 宇宙级\t16-20级 不朽级" << endl;
Color(0);
}
cout << "该功能正在筹划中......" << endl;
}
else if(num == 9)
{
cout << "攻击天赋 " << talent[0] << "级" << endl;
cout << "升级该天赋需要" << (long long)log(pow(talent[0] + 1, 5)) << "天赋点" << endl;
cout << "下一次升级攻击力+" << (long long)pow(talent[0] + 4, 2.4) << endl;
Color(5), cout << "您的天赋点: " << tlt << " ";
Color(0);
if(tlt >= (long long)log(pow(talent[0] + 1, 5))) cout << "可以升级" << endl;
else cout << "无法升级" << endl;
Color(2), cout << "按S 升级 按其他键退出" << endl;
Color(0);
char n = input();
if(n == 's' || n == 'S')
{
if(tlt >= (long long)log(pow(talent[0] + 1, 5)))
{
tlt -= (long long)log(pow(talent[0] + 1, 5));
ap += (long long)pow(talent[0] + 4, 2.4);
talent[0]++;
cout << "升级成功 当前等级";
Color(5), cout << talent[0];
Color(0), cout << "级" << endl;
}
}
else
{
system("pause");
return;
}
system("pause");
jm(9);
}
else if(num == 10)
{
cout << "防御天赋 " << talent[1] << "级" << endl;
cout << "升级该天赋需要" << (long long)log(pow(talent[1] + 1, 5)) << "天赋点" << endl;
cout << "下一次升级防御力+" << (long long)pow(talent[1] + 4, 1.2) << endl;
Color(5), cout << "您的天赋点: " << tlt << " ";
Color(0);
if(tlt >= (long long)log(pow(talent[1] + 1, 5))) cout << "可以升级" << endl;
else cout << "无法升级" << endl;
Color(2), cout << "按S 升级 按其他键退出" << endl;
Color(0);
char n = input();
if(n == 's' || n == 'S')
{
if(tlt >= (long long)log(pow(talent[1] + 1, 5)))
{
tlt -= (long long)log(pow(talent[1] + 1, 5));
dp += (long long)pow(talent[1] + 4, 1.2);
talent[1]++;
cout << "升级成功 当前等级";
Color(5), cout << talent[1];
Color(0), cout << "级" << endl;
}
}
else
{
system("pause");
return;
}
system("pause");
jm(10);
}
else if(num == 11)
{
cout << "生命天赋 " << talent[2] << "级" << endl;
cout << "升级该天赋需要" << (long long)log(pow(talent[2] + 1, 5)) << "天赋点" << endl;
cout << "下一次升级生命值+" << (long long)pow(talent[2] + 4, 3) << endl;
Color(5), cout << "您的天赋点: " << tlt << " ";
Color(0);
if(tlt >= (long long)log(pow(talent[2] + 1, 5))) cout << "可以升级" << endl;
else cout << "无法升级" << endl;
Color(2), cout << "按S 升级 按其他键退出" << endl;
Color(0);
char n = input();
if(n == 's' || n == 'S')
{
if(tlt >= (long long)log(pow(talent[2] + 1, 5)))
{
tlt -= (long long)(log(pow(talent[2] + 1, 5)));
hp += (long long)(pow(talent[2] + 4, 3));
talent[2]++;
cout << "升级成功 当前等级";
Color(5), cout << talent[2];
Color(0), cout << "级" << endl;
}
}
else
{
system("pause");
return;
}
system("pause");
jm(11);
}
else if(num == 12)
{
cout << "挑战轮回副本可获得材料" << endl;
Color(5), cout << "每挑战5层可获得淬毒残片" << endl;
cout << "每挑战10层可获得复生残片" << endl;
Color(0), system("pause");
cout << "轮回副本第" << tx + 1 << "层" << endl;
Sleep(1000);
bool win = true;
if(tx == 0)
{
win = pk(100, 40, 20, 0, 0, 0, 0, 0.0);
}
else for(long long i = 0;i < 12;i++)
{
cout << "剩余" << 12 - i << "个敌人" << endl;
Sleep(100);
bool W = pk(24000000 + tx * 4000000 + i * 80000,
6000000 + tx * 1000000 + i * 20000,
3000000 + tx * 500000 + i * 10000,
750000 + tx * 80000, 40000 + tx * 1000,
750000 + tx * 80000, min(log(tx), 4.0), 1.0);
if(!W)
{
win = false;
break;
}
}
if(!win)
{
cout << "闯关失败" << endl;
system("pause");
}
else
{
cout << "闯关成功 轮回层数提高1层 获得10w金币" << endl;
gold += 100000;
tx += 1;
if(tx % 5 == 0)
{
cout << "获得淬毒残片 毒性+2000" << endl;
dx += 2000;
}
if(tx % 10 == 0)
{
cout << "获得复生残片 恢复+2000" << endl;
hf += 2000;
}
system("pause");
}
}
else if(num == 13)
{
cout << "神识强化可获得附加伤害" << endl;
cout << "下一次神识强化可提升附加伤害" << (long long)(ss * 14 + sqrt(pow(ss, 3.5))) * 1000 << endl;
cout << "下一次神识强化需要轮回" << (long long)(ss * 2 + sqrt(ss * 4) + 1) << "层" << endl;
cout << "目前您的轮回层数";
if(tx >= (long long)(ss * 2 + sqrt(ss * 4) + 1))
{
Color(5), cout << "可以提升" << endl;
}
else
{
Color(2), cout << "无法提升" << endl;
}
Color(0);
cout << "T键提升" << endl;
char n = input('t', 't');
if(tx >= (long long)(ss * 2 + sqrt(ss * 4) + 1))
{
cout << "提升成功 神识+1 附加伤害+" << (long long)(ss * 14 + sqrt(pow(ss, 3.5))) * 1000 << endl;
ss++;
fs += (long long)(ss * 14 + sqrt(pow(ss, 3.5))) * 1000;
}
else
{
cout << "提升失败" << endl;
}
system("pause");
}
else if(num == 14)
{
cout << "神体提升可强化全部属性" << endl;
cout << "消耗200天赋点 随机获得以下属性中的1条" << endl;
cout << "生命+6000000 攻击+2000000 防御+1000000" << endl;
cout << "毒性+500000 附伤+500000" << endl;
cout << "x键 -> 升级" << endl;
char n = input('x', 'x');
if(tlt >= 200)
{
tlt -= 200;
int xn = random(0, 5);
switch(xn)
{
case 0:
cout << "生命+6000000" << endl;
hp += 6000000;
break;
case 1:
cout << "攻击+2000000" << endl;
ap += 2000000;
break;
case 2:
cout << "防御+1000000" << endl;
dp += 1000000;
break;
case 3:
cout << "毒性+500000" << endl;
dx += 500000;
break;
case 4:
cout << "附伤+500000" << endl;
fs += 500000;
break;
}
}
system("pause");
}
else if(num == 15)
{
cout << "冒险剧场简介:" << endl;
cout << "该功能为章节连载制闯关功能 过关可获得属性加成" << endl;
cout << "每通过1个章节 攻防属性提升2250 生命属性提升4500" << endl;
cout << "当然 这个功能最重要的是给予你原力的提升" << endl;
cout << "每通过1个章节 原力属性提升9000" << endl;
system("pause");
system("cls");
mxjc();
system("cls");
}
else if(num == 16)
{
int go10s = tx * 30 + (tx >= 10 ? tx * 20 : 0); // gold of 10 seconds
for(int i = 0;i <= 5;i++)
{
go10s += t[4][i] * 5 + t[5][i] * 10;
}
int shengyu = 100;
while(1)
{
Sleep(100);
SetPos(0, 0);
for(int i = 0;i < shengyu / 2;i++) Color(3), cout << "█";
for(int i = shengyu / 2;i < 50;i++) Color(0), cout << "█";
Color(0);
SetPos(0, 2);
cout << shengyu / 10.0 << "s -> " << go10s << "金币 " << endl;
cout << "按任意键退出挂机" << endl;
if(_kbhit())
{
system("cls");
return;
}
shengyu--;
if(shengyu == 0)
{
shengyu = 100;
gold += go10s;
}
}
}
}
void GAME()
{
cout << "1 创建新角色" << endl;
cout << "2 使用原角色" << endl;
long long n = input('1', '2') - '0';
if(n == 1)
{
Color(2), cout << "注意!注意!是否要创建新角色?按1退出 按2确认创建" << endl;
Color(0);
char n = input('1', '2');
if(n == '1')
{
cout << "读取中......" << endl;
INS();
}
else
{
cout << "创建中......" << endl;
init();
OUTS();
}
}
else
{
cout << "读取中......" << endl;
INS();
}
while(1)
{
system("cls");
OUTS();
pkp = (hp * 0.125 + ap * 0.5 + dp * 1.5) + (BJ * 50 + FH * 1000);
if(pkp == 0)
{
cout << "新手指引1" << endl;
cout << "在游戏界面出现后 请按键盘1 使用金币升级自身能力" << endl;
cout << "S 继续(金币+1000)" << endl;
char S = input('s', 's');
gold += 1000;
}
else if(pkp == 80)
{
cout << "新手指引2" << endl;
cout << "在游戏界面出现后 请按键盘3 使用金币获得一个护盾" << endl;
cout << "S 继续(金币+100000)" << endl;
char S = input('s', 's');
gold += 100000;
}
else if(pkp == 160 && t[1][0] < 1)
{
cout << "新手指引3" << endl;
cout << "在游戏界面出现后 请按键盘1 开启副本进行一次战斗" << endl;
cout << "S 继续" << endl;
char S = input('s', 's');
}
else if(pkp == 160 && t[1][0] == 1 && dx == 0)
{
cout << "新手指引4" << endl;
cout << "在游戏界面出现后 请按键盘4 完成毒性淬炼获得毒伤" << endl;
cout << "S 继续" << endl;
char S = input('s', 's');
}
else if(t[5][5] == 5 && tx == 0 && ss == 0)
{
cout << "指引-轮回副本/神识1" << endl;
cout << "在游戏界面出现后 按键盘1 按键盘1 完成轮回副本第1层挑战" << endl;
cout << "S 继续" << endl;
char S = input('s', 's');
}
else if(t[5][5] == 5 && tx == 1 && ss == 0)
{
cout << "指引-轮回副本/神识2" << endl;
cout << "在游戏界面出现后 按键盘4 按键盘t 开启神识获得附加伤害" << endl;
cout << "S 继续" << endl;
char S = input('s', 's');
}
Color(2), cout << "战斗力: " << pkp << endl;
Color(0);
cout << "金币: " << gold << endl;
cout << endl;
//游戏界面
if(pkp == 0)
{
cout << "1 属性提升" << endl;
cout << endl;
char n = input('1', '1');
jm(2);
continue;
}
else if(pkp == 80)
{
cout << "1 副本挑战" << endl;
cout << "2 属性提升" << endl;
cout << "3 护盾强化" << endl;
cout << endl;
char n = input('3', '3');
jm(3);
continue;
}
else if(pkp == 160 && t[1][0] < 1)
{
cout << "1 副本挑战" << endl;
cout << "2 属性提升" << endl;
cout << "3 护盾强化" << endl;
cout << endl;
char n = input('1', '1');
jm(1);
continue;
}
else if(pkp == 160 && t[1][0] == 1 && dx == 0)
{
cout << "1 副本挑战" << endl;
cout << "2 属性提升" << endl;
cout << "3 护盾强化" << endl;
cout << "4 毒性淬炼" << endl;
cout << endl;
char n = input('4', '4');
jm(4);
continue;
}
else if(t[5][5] == 5 && tx == 0 && ss == 0)
{
cout << "1 副本挑战" << endl;
cout << "2 能力养成" << endl;
cout << "3 天赋(通关副本4-5)" << endl;
cout << "4 神识(通关轮回第1层)" << endl;
cout << endl;
char n = input('1', '1');
cout << "1 轮回副本(已通关" << tx << "层)" << endl;
cout << "2 天赋获取(通关副本4-5)" << endl;
cout << "3 冒险剧场(通关副本3-5)" << endl;
cout << endl;
char m = input('1', '1');
jm(12);
continue;
}
else if(t[5][5] == 5 && tx == 1 && ss == 0)
{
cout << "1 副本挑战" << endl;
cout << "2 能力养成" << endl;
cout << "3 天赋(通关副本4-5)" << endl;
cout << "4 神识(通关轮回第1层)" << endl;
cout << endl;
char n = input('4', '4');
jm(13);
continue;
}
cout << "1 战斗试炼" << endl;
cout << "2 能力养成" << endl;
cout << "3 天赋(通关副本4-5)" << endl;
if(tx > 0) cout << "4 神识(通关轮回第1层)" << endl;
else cout << "4 ???" << endl;
if(ss >= 20) cout << "5 神体(神识20级)" << endl;
else cout << "5 ???" << endl;
if(t[1][5] == 1) cout << "6 活动(通关副本第1章)" << endl;
else cout << "6 ???" << endl;
cout << "7 金币挂机场" << endl;
cout << endl;
char n = input('1', '7');
if(n == '1')
{
if(t[5][5] != 5) cout << "1 冒险副本" << endl;
else cout << "1 轮回副本(已通关" << tx << "层)" << endl;
if(t[4][5] == 5) cout << "2 天赋副本(通关副本4-5)" << endl;
else cout << "2 ???" << endl;
if(t[3][5] == 5) cout << "3 冒险剧场(通关副本3-5)" << endl;
else cout << "3 ???" << endl;
if(tx >= 4) cout << "4 秘境" << endl;
else cout << "4 ???" << endl;
cout << endl;
char m = input('1', '3');
switch(m)
{
case '1':
if(t[5][5] != 5) jm(1);
else jm(12);
break;
case '2':
if(t[4][5] != 5)
{
cout << "你迷失在无尽的黑暗中......" << endl;
cout << "暂时没有解锁这个功能" << endl;
system("pause");
}
else jm(7);
break;
case '3':
if(t[3][5] != 5)
{
cout << "你迷失在无尽的黑暗中......" << endl;
cout << "暂时没有解锁这个功能" << endl;
system("pause");
}
else jm(15);
break;
}
}
else if(n == '2')
{
cout << "1 属性提升 生命" << hp << " 攻击" << ap << " 防御" << dp << endl;
cout << "2 护盾强化" << " 护盾" << hd << endl;
cout << "3 毒性淬炼" << " 毒性" << dx << endl;
cout << "4 暴击试炼" << " 暴击" << BJ * 100 << "%" << endl;
cout << "5 复活祈祷" << " 复活" << FH * 100 << "%" << endl;
if(t[3][5] != 5) cout << "6 ???" << endl;
else cout << "6 星空殿堂(通关副本第3章)" << endl;
cout << endl;
char m = input('1', '6');
if(m <= '5') jm((m - '0') + 1);
else jm(8);
}
else if(n == '3')
{
cout << "1 强攻天赋" << endl;
cout << "2 守御天赋" << endl;
cout << "3 生命天赋" << endl;
cout << endl;
char m = input('1', '5');
jm((m - '0') + 8);
}
else if(n == '4')
{
if(tx != 0) jm(13);
else
{
cout << "你迷失在无尽的黑暗之中......" << endl;
cout << "暂时没有解锁这个功能" << endl;
system("pause");
}
}
else if(n == '5')
{
if(ss >= 20) jm(14);
else
{
cout << "你迷失在无尽的黑暗之中......" << endl;
cout << "暂时没有解锁这个功能" << endl;
system("pause");
}
}
else if(n == '6')
{
if(t[1][5] == 1)
{
cout << "<1> 天赋点黑市" << endl;
cout << "<2> 金币大彩票" << endl;
char nx = input('1', '2');
if(nx == '1')
{
Color(2), cout << "选择购买物" << endl;
Color(0);
cout << "[1] 100天赋点 <- 1e金币" << endl;
cout << "[2] 1000天赋点 <- 9e金币" << endl;
cout << "[3] 10000天赋点 <- 81e金币" << endl;
if(t[5][0] == 0) Color(2), cout << "新手爆款[4] 100天赋点 <- 2000w金币" << endl;
Color(0);
char nn;
if(t[5][0] == 0) nn = input('1', '4');
else nn = input('1', '3');
if(nn == '1')
{
if(gold >= 100000000)
{
gold -= 100000000;
tlt += 100;
cout << "消耗1e金币 获取100天赋点" << endl;
system("pause");
}
}
else if(nn == '2')
{
if(gold >= 900000000)
{
gold -= 900000000;
tlt += 1000;
cout << "消耗9e金币 获取1000天赋点" << endl;
system("pause");
}
}
else if(nn == '3')
{
if(gold >= 8100000000)
{
gold -= 8100000000;
tlt += 10000;
cout << "消耗81e金币 获取10000天赋点" << endl;
system("pause");
}
}
else if(nn == '4' && t[5][0] == 0)
{
if(gold >= 20000000)
{
gold -= 20000000;
tlt += 100;
cout << "消耗2000w金币 获取100天赋点" << endl;
system("pause");
}
}
}
else if(nx == '2')
{
Color(5), cout << "看广告可买一次彩票" << endl;
cout << "输入一个6位数 查看与大奖数字是否匹配!" << endl;
Color(0);
cout << "输入1看广告 输入2看奖品" << endl;
char x = input('1', '2');
if(x == '1')
{
cout << "开发中......" << endl;
}
else
{
Color(5), cout << "全部吻合 1e金币+2w天赋点" << endl;
Color(4), cout << "吻合5个 1000w金币+2000天赋点" << endl;
Color(4), cout << "吻合4个 100w金币+200天赋点" << endl;
Color(2), cout << "吻合3个 10w金币+20天赋点" << endl;
Color(2), cout << "吻合2个 1w金币+2天赋点" << endl;
Color(0), cout << "吻合1个 1w金币" << endl;
Color(0), cout << "参与奖 1000金币" << endl;
}
system("pause");
}
}
else
{
cout << "你迷失在无尽的黑暗中......" << endl;
cout << "暂时没有解锁这个功能" << endl;
system("pause");
}
}
else if(n == '7')
{
cout << "注意: 该功能极其花费时间" << endl;
cout << "使用它可能在浪费您宝贵的生命" << endl;
cout << "确认进入吗?" << endl;
system("pause");
Color(2), cout << "介绍" << endl;
Color(5), cout << "这是一个挂机之地" << endl;
Color(0), cout << "通关第3章后可以在这里挂金币" << endl;
cout << "目前您的通关层数 每10秒可获得";
int num = tx * 30 + (tx >= 10 ? tx * 10 : 0);
for(int i = 0;i <= 5;i++)
{
num += t[4][i] * 5 + t[5][i] * 10;
}
Color(5), cout << num;
Color(0), cout << "金币" << endl;
system("pause");
system("cls");
jm(16);
}
}
}
int main()
{
system("mode con cols=100 lines=25");
srand(time(0));
cout << endl << endl << endl << " ";
string x = "生活大冒险";
for(long long i = 0;i < x.size();i++)
{
Sleep(50);
cout << x[i];
}
Sleep(500);
Color(5), cout << "2";
Color(0);
Sleep(500);
cout << endl << endl << " 制作: 暗月飞霜" << endl;
Sleep(666);
GAME();
return 0;
}