Center Point in Entity

Blitz3D Forums/Blitz3D Beginners Area/Center Point in Entity

This function will center your mesh assuming it has a depth, height and width of > 0


Function MESHmidhandle( mesh )

  Mw# = meshwidth( mesh )
  Mh# = meshheight( mesh )
  Md# = meshdepth( mesh )
  fitmesh mesh, -.5*mw, -.5*mh, -.5*md, mw,mh,md

End Function