dartfmt
This commit is contained in:
parent
4074f49228
commit
3676264444
1 changed files with 10 additions and 3 deletions
|
@ -32,7 +32,14 @@ class Grid {
|
|||
|
||||
void reset() {
|
||||
map.setAll(0, _buildGrid(w, h));
|
||||
if(_startingSeed != null) addPattern(pattern: _pattern, dispersal: _dispersal,amount: _amount,seed: _startingSeed, x: _x, y: _y);
|
||||
if (_startingSeed != null)
|
||||
addPattern(
|
||||
pattern: _pattern,
|
||||
dispersal: _dispersal,
|
||||
amount: _amount,
|
||||
seed: _startingSeed,
|
||||
x: _x,
|
||||
y: _y);
|
||||
_dirty = true;
|
||||
}
|
||||
|
||||
|
@ -81,7 +88,7 @@ class Grid {
|
|||
? i--
|
||||
: setCellState(cx + rng.nextInt(_dispersal),
|
||||
cy + rng.nextInt(_dispersal), true);
|
||||
if (sanityCheck > 100 && sanityCheck > i*3) break;
|
||||
if (sanityCheck > 100 && sanityCheck > i * 3) break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -180,7 +187,7 @@ class Grid {
|
|||
|
||||
for (int y = 0; y < map.length; y++) {
|
||||
for (int x = 0; x < map[y].length; x++) {
|
||||
if(_renderEdges) {
|
||||
if (_renderEdges) {
|
||||
ctx.setStrokeColorRgb(100, 100, 100);
|
||||
ctx.strokeRect(x * brickW, y * brickH, brickW, brickH);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue