소스 검색

Important fix that prevents treasures from sealing off, adding too many blocked tiles.

DjWarmonger 11 년 전
부모
커밋
fe180335de
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      lib/rmg/CRmgTemplateZone.cpp

+ 3 - 1
lib/rmg/CRmgTemplateZone.cpp

@@ -814,7 +814,9 @@ bool CRmgTemplateZone::createTreasurePile(CMapGenerator* gen, int3 &pos, float m
 			}
 			if (placeFound.valid())
 				info.nextTreasurePos = placeFound;
-			}
+			else
+				break; //no more place to add any objects
+		}
 	}
 
 	if (treasures.size())