Version: 2018.2
引用其他类库程序集
通用函数

稳定脚本运行时:已知限制

Unity 支持新版的 .NET 运行时。使用 .NET 运行时的时候,可能会遇到以下问题:

代码大小

稳定脚本运行时随附比旧版脚本运行时更大的 .NET 类库 API。这意味着代码大小通常更大。这种大小增加可能很明显,特别是在大小受限和提前 (AOT) 平台上。

要减少代码大小的增加幅度,请执行以下操作:

1.尽可能选择最小的 .NET 配置文件(请参阅 .NET 配置文件支持)。.NET Standard 2.0 配置文件大小大约只有 .NET 4.x 配置文件的一半,因此请尽可能使用 .NET Standard 2.0 配置文件。 1. Enable Strip Engine Code in the Unity Editor Player Settings (go to Edit > Project Settings > Player). This option statically analyzes the managed code in the Project, and removes any unused code. Note: This option is only available with the IL2CPP scripting backend.


引用其他类库程序集
通用函数