From 5282556ae0eb706a6debe4708c9d0eba41e76529 Mon Sep 17 00:00:00 2001 From: Allofich Date: Wed, 22 Mar 2017 19:55:48 +0900 Subject: [PATCH] Show names on combat actors when RMB GUI is active Fixes (#3797) --- apps/openmw/mwclass/creature.cpp | 2 +- apps/openmw/mwclass/npc.cpp | 2 +- apps/openmw/mwworld/worldimp.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/openmw/mwclass/creature.cpp b/apps/openmw/mwclass/creature.cpp index 8c663474f..51e0bdcce 100644 --- a/apps/openmw/mwclass/creature.cpp +++ b/apps/openmw/mwclass/creature.cpp @@ -546,7 +546,7 @@ namespace MWClass bool Creature::hasToolTip(const MWWorld::ConstPtr& ptr) const { - if (!ptr.getRefData().getCustomData()) + if (!ptr.getRefData().getCustomData() || MWBase::Environment::get().getWindowManager()->isGuiMode()) return true; const CreatureCustomData& customData = ptr.getRefData().getCustomData()->asCreatureCustomData(); diff --git a/apps/openmw/mwclass/npc.cpp b/apps/openmw/mwclass/npc.cpp index 38d288062..3b7b24981 100644 --- a/apps/openmw/mwclass/npc.cpp +++ b/apps/openmw/mwclass/npc.cpp @@ -1007,7 +1007,7 @@ namespace MWClass bool Npc::hasToolTip(const MWWorld::ConstPtr& ptr) const { - if (!ptr.getRefData().getCustomData()) + if (!ptr.getRefData().getCustomData() || MWBase::Environment::get().getWindowManager()->isGuiMode()) return true; const NpcCustomData& customData = ptr.getRefData().getCustomData()->asNpcCustomData(); diff --git a/apps/openmw/mwworld/worldimp.cpp b/apps/openmw/mwworld/worldimp.cpp index 851b02ba8..4270a112c 100644 --- a/apps/openmw/mwworld/worldimp.cpp +++ b/apps/openmw/mwworld/worldimp.cpp @@ -1039,7 +1039,7 @@ namespace MWWorld facedObject = getFacedObject(activationDistance, true); if (!facedObject.isEmpty() && !facedObject.getClass().allowTelekinesis(facedObject) - && mDistanceToFacedObject > getMaxActivationDistance()) + && mDistanceToFacedObject > getMaxActivationDistance() && !MWBase::Environment::get().getWindowManager()->isGuiMode()) return 0; } return facedObject;