about summary refs log tree commit diff
path: root/src/game/editor/io.cpp
diff options
context:
space:
mode:
authorChoupom <andycootlapin@hotmail.fr>2011-07-18 12:05:12 +0200
committeroy <Tom_Adams@web.de>2011-07-20 22:04:13 +0200
commit84e5c534322940a696d9a915829a5e69e5679a28 (patch)
tree6cfd6f5d8d836f7bf192d186f1fb63a438b1ba7b /src/game/editor/io.cpp
parentc2e8bf5035cbe3f41a71c454e348fc408f17a991 (diff)
downloadzcatch-84e5c534322940a696d9a915829a5e69e5679a28.tar.gz
zcatch-84e5c534322940a696d9a915829a5e69e5679a28.zip
added color envelope feature for tilemaps
Diffstat (limited to 'src/game/editor/io.cpp')
-rw-r--r--src/game/editor/io.cpp16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/game/editor/io.cpp b/src/game/editor/io.cpp
index 768f0fa5..68330f03 100644
--- a/src/game/editor/io.cpp
+++ b/src/game/editor/io.cpp
@@ -286,12 +286,9 @@ int CEditorMap::Save(class IStorage *pStorage, const char *pFileName)
 				Item.m_Layer.m_Flags = pLayer->m_Flags;
 				Item.m_Layer.m_Type = pLayer->m_Type;
 
-				Item.m_Color.r = pLayer->m_Color.r;
-				Item.m_Color.g = pLayer->m_Color.g;
-				Item.m_Color.b = pLayer->m_Color.b;
-				Item.m_Color.a = pLayer->m_Color.a;
-				Item.m_ColorEnv = -1; // not in use right now
-				Item.m_ColorEnvOffset = 0;
+				Item.m_Color = pLayer->m_Color;
+				Item.m_ColorEnv = pLayer->m_ColorEnv;
+				Item.m_ColorEnvOffset = pLayer->m_ColorEnvOffset;
 
 				Item.m_Width = pLayer->m_Width;
 				Item.m_Height = pLayer->m_Height;
@@ -526,10 +523,9 @@ int CEditorMap::Load(class IStorage *pStorage, const char *pFileName, int Storag
 						{
 							pTiles = new CLayerTiles(pTilemapItem->m_Width, pTilemapItem->m_Height);
 							pTiles->m_pEditor = m_pEditor;
-							pTiles->m_Color.r = pTilemapItem->m_Color.r;
-							pTiles->m_Color.g = pTilemapItem->m_Color.g;
-							pTiles->m_Color.b = pTilemapItem->m_Color.b;
-							pTiles->m_Color.a = pTilemapItem->m_Color.a;
+							pTiles->m_Color = pTilemapItem->m_Color;
+							pTiles->m_ColorEnv = pTilemapItem->m_ColorEnv;
+							pTiles->m_ColorEnvOffset = pTilemapItem->m_ColorEnvOffset;
 						}
 
 						pLayer = pTiles;