Newton Rotation Help needed

BlitzMax Modules Forums/MiniB3D/Newton Rotation Help needed

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

	Method RotateMesh(pitch#,yaw#,roll#)
	
		pitch#=-pitch#
		
		Local mat:TMatrix=New TMatrix
		mat.LoadIdentity()
		mat.Rotate(pitch#,yaw#,roll#)
		TransformMesh(mat)
		
		' set new_bounds to true so MeshWidth/Height/Depth will get new width/height/depth values next time it's called
		new_bounds=True
		
		UpdateBuffer()
	End Method


The local matrix is only used within the function to transform the mesh's vertices, the entity's own matrix is unaffected.