package main;
import java.util.Random;
import java.util.Scanner;
import javax.swing.JOptionPane;
public class main {
public static void main(String [] args){
Scanner sc = new Scanner(System.in);
Random rm = new Random();
double sday = 1000000;
int xday = 1000000;//rm.nextInt(1000000) + 500000;
double inf = 0;
int b, a, c, d = 0;
System.out.println("How many Days do you want to simulate?");
int rounds = Integer.parseInt(sc.next());
System.out.println("How many Option do you want to show?");
int options = Integer.parseInt(sc.next());
System.out.println("Money: " + xday);
for(int i = 0; i < rounds ; i++){
int WhitePotion = 1200;
inf = xday/sday;
if(inf > 1.2){
inf = inf + d;
d++;
}else if(inf < 1.2){
d = 0;
}else if(inf < 0.8){
d = 0;
inf = 0.5;
}
//System.out.println(inf + ":" + xday + "/" + sday);
WhitePotion = (int) (WhitePotion * inf);
xday = xday + ((a = rm.nextInt(100000)) - (c = ((b = rm.nextInt(100)) * WhitePotion)));
switch(options){
case 1:
System.out.println("Inf Value: " + inf);
break;
case 2:
System.out.println("WhitePotion costs: " + WhitePotion);
break;
case 3:
System.out.println("Bought " + b + " WhitePotions" );
break;
case 4:
System.out.println("Money on Server: " + xday);
break;
case 5:
System.out.println("Debug Values: " + xday + " : " + a + " : " + c);
break;
default:
System.out.println("Inf Value: " + inf);
System.out.println("WhitePotion costs: " + WhitePotion);
System.out.println("Bought " + b + " WhitePotions" );
System.out.println("Money on Server: " + xday);
System.out.println("Debug Values: " + xday + " : " + a + " : " + c);
System.out.println("---------------------------");
break;
}
}
}
}