26 lines
816 B
C#
26 lines
816 B
C#
using System;
|
|
using PkmnLibSharp.FFI;
|
|
using PkmnLibSharp.Utils;
|
|
using Interface = PkmnLibSharp.FFI.DynamicData.Libraries.ScriptResolver;
|
|
|
|
namespace PkmnLibSharp.DynamicData.Libraries
|
|
{
|
|
public abstract class ScriptResolver : HandleType
|
|
{
|
|
protected ScriptResolver(FFIHandle handle) : base(handle){}
|
|
}
|
|
|
|
/// <summary>
|
|
/// An implementation of a script resolver that pretends there are no existing scripts.
|
|
/// </summary>
|
|
public class EmptyScriptResolver : ScriptResolver
|
|
{
|
|
protected EmptyScriptResolver(FFIHandle handle) : base(handle){}
|
|
|
|
public static EmptyScriptResolver Create()
|
|
{
|
|
var handle = Interface.empty_script_resolver_new();
|
|
return Resolver.Instance.ResolveEmptyScriptResolver(handle.Resolve());
|
|
}
|
|
}
|
|
} |