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 / 3d mesh nodes recogized by DBP?

Author
Message
Straxus
15
Years of Service
User Offline
Joined: 6th Oct 2009
Location: Beaverton, Oregon
Posted: 22nd Feb 2011 23:05
Have been searching the forums last few days and have not seen anything that discusses this, so not sure if it's possible or not.

Was curious if I exported a 3d model with dummy nodes to use such as hardpoint locations for weapons (or specific hit locations in the model or where damage effect particle emitters would go)
is there a way to have darkbasic recognize these nodes and make use of them?
For example if a loaded mesh had a dummy node named "hp1", is it possible to write function(s) that would recognize the "hp1" node and convert that node's position (in the object mesh) into xyz coordinates as needed instead of having to write out positions of these locations for every single object type loaded?
As the game in question would be a space based game with multiple sized and shaped ships and stations with different placed "hardpoints" and "critical locations" it would be much more efficient than having to write out these locations for each item type.
Sixty Squares
18
Years of Service
User Offline
Joined: 7th Jun 2006
Location: Somewhere in the world
Posted: 23rd Feb 2011 00:30
I'm not entirely sure, but if these "mesh nodes" are counted as limbs of the object then you could cycle through each limb and use the LIMB NAME$() command to recognize the nodes.


Guns, cinematics, stealth, items and more!
Straxus
15
Years of Service
User Offline
Joined: 6th Oct 2009
Location: Beaverton, Oregon
Posted: 23rd Feb 2011 08:32
Thanks for the info! I see now that the "mesh nodes" are essentially the same as limbs, which made searching for additional information easier.
Gave it a shot and used the limb names$ on some exported models. Found that I can't use the dummy nodes (at least with my exporting methods), though I can export tiny cubes for the hardpoint locations in the exported mesh model and just hide them with the hide limb commands.
LBFN
17
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 23rd Feb 2011 16:44
Why not just create limbs at the locations you want in your modeling program and then export it as an .x model? For example, where you want the exhaust from the ship to come out, just place a limb there (connected to the root limb of course) and use the limb position commands to determine where the exhaust port is in 3D space.

I think with .3ds format models, DBP recognizes the individual meshes as limbs, but I also think it goes to the center point of the limbs as to the x, y, z location and would not be as accurate as creating limbs/bones and using an .x format model.

I can further illustrate this if needed, or if you want to send me your model, I can rig it for you to show you what I mean.

Straxus
15
Years of Service
User Offline
Joined: 6th Oct 2009
Location: Beaverton, Oregon
Posted: 25th Feb 2011 21:57 Edited at: 25th Feb 2011 22:56
@LBFN: Took a while to get back to this because I have been trying to find anything that could export a .X format file with the limb/bones intact.
EDITED POST: Got program to work and exports everything the way I need!
Thanks again guys for the assistance. Now that this is done I can final focus on learning/coding dbp again.

Login to post a reply

Server time is: 2024-11-23 03:11:54
Your offset time is: 2024-11-23 03:11:54