Up to date
This page is up to date for Godot 4.2
.
If you still find outdated information, please open an issue.
Експорт на Windows¶
Дивись також
На цій сторінці описано, як експортувати проект Godot на Windows. Якщо ви хочете замість цього скомпілювати редактор, або експортувати шаблони бінарників з джерела, прочитайте Compiling for Windows.
Найпростіший спосіб розповсюдження ігор на ПК - це скопіювати виконувані файли (godot.exe
), стиснути папку та надіслати її комусь іншому. Однак часто цього не бажано робити.
Godot пропонує елегантніший підхід до розповсюдження на ПК при використанні системи експорту. Під час експорту на Windows, експортер бере всі файли проєкту та створює файл data.pck
. Цей файл укомплектований спеціально оптимізованим бінарним файлом, який є меншим, швидшим та не містить редактора і налагоджувача.
Підписання коду¶
Godot is capable of automatic code signing on export. To do this you must have the
Windows SDK
(on Windows) or osslsigncode
(on any other OS) installed. You will also need a package signing certificate,
information on creating one can be found here.
Попередження
Якщо ви експортуєте для Windows із вбудованими файлами PCK, ви не зможете підписати програму, тому що вона перестане працювати.
Вбудовані PCK на Windows можуть спричиняти помилкові спрацювання в антивірусних програмах. Тому рекомендується уникати їх використання, якщо тільки ви не поширюєте свій проєкт через Steam, оскільки він обходить підписання коду та антивірусні перевірки.
Налаштування¶
Settings need to be changed in two places. First, in the editor settings, under
Export > Windows. Click on the folder next to the Sign Tool
setting, if
you're using Windows navigate to and select SignTool.exe
, if you're on a different
OS select osslsigncode
.
The second location is the Windows export preset, which can be found in Project > Export.... Add a windows desktop preset if you haven't already. Under options there is a code signing category.
Enabled
must be set to true, and Identity
must be set to the signing
certificate. The other settings can be adjusted as needed. Once this is Done
Godot will sign your project on export.
Змінні середовища¶
You can use the following environment variables to set export options outside of the editor. During the export process, these override the values that you set in the export menu.
Export option |
Environment variable |
---|---|
Encryption / Encryption Key |
|
Options / Codesign / Identity Type |
|
Options / Codesign / Identity |
|
Options / Codesign / Password |
|