Yes, I'm getting the M6 command from Lcam generated code. 
I'll try to post what you asked for. (I'm a total VB moron)
M6 start macro is
tool = GetSelectedTool()
  SetCurrentTool( tool )
end is
 x = GetToolChangeStart( 0 )
y = GetToolChangeStart( 1 )
z = GetToolChangeStart( 2 )
a = GetToolChangeStart( 3 )
b = GetToolChangeStart( 4 )
c = GetToolChangeStart( 5 )
SafeZ = GetSafeZ()
if  SafeZ  > z then StraightTraverse x, y,SafeZ, a, b, c 
 StraightFeed  x, y,  z  , a, b, c