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 / X VECTOR3( ), Y VECTOR3( ), Z VECTOR3( ) Problems

Author
Message
Jones 205
23
Years of Service
User Offline
Joined: 15th May 2003
Location:
Posted: 24th May 2003 01:13
With reference to the Attached Code, I am obviously missing something.

`Expecting an output of -2, 0, -1
`instead get 2, 0, 1
`Using Patch 4.1, Any ideas?
kevil
23
Years of Service
User Offline
Joined: 24th Nov 2002
Location: Netherlands
Posted: 24th May 2003 01:33
I have an idea!

The vars Point0, Point1 and Point2 all hold the same value.

Kevil

Jones 205
23
Years of Service
User Offline
Joined: 15th May 2003
Location:
Posted: 24th May 2003 11:07
Yes but they should not, Three different vectors, -2 is different from 2 and -1 is differnet from 1.

Dmitry K
23
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Russia
Posted: 24th May 2003 11:17
Point0=1
Point1=2
Point2=3
Ra=make vector3(Point0)
Rb=make vector3(Point1)
Rc=make vector3(Point2)
Set Vector3 Point0, -2,0,-1
Set Vector3 Point1, -2,0,1
Set Vector3 Point2, 2,0,1
x0#=X VECTOR3(Point0)
y0#=Y VECTOR3(Point0)
z0#=Z VECTOR3(Point0)
text 0,0,str$(x0#)
text 100,0,str$(y0#)
text 200,0,str$(z0#)
wait 1000
Jones 205
23
Years of Service
User Offline
Joined: 15th May 2003
Location:
Posted: 24th May 2003 13:03
Thanks DMiTROS, Works fine, I knew i was missing something.

Login to post a reply

Server time is: 2026-07-11 13:58:19
Your offset time is: 2026-07-11 13:58:19