C++ Game Programming
Basic C++ Lessons
This set of lessons will give you a simple introduction to programming in the C++ language.
Allegro Lessons
This set of lessons will demonstrate how to use the Allegro graphics library to create video games.
Game Source Code
Here you will find source code to several games so that you can see the code in action.
Recommended Books
Here is a list of books which should help you with C++

Classes
Now for the object oriented programming. Classes are used to create object which can be given different properties and functions just like real life objects making them easier to work with than just a bunch of lose variables. Heres an example:

#include <iostream>

using namespace std;

class dog{

public:

	dog();
	~dog();
	int getAge();	
	void setAge(int a);

protected:
	int age;


};

dog::dog(){


}

dog::~dog(){

	

}

int dog::getAge(){

	return age;

}

void dog::setAge(int a){

	age = a;
}

int main(){


	dog myDog;

	myDog.setAge(5);
	
	cout << "The dog is " << myDog.getAge() << " years old!\n";

	system("pause");

	return 0;

}
Here I started by creating a class called "dog". After the class declaration I definded some variables and functions as public and others protected. Public means any function can access them, protected ones can only be called from inside the class. Classes have two special functions called the constructor ( dog() ) and the deconstructor (~dog() ) which are called when an instance of the class is created and destroyed respectively.

"dog myDog" creates an instance of dog called myDog, myDog would be the actuall object modelled after the dog class. In order to run a function inside a class you must use the name of the instance followed by a "." and the name of the function (myDog.setAge()). The same goes for any public variables you may have declared.

Google