Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / blender models with animation

Author
Message
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 24th Jan 2009 23:36
Hi,I have made some game models in blender 3d with animation,
here is my code:
rem sync on : sync rate 0
load object "salute4.x",1
position object 1, 0, 0, 0
xrotate object 1,90

wait key
rem play object 1
set object speed 1,6000
play object 1
wait key

the model loads and appears on screen but i am expecting my model to salute when a key is pressed but nothing happens when a key is pressed the models remains still.When I exported my model in blender I selected export with animation button,didnt select the speed button and then exported selected.In x format.Can you tell me how to get my models animation running please.
Dabbler
17
Years of Service
User Offline
Joined: 3rd Mar 2007
Location: Minnesota
Posted: 25th Jan 2009 04:34
Try this:



You may also have to adjust your object speed. Let me know how it turns out.


Whatever...
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 25th Jan 2009 05:04
Thanks for the reply,I tried ur code but it did not do the trick so I am posting the x.file so you can try to animate it as I am unable.Then please show me how.

Attachments

Login to view attachments
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 25th Jan 2009 06:46
Thanks but the new code hasnt animated my model.Im not sure when exporting animations with blender if there are any key requirements before it will export.I will attatch the x.file so you can hopefully get it running.
Many thanks.

Attachments

Login to view attachments
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 25th Jan 2009 22:01
Still waiting guys.Can no-one get my model to animate???
HowDo
21
Years of Service
User Offline
Joined: 28th Nov 2002
Location: United Kingdom
Posted: 25th Jan 2009 22:09
have you tired use truespace as DBPro as been made to work with that package.

Dark Physics makes any hot drink go cold.
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 25th Jan 2009 22:35
Thanks for the reply,but its not the reply I was looking for as I have spent months getting my models ready with blender.Somebody must know if models made with blender can work in dbpro,and how...
if this is you please show me.
HowDo
21
Years of Service
User Offline
Joined: 28th Nov 2002
Location: United Kingdom
Posted: 25th Jan 2009 22:57
paulhenry , what I was trying to say, is see if your model from blender will load into truespace and check if the animations work in that package, if its does then export it out as an X, and see if DBPro will animate it.

But I leave it up to you what you do.

Dark Physics makes any hot drink go cold.
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 26th Jan 2009 00:15 Edited at: 26th Jan 2009 00:43
Thanks again,I have truespace installed now but I dont think I can import my blender projects,but I can import the x.projects.
pollywog
17
Years of Service
User Offline
Joined: 18th Jan 2007
Location:
Posted: 26th Jan 2009 12:06
might be a dumb question but don't you need a dds file along with your .x file? maybe you don't, I'm not sure and I don't now anything about blender except that I'm to stupid to use it.

anyway every .x model I see has a dds file with it.
Is there an option in the blender export or an external tool to make one?
I tried to load your file and got an object cant load error

Rem Project: animate
Rem Created: 1/26/2009 2:48:11 AM

Dabbler
17
Years of Service
User Offline
Joined: 3rd Mar 2007
Location: Minnesota
Posted: 27th Jan 2009 06:55
I have the same problem as pollywog, can't load object.

Have you searched for problems with Blender models in DBPro?

One thread I looked at suggested that useing more than one texture on one model may cause DBPro to crash.

I don't know (yet). I may have to learn how to use Blender.


Whatever...
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 27th Jan 2009 11:53
Thanks.Try this model,it loads ok and has animation but I still cant get it to run.Whenever I turn on the sync rate the program runs but with a black screen,so I cant tell if it is working or not.
Please help.

Attachments

Login to view attachments
pollywog
17
Years of Service
User Offline
Joined: 18th Jan 2007
Location:
Posted: 27th Jan 2009 13:36
I like your guy. Is he textured in blender and its just not coming over, or is he not textured yet. anyway it looks like dbpro isn't recognizing you have any animation frames (I guess you knew that) I printed to the screen the total number of frames and it comes back 0. maybe you can test with this move the camera using the arrow keys, rotate your guy with the l and r key.

this must be very frustrating all that work in blender and then not getting it to load correctly.
my thoughts are with you keep plugging away!

