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 / Still stuck on limbs

Author
Message
shadey
16
Years of Service
User Offline
Joined: 25th Jan 2010
Location:
Posted: 15th Oct 2012 11:12 Edited at: 15th Oct 2012 11:25
I am still trying to delete unwanted limbs from a model to be replaced by an object, my code is abit messy now as i took out the functions to test, but anyhow here is what i have so far:




the code above kinda works,the limbs get deleted... but it is placing the 'baddie' at 0,0,0 which is not the limbs origin, I can see that by printing tt$ in the main loop!

** edit **
I made all vars global also

Hail to the king, baby!
MrValentine
AGK Backer
15
Years of Service
User Offline
Joined: 5th Dec 2010
Playing: FFVII
Posted: 16th Oct 2012 04:51
In the other thread I could not understand the purpose of stepping Negative One... basically you are jumping back one nimber or maybe I do not understand this concept enough...

Eitherway... I hope you are calling this outside of the loop...

Can you send the project for checking over?

Brendy boy
20
Years of Service
User Offline
Joined: 17th Jul 2005
Location: Croatia
Posted: 16th Oct 2012 06:11
post the whole project so we can check

James H
19
Years of Service
User Offline
Joined: 21st Apr 2007
Location: St Helens
Posted: 19th Oct 2012 12:37
Has been a while since I played with dbp as I been busy and am not at my machine to check, but does limb position x etc not give world position and limb offset x etc give the limb position relative to the model which is what you want?
Green Gandalf
VIP Member
21
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 19th Oct 2012 14:17 Edited at: 19th Oct 2012 14:21
This looks wrong to me:



If you have v limbs then they will be numbered from 0 to v-1 NOT from 1 to v.

Could that be your problem?

My guess is you want



i.e. I'm assuming you don't want to delete limb 0.

I haven't checked the rest of your code though.

Edit No, I don't think that's the problem since you've checked whether the limb exists before doing anything with it.

Must be something else.
Green Gandalf
VIP Member
21
Years of Service
User Offline
Joined: 3rd Jan 2005
Playing: Malevolence:Sword of Ahkranox, Skyrim, Civ6.
Posted: 19th Oct 2012 14:56
Just done a quick test using a boned animated model. As far as I can tell this works - except for the fact that the main object disappears. That might be something to do with it being animated though.

Delete limbs one at a time by pressing <d> - if you move the object then the new spheres seem to be in the right place (even though you can't see the model after the first deletion ).

Login to post a reply

Server time is: 2026-07-08 10:16:52
Your offset time is: 2026-07-08 10:16:52