#include <SDL/SDL.h>
#include <SDL/SDL_opengl.h>
#include <GL/gl.h>
#include <GL/glu.h>

#include <stdio.h>
#include <stdlib.h>
#include <stdexcept>
#include <string>
#include <vector>

using namespace std;

#include "Moteur.h"
#include "PersoPrincipal.h"
#include "Map.h"
#include "Interface.h"

#include "main.h"
#include "Intro.h"
#include "Menu.h"
#include "RenderJeu.h"

#define TITRE "The Paradize Battle : Angel VS Evil"


int main(int argc, char *argv[])
{
	if(Moteur.Init(false, TITRE) < 0) return -1;

	FonteStandard = Moteur.NouvelleFonte("Standard");
	ImgArrierePlan = Moteur.NouvelleTexture("./Images/ArrierePlanMenu.png");
	ImgMotifArrierePlan = Moteur.NouvelleTexture("./Images/MotifAP.png");
	
	Map.LoadTextures();
	
	PersoPrincipal = Map.LoadMap("Map1.map");
	
	Interface.LoadInterface();

	while(continuer)
	{
		switch(nbRender)
		{
			case RENDER_MENU_PRINCIPAL:
				nbRender = BoucleRenderMenu();
				break;

			case RENDER_JEU:
				nbRender = BoucleRenderJeu();
				break;

			case RENDER_INTRO:
				nbRender = BoucleRenderIntro();
				break;

		}
	}

	SDL_Quit();

	return 0;
}
