fix cnc palette issues

cursor not supporting transparency; wrong icon, fx palette
This commit is contained in:
Matthias Mailänder
2012-06-18 17:40:22 +02:00
parent ce0099f5d2
commit 7cbed30dc6
2 changed files with 8 additions and 3 deletions

View File

@@ -25,9 +25,14 @@ namespace OpenRA.Graphics
{
cursors = new Dictionary<string, CursorSequence>();
var sequences = new MiniYaml(null, sequenceFiles.Select(s => MiniYaml.FromFile(s)).Aggregate(MiniYaml.MergeLiberal));
var transparent = false;
var currentMod = Mod.AllMods[Game.modData.Manifest.Mods[0]];
if (currentMod.Id == "d2k")
transparent = true;
foreach (var s in sequences.NodesDict["Palettes"].Nodes)
Game.modData.Palette.AddPalette(s.Key, new Palette(FileSystem.Open(s.Value.Value), true));
Game.modData.Palette.AddPalette(s.Key, new Palette(FileSystem.Open(s.Value.Value), transparent));
foreach (var s in sequences.NodesDict["Cursors"].Nodes)
LoadSequencesForCursor(s.Key, s.Value);

View File

@@ -74,10 +74,10 @@ World:
Name: staticterrain
PaletteFromFile@chrome:
Name: chrome
Filename: temperat.pal
Filename: cursor.pal
PaletteFromFile@effect:
Name: effect
Filename: temperat.pal
Filename: cursor.pal
PaletteFromRGBA@shadow:
Name: shadow
R: 0