Legacy Documentation: Version 4.5.0

Script language:

  • JS
  • C#
  • Boo
Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

PlayerSettings

Namespace: UnityEditor

/

Inherits from: Object

Description

Player Settings is where you define various parameters for the final game that you will build in Unity. Some of these values are used in the Resolution Dialog that launches when you open a standalone game.

Static Variables

accelerometerFrequencyAccelerometer update frequency.
advancedLicenseIs the advanced version being used?
allowedAutorotateToLandscapeLeftIs auto-rotation to landscape left supported?
allowedAutorotateToLandscapeRightIs auto-rotation to landscape right supported?
allowedAutorotateToPortraitIs auto-rotation to portrait supported?
allowedAutorotateToPortraitUpsideDownIs auto-rotation to portrait upside-down supported?
aotOptionsAdditional AOT compilation options. Shared by AOT platforms.
apiCompatibilityLevel.NET API compatibility level.
bundleIdentifierApplication bundle identifier shared between iOS & Android platforms.
bundleVersionApplication bundle version shared between iOS & Android platforms.
captureSingleScreenDefines if fullscreen games should darken secondary displays.
colorSpaceSet the color space for the current project.
companyNameThe name of your company.
defaultInterfaceOrientationDefault screen orientation for mobiles.
defaultIsFullScreenIf enabled, the game will default to fullscreen mode.
defaultScreenHeightDefault vertical dimension of stand-alone player window.
defaultScreenWidthDefault horizontal dimension of stand-alone player window.
defaultWebScreenHeightDefault vertical dimension of web player window.
defaultWebScreenWidthDefault horizontal dimension of web player window.
displayResolutionDialogDefines the behaviour of the Resolution Dialog on product launch.
firstStreamedLevelWithResourcesFirst level to have access to all Resources.Load assets in Streamed Web Players.
forceSingleInstanceRestrict standalone players to a single concurrent running instance.
gpuSkinningEnable GPU skinning on capable platforms.
iPhoneBundleIdentifierThe bundle identifier of the iPhone application.
keyaliasPassPassword for the key used for signing an Android application.
keystorePassPassword used for interacting with the Android Keystore.
macFullscreenModeDefine how to handle fullscreen mode in Mac OS X standalones.
MTRenderingIs multi-threaded rendering enabled?
productNameThe name of your product.
ps3BackgroundPathPS3 Background Image.
ps3BootCheckMaxSaveGameSizeKBPS3 Bootcheck maximum savegame size ( as per TRC R224 ). This should include the total estimated size for the savegames (including icon sizes).
ps3DLCConfigPathPS3 DLC Config file.
ps3NpCommunicationPassphraseThe Np Comminication passphrase to use when connecting to Playstation®Network.
ps3SaveGameSlotsPS3 Save Game slots.
ps3SoundPathPS3 Background Sound.
ps3ThumbnailPathPS3 Thumbnail Image.
ps3TitleConfigPathPS3 Title Config file.
ps3TrialModePS3 Title is Trial.
ps3TrophyCommIdPS3 Trophy Communication ID.
ps3TrophyCommSigPS3 Trophy Communication Signature.
ps3TrophyPackagePathPS3 Trophy Package.
psp2BackgroundPathDeprecated.
psp2DLCConfigPathDeprecated.
psp2NPCommsIDPS Vita NP Communications ID.
psp2NPCommsPassphrasePS Vita NP Passphrase.
psp2NPCommsSigPS Vita NP Signature.
psp2NPTrophyPackPathPath specifying wher to copy a trophy pack from.
psp2PackagePassword32 character password for use if you want to access the contents of a package.
psp2ParamSfxPathPath specifying where to copy the package parameter file (param.sfx) from.
psp2SoundPathDeprecated.
psp2ThumbnailPathDeprecated.
psp2TrophyCommIdDeprecated.
psp2TrophyPackagePathDeprecated.
renderingPathWhich rendering path is enabled?
resizableWindowUse resizable window in standalone player builds.
resolutionDialogBannerThe image to display in the Resolution Dialog window.
runInBackgroundIf enabled, your game will continue to run after lost focus.
statusBarHiddenShould status bar be hidden. Shared between iOS & Android platforms.
stereoscopic3DShould player render in stereoscopic 3d on supported hardware?
stripPhysicsRemove Physics code from player to save build size (Flash only).
strippingLevelManaged code stripping level.
stripUnusedMeshComponentsShould unused Mesh components be excluded from game build?
use32BitDisplayBuffer32-bit Display Buffer is used.
useAnimatedAutorotationLet the OS autorotate the screen as the device orientation changes.
useDirect3D11Should Direct3D 11 be used when available?
useMacAppStoreValidationEnable receipt validation for the Mac App Store.
usePlayerLogWrite a log file with debugging information.
xboxDeployKinectHeadOrientationXbox 360 Kinect Head Orientation file deployment.
xboxDeployKinectHeadPositionXbox 360 Kinect Head Position file deployment.
xboxDeployKinectResourcesXbox 360 Kinect resource file deployment.
xboxEnableAvatarXbox 360 Avatars.
xboxEnableKinectXbox 360 Kinect title flag - if false, the Kinect APIs are inactive.
xboxEnableKinectAutoTrackingXbox 360 Kinect automatic skeleton tracking.
xboxEnableSpeechXbox 360 Kinect Enable Speech Engine.
xboxGenerateSpaXbox 360 auto-generation of _SPAConfig.cs.
xboxImageXexFilePathXbox 360 ImageXex override configuration file path.
xboxSpaFilePathXbox 360 SPA file path.
xboxSpeechDBXbox 360 Kinect Speech DB.
xboxSplashScreenXbox 360 splash screen.
xboxTitleIdXbox 360 title id.

Static Functions

GetIconsForTargetGroupReturns the list of assigned icons for the specified platform.
GetIconSizesForTargetGroupReturns a list of icon sizes for the specified platform.
GetScriptingDefineSymbolsForGroupGet user-specified symbols for script compilation for the given build target group.
HasAspectRatioReturns whether or not the specified aspect ratio is enabled.
SetAspectRatioEnables the specified aspect ratio.
SetIconsForTargetGroupAssign a list of icons for the specified platform.
SetScriptingDefineSymbolsForGroupSet user-specified symbols for script compilation for the given build target group.

Inherited members

Variables

hideFlagsShould the object be hidden, saved with the scene or modifiable by the user?
nameThe name of the object.

Functions

GetInstanceIDReturns the instance id of the object.
ToStringReturns the name of the game object.

Static Functions

DestroyRemoves a gameobject, component or asset.
DestroyImmediateDestroys the object obj immediately. You are strongly recommended to use Destroy instead.
DontDestroyOnLoadMakes the object target not be destroyed automatically when loading a new scene.
FindObjectOfTypeReturns the first active loaded object of Type type.
FindObjectsOfTypeReturns a list of all active loaded objects of Type type.
InstantiateClones the object original and returns the clone.

Operators

boolDoes the object exist?
operator !=Compares if two objects refer to a different object.
operator ==Compares if two objects refer to the same.