|
@@ -246,7 +246,7 @@ void EditorExportPlatformIOS::get_export_options(List<ExportOption> *r_options)
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/app_store_team_id"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/app_store_team_id"), ""));
|
|
|
|
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/provisioning_profile_uuid_debug"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/provisioning_profile_uuid_debug"), ""));
|
|
- r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/code_sign_identity_debug", PROPERTY_HINT_PLACEHOLDER_TEXT, "iPhone Developer"), ""));
|
|
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/code_sign_identity_debug", PROPERTY_HINT_PLACEHOLDER_TEXT, "iPhone Developer"), "iPhone Developer"));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "application/export_method_debug", PROPERTY_HINT_ENUM, "App Store,Development,Ad-Hoc,Enterprise"), 1));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::INT, "application/export_method_debug", PROPERTY_HINT_ENUM, "App Store,Development,Ad-Hoc,Enterprise"), 1));
|
|
|
|
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/provisioning_profile_uuid_release"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/provisioning_profile_uuid_release"), ""));
|
|
@@ -255,12 +255,27 @@ void EditorExportPlatformIOS::get_export_options(List<ExportOption> *r_options)
|
|
|
|
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/name", PROPERTY_HINT_PLACEHOLDER_TEXT, "Game Name"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/name", PROPERTY_HINT_PLACEHOLDER_TEXT, "Game Name"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/info"), "Made with Godot Engine"));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/info"), "Made with Godot Engine"));
|
|
- r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/identifier", PROPERTY_HINT_PLACEHOLDER_TEXT, "come.example.game"), ""));
|
|
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/identifier", PROPERTY_HINT_PLACEHOLDER_TEXT, "com.example.game"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/signature"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/signature"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/short_version"), "1.0"));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/short_version"), "1.0"));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/version"), "1.0"));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/version"), "1.0"));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/copyright"), ""));
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "application/copyright"), ""));
|
|
|
|
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "capabilities/arkit"), false));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "capabilities/access_wifi"), false));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "capabilities/game_center"), true));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "capabilities/in_app_purchases"), false));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "capabilities/push_notifications"), false));
|
|
|
|
+
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "privacy/camera_usage_description"), "Godot would like to use your camera"));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "privacy/microphone_usage_description"), "Godot would like to use your microphone"));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "privacy/photolibrary_usage_description"), "Godot would like to use your photos"));
|
|
|
|
+
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "orientation/portrait"), true));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "orientation/landscape_left"), true));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "orientation/landscape_right"), true));
|
|
|
|
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "orientation/portrait_upside_down"), true));
|
|
|
|
+
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "required_icons/iphone_120x120", PROPERTY_HINT_FILE, "*.png"), "")); // Home screen on iPhone/iPod Touch with retina display
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "required_icons/iphone_120x120", PROPERTY_HINT_FILE, "*.png"), "")); // Home screen on iPhone/iPod Touch with retina display
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "required_icons/ipad_76x76", PROPERTY_HINT_FILE, "*.png"), "")); // Home screen on iPad
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "required_icons/ipad_76x76", PROPERTY_HINT_FILE, "*.png"), "")); // Home screen on iPad
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "required_icons/app_store_1024x1024", PROPERTY_HINT_FILE, "*.png"), "")); // App Store
|
|
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "required_icons/app_store_1024x1024", PROPERTY_HINT_FILE, "*.png"), "")); // App Store
|
|
@@ -337,6 +352,62 @@ void EditorExportPlatformIOS::_fix_config_file(const Ref<EditorExportPreset> &p_
|
|
strnew += lines[i].replace("$linker_flags", p_config.linker_flags) + "\n";
|
|
strnew += lines[i].replace("$linker_flags", p_config.linker_flags) + "\n";
|
|
} else if (lines[i].find("$cpp_code") != -1) {
|
|
} else if (lines[i].find("$cpp_code") != -1) {
|
|
strnew += lines[i].replace("$cpp_code", p_config.cpp_code) + "\n";
|
|
strnew += lines[i].replace("$cpp_code", p_config.cpp_code) + "\n";
|
|
|
|
+ } else if (lines[i].find("$access_wifi") != -1) {
|
|
|
|
+ bool is_on = p_preset->get("capabilities/access_wifi");
|
|
|
|
+ strnew += lines[i].replace("$access_wifi", is_on ? "1" : "0") + "\n";
|
|
|
|
+ } else if (lines[i].find("$game_center") != -1) {
|
|
|
|
+ bool is_on = p_preset->get("capabilities/game_center");
|
|
|
|
+ strnew += lines[i].replace("$game_center", is_on ? "1" : "0") + "\n";
|
|
|
|
+ } else if (lines[i].find("$in_app_purchases") != -1) {
|
|
|
|
+ bool is_on = p_preset->get("capabilities/in_app_purchases");
|
|
|
|
+ strnew += lines[i].replace("$in_app_purchases", is_on ? "1" : "0") + "\n";
|
|
|
|
+ } else if (lines[i].find("$push_notifications") != -1) {
|
|
|
|
+ bool is_on = p_preset->get("capabilities/push_notifications");
|
|
|
|
+ strnew += lines[i].replace("$push_notifications", is_on ? "1" : "0") + "\n";
|
|
|
|
+ } else if (lines[i].find("$required_device_capabilities") != -1) {
|
|
|
|
+ String capabilities;
|
|
|
|
+
|
|
|
|
+ // I've removed armv7 as we can run on 64bit only devices
|
|
|
|
+ // Note that capabilities listed here are requirements for the app to be installed.
|
|
|
|
+ // They don't enable anything.
|
|
|
|
+
|
|
|
|
+ if ((bool)p_preset->get("capabilities/arkit")) {
|
|
|
|
+ capabilities += "<string>arkit</string>\n";
|
|
|
|
+ }
|
|
|
|
+ if ((bool)p_preset->get("capabilities/game_center")) {
|
|
|
|
+ capabilities += "<string>gamekit</string>\n";
|
|
|
|
+ }
|
|
|
|
+ if ((bool)p_preset->get("capabilities/access_wifi")) {
|
|
|
|
+ capabilities += "<string>wifi</string>\n";
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ strnew += lines[i].replace("$required_device_capabilities", capabilities);
|
|
|
|
+ } else if (lines[i].find("$interface_orientations") != -1) {
|
|
|
|
+ String orientations;
|
|
|
|
+
|
|
|
|
+ if ((bool)p_preset->get("orientation/portrait")) {
|
|
|
|
+ orientations += "<string>UIInterfaceOrientationPortrait</string>\n";
|
|
|
|
+ }
|
|
|
|
+ if ((bool)p_preset->get("orientation/landscape_left")) {
|
|
|
|
+ orientations += "<string>UIInterfaceOrientationLandscapeLeft</string>\n";
|
|
|
|
+ }
|
|
|
|
+ if ((bool)p_preset->get("orientation/landscape_right")) {
|
|
|
|
+ orientations += "<string>UIInterfaceOrientationLandscapeRight</string>\n";
|
|
|
|
+ }
|
|
|
|
+ if ((bool)p_preset->get("orientation/portrait_upside_down")) {
|
|
|
|
+ orientations += "<string>UIInterfaceOrientationPortraitUpsideDown</string>\n";
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ strnew += lines[i].replace("$interface_orientations", orientations);
|
|
|
|
+ } else if (lines[i].find("$camera_usage_description") != -1) {
|
|
|
|
+ String description = p_preset->get("privacy/camera_usage_description");
|
|
|
|
+ strnew += lines[i].replace("$camera_usage_description", description) + "\n";
|
|
|
|
+ } else if (lines[i].find("$microphone_usage_description") != -1) {
|
|
|
|
+ String description = p_preset->get("privacy/microphone_usage_description");
|
|
|
|
+ strnew += lines[i].replace("$microphone_usage_description", description) + "\n";
|
|
|
|
+ } else if (lines[i].find("$photolibrary_usage_description") != -1) {
|
|
|
|
+ String description = p_preset->get("privacy/photolibrary_usage_description");
|
|
|
|
+ strnew += lines[i].replace("$photolibrary_usage_description", description) + "\n";
|
|
} else {
|
|
} else {
|
|
strnew += lines[i] + "\n";
|
|
strnew += lines[i] + "\n";
|
|
}
|
|
}
|
|
@@ -648,6 +719,10 @@ void EditorExportPlatformIOS::_add_assets_to_project(Vector<uint8_t> &p_project_
|
|
pbx_files += file_info_format.format(format_dict, "$_");
|
|
pbx_files += file_info_format.format(format_dict, "$_");
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ // Note, frameworks like gamekit are always included in our project.pbxprof file
|
|
|
|
+ // even if turned off in capabilities.
|
|
|
|
+ // Frameworks that are used by modules (like arkit) we may need to optionally add here.
|
|
|
|
+
|
|
String str = String::utf8((const char *)p_project_data.ptr(), p_project_data.size());
|
|
String str = String::utf8((const char *)p_project_data.ptr(), p_project_data.size());
|
|
str = str.replace("$additional_pbx_files", pbx_files);
|
|
str = str.replace("$additional_pbx_files", pbx_files);
|
|
str = str.replace("$additional_pbx_frameworks_build", pbx_frameworks_build);
|
|
str = str.replace("$additional_pbx_frameworks_build", pbx_frameworks_build);
|