Brought over a bunch of code from the roguelike and now will use it to generate a random map.

This commit is contained in:
Zed A. Shaw 2025-01-30 11:38:57 -05:00
parent 8d3d3b4ec3
commit 2daa1c9bd5
59 changed files with 4303 additions and 411 deletions

60
tests/dijkstra.json Normal file
View file

@ -0,0 +1,60 @@
[{
"input": [
[1, 1, 1, 0],
[1, 0, 1, 1],
[1, 0, 1, 1],
[1, 1, 1, 1]
],
"walls": [
[0, 0, 0, 0],
[0, 0, 0, 0],
[0, 0, 1, 0],
[0, 0, 1, 0]
],
"expected": [
[1, 1, 1, 0],
[1, 0, 1, 1],
[1, 0, 1000, 2],
[1, 1, 1000, 3]
]
},{
"input": [
[1, 1, 1, 0],
[1, 0, 1, 1],
[1, 0, 1, 1],
[1, 1, 1, 1]
],
"walls": [
[0, 0, 0, 0],
[0, 0, 0, 0],
[0, 0, 1, 0],
[0, 0, 1, 0]
],
"expected": [
[1, 1, 1, 0],
[1, 0, 1, 1],
[1, 0, 1000, 2],
[1, 1, 1000, 3]
]
},
{
"input": [
[1, 1, 1, 0],
[1, 1, 1, 1],
[1, 0, 1, 1],
[1, 1, 1, 1]
],
"walls": [
[0, 0, 0, 0],
[0, 0, 0, 0],
[0, 0, 1, 0],
[0, 0, 1, 0]
],
"expected": [
[2, 2, 1, 0],
[1, 1, 1, 1],
[1, 0, 1000, 2],
[1, 1, 1000, 3]
]
}
]