mirror of
https://github.com/XProger/OpenLara.git
synced 2025-08-13 16:44:50 +02:00
fix pickups brightness
This commit is contained in:
@@ -1954,11 +1954,12 @@ struct Level : IGame {
|
|||||||
|
|
||||||
vec3 pos = controller->getPos();
|
vec3 pos = controller->getPos();
|
||||||
if (ambientCache) {
|
if (ambientCache) {
|
||||||
if (!entity.isDoor() && !entity.isBlock()) { // no advanced ambient lighting for secret (all) doors and blocks
|
if (!entity.isDoor() && !entity.isBlock() && !entity.isPickup()) { // no advanced ambient lighting for secret (all) doors and blocks
|
||||||
AmbientCache::Cube cube;
|
AmbientCache::Cube cube;
|
||||||
ambientCache->getAmbient(roomIndex, pos, cube);
|
ambientCache->getAmbient(roomIndex, pos, cube);
|
||||||
if (cube.status == AmbientCache::Cube::READY)
|
if (cube.status == AmbientCache::Cube::READY) {
|
||||||
memcpy(controller->ambient, cube.colors, sizeof(cube.colors)); // store last calculated ambient into controller
|
memcpy(controller->ambient, cube.colors, sizeof(cube.colors)); // store last calculated ambient into controller
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
controller->ambient[0] =
|
controller->ambient[0] =
|
||||||
controller->ambient[1] =
|
controller->ambient[1] =
|
||||||
|
Reference in New Issue
Block a user