Don't export cel opacity when it's 255 (#4511 / #4552)

In this way we don't modify the current exported JSONs by users that
are not using cel opacity (which might be the most common case).
This commit is contained in:
David Capello 2024-08-08 19:01:43 -03:00
parent a11946ab0e
commit 4e5dfa9d2c

View File

@ -1570,7 +1570,9 @@ void DocExporter::createDataFile(const Samples& samples,
os << ", ";
os << "{ \"frame\": " << cel->frame();
os << ", \"opacity\": " << cel->opacity();
if (cel->opacity() != 255) {
os << ", \"opacity\": " << cel->opacity();
}
if (cel->zIndex() != 0) {
os << ", \"zIndex\": " << cel->zIndex();
}