James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 27th Jan 2009 14:53
I`ve imported your model into truespace, blender and dbp - there is no animation present in the model. Are you selecting the export animation option when you export as a direct x file? Could you post your .blend project file? I`ll see if I can get it working.
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 28th Jan 2009 02:51
Thankyou very much guys for your input,here is the blend project,1 object,1,layer,1 simple animation.When exporting to x,I have checked the export with animation buttton but as you know there is no animation.I am very stuck with this,the models have taken many months so please help me to figure out why the animation wont export.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 28th Jan 2009 16:48 Edited at: 28th Jan 2009 16:48
Unfortunately I`ve never been able to get ik solvers working as it might not be supported by anything other than blender - your using ik restraint limits on the models legs. The bone heirarchy is messed up to, some that do have the right parent need to be flipped 180(such as the MASTER bone and the two connected ones), others use mirroring(hips) which usually screws up the export as the parenting here is wrong. In addition to this you use a few materials which is a no go for dbp afaik. There are a couple or more vertices making up the cap badge that aren`t painted at all, they will never move when the model is animated, hardly noticable as you have only animated the head to turn so far - it will look worse when you animated the upper body. In short, you will have to rig and weight paint the model again, then animate it. I`ve tried making corrections, but you seem to have alterd many other settings in blender that do things I don`t know of. Any models I have managed to animate and export succesfully in the past from blender I select the export all function as opposed to the export selected function. I do this with your project and blender reports errors relating to the scene and meshes. My advice at this stage would be to take a look at truespace - the mesh import for your model was succesfull, its likely to be better supported as its officially supported I THINK, make sure to update dbp though as the official support is in one of the latest updates. Look at it this way, trying to correct the mistakes/issues might well take longer than starting again(bar reworking the mesh), so learning an application everyone says works rather than relearning/working out what blenders and dbp`s compatability issues are, should be quicker and more beneficial for the future due to its support.
Sorry I couldn`t get it working for ya, I myself will be looking to use truespace in the future, it doesn`t just look better but appears more user friendly and less complexed.
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 29th Jan 2009 06:39 Edited at: 29th Jan 2009 07:16
Many thanks,so it is the armature,and export all.I deleted the armature and export all worked,but when I add a simple armature and select export all,python script error.
Heres my new file,could you tell me what is wrong that it wont export all when any armature is added.Hopefully I am mistaken and you can add armatures and export all but I cant seem to manage it.
I tested a cube with no armature,export all,worked,added a armature, export all,python script error.


I really appreciate your help.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 29th Jan 2009 14:17 Edited at: 2nd Feb 2009 17:58
Odd really, I have just quickly tried exporting the basic cube with an armature the way I remember that I normally do with the export all function and get the same error. Still it can be done, I`ve attached an old blend file of mine that works - when you export all with animation with this it should work with animation in dbp, test it just in case. In the mean time I`ll work out what it is I normally do that I don`t seem to be remembering to get the export all feature with animation to work in dbp(its been a while).

Edit:
Here is the .blend file of a cube animated that works with export all function(with anim) and shows correctly in dbp - I`ve just done this so it definatley works. Create the xfile from this and let us know how you get on. I`ve just edited this post with full instructions of what to do, but when I tried replacing the previous file I uploaded, I lost the edits to the post!!! I will rectify later today, I have things to do right now though, I shall return asap

Edit:
download removed
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 29th Jan 2009 17:50 Edited at: 2nd Feb 2009 17:58
Actually do the following to the file you just provided:

remove armature modifiers(see pic1 - click where red circles are)
deselect envelopes(see pic2 - click where red circles are)
deselect draw shapes(see pic2 - click where red circles are)
switch from pose to object mode
hit "a" twice to select NOTHING in the scene
click rmb on the mesh object, then holding shift, click rmb on the armature object - in this order
hold left "alt" and press p - choose clear parent
hold "ctrl" and press p - choose make armature parent - choose not to create any vertex groups
switch back to pose mode - export all with anim should now work, the model should load into dbp succesfully

this model will/does look odd in dbp, as a lot of verts aren`t painted so the polygons look inverted in dbp, so the animated head is inside the chest area! It works as it should though
attached is a rar file with dbp source, correctly exported model and blend file along with a comiled exe of the source

Edit:
download removed
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 30th Jan 2009 08:18
Many thanks,I modified the model by removing the armature and then the head returns in dbpro,then I added a armature to the right arm,animated it,removed the modifier and got it to run in(my first partial success) dbpro,but the model deforms.I tried completing the armature a few times now but when I run it in dbpro it runs but not properly,the screen just appears for a instant.Ive uploaded The blend file that runs in dbpro but the model deforms,if you want to take a look and guide me further I would appreciate it alot.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 30th Jan 2009 10:48
I don`t get any crashes, though the deform is normal. When a vertex is assigned a weight value that is less than 1.0 the vertex does not show as expected in dbp. Ensure ALL vertices are weight painted 100% to avoid this. Like wise if a vertex is assigned a weight value of 0.5 for one bone and 0.5 is assigned to the same vertex for another bone, then the position of the vertex is determined by the position and rotation of both bones. If the distortion you refer to still occurs then its likely the method you use to animate is messing things up. Personaly I use the NLA editor to copy keys and the timeline editor to insert keys. Essentially I goto the timeline editor in pose mode, set to frame 0 select all bones of the armature and hit "i". This inserts a key frame which is different to the other method I use with this which is to switch recordinging on, setting the pose, apply transform and rotation then move the timeline along to the next frame, re-pose/repeat until finished, switch recording off. When you press "i" your given a choice of how to apply the keyframe - choose LocRot - this will prevent scaling during animation which may be the deforming you see beyond non weight painted vertices looking inverted. When you choose LocRot it seems to have the same affect as applying transform and rotation in the other method which is very important. If you don`t do this after each change the object will not look as expected. Use both methods together to get best results.
If you still get crashes, then try downloading the model viewer written in dbp here http://forum.thegamecreators.com/?m=forum_view&t=124936&b=5 - I use this all the time to see if blender exports turn out ok, hasn`t failed me yet. Whatever works in this has always worked in dbp for me.
One last thing, to create bones I hit space, then use "e" to extrude a fresh bone rather than create a fresh armature - doing it this way means never having to set the parent/child especially when more than two bones connect at the same point. If you need free moving bones just clear the parent and when reassigning the parent, choose to keep the offset rather than keep connected. Also NEVER use armature modifiers, there is no need to and they just screw things up for dbp. Hope that helps
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 30th Jan 2009 12:41 Edited at: 30th Jan 2009 13:41
Many thanks again,I shall check the weight is 100,When I run the model viewer I get directx 9.0 installed,requires direct x 9.0c and it wont run.I checked my drivers software cd it says 9.0c.
Back after checking that I do have dierct x 9.0c installed.
The guy who made the model viewer is running vista home premium,which says it works perfect,I have a couple of questions,
if I upgrade my computer,(I have xp home with sp2,nvidia6100,160gig)to vista,will dbpro run better,will blender run better or is waiting for windows 7 the best option?
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 30th Jan 2009 13:52 Edited at: 30th Jan 2009 14:03
Vista and upgrades won`t make a difference in either case. You need the latest version of DX9.0c as there are a few. Its important you get the latest version of 9.0c. I have vista, vista comes with dx 9 and 10 but I still had to install 9.0c, the version of 9.0c I installed originally was an older version, then when I installed an upgrade to dark physics(has nothing to do with this - just another example of the need for the right version), I had to install a newer version for it to work. I think the latest version is november 08.
Btw I used the same methods when I had XP.
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 30th Jan 2009 16:28 Edited at: 30th Jan 2009 19:22
I got my directx upgraded to nov 08,viewer works now but I could use a bit more help.

Could you look this file over and adjust it so it does not deform and so I can add the rest of the armature to it please.
Im stil a little stuck,but getting there slowly.
Update.Is exporting to.x a lost cause, as soon as you parent the armature dbpro cant handle it and totally alters the mesh,is exporting to truespace in 3ds the best way,then building a new armature,animate, and then export to .x.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 31st Jan 2009 04:37
Honestly can`t spend much time on this now, will look again tomorrow if I can. You are creating things in blender different to me - the object isn`t centered at world 0,0,0 and the armature needs redoing as you have somehow managed to change the centre of each arm so they act differently in dbp to the way I do them - thats the main reason for the deformaty along with unpainted vertices. Your still using a double sided mesh - thats twice the polycount it needs to be.
You also seem to have options selected that aren`t needed in various windows. Stick control of the armature bones doesn`t give you full access to the bone control either, plus the octahedron view shows the direction of parent to child connections so you can see when a bone is the wrong way round. Truespace? Yes its an available option which will probably be an easier and quicker route/solution, haven`t used it myself properly yet but many have stated its not as complicated as other model editors plus there are tutorial vids somewhere, check out one of the more recent newsletters. Lots of people have stuff working in dbp from blender, its just a matter of wether your prepared to persevere. That said, I intend to use truespace myself in the future as its exports are supported in U7.1 specifically(might even be earlier than 7.1), plus I hate applying scale and rotation after every other edit. I think perhaps in future you should try the 3d chat board instead/aswell, people who are active with blender/truespace with tgc products probably go there, I dunno, just a thought. Got to go now though, need sleep.
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 31st Jan 2009 08:35
Alright,Im willing to persevere if others have managed to get their models running.You mention the object centres possibly being the reason for the deformation,might a more abled than myself modeller be able to test my model with these appended and let me know if they can get it to run smoothly,and or post the appended file which runs ok so that I can build the rest of the armature.I have not learned about about object centre worlds,but I am willing to learn if the time can be spared.
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 31st Jan 2009 16:28
I`ve tried everything I can think of to get the centres back but nothing seems to work so far. I pretty much followed this tutorial (attached) in the past, but ignore anything to do with ik contstraints/solvers, armature modifiers and when you need to xmirror, do it but remove from hierarchy afterwards and reparent them once the mirror parents are removed. You`ll notice that all bones are connected. Although the offset bones in your projects can be exported, they aren`t appearing at there offsets, so for now, don`t use offsets. If your going to just get arms working for now, try starting with a back bone and extrude all bones from that armature, this way you will only need to clear mirrored parents and reparent them.

Attachments

Login to view attachments
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 31st Jan 2009 16:58
Ok,what Im hoping to happen is for somebody who is confident they can get my uploaded file,which runs,just cant get past the armature deforming problem,to edit it and repost so I can build the rest of the armature.The model now just has a neck and head bone,like you said,which I can extrude from after it has been correctly edited for me to use please.
Surely it wouldnt take 5 minutes to adjust the armature to run properly then repost it,rather than picking at it and not explaining how to fix the problems.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 31st Jan 2009 18:01 Edited at: 2nd Feb 2009 18:00
Quote: "Surely it wouldnt take 5 minutes to adjust the armature to run properly then repost it,rather than picking at it and not explaining how to fix the problems."

Really? No ones picking. Your essentially saying your idea of perseverance is to accept a 5 minute solution. Not so - here is your blend file after spending 5 minutes on it. See still not 100% right in dbp, now you have to remove the animation keys and reanimate, but this time don`t apply scale to the animation - or if you haven`t then make sure to apply LocRot using "i" to create an animation frame. At the moment the head shrinks and expands slightly during animation in dbp. This never seems to show up in blender, its the reason why I`ll be looking at truespace in future, WYSIWYG is what I`m looking and hoping for. Still, its fixable and also switch to wireframe in the modelviewer and you can see some vertices attached to the neck that remain within body area, you need to assign them to the other bone(after unassigning from current bone) they are difficult to locate in blender. Can you see why a 5 min fix isn`t as helpfull as starting over and isolating problem areas?
Before you go animating this again, take a look at that tutorial, skip down past halfway to the rigging section where octahedrons are used and note how the flow of bones doesn`t extrude from the base of a bone but the tip. The tip and base are a bit like ball and socket joints - they can only be connected in this way for dbp, extruding from the neck base will work in blender, but not for dbp - even if it loads you may have difficulties with centres again.

Edit:
download removed
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 1st Feb 2009 08:09
Ok,many thanks,I tested your model but couldnt get it to run in the model viewer.So where you start and end the armature makes a difference and how you build it,the tutorial that you posted is the one ive been following for months,it is very good but ends in running the completed animation in aviraw,which i av many.Obviously exporting in direct x is a different tutorial completely and there are none.So I have come to a solution that benefits us both.I have posted my model with no armature at all,now the model has more than 1 texture,uv mapped,and runs in the model viewer and dbpro with NO deformations,as far as I know you can have lots of textures to a model,which seem to run ok so far,but if I am wrong please correct me.Back to the solution,if you have time would you add a armature to the model posted that does not deform in dbpro.Once I get the model back and test it that it runs animations in dbpro with No deformations,place the instructions on how you made the armature from start to finish,like the previous instructions which are easily understood on ebay,then just give me the item number and i will buy them from you and you can download them to me.My intentions then to apply your armature making style to my other models if you can get it to work.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 2nd Feb 2009 00:25 Edited at: 3rd Feb 2009 15:55
Attached is another .rar file that contains an image and two blender files aswell as another DBP project showing the models exported, texture and animated. The image helps see things better in dbp though it should show up in blender too.
I`ve altered your file to include a basic armature and animation. Unfortunatly the mesh really needs more polygons around the joints so extra bones can be added for better animation, but for simplicity I just animated it anyway with 4 basic bones - not ideal and neither is the position I`ve placed them, oh well nvm, I`m sure you can do a better job with some time. You will notice that it still looks a little like its been scale animated, but I assure you its not - those arms are wide and flat and with so few vertices to paint around the elbow, wrist and shoulder the deformity looks almost as odd in blender. DBP renders things better at runtime than blender so things always look slightly different, animated or not. Anyway I`ve included a second blender file which I`ve imported a free model and rigged the torso with 3 bones this time just to keep it simple. The model has more polygons, and this time its painted so that some vertices are affected by more than 1 bone helping smooth the animation of the mesh. Be CAREFULL not to attempt to sell the model even after alteration, the modeler has included this restriction, but allows the use of it in your own exes. Licenese included in rar for your viewing. If you don`t intend selling the models, you might consider using this. Check out the readme and license.
Here is what I do from scratch, in order.

Import the mesh into a clean scene, switching off double sided option
Smooth the normals - change the smooth value to max and click set smooth button - this step not absolutly neccesary
Make sure the mesh objects data is recentered and position at 0,0,0
Apply scale and rotation. Scale here has nothing to do with animation. Doing this after every major edit seems to force blender to recalculate things correctly when scene parts are parented after edits are made
Create a fresh armature, select the tip and position favourably(you can use "x","y" or "z" to limit movement to that direction using the mouse). Repeat the process two more times so the torso bones reach from waist to neck. Reposition the bones to sit inside the torso from every angle - roughly align the flow of bones to the be as paralell as possible to the general shape of the area of the torso you intend to animate
Switch to object mode and parent the mesh to the armature(ie armature is the parent) - useing shift to select the two you must always select the one you intend to be the parent last. Choose not to create vertex groups.

***Something I`ve noticed with your projects is that you create vertex groups. I`m not saying thats wrong, but the way I do it forces you to make sure every vertex is accounted for/assigned a bone. Basically there is, or at least seems to be a hard and fast rule - that every bone must be assigned at least one vertex, every vertex must have a minimum weight of 0.001. Anything outside these parameters exports ok but fails in dbp. The way you seem to do it seems to allow empty weights which suggests that blender treats all vertices as having weights of 0.001 when using vertex groups, but as they haven`t been assigned a bone they remain in there original position/fixed during animation both in dbp and blender, however dbp shows them as inverted.

***You can assign the same vertex to more than one bone by decreasing the weight. The position of the vertex is determined by the positions/rotations of the shared bones according to the portion of weight assign to either bone. The maximum weight is 1.0, so if the weight for one bone is 0.6 and the other bone is 0.4, the vertex final position will be affected more by the bone weighted with a value of 0.6 than the bone with a value of 0.4, like wise if the values were 0.7 and 0.3, then the vertex position would be affected that little bit more by the bone weighted with a value of 0.7 than its previous weight of 0.6...

...when I painted the weights of the torso I first made all vertices a value of 1.0 for there assigned bones, then for each bone I repainted the existing values nearest the edge(where vertices are assigned to another bone) with a value of 0.5, then painted some more verts that where outside this edge with the same value, thus sharing vertices movement with neighbouring bones.

When animating(use timeline panel), select all the bones then press "i", select LocRot, this inserts the key at current frame, move the bar along a few frames, alter the pose of the torso, select all bones again and insert another key using "i", repeat for as many times as you like. To get it to animate back to the original frame 0 positions/rotations, switch to the NLA editor, select the first white diamond with rmb(it should turn yellow), hold shift and press "d" - this duplicates the key, use the mouse to move the key along to the last frame of the animation(when you duplicate the key, movement is already locked to the mouse movement). Goto the timeline editor and ensure you have set the last frame of the loop to be the same frame that you placed the last key at. Play the animation. Its ready for export in the normal manner

I hope thats clear enough for you, if its not then sorry. If I could produce a decent tutorial, trust me I would of by now, but the fact is I`m just not the right person for that. For that you need to start with a person who can at least animate decently, and does it regularly(Try 3d chat). I would never accept payment, help from me is always free!

btw you can always use email with any questions if you don`t mind me getting your email address(I assume I will), that way we won`t need to make all these uploads, granted they are small but still its untidy. Gonna remove some in a few days....

Edit: download removed
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 2nd Feb 2009 08:33 Edited at: 2nd Feb 2009 19:58
Many thanks,if I hadnt seen the animation running without deforming I wouldnt of thought poss to export animations in x,but you can,although im still not 100% correct just how yet.
I noticed you snapped the cursor to object center for start.
then space add armature.
Turned off envelopes.
vertex groups is on
b bone rest is on
deleted camera and lamp

