diff --git a/OpenRA.Editor/Surface.cs b/OpenRA.Editor/Surface.cs index aad9195081..8176246857 100755 --- a/OpenRA.Editor/Surface.cs +++ b/OpenRA.Editor/Surface.cs @@ -339,8 +339,9 @@ namespace OpenRA.Editor Map.Bounds.Height * TileSet.TileSize * Zoom); foreach (var ar in Map.Actors.Value) - DrawActor(e.Graphics, ar.Value.Location(), ActorTemplates[ar.Value.Type], - GetPaletteForActor(ar.Value)); + if (ActorTemplates.ContainsKey(ar.Value.Type)) + DrawActor(e.Graphics, ar.Value.Location(), ActorTemplates[ar.Value.Type], + GetPaletteForActor(ar.Value)); if (Tool != null) Tool.Preview(this, e.Graphics); diff --git a/OpenRA.Mods.RA/OpenRA.Mods.RA.csproj b/OpenRA.Mods.RA/OpenRA.Mods.RA.csproj index 42ad0bdd2f..65323bb07d 100644 --- a/OpenRA.Mods.RA/OpenRA.Mods.RA.csproj +++ b/OpenRA.Mods.RA/OpenRA.Mods.RA.csproj @@ -1,4 +1,4 @@ - + Debug @@ -60,6 +60,7 @@ + diff --git a/OpenRA.Mods.RA/Render/RenderEditorOnly.cs b/OpenRA.Mods.RA/Render/RenderEditorOnly.cs new file mode 100644 index 0000000000..252335e095 --- /dev/null +++ b/OpenRA.Mods.RA/Render/RenderEditorOnly.cs @@ -0,0 +1,28 @@ +#region Copyright & License Information +/* + * Copyright 2007-2011 The OpenRA Developers (see AUTHORS) + * This file is part of OpenRA, which is free software. It is made + * available to you under the terms of the GNU General Public License + * as published by the Free Software Foundation. For more information, + * see COPYING. + */ +#endregion + +using System.Collections.Generic; +using OpenRA.Traits; + +namespace OpenRA.Mods.RA.Render +{ + class RenderEditorOnlyInfo : RenderSimpleInfo + { + public override object Create(ActorInitializer init) { return new RenderEditorOnly(init.self); } + } + + class RenderEditorOnly : RenderSimple + { + public RenderEditorOnly(Actor self) : base(self, () => 0) { } + + static readonly Renderable[] Nothing = { }; + public override IEnumerable Render(Actor self) { return Nothing; } + } +} diff --git a/mods/cnc/bits/mpspawn.shp b/mods/cnc/bits/mpspawn.shp new file mode 100644 index 0000000000..0550dd88a5 Binary files /dev/null and b/mods/cnc/bits/mpspawn.shp differ diff --git a/mods/cnc/bits/waypoint.shp b/mods/cnc/bits/waypoint.shp new file mode 100644 index 0000000000..b8a3a4cb90 Binary files /dev/null and b/mods/cnc/bits/waypoint.shp differ diff --git a/mods/cnc/rules/system.yaml b/mods/cnc/rules/system.yaml index bc207e43a5..f93683020e 100644 --- a/mods/cnc/rules/system.yaml +++ b/mods/cnc/rules/system.yaml @@ -196,6 +196,8 @@ CRATE: mpspawn: Waypoint: + RenderEditorOnly: waypoint: - Waypoint: \ No newline at end of file + Waypoint: + RenderEditorOnly: \ No newline at end of file diff --git a/mods/cnc/sequences/misc.yaml b/mods/cnc/sequences/misc.yaml index 657fb8ad46..81516f9927 100644 --- a/mods/cnc/sequences/misc.yaml +++ b/mods/cnc/sequences/misc.yaml @@ -207,3 +207,12 @@ bomblet: Start: 0 Length: * +mpspawn: + idle: + Start: 0 + Length: * + +waypoint: + idle: + Start: 0 + Length: * \ No newline at end of file diff --git a/mods/ra/bits/mpspawn.shp b/mods/ra/bits/mpspawn.shp new file mode 100644 index 0000000000..0550dd88a5 Binary files /dev/null and b/mods/ra/bits/mpspawn.shp differ diff --git a/mods/ra/bits/waypoint.shp b/mods/ra/bits/waypoint.shp new file mode 100644 index 0000000000..b8a3a4cb90 Binary files /dev/null and b/mods/ra/bits/waypoint.shp differ diff --git a/mods/ra/rules/system.yaml b/mods/ra/rules/system.yaml index 24ae511abe..4122af73d1 100644 --- a/mods/ra/rules/system.yaml +++ b/mods/ra/rules/system.yaml @@ -332,6 +332,8 @@ powerproxy.sonarpulse: mpspawn: Waypoint: + RenderEditorOnly: waypoint: - Waypoint: \ No newline at end of file + Waypoint: + RenderEditorOnly: \ No newline at end of file diff --git a/mods/ra/sequences.yaml b/mods/ra/sequences.yaml index d57af36523..760d3f808a 100644 --- a/mods/ra/sequences.yaml +++ b/mods/ra/sequences.yaml @@ -1822,4 +1822,14 @@ bubbles: idle: Start: 0 Length: * - Tick: 220 \ No newline at end of file + Tick: 220 + +mpspawn: + idle: + Start: 0 + Length: * + +waypoint: + idle: + Start: 0 + Length: * \ No newline at end of file