跳到正文

个人记录

小游戏

fsc0190约 2 分钟
原文
文章信息与版本

文章信息

发布
2023年3月19日
收录
2025年12月12日
更新
2026年11月21日
篇幅
约 2 分钟

版本

  1. v1当前
C
#include<bits/stdc++.h>
using namespace std;
int hp,maxhp = 100;
int ap = 10;
int hp = 0;
int lv = 1;
int bosslv = 0;
int jinbi = 50;
int main()
{
	cout << "打怪小游戏,";
	Sleep(500);
	cout << "作者";
	Sleep(500);
	cout << ":";
	Sleep(500);
	cout << "f";
	Sleep(500);
	cout << "s";
	Sleep(500);
	cout << "c";
	Sleep(500);
	cout << "0";
	Sleep(500);
	cout << "1";
	Sleep(500);
	cout << "9";
	Sleep(500);
	cout << "0";
	Sleep(1500);
	cout << endl << "要开始游戏吗?要则输入1,否则输入2";
	Sleep(500);
	char a;
	cin >> a;
	if (a == '2')
	{
		cout << "不想玩就别玩了,也别出去了";
		Sleep(1000000);
	}
	else if (a = '1')
	{
		while (bosslv != 10)
		{
			int a;
			cout << "1.商店 2.打怪 3.状态";
			cin >> a;
			if (a == 1)
			{
				cout << "1.血加50 50金币 2.血加500 400金币 3.攻击加5 50金币 4.攻击加50 400金币 5.神秘盲盒 0金币"
			}
			else if (a == 2)
			{
				int x;
				cout << "1.小怪 2.中怪 3.大怪 4.将领 5.大boss"; 
				cin >> x;
				cin >> sum;
				if (x == 1)
				{
					sum = 20;
					cout << 
				}
			} 
		}
	}
	return 0;
}
原文