C-Engine/include/Map/Level.hpp

63 lines
1.9 KiB
C++

/* ************************************************************************** */
/* _____ */
/* Level.hpp | ___| _ ____ ___ */
/* Project : C-Engine | |_ | | | __| / _ \ */
/* | _| | | | |= | __/ */
/* By: Fife <wasabifife@gmail.com> |_| |_| |_| \___| */
/* */
/* */
/* ************************************************************************** */
#ifndef CENGINE_LEVEL_HPP
#define CENGINE_LEVEL_HPP
#include "..\Rework\CEngine.hpp"
class Level
{
public:
Level();//Constructeur
void AffectWorld( World * v );
World * GetWorld();
void SetMap( const unsigned char * userTileset , unsigned char * userMap , bool * userProperties, int userTileWidth , int userTileHeight , int userWorldWidth , int userWorldHeight);
int GetIdMap( int x, int y );
void ReplaceIdMap( int x , int y, char v );
void DrawMap();
Object ** GetListeObject();
int GetNbObject();
void AddObject( Object * v); //Ajout un objet au level
bool DelObject( Object * v); //Supprime l'objet
void DelAllObject(); //Supprime tout les objets
int tileWidth;
int tileHeight;
int levelWidth;
int levelHeight;
private:
World * worldLink;
unsigned char * map;
const unsigned char * tileset;
bool * solid;
int tilegap;
int xscroll,yscroll;
Object ** listeObject;
int nbObject;
};
#endif