mirror of
https://github.com/xivdev/Penumbra.git
synced 2025-12-31 12:53:47 +01:00
Added a whole lot of rudimentary comments, also importing selects the last imported mod if possible.
This commit is contained in:
parent
a19ec226c5
commit
d29049ca21
24 changed files with 83 additions and 23 deletions
|
|
@ -4,6 +4,8 @@ using Penumbra.Util;
|
|||
|
||||
namespace Penumbra.Mod
|
||||
{
|
||||
// A complete Mod containing settings (i.e. dependent on a collection)
|
||||
// and the resulting cache.
|
||||
public class Mod
|
||||
{
|
||||
public ModSettings Settings { get; }
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ using Penumbra.Util;
|
|||
|
||||
namespace Penumbra.Mod
|
||||
{
|
||||
// The ModCache contains volatile information dependent on all current settings in a collection.
|
||||
public class ModCache
|
||||
{
|
||||
public Dictionary< Mod, (List< GamePath > Files, List< MetaManipulation > Manipulations) > Conflicts { get; private set; } = new();
|
||||
|
|
|
|||
|
|
@ -3,6 +3,9 @@ using Dalamud.Plugin;
|
|||
|
||||
namespace Penumbra.Mod
|
||||
{
|
||||
// ModData contains all permanent information about a mod,
|
||||
// and is independent of collections or settings.
|
||||
// It only changes when the user actively changes the mod or their filesystem.
|
||||
public class ModData
|
||||
{
|
||||
public DirectoryInfo BasePath;
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ using Penumbra.Util;
|
|||
|
||||
namespace Penumbra.Mod
|
||||
{
|
||||
// Functions that do not really depend on only one component of a mod.
|
||||
public static class ModFunctions
|
||||
{
|
||||
public static bool CleanUpCollection( Dictionary< string, ModSettings > settings, IEnumerable< DirectoryInfo > modPaths )
|
||||
|
|
|
|||
|
|
@ -58,7 +58,6 @@ namespace Penumbra.Mod
|
|||
return true;
|
||||
}
|
||||
|
||||
|
||||
public static ModMeta? LoadFromFile( FileInfo filePath )
|
||||
{
|
||||
try
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ using Penumbra.Structs;
|
|||
|
||||
namespace Penumbra.Mod
|
||||
{
|
||||
// Contains the settings for a given mod.
|
||||
public class ModSettings
|
||||
{
|
||||
public bool Enabled { get; set; }
|
||||
|
|
|
|||
|
|
@ -4,6 +4,9 @@ using Penumbra.Structs;
|
|||
|
||||
namespace Penumbra.Mod
|
||||
{
|
||||
// Contains settings with the option selections stored by names instead of index.
|
||||
// This is meant to make them possibly more portable when we support importing collections from other users.
|
||||
// Enabled does not exist, because disabled mods would not be exported in this way.
|
||||
public class NamedModSettings
|
||||
{
|
||||
public int Priority { get; set; }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue