mirror of
https://github.com/AssetRipper/AssetRipper.git
synced 2025-12-11 20:15:29 +01:00
17 lines
405 B
C#
17 lines
405 B
C#
using System.Text.Json;
|
|
|
|
namespace AssetRipper.GUI.Electron;
|
|
|
|
public readonly record struct ResourcePath(BundlePath BundlePath, int Index)
|
|
{
|
|
public string ToJson()
|
|
{
|
|
return JsonSerializer.Serialize(this, PathSerializerContext.Default.ResourcePath);
|
|
}
|
|
|
|
public static ResourcePath FromJson(string json)
|
|
{
|
|
return JsonSerializer.Deserialize(json, PathSerializerContext.Default.ResourcePath);
|
|
}
|
|
}
|