mirror of
https://github.com/xivdev/Penumbra.git
synced 2026-01-01 05:13:43 +01:00
Rework ResolveData.
This commit is contained in:
parent
75182d094b
commit
d12a3dd152
14 changed files with 199 additions and 170 deletions
|
|
@ -114,18 +114,18 @@ public unsafe partial class ResourceLoader
|
|||
|
||||
|
||||
// Use the default method of path replacement.
|
||||
public static (FullPath?, LinkedModCollection?) DefaultResolver( Utf8GamePath path )
|
||||
public static (FullPath?, ResolveData) DefaultResolver( Utf8GamePath path )
|
||||
{
|
||||
var resolved = Penumbra.CollectionManager.Default.ResolvePath( path );
|
||||
return ( resolved, new LinkedModCollection( Penumbra.CollectionManager.Default ) );
|
||||
return ( resolved, Penumbra.CollectionManager.Default.ToResolveData() );
|
||||
}
|
||||
|
||||
// Try all resolve path subscribers or use the default replacer.
|
||||
private (FullPath?, LinkedModCollection?) ResolvePath( Utf8GamePath path, ResourceCategory category, ResourceType resourceType, int resourceHash )
|
||||
private (FullPath?, ResolveData) ResolvePath( Utf8GamePath path, ResourceCategory category, ResourceType resourceType, int resourceHash )
|
||||
{
|
||||
if( !DoReplacements || _incMode.Value )
|
||||
{
|
||||
return ( null, null );
|
||||
return ( null, ResolveData.Invalid );
|
||||
}
|
||||
|
||||
path = path.ToLower();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue