Hey all. I recently modeled and rigged a simple gift box for use in my game. Here is a picture of the setup in Cinema 4D:
When I import this into Unreal, the main part of the box is not imported and only the two flaps are - but they’re both imported as separate meshes. I found that adding a bone to the main part of the box allows that to import as well, but it still all imports separately. When I open the .fbx file in any other program, such as Cinema 4D or Blender, it all imports fine… Any idea why?
Something is wrong with your attachment. I only get a message about an invalid link.
Are you planning to animate the box? If not you shouldn’t need a bone at all.
You might want to combine your meshes into a single Object (in C4D) and use polygon selections for different materials instead.
Or you can try “combine meshes” in the UE4 import settings.
If you show me your setup especially the object hierarchy, i’m sure i can help you.
You also should read up some of the threads allready made about cinema 4d export to UE4.
Just use the forum search and enter cinema 4d, this is how i find all these threads.
e.g. you can find out there, that in the latest cinema versions fbx 6.1 2010 works nearly perfect even for meshes with multiple materials, a second UV channel etc.
It even imports some Material-attributes and textures into UE4.
My apologies! I thought I fixed that.
That one should work. Also, yes, I do plan on animating it.
Ok, here’s an example including .c4d, .fbx and .uasset:
http://www.mediafire.com/download/xkqq69losu4yepq/Box_test.zip
Your issues are caused by a wrong hierarchy setup.
FBX should be set up with a Nullobject as root.
Notice that i rotated this root -90° pitch, otherwise the object will rotate +90° Pitch as soon as animations are applied in UE4.
This is related to issues with axis converting between lefthanded and righthanded coordinate system.
The whole joint hierarchy schould be placed inside this null, in this case starting with a basebone the main body of the box will be rigged to.
Then create a bone for left and right flap and place it right at the point where the flaps are tied to the box.
You can make them childs of the basebone like in my example or just place them next to it, both will work.
No need for more joints since you only need to animate the rotation of these two joints and have one joint you can rig the rest of the box to.
Unweighted meshes won’t import in a skeletal mesh, for obviouse reasons. (just in case you still wonder why the box vanished on import in UE4)
Now rig the mesh to the joints.
Doesn’t really matter if you keep it as a single mesh like in my example, or if you rig several objects.
As long as you keep the meshes a child of the root null and each of them is rigged to a joint with weight tag and skin object, you should be fine.
I’ve exported all animations in a single file and used the UE4 animation editor to copy the initial animation and cut out the pieces i wanted to be their own animations.
There certainly are other ways too, but this is stuff for another lesson.
(also i used a double sided material for the mesh, since i did only a quick mesh with no inside)
C4D R17.048 with fbx v6.1 2010 was used for export, because recently it was discovered to be the most compatible way of getting your stuff into UE4.
You can try other versions, but i do not guarantee the same result.
Add the .uasset files to the content folder of your unreal project to preview the mesh and animation.
If you cannot load the .c4d file because you use an older program version then R17, import the .fbx to C4D to see the setup.
Enough input for today. If you have issues or questions, post them and we will sort them out.