Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support NiSwitchNode #2141

merged 1 commit into from Jan 23, 2019


None yet
2 participants
Copy link

akortunov commented Jan 23, 2019

Implements feature #4812.

In upstream master we handle the NiSwitchNode as a common NiNode (render all children), while vanilla Morrowind renders just its first child (and MGE improves its loading, so it is possible to switch between its children).

This PR creates an osg::Switch for every NiSwitchNode, so it is possible so set current active child:


By default only first children is rendered.

Note: autogenerated collisions still will be based on all node children in both Morrowind and OpenMW, so it is recommended to use either NiRootCollisionNode or NCO for such meshes.

Switch nodes will allow us to implement some extended features (such as native herbalism or glowing windows) and it does not matter if they will be hardcoded or handled via Lua scripting with scene graph access (probably based on existing Lua bindings for OpenSceneGraph).


This comment has been minimized.

Copy link

psi29a commented Jan 23, 2019

LGTM, sweet!

@psi29a psi29a merged commit 8ddb45e into OpenMW:master Jan 23, 2019

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
continuous-integration/travis-ci/pr The Travis CI build passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.