Made lithification chance changeable
0.0003 is still the default
This commit is contained in:
parent
a61d3f857b
commit
ad6e2ea8fc
|
|
@ -13,9 +13,9 @@ Proper classification of limestone within these code comments
|
||||||
|
|
||||||
//Generalized sedimentation function
|
//Generalized sedimentation function
|
||||||
|
|
||||||
function sedimentation(pixel,sedimentNeighborTable,finalRock) {
|
function sedimentation(pixel,sedimentNeighborTable,finalRock,chance=0.0003) {
|
||||||
|
if(Math.random() < chance) {
|
||||||
var validNeighborArray = Array.apply(null, Array(adjacentCoords.length)).map(function() {return false});
|
var validNeighborArray = Array.apply(null, Array(adjacentCoords.length)).map(function() {return false});
|
||||||
if(Math.random() < 0.0003) {
|
|
||||||
//sedimentSandstoneTries++;
|
//sedimentSandstoneTries++;
|
||||||
for(i = 0; i < adjacentCoords.length; i++) {
|
for(i = 0; i < adjacentCoords.length; i++) {
|
||||||
//sedimentSandstoneTryIterations++;
|
//sedimentSandstoneTryIterations++;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue