This repository has been archived on 2021-11-25. You can view files and clone it, but cannot push or open issues or pull requests.
TowerDefense/tmxparser.h

32 lines
478 B
C++

#pragma once
#include <string>
#include <vector>
class Layer
{
public:
int width,height;
std::string name;
std::vector<std::vector<int>> data;
};
class Tileset
{
public:
int firstgid;
int tilewidth,tileheight,tilecount,columns;
std::string source;
int width,height;
};
class Map
{
public:
std::vector<Layer> data;
std::vector<Tileset> tiledata;
int tilewidth,tileheight;
Map(const std::string& TMXFilename);
Map()=default;
};