modestly randomise dab, bump points again.
authornemo
Sat, 15 Nov 2014 09:26:08 -0500
changeset 10499 0d8016085108
parent 10498 bcd1d7ad2f3e
child 10500 585a33f2d105
modestly randomise dab, bump points again.
hedgewars/uConsts.pas
hedgewars/uLandGenTemplateBased.pas
--- a/hedgewars/uConsts.pas	Sat Nov 15 13:52:07 2014 +0300
+++ b/hedgewars/uConsts.pas	Sat Nov 15 09:26:08 2014 -0500
@@ -151,7 +151,7 @@
     cMaxHHIndex      = 7;
     cMaxHHs          = 48;
 
-    cMaxEdgePoints = 24576;
+    cMaxEdgePoints = 32768;
 
     cHHRadius = 9;
     cHHStepTicks = 29;
--- a/hedgewars/uLandGenTemplateBased.pas	Sat Nov 15 13:52:07 2014 +0300
+++ b/hedgewars/uLandGenTemplateBased.pas	Sat Nov 15 09:26:08 2014 -0500
@@ -6,7 +6,7 @@
 procedure GenTemplated(var Template: TEdgeTemplate);
 procedure DivideEdges(fillPointsCount: LongWord; var pa: TPixAr);
 
-var minDistance: LongInt; // different details size
+var minDistance, dabDiv: LongInt; // different details size
 
 implementation
 uses uVariables, uConsts, uFloat, uLandUtils, uRandom, SDLh, math;
@@ -261,7 +261,7 @@
 
     // don't move new point for more than length of initial segment
     // adjust/parametrize for more flat surfaces (try values 3/4, 1/2 of dab, or even 1/4)
-    d:= dab;
+    d:= dab * 100 div dabDiv;
     //d:= dab * (1 + abs(cFeatureSize - 8)) div 6;
     //d:= dab * (14 + cFeatureSize) div 20;
     if distL > d then distL:= d;
@@ -345,6 +345,9 @@
             Land[y, x]:= lfBasic;
     
     minDistance:= sqr(cFeatureSize) div 8 + 10;
+    //dabDiv:= getRandom(41)+60;
+    //dabDiv:= getRandom(31)+70;
+    dabDiv:= getRandom(21)+100;
     MaxHedgehogs:= Template.MaxHedgehogs;
     hasGirders:= Template.hasGirders;
     playHeight:= Template.TemplateHeight;