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 Discussion / the door won't

Author
Message
HomerS
17
Years of Service
User Offline
Joined: 8th Apr 2007
Location:
Posted: 29th May 2014 20:39
Hi all,

How to get the door turned open/closed the correct way?

Here is my code.



Do I have to do something with it as a limb???

Toedeledoki
MrValentine
AGK Backer
13
Years of Service
User Offline
Joined: 5th Dec 2010
Playing: FFVII
Posted: 29th May 2014 21:35
You need to offset the door, by 50% on the width...

Are you using DBPro or DBClassic?

TheComet
17
Years of Service
User Offline
Joined: 18th Oct 2007
Location: I`m under ur bridge eating ur goatz.
Posted: 29th May 2014 21:36 Edited at: 30th May 2014 14:45
The center of the object needs to be shifted for the door to rotate correctly. A trick you can use is to offset the root limb (limb 0):



Quote: "Are you using DBPro or DBClassic?"


This is a DBC board, so he should be using DBC.

Your dungeon has been arrested by a signature image because it tried to be a mod
HomerS
17
Years of Service
User Offline
Joined: 8th Apr 2007
Location:
Posted: 30th May 2014 11:42
Hi,

Yes it is classic.

I used your code, it misses the limbnr 0? like this



but it still turns in the middel

Here it is in the complete code...



Toedeledoki
29 games
18
Years of Service
User Offline
Joined: 23rd Nov 2005
Location: not entirely sure
Posted: 30th May 2014 13:11
Once you've offset the limb to reposition the door's centre you then need to move the door.



I modified your code in DBPro but it should work in DBC.

Silverman
17
Years of Service
User Offline
Joined: 18th Jan 2007
Location: France
Posted: 30th May 2014 16:05
hi,

29 games, your code not work correctly in dbc.

modified:


DirectX 9.0c (February 2010)/ DBClassic v1.20
HomerS
17
Years of Service
User Offline
Joined: 8th Apr 2007
Location:
Posted: 30th May 2014 19:21
Thank all,

Now that works like a real door. LOL

So the next thing for me to do to change the turningpoint:
1. make an object.
2. ofset an object.
3. make a mesh from an object.
4. delete the object.
5. make an object from the mesh.

right?



I shall show the programm when it is finished.

Toedeledoki
Silverman
17
Years of Service
User Offline
Joined: 18th Jan 2007
Location: France
Posted: 31st May 2014 13:54
right!

DirectX 9.0c (February 2010)/ DBClassic v1.20

Login to post a reply

Server time is: 2024-11-21 12:21:59
Your offset time is: 2024-11-21 12:21:59