tmxlite: tmx::ObjectTypes Class Reference

tmxlite 1.0.0 lightweight parse for Tiled maps

Classes | Public Member Functions | List of all members
tmx::ObjectTypes Class Referencefinal

Parser for Tiled object types export format. Link to the specification: https://doc.mapeditor.org/fr/latest/manual/custom-properties/#predefining-properties. More...

`#include <ObjectTypes.hpp>`

## Classes
struct | Type
| Types that stores all predefined properties for all objects of this type. To take less spaces, they are not exported by default into maps. More...

## Public Member Functions
bool | load (const std::string &)
| Attempts to parse the object types at the given location.
bool | loadFromString (const std::string &data, const std::string &workingDir)
| Loads an object types from a document stored in a string.
const std::vector< Type > & | getTypes () const
| Returns all predefined types and their default values.

## Detailed Description

Parser for Tiled object types export format. Link to the specification: https://doc.mapeditor.org/fr/latest/manual/custom-properties/#predefining-properties.

## Member Function Documentation

## ◆ load()

bool tmx::ObjectTypes::load | ( | const std::string & |  | ) |

Attempts to parse the object types at the given location.

Parameters

  std::string | Path to object types file to try to parse

Returns
  true if object types was parsed successfully else returns false. In debug mode this will attempt to log any errors to the console.

## ◆ loadFromString()

bool tmx::ObjectTypes::loadFromString | ( | const std::string & | data,
|  | const std::string & | workingDir )

Loads an object types from a document stored in a string.

Parameters

  data | A std::string containing the object types to load
  workingDir | A std::string containing the working directory in which to find files.

Returns
  true if successful, else false

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

- D:/W/B/src/tmxlite-1.4.5/tmxlite/include/tmxlite/ObjectTypes.hpp