summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/object/script_language.h6
-rw-r--r--core/object/script_language_extension.cpp7
-rw-r--r--core/object/script_language_extension.h18
-rw-r--r--doc/classes/ScriptLanguageExtension.xml30
-rw-r--r--doc/classes/VehicleBody3D.xml3
-rw-r--r--modules/basis_universal/register_types.cpp4
-rw-r--r--modules/gdscript/gdscript.cpp5
-rw-r--r--modules/gdscript/gdscript.h1
-rw-r--r--modules/gltf/doc_classes/GLTFState.xml11
-rw-r--r--modules/gltf/gltf_state.cpp11
-rw-r--r--modules/gltf/gltf_state.h4
-rw-r--r--modules/mono/csharp_script.cpp5
-rw-r--r--modules/mono/csharp_script.h1
-rw-r--r--scene/gui/text_edit.cpp2
14 files changed, 5 insertions, 103 deletions
diff --git a/core/object/script_language.h b/core/object/script_language.h
index 3ef121a8e7..696c9a94a5 100644
--- a/core/object/script_language.h
+++ b/core/object/script_language.h
@@ -249,7 +249,6 @@ public:
virtual void init() = 0;
virtual String get_type() const = 0;
virtual String get_extension() const = 0;
- virtual Error execute_file(const String &p_path) = 0;
virtual void finish() = 0;
/* EDITOR FUNCTIONS */
@@ -428,11 +427,6 @@ public:
virtual int profiling_get_accumulated_data(ProfilingInfo *p_info_arr, int p_info_max) = 0;
virtual int profiling_get_frame_data(ProfilingInfo *p_info_arr, int p_info_max) = 0;
- virtual void *alloc_instance_binding_data(Object *p_object) { return nullptr; } //optional, not used by all languages
- virtual void free_instance_binding_data(void *p_data) {} //optional, not used by all languages
- virtual void refcount_incremented_instance_binding(Object *p_object) {} //optional, not used by all languages
- virtual bool refcount_decremented_instance_binding(Object *p_object) { return true; } //return true if it can die //optional, not used by all languages
-
virtual void frame();
virtual bool handles_global_class_type(const String &p_type) const { return false; }
diff --git a/core/object/script_language_extension.cpp b/core/object/script_language_extension.cpp
index c7eb32c020..0df9d58334 100644
--- a/core/object/script_language_extension.cpp
+++ b/core/object/script_language_extension.cpp
@@ -84,7 +84,6 @@ void ScriptLanguageExtension::_bind_methods() {
GDVIRTUAL_BIND(_init);
GDVIRTUAL_BIND(_get_type);
GDVIRTUAL_BIND(_get_extension);
- GDVIRTUAL_BIND(_execute_file, "path");
GDVIRTUAL_BIND(_finish);
GDVIRTUAL_BIND(_get_reserved_words);
@@ -144,12 +143,6 @@ void ScriptLanguageExtension::_bind_methods() {
GDVIRTUAL_BIND(_profiling_get_accumulated_data, "info_array", "info_max");
GDVIRTUAL_BIND(_profiling_get_frame_data, "info_array", "info_max");
- GDVIRTUAL_BIND(_alloc_instance_binding_data, "object");
- GDVIRTUAL_BIND(_free_instance_binding_data, "data");
-
- GDVIRTUAL_BIND(_refcount_incremented_instance_binding, "object");
- GDVIRTUAL_BIND(_refcount_decremented_instance_binding, "object");
-
GDVIRTUAL_BIND(_frame);
GDVIRTUAL_BIND(_handles_global_class_type, "type");
diff --git a/core/object/script_language_extension.h b/core/object/script_language_extension.h
index 8e162a1b0f..79cf712119 100644
--- a/core/object/script_language_extension.h
+++ b/core/object/script_language_extension.h
@@ -202,7 +202,6 @@ public:
EXBIND0(init)
EXBIND0RC(String, get_type)
EXBIND0RC(String, get_extension)
- EXBIND1R(Error, execute_file, const String &)
EXBIND0(finish)
/* EDITOR FUNCTIONS */
@@ -596,23 +595,6 @@ public:
return ret;
}
- GDVIRTUAL1R(GDExtensionPtr<void>, _alloc_instance_binding_data, Object *)
-
- virtual void *alloc_instance_binding_data(Object *p_object) override {
- GDExtensionPtr<void> ret = nullptr;
- GDVIRTUAL_REQUIRED_CALL(_alloc_instance_binding_data, p_object, ret);
- return ret.operator void *();
- }
-
- GDVIRTUAL1(_free_instance_binding_data, GDExtensionPtr<void>)
-
- virtual void free_instance_binding_data(void *p_data) override {
- GDVIRTUAL_REQUIRED_CALL(_free_instance_binding_data, p_data);
- }
-
- EXBIND1(refcount_incremented_instance_binding, Object *)
- EXBIND1R(bool, refcount_decremented_instance_binding, Object *)
-
EXBIND0(frame)
EXBIND1RC(bool, handles_global_class_type, const String &)
diff --git a/doc/classes/ScriptLanguageExtension.xml b/doc/classes/ScriptLanguageExtension.xml
index 2d41f8e880..d67fe5d255 100644
--- a/doc/classes/ScriptLanguageExtension.xml
+++ b/doc/classes/ScriptLanguageExtension.xml
@@ -21,12 +21,6 @@
<description>
</description>
</method>
- <method name="_alloc_instance_binding_data" qualifiers="virtual">
- <return type="void*" />
- <param index="0" name="object" type="Object" />
- <description>
- </description>
- </method>
<method name="_auto_indent_code" qualifiers="virtual const">
<return type="String" />
<param index="0" name="code" type="String" />
@@ -118,12 +112,6 @@
<description>
</description>
</method>
- <method name="_execute_file" qualifiers="virtual">
- <return type="int" enum="Error" />
- <param index="0" name="path" type="String" />
- <description>
- </description>
- </method>
<method name="_find_function" qualifiers="virtual const">
<return type="int" />
<param index="0" name="class_name" type="String" />
@@ -141,12 +129,6 @@
<description>
</description>
</method>
- <method name="_free_instance_binding_data" qualifiers="virtual">
- <return type="void" />
- <param index="0" name="data" type="void*" />
- <description>
- </description>
- </method>
<method name="_get_built_in_templates" qualifiers="virtual const">
<return type="Dictionary[]" />
<param index="0" name="object" type="StringName" />
@@ -298,18 +280,6 @@
<description>
</description>
</method>
- <method name="_refcount_decremented_instance_binding" qualifiers="virtual">
- <return type="bool" />
- <param index="0" name="object" type="Object" />
- <description>
- </description>
- </method>
- <method name="_refcount_incremented_instance_binding" qualifiers="virtual">
- <return type="void" />
- <param index="0" name="object" type="Object" />
- <description>
- </description>
- </method>
<method name="_reload_all_scripts" qualifiers="virtual">
<return type="void" />
<description>
diff --git a/doc/classes/VehicleBody3D.xml b/doc/classes/VehicleBody3D.xml
index 9f905c0ec5..6813c88940 100644
--- a/doc/classes/VehicleBody3D.xml
+++ b/doc/classes/VehicleBody3D.xml
@@ -23,7 +23,8 @@
</member>
<member name="mass" type="float" setter="set_mass" getter="get_mass" overrides="RigidBody3D" default="40.0" />
<member name="steering" type="float" setter="set_steering" getter="get_steering" default="0.0">
- The steering angle for the vehicle, in radians. Setting this to a non-zero value will result in the vehicle turning when it's moving. Wheels that have [member VehicleWheel3D.use_as_steering] set to [code]true[/code] will automatically be rotated.
+ The steering angle for the vehicle. Setting this to a non-zero value will result in the vehicle turning when it's moving. Wheels that have [member VehicleWheel3D.use_as_steering] set to [code]true[/code] will automatically be rotated.
+ [b]Note:[/b] This property is edited in the inspector in degrees. In code the property is set in radians.
</member>
</members>
</class>
diff --git a/modules/basis_universal/register_types.cpp b/modules/basis_universal/register_types.cpp
index c5db9b9933..f7bdaf389e 100644
--- a/modules/basis_universal/register_types.cpp
+++ b/modules/basis_universal/register_types.cpp
@@ -74,7 +74,7 @@ static Vector<uint8_t> basis_universal_packer(const Ref<Image> &p_image, Image::
params.m_source_images.push_back(buimg_image);
}
basisu::vector<basisu::image> images;
- for (int32_t mip_map_i = 1; mip_map_i < image->get_mipmap_count(); mip_map_i++) {
+ for (int32_t mip_map_i = 1; mip_map_i <= image->get_mipmap_count(); mip_map_i++) {
Ref<Image> mip_map = image->get_image_from_mipmap(mip_map_i);
Vector<uint8_t> mip_map_vec = mip_map->get_data();
basisu::image buimg_mipmap(mip_map->get_width(), mip_map->get_height());
@@ -247,7 +247,7 @@ static Ref<Image> basis_universal_unpacker_ptr(const uint8_t *p_data, int p_size
dst[i] = 0x00;
}
uint32_t mip_count = Image::get_image_required_mipmaps(info.m_orig_width, info.m_orig_height, imgfmt);
- for (uint32_t level_i = 0; level_i < mip_count; level_i++) {
+ for (uint32_t level_i = 0; level_i <= mip_count; level_i++) {
basist::basisu_image_level_info level;
tr.get_image_level_info(ptr, size, level, 0, level_i);
int ofs = Image::get_image_mipmap_offset(info.m_width, info.m_height, imgfmt, level_i);
diff --git a/modules/gdscript/gdscript.cpp b/modules/gdscript/gdscript.cpp
index 00f8d2817a..b6caefbdb5 100644
--- a/modules/gdscript/gdscript.cpp
+++ b/modules/gdscript/gdscript.cpp
@@ -2027,11 +2027,6 @@ String GDScriptLanguage::get_extension() const {
return "gd";
}
-Error GDScriptLanguage::execute_file(const String &p_path) {
- // ??
- return OK;
-}
-
void GDScriptLanguage::finish() {
if (_call_stack) {
memdelete_arr(_call_stack);
diff --git a/modules/gdscript/gdscript.h b/modules/gdscript/gdscript.h
index 82d04f641c..0117ed40ab 100644
--- a/modules/gdscript/gdscript.h
+++ b/modules/gdscript/gdscript.h
@@ -473,7 +473,6 @@ public:
virtual void init() override;
virtual String get_type() const override;
virtual String get_extension() const override;
- virtual Error execute_file(const String &p_path) override;
virtual void finish() override;
/* EDITOR FUNCTIONS */
diff --git a/modules/gltf/doc_classes/GLTFState.xml b/modules/gltf/doc_classes/GLTFState.xml
index b322c07cec..33b92f37c8 100644
--- a/modules/gltf/doc_classes/GLTFState.xml
+++ b/modules/gltf/doc_classes/GLTFState.xml
@@ -91,11 +91,6 @@
<description>
</description>
</method>
- <method name="get_skeleton_to_node">
- <return type="Dictionary" />
- <description>
- </description>
- </method>
<method name="get_skeletons">
<return type="GLTFSkeleton[]" />
<description>
@@ -196,12 +191,6 @@
<description>
</description>
</method>
- <method name="set_skeleton_to_node">
- <return type="void" />
- <param index="0" name="skeleton_to_node" type="Dictionary" />
- <description>
- </description>
- </method>
<method name="set_skeletons">
<return type="void" />
<param index="0" name="skeletons" type="GLTFSkeleton[]" />
diff --git a/modules/gltf/gltf_state.cpp b/modules/gltf/gltf_state.cpp
index b7b7113a97..b493e498f1 100644
--- a/modules/gltf/gltf_state.cpp
+++ b/modules/gltf/gltf_state.cpp
@@ -82,8 +82,6 @@ void GLTFState::_bind_methods() {
ClassDB::bind_method(D_METHOD("set_unique_animation_names", "unique_animation_names"), &GLTFState::set_unique_animation_names);
ClassDB::bind_method(D_METHOD("get_skeletons"), &GLTFState::get_skeletons);
ClassDB::bind_method(D_METHOD("set_skeletons", "skeletons"), &GLTFState::set_skeletons);
- ClassDB::bind_method(D_METHOD("get_skeleton_to_node"), &GLTFState::get_skeleton_to_node);
- ClassDB::bind_method(D_METHOD("set_skeleton_to_node", "skeleton_to_node"), &GLTFState::set_skeleton_to_node);
ClassDB::bind_method(D_METHOD("get_create_animations"), &GLTFState::get_create_animations);
ClassDB::bind_method(D_METHOD("set_create_animations", "create_animations"), &GLTFState::set_create_animations);
ClassDB::bind_method(D_METHOD("get_animations"), &GLTFState::get_animations);
@@ -117,7 +115,6 @@ void GLTFState::_bind_methods() {
ADD_PROPERTY(PropertyInfo(Variant::ARRAY, "unique_names", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_INTERNAL | PROPERTY_USAGE_EDITOR), "set_unique_names", "get_unique_names"); // Set<String>
ADD_PROPERTY(PropertyInfo(Variant::ARRAY, "unique_animation_names", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_INTERNAL | PROPERTY_USAGE_EDITOR), "set_unique_animation_names", "get_unique_animation_names"); // Set<String>
ADD_PROPERTY(PropertyInfo(Variant::ARRAY, "skeletons", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_INTERNAL | PROPERTY_USAGE_EDITOR), "set_skeletons", "get_skeletons"); // Vector<Ref<GLTFSkeleton>>
- ADD_PROPERTY(PropertyInfo(Variant::DICTIONARY, "skeleton_to_node", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_INTERNAL | PROPERTY_USAGE_EDITOR), "set_skeleton_to_node", "get_skeleton_to_node"); // RBMap<GLTFSkeletonIndex,
ADD_PROPERTY(PropertyInfo(Variant::BOOL, "create_animations"), "set_create_animations", "get_create_animations"); // bool
ADD_PROPERTY(PropertyInfo(Variant::ARRAY, "animations", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_INTERNAL | PROPERTY_USAGE_EDITOR), "set_animations", "get_animations"); // Vector<Ref<GLTFAnimation>>
ADD_PROPERTY(PropertyInfo(Variant::INT, "handle_binary_image", PROPERTY_HINT_ENUM, "Discard All Textures,Extract Textures,Embed As Basis Universal,Embed as Uncompressed", PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_INTERNAL | PROPERTY_USAGE_EDITOR), "set_handle_binary_image", "get_handle_binary_image"); // enum
@@ -315,14 +312,6 @@ void GLTFState::set_skeletons(TypedArray<GLTFSkeleton> p_skeletons) {
GLTFTemplateConvert::set_from_array(skeletons, p_skeletons);
}
-Dictionary GLTFState::get_skeleton_to_node() {
- return GLTFTemplateConvert::to_dict(skeleton_to_node);
-}
-
-void GLTFState::set_skeleton_to_node(Dictionary p_skeleton_to_node) {
- GLTFTemplateConvert::set_from_dict(skeleton_to_node, p_skeleton_to_node);
-}
-
bool GLTFState::get_create_animations() {
return create_animations;
}
diff --git a/modules/gltf/gltf_state.h b/modules/gltf/gltf_state.h
index b6979ca48e..f2036fca1e 100644
--- a/modules/gltf/gltf_state.h
+++ b/modules/gltf/gltf_state.h
@@ -89,7 +89,6 @@ class GLTFState : public Resource {
HashSet<String> unique_animation_names;
Vector<Ref<GLTFSkeleton>> skeletons;
- HashMap<GLTFSkeletonIndex, GLTFNodeIndex> skeleton_to_node;
Vector<Ref<GLTFAnimation>> animations;
HashMap<GLTFNodeIndex, Node *> scene_nodes;
HashMap<GLTFNodeIndex, ImporterMeshInstance3D *> scene_mesh_instances;
@@ -198,9 +197,6 @@ public:
TypedArray<GLTFSkeleton> get_skeletons();
void set_skeletons(TypedArray<GLTFSkeleton> p_skeletons);
- Dictionary get_skeleton_to_node();
- void set_skeleton_to_node(Dictionary p_skeleton_to_node);
-
bool get_create_animations();
void set_create_animations(bool p_create_animations);
diff --git a/modules/mono/csharp_script.cpp b/modules/mono/csharp_script.cpp
index 43d2779e41..872e803b9c 100644
--- a/modules/mono/csharp_script.cpp
+++ b/modules/mono/csharp_script.cpp
@@ -92,11 +92,6 @@ String CSharpLanguage::get_extension() const {
return "cs";
}
-Error CSharpLanguage::execute_file(const String &p_path) {
- // ??
- return OK;
-}
-
void CSharpLanguage::init() {
#ifdef DEBUG_METHODS_ENABLED
if (OS::get_singleton()->get_cmdline_args().find("--class-db-json")) {
diff --git a/modules/mono/csharp_script.h b/modules/mono/csharp_script.h
index 6021555255..02c354f74e 100644
--- a/modules/mono/csharp_script.h
+++ b/modules/mono/csharp_script.h
@@ -413,7 +413,6 @@ public:
/* LANGUAGE FUNCTIONS */
String get_type() const override;
String get_extension() const override;
- Error execute_file(const String &p_path) override;
void init() override;
void finish() override;
diff --git a/scene/gui/text_edit.cpp b/scene/gui/text_edit.cpp
index ebca8296a0..7ab33d5c6c 100644
--- a/scene/gui/text_edit.cpp
+++ b/scene/gui/text_edit.cpp
@@ -1548,7 +1548,7 @@ void TextEdit::_notification(int p_what) {
ime_text = DisplayServer::get_singleton()->ime_get_text();
ime_selection = DisplayServer::get_singleton()->ime_get_selection();
- if (!ime_text.is_empty()) {
+ if (!ime_text.is_empty() && has_selection()) {
delete_selection();
}