TFormVector/TFormPoint

Blitz3D Forums/Blitz3D Programming/TFormVector/TFormPoint

Makepool(Posted 2005) [#1]
What's the difference ay? Surely they both return the same results.


sswift(Posted 2005) [#2]
I'm just guessing, but I think TFormVector ignores the scale of the entity, whereas TFormPoint does not.

That way, your objects do not move faster when you scale them up if you are using TFormVector to calculate their trajectories and physics.


Stevie G(Posted 2005) [#3]
That way, your objects do not move faster when you scale them up if you are using TFormVector to calculate their trajectories and physics.


Not true. Logically, the TFORM commands always take the entityscale into consideration.


fredborg(Posted 2005) [#4]
TFormVector doesn't take position into account, while TFormPoint does.

TFormNormal is the same as TFormVector except it normalizes the vector, so it always has a length of 1 unit.

An example would be, you want to know where a vertex in a mesh is in your world/game, so you use:
TFormPoint VertexX,VertexY,VertexZ,mymesh,0

You might also want to know which direction the vertex's normal is pointing in the world/game, so you use:
TFormVector VertexNX,VertexNY,VertexNZ,mymesh,0
(You could also have used TFormNormal for that)

So TFormPoint is for finding out stuff about a location, while TFormVector is for finding out stuff about a direction.