fix infinite loop in landgen
authoralfadur
Fri, 02 Nov 2018 20:46:17 +0300
changeset 14093 dbaa125a0fe9
parent 14092 32a34bf70f65
child 14094 d0b0d61b7d5e
fix infinite loop in landgen
rust/landgen/src/outline.rs
--- a/rust/landgen/src/outline.rs	Fri Nov 02 20:30:13 2018 +0300
+++ b/rust/landgen/src/outline.rs	Fri Nov 02 20:46:17 2018 +0300
@@ -170,7 +170,7 @@
             let old_len = self.total_len();
             self.divide_edges(random_numbers);
 
-            if self.total_len() != old_len {
+            if self.total_len() == old_len {
                 break;
             }
         }