This repository has been archived by the owner on Sep 7, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
wrap_port.java
150 lines (141 loc) · 4.98 KB
/
wrap_port.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
import java.io.*;
public class wrap_port
{
void main()throws Exception
{
LOADING z=new LOADING();
z.loading();
BufferedReader br=new BufferedReader(new InputStreamReader(System.in));
String s=" ";
int a=50;
int c=0;
Double b=1.0;
disp_warp ui=new disp_warp();
ui.disp();
Thread.sleep(1000);
System.out.println("\u000c");
for(int i=0;i<a;a--)
{
if(b==a){
System.out.print(" you|");continue;
}
if(c!=10){
if(a>=10)System.out.print(" "+a+" |");
else System.out.print(" "+a+" |");
}
else{
System.out.println();
System.out.print("__________________________________________________");
System.out.println();
System.out.print(" "+a+" |");
c=0;
}
c++;
}
a=50;
c=0;
System.out.println("\nTIME TO PLAY");
Double roll=0.0,u=0.0;
for(;;)
{
System.out.println("\nType anything to roll the dice");
s=br.readLine();
roll=0.0;
u=0.0;
roll=(Math.random()*6-2)+2;
u=Math.ceil(roll);
System.out.println("you got "+u);
Thread.sleep(1500);
System.out.println("\u000c");
if(b+u==10||b+u==8||b+u==26||b+u==34||b+u==18||b+u==23||b+u==5||b+u==31||b+u==40||b+u==41){
System.out.println("You landed on a warp!!");
roll=(Math.random()*10-(-10)-10);
u=Math.ceil(roll); }
if(b+u==13){System.out.println("You landed on a portal!!");
System.out.println("you teleported to 26 :)");
b=26.0;
Thread.sleep(2000);
System.out.println("\u000c");
}
if(b+u==26){System.out.println("You landed on a portal!!");
System.out.println("you teleported to 13 :(");
b=13.0;
Thread.sleep(2000);
System.out.println("\u000c");
}
if(b+u==45){System.out.println("You landed on a portal!!");
System.out.println("you teleported to 36 :(");
b=36.0;
Thread.sleep(2000);
System.out.println("\u000c");
}
if(b+u==36){System.out.println("You landed on a portal!!");
System.out.println("you teleported to 45 :)");
b=45.0;
Thread.sleep(2000);
System.out.println("\u000c");
}
if(b+u==2){System.out.println("You landed on a portal!!");
System.out.println("you teleported to 33 :)");
b=33.0;
Thread.sleep(2000);
System.out.println("\u000c");
}
if(b+u==33){System.out.println("You landed on a portal!!");
System.out.println("you teleported to 2 :(");
b=2.0;
Thread.sleep(2000);
System.out.println("\u000c");
}
if(b+u==21){System.out.println("You landed on a portal!!");
System.out.println("you teleported to 31 :)");
b=31.0;
Thread.sleep(2000);
System.out.println("\u000c");
}
if(b+u==31){System.out.println("You landed on a portal!!");
System.out.println("you teleported to 21 :(");
b=21.0;
Thread.sleep(2000);
System.out.println("\u000c");
}
if(b>=50){
System.out.println("YOU DID IT");
break;
}
b+=u;
for(int i=0;i<a;a--)
{
if(b==a){
if(b%10!=0){
c++;
System.out.print(" you|");continue;
}
else{
System.out.println();
System.out.print("__________________________________________________");
System.out.println();
System.out.print(" you|");
c=0;
}
continue;
}
if(c!=10){
if(a>=10)System.out.print(" "+a+" |");
else System.out.print(" "+a+" |");
}
else{
System.out.println();
System.out.print("__________________________________________________");
System.out.println();
System.out.print(" "+a+" |");
c=0;
}
c++;
}
a=50;
c=0;
}
System.out.println("\u000c");
}
}