Original Post
Not sure if this topic is valid here, but here goes. I'm finally discoverd how to implement a 'followmode' in my program by using the timerfunc of GLUT. Now i use this code, but unfortunately, it keeps incrementing the field by the translations. I could do a loadidentity or something akin, but i tried that, does not work. I tried everything, can't see where the problem is. It also doesn't seem to translate properly, but that's another problem. I tried setting to modelview matrix, push and popping the view, nothing. If anyone can provide me with any insight on this, it would be most welcome. What the timerfunc basically does is it translates to an already drawn object on screen, that's all. In this case it always translates to the last node, hence the word followmode.
GLvoid follow_mode(GLvoid)
{
if(o_tail) {
glTranslatef(atof(o_tail->x),atof(o_tail->z),atof(o_tail->y));
glutPostRedisplay();
}
glutTimerFunc(1000,follow_mode,0);
//glutPostRedisplay();
}