Document all undocumented methods and properties
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -9,8 +9,14 @@ using PkmnLib.Static.Utils;
|
||||
|
||||
namespace PkmnLib.Dynamic.Libraries.DataLoaders;
|
||||
|
||||
/// <summary>
|
||||
/// Loads move data from a JSON file.
|
||||
/// </summary>
|
||||
public static class MoveDataLoader
|
||||
{
|
||||
/// <summary>
|
||||
/// Loads move data from a stream.
|
||||
/// </summary>
|
||||
public static MoveLibrary LoadMoves(Stream stream, TypeLibrary typeLibrary,
|
||||
Action<SerializedMoveDataWrapper>? onAfterLoad = null)
|
||||
{
|
||||
@@ -25,14 +31,20 @@ public static class MoveDataLoader
|
||||
return library;
|
||||
}
|
||||
|
||||
[PublicAPI]
|
||||
public static
|
||||
Func<SerializedMove, StringKey, TypeIdentifier, MoveCategory, byte, byte, byte, MoveTarget, sbyte,
|
||||
ISecondaryEffect?
|
||||
, IEnumerable<StringKey>, MoveDataImpl> MoveConstructor =
|
||||
(_, name, moveType, category, basePower, accuracy, baseUsages, target, priority, secondaryEffect, flags) =>
|
||||
new MoveDataImpl(name, moveType, category, basePower, accuracy, baseUsages, target, priority,
|
||||
secondaryEffect, flags);
|
||||
/// <summary>
|
||||
/// Factory delegate for creating moves.
|
||||
/// </summary>
|
||||
public delegate MoveDataImpl MoveFactoryDelegate(SerializedMove serialized, StringKey name, TypeIdentifier type,
|
||||
MoveCategory category, byte basePower, byte accuracy, byte pp, MoveTarget target, sbyte priority,
|
||||
ISecondaryEffect? secondaryEffect, IEnumerable<StringKey> flags);
|
||||
|
||||
/// <summary>
|
||||
/// The move constructor. This is used to create moves from the JSON data.
|
||||
/// </summary>
|
||||
[PublicAPI] public static MoveFactoryDelegate MoveConstructor =
|
||||
(_, name, moveType, category, basePower, accuracy, baseUsages, target, priority, secondaryEffect, flags) =>
|
||||
new MoveDataImpl(name, moveType, category, basePower, accuracy, baseUsages, target, priority,
|
||||
secondaryEffect, flags);
|
||||
|
||||
private static MoveDataImpl DeserializeMove(SerializedMove serialized, TypeLibrary typeLibrary)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user