forked from Unity-Technologies/EntityComponentSystemSamples
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathUserDefinedTemplates.cs
More file actions
44 lines (42 loc) · 1.57 KB
/
Copy pathUserDefinedTemplates.cs
File metadata and controls
44 lines (42 loc) · 1.57 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
using System.Collections.Generic;
namespace Unity.NetCode.Generators
{
public static partial class UserDefinedTemplates
{
static partial void RegisterTemplates(List<TypeRegistryEntry> templates, string defaultRootPath)
{
templates.AddRange(new[]{
new TypeRegistryEntry
{
Type = "Unity.Mathematics.float3",
SubType = GhostFieldSubType.Translation2D,
Quantized = true,
Smoothing = SmoothingAction.InterpolateAndExtrapolate,
SupportCommand = false,
Composite = false,
#if UNITY_2021_2_OR_NEWER
Template = "Custom.Translation2d",
#else
Template = "Assets/Samples/NetCodeGen/Templates/Translation2d.NetCodeSourceGenerator.additionalfile",
#endif
TemplateOverride = "",
},
new TypeRegistryEntry
{
Type = "Unity.Mathematics.quaternion",
SubType = GhostFieldSubType.Rotation2D,
Quantized = true,
Smoothing = SmoothingAction.InterpolateAndExtrapolate,
SupportCommand = false,
Composite = false,
#if UNITY_2021_2_OR_NEWER
Template = "Custom.Rotation2d",
#else
Template = "Assets/Samples/NetCodeGen/Templates/Rotation2d.NetCodeSourceGenerator.additionalfile",
#endif
TemplateOverride = "",
},
});
}
}
}