Version: 5.6
Автономный
Multi-display

Standalone Player Settings

This page details the Player Settings specific to standalone platforms (Mac OSX, Windows and Linux). A description of the general Player Settings can be found here.

Resolution And Presentation

Свойство: Описание:
Разрешение экрана
Default is Full Screen Check this box to make the game start in fullscreen mode by default.
Default Is Native Resolution Check this box to make the game use the default resolution used on the target machine.
Default Screen Width Default width of the game screen in pixels.
Default Screen Height Default height of the game screen in pixels.
Run in background Check this box to make the game keep running (rather than pausing) if the app loses focus.
Настройки Проигрывателя Автономной сборки
Capture Single Screen Check this box to ensure standalone games in fullscreen mode do not darken the secondary monitor in multi-monitor setups. This is not supported on Mac OS X.
###Настройка вашего диалогового окна для выбора разрешения (Resolution Dialog) Choose whether the game should start with a dialog to let the user choose the screen resolution. The options are Disabled, Enabled and Hidden by Default (i.e. the option only appears if the alt key is held down at startup).
Use Player Log Вести лог-файл с отладочной информацией. Если вы планируете разместить ваше приложение в Mac App Store, вы захотите снять галочку с этого свойства. Выбрано по умолчанию.
Resizable Window Позволяет пользователю изменять размеры окна проигрывателя автономной сборки.
Mac App Store Validation Включает проверку чека для Mac App Store.
Mac Fullscreen Mode Choose how fullscreen mode operate on MacOSX. The options are Capture Display (i.e. Unity takes over the whole display and the user cannot switch apps until fullscreen mode is exited), Fullscreen Window and Fullscreen Window with Menu Bar and Dock.
D3D9 FullScreen Mode Choose the fullscreen mode when using DirectX 9.
        Exclusive Mode Sets the Default Fullscreen mode to encompass the whole screen without a window surrounding it.
    Fullscreen Window Keeps the game in a window when in fullscreen. Better for allowing the game to run in the background.
        Exclusive Mode Sets the Default Fullscreen mode to encompass the whole screen without a window surrounding it.
    Fullscreen Window Keeps the game in a window when in fullscreen. Better for allowing the game to run in the background.
Visible in Background Check this box to show the application in the background if Fullscreen Windowed mode is used (in Windows).
Force Single Instance Check this box to restrict standalone players to a single concurrent running instance.
Supported Aspect Ratios Choose the aspect ratios that appear in the Resolution Dialog at startup (as long as they are supported by the user’s monitor).

Icon

Свойство: Описание:
Override for Standalone Смотрите, может вам захочется назначить свои собственные иконки, которые будут использоваться в вашей игре под ПК. Иконки различных размеров должны заполнять квадратные рамки, расположенные ниже.

Splash Image

Свойство: Описание:
Config Dialog Banner Добавте ваше собственное изображение для отображения на экране во время загрузки игры.
Show Unity Splash Screen Shows the “Made with Unity” Splash Screen when the game is loading .

Other Settings

Свойство: Описание:
Rendering
Color Space Choose which color space should be used for rendering. The options are Gamma and Linear. See the Unity Manual page on Linear Rendering for a guide to the difference between the two.
Auto Graphics API for Windows Check this box to use the best Graphics API on the Windows machine the game is running on. Uncheck it to add and remove supported Graphics APIs.
Auto Graphics API for Mac Check this box to use the best Graphics API on the Mac the game is running on. Uncheck it to add and remove supported Graphics APIs.
Auto Graphics API for Linux Check this box to use the best Graphics API on the Linux machine it runs on. Uncheck it to add and remove supported Graphics APIs.
Static Batching Check this box to use Static batching.
Dynamic Batching Check this box to use Dynamic Batching (activated by default).
GPU Skinning Check this box to enable DX11/ES3 GPU skinning.
Graphics Jobs (Experimental) Check this box to instruct Unity to offload graphics tasks (render loops) to worker threads running on other CPU cores. This is intended to reduce the time spent in Camera.Render on the main thread, which is often a bottleneck. Please note that this feature is experimental. it may not deliver a performance improvement for your project, and may introduce new crashes.
Virtual Reality Supported Check this box when building a Virtual Reality application. See VR Overview for more information.
Настройки
Scripting Backend Mono2x is the only scripting backend supported on Standalone platforms.
Disable HW Statistics Check this box to instruct the application not to send information about the hardware to Unity (See the Unity Hardware Statistics page for more details).
Scripting Define Symbols Пользовательские флаги компиляции (обратитесь к странице [платформо-зависимая компиляция] для более подробной информации).
Оптимизация
API Compatibility Level There are two options for API compatibility level: .Net 2.0, or .Net 2.0 Subset.
        .Net 2.0 Библиотеки .Net 2.0. Максимальная совместимость с .net, самый большой размер файлов
        .Net 2.0 Subset Подмножество полной совместимости с .net, меньший размер файлов
Prebake Collision Meshes Check this box to add collision data to meshes at build time.
Preload Shaders Check this box to load shaders when the player starts up.
Preloaded Assets Set an array of assets to be loaded when the player starts up.
Vertex Compression Vertex compression can be set per channel. You can, for instance, choose to have compression enabled for everything except positions and lightmap UVs. Whole mesh compression set per imported object will override the vertex compression on objects that have it set, while everything else will obey the vertex compression options/channels set here.
Optimize Mesh Data Удаляет все данные из мешей, которые не требуются применённым к ним материалам (касательные, нормали, цвета, UV-координаты).

API Compatibility Level

