ok what i normally do is a quick and nasty weighting just so i can check things out in udk, in this case take your time since in most parts are sub-object it should be ok, don't waste to much time with the springs just in case it doesn't work
Announcement
Collapse
No announcement yet.
[WALK-THROUGH] Fully Functional Vehicle (my first car).
Collapse
X
-
ok, so i just finshed assigning all the verticies to there propper groups and thought i would give it a test import. i tried "file>export>.psk" and it made blender crash, then i tried to export using the"export to unreal" button on the side toolbar and that failed aswell, i then tried the .fbx exporter, it exported successfully, i converted it to the correct .fbx version, and then imported to UDK. now it imported just fine (so no warnings or anything), but because my export script is standard and not modified it added an extra armature (i also did nothing to the export settings), the car and skeleton were on there side. i tried moving a couple of the bones in the skeletal mesh viewer and they moved the corresponding part of of the car witch means the way i added the wieghts must have worked in some way, i also grabbed one of the spring bones, moved it and the spring streched as i expected but the top of the spring slowly moved away from the top suspension bone that its also attached to so i think the springs might need 2 bones each instead of one. i have no idea why the .psk exporter did'nt work or why the .fbx does.
i have tried to work out what the problem is by comparing the stuff in the top right corner of my screen with the top right corner of your screen in your tutorial but it looks the same.
i cant work out what the problem/s could be.
so close but not quite
Comment
-
ok i'll do a video for the fbx fix today, never seen that error but i'll guess that some vertex has more than 2 bone weights but then its a guess only
ok this is doing my nut in, when ever i export a skel mesh from blender 2.65 using the fbx exporter the bones get rotated.
sorry at this moment in time i"ve no idea on how to get it to work using fbx
we'll have to find the problem with the psk export
Comment
-
well all verticies except the springs verticies have a wieght of 1 and are assigned to only one vertex group. every vert of the springs has two wieghts and are assigned to two vertex groups.
also i have been testing the fbx eporter. yesterday i just exported using the default settings and when i imported the car and skeleton were both on there sides but still in the correct positions in relation to each other. today i tried to set the "up and forward" in the export options but it imported really wierd, the car was still on its side but the skeleton was pointing up (so the bones for the front of the car were pointing up and the rear bones were pointing down).
this is getting very odd
Comment
-
I think you either have loose vertices and edges, or a degenerate polygon. In mesh edit try Select->Loose verts/edges for the former. For the latter you can try W->Remove doubles, but beware that may weld some stuff you don't want welded.
If that fails, create a temp copy of the file to work on (so you don't accidentally save over your work!) and try breaking down the model and exporting specific parts in isolation until you find the area that's causing the issue.
I'm still on 2.63 at the moment, but I'll have a look at the fbx export tonight. It's been awhile since I last did this... I assume you've read the relevant link in my sig?
Comment
-
Ok, for 2.65a FBX:
You can find the python script in *blender*\2.65\scripts\addons\io_scene_fbx\export_ fbx.py
If this is in the progam files directory or similar then Window's UAC may complain if you try to edit it directly. So copy the file to the desktop (create a second backup of the original just in case) and open it with notepad or something better, but not a word processor. Any scripting IDE like Notepad++ or even Blender itself will do.
Lines 2549 to 2556 look like this:
Code:#for bonename, bone, obname, me, armob in ob_bones: for my_bone in ob_bones: # Always parent to armature now if my_bone.parent: fw('\n\tConnect: "OO", "Model::%s", "Model::%s"' % (my_bone.fbxName, my_bone.parent.fbxName)) else: # the armature object is written as an empty and all root level bones connect to it fw('\n\tConnect: "OO", "Model::%s", "Model::%s"' % (my_bone.fbxName, my_bone.fbxArm.fbxName))
Code:#for bonename, bone, obname, me, armob in ob_bones: for my_bone in ob_bones: # Always parent to armature now if my_bone.parent: fw('\n\tConnect: "OO", "Model::%s", "Model::%s"' % (my_bone.fbxName, my_bone.parent.fbxName)) #else: # # the armature object is written as an empty and all root level bones connect to it # fw('\n\tConnect: "OO", "Model::%s", "Model::%s"' % (my_bone.fbxName, my_bone.fbxArm.fbxName))
This will prevent the script from adding a default root bone at the top of the rig hierarchy. Save the file then copy it back into the original folder, overwriting the original.
Open Blender and load your file.
Choose Export->FBX export. The default export settings should be fine, don't worry about the orientation settings as they're pretty much ignored for skeletal rigs and only of use to static meshes. Since this isn't an animation rig you can ignore Only Deform Bones (rigs built for animation often contain control bones not intended for UDK, and this will filter out any bone not enabled as a vertex deformer).
In UDK, select import and locate the fbx file. An options screen will popup. Locate the SkeletalMesh->Advanced panel and tick "Use T0As Ref Pose". This will use the first frame of Blender's main timeline as the reference pose for the rig and sets up its orientation.
Ignore the warning about out of date fbx format. When the mesh is imported it should automatically be rotated to face down the X axis (Rot Origin yaw will be -90).
Comment
-
Originally posted by Spoof View PostI think you either have loose vertices and edges, or a degenerate polygon. In mesh edit try Select->Loose verts/edges for the former. For the latter you can try W->Remove doubles, but beware that may weld some stuff you don't want welded.
because i have had to rebuild my car so many times the last time i did it i triple checked to see if there were any doubles/loose verts/edges, after that i manualy corrected every individual tri so im pretty confident there arent any.
If that fails, create a temp copy of the file to work on (so you don't accidentally save over your work!) and try breaking down the model and exporting specific parts in isolation until you find the area that's causing the issue.
when i tried to parent the mesh and bones i pressed the "with automatic weights" like in geodav's tutorial and had a weird warrning (again screenshot a page or two back), turns out it had created the vertex groups but didnt assign any verticies to them, so i went through every vertex group and unassigned all verticies just to make sure, then assigned all the vertices to the correct groups witch seemed to work fine. (not sure if that warning had anything to do with it)
I'm still on 2.63 at the moment, but I'll have a look at the fbx export tonight. It's been awhile since I last did this... I assume you've read the relevant link in my sig?
i took a look but im no scripter unfortunatelycould'nt make heads or tails of it.
i did think that the psk export failed because of the way i weighted the springs, so i unassigned those verticies and tried exporting again witch resulted in the same failure warnig.
i did notice this after the export to psk failed
before i tried to export there was only one mesh (buggy), it would appear that the psk exporter duplicated the mesh twice. in blenders console window when i try to export it says "copy and convert anyway..." just above where it says "mesh selected 1" or whatever (cant remember the exact phrase). dontknow it that means anything or not.
to be honest it boggles the mind
--EDIT--
ha, you posted while i was typing
anyway i only have notepad, i do have visual studio 2010 and 2012, unreal x editor, and context/uncodeX, will one of them work?
also will that fix the rotating skeleton problem GEODAV said about?
Comment
-
The extra mesh is a result of the PSK exporter crashing. It generates a duplicate mesh to triangulate it, and destroys that extra mesh at the end... unless it crashes
One thing I would advise - and you may kick yourself for doing it - don't triangulate your mesh until the very, very end. Both PSK and FBX will happily export quads, and a quad topology is far easier to work with when editing. There are options to convert back to quads, but you may need to tinker with some parts to get them right - it's up to you.
I don't think automatic weight generation is a good idea for a hard-surface model like a car as it'll create blended weights between bones at the joints, so the mesh will bend and stretch organically. It's mainly for characters... and springsAssigning the groups directly to each bone should give them a 1:1 relationship. You can always add a little stretching in weight-paint mode, so e.g. the steering rack bends a little when you put some serious stress on it hehe.
Also, if you haven't noticed already, read up. I posted again while you were posting.
Edit: also the PSK crash log is nothing to do with bones or weighting. It's found a face (triangle) who's normal is coplanar - meaning it's not pointing out from the face, implying that the triangle is degenerate: two or more of the vertices have the exact same coordinates, which prevents the math from calculating a plane for the surface normal.
Comment
Comment