File tree 1 file changed +4
-4
lines changed
src/main/java/seprini/controllers
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -134,11 +134,11 @@ public void update(float delta) throws InterruptedException {
134
134
Art .getSound ("warning" ).play (1.0f );
135
135
}
136
136
137
- // If the number of aircraft is below the maximum permitted, or the time
138
- // elapsed since the last generation is less than
137
+ // If the number of aircraft is below the maximum permitted and the time
138
+ // elapsed since the last generation is greater than the preset
139
139
// time difference between aircraft generated, create a new aircraft
140
- if (aircraftList .size () > difficulty .getMaxAircraft ()
141
- || timer - lastGenerated > difficulty
140
+ if (aircraftList .size () < difficulty .getMaxAircraft ()
141
+ && timer - lastGenerated > difficulty
142
142
.getTimeBetweenGenerations () + rand .nextInt (100 )) {
143
143
final Aircraft generatedAircraft = generateAircraft ();
144
144
You can’t perform that action at this time.
0 commit comments