diff --git a/src/Client/LevelRenderer/ObjectAppearance.cpp b/src/Client/LevelRenderer/ObjectAppearance.cpp index b529cbf..e2ba787 100644 --- a/src/Client/LevelRenderer/ObjectAppearance.cpp +++ b/src/Client/LevelRenderer/ObjectAppearance.cpp @@ -385,6 +385,10 @@ std::vector ObjectAppearanceManager::getObjectVertices(const Object& return vertices; } + // The in-game editor gives some objects a subtype of -1 to indicate that the property is unused. + // This workaround allows traps to remain visible in NecroEdit even after saving dungeons with them in-game. + variant = std::max(0, variant); + try { spriteData.nodeID = it->second.nodeIDs.at(variant);