From 259418f8275371fc2f0bab6892caa4ef66b84240 Mon Sep 17 00:00:00 2001 From: Juan Linietsky Date: Fri, 5 Aug 2016 22:46:45 -0300 Subject: VisualScript can now execute visual scripts, but there is no debugger or profiler yet. --- tools/editor/editor_settings.cpp | 7 +++++++ tools/editor/script_create_dialog.cpp | 16 ++++++++-------- 2 files changed, 15 insertions(+), 8 deletions(-) (limited to 'tools') diff --git a/tools/editor/editor_settings.cpp b/tools/editor/editor_settings.cpp index 9dcf71e256..11402c64e9 100644 --- a/tools/editor/editor_settings.cpp +++ b/tools/editor/editor_settings.cpp @@ -647,6 +647,11 @@ void EditorSettings::_load_defaults(Ref p_extra_config) { set("import/automatic_reimport_on_sources_changed",true); + set("visual_script/color_functions",Color(1,0.9,0.9)); + set("visual_script/color_data",Color(0.9,1.0,0.9)); + set("visual_script/color_operators",Color(0.9,0.9,1.0)); + set("visual_script/color_flow_control",Color(1.0,1.0,0.8)); + if (p_extra_config.is_valid()) { if (p_extra_config->has_section("init_projects") && p_extra_config->has_section_key("init_projects", "list")) { @@ -945,6 +950,8 @@ bool EditorSettings::_save_text_editor_theme(String p_file) { cf->set_value(theme_section, "word_highlighted_color", ((Color)get("text_editor/word_highlighted_color")).to_html()); cf->set_value(theme_section, "search_result_color", ((Color)get("text_editor/search_result_color")).to_html()); cf->set_value(theme_section, "search_result_border_color", ((Color)get("text_editor/search_result_border_color")).to_html()); + + Error err = cf->save(p_file); if (err == OK) { diff --git a/tools/editor/script_create_dialog.cpp b/tools/editor/script_create_dialog.cpp index e93a40efbc..749198314a 100644 --- a/tools/editor/script_create_dialog.cpp +++ b/tools/editor/script_create_dialog.cpp @@ -117,20 +117,20 @@ void ScriptCreateDialog::ok_pressed() { - String text = ScriptServer::get_language( language_menu->get_selected() )->get_template(cname,parent_name->get_text()); - Script *script = ScriptServer::get_language( language_menu->get_selected() )->create_script(); - script->set_source_code(text); - if (cname!="") - script->set_name(cname); + Ref