Skip to content
This repository was archived by the owner on Jan 18, 2022. It is now read-only.

Commit 2de0d3d

Browse files
authored
UTY-1627: Fix Codegen Nullref (#695)
1 parent 6f4cc83 commit 2de0d3d

File tree

2 files changed

+1
-17
lines changed

2 files changed

+1
-17
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@
2828
- Code generation now captures nested package dependencies, so the generated schema contains schema components from all required packages. Previously, code generation only generated schema for top-level dependencies, skipping nested packages.
2929
- Fixed a bug where spaces in the path would cause code generation to fail on OSX.
3030
- Fixed an issue in the TransformSynchronization module where an integer underflow would cause a memory crash.
31+
- Fixed a bug where using `Coordinates`, `Vector3f`, or `Vector3d` in a command definition would cause the Code Generator to crash.
3132

3233
### Removed
3334

workers/unity/Packages/com.improbable.gdk.tools/.CodeGenerator/GdkCodeGenerator/src/Generation/Model/UnitySchemaFile.cs

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -152,12 +152,6 @@ internal UnityEventDefinition(ComponentDefinitionRaw.EventDefinitionRaw rawEvent
152152
{
153153
Name = rawEventDefinition.name;
154154
RawType = rawEventDefinition.type;
155-
156-
if (RawType.IsBuiltInType)
157-
{
158-
Type = new UnityTypeReference(RawType.TypeName, null, null);
159-
}
160-
161155
EventIndex = rawEventDefinition.eventIndex;
162156
}
163157
}
@@ -179,17 +173,6 @@ internal UnityCommandDefinition(ComponentDefinitionRaw.CommandDefinitionRaw rawC
179173
Name = rawCommandDefinition.name;
180174
RawRequestType = rawCommandDefinition.requestType;
181175
RawResponseType = rawCommandDefinition.responseType;
182-
183-
if (RawRequestType != null && RawRequestType.IsBuiltInType)
184-
{
185-
RequestType = new UnityTypeReference(RawRequestType.TypeName, null, null);
186-
}
187-
188-
if (RawResponseType != null && RawResponseType.IsBuiltInType)
189-
{
190-
ResponseType = new UnityTypeReference(RawResponseType.TypeName, null, null);
191-
}
192-
193176
CommandIndex = rawCommandDefinition.commandIndex;
194177
}
195178
}

0 commit comments

Comments
 (0)