about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/game/editor/editor.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/game/editor/editor.cpp b/src/game/editor/editor.cpp
index fe6e963c..75f9476c 100644
--- a/src/game/editor/editor.cpp
+++ b/src/game/editor/editor.cpp
@@ -3798,6 +3798,14 @@ void CEditorMap::DeleteEnvelope(int Index)
 						Layer->m_lQuads[k].m_ColorEnv--;
 				}
 			}
+			else if(m_lGroups[i]->m_lLayers[j]->m_Type == LAYERTYPE_TILES)
+			{
+				CLayerTiles *Layer = static_cast<CLayerTiles *>(m_lGroups[i]->m_lLayers[j]);
+				if(Layer->m_ColorEnv == Index)
+					Layer->m_ColorEnv = -1;
+				if(Layer->m_ColorEnv > Index)
+					Layer->m_ColorEnv--;
+			}
 
 	m_lEnvelopes.remove_index(Index);
 }