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 / i know this is a newb question but how do i use newxvalue?

Author
Message
kfoong
21
Years of Service
User Offline
Joined: 28th Jan 2003
Location: Australia
Posted: 10th Apr 2003 16:31
So how? I just do not get it, someone please explain to me!
--------
http://www.stellarblue.vze.com/
Danmatsuma
21
Years of Service
User Offline
Joined: 2nd Mar 2003
Location: Australia
Posted: 10th Apr 2003 17:26
Click on the source button bottom left.

The step# value is how far to move your object
the direct_ang# value is the angle to use.

if you mess with those two values you should get the hang of it.

In this 'lil example you just control the curve to the left or right of the sphere by changing the value of direct_ang#.
Left and Right keys

ZX Spectrum 48k Issue 3, Radio shack Tape drive, Rank arena 12" T.V. set.
BoB Vila
21
Years of Service
User Offline
Joined: 27th Feb 2003
Location: United States
Posted: 10th Apr 2003 17:28
Ok, Say you are at a point in 3D space. and you wanted to then move to a new direction based on an angle. you would use the newXYZvalue command.

I wrote a centipede game, and when the centipede moves left, right and down. To make the models head move in the new direction, I used the newXangle command that would either calculate a point that was 90 degrees from the model or 270 degrees from the model and then point the object at it. (I could use the same Z and Y as I currently was using)

I hope that explains it a little bit. I wasn't exactly sure what it did at first, until I needed to find points and I only had angles. Its a very powerful command.

So in review... you use a current X value, an angle from the X value, and the step value of how far in 3D space you want your new X value to be from the "current" one.

Hope that helps.

Bobvila.com made me take off my avatar! (dunno how they found out)
Chiwawa
21
Years of Service
User Offline
Joined: 13th Oct 2002
Location: Canada
Posted: 10th Apr 2003 19:51
in fact...these function are 2d... sorry

see that:




my functions..is EXACTLY the same thing..and this is for 2D.. it just take the distance..and decompose it in X and Z ..and add it to the original X and Z ...you cant use..it for 3D ..you should do some other ..math if you want to use XYZ ..at the same time..

but to move in 3d World..when your matrix..is not flat you need to do something like that:



i know...its the 3 same function...but with diffrent result...i could put another parameter to say wich ...value i want into the result..but..

and see the .."print"...it print the 3d distance between ..last loop......and its sopposed to be 5...and its ALMOST ..always 5..im precise..at 0.001 even more..

then IM THE KING OF 3D

i hope it will help you...
if you have any comment.......say it
kfoong
21
Years of Service
User Offline
Joined: 28th Jan 2003
Location: Australia
Posted: 11th Apr 2003 01:54
chiwawa youre not helping me

--------
http://www.stellarblue.vze.com/
Chiwawa
21
Years of Service
User Offline
Joined: 13th Oct 2002
Location: Canada
Posted: 11th Apr 2003 02:11 Edited at: 11th Apr 2003 02:14
ok..sorry ..but ive fully explained ..3d moving and NewXYZValue..in french..on DB french forum... but in english.. im not enough good...to explain all what i want to explain..sorry..

but at least..you have my 3 function.......in my second example..use that if you want 3d motion...you can tweak them a little bit..to fit in your code..if you want

and ..now you know what there is "inside" on the newxvalue and the newzvalue.... then..you should understand...if not..... u just not enough ...experimented in math.. just go to school..and come back ke ke ke...just kidding ...

just ask someone who speak english..

Login to post a reply

Server time is: 2024-09-20 03:44:50
Your offset time is: 2024-09-20 03:44:50