Skip to content

Commit

Permalink
JSON plugin: Fixed reading of custom properties on tile collision obj…
Browse files Browse the repository at this point in the history
  • Loading branch information
bjorn committed Aug 28, 2017
1 parent 1f39a64 commit 92708e5
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/libtiled/varianttomapconverter.cpp
Expand Up @@ -287,8 +287,12 @@ SharedTileset VariantToMapConverter::toTileset(const QVariant &variant)
}

QVariantMap objectGroupVariant = tileVar[QLatin1String("objectgroup")].toMap();
if (!objectGroupVariant.isEmpty())
tile->setObjectGroup(toObjectGroup(objectGroupVariant));
if (!objectGroupVariant.isEmpty()) {
ObjectGroup *objectGroup = toObjectGroup(objectGroupVariant);
if (objectGroup)
objectGroup->setProperties(extractProperties(objectGroupVariant));
tile->setObjectGroup(objectGroup);
}

QVariantList frameList = tileVar[QLatin1String("animation")].toList();
if (!frameList.isEmpty()) {
Expand Down

0 comments on commit 92708e5

Please sign in to comment.