Project

General

Profile

Feature #2666

Make body and its animation visible from 1st person

Added by Jan Štěpánek over 2 years ago. Updated 2 days ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Rendering
Target version:
Start date:
06/12/2015
% Done:

0%

Severity:
Normal

Description

It would be nice to see player's body and 3rd person animations from 1st person view like in Arx Fatalis or Arma for example.

Here is some example and inspiration made by Darknut for Morrowind:
https://www.youtube.com/watch?v=qS-ADPbNh1g
https://www.youtube.com/watch?v=YgxnCH0-9V4
https://www.youtube.com/watch?v=EA7frLIW8_I


Related issues

Duplicated by OpenMW - Feature #3210: Full Body view while in 1st Person Rejected 02/22/2016

History

#1 Updated by scrawl . over 2 years ago

  • Target version set to openmw-future

#2 Updated by scrawl . over 1 year ago

  • Duplicated by Feature #3210: Full Body view while in 1st Person added

#3 Updated by Sergey "Shnatsel" Davidoff over 1 year ago

Getting third-person swimming animations in first person requires a binary hack on the vanilla engine (see Darknut's First Person Enhanced 2.0). It'd be great to be able to do this cleanly.

#4 Updated by scrawl . over 1 year ago

Just for fun:

https://youtu.be/8_Um8tnmLLs

diff --git a/apps/openmw/mwrender/camera.cpp b/apps/openmw/mwrender/camera.cpp
index 5a3f2be..467947b 100644
--- a/apps/openmw/mwrender/camera.cpp
+++ b/apps/openmw/mwrender/camera.cpp
@@ -1,6 +1,7 @@
 #include "camera.hpp" 

 #include <osg/Camera>
+#include <osg/PositionAttitudeTransform>

 #include <components/sceneutil/positionattitudetransform.hpp>

@@ -370,10 +371,17 @@ namespace MWRender
     {
         if(isFirstPerson())
         {
-            mAnimation->setViewMode(NpcAnimation::VM_FirstPerson);
+            //mAnimation->setViewMode(NpcAnimation::VM_FirstPerson);
             mTrackingNode = mAnimation->getNode("Camera");
             if (!mTrackingNode)
                 mTrackingNode = mAnimation->getNode("Head");
+
+            osg::ref_ptr<osg::PositionAttitudeTransform> node2 = new osg::PositionAttitudeTransform;
+            const_cast<osg::Node*>(mTrackingNode.get())->asGroup()->addChild(node2);
+            node2->setPosition(osg::Vec3f(0,-10,0));
+            mTrackingNode = node2;
+
+
             mHeightScale = 1.f;
         }
         else

#5 Updated by Will Herrmann 3 months ago

If we have a basic implementation for this, is there any reason we can't add it to the game, probably in the GUI Settings Section?

It was very well received in this Reddit post and I think would help convince people to try OpenMW if it was on the features list.

#6 Updated by Alexei Dobrohotov 2 days ago

  • Category set to Rendering

Also available in: Atom PDF