TMX: Added support for reading the object.rotation attribute (#11540)

Introduced with Tiled 0.10, this attribute stores the rotation of an
object in degrees clockwise.

Closes bjorn/tiled#921
This commit is contained in:
Thorbjørn Lindeijer 2017-09-20 08:31:15 +02:00 committed by minggo
parent a5374d0411
commit 7350aeca8c
1 changed files with 2 additions and 0 deletions

View File

@ -518,6 +518,8 @@ void TMXMapInfo::startElement(void* /*ctx*/, const char *name, const char **atts
dict["width"] = Value(s.width);
dict["height"] = Value(s.height);
dict["rotation"] = attributeDict["rotation"].asDouble();
// Add the object to the objectGroup
objectGroup->getObjects().push_back(Value(dict));