I'm having real trouble positioning my objects consistantly.
I'm creating a pivot and positioning the mesh so that the pivot is in the centre of the mesh, and then positioning the object at 0,0,0
This works for one mesh, but another one is way out for some reason.
and this for creating the initial positions
and this for displaying them :
I'm creating a pivot and positioning the mesh so that the pivot is in the centre of the mesh, and then positioning the object at 0,0,0
This works for one mesh, but another one is way out for some reason.
playArea[index].pivot=CreatePivot() playArea[index].mesh=CopyMesh(loadData[6].mesh,playArea[index].pivot) PositionEntity playArea[index].mesh,0.0-(MeshWidth(playArea[index].mesh)/2.0),0.0-(MeshHeight(playArea[index].mesh)/2.0),0.0-(MeshDepth(playArea[index].mesh)/2.0)
and this for creating the initial positions
s.pivot=CreatePivot() s.mesh=CopyMesh(loadData[7].mesh,s.pivot) PositionEntity s.mesh,0.0-(MeshWidth(s.mesh)/2.0),0.0-(MeshHeight(s.mesh)/2.0),0.0-(MeshDepth(s.mesh)/2.0)
and this for displaying them :
PositionEntity playArea[index].pivot,0.0,0.0,0.0 PositionEntity s.pivot,0.0,0.0,0.0