-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathGodDrinksJava.java
128 lines (114 loc) · 2.98 KB
/
GodDrinksJava.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
package goddrinksjava;
/**
* The program GodDrinksJava implements an application that
* creates an empty simulated world with no meaning or purpose.
*
* @author momocashew
*/
public class GodDrinksJava {
public static void main(String[] args) {
Thing me = new Lovable("Me", 0, true, -1, false);
Thing you = new Lovable("You", 0, false, -1, false);
World world = new World(5);
world.addThing(me);
world.addThing(you);
world.startSimulation();
if (me instanceof PointSet) {
you.addAttribute(me.getDimensions().toAttribute());
me.resetDimensions();
}
if (me instanceof Circle) {
you.addAttribute(me.getCircumference().toAttribute());
me.resetCircumference();
}
if (me instanceof SineWave) {
you.addAction("sit", me.getTangent(you.getXPosition()));
}
if (me instanceof Sequence) {
me.setLimit(you.toLimit());
}
me.toggleCurrent();
me.canSee(false);
me.addFeeling("dizzy");
world.timeTravelForTwo("AD", 617, me, you);
world.timeTravelForTwo("BC", 3691, me, you);
world.unite(me, you);
if (me.getNumStimulationsAvailable() >=
you.getNumStimulationsNeeded()) {
you.setSatisfaction(me.toSatisfaction());
}
if (you.getFeelingIndex("happy") != -1) {
me.requestExecution(world);
}
world.lockThing(me);
world.lockThing(you);
if (me instanceof Eggplant) {
you.addAttribute(me.getNutrients().toAttribute());
me.resetNutrients();
}
if (me instanceof Tomato) {
you.addAttribute(me.getAntioxidants().toAttribute());
me.resetAntioxidants();
}
if (me instanceof TabbyCat) {
me.purr();
}
if (world.getGod().equals(me)) {
me.setProof(you.toProof());
}
me.toggleGender();
world.procreate(me, you);
me.toggleRoleBDSM();
world.makeHigh(me);
world.makeHigh(you);
if (me.getSenseIndex("vibration")) {
me.addFeeling("complete");
}
world.unlock(you);
world.removeThing(you);
me.lookFor(you, world);
me.lookFor(you, world);
me.lookFor(you, world);
me.lookFor(you, world);
me.lookFor(you, world);
if (me.getMemory().isErasable()) {
me.removeFeeling("disheartened");
}
try {
me.setOpinion(me.getOpinionIndex("you are here"), false);
} catch (IllegalArgumentException e) {
world.announce("God is always true.");
}
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.runExecution();
world.announce("1", "de");
world.announce("2", "es");
world.announce("3", "fr");
world.announce("4", "kr");
world.announce("5", "se");
world.announce("6", "cn");
world.runExecution();
if (world.isExecutableBy(me)) {
you.setExecution(me.toExecution());
}
if (world.getThingIndex(you) != -1) {
world.runExecution();
}
me.escape(world);
me.learnTopic("love");
me.takeExamTopic("love");
me.getAlgebraicExpression("love");
me.escape("love");
world.execute(me);
}
}