2014-01-24 10:22:18 +01:00
|
|
|
//////////////////////////////////
|
|
|
|
// Created by Sam Svensson 2013 //
|
|
|
|
//////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef LEVELLOADER_H
|
|
|
|
#define LEVELLOADER_H
|
|
|
|
|
2014-01-24 10:42:19 +01:00
|
|
|
#include <string>
|
2014-01-24 10:22:18 +01:00
|
|
|
#include <vector>
|
|
|
|
#include <Vector.h>
|
|
|
|
#include "ObjectDefines.h"
|
|
|
|
#include "LevelParser.h"
|
|
|
|
|
|
|
|
namespace GameLogic
|
|
|
|
{
|
|
|
|
class LevelLoader
|
|
|
|
{
|
|
|
|
|
|
|
|
public:
|
2014-01-24 10:42:19 +01:00
|
|
|
LevelLoader(){this->parser = new GameLogic::LevelFileLoader::LevelParser(); }
|
|
|
|
~LevelLoader(){}
|
2014-01-24 10:22:18 +01:00
|
|
|
std::vector<ObjectTypeHeader> LoadLevel(std::string fileName); //loads the level and objects from file
|
2014-01-24 10:42:19 +01:00
|
|
|
ObjectTypeHeader LoadLevelHeader(std::string fileName); //just for fast access for the meta information about the level.
|
2014-01-24 10:22:18 +01:00
|
|
|
|
|
|
|
private:
|
2014-01-24 10:42:19 +01:00
|
|
|
GameLogic::LevelFileLoader::LevelParser *parser;
|
2014-01-24 10:22:18 +01:00
|
|
|
};
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|