From a13f10139d33264fc9ebc5a15c75faf16fc7757e Mon Sep 17 00:00:00 2001 From: chai Date: Wed, 7 Jul 2021 18:47:37 +0800 Subject: +Action Tool --- .../Odin Inspector/Scripts/VectorIntFormatters.cs | 80 ---------------------- 1 file changed, 80 deletions(-) delete mode 100644 Assets/Plugins/Sirenix/Odin Inspector/Scripts/VectorIntFormatters.cs (limited to 'Assets/Plugins/Sirenix/Odin Inspector/Scripts/VectorIntFormatters.cs') diff --git a/Assets/Plugins/Sirenix/Odin Inspector/Scripts/VectorIntFormatters.cs b/Assets/Plugins/Sirenix/Odin Inspector/Scripts/VectorIntFormatters.cs deleted file mode 100644 index ccb62ce0..00000000 --- a/Assets/Plugins/Sirenix/Odin Inspector/Scripts/VectorIntFormatters.cs +++ /dev/null @@ -1,80 +0,0 @@ -#if UNITY_2017_2_OR_NEWER - -//----------------------------------------------------------------------- -// -// Copyright (c) Sirenix IVS. All rights reserved. -// -//----------------------------------------------------------------------- - -[assembly: Sirenix.Serialization.RegisterFormatter(typeof(Sirenix.Serialization.Vector2IntFormatter))] -[assembly: Sirenix.Serialization.RegisterFormatter(typeof(Sirenix.Serialization.Vector3IntFormatter))] -namespace Sirenix.Serialization -{ - using UnityEngine; - - /// - /// Custom formatter for the type. - /// - /// - public class Vector2IntFormatter : MinimalBaseFormatter - { - private static readonly Serializer Serializer = Serialization.Serializer.Get(); - - /// - /// Reads into the specified value using the specified reader. - /// - /// The value to read into. - /// The reader to use. - protected override void Read(ref Vector2Int value, IDataReader reader) - { - value.x = Vector2IntFormatter.Serializer.ReadValue(reader); - value.y = Vector2IntFormatter.Serializer.ReadValue(reader); - } - - /// - /// Writes from the specified value using the specified writer. - /// - /// The value to write from. - /// The writer to use. - protected override void Write(ref Vector2Int value, IDataWriter writer) - { - Vector2IntFormatter.Serializer.WriteValue(value.x, writer); - Vector2IntFormatter.Serializer.WriteValue(value.y, writer); - } - } - - /// - /// Custom formatter for the type. - /// - /// - public class Vector3IntFormatter : MinimalBaseFormatter - { - private static readonly Serializer Serializer = Serialization.Serializer.Get(); - - /// - /// Reads into the specified value using the specified reader. - /// - /// The value to read into. - /// The reader to use. - protected override void Read(ref Vector3Int value, IDataReader reader) - { - value.x = Vector3IntFormatter.Serializer.ReadValue(reader); - value.y = Vector3IntFormatter.Serializer.ReadValue(reader); - value.z = Vector3IntFormatter.Serializer.ReadValue(reader); - } - - /// - /// Writes from the specified value using the specified writer. - /// - /// The value to write from. - /// The writer to use. - protected override void Write(ref Vector3Int value, IDataWriter writer) - { - Vector3IntFormatter.Serializer.WriteValue(value.x, writer); - Vector3IntFormatter.Serializer.WriteValue(value.y, writer); - Vector3IntFormatter.Serializer.WriteValue(value.z, writer); - } - } -} - -#endif \ No newline at end of file -- cgit v1.1-26-g67d0