mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Fix consistency issues in converting to metadata
This commit is contained in:
@@ -33,6 +33,7 @@ namespace SabreTools.DatItems.Formats
|
||||
#region Constructors
|
||||
|
||||
public DipValue() : base() { }
|
||||
|
||||
public DipValue(Models.Metadata.DipValue item) : base(item)
|
||||
{
|
||||
// Process flag values
|
||||
@@ -46,5 +47,22 @@ namespace SabreTools.DatItems.Formats
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Cloning Methods
|
||||
|
||||
/// <inheritdoc/>
|
||||
public override Models.Metadata.DipValue GetInternalClone()
|
||||
{
|
||||
var dipValueItem = base.GetInternalClone();
|
||||
|
||||
// Handle subitems
|
||||
var subCondition = GetFieldValue<Condition>(Models.Metadata.DipValue.ConditionKey);
|
||||
if (subCondition != null)
|
||||
dipValueItem[Models.Metadata.DipValue.ConditionKey] = subCondition.GetInternalClone();
|
||||
|
||||
return dipValueItem;
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user