This implements base ambient lighting for tiles which helps with tiles like lava and ceiling lights.

This commit is contained in:
Zed A. Shaw 2025-05-29 12:34:25 -04:00
parent 74a1801069
commit 3dc70c3af6
11 changed files with 48 additions and 17 deletions

View file

@ -99,8 +99,7 @@ size_t LevelManager::create_level(shared_ptr<DinkyECS::World> prev_world) {
auto player = world->get_the<Player>();
$levels.emplace_back(index, player.entity, map, world,
make_shared<LightRender>(map->width(), map->height()),
collider);
make_shared<LightRender>(map->tiles()), collider);
dbc::check(index == $levels.size() - 1, "Level index is not the same as $levels.size() - 1, off by one error");
return index;