Skip to content

Commit ada1615

Browse files
committed
Unity code stripping: add [Preserve] tag to avoid stripping 'ReflectionType'
1 parent 0839074 commit ada1615

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

Assets/Colyseus/Runtime/Colyseus/Serializer/Schema/Types/Reflection.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,12 @@ public class ReflectionType : Schema
4545
/// <summary>
4646
/// An <see cref="ArraySchema{T}" /> of <see cref="ReflectionField" />
4747
/// </summary>
48+
[Preserve]
4849
[Type(2, "array", typeof(ArraySchema<ReflectionField>))]
4950
public ArraySchema<ReflectionField> fields;
51+
52+
[Preserve]
53+
public ReflectionType() {}
5054
}
5155

5256
/// <summary>
@@ -58,6 +62,7 @@ public class Reflection : Schema
5862
/// <summary>
5963
/// An <see cref="ArraySchema{T}" /> of <see cref="ReflectionType" />
6064
/// </summary>
65+
[Preserve]
6166
[Type(0, "array", typeof(ArraySchema<ReflectionType>))]
6267
public ArraySchema<ReflectionType> types;
6368

Assets/Colyseus/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "io.colyseus.sdk",
3-
"version": "0.16.9",
3+
"version": "0.16.10",
44
"displayName": "Colyseus SDK",
55
"description": "Colyseus Multiplayer SDK for Unity",
66
"unity": "2019.1",

0 commit comments

Comments
 (0)