Merge pull request #31191 from aaronfranke/serializable
[Mono] Make all structs seralizable
This commit is contained in:
commit
e37e71d961
|
@ -5,6 +5,7 @@
|
||||||
// file: core/variant_call.cpp
|
// file: core/variant_call.cpp
|
||||||
// commit: 5ad9be4c24e9d7dc5672fdc42cea896622fe5685
|
// commit: 5ad9be4c24e9d7dc5672fdc42cea896622fe5685
|
||||||
using System;
|
using System;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
#if REAL_T_IS_DOUBLE
|
#if REAL_T_IS_DOUBLE
|
||||||
using real_t = System.Double;
|
using real_t = System.Double;
|
||||||
#else
|
#else
|
||||||
|
@ -13,6 +14,8 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct AABB : IEquatable<AABB>
|
public struct AABB : IEquatable<AABB>
|
||||||
{
|
{
|
||||||
private Vector3 _position;
|
private Vector3 _position;
|
||||||
|
|
|
@ -8,6 +8,7 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
[StructLayout(LayoutKind.Sequential)]
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Basis : IEquatable<Basis>
|
public struct Basis : IEquatable<Basis>
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,7 +1,10 @@
|
||||||
using System;
|
using System;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Color : IEquatable<Color>
|
public struct Color : IEquatable<Color>
|
||||||
{
|
{
|
||||||
public float r;
|
public float r;
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
using System;
|
using System;
|
||||||
|
using System.Runtime.InteropServices;
|
||||||
#if REAL_T_IS_DOUBLE
|
#if REAL_T_IS_DOUBLE
|
||||||
using real_t = System.Double;
|
using real_t = System.Double;
|
||||||
#else
|
#else
|
||||||
|
@ -7,6 +8,8 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Plane : IEquatable<Plane>
|
public struct Plane : IEquatable<Plane>
|
||||||
{
|
{
|
||||||
private Vector3 _normal;
|
private Vector3 _normal;
|
||||||
|
|
|
@ -8,6 +8,7 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
[StructLayout(LayoutKind.Sequential)]
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Quat : IEquatable<Quat>
|
public struct Quat : IEquatable<Quat>
|
||||||
{
|
{
|
||||||
|
|
|
@ -8,6 +8,7 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
[StructLayout(LayoutKind.Sequential)]
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Rect2 : IEquatable<Rect2>
|
public struct Rect2 : IEquatable<Rect2>
|
||||||
{
|
{
|
||||||
|
|
|
@ -8,6 +8,7 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
[StructLayout(LayoutKind.Sequential)]
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Transform : IEquatable<Transform>
|
public struct Transform : IEquatable<Transform>
|
||||||
{
|
{
|
||||||
|
|
|
@ -8,6 +8,7 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
[StructLayout(LayoutKind.Sequential)]
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Transform2D : IEquatable<Transform2D>
|
public struct Transform2D : IEquatable<Transform2D>
|
||||||
{
|
{
|
||||||
|
|
|
@ -14,6 +14,7 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
[StructLayout(LayoutKind.Sequential)]
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Vector2 : IEquatable<Vector2>
|
public struct Vector2 : IEquatable<Vector2>
|
||||||
{
|
{
|
||||||
|
|
|
@ -14,6 +14,7 @@ using real_t = System.Single;
|
||||||
|
|
||||||
namespace Godot
|
namespace Godot
|
||||||
{
|
{
|
||||||
|
[Serializable]
|
||||||
[StructLayout(LayoutKind.Sequential)]
|
[StructLayout(LayoutKind.Sequential)]
|
||||||
public struct Vector3 : IEquatable<Vector3>
|
public struct Vector3 : IEquatable<Vector3>
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue