added random money generation throughout the maze

This commit is contained in:
Alexandre 2024-07-12 20:16:49 +02:00
parent 8553435526
commit 17725892fe
5 changed files with 3 additions and 0 deletions

BIN
a.out

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1061,6 +1061,9 @@ let init_chunk_all hash mem ch_x ch_y ch_z =
for k = 0 to n_cubes -1 do for k = 0 to n_cubes -1 do
if (Random.int 101) < density then if (Random.int 101) < density then
dyn_append dyna {flag = "terrain" ; cube = create_cube (chunk_size*ch_x + cube_size*i) (chunk_size*ch_y + cube_size*j) (chunk_size*ch_z + cube_size*k) cube_size; red = 250; green = 250; blue = 250} dyn_append dyna {flag = "terrain" ; cube = create_cube (chunk_size*ch_x + cube_size*i) (chunk_size*ch_y + cube_size*j) (chunk_size*ch_z + cube_size*k) cube_size; red = 250; green = 250; blue = 250}
else if (Random.int 101) = 0 then begin
dyn_append dyna {flag = "5" ; cube = create_cube (chunk_size*ch_x + cube_size*i) (chunk_size*ch_y + cube_size*j) (chunk_size*ch_z + cube_size*k) 1; red = 200; green = 200; blue = 64};
end
done done
done done
done; done;

BIN
display.o

Binary file not shown.