Fix bug in calculating center of child plane