1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-29 18:32:36 +00:00

Merge pull request #3198 from akortunov/master

Early out from LOS check when source and target is the same
This commit is contained in:
Bret Curtis 2021-10-27 11:28:03 +02:00 committed by GitHub
commit 299f8c3fe7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 0 deletions

View File

@ -26,6 +26,7 @@
Bug #5801: A multi-effect spell with the intervention effects and recall always favors Almsivi intervention
Bug #5842: GetDisposition adds temporary disposition change from different actors
Bug #5863: GetEffect should return true after the player has teleported
Bug #5913: Failed assertion during Ritual of Trees quest
Bug #6037: Morrowind Content Language Cannot be Set to English in OpenMW Launcher
Bug #6051: NaN water height in ESM file is not handled gracefully
Bug #6066: addtopic "return" does not work from within script. No errors thrown

View File

@ -370,6 +370,8 @@ namespace MWPhysics
bool PhysicsSystem::getLineOfSight(const MWWorld::ConstPtr &actor1, const MWWorld::ConstPtr &actor2) const
{
if (actor1 == actor2) return true;
const auto it1 = mActors.find(actor1.mRef);
const auto it2 = mActors.find(actor2.mRef);
if (it1 == mActors.end() || it2 == mActors.end())