Hey,
So I'm new to OpenGL but I've covered and played with the basics. I'm creating a 2D game and I want the view/camera/screen/whatever to follow the user controlled character (which is aimed to be centered at all times) creating a scrolling effect like that of, for example, Mario on the SNES.
I'm hoping there is a way for me to accomplish this by adding a few lines to my current code, where:
void processKeys(){
if(keys[VK_LEFT])
{
Xcoord-=0.25;
}
moves the user controlled character through translate
glTranslatef(Xcoord, Ycoord, 0.0);
If this can be done, how? If it can't, how should I attempt to get it working?