maybe try
Code:

my.x = (vec_pos1.x+vec_pos2.x)/2;
my.y = (vec_pos1.y+vec_pos2.y)/2;
my.z = (vec_pos1.z+vec_pos2.z)/2;