mirror of
https://github.com/XProger/OpenLara.git
synced 2025-02-25 07:52:43 +01:00
#23 fix ambient cubes for cutscene actors
This commit is contained in:
parent
695678c86e
commit
7b88afaaae
@ -1369,11 +1369,9 @@ struct Level : IGame {
|
||||
vec3 pos = controller->getPos();
|
||||
if (ambientCache) {
|
||||
AmbientCache::Cube cube;
|
||||
if (Core::stats.frame != controller->jointsFrame) {
|
||||
ambientCache->getAmbient(roomIndex, pos, cube);
|
||||
if (cube.status == AmbientCache::Cube::READY)
|
||||
memcpy(controller->ambient, cube.colors, sizeof(cube.colors)); // store last calculated ambient into controller
|
||||
}
|
||||
ambientCache->getAmbient(roomIndex, pos, cube);
|
||||
if (cube.status == AmbientCache::Cube::READY)
|
||||
memcpy(controller->ambient, cube.colors, sizeof(cube.colors)); // store last calculated ambient into controller
|
||||
Core::active.shader->setParam(uAmbient, controller->ambient[0], 6);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user