diff options
27 files changed, 90 insertions, 114 deletions
diff --git a/.travis.yml b/.travis.yml index cb0b33679c..8c24291328 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,7 @@ language: cpp +# OS config, depends on actual 'os' in build matrix dist: trusty - sudo: false env: @@ -9,7 +9,7 @@ env: - SCONS_CACHE=$HOME/.scons_cache - SCONS_CACHE_LIMIT=1024 - OPTIONS="verbose=yes progress=no gdnative_wrapper=yes" - - secure: AnjB84ZZYDxDQdWwsT9PJrD5tEnwcauzvVeSG+us2GxgfyJ2HFArkZ/IjlvbsfYIiiHghJ2Ssy9yPtUT921BtNNHoWuN/8YQziGrlwiSfLGmS/n8GFH22OYwzDSa7UC7ODts5La2I4+JzrdtF933TwE+4QzH4E3GyaKbznh402E= + - secure: "QLFRizqry/Y5pnEZvDlQz5S3YydQ+600u4rHEzFgUTd0heYeQaETXAQeMzp0ymuG1BkdRAl5YJoLVJgAzjwI9hrvugvoUlh2//SfpqZCHN/Q1fYbtGgNTn01R3VFEpcfYQL93I2EjrxVm0WTM4PwCvMO+hU0aWTRDvCt1Lty0kMR+RMDQOO/woqunoXh5wvFNxTJJkAmuLe0v962DJYOIwJAnqMLR0aFYjmeQJ20bc/2X5oLt+WuJDuf/lGj6WSlD6z/o/kL3YxHoUyw4A/HAZ2IX0IfNHKuay60ESWzl/NlobnePiPwHAE2pdDVu//q16fanb9VeYnBYRFse49TpFRb86Lo+Qz8nKDJqpQEIY0YKNCFqekrubqTM++Lj6QvGpykQZNxUhybmELcEsRG4PS0UMvCpebdnJD46nNB+DtO2Lgb4xXDLQwpq19z1wizq/XDQ5hz61TIIx8+i8TsgdSQKCTeWovd4HcD4CVjAD5XTLGgyRmI/zC2d+lTnKo6W9diLq/bX/Goq2QPeaTPABqv817IaJka2JyugQ7Qal/+gNTjYRRsimRCL9B2tVh+Uh8rWhTFhQL4QbP5P65HF+p8qojUzqtAhPMbZ8mxUtNukUI3liVgPgiMss96sG0nTVglFgkkAkEjIMFnqMSKnTfG812K4jIhp2jCO2Q3NeI=" cache: directories: @@ -20,78 +20,66 @@ matrix: - env: STATIC_CHECKS=yes os: linux compiler: gcc - - env: GODOT_TARGET=x11 TOOLS=yes CACHE_NAME=${GODOT_TARGET}-gcc-tools" + addons: + apt: + sources: + - llvm-toolchain-trusty-5.0 + packages: + - clang-format-5.0 + + coverity_scan: + project: + name: "godotengine/godot" + description: "Godot Engine Coverity scans" + notification_email: coverity@godotengine.org + build_command_prepend: "" + build_command: "scons p=x11 -j2 $OPTIONS" + branch_pattern: coverity_scan + + - env: GODOT_TARGET=x11 TOOLS=yes CACHE_NAME=${GODOT_TARGET}-tools-mono-gcc EXTRA_ARGS="module_mono_enabled=yes mono_glue=no" os: linux compiler: gcc - - env: GODOT_TARGET=x11 TOOLS=no CACHE_NAME=${GODOT_TARGET}-clang" + addons: + apt: + sources: + - mono + packages: + - &linux_deps [libasound2-dev, libfreetype6-dev, libgl1-mesa-dev, libglu1-mesa-dev, libx11-dev, libxcursor-dev, libxi-dev, libxinerama-dev, libxrandr-dev] + - &linux_mono_deps [mono-devel, msbuild] + + - env: GODOT_TARGET=x11 TOOLS=no CACHE_NAME=${GODOT_TARGET}-clang os: linux compiler: clang - #- env: GODOT_TARGET=windows TOOLS=yes CACHE_NAME=${GODOT_TARGET}-gcc-tools - # os: linux - # compiler: gcc - - env: GODOT_TARGET=android TOOLS=no CACHE_NAME=${GODOT_TARGET}-gcc + addons: + apt: + packages: + - *linux_deps + + - env: GODOT_TARGET=android TOOLS=no CACHE_NAME=${GODOT_TARGET}-clang os: linux - compiler: gcc - - env: GODOT_TARGET=osx TOOLS=yes CACHE_NAME=${GODOT_TARGET}-clang-tools + compiler: clang + + - env: GODOT_TARGET=osx TOOLS=yes CACHE_NAME=${GODOT_TARGET}-tools-clang os: osx osx_image: xcode9.3 compiler: clang + - env: GODOT_TARGET=iphone TOOLS=no CACHE_NAME=${GODOT_TARGET}-clang os: osx osx_image: xcode9.3 compiler: clang - - env: GODOT_TARGET=server TOOLS=no CACHE_NAME=${GODOT_TARGET}-clang" - os: linux - compiler: clang - -addons: - apt: - sources: - - ubuntu-toolchain-r-test - - llvm-toolchain-trusty-5.0 - packages: - - build-essential - - scons - - pkg-config - - libx11-dev - - libxcursor-dev - - libxi-dev - - libxinerama-dev - - libxrandr-dev - - libgl1-mesa-dev - - libglu1-mesa-dev - - libasound2-dev - - libfreetype6-dev - - # For cross-compiling to Windows. - #- binutils-mingw-w64-i686 - #- binutils-mingw-w64-x86-64 - #- gcc-mingw-w64-i686 - #- gcc-mingw-w64-x86-64 - #- g++-mingw-w64-i686 - #- g++-mingw-w64-x86-64 - #- mingw-w64 - # For style checks. - - clang-format-5.0 - - coverity_scan: - project: - name: "godotengine/godot" - description: "Godot Engine Coverity scans" - notification_email: coverity@godotengine.org - build_command_prepend: "" - build_command: "scons p=x11 -j2 $OPTIONS" - branch_pattern: coverity_scan + - env: GODOT_TARGET=server TOOLS=yes CACHE_NAME=${GODOT_TARGET}-tools-gcc + os: linux + compiler: gcc + addons: + apt: + packages: + - *linux_deps before_install: - if [ "$STATIC_CHECKS" = "yes" ]; then unset SCONS_CACHE; - else - if [ "$TRAVIS_BRANCH" = "coverity_scan" ]; then - echo "This job runs in the Coverity Scan branch and is not the STATIC_CHECKS job meant for it, so aborting with exit code 0."; - travis_terminate 0; - fi; fi install: @@ -115,5 +103,5 @@ script: - if [ "$STATIC_CHECKS" = "yes" ]; then sh ./misc/travis/clang-format.sh; else - scons -j2 CC=$CC CXX=$CXX platform=$GODOT_TARGET TOOLS=$TOOLS $OPTIONS; + scons -j2 CC=$CC CXX=$CXX platform=$GODOT_TARGET TOOLS=$TOOLS $EXTRA_ARGS $OPTIONS; fi diff --git a/doc/classes/@GDScript.xml b/doc/classes/@GDScript.xml index cddc59ab71..a4ca830d4d 100644 --- a/doc/classes/@GDScript.xml +++ b/doc/classes/@GDScript.xml @@ -4,7 +4,7 @@ Built-in GDScript functions. </brief_description> <description> - This contains the list of built-in gdscript functions. Mostly math functions and other utilities. Everything else is expanded by objects. + List of core built-in GDScript functions. Math functions and other utilities. Everything else is provided by objects. (Keywords: builtin, built in, global functions.) </description> <tutorials> </tutorials> diff --git a/doc/classes/AudioEffectEQ10.xml b/doc/classes/AudioEffectEQ10.xml index f88a954417..daca342ace 100644 --- a/doc/classes/AudioEffectEQ10.xml +++ b/doc/classes/AudioEffectEQ10.xml @@ -16,7 +16,6 @@ Band 8 : 4000 Hz Band 9 : 8000 Hz Band 10 : 16000 Hz - See also [AudioEffectEQ], [AudioEffectEQ6], [AudioEffectEQ21]. </description> <tutorials> diff --git a/doc/classes/AudioEffectEQ21.xml b/doc/classes/AudioEffectEQ21.xml index 86d2189f27..99d35604fc 100644 --- a/doc/classes/AudioEffectEQ21.xml +++ b/doc/classes/AudioEffectEQ21.xml @@ -27,7 +27,6 @@ Band 19 : 11000 Hz Band 20 : 16000 Hz Band 21 : 22000 Hz - See also [AudioEffectEQ], [AudioEffectEQ6], [AudioEffectEQ10]. </description> <tutorials> diff --git a/doc/classes/AudioEffectEQ6.xml b/doc/classes/AudioEffectEQ6.xml index 8f789cdbdd..047c4c960f 100644 --- a/doc/classes/AudioEffectEQ6.xml +++ b/doc/classes/AudioEffectEQ6.xml @@ -12,7 +12,6 @@ Band 4 : 1000 Hz Band 5 : 3200 Hz Band 6 : 10000 Hz - See also [AudioEffectEQ], [AudioEffectEQ10], [AudioEffectEQ21]. </description> <tutorials> diff --git a/doc/classes/EditorImportPlugin.xml b/doc/classes/EditorImportPlugin.xml index 406bd7b7df..e48eb82691 100644 --- a/doc/classes/EditorImportPlugin.xml +++ b/doc/classes/EditorImportPlugin.xml @@ -5,10 +5,7 @@ </brief_description> <description> EditorImportPlugins provide a way to extend the editor's resource import functionality. Use them to import resources from custom files or to provide alternatives to the editor's existing importers. Register your [EditorPlugin] with [method EditorPlugin.add_import_plugin]. - EditorImportPlugins work by associating with specific file extensions and a resource type. See [method get_recognized_extension] and [method get_resource_type]). They may optionally specify some import presets that affect the import process. EditorImportPlugins are responsible for creating the resources and saving them in the [code].import[/code] directory. - - Below is an example EditorImportPlugin that imports a [Mesh] from a file with the extension ".special" or ".spec": [codeblock] tool diff --git a/doc/classes/Engine.xml b/doc/classes/Engine.xml index 3273005395..f921b76b21 100644 --- a/doc/classes/Engine.xml +++ b/doc/classes/Engine.xml @@ -16,7 +16,6 @@ </return> <description> Returns engine author information in a Dictionary. - "lead_developers" - Array of Strings, lead developer names "founders" - Array of Strings, founder names "project_managers" - Array of Strings, project manager names @@ -28,7 +27,6 @@ </return> <description> Returns an Array of copyright information Dictionaries. - "name" - String, component name "parts" - Array of Dictionaries {"files", "copyright", "license"} describing subsections of the component </description> @@ -89,7 +87,6 @@ </return> <description> Returns the current engine version information in a Dictionary. - "major" - Holds the major version number as an int "minor" - Holds the minor version number as an int "patch" - Holds the patch version number as an int diff --git a/doc/classes/InputEventMouseButton.xml b/doc/classes/InputEventMouseButton.xml index fd326f97d5..50641dceed 100644 --- a/doc/classes/InputEventMouseButton.xml +++ b/doc/classes/InputEventMouseButton.xml @@ -21,7 +21,7 @@ If [code]true[/code] the mouse button's state is a double-click. If [code]false[/code] the mouse button's state is released. </member> <member name="factor" type="float" setter="set_factor" getter="get_factor"> - TO TALK in PR, reduz said : i think it's used for apple touch but i don't remember what it does + Magnitude. Amount (or delta) of the event. Used for scroll events, indicates scroll amount (vertically or horizontally). Only supported on some platforms, sensitivity varies by platform. May be 0 if not supported. </member> <member name="pressed" type="bool" setter="set_pressed" getter="is_pressed"> If [code]true[/code] the mouse button's state is pressed. If [code]false[/code] the mouse button's state is released. diff --git a/doc/classes/OS.xml b/doc/classes/OS.xml index 9505cad868..b53d1e2345 100644 --- a/doc/classes/OS.xml +++ b/doc/classes/OS.xml @@ -292,7 +292,6 @@ </argument> <description> Returns the dots per inch density of the specified screen. - On Android Devices, the actual screen densities are grouped into six generalized densities: ldpi - 120 dpi mdpi - 160 dpi diff --git a/doc/classes/Quat.xml b/doc/classes/Quat.xml index f1a6ce5c0b..c755e6b02a 100644 --- a/doc/classes/Quat.xml +++ b/doc/classes/Quat.xml @@ -6,7 +6,6 @@ <description> A unit quaternion used for representing 3D rotations. It is similar to [Basis], which implements matrix representation of rotations, and can be parametrized using both an axis-angle pair or Euler angles. But due to its compactness and the way it is stored in memory, certain operations (obtaining axis-angle and performing SLERP, in particular) are more efficient and robust against floating point errors. - Quaternions need to be (re)normalized. </description> <tutorials> diff --git a/doc/classes/Skeleton.xml b/doc/classes/Skeleton.xml index 0f96ee01ff..4d826002fe 100644 --- a/doc/classes/Skeleton.xml +++ b/doc/classes/Skeleton.xml @@ -5,6 +5,8 @@ </brief_description> <description> Skeleton provides a hierarchical interface for managing bones, including pose, rest and animation (see [Animation]). Skeleton will support rag doll dynamics in the future. + The overall transform of a bone with respect to the skeleton is determined by the following hierarchical order: rest pose, custom pose and pose. + Note that "global pose" below refers to the overall transform of the bone with respect to skeleton, so it not the actual global/world transform of the bone. </description> <tutorials> </tutorials> @@ -60,6 +62,7 @@ <argument index="0" name="bone_idx" type="int"> </argument> <description> + Return the custom pose of the specified bone. Custom pose is applied on top of the rest pose. </description> </method> <method name="get_bone_global_pose" qualifiers="const"> @@ -68,6 +71,7 @@ <argument index="0" name="bone_idx" type="int"> </argument> <description> + Return the overall transform of the specified bone, with respect to the skeleton. Being relative to the skeleton frame, this is not the actual "global" transform of the bone. </description> </method> <method name="get_bone_name" qualifiers="const"> @@ -76,7 +80,7 @@ <argument index="0" name="bone_idx" type="int"> </argument> <description> - Return the name of the bone at index "index" + Return the name of the bone at index "index". </description> </method> <method name="get_bone_parent" qualifiers="const"> @@ -94,7 +98,7 @@ <argument index="0" name="bone_idx" type="int"> </argument> <description> - Return the pose transform for bone "bone_idx". + Return the pose transform of the specified bone. Pose is applied on top of the custom pose, which is applied on top the rest pose. </description> </method> <method name="get_bone_rest" qualifiers="const"> @@ -112,6 +116,7 @@ <argument index="0" name="bone_idx" type="int"> </argument> <description> + Return the combination of custom pose and pose. The returned transform is in skeleton's reference frame. </description> </method> <method name="get_bound_child_nodes_to_bone" qualifiers="const"> diff --git a/doc/classes/Spatial.xml b/doc/classes/Spatial.xml index 46f2bedfc2..d9242d8c42 100644 --- a/doc/classes/Spatial.xml +++ b/doc/classes/Spatial.xml @@ -5,7 +5,6 @@ </brief_description> <description> Most basic 3D game object, with a 3D [Transform] and visibility settings. All other 3D game objects inherit from Spatial. Use Spatial as a parent node to move, scale, rotate and show/hide children in a 3D project. - Affine operations (rotate, scale, translate) happen in parent's local coordinate system, unless the Spatial object is set as top level. Affine operations in this coordinate system correspond to direct affine operations on the Spatial's transform. The word local below refers to this coordinate system. The coordinate system that is attached to the Spatial object itself is referred to as object-local coordinate system. </description> <tutorials> @@ -284,7 +283,6 @@ </member> <member name="rotation" type="Vector3" setter="set_rotation" getter="get_rotation"> Rotation part of the local transformation, specified in terms of YXZ-Euler angles in the format (X-angle, Y-angle, Z-angle), in radians. - Note that in the mathematical sense, rotation is a matrix and not a vector. The three Euler angles, which are the three indepdent parameters of the Euler-angle parametrization of the rotation matrix, are stored in a [Vector3] data structure not because the rotation is a vector, but only because [Vector3] exists as a convenient data-structure to store 3 floating point numbers. Therefore, applying affine operations on the rotation "vector" is not meaningful. </member> <member name="rotation_degrees" type="Vector3" setter="set_rotation_degrees" getter="get_rotation_degrees"> diff --git a/doc/classes/ToolButton.xml b/doc/classes/ToolButton.xml index 1dbfd63010..d8db95a854 100644 --- a/doc/classes/ToolButton.xml +++ b/doc/classes/ToolButton.xml @@ -5,7 +5,6 @@ </brief_description> <description> This is a helper class to generate a flat [Button] (see [method Button.set_flat]), creating a ToolButton is equivalent to: - [codeblock] var btn = Button.new() btn.set_flat(true) diff --git a/doc/classes/TreeItem.xml b/doc/classes/TreeItem.xml index 6448b26972..57e0f2825a 100644 --- a/doc/classes/TreeItem.xml +++ b/doc/classes/TreeItem.xml @@ -308,7 +308,7 @@ <argument index="0" name="child" type="Object"> </argument> <description> - Removes the child TreeItem at index [code]index[/code]. + Removes the given child TreeItem. </description> </method> <method name="select"> diff --git a/doc/classes/Vector2.xml b/doc/classes/Vector2.xml index 26e2da09d6..ba62a385af 100644 --- a/doc/classes/Vector2.xml +++ b/doc/classes/Vector2.xml @@ -76,6 +76,7 @@ <return type="Vector2"> </return> <description> + Returns the vector with all components rounded up. </description> </method> <method name="clamped"> @@ -142,7 +143,7 @@ <return type="Vector2"> </return> <description> - Remove the fractional part of x and y. + Returns the vector with all components rounded down. </description> </method> <method name="is_normalized"> diff --git a/doc/classes/ViewportTexture.xml b/doc/classes/ViewportTexture.xml index 83ffc6bcfd..6281fbcc0b 100644 --- a/doc/classes/ViewportTexture.xml +++ b/doc/classes/ViewportTexture.xml @@ -1,6 +1,7 @@ <?xml version="1.0" encoding="UTF-8" ?> <class name="ViewportTexture" inherits="Texture" category="Core" version="3.1"> <brief_description> + Texture which displays the content of a [Viewport]. </brief_description> <description> </description> @@ -12,6 +13,7 @@ </methods> <members> <member name="viewport_path" type="NodePath" setter="set_viewport_path_in_scene" getter="get_viewport_path_in_scene"> + The path to the [Viewport] node to display. This is relative to the scene root, not to the node which uses the texture. </member> </members> <constants> diff --git a/editor/editor_inspector.cpp b/editor/editor_inspector.cpp index ebfb63b1f3..848e0b30da 100644 --- a/editor/editor_inspector.cpp +++ b/editor/editor_inspector.cpp @@ -1654,6 +1654,10 @@ void EditorInspector::set_use_folding(bool p_enable) { update_tree(); } +bool EditorInspector::is_using_folding() { + return use_folding; +} + void EditorInspector::collapse_all_folding() { for (List<EditorInspectorSection *>::Element *E = sections.front(); E; E = E->next()) { diff --git a/editor/editor_inspector.h b/editor/editor_inspector.h index a6b183799f..06426a30e6 100644 --- a/editor/editor_inspector.h +++ b/editor/editor_inspector.h @@ -314,6 +314,7 @@ public: void set_property_selectable(bool p_selectable); void set_use_folding(bool p_enable); + bool is_using_folding(); void collapse_all_folding(); void expand_all_folding(); diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index aedf472b83..72a7ce3534 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -1381,7 +1381,8 @@ void EditorNode::_edit_current() { return; } - bool capitalize = bool(EDITOR_DEF("interface/editor/capitalize_properties", true)); + bool capitalize = bool(EDITOR_GET("interface/inspector/capitalize_properties")); + bool disable_folding = bool(EDITOR_GET("interface/inspector/disable_folding")); bool is_resource = current_obj->is_class("Resource"); bool is_node = current_obj->is_class("Node"); @@ -1437,6 +1438,7 @@ void EditorNode::_edit_current() { if (current_obj->is_class("ScriptEditorDebuggerInspectedObject")) { editable_warning = TTR("This is a remote object so changes to it will not be kept.\nPlease read the documentation relevant to debugging to better understand this workflow."); capitalize = false; + disable_folding = true; } get_inspector()->edit(current_obj); @@ -1449,6 +1451,10 @@ void EditorNode::_edit_current() { get_inspector()->set_enable_capitalize_paths(capitalize); } + if (get_inspector()->is_using_folding() == disable_folding) { + get_inspector()->set_use_folding(!disable_folding); + } + /* Take care of PLUGIN EDITOR */ EditorPlugin *main_plugin = editor_data.get_editor(current_obj); @@ -4637,6 +4643,7 @@ EditorNode::EditorNode() { EDITOR_DEF("interface/scene_tabs/restore_scenes_on_load", false); EDITOR_DEF("interface/scene_tabs/show_thumbnail_on_hover", true); EDITOR_DEF("interface/inspector/capitalize_properties", true); + EDITOR_DEF("interface/inspector/disable_folding", false); EDITOR_DEF("interface/inspector/open_resources_in_new_inspector", false); EDITOR_DEF("run/auto_save/save_before_running", true); diff --git a/editor/editor_themes.cpp b/editor/editor_themes.cpp index 6d9a5c161f..30d439b1c1 100644 --- a/editor/editor_themes.cpp +++ b/editor/editor_themes.cpp @@ -304,8 +304,8 @@ Ref<Theme> create_editor_theme(const Ref<Theme> p_theme) { } break; case 7: { // Solarized (Dark) preset_accent_color = Color::html("#268bd2"); - preset_base_color = Color::html("#002b36"); - preset_contrast = 0.2; + preset_base_color = Color::html("#073642"); + preset_contrast = 0.15; } break; case 8: { // Solarized (Light) preset_accent_color = Color::html("#268bd2"); @@ -1056,7 +1056,7 @@ Ref<Theme> create_editor_theme(const Ref<Theme> p_theme) { const Color string_color = Color::html(dark_theme ? "#ffd942" : "#ffd118").linear_interpolate(mono_color, dark_theme ? 0.5 : 0.3); const Color te_background_color = dark_theme ? background_color : base_color; - const Color completion_background_color = base_color; + const Color completion_background_color = dark_theme ? base_color : background_color; const Color completion_selected_color = alpha1; const Color completion_existing_color = alpha2; const Color completion_scroll_color = alpha1; @@ -1069,7 +1069,7 @@ Ref<Theme> create_editor_theme(const Ref<Theme> p_theme) { const Color selection_color = alpha2; const Color brace_mismatch_color = error_color; const Color current_line_color = alpha1; - const Color line_length_guideline_color = warning_color; + const Color line_length_guideline_color = dark_theme ? base_color : background_color; const Color word_highlighted_color = alpha1; const Color number_color = basetype_color.linear_interpolate(mono_color, dark_theme ? 0.5 : 0.3); const Color function_color = main_color; diff --git a/editor/import/editor_scene_importer_gltf.cpp b/editor/import/editor_scene_importer_gltf.cpp index f4be6e8d59..07a4cf5884 100644 --- a/editor/import/editor_scene_importer_gltf.cpp +++ b/editor/import/editor_scene_importer_gltf.cpp @@ -863,6 +863,7 @@ Error EditorSceneImporterGLTF::_parse_meshes(GLTFState &state) { ERR_FAIL_COND_V(!d.has("primitives"), ERR_PARSE_ERROR); Array primitives = d["primitives"]; + Dictionary extras = d.has("extras") ? (Dictionary)d["extras"] : Dictionary(); for (int j = 0; j < primitives.size(); j++) { @@ -1000,8 +1001,10 @@ Error EditorSceneImporterGLTF::_parse_meshes(GLTFState &state) { Array targets = p["targets"]; if (j == 0) { + Array target_names = extras.has("targetNames") ? (Array)extras["targetNames"] : Array(); for (int k = 0; k < targets.size(); k++) { - mesh.mesh->add_blend_shape(String("morph_") + itos(k)); + String name = k < target_names.size() ? (String)target_names[k] : String("morph_") + itos(k); + mesh.mesh->add_blend_shape(name); } } diff --git a/editor/inspector_dock.cpp b/editor/inspector_dock.cpp index 6c7843273e..0d0b12c911 100644 --- a/editor/inspector_dock.cpp +++ b/editor/inspector_dock.cpp @@ -553,8 +553,8 @@ InspectorDock::InspectorDock(EditorNode *p_editor, EditorData &p_editor_data) { inspector->set_v_size_flags(Control::SIZE_EXPAND_FILL); inspector->set_use_doc_hints(true); inspector->set_hide_script(false); - inspector->set_enable_capitalize_paths(bool(EDITOR_DEF("interface/editor/capitalize_properties", true))); - inspector->set_use_folding(!bool(EDITOR_DEF("interface/editor/disable_inspector_folding", false))); + inspector->set_enable_capitalize_paths(bool(EDITOR_GET("interface/inspector/capitalize_properties"))); + inspector->set_use_folding(!bool(EDITOR_GET("interface/inspector/disable_folding"))); inspector->register_text_enter(search); inspector->set_undo_redo(&editor_data->get_undo_redo()); diff --git a/main/main.cpp b/main/main.cpp index 119d1ee345..2e3c2f41b9 100644 --- a/main/main.cpp +++ b/main/main.cpp @@ -539,6 +539,7 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph } else if (I->get() == "--build-solutions") { // Build the scripting solution such C# auto_build_solutions = true; + editor = true; #endif } else if (I->get() == "--no-window") { // disable window creation, Windows only @@ -1815,9 +1816,6 @@ bool Main::iteration() { } } - if (AudioServer::get_singleton()) - AudioServer::get_singleton()->update(); - idle_process_ticks = OS::get_singleton()->get_ticks_usec() - idle_begin; idle_process_max = MAX(idle_process_ticks, idle_process_max); uint64_t frame_time = OS::get_singleton()->get_ticks_usec() - ticks; diff --git a/modules/gdnative/pluginscript/pluginscript_script.cpp b/modules/gdnative/pluginscript/pluginscript_script.cpp index eb2e7903e5..c3a623e9a1 100644 --- a/modules/gdnative/pluginscript/pluginscript_script.cpp +++ b/modules/gdnative/pluginscript/pluginscript_script.cpp @@ -84,35 +84,20 @@ StringName PluginScript::get_instance_base_type() const { } void PluginScript::update_exports() { -// TODO #ifdef TOOLS_ENABLED -#if 0 ASSERT_SCRIPT_VALID(); - if (/*changed &&*/ placeholders.size()) { //hm :( + if (placeholders.size()) { //update placeholders if any Map<StringName, Variant> propdefvalues; List<PropertyInfo> propinfos; - const String *props = (const String *)pybind_get_prop_list(_py_exposed_class); - for (int i = 0; props[i] != ""; ++i) { - const String propname = props[i]; - pybind_get_prop_default_value(_py_exposed_class, propname.c_str(), (godot_variant *)&propdefvalues[propname]); - pybind_prop_info raw_info; - pybind_get_prop_info(_py_exposed_class, propname.c_str(), &raw_info); - PropertyInfo info; - info.type = (Variant::Type)raw_info.type; - info.name = propname; - info.hint = (PropertyHint)raw_info.hint; - info.hint_string = *(String *)&raw_info.hint_string; - info.usage = raw_info.usage; - propinfos.push_back(info); - } + + get_script_property_list(&propinfos); for (Set<PlaceHolderScriptInstance *>::Element *E = placeholders.front(); E; E = E->next()) { - E->get()->update(propinfos, propdefvalues); + E->get()->update(propinfos, _properties_default_values); } } #endif -#endif } // TODO: rename p_this "p_owner" ? diff --git a/scene/3d/reflection_probe.cpp b/scene/3d/reflection_probe.cpp index 7e3a87cbd4..4d50945062 100644 --- a/scene/3d/reflection_probe.cpp +++ b/scene/3d/reflection_probe.cpp @@ -241,8 +241,8 @@ void ReflectionProbe::_bind_methods() { ADD_PROPERTY(PropertyInfo(Variant::INT, "update_mode", PROPERTY_HINT_ENUM, "Once,Always"), "set_update_mode", "get_update_mode"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "intensity", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_intensity", "get_intensity"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "max_distance", PROPERTY_HINT_EXP_RANGE, "0,16384,0.1,or_greater"), "set_max_distance", "get_max_distance"); - ADD_PROPERTY(PropertyInfo(Variant::VECTOR2, "extents"), "set_extents", "get_extents"); - ADD_PROPERTY(PropertyInfo(Variant::VECTOR2, "origin_offset"), "set_origin_offset", "get_origin_offset"); + ADD_PROPERTY(PropertyInfo(Variant::VECTOR3, "extents"), "set_extents", "get_extents"); + ADD_PROPERTY(PropertyInfo(Variant::VECTOR3, "origin_offset"), "set_origin_offset", "get_origin_offset"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "box_projection"), "set_enable_box_projection", "is_box_projection_enabled"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "enable_shadows"), "set_enable_shadows", "are_shadows_enabled"); ADD_PROPERTY(PropertyInfo(Variant::INT, "cull_mask", PROPERTY_HINT_LAYERS_3D_RENDER), "set_cull_mask", "get_cull_mask"); diff --git a/servers/audio_server.cpp b/servers/audio_server.cpp index b08e41301a..8ee43ddc32 100644 --- a/servers/audio_server.cpp +++ b/servers/audio_server.cpp @@ -939,9 +939,6 @@ void AudioServer::finish() { buses.clear(); } -void AudioServer::update() { -} - /* MISC config */ void AudioServer::lock() { diff --git a/servers/audio_server.h b/servers/audio_server.h index af2668b69e..b7fcd9c093 100644 --- a/servers/audio_server.h +++ b/servers/audio_server.h @@ -273,7 +273,6 @@ public: virtual void init(); virtual void finish(); - virtual void update(); virtual void load_default_bus_layout(); /* MISC config */ |