You can choose your mono API compatibility level for all targets. Sometimes a 3rd-party .net dll will use things that are outside of the .net compatibility level that you would like to use. In order to understand what is going on in such cases, and how to best fix it, install “Reflector” for Windows.

  1. Перетащите .net узлы для уровня API совместимости рассматриваемый в отношении отражателя (reflector). Их можно найти в Frameworks/Mono/lib/mono/YOURSUBSET/
  2. Также перетащите в вашу стороннюю сборку.
  3. Нажмите правой кнопкой на вашей сторонней библиотеке и выберите “Analyze”.
  4. В отчёте по анализу, проверьте секцию под названием “Depends on”. Всё что зависит от сторонней сборки, но доступно вам лишь на уровне совместимости .net, будет выделено там красным цветом.

Детали

Настройка вашего диалогового окна для выбора разрешения (Resolution Dialog)

The Resolution Dialog, presented to end-users
The Resolution Dialog, presented to end-users

В Standalone проигрывателе у вас есть возможность добавить своё баннерное изображение для диалогового окна Screen Resolution. Максимальный размер изображения равен 432 x 163 пикселям. Изображение не будет масштабировано до соответствия выделяемой области экрана. Вместо этого оно будет отцентрировано и обрезано.

Publishing to the Mac App Store

Use Player Log позволяет вести запись в лог файл вместе с отладочной информацией. Полезно в случаях, когда нужно разобраться в проблемах, которые возникают в вашей игре. При публикации игр для магазина Apple’s Mac приложений рекомендует отключать эту опцию, так как Apple может отклонить ваш запрос. См. для дополнительной информации по лог файлам эту страницу руководства.

The property Use Mac App Store Validation enables receipt validation for the Mac App Store. If this is enabled, your game will only run when it contains a valid receipt from the Mac App Store. Use this when submitting games to Apple for publishing on the App Store. This prevents people from running the game on a different computer to the one it was purchased on. Note that this feature does not implement any strong copy protection. In particular, any potential crack against one Unity game would work against any other Unity content. For this reason, it is recommended that you implement your own receipt validation code on top of this, using Unity’s plugin feature. However, since Apple requires plugin validation to initially happen before showing the screen setup dialog, you should still enable this check, or Apple might reject your submission.

Windows Store Apps

Player Settings
Player Settings

При создании решения в Visual Studio в первый раз, большинство этих настроек помещается в Package.appxmanifest.

Note: If you build your project on top of the existing one, Unity won’t overwrite Package.appxmanifest file if it’s already present, so check for this if you change something in Player Settings. If you want Package.appxmanifest to be regenerated, simply delete it and rebuild your project from Unity.

To read more about App package manifest, see the Windows Dev Center App package manifest page.

Any settings you choose in Packaging, Application UI, Tile, Splash Screen and Capabilities directly transfer to settings in the Package.appxmanifest file.

Certificate

Каждому Windows Store приложению необходим сертификат, определяющий его разработчика. Если разработчик не предоставит свой сертификат, то Unity создаст для него стандартный.

Compilation

Как вы знаете, Unity использует Mono для компиляции файлов скриптов, и вы можете использовать API расположенное в .NET 3.5. Compilation Overrides позволяет использовать в ваших c# файлах .NET для Windows Store Apps (также известный как .NET Core). Сам же API доступен по адресу.

There are three options to choose from in Compiler Overrides:

Свойство: Описание:
None 1. При использовании Mono компилятора, не компилируются никакие - C# файлы.
Use .Net Core C# files are compiled using Microsoft compiler and .NET Core. You can use Windows Runtime API, but classes implemented in C# files aren’t accessible from JS.
Use .Net Core Partially C# files not located in Plugins, Standard Assets or Pro Standard Assets folders are compiled using Microsoft compiler and .NET Core. All other C# files are compiled using Mono compiler. The advantage here is that classes implemented in C# are accessible from JS.

Заметка: Вы не сможете тестировать .NET Core API в редакторе Unity, потому что он не имеет доступа к .NET Core. Поэтому вы сможете протестировать API только при запущенном Windows Store App.

Note: You cannot use .NET Core API in JS.

Вот небольшой пример того, как использовать в скриптах .NET Core API.

    string GetTemporaryFolder()
    {
    #if NETFX_CORE
        return Windows.Storage.ApplicationData.Current.TemporaryFolder.Path;
    #else
        return "LocalFolder";
    #endif
    }

Plugins

The property Unprocessed Plugins contains a list of plugins which are ignored by Unity’s preprocessing tools (like SerializationWeaver and AssemblyPreprocessor). Usually you don’t need to modify this list, unless you’re getting an error that Unity has failed to preprocess your plugin.

Что произойдёт если вы добавите в этот список плагин?

Unity не вводит в вашу сборку, используемую для сериализации дополнительный IL код, и если ваш плагин не ссылается на библиотеку UnityEngine.dll, то ничего страшного, потому что Unity не должен сириализировать данных из вашего плагина.

Independent Input Source

The property Independent Input Source essentially gives you the ability to make your input more responsive. Learn more on the Windows Dev Center SwapChainPanel.CreateCoreIndependentInputSource class page.

Low Latency Presentation API

The property Low Latency Presentation API essentially creates a D3D11 swapchain with a DXGI\_SWAP\_CHAIN\_FLAG\_FRAME\_LATENCY\_WAITABLE_OBJECT flag, and can increase input responsiveness. Learn more on the Windows Dev Center DXGI_SWAP_CHAIN_FLAG enumeration page. This option is disabled by default because on hardware with older GPU drivers, this option makes game laggy, if you enable this option - be sure to profile your game if the performance is still acceptable.

Capabilities

Данные настройки копируются прямо в Package.appxmanifest.

Note: If you’re building your game on top of a previous package, Package.appxmanifest won’t be overwritten, so check for this if you change something in Player Settings.

Автономный
Multi-display
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961