Blender: Error importing/exporting Civ5 CN6 files to Civ6 modding

Done. What's next, how to install the 1.51 script? Do I have to delete the previous versions first?

No just re-add the Add On like you did the first time and it should replace it. You should probably uncheck/recheck the checkbox next to the Add On to make sure it is reloaded.
 
Success! (i've just found out i've forgot to delete a box generated when running Blender program for the first time :p )

Here a new project. I'm return working on Siege Cannon project, i've removed crews and associating animation paths. Now how can I add Field Cannon (as vehicle, not crew) animations to it?
Do it in blender, civnexus or asset editor? and do I have to rotate the whole piece to point in front first?
Working with Blender4.jpg

The geometric files contained in this zip are what i'm quite sure usable.
 

Attachments

Success! (i've just found out i've forgot to delete a box generated when running Blender program for the first time :p )

I did wonder if you'd removed the default Cube. You can re-save an empty start up file by using CTRL-U to save your current state as the default document.

Here a new project. I'm return working on Siege Cannon project, i've removed crews and associating animation paths. Now how can I add Field Cannon (as vehicle, not crew) animations to it?
Do it in blender, civnexus or asset editor? and do I have to rotate the whole piece to point in front first?
The geometric files contained in this zip are what i'm quite sure usable.

I'd suggest the best way will be to rig this Civ V Cannon to the Civ VI Field Cannon skeleton and animations. This can only be done in Blender.

The steps will be:
1) Export the Field Cannon .fgx file to .cn6.
2) Load into Blender.
3) Load Civ V Cannon into Blender or Append it from a saved .blend file alternatively.
4) Use Ctrl-P to parent the Civ V Cannon mesh to the Civ VI Field Cannon Armature object.
5) Then you'll need to do the actual rigging. This consists of assigning the various parts of the Civ V Cannon mesh to Vertex Groups which correspond to the different bones in the Civ VI Field Cannon Armature. You can potential do this in a rough way by lining up the two Cannon meshes and then using Transfer Weights as described in Step 5 here. Alternatively you can just inspect the Vertex Groups in the Civ VI Field Cannon mesh and the assign the parts of the Civ V Cannon mesh in a similar way.
6) Once you have all the Vertex groups assigned you can remove the Civ VI Field Cannon mesh and the original Civ V Armature object then export to .cn6. You can test that the rigging is successful in FGX Viewer by opening your model .fgx and dragging and dropping in the relevant Field Cannon animations to see if you model animates correctly.
7) You can then use the .ast Asset file of the Field Cannon as your base and just replace the Geometry Set section with the data for your new model created via CivNexus6 using the "Create GeometrySet xml for .ast file".

That's the high level process - it's not the easiest Blender task but it is possible.
 
Here. I've aligned two cannons into the same zero origin point. and set parents as you said. what now? how can I transfer weights to bring animations from Civ6 Field cannon to Civ5 cannon? the manual link you cited is for 2.49 and not 2.79. is there an execute button in tools>transfer tab?
Working with Blender4 (two cannons aligned in zero points, what next).jpg
 
Here. I've aligned two cannons into the same zero origin point. and set parents as you said. what now? how can I transfer weights to bring animations from Civ6 Field cannon to Civ5 cannon? the manual link you cited is for 2.49 and not 2.79. is there an execute button in tools>transfer tab?

The manual I linked is for 2.7. Not sure how you concluded it was 2.49? Anyway I'll copy paste the relevant section here:
In Object mode in 3D view select the template object and new object with shift RIGHT CLICK. OLD rigged mesh first then the new one second. YOUR NEW MESH MUST HAVE NO VERTEX GROUPS FOR THIS TO WORK. Select Weight Paint mode in the 3D View then press Transfer Weights in he Tools side bar.

Just warning you that this process works reasonably well when meshes are human or perfectly aligned - in a situation like this with a mechanical model you might be better just setting the Vertex Groups manually.
 
