Merge pull request #7593 from Phrohdoh/wiki-trait-links

Wiki trait links.
This commit is contained in:
Oliver Brakmann
2015-03-10 18:40:53 +01:00

View File

@@ -53,7 +53,7 @@ namespace OpenRA.Mods.Common.UtilityCommands
if (reqCount > 0) if (reqCount > 0)
{ {
if (t.HasAttribute<DescAttribute>()) if (t.HasAttribute<DescAttribute>())
doc.AppendLine("\n"); doc.AppendLine();
doc.Append("Requires trait{0}: ".F(reqCount > 1 ? "s" : "")); doc.Append("Requires trait{0}: ".F(reqCount > 1 ? "s" : ""));
@@ -62,7 +62,7 @@ namespace OpenRA.Mods.Common.UtilityCommands
{ {
var n = require.Name; var n = require.Name;
var name = n.EndsWith("Info") ? n.Remove(n.Length - 4, 4) : n; var name = n.EndsWith("Info") ? n.Remove(n.Length - 4, 4) : n;
doc.Append("`{0}`{1}".F(name, i + 1 == reqCount ? ".\n" : ", ")); doc.Append("[`{0}`](#{1}){2}".F(name, name.ToLowerInvariant(), i + 1 == reqCount ? ".\n" : ", "));
i++; i++;
} }
} }