Platform Dependent Compilation

1、Platform Defines

  Platform Dependent Compilation

2、在Project Setting -> Player 面板的Other Settings的Scripting Define Symbols可以自定义macro,在此片定义的macro会被所有代码引用。

  Platform Dependent Compilation

  以分号分隔。

3、You can define your own preprocessor directives to control which code gets included when compiling. To do this you must add a text file with the extra directives to the "Assets/" folder. The name of the file depends on the language you are using, and the extension is .rsp:

  Platform Dependent Compilation

  Platform Dependent CompilationAs an example, if you include the single line "-define:UNITY_DEBUG" in your smcs.rsp file the define UNITY_DEBUG will exist as a global define for C# scripts, except for Editor scripts.

  smcs.exe路径:...\Unity\Editor\Data\Mono\lib\mono\unity

参考:

1、file:///D:/Program%20Files%20(x86)/Unity/Editor/Data/Documentation/Documentation/Manual/PlatformDependentCompilation.html

2、http://answers.unity3d.com/questions/351440/smcsexe-consistently-crashes.html

3、file:///D:/Program%20Files%20(x86)/Unity/Editor/Data/Documentation/Documentation/Components/class-PlayerSettings40.html

相关文章:

  • 2021-10-19
  • 2022-12-23
  • 2021-05-12
  • 2022-12-23
  • 2021-05-29
  • 2021-05-18
  • 2021-04-04
  • 2022-02-17
猜你喜欢
  • 2021-05-15
  • 2022-02-07
  • 2021-11-12
  • 2022-12-23
  • 2021-11-06
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案