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.

DarkBASIC Professional Discussion / Deleting Character or Model Bone/Skeleton

Author
Message
RustyKristy
8
Years of Service
User Offline
Joined: 13th Jan 2016
Location:
Posted: 24th Jul 2018 10:19
Hi, still lost with what command to use, so how do you delete a particular bone or the whole skeleton of a rigged model in DBPro?
Bored of the Rings
User Banned
Posted: 24th Jul 2018 11:28 Edited at: 24th Jul 2018 11:35
ok well for my DBOtoX export app, I used [edit] ]remove limb. If I get time later I'll post code, just at work at moment (well at home) but maybe during my break I'll grab it and post here.

[update-here a code snippet]



Now, it's been a while playing with that command, but you might find you have to reverse the values in the FOR...NEXT statement i.e. for l=maxlimbs-1 to 1 step -1,,,,, as I no longer use this code and I think originally I had the FOR bit ...working backwards.....so long ago....maybe I need to test again see what happens.
Professional Programmer, languages: SAS, C++, SQL, PL-SQL, DBPro, Purebasic, JavaScript, others
RustyKristy
8
Years of Service
User Offline
Joined: 13th Jan 2016
Location:
Posted: 25th Jul 2018 04:34
thanks BoTR. I tested and nothing happens, it does increase the saved object file by 1kb and that's about it. How does DBPro distinguish between bone and submeshes? as I see the limb term is again used there.
Bored of the Rings
User Banned
Posted: 25th Jul 2018 06:29
so, the "get limb fvf(objID,l) =0", part of the code is saying, if there isn't a mesh for this limb delete it. So it wont delete anything if your limbs have meshes e.g. Also, did you try stepping backwards i.e. last limb to first limb in the FOR...NEXT as explained above? remove the "get limb FVF" bit and see what happens.
i.e. for l=maxlimbs-1 to 1.
Professional Programmer, languages: SAS, C++, SQL, PL-SQL, DBPro, Purebasic, JavaScript, others
RustyKristy
8
Years of Service
User Offline
Joined: 13th Jan 2016
Location:
Posted: 26th Jul 2018 02:20 Edited at: 26th Jul 2018 02:20
I see and maybe I'm doing it wrong. Can you please elaborate by posting a short full example with a DBO boned mesh (even not rigged)? I'm also trying to find any documentation related to manipulating bones by code with DBPro but could not find one. What I find weird in fragmotion is it labels other entities as bones if they are not meshes.
Bored of the Rings
User Banned
Posted: 26th Jul 2018 10:30
actually ,it would be good if you could post your code and I can tell you where your going wrong
Professional Programmer, languages: SAS, C++, SQL, PL-SQL, DBPro, Purebasic, JavaScript, others
RustyKristy
8
Years of Service
User Offline
Joined: 13th Jan 2016
Location:
Posted: 26th Jul 2018 12:11
This is the code that you posted now with all your suggestions and I just added the saved part for me to check if the Skeleton or bone is removed.



Skeleton is still there..
Bored of the Rings
User Banned
Posted: 26th Jul 2018 15:15 Edited at: 26th Jul 2018 19:09
[edit-let me look further into this....normally only works with character bones......]
Professional Programmer, languages: SAS, C++, SQL, PL-SQL, DBPro, Purebasic, JavaScript, others
LBFN
16
Years of Service
User Offline
Joined: 7th Apr 2007
Location: USA
Posted: 28th Jul 2018 15:07
Don't you need a step -1 included here:



So many games to code.....so little time.
Bored of the Rings
User Banned
Posted: 28th Jul 2018 15:32 Edited at: 28th Jul 2018 16:06
@LBFN - yes you are correct, didn't spot that wiv me trained eye...... thanks a lot

Professional Programmer, languages: SAS, C++, SQL, PL-SQL, DBPro, Purebasic, JavaScript, others

Login to post a reply

Server time is: 2024-03-29 13:33:02
Your offset time is: 2024-03-29 13:33:02