From a7026ae3e97b47079300c0901522c8395b176e6f Mon Sep 17 00:00:00 2001 From: Evil Eye Date: Sun, 26 May 2024 09:52:50 +0200 Subject: [PATCH] Make torches held by creatures emit light --- CHANGELOG.md | 1 + apps/openmw/mwrender/creatureanimation.cpp | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4ea7f5a224..690054b343 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -177,6 +177,7 @@ Bug #7970: Difference of GetPCSleep (?) behavior between vanilla and OpenMW Bug #7980: Paralyzed NPCs' lips move Bug #7997: Can toggle perspective when paralyzed + Bug #8002: Portable light sources held by creatures do not emit lighting Feature #1415: Infinite fall failsafe Feature #2566: Handle NAM9 records for manual cell references Feature #3537: Shader-based water ripples diff --git a/apps/openmw/mwrender/creatureanimation.cpp b/apps/openmw/mwrender/creatureanimation.cpp index b56035eb5f..b6cc823d28 100644 --- a/apps/openmw/mwrender/creatureanimation.cpp +++ b/apps/openmw/mwrender/creatureanimation.cpp @@ -5,6 +5,7 @@ #include #include #include +#include #include #include #include @@ -172,6 +173,9 @@ namespace MWRender SceneUtil::AssignControllerSourcesVisitor assignVisitor(std::move(source)); attached->accept(assignVisitor); + + if (item.getType() == ESM::Light::sRecordId) + addExtraLight(scene->getNode()->asGroup(), SceneUtil::LightCommon(*item.get()->mBase)); } catch (std::exception& e) {