Just warning you that this process works reasonably well when meshes are human or perfectly aligned - in a situation like this with a mechanical model you might be better just setting the Vertex Groups manually.
Manual vortex group setting? how, Civ5 cannons has more vertex groups, (the 'neccessary' group. not 'ancillary' like sponge which is latched in the gun carriage and trail box)
Working with Blender4 (Vertex groups).jpg


Also did I set parents correctly?
 
Manual vortex group setting? how, Civ5 cannons has more vertex groups, (the 'neccessary' group. not 'ancillary' like sponge which is latched in the gun carriage and trail box)

Also did I set parents correctly?

They have different number of vertex groups because they have different Armatures (Skeletons) and animations. You just have to use some common sense like assign everything that was assigned to right wheel on the old armature to right wheel vertex group of the new armature. I can't really tell if you have parented the mesh to the Civ 6 armature correctly. When you do it you should use Ctrl-P and select Create Empty Groups - this will add the vertex groups for the new armature's bones to your Civ 5 mesh.
 
Also that 'armature object' in question is in 'root' directory and not Field Cannon

4) Use Ctrl-P to parent the Civ V Cannon mesh to the Civ VI Field Cannon Armature object.
5) Then you'll need to do the actual rigging. This consists of assigning the various parts of the Civ V Cannon mesh to Vertex Groups which correspond to the different bones in the Civ VI Field Cannon Armature. You can potential do this in a rough way by lining up the two Cannon meshes and then using Transfer Weights as described in Step 5 here. Alternatively you can just inspect the Vertex Groups in the Civ VI Field Cannon mesh and the assign the parts of the Civ V Cannon mesh in a similar way.

Also assigning vertexes requires renaming and the use of 'transfer command' too? It means adding 'dummy' vertex group in Civ6 Field Cannon to match extra bones of Civ5 Cannon? (which the 'main' unit of the FC = 'Left Cart, Right Cart, (I don't understand why the civ5 cannon uses two sets of gun carriage axles? theoretically the civ6 one is simplified piece). Or combining the civ5 cannon highlighted vertexes into one 'main' so it will be easily assigned. (personally I don't see any reasons for Firaxis 3d team to give FOUR separate bones for a carriage 'main' vertex' ) if combination is to be done first. how?
Working with Blender4 (Vertex groups 2).jpg

And there's heirachy tree as well in the same image posted here. (I think this checked whether mesh parenting is correct or not) Is this relation tree shown in the righthand a correct one? I've tried transferring with 'vertex group options' to a perfect match, delete civ 6 field cannon and move the civ 5 ones and export. What happened is that Civ5 cannon mesh is 'lost'! (i.e. the mesh did not shown in the list if the exported file is browsed with civnexus, also making a new file and import the previous work also checked wether did the intended mesh to use is still there or 'lost')
 
Last edited:
And the red 'modifier' thing shown in the mesh of Civ5Cannon entry. what should I do with it? duplicate civ6 field cannon armature and align the duplicate armature with the civ 5 cannon and set modifier?
Working with Blender4 (Missing Modifier).jpg


And the bone symbols shown in the upper left box (one with heirachy tree) should also be set to civ5 vertex groups too?
 
Last edited:
If you select Mesh under Properties you can Select the parts of the Mesh which are assigned to each Vertex Groups. I recommend you do this as you'll then have a better idea how Vertex Groups bone mapping (what people call "rigging") works.

It means adding 'dummy' vertex group in Civ6 Field Cannon to match extra bones of Civ5 Cannon?

The other way around really you are assigned new Vertex Groups corresponding to the Civ 6 Field Cannon's bone names to the Civ 5 Cannon's mesh.

Also that 'armature object' in question is in 'root' directory and not Field Cannon

It's not a directory it is the parent object for the Armature with the name Root.

After you parent the Civ 5 Cannon mesh to the Civ 6 Armature (Root) then you should end up with two modifiers - one for the old Armature which has the red highlighting and is no longer needed and one for the new one which is needed. You can delete the old redundant red one.
 
