原神模拟抽卡代码

原神抽卡模拟代码(3.0版本甘雨池子)

概率与游戏近似,保底无小保底,有第二次必出up五星,十连必出四星

#include 
#include 
#include 
#include 
#include 
using namespace std;
int x,y,chou;
bool card=0,sxbd=0;
int cho[1024];
char up1[64]={"甘雨*****"};
char up2[64]={"行秋****"};
char up3[64]={"砂糖****"};
char up4[64]={"多莉****"};
char oneten;
int main()
{
	sxbd=false;
	cout<<"*****************************"<>oneten;
	if(oneten=='a')
	{
		srand((int)time(NULL));
		for(int q=1;q<=10;++q)
		{
			cho[q]=rand()%741;
		}
		for(int p=1;p<=10;++p)
		{
			if(cho[p]>=24 && cho[p]<=152)
			{
				sxbd=true;
			}
		} 
		if(sxbd==false)
		{
			cho[10]=rand()%129+25;
		}
		for(int i=1;i<=10;++i)
		{
			//cout<=0 && chou<=9)
			{
				cout<<"up五星-"<=10 && chou<=23)
			{
				cout<<"up五星-"<=24 && chou<=34)
			{
				cout<<"四星-"<< up2 <=35 && chou<=45)
			{
				cout<<"四星-"<=46 && chou<=56)
			{
				cout<<"四星-"<=57 && chou<=152)
			{
				cout<<"四星-";
				if(chou==57 || chou==58)
					cout<<"香菱****"<=153 && chou<=740)
			{
				cout<<"三星-";
				if(chou>=154 && chou<=180)
				{
					cout<<"黎明神剑***"<=181 && chou<=210)
				{
					cout<<"冷刃***"<=211 && chou<=240)
				{
					cout<<"飞天御剑***"<=241 && chou<=270)
				{
					cout<<"旅行剑***"<=271 && chou<=300)
				{
					cout<<"吃虎鱼刀***"<=301 && chou<=330)
				{
					cout<<"铁影阔剑***"<=331 && chou<=360)
				{
					cout<<"沐浴龙血的剑***"<=361 && chou<=390)
				{
					cout<<"以理服人***"<=391 && chou<=420)
				{
					cout<<"石英大剑***"<=421 && chou<=450)
				{
					cout<<"飞天大御剑***"<=451 && chou<=480)
				{
					cout<<"鸦羽弓***"<=481 && chou<=510)
				{
					cout<<"信使***"<=511 && chou<=530)
				{
					cout<<"弹弓***"<=531 && chou<=560)
				{
					cout<<"反曲弓***"<=561 && chou<=590)
				{
					cout<<"讨龙英杰谭***"<=591 && chou<=620)
				{
					cout<<"魔导诸论***"<=621 && chou<=650)
				{
					cout<<"翡玉法球***"<=651 && chou<=680)
				{
					cout<<"白缨枪***"<=681 && chou<=710)
				{
					cout<<"黑缨枪***"<=711 && chou<=740)
				{
					cout<<"钺矛***"<

制作不易,点个赞憋

要就拿着吧,运行编译软件----DEV-C++

你可能感兴趣的:(c++,c语言)