Better lighting and a circle algorithm that works more reliably.
This commit is contained in:
parent
03fe9b3d01
commit
35f2defc11
9 changed files with 97 additions and 87 deletions
|
@ -143,7 +143,7 @@ void WorldBuilder::generate() {
|
|||
|
||||
Point center = $map.place_entity(1);
|
||||
for(matrix::circle it{center, 3}; it.next();) {
|
||||
for(int x = it.x0; x < it.x1; x++) {
|
||||
for(int x = it.left; x < it.right; x++) {
|
||||
if($map.inmap(x, it.y) && !$map.iswall(x, it.y)) {
|
||||
$map.$tiles.set_tile(x, it.y, "WATER_TILE");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue