diff --git a/components/nif/niffile.cpp b/components/nif/niffile.cpp index 0edabdd7a7..f806c61bc1 100644 --- a/components/nif/niffile.cpp +++ b/components/nif/niffile.cpp @@ -49,180 +49,265 @@ namespace Nif static std::map makeFactory() { return { + // 4.0.0.2 refers to Bethesda variant of NetImmerse 4.0.0.2 file format + // Gamebryo refers to files newer than 4.0.0.2 + // Bethesda refers to custom records Bethesda introduced post-4.0.0.2 + + // NODES + + // NiNode-like nodes, 4.0.0.2 { "NiNode", &construct }, - { "NiSwitchNode", &construct }, - { "NiLODNode", &construct }, - { "NiFltAnimationNode", &construct }, { "AvoidNode", &construct }, - { "NiCollisionSwitch", &construct }, - { "NiBSParticleNode", &construct }, - { "NiBSAnimationNode", &construct }, { "NiBillboardNode", &construct }, - { "NiTriShape", &construct }, - { "NiTriStrips", &construct }, - { "NiLines", &construct }, - { "NiParticles", &construct }, - { "NiRotatingParticles", &construct }, - { "NiAutoNormalParticles", &construct }, - { "NiCamera", &construct }, + { "NiBSAnimationNode", &construct }, + { "NiBSParticleNode", &construct }, + { "NiCollisionSwitch", &construct }, + { "NiSortAdjustNode", &construct }, { "RootCollisionNode", &construct }, - { "NiTexturingProperty", &construct }, - { "NiFogProperty", &construct }, - { "NiMaterialProperty", &construct }, - { "NiZBufferProperty", &construct }, - { "NiAlphaProperty", &construct }, - { "NiVertexColorProperty", &construct }, - { "NiShadeProperty", &construct }, - { "NiDitherProperty", &construct }, - { "NiWireframeProperty", &construct }, - { "NiSpecularProperty", &construct }, - { "NiStencilProperty", &construct }, - { "NiVisController", &construct }, + + // NiNode-like nodes, Bethesda + { "BSBlastNode", &construct }, + { "BSDamageStage", &construct }, + { "BSFadeNode", &construct }, + { "BSLeafAnimNode", &construct }, + { "BSMultiBoundNode", &construct }, + { "BSOrderedNode", &construct }, + { "BSRangeNode", &construct }, + { "BSTreeNode", &construct }, + { "BSValueNode", &construct }, + + // Switch nodes, 4.0.0.2 + { "NiSwitchNode", &construct }, + { "NiFltAnimationNode", &construct }, + { "NiLODNode", &construct }, + + // NiSequence nodes, 4.0.0.2 + { "NiSequenceStreamHelper", &construct }, + + // NiSequence nodes, Gamebryo + { "NiSequence", &construct }, + { "NiControllerSequence", &construct }, + + // Other nodes, 4.0.0.2 + { "NiCamera", &construct }, + + // ACCUMULATORS + + // 4.0.0.2 + { "NiAlphaAccumulator", &construct }, + { "NiClusterAccumulator", &construct }, + + // CONTROLLERS + + // 4.0.0.2 + { "NiAlphaController", &construct }, + { "NiBSPArrayController", &construct }, + { "NiFlipController", &construct }, { "NiGeomMorpherController", &construct }, { "NiKeyframeController", &construct }, - { "NiAlphaController", &construct }, - { "NiRollController", &construct }, - { "NiUVController", &construct }, - { "NiPathController", &construct }, + { "NiLookAtController", &construct }, { "NiMaterialColorController", &construct }, - { "NiBSPArrayController", &construct }, { "NiParticleSystemController", &construct }, - { "NiFlipController", &construct }, + { "NiPathController", &construct }, + { "NiRollController", &construct }, + { "NiUVController", &construct }, + { "NiVisController", &construct }, + + // Gamebryo + { "NiControllerManager", &construct }, + { "NiTransformController", &construct }, { "NiTextureTransformController", &construct }, + { "NiMultiTargetTransformController", + &construct }, + + // Bethesda + { "BSMaterialEmittanceMultController", + &construct }, + { "BSRefractionFirePeriodController", + &construct }, + { "BSRefractionStrengthController", + &construct }, + { "BSEffectShaderPropertyColorController", + &construct }, + { "BSEffectShaderPropertyFloatController", + &construct }, + { "BSLightingShaderPropertyColorController", + &construct }, + { "BSLightingShaderPropertyFloatController", + &construct }, + { "bhkBlendController", &construct }, + + // Interpolators, Gamebryo + { "NiBlendBoolInterpolator", &construct }, + { "NiBlendFloatInterpolator", &construct }, + { "NiBlendPoint3Interpolator", &construct }, + { "NiBlendTransformInterpolator", + &construct }, + { "NiBoolInterpolator", &construct }, + { "NiBoolTimelineInterpolator", &construct }, + { "NiColorInterpolator", &construct }, + { "NiFloatInterpolator", &construct }, + { "NiPoint3Interpolator", &construct }, + { "NiTransformInterpolator", &construct }, + + // DATA + + // 4.0.0.2 + { "NiColorData", &construct }, + { "NiFloatData", &construct }, + { "NiKeyframeData", &construct }, + { "NiMorphData", &construct }, + { "NiPalette", &construct }, + { "NiPixelData", &construct }, + { "NiPosData", &construct }, + { "NiSourceTexture", &construct }, + { "NiUVData", &construct }, + { "NiVisData", &construct }, + + // Gamebryo + { "NiBoolData", &construct }, + { "NiDefaultAVObjectPalette", &construct }, + { "NiTransformData", &construct }, + + // Bethesda + { "BSShaderTextureSet", &construct }, + + // DYNAMIC EFFECTS + + // 4.0.0.2 { "NiAmbientLight", &construct }, { "NiDirectionalLight", &construct }, { "NiPointLight", &construct }, { "NiSpotLight", &construct }, { "NiTextureEffect", &construct }, + + // EXTRA DATA + + // 4.0.0.2 { "NiExtraData", &construct }, - { "NiVertWeightsExtraData", &construct }, - { "NiTextKeyExtraData", &construct }, { "NiStringExtraData", &construct }, - { "NiGravity", &construct }, - { "NiPlanarCollider", &construct }, - { "NiSphericalCollider", &construct }, - { "NiParticleGrowFade", &construct }, - { "NiParticleColorModifier", &construct }, - { "NiParticleRotation", &construct }, - { "NiFloatData", &construct }, - { "NiTriShapeData", &construct }, - { "NiTriStripsData", &construct }, - { "NiLinesData", &construct }, - { "NiVisData", &construct }, - { "NiColorData", &construct }, - { "NiPixelData", &construct }, - { "NiMorphData", &construct }, - { "NiKeyframeData", &construct }, - { "NiSkinData", &construct }, - { "NiUVData", &construct }, - { "NiPosData", &construct }, - { "NiParticlesData", &construct }, - { "NiRotatingParticlesData", &construct }, - { "NiAutoNormalParticlesData", &construct }, - { "NiSequenceStreamHelper", &construct }, - { "NiSourceTexture", &construct }, - { "NiSkinInstance", &construct }, - { "NiLookAtController", &construct }, - { "NiPalette", &construct }, - { "NiIntegerExtraData", &construct }, - { "NiIntegersExtraData", &construct }, + { "NiTextKeyExtraData", &construct }, + { "NiVertWeightsExtraData", &construct }, + + // Gamebryo { "NiBinaryExtraData", &construct }, { "NiBooleanExtraData", &construct }, - { "NiVectorExtraData", &construct }, { "NiColorExtraData", &construct }, { "NiFloatExtraData", &construct }, { "NiFloatsExtraData", &construct }, + { "NiIntegerExtraData", &construct }, + { "NiIntegersExtraData", &construct }, + { "NiVectorExtraData", &construct }, { "NiStringPalette", &construct }, - { "NiBoolData", &construct }, - { "NiSkinPartition", &construct }, - { "BSXFlags", &construct }, + + // Bethesda bounds { "BSBound", &construct }, - { "NiTransformData", &construct }, - { "BSFadeNode", &construct }, - { "BSLeafAnimNode", &construct }, - { "BSTreeNode", &construct }, - { "BSValueNode", &construct }, - { "BSOrderedNode", &construct }, - { "BSMultiBoundNode", &construct }, - { "BSRangeNode", &construct }, - { "BSBlastNode", &construct }, - { "BSDamageStage", &construct }, - { "bhkBlendController", &construct }, - { "BSMaterialEmittanceMultController", - &construct }, - { "BSRefractionFirePeriodController", - &construct }, - { "BSRefractionStrengthController", - &construct }, - { "NiFloatInterpolator", &construct }, - { "NiBoolInterpolator", &construct }, - { "NiBoolTimelineInterpolator", &construct }, - { "NiPoint3Interpolator", &construct }, - { "NiTransformController", &construct }, - { "NiMultiTargetTransformController", - &construct }, - { "NiTransformInterpolator", &construct }, - { "NiColorInterpolator", &construct }, - { "BSShaderTextureSet", &construct }, - { "BSLODTriShape", &construct }, - { "BSShaderProperty", &construct }, - { "BSShaderPPLightingProperty", &construct }, - { "BSShaderNoLightingProperty", &construct }, + { "BSMultiBound", &construct }, + { "BSMultiBoundOBB", &construct }, + { "BSMultiBoundSphere", &construct }, + + // Bethesda markers { "BSFurnitureMarker", &construct }, { "BSFurnitureMarkerNode", &construct }, + { "BSInvMarker", &construct }, + + // Other Bethesda records + { "BSBehaviorGraphExtraData", &construct }, + { "BSXFlags", &construct }, + + // GEOMETRY + + // 4.0.0.2 + { "NiAutoNormalParticles", &construct }, + { "NiAutoNormalParticlesData", &construct }, + { "NiLines", &construct }, + { "NiLinesData", &construct }, + { "NiParticles", &construct }, + { "NiParticlesData", &construct }, + { "NiRotatingParticles", &construct }, + { "NiRotatingParticlesData", &construct }, + { "NiSkinData", &construct }, + { "NiSkinInstance", &construct }, + { "NiSkinPartition", &construct }, + { "NiTriShape", &construct }, + { "NiTriShapeData", &construct }, + { "NiTriStrips", &construct }, + { "NiTriStripsData", &construct }, + + // Bethesda + { "BSDismemberSkinInstance", &construct }, + { "BSTriShape", &construct }, + { "BSLODTriShape", &construct }, + + // PARTICLES + + // Modifiers, 4.0.0.2 + { "NiGravity", &construct }, + { "NiParticleColorModifier", &construct }, + { "NiParticleGrowFade", &construct }, + { "NiParticleRotation", &construct }, + + // Colliders, 4.0.0.2 + { "NiPlanarCollider", &construct }, + { "NiSphericalCollider", &construct }, + + // PHYSICS + + // Collision objects, Gamebryo { "NiCollisionObject", &construct }, + + // Collision objects, Bethesda { "bhkCollisionObject", &construct }, - { "bhkSPCollisionObject", &construct }, { "bhkPCollisionObject", &construct }, - { "BSDismemberSkinInstance", &construct }, - { "NiControllerManager", &construct }, + { "bhkSPCollisionObject", &construct }, + + // Constraint records, Bethesda + { "bhkHingeConstraint", &construct }, + { "bhkLimitedHingeConstraint", &construct }, + { "bhkRagdollConstraint", &construct }, + + // Physics body records, Bethesda + { "bhkRigidBody", &construct }, + { "bhkRigidBodyT", &construct }, + + // Physics geometry records, Bethesda + { "bhkBoxShape", &construct }, + { "bhkCapsuleShape", &construct }, + { "bhkCompressedMeshShape", &construct }, + { "bhkCompressedMeshShapeData", &construct }, + { "bhkConvexTransformShape", &construct }, + { "bhkConvexVerticesShape", &construct }, + { "bhkListShape", &construct }, { "bhkMoppBvTreeShape", &construct }, { "bhkNiTriStripsShape", &construct }, { "bhkPackedNiTriStripsShape", &construct }, { "hkPackedNiTriStripsData", &construct }, - { "bhkConvexVerticesShape", &construct }, - { "bhkConvexTransformShape", &construct }, - { "bhkTransformShape", &construct }, { "bhkSimpleShapePhantom", &construct }, - { "bhkBoxShape", &construct }, - { "bhkCapsuleShape", &construct }, { "bhkSphereShape", &construct }, - { "bhkListShape", &construct }, - { "bhkRigidBody", &construct }, - { "bhkRigidBodyT", &construct }, - { "bhkRagdollConstraint", &construct }, - { "bhkHingeConstraint", &construct }, - { "bhkLimitedHingeConstraint", &construct }, + { "bhkTransformShape", &construct }, + + // PROPERTIES + + // 4.0.0.2 + { "NiAlphaProperty", &construct }, + { "NiDitherProperty", &construct }, + { "NiFogProperty", &construct }, + { "NiMaterialProperty", &construct }, + { "NiShadeProperty", &construct }, + { "NiSpecularProperty", &construct }, + { "NiStencilProperty", &construct }, + { "NiTexturingProperty", &construct }, + { "NiVertexColorProperty", &construct }, + { "NiWireframeProperty", &construct }, + { "NiZBufferProperty", &construct }, + + // Shader properties, Bethesda + { "BSShaderProperty", &construct }, + { "BSShaderPPLightingProperty", &construct }, + { "BSShaderNoLightingProperty", &construct }, { "BSLightingShaderProperty", &construct }, { "BSEffectShaderProperty", &construct }, - { "NiSortAdjustNode", &construct }, - { "NiClusterAccumulator", &construct }, - { "NiAlphaAccumulator", &construct }, - { "NiSequence", &construct }, - { "NiControllerSequence", &construct }, - { "NiDefaultAVObjectPalette", &construct }, - { "NiBlendBoolInterpolator", &construct }, - { "NiBlendFloatInterpolator", &construct }, - { "NiBlendPoint3Interpolator", &construct }, - { "NiBlendTransformInterpolator", - &construct }, - { "bhkCompressedMeshShape", &construct }, - { "bhkCompressedMeshShapeData", &construct }, - { "BSMultiBound", &construct }, - { "BSMultiBoundOBB", &construct }, - { "BSMultiBoundSphere", &construct }, - { "BSInvMarker", &construct }, - { "BSTriShape", &construct }, - { "BSEffectShaderPropertyFloatController", - &construct }, - { "BSLightingShaderPropertyFloatController", - &construct }, - { "BSEffectShaderPropertyColorController", - &construct }, - { "BSLightingShaderPropertyColorController", - &construct }, - { "BSBehaviorGraphExtraData", &construct }, }; }