fixed minor erros in triangle creation