im ok upto this point
now with my model that you added a armature too the spine bone was weight painted all the model except the arm,which I tried to adjust by:
clearing the weight paint of the spine and extruding a right arm then weight painting the right arm and redoing the spine the rest of the model but it exports but wont run,so
i started the armature again,
shift s, cursor to selection,object cente
add armature
turn off shapes and envelopes
turned on b bone rest
the spine has 3 parts then neck bone then head bone,
at tip of 3rd spine bone ,the collar bone is where I want to extrude the arms (selected in file)and also the legs from the root of the spine
now when I turn on the x axis mirror to extrude the arms the mirror does not mirror it just extrudes one side only,and im not sure why it doesnt mirror, will not mirroring the arms and
legs work,and does every ounce of weight paint on the model have to be perfect i.e.all the model weight painted in order for it to run with animation.
Heres my file with my spine,the tip of the collar bone is selected from which I want to extrude my collar bones and then 2 bones for the arms, and 2 bones for the hands,could you get my armature to extrude xaxis mirror and if you want to put the arm and hand bones in and test it that would be great,and repost it,
also,it only needs roughly 20 bones weight painted to build the armature,and then finishing for export and to run animations,
if you have the time to finish the armature,that works,and post it,I would gladly buy the info from you,if you are willing to finish the armature or I can just keeping learning one step at a time as per the last week or so

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 2nd Feb 2009 18:48 Edited at: 2nd Feb 2009 18:52
I meant to contact me by email with your email address - posting your email on the board probably isn`t a good idea. If you weren`t
aware, theres buttons at the end of each persons post, if a person wants one they can have an email button(see bottom of my post) by
altering their profile. Only members logged in to the forum can get at it then. If you did know nvm - soz!

My email service has been down the last 12 hrs so I`ll post on here instead
Your nearly there, but I have a change to what I said about there seeming to be a rule with bones, weights and dbp imports. It would
seem that you may get away with leaving vertices unpainted but only after they have been painted once before and then removed - I think blender needs this "once over" paint thing to update data for export with data held internally that the runtime environment deals with automatically. On your mesh, I rigged and painted it only to find at the end that 3 rogue vertices were showing up in dbp. I then cleared each limbs verts of weight values and applied a face to each bone by repainting. The rogue vertices showed up in dbp still! I guessed the rough location of the polygons connected to these verts(in the end there were 4 polygons), then removed and recreated them.(in edit mode select vertices in clockwise order with the camera directly looking at the target face and theres an option in the menu under "faces" to create a face). Works good as a fix but it does suggest that those verts got locked from the end users control, with regards to weight painting only. I do remember at the start I accidently assigned weights without parenting the mesh to the armature first, so when I realised I reduced the paint value to 0 and went back over them. Obviously I mustn`t have got 3 of them!

Quote: "I noticed you snapped the cursor to object center for start.
then space add armature.
Turned off envelopes.
vertex groups is on
b bone rest is on
deleted camera and lamp"