A step by step. Now i've created an empty new vertex on Civ5 Cannon (is it case sensitive?). What now, Which tools (and viewing mode) will be used to define where in that cannon mesh (Should be axles and trails, also including accessories) is called 'Main' Vertex? Vertex Paint or Weight Paint? (and paint smearing tips so the vertex extent will only applied to desired sections)... Also, i've forgot one basic controls... Rotation, how to rotate the 3d workspace so to see the other side of the same piece? which keyboard buttons and mouseclick should I do? since the Alt+mousedrag (as in Asset Editor) does nothing :P)
The rest of civ5 Cannon vertex groups (Leftwheel Rightweel and Cannon) can be renamed to match each other.
Working with Blender4 (Vertex groups 3).jpg
 
In Blender I generally use Middle Mouse Button drag to rotate the camera. You can use Numpad 1 or 3 or 7 to view the model from along the different axes.
 
What I would do is use Edit Mode rather than Weight Paint. In the Mesh tab first Select the old civ 5 left wheel Vertex Group and then Assign those Vertexes (Vertices) to the new Civ 6 left wheel Vertex Group. This is a bit easier than using Weight Paint to paint by hand.
 
But the 'Main' tab wasn't bound to the any parts in the Civ5 cannon mesh yet. (look at the vertex 'main' is highlighted blue (selected) Do i have to define the 'main' vertex first? I feel like it has to be transferred. My understanding is that 'Main' vertex in Civ6 Field Cannon is the carriage trail and axle.
If not paint the axle and trail manually, how can I define that 'main' vertex group is carriage trail, axle, trail box and two rods?

Working with Blender4 (Vertex groups 5).jpg


OK This is edit mode. What i see is the Civ5 cannon mesh shown its wireframe. I've clicked at Cannon, wheels on vertex properties but no highlighting colours appear but the red highlight did shown up in weight mode. What now
 
But the 'Main' tab wasn't bound to the any parts in the Civ5 cannon mesh yet. (look at the vertex 'main' is highlighted blue (selected) Do i have to define the 'main' vertex first? I feel like it has to be transferred. My understanding is that 'Main' vertex in Civ6 Field Cannon is the carriage trail and axle.
If not paint the axle and trail manually, how can I define that 'main' vertex group is carriage trail, axle, trail box and two rods?

OK This is edit mode. What i see is the Civ5 cannon mesh shown its wireframe. I've clicked at Cannon, wheels on vertex properties but no highlighting colours appear but the red highlight did shown up in weight mode. What now

The A key will select/deselect all in Edit Mode. You want to deselect everything. Then when you select each Vertex Group you can use Select to see which vertices are part of that Vertex Group.

When you parent the old Civ 5 mesh to the Civ 6 Armature using Ctrl-P you should pick "Create Empty Groups". Then you'll have the old Vertex Groups and the new ones all available to the mesh. You can then select each Vertex Group of the old mesh and assign it to the corresponding Vertex Group on the new mesh.
 
This is the hierachy tree of Civ6 Field Cannon armature. It belongs to 'root' and not 'field cannon'
Working with Blender4 (Armature and root).jpg

And when I try to set parenting anew. (I think I did wrong). this screen showns up
Working with Blender4 (Armature and root).jpg

Where's 'Create Empty Group'? to pick sir?
 

Attachments

  • Working with Blender4 (Set parent).jpg
    Working with Blender4 (Set parent).jpg
    321.3 KB · Views: 141
Where's 'Create Empty Group'? to pick sir?

When you use Ctrl-P to Set Parent To the Root Armature Object for the old mesh you'll get a menu like this:
sr-3dvieweditorheader-objectmenu-parent-armature_deform.jpg


You should pick the "With Empty Groups" option then you'll have both old Vertex Groups (for the old Civ 5 bones) and new empty Vertex Groups (for the new Civ 6 bones) on your mesh.
 
Is this the correct results of Ctrl+P 'make parent' command?

The type 'With empty groups' must shown up in a box (highlighted red) to the left, and Parent box to the right is now empty. Is this a correct result? and what's next?

Check the Vertex Groups for the old mesh and you should have both sets of bone named Vertex Groups in it.
 
Back
Top Bottom