Tileson 1.4.0
A helpful json parser for Tiled maps
Loading...
Searching...
No Matches
Public Member Functions | List of all members
tson::Grid Class Reference

#include <Grid.hpp>

Public Member Functions

 Grid ()=default
 
 Grid (IJson &json)
 
bool parse (IJson &json)
 
const std::string & getOrientation () const
 
const Vector2igetSize () const
 

Constructor & Destructor Documentation

◆ Grid() [1/2]

tson::Grid::Grid ( )
inlinedefault

◆ Grid() [2/2]

tson::Grid::Grid ( IJson json)
inlineexplicit

Parses Tiled grid data from json

Parameters
json

Member Function Documentation

◆ getOrientation()

const std::string & tson::Grid::getOrientation ( ) const
inline

'orientation': Orientation of the grid for the tiles in this tileset (orthogonal or isometric)

Returns
orientation as string

◆ getSize()

const tson::Vector2i & tson::Grid::getSize ( ) const
inline

'width' and 'height': Size.

Returns
size as int

◆ parse()

bool tson::Grid::parse ( IJson json)
inline

Parses Tiled grid data from json

Parameters
json
Returns
true if all mandatory fields was found. false otherwise.

The documentation for this class was generated from the following file: