26 lines
720 B
C#
26 lines
720 B
C#
using PkmnLibSharp.FFI;
|
|
using PkmnLibSharp.Utils;
|
|
using Interface = PkmnLibSharp.FFI.DynamicData.Libraries.DamageLibrary;
|
|
|
|
namespace PkmnLibSharp.DynamicData.Libraries
|
|
{
|
|
public abstract class DamageLibrary : HandleType
|
|
{
|
|
protected DamageLibrary(FFIHandle ptr) : base(ptr)
|
|
{
|
|
}
|
|
}
|
|
|
|
public class Gen7DamageLibrary : DamageLibrary
|
|
{
|
|
public Gen7DamageLibrary(FFIHandle ptr) : base(ptr)
|
|
{
|
|
}
|
|
|
|
public static Gen7DamageLibrary Create(bool hasRandomness)
|
|
{
|
|
var handle = Interface.gen_7_damage_library_new((byte)(hasRandomness ? 1 : 0));
|
|
return Resolver.Instance.ResolveGen7DamageLibrary(handle.Resolve());
|
|
}
|
|
}
|
|
} |