Procházet zdrojové kódy

Bring back special case for the first victim with nothing found yet - needed so that we avoid stomping nothing at all

tags/v1.1.2
Fen Dweller před 5 roky
rodič
revize
34a39643b5
1 změnil soubory, kde provedl 4 přidání a 1 odebrání
  1. +4
    -1
      recursive-macro.js

+ 4
- 1
recursive-macro.js Zobrazit soubor

@@ -405,7 +405,10 @@ function fill_area(area, weights, variance=0.15)

while (loopvar < limit) {
if (loopvar <= clusters[candidate.name]) {
if (loopvar == 0 && result.length == 0) {
++count;
}
else if (loopvar <= clusters[candidate.name]) {
if (Math.random() < candidate.weight ? 1 : Math.random() < cluster_chances[candidate.name]) {
++count;
}


Načítá se…
Zrušit
Uložit