Game Development Community

Making a new MatrixF object

by Ian Omroth Hardingham · in Torque Game Engine · 03/11/2002 (10:55 am) · 1 replies

Hey guys.
Can anyone tell me how to make a new matrixF object in the scripting language?

I'm trying to put the camera in a fixed position, and I'm not sure how to construct the transform matrix from just the coordinates.

Cheers.
Ian

#1
03/11/2002 (2:19 pm)
MatrixF isn't a console object, so you can't create it in the scripting language.

You'll need to pass the necessary info to the engine code and have it create the matrix. You can use TypeMatrixPosition and TypeMatrixRotation fields for that. (Look at the relevant getData/setData functions in engine/math/mathTypes.cc for the format.)