nerfed coin/ore spawning rate by 10%
This commit is contained in:
parent
0a874da94d
commit
a96ed3b1bd
BIN
display.cmi
BIN
display.cmi
Binary file not shown.
BIN
display.cmx
BIN
display.cmx
Binary file not shown.
16
display.ml
16
display.ml
|
@ -37,9 +37,14 @@ let coin_magnet_dist = 1. ;;
|
||||||
|
|
||||||
(* -------------------------------------------------------------------------------------------------------- *)
|
(* -------------------------------------------------------------------------------------------------------- *)
|
||||||
|
|
||||||
let structure_1_frequency = 2500 ;;
|
|
||||||
(* avg number of chunk generation required before encountering a structure of type 1 *)
|
(* avg number of chunk generation required before encountering a structure of type 1 *)
|
||||||
|
let structure_1_frequency = 2500 ;;
|
||||||
|
|
||||||
|
(* 0 ~ 1000 *)
|
||||||
|
let oreMissChance = 50 ;;
|
||||||
|
|
||||||
|
(* avg number of chunk generation required before encountering a structure of type 2 *)
|
||||||
|
(* NOTE : structure 2 attempts to spawn after structure 1, so the odds will be ever so slightly less than this number *)
|
||||||
let structure_2_frequency = 2500 ;;
|
let structure_2_frequency = 2500 ;;
|
||||||
|
|
||||||
(* -------------------------------------------------------------------------------------------------------- *)
|
(* -------------------------------------------------------------------------------------------------------- *)
|
||||||
|
@ -1242,7 +1247,8 @@ let generate_structure_1 hash mem ch_x ch_y ch_z =
|
||||||
for i = 0 to chunk_size -1 do
|
for i = 0 to chunk_size -1 do
|
||||||
for j = 0 to chunk_size -1 do
|
for j = 0 to chunk_size -1 do
|
||||||
for k = 0 to chunk_size -1 do
|
for k = 0 to chunk_size -1 do
|
||||||
dyn_append filled {flag = "10" ; cube = create_cube (chx*chunk_size+i) (chy*chunk_size+j) (chz*chunk_size+k) 1; red = 250; green = 250; blue = 64};
|
if (Random.int 1000 >= oreMissChance) then
|
||||||
|
dyn_append filled {flag = "10" ; cube = create_cube (chx*chunk_size+i) (chy*chunk_size+j) (chz*chunk_size+k) 1; red = 250; green = 250; blue = 64};
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
done;
|
done;
|
||||||
|
@ -1353,8 +1359,10 @@ let generate_structure_2 hash mem ch_x ch_y ch_z =
|
||||||
for i = 0 to chunk_size -1 do
|
for i = 0 to chunk_size -1 do
|
||||||
for j = 0 to chunk_size -1 do
|
for j = 0 to chunk_size -1 do
|
||||||
for k = 0 to chunk_size -1 do
|
for k = 0 to chunk_size -1 do
|
||||||
let (cOre, cColors) = generate_random_ore () in
|
if (Random.int 1000 >= oreMissChance) then begin
|
||||||
dyn_append filled {flag = cOre ; cube = create_cube (chx*chunk_size+i) (chy*chunk_size+j) (chz*chunk_size+k) 1; red = cColors.(0); green = cColors.(1); blue = cColors.(2)};
|
let (cOre, cColors) = generate_random_ore () in
|
||||||
|
dyn_append filled {flag = cOre ; cube = create_cube (chx*chunk_size+i) (chy*chunk_size+j) (chz*chunk_size+k) 1; red = cColors.(0); green = cColors.(1); blue = cColors.(2)};
|
||||||
|
end
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
done;
|
done;
|
||||||
|
|
Loading…
Reference in New Issue