mirror of
https://github.com/SoDOff-Project/sodoff.git
synced 2025-10-11 16:28:50 -07:00

.net 8 deprecated BinaryFormatter serialization apart from that proper deep copies are ~10x faster
29 lines
713 B
C#
29 lines
713 B
C#
using System.Xml.Serialization;
|
|
|
|
namespace sodoff.Schema;
|
|
|
|
[XmlRoot(ElementName = "IT", Namespace = "")]
|
|
[Serializable]
|
|
public class ItemDataTexture {
|
|
public ItemDataTexture() {}
|
|
|
|
public ItemDataTexture(ItemDataTexture other) {
|
|
TextureName = other.TextureName;
|
|
TextureTypeName = other.TextureTypeName;
|
|
OffsetX = other.OffsetX;
|
|
OffsetY = other.OffsetY;
|
|
}
|
|
|
|
[XmlElement(ElementName = "n")]
|
|
public string TextureName;
|
|
|
|
[XmlElement(ElementName = "t")]
|
|
public string TextureTypeName;
|
|
|
|
[XmlElement(ElementName = "x", IsNullable = true)]
|
|
public float? OffsetX;
|
|
|
|
[XmlElement(ElementName = "y", IsNullable = true)]
|
|
public float? OffsetY;
|
|
}
|