Yeah sorry I never mentioned that, but what do you mean by "b bone rest is on"?
Although vertex groups is on here, when parenting I never choose to create vertex groups, as sometimes when working I may have to clear parents somewhere and want to keep the current groups. The tab I think must be on no matter what, it ensures auto creation of a group and assigns the group name to the bone of the armature currently being painted, if a group isn`t already assigned to that bone. When I refered to the way you create & use them, I assumed it wasn`t the same way I do it as you have many unpainted verts in your projects that export succesfully. This now leaves me to believe your way will prevent exports/imports from crashing as the data for export is the same as the runtime data(basically its like initailising data for export process). The downside is that there is a higher risk of losing access to vertex weights. Before you ask, yes I`ve tried clearing the mesh of weights, after clearing them from bone weights and clearing the parenting.

One thing I forgot about x mirror. You can leave it on, even for export, but to get two bones to extrude using it, you need to hold shift down and press "e", just pressing "e" is for one bone extrusion. Be carefull to only extrude from the tip though, if you had selected the middle part of the bone to extrude using shift and "e" then you will get 4 bones, 2 mirrrored at the tip and two mirrored at the base! Its also worth noting that most of the time right click during a modification throughout blender usually cancels the action you had just taken. Therefore, if you accidentally extrude a bone and ant to start again, you MUST press the delete key after canceling the current action to get rid of the unwanted extrusion. Right clicking only cancels the positioning of the tip, it doesn`t remove the bone.
Attached is your project file rigged and weight painted. I haven`t blended any of the weights in this, basically you need to animate it now and decide where best to blend weights after the basic animation of the bones are in place. You can play the animation in weight paint mode so it makes for ease of editing. Theres another one there with animation, but yo can see why extra vertices are needed and maybe a better skeleton. Once your happy you have a method to do all you need to with blender you should research how best to construct a mesh for bone animation and how best to rig the meshes. I suspect it will mostly be trial and error but there will be known methods.
****I would think getting your hands on a model you know thats been bone animated and works in dbp, and examining its wireframe will help a LOT. You can load the original model into dbp, hide it, create some primitives and place them at the bone locations to get a visual of the structure of the rig you need to build in blender. You also need to save out the mesh from dbp and import it into blender.****
You can find a model suitable for examination from The Game Creator Store as some are free. The one you want is the Ogre(you just use your forum details to login which you need to do to download it - make sure you know where the download is being put)

Attachments

Login to view attachments
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 2nd Feb 2009 21:04 Edited at: 2nd Feb 2009 22:11
Amazing,thanks very much,can we clarify the process:
vertex groups and b bone rest are meant to be off,but when i loaded your models they were on ,poss due to automation
back to the collar bones,
shift e,
extrude arms and hands,
i noticed that you avnt extruded from the root of the spine but from the tip of spine 1
shift e again
extrude legs and feet
xxxxxxfinishing touches herexxxxxx
select mesh,shift select armature
make parent
weight paint
animate
export
are there any buttons,anything that i have missed,i put finishing touches as this is where i thought you might have some input or maybe i have missed elsewhere,example why is the model purple when i get it back?
that camouflage bitmap is exactly what ive been after for my models so thanks alot,I really appreciate the models running which I never would have figured out otherwise,i shall go try some animations now but would like to know about completing the exporting process.
ok,back after some animating,i added a simple animation of the head(posted)on both animations,they both work in the model viewer but crash in dbp,i simply opened the action editor,deleted all from the leg kick,then animated,can you test them and see if you can get them to run.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 2nd Feb 2009 22:17 Edited at: 2nd Feb 2009 22:18
Vertex groups must always be on in that tab, when parenting a mesh to an armature ALWAYS choose to not create vertex groups. This doesn`t effect the tab selection. The tab selection vertex groups on/off the render. Press play and during the animation select and deselect that option to see its effect. For every bone, when you first paint vertices for that bone, a new vertex group is automatically created, any vertices painted for that bone afterwards get assign to that vertex group. If vertex groups exist for a mesh prior to any bone being selected(if a mesh is not parented to an armature), then it belongs to a vertex group I can access and clear after parenting, but if any aren`t properly cleared then there positions aren`t the same in dbp as they are in blender. I`ve attached another file showing this - everything looks the same as in one of the files of the previous download, but the exports shows those rogue vertices. The previous downloads are this file corrected by replacing the polygons that the rogue vertices where part of.
The b-bone option must be a default or something as I always use stick or octrahedron.
The texture is pink because to get it to texture in dbp I don`t use materials. DBP doesn`t support materials. I just switch the mesh to uv mode, switch the panel to the uv editor, place the cursor, in the window, hit "a" until all faces are selected, in the uv editor select replace image from the menu(dds files don`t show up in blender). Next to the option mode slide down window(were you select weight paint, edit etc), is a square window option for wireframe, shaded etc. The green sphere like thing is texture mode. The rule for dbp is 1 mesh, 8(I think)layers of uv coords per mesh, 1 texture per uv layer (or 2 if you count light mapping or alpha maps) AFAIK.
Although you don`t see the texture when you load in the file to dbp, you just load the texture manually in dbp and apply to the object.
When you get all this to work it will take many many edits to get it to how you want it so make sure to back up as you go along.

Edit: not sure were that image is from, I wouldn`t use it for distribution.

Attachments

Login to view attachments
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 2nd Feb 2009 23:07
Im crashing and burning at the final stage as I added a simple animation to the last file waaaa,and it crashed in bdp,my method to add the animation are:
frame 1 select armature, pose mode ,select all,i,loc rot
increase frame, move bone,i loc rot, increase frame,move bone,i loc rot,
then selecting mesh in object mode and exporting,it exports but wont run,almost there I hope,heres the file.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 2nd Feb 2009 23:07 Edited at: 2nd Feb 2009 23:44
Just spotted your edit - It imports into dbp just fine for me. Are you using upgrade 7.1 official release?

Edit ...and just saw your post! Will reply in a sec

Edit: ? Your second export works fine too. Whatever you did also altered the weights to the polygons I fixed as they are odd again...or you used the last download which I put up to show the error I had with those polygons - if so use the previous download that has two blend files in it - the one without any animation is good to export and just needs animation

If you still get crashes, what version of blender & dbp do you have? (sorry if I already asked)

Edit yet again! : Whenever you create a new animation frame tap "a" until all bones are selected then press "i".
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 3rd Feb 2009 08:53 Edited at: 3rd Feb 2009 10:45
The model kicking,runs in the model viewer but crashes bdpro.they`re all crashing when i add animation.
My bdp version is 1.055.
my blender version is 2.48a.
heres the kick file that crashes in bdp but runs in the model viewer,no alterations av been made,see if it runs in dbp on your comp then obviously i av a prob this end if it runs your end.

I have not upgraded my bdp.Maybe this is all that is required.
EDIT:The kick model WORKS WITH THE UPGRADE 7.1,YES.
I have my first animation now,modified from the kick,no deformations,nothing irregular.The upgrade did the trick,thankyou very much for all your help.Did you get my email address.If you send me a email I can get in touch if I require any further help,which im certain I will,and will also use this forum.
Many,many thanks PH.

Attachments

Login to view attachments
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 3rd Feb 2009 15:51 Edited at: 3rd Feb 2009 16:02
Hey no worries you got there in the end
Yes I got the email address written down. Feel free to use the email button at the bottom of my post - thats what its for - I`ve sent you a mail anyway so you can get the address off that if you need to.

Edit: actually my isp sent the mail back that I sent you, I must have made an error when I copied your email address - can you just use the email button at bottom of post and send me one? Make sure you type the email address IN the message aswell, because you haven`t made you address public, chances are that when I recieve your mail, I won`t be able to just reply in the standard manner.
Cheers
paulhenry
16
Years of Service
User Offline
Joined: 20th Jun 2008
Location:
Posted: 3rd Feb 2009 16:13 Edited at: 3rd Feb 2009 16:13
We did get their in the end,now for the programming challenges,
Below is my code for controlling the character,3rd person,but I have a problem when forward is pressed, the player faces the camera,so you cant rotate and go forward,you can rotate but when forward is pressed the player changes back and faces the camera,the animation works very well.Also if you could adapt the code to move the object forward by 1 on z axis with up.
ps i avnt recieved your email.u sure u got corrrect address.


load object "Waitingworks4.x",1
load object "Waitingworks5walk12.x",2
hide object 2
position object 2, 0, 0, 0
xrotate object 2,90
position object 1, 0, 0, 0
xrotate object 1,90
aY# = Object angle Y(1)
REM START LOOP
DO

IF UPKEY() = 0
HIDE OBJECT 2
SHOW OBJECT 1
set object speed 1,5
LOOP object 1,1,231
ENDIF


if upkey() = 1
hide object 1
show object 2
set object speed 2,5
LOOP object 2,1,21
ENDIF

rem IF LEFTKEY() = 1

Rem Control input
rem If Upkey()=1 then Move object 1,2
If Leftkey()=1 then aY# = Wrapvalue(aY#+1)

If Rightkey()=1 then aY# = Wrapvalue(aY#-1)

rem rotate the sphere
Yrotate object 1,aY#


LOOP
James H
17
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 3rd Feb 2009 17:38 Edited at: 3rd Feb 2009 17:41


That should work. In future place your code in a snippet box by clicking the code button (centimetres from were you type up your post), once before pasting/typing in your code and once after

To save on resources for performance your much better off using one object with all the animation in it. Its standard practice. There are two other steps to take that can help reduce resources/increase performance, the first is to apply a shader to the model called fastbone.fx(you can utilise the google forum search feature at the bottom of any forum page to find it) - if you have a half decent graphics card you should see a performance increase when the framerate isn`t restricted, the other is to use enhanced animations plugin(available to purchase for a small price from the TGC homepage). You would only see a reduction of animation data with this plugin, ie if all your models have the same bone structure you can use saved out data from one and apply it to another. In addition to this enhanced animations gives a smooth transition between animations though it takes dome additional codeing. I think you might be impressed with this feature alone, theres also a demo of enhanced animation available.

btw I edited my last post about your email address. I DID copy it wrong

Login to post a reply

Server time is: 2024-11-24 15:10:10
Your offset time is: 2024-11-24 15:10:10