v2.4.0: adjusted secret rooms to use the same queueing as special rooms
This commit is contained in:
+6
-9
@@ -88,15 +88,12 @@ public abstract class SecretRoom extends SpecialRoom {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static SecretRoom createRoom(){
|
public static SecretRoom createRoom(){
|
||||||
|
|
||||||
SecretRoom r = null;
|
//60% chance for front of queue, 30% chance for next, 10% for one after that
|
||||||
int index = runSecrets.size();
|
int index = Random.chances(new float[]{6, 3, 1});
|
||||||
for (int i = 0; i < 4; i++){
|
while (index >= runSecrets.size()) index--;
|
||||||
int newidx = Random.Int( runSecrets.size() );
|
|
||||||
if (newidx < index) index = newidx;
|
SecretRoom r = Reflection.newInstance(runSecrets.get( index ));
|
||||||
}
|
|
||||||
|
|
||||||
r = Reflection.newInstance(runSecrets.get( index ));
|
|
||||||
|
|
||||||
runSecrets.add(runSecrets.remove(index));
|
runSecrets.add(runSecrets.remove(index));
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user