用户工具

站点工具


侧边栏



Unity3D中文文档

script:unityengine:enumerations:runtimeplatform:runtimeplatform

RuntimePlatform 运行平台

Description 描述

The platform application is running. Returned by Application.platform.

Note: The difference between using RuntimePlatform and Platform dependent Compilation is that using RuntimePlatform is evaluated at runtime while Platform dependent Compilation is evaluated at compile time. So if you can use platform dependent compilation, don't hesitate to use it. In most cases, you can get the same functionality using both, and using the defines will produce smaller and faster code, as you don't need to check at runtime. There are some cases where RuntimePlatform is needed at runtime.

应用程序运行的平台,由Application.platform返回。

注意:使用RuntimePlatform和Platform两者是不同的,取决于编译是使用RuntimePlatform在运行时判断的,还是Platform取决于编译在编译时判断的。因此如果可以使用platform取决于编译,不要犹豫使用它。大多数情况下,可以使用这两种获得相同的功能,使用定义将产生更小和更快代码,因为你不需要在运行时检查。有些情况下必须使用RuntimePlatform,例如,如果需要检查那个平台运行webplayer,这个可以在运行时检查 。

Variables 变量

OSXEditorIn the Unity editor on Mac OS X.
在Mac OS X下运行Unity编辑器。
OSXPlayerIn the player on Mac OS X.
在Mac OS X 播放器上。
WindowsPlayerIn the player on Windows.
在Windows的播放器上。
OSXDashboardPlayerIn the Dashboard widget on Mac OS X.
在Mac OS X仪表盘部件。
WindowsEditorIn the Unity editor on Windows.
在Windows下运行Unity编辑器。
IPhonePlayerIn the player on the iPhone.
在iPhone播放器。
XBOX360In the player on the XBOX360.
在XBOX360播放器。
PS3In the player on the Play Station 3.
在PS3播放器。
AndroidIn the player on Android devices.
在Android系统播放器。
LinuxPlayerIn the player on Linux.
在Linux系统播放器。
WebGLPlayerIn the player on WebGL?
在WebGL软件播放器。
WSAPlayerX86In the player on Windows Store Apps when CPU architecture is X86.
CPU框架是X86在Windows商店软件播放器。
WSAPlayerX64In the player on Windows Store Apps when CPU architecture is X64.
CPU框架是X64在Windows商店软件播放器。
WSAPlayerARMIn the player on Windows Store Apps when CPU architecture is ARM.
CPU框架是ARM在Windows商店软件播放器。
WP8PlayerIn the player on Windows Phone 8 device.
在WindowsPhone8系统播放器。
TizenPlayerIn the player on Tizen.
在泰泽系统播放器。
PSP2In the player on the PS Vita.
在PS Vita播放器。
script/unityengine/enumerations/runtimeplatform/runtimeplatform.txt · 最后更改: 2016/10/08 09:24 由 emjo