Add path auto-tiling tool to map editor
Exposes the TilingPath code used by the map generator as a map editor tool to help automate the process of tiling sequences of templates together. No additional template stitching definitions are added as part of this commit. As such, the tool currently only supports the same auto tiling as the map generator does. This includes: - RA and CnC support. - Beaches, land cliffs, and roads. Support for additional mods and templates can be added in follow-ups by adding the necessary MultiBrush definitions. Related changes included in this commit to support this work include: - Add support for sparse EditorBlits. - Add support for MultiBrush to EditorBlitSource conversion. - Add support for EditorBlitSource previewing. - Adjust the "Road" types used in segmented MultiBrush definitions.
This commit is contained in:
committed by
Gustas Kažukauskas
parent
d3d949176d
commit
ad08045e5f
@@ -137,7 +137,17 @@ namespace OpenRA.Mods.Common.Traits
|
||||
|
||||
public IEnumerable<IRenderable> Render()
|
||||
{
|
||||
var items = previews.SelectMany(p => p.Render(worldRenderer, CenterPosition));
|
||||
return RenderAt(CenterPosition);
|
||||
}
|
||||
|
||||
public IEnumerable<IRenderable> RenderWithOffset(WVec offset)
|
||||
{
|
||||
return RenderAt(CenterPosition + offset);
|
||||
}
|
||||
|
||||
public IEnumerable<IRenderable> RenderAt(WPos centerPosition)
|
||||
{
|
||||
var items = previews.SelectMany(p => p.Render(worldRenderer, centerPosition));
|
||||
if (Selected)
|
||||
{
|
||||
var overlay = items.Where(r => !r.IsDecoration && r is IModifyableRenderable)
|
||||
|
||||
Reference in New Issue
Block a user