mirror of
https://github.com/space-wizards/RobustToolbox.git
synced 2026-02-15 03:30:53 +01:00
39 lines
1.2 KiB
C#
39 lines
1.2 KiB
C#
using Robust.Packaging.AssetProcessing;
|
|
|
|
namespace Robust.Packaging;
|
|
|
|
public sealed class RobustClientPackaging
|
|
{
|
|
public static IReadOnlySet<string> ClientIgnoredResources { get; } = new HashSet<string>
|
|
{
|
|
"Maps",
|
|
"ConfigPresets",
|
|
// Leaving this here for future archaeologists to ponder at.
|
|
"emotes.xml",
|
|
"Groups",
|
|
"engineCommandPerms.yml"
|
|
};
|
|
|
|
public static async Task WriteClientResources(
|
|
string contentDir,
|
|
AssetPass pass,
|
|
CancellationToken cancel = default)
|
|
{
|
|
await WriteClientResources(contentDir, pass, new HashSet<string>(), cancel);
|
|
}
|
|
|
|
public static async Task WriteClientResources(
|
|
string contentDir,
|
|
AssetPass pass,
|
|
IReadOnlySet<string> additionalIgnoredResources,
|
|
CancellationToken cancel = default)
|
|
{
|
|
var ignoreSet = ClientIgnoredResources
|
|
.Union(RobustSharedPackaging.SharedIgnoredResources)
|
|
.Union(additionalIgnoredResources)
|
|
.ToHashSet();
|
|
|
|
await RobustSharedPackaging.DoResourceCopy(Path.Combine(contentDir, "Resources"), pass, ignoreSet, cancel: cancel);
|
|
}
|
|
}
|