Remove unnecessary Simulation variables
This commit is contained in:
parent
27d4879b1b
commit
9b2b5f3e55
1 changed files with 0 additions and 6 deletions
|
@ -14,11 +14,8 @@ class Simulation {
|
||||||
bool _renderEdges = true;
|
bool _renderEdges = true;
|
||||||
|
|
||||||
int _startingSeed;
|
int _startingSeed;
|
||||||
int _x;
|
|
||||||
int _y;
|
|
||||||
int _amount;
|
int _amount;
|
||||||
int _dispersal;
|
int _dispersal;
|
||||||
CellPattern _pattern;
|
|
||||||
|
|
||||||
int get w => map.width;
|
int get w => map.width;
|
||||||
int get h => map.height;
|
int get h => map.height;
|
||||||
|
@ -42,11 +39,8 @@ class Simulation {
|
||||||
int seed}) {
|
int seed}) {
|
||||||
_startingSeed = seed ?? DateTime.now().millisecondsSinceEpoch;
|
_startingSeed = seed ?? DateTime.now().millisecondsSinceEpoch;
|
||||||
math.Random rng = new math.Random(_startingSeed);
|
math.Random rng = new math.Random(_startingSeed);
|
||||||
_x = x;
|
|
||||||
_y = y;
|
|
||||||
_amount = amount ?? rng.nextInt(20);
|
_amount = amount ?? rng.nextInt(20);
|
||||||
_dispersal = dispersal ?? 10;
|
_dispersal = dispersal ?? 10;
|
||||||
_pattern = pattern;
|
|
||||||
int cx = x ?? rng.nextInt(map.width ~/ 3) + (map.width ~/ 3);
|
int cx = x ?? rng.nextInt(map.width ~/ 3) + (map.width ~/ 3);
|
||||||
int cy = y ?? rng.nextInt(map.height ~/ 3) + (map.height ~/ 3);
|
int cy = y ?? rng.nextInt(map.height ~/ 3) + (map.height ~/ 3);
|
||||||
switch (pattern) {
|
switch (pattern) {
|
||||||
|
|
Loading…
Reference in a new issue