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 / how do i get the real # for y rotation?

Author
Message
David iz cool
19
Years of Service
User Offline
Joined: 21st Sep 2005
Location: somewhere lol :P
Posted: 24th Oct 2005 16:07
hi,i have some code like:

print yangle object(1)

i rotate my object,it gives me a # of 40

i then change my code to this:
yrotate object 1,40

but my object is not rotated the right angle now.
i play with it & find out the yangle i wanted is like -140 or something like that.

so how do i get the 'real' yrotation #????
NanoBrain
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Portland, OR
Posted: 24th Oct 2005 16:31
David iz cool,

To start, DB only allows a angle between 0 and 360 to rotate objects. If you are using atanfull, coming up with negative angle value. Then, convert the negative value angles to a correct positive value by incrementing them by 360.





+NanoBrain+
Sven B
19
Years of Service
User Offline
Joined: 5th Jan 2005
Location: Belgium
Posted: 24th Oct 2005 22:31
Or if you want to save some place:



It does completely the same. The only difference is the number of command lines...

Immunity and Annihalation makes Immunihalation...
NanoBrain
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Portland, OR
Posted: 25th Oct 2005 02:37
Sven B,

Never experimented doing it that way. Thanks.



+NanoBrain+
Sven B
19
Years of Service
User Offline
Joined: 5th Jan 2005
Location: Belgium
Posted: 25th Oct 2005 20:19
Never too old to learn...

Not that you're old ofcourse

Immunity and Annihalation makes Immunihalation...
NanoBrain
19
Years of Service
User Offline
Joined: 20th Jan 2005
Location: Portland, OR
Posted: 25th Oct 2005 21:05
Sven B,

Yes, I have many years ahead of me...maybe.



+NanoBrain+

Login to post a reply

Server time is: 2024-09-24 07:34:01
Your offset time is: 2024-09-24 07:34:01