summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--core/command_queue_mt.h6
-rw-r--r--core/compressed_translation.h2
-rw-r--r--core/error_macros.h2
-rw-r--r--core/global_constants.cpp2
-rw-r--r--core/io/ip_address.cpp2
-rw-r--r--core/map.h4
-rw-r--r--core/message_queue.cpp2
-rw-r--r--core/pool_allocator.cpp4
-rw-r--r--core/script_debugger_remote.cpp4
-rw-r--r--core/set.h4
-rw-r--r--core/variant.h2
-rw-r--r--core/variant_op.cpp2
-rw-r--r--doc/classes/ConfigFile.xml2
-rw-r--r--doc/classes/File.xml2
-rw-r--r--doc/classes/HTTPClient.xml2
-rw-r--r--doc/classes/Line2D.xml2
-rw-r--r--doc/classes/Sprite.xml2
-rw-r--r--doc/classes/VehicleBody.xml7
-rw-r--r--doc/classes/VehicleWheel.xml16
-rw-r--r--doc/classes/Viewport.xml2
-rw-r--r--doc/classes/VisualServer.xml2
-rw-r--r--drivers/convex_decomp/b2d_decompose.cpp2
-rw-r--r--drivers/dummy/rasterizer_dummy.h2
-rw-r--r--drivers/gles3/rasterizer_canvas_gles3.cpp2
-rw-r--r--drivers/gles3/rasterizer_canvas_gles3.h2
-rw-r--r--drivers/gles3/rasterizer_storage_gles3.cpp2
-rw-r--r--editor/dictionary_property_edit.cpp2
-rw-r--r--editor/editor_file_dialog.cpp2
-rw-r--r--editor/editor_node.cpp4
-rw-r--r--editor/icons/icon_action_copy.svg3
-rw-r--r--editor/icons/icon_action_cut.svg3
-rw-r--r--editor/icons/icon_action_paste.svg3
-rw-r--r--editor/icons/icon_array_mesh.svg2
-rw-r--r--editor/icons/icon_asset_lib.svg4
-rw-r--r--editor/icons/icon_capsule_mesh.svg4
-rw-r--r--editor/icons/icon_cone_twist_joint.svg6
-rw-r--r--editor/icons/icon_cube_mesh.svg4
-rw-r--r--editor/icons/icon_cylinder_mesh.svg4
-rw-r--r--editor/icons/icon_enum.svg3
-rw-r--r--editor/icons/icon_help_search.svg6
-rw-r--r--editor/icons/icon_mesh.svg4
-rw-r--r--editor/icons/icon_mesh_instance.svg4
-rw-r--r--editor/icons/icon_mesh_instance_2d.svg3
-rw-r--r--editor/icons/icon_mesh_library.svg4
-rw-r--r--editor/icons/icon_multi_mesh.svg4
-rw-r--r--editor/icons/icon_multi_mesh_instance.svg4
-rw-r--r--editor/icons/icon_navigation_mesh.svg4
-rw-r--r--editor/icons/icon_navigation_mesh_instance.svg6
-rw-r--r--editor/icons/icon_plane_mesh.svg4
-rw-r--r--editor/icons/icon_prism_mesh.svg4
-rw-r--r--editor/icons/icon_quad_mesh.svg4
-rw-r--r--editor/icons/icon_rayito.svg5
-rw-r--r--editor/icons/icon_reflection_probe.svg6
-rw-r--r--editor/icons/icon_short_cut.svg5
-rw-r--r--editor/icons/icon_skeleton.svg4
-rw-r--r--editor/icons/icon_skeleton_2d.svg3
-rw-r--r--editor/icons/icon_sphere_mesh.svg4
-rw-r--r--editor/icons/icon_timer.svg5
-rw-r--r--editor/icons/icon_tree.svg1
-rw-r--r--editor/import/editor_scene_importer_gltf.cpp3
-rw-r--r--editor/import/resource_importer_csv_translation.cpp2
-rw-r--r--editor/plugins/canvas_item_editor_plugin.cpp6
-rw-r--r--editor/plugins/collision_polygon_editor_plugin.cpp10
-rw-r--r--editor/plugins/skeleton_2d_editor_plugin.cpp115
-rw-r--r--editor/plugins/skeleton_2d_editor_plugin.h55
-rw-r--r--editor/plugins/spatial_editor_plugin.cpp3
-rw-r--r--editor/plugins/spatial_editor_plugin.h3
-rw-r--r--editor/script_editor_debugger.cpp2
-rw-r--r--main/input_default.cpp2
-rw-r--r--methods.py6
-rw-r--r--modules/bullet/bullet_physics_server.cpp2
-rw-r--r--modules/bullet/bullet_physics_server.h2
-rw-r--r--modules/bullet/godot_motion_state.h2
-rw-r--r--modules/bullet/space_bullet.cpp2
-rw-r--r--modules/gdnative/include/pluginscript/godot_pluginscript.h2
-rw-r--r--modules/gdscript/gdscript_compiler.cpp2
-rw-r--r--modules/gdscript/gdscript_parser.cpp4
-rw-r--r--modules/mono/editor/godotsharp_editor.cpp7
-rw-r--r--modules/regex/doc_classes/RegEx.xml4
-rw-r--r--modules/visual_script/visual_script.cpp4
-rw-r--r--modules/visual_script/visual_script_nodes.cpp6
-rw-r--r--modules/websocket/lws_helper.h2
-rw-r--r--platform/android/export/export.cpp4
-rw-r--r--platform/osx/os_osx.mm4
-rw-r--r--platform/uwp/export/export.cpp2
-rw-r--r--platform/windows/detect.py4
-rw-r--r--platform/x11/os_x11.cpp2
-rw-r--r--scene/2d/audio_stream_player_2d.cpp4
-rw-r--r--scene/2d/canvas_item.cpp6
-rw-r--r--scene/2d/canvas_item.h2
-rw-r--r--scene/2d/mesh_instance_2d.cpp2
-rw-r--r--scene/2d/skeleton_2d.cpp210
-rw-r--r--scene/2d/skeleton_2d.h68
-rw-r--r--scene/3d/audio_stream_player_3d.cpp4
-rw-r--r--scene/gui/dialogs.h2
-rw-r--r--scene/gui/file_dialog.cpp8
-rw-r--r--scene/gui/text_edit.cpp4
-rw-r--r--scene/gui/texture_progress.cpp2
-rw-r--r--scene/main/node.cpp2
-rw-r--r--scene/main/node.h2
-rw-r--r--scene/main/scene_tree.cpp2
-rw-r--r--scene/resources/bit_mask.cpp6
-rw-r--r--scene/resources/bit_mask.h2
-rw-r--r--scene/resources/material.cpp6
-rw-r--r--scene/resources/material.h2
-rw-r--r--scene/resources/primitive_meshes.h2
-rw-r--r--scene/resources/style_box.cpp4
-rw-r--r--servers/arvr_server.h2
-rw-r--r--servers/audio_server.cpp4
-rw-r--r--servers/visual/rasterizer.h6
-rw-r--r--servers/visual/visual_server_canvas.cpp19
-rw-r--r--servers/visual/visual_server_canvas.h7
-rw-r--r--servers/visual/visual_server_raster.h5
-rw-r--r--servers/visual/visual_server_wrap_mt.h5
-rw-r--r--servers/visual_server.h6
115 files changed, 665 insertions, 202 deletions
diff --git a/core/command_queue_mt.h b/core/command_queue_mt.h
index cecc9e405d..3942b961d3 100644
--- a/core/command_queue_mt.h
+++ b/core/command_queue_mt.h
@@ -55,7 +55,7 @@
#define _COMMA_11 ,
#define _COMMA_12 ,
-// 1-based comma separed list of ITEMs
+// 1-based comma separated list of ITEMs
#define COMMA_SEP_LIST(ITEM, LENGTH) _COMMA_SEP_LIST_##LENGTH(ITEM)
#define _COMMA_SEP_LIST_12(ITEM) \
_COMMA_SEP_LIST_11(ITEM) \
@@ -95,7 +95,7 @@
ITEM(1)
#define _COMMA_SEP_LIST_0(ITEM)
-// 1-based semicolon separed list of ITEMs
+// 1-based semicolon separated list of ITEMs
#define SEMIC_SEP_LIST(ITEM, LENGTH) _SEMIC_SEP_LIST_##LENGTH(ITEM)
#define _SEMIC_SEP_LIST_12(ITEM) \
_SEMIC_SEP_LIST_11(ITEM); \
@@ -135,7 +135,7 @@
ITEM(1)
#define _SEMIC_SEP_LIST_0(ITEM)
-// 1-based space separed list of ITEMs
+// 1-based space separated list of ITEMs
#define SPACE_SEP_LIST(ITEM, LENGTH) _SPACE_SEP_LIST_##LENGTH(ITEM)
#define _SPACE_SEP_LIST_12(ITEM) \
_SPACE_SEP_LIST_11(ITEM) \
diff --git a/core/compressed_translation.h b/core/compressed_translation.h
index 400fa4491b..ccc47d0bf6 100644
--- a/core/compressed_translation.h
+++ b/core/compressed_translation.h
@@ -38,7 +38,7 @@ class PHashTranslation : public Translation {
GDCLASS(PHashTranslation, Translation);
//this translation uses a sort of modified perfect hash algorithm
- //it requieres hashing strings twice and then does a binary search,
+ //it requires hashing strings twice and then does a binary search,
//so it's slower, but at the same time it has an extreemly high chance
//of catching untranslated strings
diff --git a/core/error_macros.h b/core/error_macros.h
index 1f9164a99b..b8d0c7e0c3 100644
--- a/core/error_macros.h
+++ b/core/error_macros.h
@@ -33,7 +33,7 @@
#include "typedefs.h"
/**
- * Error macros. Unlike exceptions and asserts, these macros try to mantain consistency and stability
+ * Error macros. Unlike exceptions and asserts, these macros try to maintain consistency and stability
* inside the code. It is recommended to always return processable data, so in case of an error, the
* engine can stay working well.
* In most cases, bugs and/or invalid data are not fatal and should never allow a perfectly running application
diff --git a/core/global_constants.cpp b/core/global_constants.cpp
index a24bf03c9a..04810afe73 100644
--- a/core/global_constants.cpp
+++ b/core/global_constants.cpp
@@ -580,7 +580,7 @@ void register_global_constants() {
BIND_GLOBAL_ENUM_CONSTANT_CUSTOM("TYPE_COLOR_ARRAY", Variant::POOL_COLOR_ARRAY);
BIND_GLOBAL_ENUM_CONSTANT_CUSTOM("TYPE_MAX", Variant::VARIANT_MAX);
- //comparation
+ //comparison
BIND_GLOBAL_ENUM_CONSTANT_CUSTOM("OP_EQUAL", Variant::OP_EQUAL);
BIND_GLOBAL_ENUM_CONSTANT_CUSTOM("OP_NOT_EQUAL", Variant::OP_NOT_EQUAL);
BIND_GLOBAL_ENUM_CONSTANT_CUSTOM("OP_LESS", Variant::OP_LESS);
diff --git a/core/io/ip_address.cpp b/core/io/ip_address.cpp
index 7261363ad6..6d979d10eb 100644
--- a/core/io/ip_address.cpp
+++ b/core/io/ip_address.cpp
@@ -211,7 +211,7 @@ IP_Address::IP_Address(const String &p_string) {
clear();
if (p_string == "*") {
- // Wildcard (not a vaild IP)
+ // Wildcard (not a valid IP)
wildcard = true;
} else if (p_string.find(":") >= 0) {
diff --git a/core/map.h b/core/map.h
index 5ff269c26b..700d4b8693 100644
--- a/core/map.h
+++ b/core/map.h
@@ -197,7 +197,7 @@ private:
if (node->right != _data._nil) {
node = node->right;
- while (node->left != _data._nil) { /* returns the minium of the right subtree of node */
+ while (node->left != _data._nil) { /* returns the minimum of the right subtree of node */
node = node->left;
}
return node;
@@ -219,7 +219,7 @@ private:
if (node->left != _data._nil) {
node = node->left;
- while (node->right != _data._nil) { /* returns the minium of the left subtree of node */
+ while (node->right != _data._nil) { /* returns the minimum of the left subtree of node */
node = node->right;
}
return node;
diff --git a/core/message_queue.cpp b/core/message_queue.cpp
index 3ceafe1a30..25ee6eafae 100644
--- a/core/message_queue.cpp
+++ b/core/message_queue.cpp
@@ -278,7 +278,7 @@ void MessageQueue::flush() {
while (read_pos < buffer_end) {
- //lock on each interation, so a call can re-add itself to the message queue
+ //lock on each iteration, so a call can re-add itself to the message queue
Message *message = (Message *)&buffer[read_pos];
diff --git a/core/pool_allocator.cpp b/core/pool_allocator.cpp
index d81e1912bf..017586b92a 100644
--- a/core/pool_allocator.cpp
+++ b/core/pool_allocator.cpp
@@ -90,7 +90,7 @@ bool PoolAllocator::find_hole(EntryArrayPos *p_pos, int p_for_size) {
int hole_size = entry.pos - prev_entry_end_pos;
- /* detemine if what we want fits in that hole */
+ /* determine if what we want fits in that hole */
if (hole_size >= p_for_size) {
*p_pos = i;
return true;
@@ -100,7 +100,7 @@ bool PoolAllocator::find_hole(EntryArrayPos *p_pos, int p_for_size) {
prev_entry_end_pos = entry_end(entry);
}
- /* No holes between entrys, check at the end..*/
+ /* No holes between entries, check at the end..*/
if ((pool_size - prev_entry_end_pos) >= p_for_size) {
*p_pos = entry_count;
diff --git a/core/script_debugger_remote.cpp b/core/script_debugger_remote.cpp
index 41071ace5d..632285f48d 100644
--- a/core/script_debugger_remote.cpp
+++ b/core/script_debugger_remote.cpp
@@ -1016,11 +1016,11 @@ void ScriptDebuggerRemote::add_profiling_frame_data(const StringName &p_name, co
}
void ScriptDebuggerRemote::profiling_start() {
- //ignores this, uses it via connnection
+ //ignores this, uses it via connection
}
void ScriptDebuggerRemote::profiling_end() {
- //ignores this, uses it via connnection
+ //ignores this, uses it via connection
}
void ScriptDebuggerRemote::profiling_set_frame_times(float p_frame_time, float p_idle_time, float p_physics_time, float p_physics_frame_time) {
diff --git a/core/set.h b/core/set.h
index 4f17c953b1..d79dd81644 100644
--- a/core/set.h
+++ b/core/set.h
@@ -185,7 +185,7 @@ private:
if (node->right != _data._nil) {
node = node->right;
- while (node->left != _data._nil) { /* returns the minium of the right subtree of node */
+ while (node->left != _data._nil) { /* returns the minimum of the right subtree of node */
node = node->left;
}
return node;
@@ -207,7 +207,7 @@ private:
if (node->left != _data._nil) {
node = node->left;
- while (node->right != _data._nil) { /* returns the minium of the left subtree of node */
+ while (node->right != _data._nil) { /* returns the minimum of the left subtree of node */
node = node->right;
}
return node;
diff --git a/core/variant.h b/core/variant.h
index 51ee8ea9d1..0a4afada5b 100644
--- a/core/variant.h
+++ b/core/variant.h
@@ -293,7 +293,7 @@ public:
// If this changes the table in variant_op must be updated
enum Operator {
- //comparation
+ //comparison
OP_EQUAL,
OP_NOT_EQUAL,
OP_LESS,
diff --git a/core/variant_op.cpp b/core/variant_op.cpp
index e46fac77ee..e4eea4ed48 100644
--- a/core/variant_op.cpp
+++ b/core/variant_op.cpp
@@ -147,7 +147,7 @@ Variant::operator bool() const {
return booleanize();
}
-// We consider all unitialized or empty types to be false based on the type's
+// We consider all uninitialized or empty types to be false based on the type's
// zeroiness.
bool Variant::booleanize() const {
return !is_zero();
diff --git a/doc/classes/ConfigFile.xml b/doc/classes/ConfigFile.xml
index da86554380..b46e96c2a0 100644
--- a/doc/classes/ConfigFile.xml
+++ b/doc/classes/ConfigFile.xml
@@ -4,7 +4,7 @@
Helper class to handle INI-style files.
</brief_description>
<description>
- This helper class can be used to store [Variant] values on the filesystem using INI-style formatting. The stored values are indentified by a section and a key:
+ This helper class can be used to store [Variant] values on the filesystem using INI-style formatting. The stored values are identified by a section and a key:
[codeblock]
[section]
some_key=42
diff --git a/doc/classes/File.xml b/doc/classes/File.xml
index baa7045e8c..4074c236eb 100644
--- a/doc/classes/File.xml
+++ b/doc/classes/File.xml
@@ -380,7 +380,7 @@
<members>
<member name="endian_swap" type="bool" setter="set_endian_swap" getter="get_endian_swap">
If [code]true[/code] the file's endianness is swapped. Use this if you're dealing with files written in big endian machines.
- Note that this is about the file format, not CPU type. This is always reseted to [code]false[/code] whenever you open the file.
+ Note that this is about the file format, not CPU type. This is always reset to [code]false[/code] whenever you open the file.
</member>
</members>
<constants>
diff --git a/doc/classes/HTTPClient.xml b/doc/classes/HTTPClient.xml
index 1c518fb6f5..2dcfb6c7d9 100644
--- a/doc/classes/HTTPClient.xml
+++ b/doc/classes/HTTPClient.xml
@@ -384,7 +384,7 @@
HTTP status code [code]429 Too Many Requests[/code]. The user has sent too many requests in a given amount of time (see "rate limiting"). Back off and increase time between requests or try again later.
</constant>
<constant name="RESPONSE_REQUEST_HEADER_FIELDS_TOO_LARGE" value="431" enum="ResponseCode">
- HTTP status code [code]431 Rquest Header Fields Too Large[/code]. The server is unwilling to process the request because its header fields are too large. The request MAY be resubmitted after reducing the size of the request header fields.
+ HTTP status code [code]431 Request Header Fields Too Large[/code]. The server is unwilling to process the request because its header fields are too large. The request MAY be resubmitted after reducing the size of the request header fields.
</constant>
<constant name="RESPONSE_UNAVAILABLE_FOR_LEGAL_REASONS" value="451" enum="ResponseCode">
HTTP status code [code]451 Response Unavailable For Legal Reasons[/code]. The server is denying access to the resource as a consequence of a legal demand.
diff --git a/doc/classes/Line2D.xml b/doc/classes/Line2D.xml
index fd45c8a986..89f43fc95d 100644
--- a/doc/classes/Line2D.xml
+++ b/doc/classes/Line2D.xml
@@ -53,7 +53,7 @@
<argument index="1" name="position" type="Vector2">
</argument>
<description>
- Overwites the position in point [code]i[/code] with the supplied [code]position[/code].
+ Overwrites the position in point [code]i[/code] with the supplied [code]position[/code].
</description>
</method>
</methods>
diff --git a/doc/classes/Sprite.xml b/doc/classes/Sprite.xml
index d60e1dbe52..a3423a0739 100644
--- a/doc/classes/Sprite.xml
+++ b/doc/classes/Sprite.xml
@@ -26,7 +26,7 @@
Current frame to display from sprite sheet. [member vframes] or [member hframes] must be greater than 1.
</member>
<member name="hframes" type="int" setter="set_hframes" getter="get_hframes">
- The number of collumns in the sprite sheet.
+ The number of columns in the sprite sheet.
</member>
<member name="normal_map" type="Texture" setter="set_normal_map" getter="get_normal_map">
The normal map gives depth to the Sprite.
diff --git a/doc/classes/VehicleBody.xml b/doc/classes/VehicleBody.xml
index f5ec98ea04..873490c0c8 100644
--- a/doc/classes/VehicleBody.xml
+++ b/doc/classes/VehicleBody.xml
@@ -1,8 +1,11 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VehicleBody" inherits="RigidBody" category="Core" version="3.1-dev">
<brief_description>
+ Physics body that simulates the behaviour of a car.
</brief_description>
<description>
+ This nodes implements all the physics logic needed to simulate a car. It is based on the raycast vehicle system commonly found in physics engines. You will need to add a [CollisionShape] for the main body of your vehicle and add [VehicleWheel] nodes for the wheels. You should also add a [MeshInstance] to this node for the 3D model of your car but this model should not include meshes for the wheels. You should control the vehicle by using the [member brake], [member engine_force], and [member steering] properties and not change the position or orientation of this node directly.
+ Note that the origin point of your VehicleBody will determine the center of gravity of your vehicle so it is better to keep this low and move the [CollisionShape] and [MeshInstance] upwards.
</description>
<tutorials>
</tutorials>
@@ -12,10 +15,14 @@
</methods>
<members>
<member name="brake" type="float" setter="set_brake" getter="get_brake">
+ Slows down the vehicle by applying a braking force. The vehicle is only slowed down if the wheels are in contact with a surface. The force you need to apply to adequately slow down your vehicle depends on the [member RigidBody.mass] of the vehicle. For a vehicle with a mass set to 1000, try a value in the 25 - 30 range for hard braking.
</member>
<member name="engine_force" type="float" setter="set_engine_force" getter="get_engine_force">
+ Accelerates the vehicle by applying an engine force. The vehicle is only speed up if the wheels that have [member VehicleWheel.set_use_as_traction] set to true and are in contact with a surface. The [member RigidBody.mass] of the vehicle has an effect on the acceleration of the vehicle. For a vehicle with a mass set to 1000, try a value in the 25 - 50 range for acceleration. Note that the simulation does not take the effect of gears into account, you will need to add logic for this if you wish to simulate gears.
+ A negative value will result in the vehicle reversing.
</member>
<member name="steering" type="float" setter="set_steering" getter="get_steering">
+ 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 VehicleWheel.set_use_as_steering] set to true will automatically be rotated.
</member>
</members>
<constants>
diff --git a/doc/classes/VehicleWheel.xml b/doc/classes/VehicleWheel.xml
index 16b2424b6e..ccc4b964c1 100644
--- a/doc/classes/VehicleWheel.xml
+++ b/doc/classes/VehicleWheel.xml
@@ -1,8 +1,10 @@
<?xml version="1.0" encoding="UTF-8" ?>
<class name="VehicleWheel" inherits="Spatial" category="Core" version="3.1-dev">
<brief_description>
+ Physics object that simulates the behaviour of a wheel.
</brief_description>
<description>
+ This node needs to be used as a child node of [VehicleBody] and simulates the behaviour of one of its wheels. This node also acts as a collider to detect if the wheel is touching a surface.
</description>
<tutorials>
</tutorials>
@@ -13,37 +15,51 @@
<return type="float">
</return>
<description>
+ Returns a value between 0.0 and 1.0 that indicates whether this wheel is skidding. 0.0 is not skidding, 1.0 means the wheel has lost grip.
</description>
</method>
<method name="is_in_contact" qualifiers="const">
<return type="bool">
</return>
<description>
+ Returns true if this wheel is in contact with a surface.
</description>
</method>
</methods>
<members>
<member name="damping_compression" type="float" setter="set_damping_compression" getter="get_damping_compression">
+ The damping applied to the spring when the spring is being compressed. This value should be between 0.0 (no damping) and 1.0. A value of 0.0 means the car will keep bouncing as the spring keeps its energy. A good value for this is around 0.3 for a normal car, 0.5 for a race car.
</member>
<member name="damping_relaxation" type="float" setter="set_damping_relaxation" getter="get_damping_relaxation">
+ The damping applied to the spring when relaxing. This value should be between 0.0 (no damping) and 1.0. This value should always be slighly higher then the [member damping_compression] property. For a [member damping_compression] value of 0.3, try a relaxation value of 0.5
</member>
<member name="suspension_max_force" type="float" setter="set_suspension_max_force" getter="get_suspension_max_force">
+ The maximum force the spring can resist. This value should be higher then a quarter of the [member RigidBody.mass] of the [VehicleBody] or the spring will not carry the weight of the vehicle. Good results are often obtained by a value that is about 3x to 4x this number.
</member>
<member name="suspension_stiffness" type="float" setter="set_suspension_stiffness" getter="get_suspension_stiffness">
+ This value defines the stiffness of the suspension. Use a value lower then 50 for an offroad car, a value between 50 and 100 for a race car and try something around 200 for something like a Formula 1 car.
</member>
<member name="suspension_travel" type="float" setter="set_suspension_travel" getter="get_suspension_travel">
+ This is the distance the suspension can travel. As Godots measures are in meters keep this setting relatively low. Try a value between 0.1 and 0.3 depending on the type of car .
</member>
<member name="use_as_steering" type="bool" setter="set_use_as_steering" getter="is_used_as_steering">
+ If true this wheel will be turned when the car steers.
</member>
<member name="use_as_traction" type="bool" setter="set_use_as_traction" getter="is_used_as_traction">
+ If true this wheel transfers engine force to the ground to propel the vehicle forward.
</member>
<member name="wheel_friction_slip" type="float" setter="set_friction_slip" getter="get_friction_slip">
+ This determines how much grip this wheel has. It is combined with the friction setting of the surface the wheel is in contact with. 0.0 means no grip, 1.0 is normal grip. For a drift car setup, try setting the grip of the rear wheels slightly lower then the front wheels, or use a lower value to simulate tire wear.
+ It's best to set this to 1.0 when starting out.
</member>
<member name="wheel_radius" type="float" setter="set_radius" getter="get_radius">
+ The radius of the wheel in meters.
</member>
<member name="wheel_rest_length" type="float" setter="set_suspension_rest_length" getter="get_suspension_rest_length">
+ This is the distance in meters the wheel is lowered from its origin point. Don't set this to 0.0 and move the wheel into position, instead move the origin point of your wheel (the gizmo in Godot) to the position the wheel will take when bottoming out, then use the rest lenght to move the wheel down to the position it should be in when the car is in rest.
</member>
<member name="wheel_roll_influence" type="float" setter="set_roll_influence" getter="get_roll_influence">
+ This value effects the roll of your vehicle. If set to 0.0 for all wheels your vehicle will be prone to rolling over while a value of 1.0 will resist body roll.
</member>
</members>
<constants>
diff --git a/doc/classes/Viewport.xml b/doc/classes/Viewport.xml
index b3568321ad..6aac66269d 100644
--- a/doc/classes/Viewport.xml
+++ b/doc/classes/Viewport.xml
@@ -123,7 +123,7 @@
<return type="bool">
</return>
<description>
- Get the enabled status of the size strech override set with [method set_size_override_stretch].
+ Get the enabled status of the size stretch override set with [method set_size_override_stretch].
</description>
</method>
<method name="set_attach_to_screen_rect">
diff --git a/doc/classes/VisualServer.xml b/doc/classes/VisualServer.xml
index 204a4a6704..505a3d1474 100644
--- a/doc/classes/VisualServer.xml
+++ b/doc/classes/VisualServer.xml
@@ -1274,7 +1274,7 @@
<return type="void">
</return>
<description>
- Syncronizes threads.
+ Synchronizes threads.
</description>
</method>
<method name="free_rid">
diff --git a/drivers/convex_decomp/b2d_decompose.cpp b/drivers/convex_decomp/b2d_decompose.cpp
index d1f7a4d3c3..14456144a6 100644
--- a/drivers/convex_decomp/b2d_decompose.cpp
+++ b/drivers/convex_decomp/b2d_decompose.cpp
@@ -94,7 +94,7 @@ static Vector<Vector<Vector2> > _b2d_decompose(const Vector<Vector2> &p_polygon)
float32 dot = dx0 * dx1 + dy0 * dy1;
if (fabs(cross) < b2_angularSlop && dot > 0) {
//Angle too close, split the triangle across from this point.
- //This is guaranteed to result in two triangles that satify
+ //This is guaranteed to result in two triangles that satisfy
//the tolerance (one of the angles is 90 degrees)
float32 dx2 = curr.x[lower] - curr.x[upper];
float32 dy2 = curr.y[lower] - curr.y[upper];
diff --git a/drivers/dummy/rasterizer_dummy.h b/drivers/dummy/rasterizer_dummy.h
index 4a7b8fd3a4..5836f5a700 100644
--- a/drivers/dummy/rasterizer_dummy.h
+++ b/drivers/dummy/rasterizer_dummy.h
@@ -619,7 +619,7 @@ public:
void canvas_begin(){};
void canvas_end(){};
- void canvas_render_items(Item *p_item_list, int p_z, const Color &p_modulate, Light *p_light){};
+ void canvas_render_items(Item *p_item_list, int p_z, const Color &p_modulate, Light *p_light,const Transform2D& p_transform){};
void canvas_debug_viewport_shadows(Light *p_lights_with_shadow){};
void canvas_light_shadow_buffer_update(RID p_buffer, const Transform2D &p_light_xform, int p_light_mask, float p_near, float p_far, LightOccluderInstance *p_occluders, CameraMatrix *p_xform_cache) {}
diff --git a/drivers/gles3/rasterizer_canvas_gles3.cpp b/drivers/gles3/rasterizer_canvas_gles3.cpp
index d4b6c8577e..85fd565f5b 100644
--- a/drivers/gles3/rasterizer_canvas_gles3.cpp
+++ b/drivers/gles3/rasterizer_canvas_gles3.cpp
@@ -1042,7 +1042,7 @@ void RasterizerCanvasGLES3::_copy_texscreen(const Rect2 &p_rect) {
glEnable(GL_BLEND);
}
-void RasterizerCanvasGLES3::canvas_render_items(Item *p_item_list, int p_z, const Color &p_modulate, Light *p_light) {
+void RasterizerCanvasGLES3::canvas_render_items(Item *p_item_list, int p_z, const Color &p_modulate, Light *p_light, const Transform2D &p_transform) {
Item *current_clip = NULL;
RasterizerStorageGLES3::Shader *shader_cache = NULL;
diff --git a/drivers/gles3/rasterizer_canvas_gles3.h b/drivers/gles3/rasterizer_canvas_gles3.h
index 9f1a9466f1..1dc17f98d5 100644
--- a/drivers/gles3/rasterizer_canvas_gles3.h
+++ b/drivers/gles3/rasterizer_canvas_gles3.h
@@ -129,7 +129,7 @@ public:
_FORCE_INLINE_ void _canvas_item_render_commands(Item *p_item, Item *current_clip, bool &reclip);
_FORCE_INLINE_ void _copy_texscreen(const Rect2 &p_rect);
- virtual void canvas_render_items(Item *p_item_list, int p_z, const Color &p_modulate, Light *p_light);
+ virtual void canvas_render_items(Item *p_item_list, int p_z, const Color &p_modulate, Light *p_light, const Transform2D &p_transform);
virtual void canvas_debug_viewport_shadows(Light *p_lights_with_shadow);
virtual void canvas_light_shadow_buffer_update(RID p_buffer, const Transform2D &p_light_xform, int p_light_mask, float p_near, float p_far, LightOccluderInstance *p_occluders, CameraMatrix *p_xform_cache);
diff --git a/drivers/gles3/rasterizer_storage_gles3.cpp b/drivers/gles3/rasterizer_storage_gles3.cpp
index 0fc095a868..a287dca1ed 100644
--- a/drivers/gles3/rasterizer_storage_gles3.cpp
+++ b/drivers/gles3/rasterizer_storage_gles3.cpp
@@ -908,7 +908,7 @@ Ref<Image> RasterizerStorageGLES3::texture_get_data(RID p_texture, VS::CubeMapSi
return Ref<Image>(img);
#else
- ERR_EXPLAIN("Sorry, It's not posible to obtain images back in OpenGL ES");
+ ERR_EXPLAIN("Sorry, It's not possible to obtain images back in OpenGL ES");
return Ref<Image>();
#endif
}
diff --git a/editor/dictionary_property_edit.cpp b/editor/dictionary_property_edit.cpp
index 4c0ad59385..a87edfd00d 100644
--- a/editor/dictionary_property_edit.cpp
+++ b/editor/dictionary_property_edit.cpp
@@ -41,7 +41,7 @@ void DictionaryPropertyEdit::_notif_changev(const String &p_v) {
void DictionaryPropertyEdit::_set_key(const Variant &p_old_key, const Variant &p_new_key) {
- // TODO: Set key of a dictionary is not allowd yet
+ // TODO: Set key of a dictionary is not allowed yet
return;
}
diff --git a/editor/editor_file_dialog.cpp b/editor/editor_file_dialog.cpp
index 22b33cc98f..c52f25e66b 100644
--- a/editor/editor_file_dialog.cpp
+++ b/editor/editor_file_dialog.cpp
@@ -551,7 +551,7 @@ void EditorFileDialog::_item_list_item_rmb_selected(int p_item, const Vector2 &p
}
if (single_item_selected) {
- item_menu->add_icon_item(get_icon("CopyNodePath", "EditorIcons"), TTR("Copy Path"), ITEM_MENU_COPY_PATH);
+ item_menu->add_icon_item(get_icon("ActionCopy", "EditorIcons"), TTR("Copy Path"), ITEM_MENU_COPY_PATH);
}
if (allow_delete) {
item_menu->add_icon_item(get_icon("Remove", "EditorIcons"), TTR("Delete"), ITEM_MENU_DELETE, KEY_DELETE);
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp
index 3ef6d65ab4..8132575479 100644
--- a/editor/editor_node.cpp
+++ b/editor/editor_node.cpp
@@ -99,6 +99,7 @@
#include "editor/plugins/script_text_editor.h"
#include "editor/plugins/shader_editor_plugin.h"
#include "editor/plugins/shader_graph_editor_plugin.h"
+#include "editor/plugins/skeleton_2d_editor_plugin.h"
#include "editor/plugins/spatial_editor_plugin.h"
#include "editor/plugins/sprite_editor_plugin.h"
#include "editor/plugins/sprite_frames_editor_plugin.h"
@@ -2908,7 +2909,7 @@ void EditorNode::_set_main_scene_state(Dictionary p_state, Node *p_for_scene) {
if (p_state.has("editor_index")) {
int index = p_state["editor_index"];
- if (current < 2) { //if currently in spatial/2d, only switch to spatial/2d. if curently in script, stay there
+ if (current < 2) { //if currently in spatial/2d, only switch to spatial/2d. if currently in script, stay there
if (index < 2 || !get_edited_scene()) {
_editor_select(index);
}
@@ -5673,6 +5674,7 @@ EditorNode::EditorNode() {
add_editor_plugin(memnew(MeshLibraryEditorPlugin(this)));
add_editor_plugin(memnew(StyleBoxEditorPlugin(this)));
add_editor_plugin(memnew(SpriteEditorPlugin(this)));
+ add_editor_plugin(memnew(Skeleton2DEditorPlugin(this)));
add_editor_plugin(memnew(ParticlesEditorPlugin(this)));
add_editor_plugin(memnew(ResourcePreloaderEditorPlugin(this)));
add_editor_plugin(memnew(ItemListEditorPlugin(this)));
diff --git a/editor/icons/icon_action_copy.svg b/editor/icons/icon_action_copy.svg
new file mode 100644
index 0000000000..d5da233bc9
--- /dev/null
+++ b/editor/icons/icon_action_copy.svg
@@ -0,0 +1,3 @@
+<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
+<path d="m2 1c-0.554 0-1 0.446-1 1v9c0 0.554 0.446 1 1 1h1v-9h9v-1c0-0.554-0.446-1-1-1h-9zm3 3c-0.554 0-1 0.446-1 1v9c0 0.554 0.446 1 1 1h9c0.554 0 1-0.446 1-1v-9c0-0.554-0.446-1-1-1h-9zm1 2h7v7h-7v-7z" fill="#e0e0e0"/>
+</svg>
diff --git a/editor/icons/icon_action_cut.svg b/editor/icons/icon_action_cut.svg
new file mode 100644
index 0000000000..776ca3a4c4
--- /dev/null
+++ b/editor/icons/icon_action_cut.svg
@@ -0,0 +1,3 @@
+<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
+<path d="m3.6348 0.50977c-2.9641 2.866 0.53553 8.9289 2.7676 8.7949l0.44141 0.76562-0.56445 0.97852a3 3 0 0 0 -2.2793 -1.0488 3 3 0 0 0 -3 3 3 3 0 0 0 3 3 3 3 0 0 0 2.5938 -1.502l0.0039062 0.001953 1.4023-2.4277 1.4023 2.4277 0.0019531-0.001953a3 3 0 0 0 2.5957 1.502 3 3 0 0 0 3 -3 3 3 0 0 0 -3 -3 3 3 0 0 0 -2.2773 1.0527l-0.56641-0.98242 0.44141-0.76562c2.2321 0.13397 5.7317-5.9289 2.7676-8.7949l-4.3652 7.5605-4.3652-7.5605zm0.36523 11.49a1 1 0 0 1 1 1 1 1 0 0 1 -0.12305 0.47852l-0.011719 0.021484a1 1 0 0 1 -0.86523 0.5 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1zm8 0a1 1 0 0 1 1 1 1 1 0 0 1 -1 1 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1z" fill="#e0e0e0"/>
+</svg>
diff --git a/editor/icons/icon_action_paste.svg b/editor/icons/icon_action_paste.svg
new file mode 100644
index 0000000000..b71e5531df
--- /dev/null
+++ b/editor/icons/icon_action_paste.svg
@@ -0,0 +1,3 @@
+<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
+<path d="m8 1c-1.3045 0-2.4033 0.8372-2.8164 2h-3.1836c-0.554 0-1 0.446-1 1v10c0 0.554 0.446 1 1 1h12c0.554 0 1-0.446 1-1v-10c0-0.554-0.446-1-1-1h-3.1836c-0.41312-1.1628-1.5119-2-2.8164-2zm0 2a1 1 0 0 1 1 1 1 1 0 0 1 -1 1 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1zm-5 2h2v2h6v-2h2v8h-10v-8z" fill="#e0e0e0"/>
+</svg>
diff --git a/editor/icons/icon_array_mesh.svg b/editor/icons/icon_array_mesh.svg
index 867fc95b0c..7c086e1a44 100644
--- a/editor/icons/icon_array_mesh.svg
+++ b/editor/icons/icon_array_mesh.svg
@@ -1,3 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<path d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 2 2 2 2 0 0 0 2 -2 2 2 0 0 0 -2 -2zm10 0a2 2 0 0 0 -2 2 2 2 0 0 0 2 2 2 2 0 0 0 2 -2 2 2 0 0 0 -2 -2zm-2 7v3h-3v2h3v3h2v-3h3v-2h-3v-3h-2zm-8 3a2 2 0 0 0 -2 2 2 2 0 0 0 2 2 2 2 0 0 0 2 -2 2 2 0 0 0 -2 -2z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#ffd684" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-east-asian:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
+<path d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 2 2 2 2 0 0 0 2 -2 2 2 0 0 0 -2 -2zm10 0a2 2 0 0 0 -2 2 2 2 0 0 0 2 2 2 2 0 0 0 2 -2 2 2 0 0 0 -2 -2zm-2 7v3h-3v2h3v3h2v-3h3v-2h-3v-3h-2zm-8 3a2 2 0 0 0 -2 2 2 2 0 0 0 2 2 2 2 0 0 0 2 -2 2 2 0 0 0 -2 -2z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_asset_lib.svg b/editor/icons/icon_asset_lib.svg
index fcd670817d..1348c491fc 100644
--- a/editor/icons/icon_asset_lib.svg
+++ b/editor/icons/icon_asset_lib.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m8 1c-1.6569 0-3 1.3431-3 3v2h-4v7c0 1.108 0.89199 2 2 2h10c1.108 0 2-0.89199 2-2v-7h-4v-2c0-1.6569-1.3431-3-3-3zm0 2c0.55228 0 1 0.44772 1 1v2h-2v-2c0-0.55228 0.44772-1 1-1z" fill="#e0e0e0"/>
-</g>
+<path d="m8 1c-1.6569 0-3 1.3431-3 3v2h-4v7c0 1.108 0.89199 2 2 2h10c1.108 0 2-0.89199 2-2v-7h-4v-2c0-1.6569-1.3431-3-3-3zm0 2c0.55228 0 1 0.44772 1 1v2h-2v-2c0-0.55228 0.44772-1 1-1z" fill="#e0e0e0"/>
</svg>
diff --git a/editor/icons/icon_capsule_mesh.svg b/editor/icons/icon_capsule_mesh.svg
index bc736200a4..c375e6adfb 100644
--- a/editor/icons/icon_capsule_mesh.svg
+++ b/editor/icons/icon_capsule_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path d="m8 1037.4c-2.7527 0-5 2.2419-5 4.9903v4.0175c0 2.7484 2.2473 4.9922 5 4.9922 2.7527 0 5-2.2438 5-4.9922v-4.0175c0-2.7484-2.2473-4.9903-5-4.9903zm-1.0059 2.1264v4.8576c-0.66556-0.1047-1.2973-0.372-1.9941-0.6618v-1.3222c0-1.3474 0.79838-2.4648 1.9941-2.8736zm2.0118 0c1.1957 0.4088 1.9941 1.5262 1.9941 2.8736v1.3451c-0.68406 0.3054-1.3142 0.5732-1.9941 0.6663zm-4.0059 6.334c0.67836 0.2231 1.3126 0.447 1.9941 0.5264v2.8848c-1.1957-0.4092-1.9941-1.5242-1.9941-2.8716zm6 0.03v0.5094c0 1.3474-0.79838 2.4619-1.9941 2.8711v-2.8711c0.68606-0.068 1.3207-0.2828 1.9941-0.5094z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#ffd684" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-east-asian:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
-</g>
+<path d="m8 1c-2.7527 0-5 2.2419-5 4.9903v4.0175c0 2.7484 2.2473 4.9922 5 4.9922 2.7527 0 5-2.2438 5-4.9922v-4.0175c0-2.7484-2.2473-4.9903-5-4.9903zm-1.0059 2.1264v4.8576c-0.66556-0.1047-1.2973-0.372-1.9941-0.6618v-1.3222c0-1.3474 0.79838-2.4648 1.9941-2.8736zm2.0118 0c1.1957 0.4088 1.9941 1.5262 1.9941 2.8736v1.3451c-0.68406 0.3054-1.3142 0.5732-1.9941 0.6663zm-4.0059 6.334c0.67836 0.2231 1.3126 0.447 1.9941 0.5264v2.8848c-1.1957-0.4092-1.9941-1.5242-1.9941-2.8716zm6 0.03v0.5094c0 1.3474-0.79838 2.4619-1.9941 2.8711v-2.8711c0.68606-0.068 1.3207-0.2828 1.9941-0.5094z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_cone_twist_joint.svg b/editor/icons/icon_cone_twist_joint.svg
index c9d92d6537..8d869fa1d5 100644
--- a/editor/icons/icon_cone_twist_joint.svg
+++ b/editor/icons/icon_cone_twist_joint.svg
@@ -1,7 +1,5 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)" fill="none" stroke="#fc9c9c" stroke-linecap="round" stroke-width="2">
-<path transform="translate(0 1036.4)" d="m8 2l-6 9a6 3 0 0 0 3 2.5977 6 3 0 0 0 6 0 6 3 0 0 0 3 -2.5977l-6-9z" stroke-linejoin="round"/>
-<ellipse cx="8" cy="1047.4" rx="6" ry="3" stroke-linejoin="round"/>
-<path d="m8 1039.4v8"/>
+<g transform="translate(0 -1036.4)">
+<path transform="translate(0 1036.4)" d="m7.9824 1a1.0001 1.0001 0 0 0 -0.81445 0.44531l-4.7012 7.0527c-0.80117 0.58197-1.3801 1.3563-1.4492 2.3145a1.0001 1.0001 0 0 0 -0.017578 0.1875c0 0.21449 0.033976 0.41628 0.082031 0.61328 0.0071983 0.028314 0.015306 0.055972 0.023438 0.083985 0.053631 0.19149 0.1274 0.37452 0.2207 0.54883 0.19678 0.36764 0.47105 0.69651 0.80273 0.98633 0.007988 0.007025 0.013442 0.016473 0.021484 0.023437 0.016953 0.014679 0.03747 0.026532 0.054688 0.041016 0.10299 0.086112 0.21259 0.16531 0.32422 0.24414 0.23883 0.16992 0.49083 0.33075 0.76953 0.4707 0.0025295 0.00127 0.0052799 0.002638 0.0078125 0.003906 0.001313 6.58e-4 0.0025928 0.001296 0.0039063 0.001953 0.0085785 0.00429 0.018732 0.007456 0.027344 0.011719 0.26499 0.13103 0.55174 0.24596 0.84961 0.35156 0.10487 0.037634 0.21202 0.071147 0.32031 0.10547 0.072945 0.022902 0.1402 0.050715 0.21484 0.072266 0.16777 0.04843 0.34161 0.086385 0.51367 0.12695 0.093562 0.021905 0.18185 0.048745 0.27734 0.068359 0.010733 0.002205 0.022447 0.003684 0.033203 0.00586 0.34623 0.071177 0.69974 0.12196 1.0566 0.16211 0.057889 0.006228 0.11544 0.01213 0.17383 0.017578 0.81052 0.079498 1.6348 0.079498 2.4453 0 0.058387-0.005448 0.11594-0.01135 0.17383-0.017578 0.3569-0.040146 0.71041-0.090932 1.0566-0.16211 0.010948-0.002251 0.022269-0.003578 0.033203-0.00586 0.095491-0.019614 0.18378-0.046454 0.27734-0.068359 0.17206-0.040568 0.3459-0.078523 0.51367-0.12695 0.074642-0.021551 0.1419-0.049364 0.21484-0.072266 0.10829-0.034322 0.21544-0.067835 0.32031-0.10547 0.29787-0.1056 0.58462-0.22053 0.84961-0.35156 0.009951-0.00492 0.021348-0.008715 0.03125-0.013672 0.002626-0.001315 0.005189-0.002588 0.007813-0.003906 0.2787-0.13995 0.5307-0.30078 0.76953-0.4707 0.11163-0.07883 0.22123-0.15803 0.32422-0.24414 0.017218-0.014484 0.037734-0.026337 0.054687-0.041016 0.008042-0.006964 0.013497-0.016412 0.021485-0.023437 0.33169-0.28982 0.60596-0.61869 0.80273-0.98633 0.093299-0.17431 0.16707-0.35733 0.2207-0.54883 0.008132-0.028013 0.016239-0.055671 0.023438-0.083985 0.048055-0.197 0.082031-0.39879 0.082031-0.61328a1.0001 1.0001 0 0 0 -0.017578 -0.18164 1.0001 1.0001 0 0 0 -0.001953 -0.017578c-0.073081-0.95265-0.64941-1.7232-1.4473-2.3027l-4.7012-7.0527a1.0001 1.0001 0 0 0 -0.84961 -0.44531zm-0.98242 4.3027v1.7461c-0.43911 0.033461-0.86366 0.087835-1.2734 0.16406l1.2734-1.9102zm2 0l1.2734 1.9102c-0.40978-0.076228-0.83432-0.1306-1.2734-0.16406v-1.7461zm-2 3.748v1.9492a1.0001 1.0001 0 1 0 2 0v-1.9492c1.1126 0.10487 2.0951 0.37277 2.7949 0.72266 0.12146 0.060728 0.20622 0.12218 0.30664 0.18359l0.80078 1.2012c-0.032965 0.14677-0.089654 0.30658-0.30469 0.51758-0.051464 0.049149-0.10034 0.098137-0.16406 0.14844-0.045193 0.035312-0.091373 0.070148-0.14258 0.10547-0.11245 0.07827-0.24511 0.15838-0.39062 0.23633-0.075428 0.040204-0.1553 0.078371-0.23828 0.11719-0.16195 0.075482-0.33452 0.14662-0.52148 0.21289-0.070588 0.025324-0.14454 0.048409-0.21875 0.072265-0.23425 0.074473-0.48077 0.14392-0.74414 0.20117-0.021343 0.004579-0.041038 0.011189-0.0625 0.015625-0.2559 0.05368-0.53101 0.090517-0.80859 0.125-0.856 0.10229-1.7573 0.10229-2.6133 0-0.27759-0.034483-0.5527-0.07132-0.80859-0.125-0.021462-0.004436-0.041156-0.011046-0.0625-0.015625-0.26337-0.057254-0.50989-0.1267-0.74414-0.20117-0.074211-0.023856-0.14816-0.046941-0.21875-0.072265-0.18697-0.066266-0.35954-0.13741-0.52148-0.21289-0.082979-0.038816-0.16285-0.076983-0.23828-0.11719-0.14552-0.077951-0.27818-0.15806-0.39062-0.23633-0.051205-0.035321-0.097386-0.070157-0.14258-0.10547-0.06372-0.050301-0.1126-0.099289-0.16406-0.14844-0.21503-0.21099-0.27173-0.37081-0.30469-0.51758l0.80078-1.2012c0.10043-0.061415 0.18518-0.12287 0.30664-0.18359 0.69978-0.34989 1.6823-0.61778 2.7949-0.72266z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#fc9c9c" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
</g>
</svg>
diff --git a/editor/icons/icon_cube_mesh.svg b/editor/icons/icon_cube_mesh.svg
index 45275216ab..d1897dd710 100644
--- a/editor/icons/icon_cube_mesh.svg
+++ b/editor/icons/icon_cube_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 14.999999 14.999999" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1037.4)">
-<path d="m7.5 1038.2-6.5625 3.2804v6.772l6.5625 3.2804 6.5625-3.2804v-6.772zm0 1.9831 3.6926 1.8463-3.6926 1.8463-3.6926-1.8463zm-4.7889 3.2804 3.9022 1.9502v3.6944l-3.9022-1.952zm9.5779 0v3.6926l-3.9022 1.952v-3.6944z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#ffd684" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-east-asian:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
-</g>
+<path transform="scale(.9375)" d="m8 0.88867-7 3.5v7.2227l7 3.5 7-3.5v-7.2227zm0 2.1152 3.9395 1.9707-3.9395 1.9688-3.9395-1.9688zm-5 3.5527 4 2v3.9414l-4-2.002zm10 0v3.9395l-4 2.002v-3.9414z" fill="#ffd684" stroke-width="1.0667"/>
</svg>
diff --git a/editor/icons/icon_cylinder_mesh.svg b/editor/icons/icon_cylinder_mesh.svg
index 92a93ec220..21b5fc144b 100644
--- a/editor/icons/icon_cylinder_mesh.svg
+++ b/editor/icons/icon_cylinder_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 14.999999 14.999999" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1037.4)">
-<path transform="matrix(.9375 0 0 .9375 0 1037.4)" d="m8 1c-1.7469 0-3.328 0.22648-4.5586 0.63672-0.61528 0.20512-1.1471 0.45187-1.5898 0.80078s-0.85156 0.88101-0.85156 1.5625v8c0 0.68149 0.40884 1.2155 0.85156 1.5645s0.97457 0.59577 1.5898 0.80078c1.2306 0.41024 2.8117 0.63477 4.5586 0.63477s3.328-0.22453 4.5586-0.63477c0.61527-0.20501 1.1471-0.45187 1.5898-0.80078 0.44272-0.34891 0.85156-0.88296 0.85156-1.5645v-8c0-0.68149-0.40884-1.2136-0.85156-1.5625-0.44272-0.34891-0.97457-0.59566-1.5898-0.80078-1.2306-0.41024-2.8117-0.63672-4.5586-0.63672zm0 2c1.5668 0 2.9867 0.22145 3.9277 0.53516 0.46368 0.15456 0.80138 0.33741 0.96875 0.4668-0.16752 0.12928-0.50546 0.3105-0.96875 0.46484-0.94102 0.31371-2.361 0.5332-3.9277 0.5332s-2.9867-0.2195-3.9277-0.5332c-0.46329-0.15435-0.80123-0.33556-0.96875-0.46484 0.16737-0.12939 0.50507-0.31224 0.96875-0.4668 0.94102-0.31371 2.361-0.53516 3.9277-0.53516zm-5 3.1875c0.1468 0.059071 0.2835 0.12512 0.44141 0.17773 1.2306 0.41024 2.8117 0.63477 4.5586 0.63477s3.328-0.22453 4.5586-0.63477c0.15791-0.052617 0.29461-0.11866 0.44141-0.17773v5.8125c-0.16752 0.12928-0.60898 0.31245-1.0723 0.4668-0.94102 0.31371-2.361 0.5332-3.9277 0.5332s-2.9867-0.2195-3.9277-0.5332c-0.46329-0.15435-0.90474-0.33752-1.0723-0.4668z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#ffd684" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-east-asian:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
-</g>
+<path d="m7.5 0.9375c-1.6377 0-3.12 0.2123-4.2737 0.5969-0.57682 0.1923-1.0754 0.4237-1.4905 0.7508-0.41505 0.3271-0.79834 0.8259-0.79834 1.4648v7.5c0 0.6389 0.38329 1.1396 0.79834 1.4667 0.41505 0.3271 0.91366 0.5585 1.4905 0.7507 1.1536 0.3846 2.6359 0.5951 4.2737 0.5951s3.12-0.2105 4.2737-0.5951c0.57682-0.1922 1.0754-0.4236 1.4905-0.7507 0.41505-0.3271 0.79834-0.8278 0.79834-1.4667v-7.5c0-0.6389-0.38329-1.1377-0.79834-1.4648-0.41505-0.3271-0.91366-0.5585-1.4905-0.7508-1.1536-0.3846-2.6359-0.5969-4.2737-0.5969zm0 1.875c1.4689 0 2.8 0.2076 3.6823 0.5017 0.4347 0.1449 0.7513 0.3163 0.9082 0.4376-0.15705 0.1212-0.47387 0.2911-0.9082 0.4358-0.88221 0.2941-2.2134 0.4999-3.6823 0.4999s-2.8-0.2058-3.6823-0.4999c-0.43433-0.1447-0.75115-0.3146-0.9082-0.4358 0.15691-0.1213 0.47351-0.2927 0.9082-0.4376 0.88221-0.2941 2.2134-0.5017 3.6823-0.5017zm-4.6875 2.9883c0.13762 0.055 0.26578 0.1173 0.41382 0.1666 1.1536 0.3846 2.6359 0.5951 4.2737 0.5951s3.12-0.2105 4.2737-0.5951c0.14804-0.049 0.2762-0.1112 0.41382-0.1666v5.4492c-0.15705 0.1212-0.57092 0.2929-1.0052 0.4376-0.88221 0.2941-2.2134 0.4999-3.6823 0.4999s-2.8-0.2058-3.6823-0.4999c-0.43433-0.1447-0.8482-0.3164-1.0052-0.4376z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_enum.svg b/editor/icons/icon_enum.svg
new file mode 100644
index 0000000000..e9c3fbbd2e
--- /dev/null
+++ b/editor/icons/icon_enum.svg
@@ -0,0 +1,3 @@
+<svg width="16" height="12" version="1.1" viewBox="0 0 16 12" xmlns="http://www.w3.org/2000/svg">
+<path d="m3 2c-0.5304 8.01e-5 -1.0391 0.21085-1.4141 0.58594-0.37509 0.37501-0.58586 0.88366-0.58594 1.4141v1c-0.2652 4.01e-5 -0.51953 0.10542-0.70703 0.29297-0.18755 0.18751-0.29293 0.44183-0.29297 0.70703 4.0076e-5 0.2652 0.10542 0.51953 0.29297 0.70703 0.18751 0.18755 0.44183 0.29293 0.70703 0.29297v1c8.01e-5 0.5304 0.21085 1.0391 0.58594 1.4141 0.37501 0.37509 0.88366 0.58586 1.4141 0.58594h1v-2h-1v-4h1v-2zm3 0v8h4v-2h-2v-1h2v-2h-2v-1h2v-2zm6 0v2h1v4h-1v2h1c0.5304-8.03e-5 1.0391-0.21085 1.4141-0.58594 0.37509-0.37501 0.58586-0.88366 0.58594-1.4141v-1c0.2652-4.01e-5 0.51953-0.10542 0.70703-0.29297 0.18755-0.18751 0.29293-0.44183 0.29297-0.70703-4e-5 -0.2652-0.10542-0.51953-0.29297-0.70703-0.1875-0.18755-0.44183-0.29293-0.70703-0.29297v-1c-8e-5 -0.5304-0.21085-1.0391-0.58594-1.4141-0.37501-0.37509-0.88366-0.58586-1.4141-0.58594z" fill="#e0e0e0"/>
+</svg>
diff --git a/editor/icons/icon_help_search.svg b/editor/icons/icon_help_search.svg
index c0768ea5ed..8e4f97d781 100644
--- a/editor/icons/icon_help_search.svg
+++ b/editor/icons/icon_help_search.svg
@@ -1,7 +1,5 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)" stroke-width="2">
-<path transform="translate(0 1036.4)" d="m0 10v6h2c1.6569 0 3-1.3431 3-3s-1.3431-3-3-3zm5 3c0 1.6569 1.3431 3 3 3s3-1.3431 3-3-1.3431-3-3-3-3 1.3431-3 3zm6 0c0 1.6569 1.3431 3 3 3h1v-2h-1c-0.55228-1e-5 -0.99999-0.44772-1-1 1e-5 -0.55228 0.44772-0.99999 1-1h1v-2h-1c-1.6569 0-3 1.3431-3 3zm-9-1c0.55228 0 1 0.44772 1 1s-0.44772 1-1 1zm6 0c0.55228 1e-5 0.99999 0.44772 1 1-9.6e-6 0.55228-0.44772 0.99999-1 1-0.55228-1e-5 -0.99999-0.44772-1-1 9.6e-6 -0.55228 0.44772-0.99999 1-1z" fill="#e0e0e0" stroke-linecap="round" stroke-linejoin="round" stroke-opacity=".32549"/>
-<path d="m9 1036.4a4 4 0 0 0 -4 4 4 4 0 0 0 4 4 4 4 0 0 0 4 -4 4 4 0 0 0 -4 -4zm0 2a2 2 0 0 1 2 2 2 2 0 0 1 -2 2 2 2 0 0 1 -2 -2 2 2 0 0 1 2 -2z" fill="#e0e0e0" stroke-linecap="round" stroke-linejoin="round" stroke-opacity=".32549"/>
-<path d="m7 1042.4-3 3" fill="none" stroke="#e0e0e0"/>
+<g transform="translate(0 -1036.4)">
+<path transform="translate(0 1036.4)" d="m9 0a4 4 0 0 0 -4 4 4 4 0 0 0 0.55859 2.0273l-2.2656 2.2656 1.4141 1.4141 2.2656-2.2656a4 4 0 0 0 2.0273 0.55859 4 4 0 0 0 4 -4 4 4 0 0 0 -4 -4zm0 2a2 2 0 0 1 2 2 2 2 0 0 1 -2 2 2 2 0 0 1 -2 -2 2 2 0 0 1 2 -2zm-9 8v6h2c1.6569 0 3-1.3431 3-3s-1.3431-3-3-3h-2zm5 3c0 1.6569 1.3431 3 3 3s3-1.3431 3-3-1.3431-3-3-3-3 1.3431-3 3zm6 0c0 1.6569 1.3431 3 3 3h1v-2h-1c-0.55228-1e-5 -0.99999-0.44772-1-1 1e-5 -0.55228 0.44772-0.99999 1-1h1v-2h-1c-1.6569 0-3 1.3431-3 3zm-9-1c0.55228 0 1 0.44772 1 1s-0.44772 1-1 1v-2zm6 0c0.55228 1e-5 0.99999 0.44772 1 1-9.6e-6 0.55228-0.44772 0.99999-1 1-0.55228-1e-5 -0.99999-0.44772-1-1 9.6e-6 -0.55228 0.44772-0.99999 1-1z" fill="#e0e0e0" stroke-linecap="round" stroke-linejoin="round" stroke-opacity=".32549" stroke-width="2"/>
</g>
</svg>
diff --git a/editor/icons/icon_mesh.svg b/editor/icons/icon_mesh.svg
index d90dc14b5b..f96efb0430 100644
--- a/editor/icons/icon_mesh.svg
+++ b/editor/icons/icon_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h6.541a2 2 0 0 0 1.7285 1 2 2 0 0 0 2 -2 2 2 0 0 0 -1.0312 -1.75h0.03125v-6.5215a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm2.4141 3h5.8574a2 2 0 0 0 0.72852 0.73047v5.8555l-6.5859-6.5859zm-1.4141 1.4141l6.5859 6.5859h-5.8574a2 2 0 0 0 -0.72852 -0.73047v-5.8555z" fill="#ffd684"/>
-</g>
+<path d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h6.541a2 2 0 0 0 1.7285 1 2 2 0 0 0 2 -2 2 2 0 0 0 -1.0312 -1.75h0.03125v-6.5215a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm2.4141 3h5.8574a2 2 0 0 0 0.72852 0.73047v5.8555l-6.5859-6.5859zm-1.4141 1.4141l6.5859 6.5859h-5.8574a2 2 0 0 0 -0.72852 -0.73047v-5.8555z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_mesh_instance.svg b/editor/icons/icon_mesh_instance.svg
index 3342a3e06d..2860cf6889 100644
--- a/editor/icons/icon_mesh_instance.svg
+++ b/editor/icons/icon_mesh_instance.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h6.541a2 2 0 0 0 1.7285 1 2 2 0 0 0 2 -2 2 2 0 0 0 -1.0312 -1.75h0.03125v-6.5215a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm2.4141 3h5.8574a2 2 0 0 0 0.72852 0.73047v5.8555l-6.5859-6.5859zm-1.4141 1.4141l6.5859 6.5859h-5.8574a2 2 0 0 0 -0.72852 -0.73047v-5.8555z" fill="#fc9c9c" fill-opacity=".99608"/>
-</g>
+<path d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h6.541a2 2 0 0 0 1.7285 1 2 2 0 0 0 2 -2 2 2 0 0 0 -1.0312 -1.75h0.03125v-6.5215a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm2.4141 3h5.8574a2 2 0 0 0 0.72852 0.73047v5.8555l-6.5859-6.5859zm-1.4141 1.4141l6.5859 6.5859h-5.8574a2 2 0 0 0 -0.72852 -0.73047v-5.8555z" fill="#fc9c9c" fill-opacity=".99608"/>
</svg>
diff --git a/editor/icons/icon_mesh_instance_2d.svg b/editor/icons/icon_mesh_instance_2d.svg
new file mode 100644
index 0000000000..051547b524
--- /dev/null
+++ b/editor/icons/icon_mesh_instance_2d.svg
@@ -0,0 +1,3 @@
+<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
+<path d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h6.541a2 2 0 0 0 1.7285 1 2 2 0 0 0 2 -2 2 2 0 0 0 -1.0312 -1.75h0.03125v-6.5215a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm2.4141 3h5.8574a2 2 0 0 0 0.72852 0.73047v5.8555l-6.5859-6.5859zm-1.4141 1.4141l6.5859 6.5859h-5.8574a2 2 0 0 0 -0.72852 -0.73047v-5.8555z" fill="#a5b7f3"/>
+</svg>
diff --git a/editor/icons/icon_mesh_library.svg b/editor/icons/icon_mesh_library.svg
index 3bef2df33c..3683650e2e 100644
--- a/editor/icons/icon_mesh_library.svg
+++ b/editor/icons/icon_mesh_library.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h2.2695v-2h-2.2715a2 2 0 0 0 -0.72852 -0.73047v-5.8555l3 3v-0.41406a2.0002 2.0002 0 0 1 0.80859 -1.6055l-2.3945-2.3945h5.8574a2 2 0 0 0 0.72852 0.73047v1.2695a2.0002 2.0002 0 0 1 0.99805 0.27148 2.0002 2.0002 0 0 1 1.002 -0.27148v-1.2715a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm6 7v1 5 1h5c0.55228 0 1-0.4477 1-1v-5c0-0.5523-0.44772-1-1-1v4l-1-1-1 1v-4h-3z" fill="#ffd684"/>
-</g>
+<path d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h2.2695v-2h-2.2715a2 2 0 0 0 -0.72852 -0.73047v-5.8555l3 3v-0.41406a2.0002 2.0002 0 0 1 0.80859 -1.6055l-2.3945-2.3945h5.8574a2 2 0 0 0 0.72852 0.73047v1.2695a2.0002 2.0002 0 0 1 0.99805 0.27148 2.0002 2.0002 0 0 1 1.002 -0.27148v-1.2715a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm6 7v1 5 1h5c0.55228 0 1-0.4477 1-1v-5c0-0.5523-0.44772-1-1-1v4l-1-1-1 1v-4h-3z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_multi_mesh.svg b/editor/icons/icon_multi_mesh.svg
index 2582ba9e51..522561bb28 100644
--- a/editor/icons/icon_multi_mesh.svg
+++ b/editor/icons/icon_multi_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m3 1c-1.1046 0-2 0.89543-2 2 5.649e-4 0.71397 0.38169 1.3735 1 1.7305v6.541c-0.61771 0.35663-0.99874 1.0152-1 1.7285 0 1.1046 0.89543 2 2 2 0.71397-5.65e-4 1.3735-0.38169 1.7305-1h1.2695v-2h-1.2715c-0.17478-0.30301-0.42598-0.55488-0.72852-0.73047v-5.8555l3.5859 3.5859h1.4141v-1.4141l-3.5859-3.5859h5.8574c0.17532 0.30158 0.42647 0.55205 0.72852 0.72656v1.2734h2v-1.2695c0.61831-0.35698 0.99944-1.0165 1-1.7305 0-1.1046-0.89543-2-2-2-0.71397 5.648e-4 -1.3735 0.38169-1.7305 1h-6.541c-0.35663-0.61771-1.0152-0.99874-1.7285-1zm8 7v3h-3v2h3v3h2v-3h3v-2h-3v-3z" fill="#ffd684"/>
-</g>
+<path d="m3 1c-1.1046 0-2 0.89543-2 2 5.649e-4 0.71397 0.38169 1.3735 1 1.7305v6.541c-0.61771 0.35663-0.99874 1.0152-1 1.7285 0 1.1046 0.89543 2 2 2 0.71397-5.65e-4 1.3735-0.38169 1.7305-1h1.2695v-2h-1.2715c-0.17478-0.30301-0.42598-0.55488-0.72852-0.73047v-5.8555l3.5859 3.5859h1.4141v-1.4141l-3.5859-3.5859h5.8574c0.17532 0.30158 0.42647 0.55205 0.72852 0.72656v1.2734h2v-1.2695c0.61831-0.35698 0.99944-1.0165 1-1.7305 0-1.1046-0.89543-2-2-2-0.71397 5.648e-4 -1.3735 0.38169-1.7305 1h-6.541c-0.35663-0.61771-1.0152-0.99874-1.7285-1zm8 7v3h-3v2h3v3h2v-3h3v-2h-3v-3z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_multi_mesh_instance.svg b/editor/icons/icon_multi_mesh_instance.svg
index 0140f1137b..f873ac2bf3 100644
--- a/editor/icons/icon_multi_mesh_instance.svg
+++ b/editor/icons/icon_multi_mesh_instance.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m3 1c-1.1046 0-2 0.89543-2 2 5.649e-4 0.71397 0.38169 1.3735 1 1.7305v6.541c-0.61771 0.35663-0.99874 1.0152-1 1.7285 0 1.1046 0.89543 2 2 2 0.71397-5.65e-4 1.3735-0.38169 1.7305-1h1.2695v-2h-1.2715c-0.17478-0.30301-0.42598-0.55488-0.72852-0.73047v-5.8555l3.5859 3.5859h1.4141v-1.4141l-3.5859-3.5859h5.8574c0.17532 0.30158 0.42647 0.55205 0.72852 0.72656v1.2734h2v-1.2695c0.61831-0.35698 0.99944-1.0165 1-1.7305 0-1.1046-0.89543-2-2-2-0.71397 5.648e-4 -1.3735 0.38169-1.7305 1h-6.541c-0.35663-0.61771-1.0152-0.99874-1.7285-1zm8 7v3h-3v2h3v3h2v-3h3v-2h-3v-3z" fill="#fc9c9c" fill-opacity=".99608"/>
-</g>
+<path d="m3 1c-1.1046 0-2 0.89543-2 2 5.649e-4 0.71397 0.38169 1.3735 1 1.7305v6.541c-0.61771 0.35663-0.99874 1.0152-1 1.7285 0 1.1046 0.89543 2 2 2 0.71397-5.65e-4 1.3735-0.38169 1.7305-1h1.2695v-2h-1.2715c-0.17478-0.30301-0.42598-0.55488-0.72852-0.73047v-5.8555l3.5859 3.5859h1.4141v-1.4141l-3.5859-3.5859h5.8574c0.17532 0.30158 0.42647 0.55205 0.72852 0.72656v1.2734h2v-1.2695c0.61831-0.35698 0.99944-1.0165 1-1.7305 0-1.1046-0.89543-2-2-2-0.71397 5.648e-4 -1.3735 0.38169-1.7305 1h-6.541c-0.35663-0.61771-1.0152-0.99874-1.7285-1zm8 7v3h-3v2h3v3h2v-3h3v-2h-3v-3z" fill="#fc9c9c" fill-opacity=".99608"/>
</svg>
diff --git a/editor/icons/icon_navigation_mesh.svg b/editor/icons/icon_navigation_mesh.svg
index cc04e06b51..831d1a0769 100644
--- a/editor/icons/icon_navigation_mesh.svg
+++ b/editor/icons/icon_navigation_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h2.5078l0.75-2h-3.2598a2 2 0 0 0 -0.72852 -0.73047v-5.8555l4.6973 4.6973 0.77148-2.0566-4.0547-4.0547h5.8574a2 2 0 0 0 0.72852 0.73047v0.27148a2.0002 2.0002 0 0 1 0.023438 0 2.0002 2.0002 0 0 1 1.8496 1.2969l0.12695 0.33789v-1.9082a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm9 6l-3 8 3-2 3 2-3-8z" fill="#ffd684"/>
-</g>
+<path d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h2.5078l0.75-2h-3.2598a2 2 0 0 0 -0.72852 -0.73047v-5.8555l4.6973 4.6973 0.77148-2.0566-4.0547-4.0547h5.8574a2 2 0 0 0 0.72852 0.73047v0.27148a2.0002 2.0002 0 0 1 0.023438 0 2.0002 2.0002 0 0 1 1.8496 1.2969l0.12695 0.33789v-1.9082a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm9 6l-3 8 3-2 3 2-3-8z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_navigation_mesh_instance.svg b/editor/icons/icon_navigation_mesh_instance.svg
index 85c6292290..e6636807af 100644
--- a/editor/icons/icon_navigation_mesh_instance.svg
+++ b/editor/icons/icon_navigation_mesh_instance.svg
@@ -1,7 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)" fill="#fc9c9c" fill-opacity=".99608">
-<path transform="translate(0 1036.4)" d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h2.5078l0.75-2h-3.2598a2 2 0 0 0 -0.72852 -0.73047v-5.8555l4.6973 4.6973 0.77148-2.0566-4.0547-4.0547h5.8574a2 2 0 0 0 0.72852 0.73047v0.27148a2.0002 2.0002 0 0 1 0.023438 0 2.0002 2.0002 0 0 1 1.8496 1.2969l0.12695 0.33789v-1.9082a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm9 6l-3 8 3-2 3 2-3-8z"/>
-<rect x="12" y="1040.4" width="2" height="1"/>
-<rect x="12" y="1040.4" width="2" height="1"/>
-</g>
+<path d="m3 1a2 2 0 0 0 -2 2 2 2 0 0 0 1 1.7305v6.541a2 2 0 0 0 -1 1.7285 2 2 0 0 0 2 2 2 2 0 0 0 1.7305 -1h2.5078l0.75-2h-3.2598a2 2 0 0 0 -0.72852 -0.73047v-5.8555l4.6973 4.6973 0.77148-2.0566-4.0547-4.0547h5.8574a2 2 0 0 0 0.72852 0.73047v0.27148a2.0002 2.0002 0 0 1 0.023438 0 2.0002 2.0002 0 0 1 1.8496 1.2969l0.12695 0.33789v-1.9082a2 2 0 0 0 1 -1.7285 2 2 0 0 0 -2 -2 2 2 0 0 0 -1.7305 1h-6.541a2 2 0 0 0 -1.7285 -1zm9 6l-3 8 3-2 3 2-3-8z" fill="#fc9c9c" fill-opacity=".99608"/>
</svg>
diff --git a/editor/icons/icon_plane_mesh.svg b/editor/icons/icon_plane_mesh.svg
index 7a5c8f4354..dae7b02da5 100644
--- a/editor/icons/icon_plane_mesh.svg
+++ b/editor/icons/icon_plane_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path d="m2 1048.4h12l-3-8h-6z" fill="none" stroke="#ffd684" stroke-linejoin="round" stroke-width="2"/>
-</g>
+<path d="m2 12h12l-3-8h-6z" fill="none" stroke="#ffd684" stroke-linejoin="round" stroke-width="2"/>
</svg>
diff --git a/editor/icons/icon_prism_mesh.svg b/editor/icons/icon_prism_mesh.svg
index 68dfa117f7..8f8feb2eb6 100644
--- a/editor/icons/icon_prism_mesh.svg
+++ b/editor/icons/icon_prism_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m7.9824 1.002a1.0001 1.0001 0 0 0 -0.81445 0.44336l-5.9727 8.9609-0.027344 0.039062a1 1 0 0 0 -0.0625 0.10742 1 1 0 0 0 0.44727 1.3418l6 3a1.0001 1.0001 0 0 0 0.89453 0l6-3a1 1 0 0 0 0.44726 -1.3418 1 1 0 0 0 -0.0625 -0.10742l-6-9a1.0001 1.0001 0 0 0 -0.84961 -0.44336zm-0.98242 4.3008v7.0801l-3.5391-1.7715 3.5391-5.3086zm2 0l3.5391 5.3086-3.5391 1.7715v-7.0801z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#ffd684" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="filter-blend-mode:normal;filter-gaussianBlur-deviation:0;font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-east-asian:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
-</g>
+<path d="m7.9824 1.002a1.0001 1.0001 0 0 0 -0.81445 0.44336l-5.9727 8.9609-0.027344 0.03906a1 1 0 0 0 -0.0625 0.10742 1 1 0 0 0 0.44727 1.3418l6 3a1.0001 1.0001 0 0 0 0.89453 0l6-3a1 1 0 0 0 0.44726 -1.3418 1 1 0 0 0 -0.0625 -0.10742l-6-9a1.0001 1.0001 0 0 0 -0.84961 -0.44336zm-0.98242 4.3008v7.0801l-3.5391-1.7715zm2 0 3.5391 5.3086l-3.5391 1.7715z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#ffd684" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
</svg>
diff --git a/editor/icons/icon_quad_mesh.svg b/editor/icons/icon_quad_mesh.svg
index bf7b593e9e..40a07b36f7 100644
--- a/editor/icons/icon_quad_mesh.svg
+++ b/editor/icons/icon_quad_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path d="m15 1037.4v14h-14v-14zm-2 2h-8.5859l8.5859 8.5859zm-10 1.4141v8.5859h8.5859z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#ffd684" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-east-asian:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
-</g>
+<path d="m15 1v14h-14v-14zm-2 2h-8.5859l8.5859 8.5859zm-10 1.4141v8.5859h8.5859z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_rayito.svg b/editor/icons/icon_rayito.svg
index e1891e783a..937a5cc4d7 100644
--- a/editor/icons/icon_rayito.svg
+++ b/editor/icons/icon_rayito.svg
@@ -1,6 +1,5 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)" fill="#ffd684">
-<rect transform="matrix(1 0 -.14142 .98995 0 0)" x="152.19" y="1047.9" width="7" height="7.0711"/>
-<path d="m6 1043.4h8l-9 8z"/>
+<g transform="translate(0 -1036.4)">
+<path transform="translate(0 1036.4)" d="m4 1l-1 7h2.875l-0.875 7 9-8h-3.8574l0.85742-6h-7z" fill="#ffd684"/>
</g>
</svg>
diff --git a/editor/icons/icon_reflection_probe.svg b/editor/icons/icon_reflection_probe.svg
index 0a7f537737..e0f1572317 100644
--- a/editor/icons/icon_reflection_probe.svg
+++ b/editor/icons/icon_reflection_probe.svg
@@ -1,7 +1,5 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)" fill="none" stroke="#fc9c9c" stroke-linejoin="round" stroke-opacity=".99608" stroke-width="2">
-<path d="m2 1045.4v5h12v-4"/>
-<path d="m2 1040.4 5 6 7-7"/>
-<path d="m14 1043.4v-4h-4" stroke-linecap="round"/>
+<g transform="translate(0 -1036.4)">
+<path transform="translate(0 1036.4)" d="m10 2a1.0001 1.0001 0 1 0 0 2h1.5859l-4.5195 4.5195-4.2988-5.1582-1.5352 1.2793 5 6a1.0001 1.0001 0 0 0 1.4746 0.064453l5.293-5.293v1.5879a1.0001 1.0001 0 1 0 2 0v-4a1.0001 1.0001 0 0 0 -1 -1h-4zm-9 7v5a1.0001 1.0001 0 0 0 1 1h12a1.0001 1.0001 0 0 0 1 -1v-4h-2v3h-10v-4h-2z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#fc9c9c" fill-opacity=".99608" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
</g>
</svg>
diff --git a/editor/icons/icon_short_cut.svg b/editor/icons/icon_short_cut.svg
index 736f1f3c02..8c7978e522 100644
--- a/editor/icons/icon_short_cut.svg
+++ b/editor/icons/icon_short_cut.svg
@@ -1,6 +1,5 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)" fill-opacity=".99608">
-<path transform="translate(0 1036.4)" d="m4 2c-0.55228 0-1 0.4477-1 1v9.084c4.015e-4 0.506 0.448 0.91602 1 0.91602h8c0.552 0 0.9996-0.41002 1-0.91602v-9.084c0-0.5523-0.44772-1-1-1h-8zm-3 2v9a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-9h-1v9a0.99998 0.99998 0 0 1 -1 1h-10a1 1 0 0 1 -1 -1v-9h-1zm6 0h3l-1 3h2l-4 4 1-3h-2l1-4z" fill="#e0e0e0"/>
-<rect x="27" y="1038.4" width="7" height="14" fill="#fff"/>
+<g transform="translate(0 -1036.4)">
+<path transform="translate(0 1036.4)" d="m4 2c-0.55228 0-1 0.4477-1 1v9.084c4.015e-4 0.506 0.448 0.91602 1 0.91602h8c0.552 0 0.9996-0.41002 1-0.91602v-9.084c0-0.5523-0.44772-1-1-1h-8zm-3 2v9a2 2 0 0 0 2 2h10a2 2 0 0 0 2 -2v-9h-1v9a0.99998 0.99998 0 0 1 -1 1h-10a1 1 0 0 1 -1 -1v-9h-1zm6 0h3l-1 3h2l-4 4 1-3h-2l1-4z" fill="#e0e0e0" fill-opacity=".99608"/>
</g>
</svg>
diff --git a/editor/icons/icon_skeleton.svg b/editor/icons/icon_skeleton.svg
index d5c5f301bb..ef563338c8 100644
--- a/editor/icons/icon_skeleton.svg
+++ b/editor/icons/icon_skeleton.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m6 2a4 4 0 0 0 -4 4 4 4 0 0 0 2 3.4531v3.5469a2 2 0 0 0 1 1.7324 2 2 0 0 0 1 0.26562v0.001953h4v-0.001953a2 2 0 0 0 1 -0.26562 2 2 0 0 0 1 -1.7324v-3.5469a4 4 0 0 0 2 -3.4531 4 4 0 0 0 -4 -4h-4zm-1 3a1 1 0 0 1 1 1 1 1 0 0 1 -1 1 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1zm6 0a1 1 0 0 1 1 1 1 1 0 0 1 -1 1 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1zm-4 2h2v1h-2v-1zm-2 2h1v1h1v-1h1 1v1h1v-1h1v0.86719 3.1328h-1v-1h-1v1h-1-1v-1h-1v1h-1v-3.1309-0.86914z" fill="#fc9c9c" fill-opacity=".99608"/>
-</g>
+<path d="m6 2a4 4 0 0 0 -4 4 4 4 0 0 0 2 3.4531v3.5469a2 2 0 0 0 1 1.7324 2 2 0 0 0 1 0.26562v0.001953h4v-0.001953a2 2 0 0 0 1 -0.26562 2 2 0 0 0 1 -1.7324v-3.5469a4 4 0 0 0 2 -3.4531 4 4 0 0 0 -4 -4h-4zm-1 3a1 1 0 0 1 1 1 1 1 0 0 1 -1 1 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1zm6 0a1 1 0 0 1 1 1 1 1 0 0 1 -1 1 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1zm-4 2h2v1h-2v-1zm-2 2h1v1h1v-1h1 1v1h1v-1h1v0.86719 3.1328h-1v-1h-1v1h-1-1v-1h-1v1h-1v-3.1309-0.86914z" fill="#fc9c9c" fill-opacity=".99608"/>
</svg>
diff --git a/editor/icons/icon_skeleton_2d.svg b/editor/icons/icon_skeleton_2d.svg
new file mode 100644
index 0000000000..1ee9bde2a6
--- /dev/null
+++ b/editor/icons/icon_skeleton_2d.svg
@@ -0,0 +1,3 @@
+<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
+<path d="m6 2a4 4 0 0 0 -4 4 4 4 0 0 0 2 3.4531v3.5469a2 2 0 0 0 1 1.7324 2 2 0 0 0 1 0.26562v0.001953h4v-0.001953a2 2 0 0 0 1 -0.26562 2 2 0 0 0 1 -1.7324v-3.5469a4 4 0 0 0 2 -3.4531 4 4 0 0 0 -4 -4h-4zm-1 3a1 1 0 0 1 1 1 1 1 0 0 1 -1 1 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1zm6 0a1 1 0 0 1 1 1 1 1 0 0 1 -1 1 1 1 0 0 1 -1 -1 1 1 0 0 1 1 -1zm-4 2h2v1h-2v-1zm-2 2h1v1h1v-1h1 1v1h1v-1h1v0.86719 3.1328h-1v-1h-1v1h-1-1v-1h-1v1h-1v-3.1309-0.86914z" fill="#a5b7f3"/>
+</svg>
diff --git a/editor/icons/icon_sphere_mesh.svg b/editor/icons/icon_sphere_mesh.svg
index 519b69cbd7..e298bbef3d 100644
--- a/editor/icons/icon_sphere_mesh.svg
+++ b/editor/icons/icon_sphere_mesh.svg
@@ -1,5 +1,3 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
-<g transform="translate(0 -1036.4)">
-<path transform="translate(0 1036.4)" d="m8 1c-3.8541 0-7 3.1459-7 7 0 3.8542 3.1459 7 7 7 3.8541 0 7-3.1458 7-7 0-3.8541-3.1459-7-7-7zm-1 2.0977v4.8711c-1.2931-0.071342-2.6061-0.29819-3.9434-0.69141 0.30081-2.0978 1.8852-3.7665 3.9434-4.1797zm2 0c2.0549 0.41253 3.637 2.0767 3.9414 4.1699-1.3046 0.36677-2.6158 0.60259-3.9414 0.6875v-4.8574zm3.7852 6.2812c-0.50864 1.7788-1.9499 3.1531-3.7852 3.5215v-2.9512c1.2792-0.072301 2.5419-0.26704 3.7852-0.57031zm-9.5645 0.017578c1.2733 0.31892 2.5337 0.50215 3.7793 0.5625v2.9414c-1.8291-0.36719-3.266-1.7339-3.7793-3.5039z" color="#000000" color-rendering="auto" dominant-baseline="auto" fill="#ffd684" image-rendering="auto" shape-rendering="auto" solid-color="#000000" style="filter-blend-mode:normal;filter-gaussianBlur-deviation:0;font-feature-settings:normal;font-variant-alternates:normal;font-variant-caps:normal;font-variant-east-asian:normal;font-variant-ligatures:normal;font-variant-numeric:normal;font-variant-position:normal;isolation:auto;mix-blend-mode:normal;shape-padding:0;text-decoration-color:#000000;text-decoration-line:none;text-decoration-style:solid;text-indent:0;text-orientation:mixed;text-transform:none;white-space:normal"/>
-</g>
+<path d="m8 1c-3.8541 0-7 3.1459-7 7 0 3.8542 3.1459 7 7 7 3.8541 0 7-3.1458 7-7 0-3.8541-3.1459-7-7-7zm-1 2.0977v4.8711c-1.2931-0.071342-2.6061-0.29819-3.9434-0.69141 0.30081-2.0978 1.8852-3.7665 3.9434-4.1797zm2 0c2.0549 0.41253 3.637 2.0767 3.9414 4.1699-1.3046 0.36677-2.6158 0.60259-3.9414 0.6875v-4.8574zm3.7852 6.2812c-0.50864 1.7788-1.9499 3.1531-3.7852 3.5215v-2.9512c1.2792-0.072301 2.5419-0.26704 3.7852-0.57031zm-9.5645 0.017578c1.2733 0.31892 2.5337 0.50215 3.7793 0.5625v2.9414c-1.8291-0.36719-3.266-1.7339-3.7793-3.5039z" fill="#ffd684"/>
</svg>
diff --git a/editor/icons/icon_timer.svg b/editor/icons/icon_timer.svg
index e5907cea20..6bf4a29158 100644
--- a/editor/icons/icon_timer.svg
+++ b/editor/icons/icon_timer.svg
@@ -1,8 +1,5 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
<g transform="translate(0 -1036.4)">
-<rect x="2" y="1037.4" width="12" height="2" ry="1" fill="#e0e0e0"/>
-<rect x="2" y="1049.4" width="12" height="2" ry="1" fill="#e0e0e0"/>
-<path d="m3 1050.4h10l-3-6h-4z" fill="#e0e0e0"/>
-<path d="m3 1038.4h10c0 2-3 4-4 6 1 2 4 4 4 6h-10c0-2 3-4 4-6-1-2-4-4-4-6z" fill="none" stroke="#e0e0e0" stroke-linejoin="round" stroke-width="2"/>
+<path transform="translate(0 1036.4)" d="m3 1a1.0001 1.0001 0 0 0 -0.38672 0.078125 1.0001 1.0001 0 0 0 -0.0019531 0c-0.0022762 9.545e-4 -0.0035918 0.0029354-0.0058593 0.0039062a1.0001 1.0001 0 0 0 -0.31055 0.20898c-0.0012857 0.0012787-0.0026276 0.0026206-0.0039063 0.0039063a1.0001 1.0001 0 0 0 -0.20508 0.30469c-0.0029915 0.0068502-0.0069239 0.012601-0.0097656 0.019531a1.0001 1.0001 0 0 0 -0.076172 0.38086c0 1.5 0.96697 2.6247 1.873 3.6602 0.76081 0.8695 1.4161 1.6425 1.875 2.3398-0.45889 0.6974-1.1141 1.4723-1.875 2.3418-0.90608 1.0355-1.873 2.1582-1.873 3.6582a1.0001 1.0001 0 0 0 0.078125 0.38867v0.001953c9.292e-4 0.002204 0.0029617 0.003663 0.0039062 0.005859a1.0001 1.0001 0 0 0 0.20898 0.30664c0.0010185 0.001027 0.0028834 0.004836 0.0039063 0.005859a1.0001 1.0001 0 0 0 0.30078 0.20312c0.0093182 0.004119 0.017877 0.007879 0.027344 0.011719a1.0001 1.0001 0 0 0 0.37695 0.076172h10a1.0001 1.0001 0 0 0 0.375 -0.074219c0.010174-0.0041 0.019294-0.009251 0.029297-0.013672a1.0001 1.0001 0 0 0 0.29297 -0.19922c0.004786-0.004679 0.00898-0.008899 0.013672-0.013672a1.0001 1.0001 0 0 0 0.20117 -0.29492c0.004119-0.009318 0.007879-0.017877 0.011719-0.027344a1.0001 1.0001 0 0 0 0.076172 -0.37695c0-1.5-0.96697-2.6227-1.873-3.6582-0.76087-0.8695-1.4161-1.6444-1.875-2.3418 0.4589-0.6973 1.1142-1.4703 1.875-2.3398 0.90608-1.0355 1.873-2.1602 1.873-3.6602a1.0001 1.0001 0 0 0 -0.078125 -0.39062 1.0001 1.0001 0 0 0 -0.21484 -0.31641 1.0001 1.0001 0 0 0 -0.31055 -0.21094 1.0001 1.0001 0 0 0 -0.011718 -0.0058593 1.0001 1.0001 0 0 0 -0.38477 -0.076172h-10zm1.5879 2h6.8242c-0.2378 0.4408-0.3055 0.7892-0.78906 1.3418-0.84392 0.9645-1.8983 1.9723-2.5176 3.2109a1.0001 1.0001 0 0 0 -0.10547 0.44727 1.0001 1.0001 0 0 0 -0.10547 -0.44727c-0.61926-1.2386-1.6737-2.2464-2.5176-3.2109-0.48356-0.5526-0.55126-0.901-0.78906-1.3418z" fill="#e0e0e0"/>
</g>
</svg>
diff --git a/editor/icons/icon_tree.svg b/editor/icons/icon_tree.svg
index 62efb9f94f..15be220451 100644
--- a/editor/icons/icon_tree.svg
+++ b/editor/icons/icon_tree.svg
@@ -1,6 +1,5 @@
<svg width="16" height="16" version="1.1" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
<g transform="translate(0 -1036.4)">
-<rect x="29" y="1042.4" width="1" height="1" fill="#fefeff"/>
<path transform="translate(0 1036.4)" d="m1 1v13c5.52e-5 0.55226 0.44774 0.99994 1 1h13v-2h-12v-6h2v3c5.52e-5 0.55226 0.44774 0.99994 1 1h9v-2h-8v-2h8v-2h-12v-2h12v-2z" fill="#a5efac"/>
</g>
</svg>
diff --git a/editor/import/editor_scene_importer_gltf.cpp b/editor/import/editor_scene_importer_gltf.cpp
index 1c4617c353..2636839764 100644
--- a/editor/import/editor_scene_importer_gltf.cpp
+++ b/editor/import/editor_scene_importer_gltf.cpp
@@ -1108,7 +1108,8 @@ Error EditorSceneImporterGLTF::_parse_images(GLTFState &state, const String &p_b
if (d.has("uri")) {
String uri = d["uri"];
- if (uri.findn("data:application/octet-stream;base64") == 0) {
+ if (uri.findn("data:application/octet-stream;base64") == 0 ||
+ uri.findn("data:" + mimetype + ";base64") == 0) {
//embedded data
data = _parse_base64_uri(uri);
data_ptr = data.ptr();
diff --git a/editor/import/resource_importer_csv_translation.cpp b/editor/import/resource_importer_csv_translation.cpp
index 22c32f5fc9..ec0500361d 100644
--- a/editor/import/resource_importer_csv_translation.cpp
+++ b/editor/import/resource_importer_csv_translation.cpp
@@ -50,7 +50,7 @@ void ResourceImporterCSVTranslation::get_recognized_extensions(List<String> *p_e
}
String ResourceImporterCSVTranslation::get_save_extension() const {
- return ""; //does not save a single resoure
+ return ""; //does not save a single resource
}
String ResourceImporterCSVTranslation::get_resource_type() const {
diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp
index 9680ad07e7..f16747f929 100644
--- a/editor/plugins/canvas_item_editor_plugin.cpp
+++ b/editor/plugins/canvas_item_editor_plugin.cpp
@@ -597,7 +597,7 @@ void CanvasItemEditor::_save_canvas_item_state(List<CanvasItem *> p_canvas_items
bone = Object::cast_to<Node2D>(bone->get_parent());
}
- //Save the bone state and lenght if we have an IK chain
+ //Save the bone state and length if we have an IK chain
if (ik_found) {
bone = Object::cast_to<Node2D>(canvas_item);
Transform2D bone_xform = bone->get_global_transform();
@@ -676,12 +676,12 @@ bool CanvasItemEditor::_gui_input_rulers_and_guides(const Ref<InputEvent> &p_eve
Ref<InputEventMouseButton> b = p_event;
Ref<InputEventMouseMotion> m = p_event;
- // Start draging a guide
+ // Start dragging a guide
if (drag_type == DRAG_NONE) {
if (b.is_valid() && b->get_button_index() == BUTTON_LEFT && b->is_pressed()) {
if (show_guides && show_rulers && EditorNode::get_singleton()->get_edited_scene()) {
Transform2D xform = viewport_scrollable->get_transform() * transform;
- // Retreive the guide lists
+ // Retrieve the guide lists
Array vguides;
if (EditorNode::get_singleton()->get_edited_scene()->has_meta("_edit_vertical_guides_")) {
vguides = EditorNode::get_singleton()->get_edited_scene()->get_meta("_edit_vertical_guides_");
diff --git a/editor/plugins/collision_polygon_editor_plugin.cpp b/editor/plugins/collision_polygon_editor_plugin.cpp
index d8d3c0cee6..4410242d9c 100644
--- a/editor/plugins/collision_polygon_editor_plugin.cpp
+++ b/editor/plugins/collision_polygon_editor_plugin.cpp
@@ -140,7 +140,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera *p_camera, const R
Vector<Vector2> poly = node->get_polygon();
//first check if a point is to be added (segment split)
- real_t grab_treshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8);
+ real_t grab_threshold = EDITOR_DEF("editors/poly_editor/point_grab_radius", 8);
switch (mode) {
@@ -159,7 +159,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera *p_camera, const R
return true;
} else {
- if (wip.size() > 1 && p_camera->unproject_position(gt.xform(Vector3(wip[0].x, wip[0].y, depth))).distance_to(gpoint) < grab_treshold) {
+ if (wip.size() > 1 && p_camera->unproject_position(gt.xform(Vector3(wip[0].x, wip[0].y, depth))).distance_to(gpoint) < grab_threshold) {
//wip closed
_wip_close();
@@ -213,7 +213,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera *p_camera, const R
continue; //not valid to reuse point
real_t d = cp.distance_to(gpoint);
- if (d < closest_dist && d < grab_treshold) {
+ if (d < closest_dist && d < grab_threshold) {
closest_dist = d;
closest_pos = cp;
closest_idx = i;
@@ -242,7 +242,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera *p_camera, const R
Vector2 cp = p_camera->unproject_position(gt.xform(Vector3(poly[i].x, poly[i].y, depth)));
real_t d = cp.distance_to(gpoint);
- if (d < closest_dist && d < grab_treshold) {
+ if (d < closest_dist && d < grab_threshold) {
closest_dist = d;
closest_pos = cp;
closest_idx = i;
@@ -288,7 +288,7 @@ bool CollisionPolygonEditor::forward_spatial_gui_input(Camera *p_camera, const R
Vector2 cp = p_camera->unproject_position(gt.xform(Vector3(poly[i].x, poly[i].y, depth)));
real_t d = cp.distance_to(gpoint);
- if (d < closest_dist && d < grab_treshold) {
+ if (d < closest_dist && d < grab_threshold) {
closest_dist = d;
closest_pos = cp;
closest_idx = i;
diff --git a/editor/plugins/skeleton_2d_editor_plugin.cpp b/editor/plugins/skeleton_2d_editor_plugin.cpp
new file mode 100644
index 0000000000..6bf94b95eb
--- /dev/null
+++ b/editor/plugins/skeleton_2d_editor_plugin.cpp
@@ -0,0 +1,115 @@
+#include "skeleton_2d_editor_plugin.h"
+
+#include "canvas_item_editor_plugin.h"
+#include "scene/2d/mesh_instance_2d.h"
+#include "scene/gui/box_container.h"
+#include "thirdparty/misc/clipper.hpp"
+
+void Skeleton2DEditor::_node_removed(Node *p_node) {
+
+ if (p_node == node) {
+ node = NULL;
+ options->hide();
+ }
+}
+
+void Skeleton2DEditor::edit(Skeleton2D *p_sprite) {
+
+ node = p_sprite;
+}
+
+void Skeleton2DEditor::_menu_option(int p_option) {
+
+ switch (p_option) {
+ case MENU_OPTION_MAKE_REST: {
+
+ if (node->get_bone_count() == 0) {
+ err_dialog->set_text(TTR("This skeleton has no bones, create some children Bone2D nodes."));
+ err_dialog->popup_centered_minsize();
+ return;
+ }
+ UndoRedo *ur = EditorNode::get_singleton()->get_undo_redo();
+ ur->create_action("Create Rest Pose from Bones");
+ for (int i = 0; i < node->get_bone_count(); i++) {
+ Bone2D *bone = node->get_bone(i);
+ ur->add_do_method(bone, "set_rest", bone->get_transform());
+ ur->add_undo_method(bone, "set_rest", bone->get_rest());
+ }
+ ur->commit_action();
+
+ } break;
+ case MENU_OPTION_SET_REST: {
+ if (node->get_bone_count() == 0) {
+ err_dialog->set_text(TTR("This skeleton has no bones, create some children Bone2D nodes."));
+ err_dialog->popup_centered_minsize();
+ return;
+ }
+ UndoRedo *ur = EditorNode::get_singleton()->get_undo_redo();
+ ur->create_action("Set Rest Pose to Bones");
+ for (int i = 0; i < node->get_bone_count(); i++) {
+ Bone2D *bone = node->get_bone(i);
+ ur->add_do_method(bone, "set_transform", bone->get_rest());
+ ur->add_undo_method(bone, "set_transform", bone->get_transform());
+ }
+ ur->commit_action();
+
+ } break;
+ }
+}
+
+void Skeleton2DEditor::_bind_methods() {
+
+ ClassDB::bind_method("_menu_option", &Skeleton2DEditor::_menu_option);
+}
+
+Skeleton2DEditor::Skeleton2DEditor() {
+
+ options = memnew(MenuButton);
+
+ CanvasItemEditor::get_singleton()->add_control_to_menu_panel(options);
+
+ options->set_text(TTR("Skeleton2D"));
+ options->set_icon(EditorNode::get_singleton()->get_gui_base()->get_icon("Skeleton2D", "EditorIcons"));
+
+ options->get_popup()->add_item(TTR("Make Rest Pose (From Bones)"), MENU_OPTION_MAKE_REST);
+ options->get_popup()->add_separator();
+ options->get_popup()->add_item(TTR("Set Bones to Rest Pose"), MENU_OPTION_SET_REST);
+
+ options->get_popup()->connect("id_pressed", this, "_menu_option");
+
+ err_dialog = memnew(AcceptDialog);
+ add_child(err_dialog);
+}
+
+void Skeleton2DEditorPlugin::edit(Object *p_object) {
+
+ sprite_editor->edit(Object::cast_to<Skeleton2D>(p_object));
+}
+
+bool Skeleton2DEditorPlugin::handles(Object *p_object) const {
+
+ return p_object->is_class("Skeleton2D");
+}
+
+void Skeleton2DEditorPlugin::make_visible(bool p_visible) {
+
+ if (p_visible) {
+ sprite_editor->options->show();
+ } else {
+
+ sprite_editor->options->hide();
+ sprite_editor->edit(NULL);
+ }
+}
+
+Skeleton2DEditorPlugin::Skeleton2DEditorPlugin(EditorNode *p_node) {
+
+ editor = p_node;
+ sprite_editor = memnew(Skeleton2DEditor);
+ editor->get_viewport()->add_child(sprite_editor);
+
+ //sprite_editor->options->hide();
+}
+
+Skeleton2DEditorPlugin::~Skeleton2DEditorPlugin() {
+}
diff --git a/editor/plugins/skeleton_2d_editor_plugin.h b/editor/plugins/skeleton_2d_editor_plugin.h
new file mode 100644
index 0000000000..bbe2a3a6f2
--- /dev/null
+++ b/editor/plugins/skeleton_2d_editor_plugin.h
@@ -0,0 +1,55 @@
+#ifndef SKELETON_2D_EDITOR_PLUGIN_H
+#define SKELETON_2D_EDITOR_PLUGIN_H
+
+#include "editor/editor_node.h"
+#include "editor/editor_plugin.h"
+#include "scene/2d/skeleton_2d.h"
+#include "scene/gui/spin_box.h"
+
+class Skeleton2DEditor : public Control {
+
+ GDCLASS(Skeleton2DEditor, Control);
+
+ enum Menu {
+ MENU_OPTION_MAKE_REST,
+ MENU_OPTION_SET_REST,
+ };
+
+ Skeleton2D *node;
+
+ MenuButton *options;
+ AcceptDialog *err_dialog;
+
+ void _menu_option(int p_option);
+
+ //void _create_uv_lines();
+ friend class Skeleton2DEditorPlugin;
+
+protected:
+ void _node_removed(Node *p_node);
+ static void _bind_methods();
+
+public:
+ void edit(Skeleton2D *p_sprite);
+ Skeleton2DEditor();
+};
+
+class Skeleton2DEditorPlugin : public EditorPlugin {
+
+ GDCLASS(Skeleton2DEditorPlugin, EditorPlugin);
+
+ Skeleton2DEditor *sprite_editor;
+ EditorNode *editor;
+
+public:
+ virtual String get_name() const { return "Skeleton2D"; }
+ bool has_main_screen() const { return false; }
+ virtual void edit(Object *p_object);
+ virtual bool handles(Object *p_object) const;
+ virtual void make_visible(bool p_visible);
+
+ Skeleton2DEditorPlugin(EditorNode *p_node);
+ ~Skeleton2DEditorPlugin();
+};
+
+#endif // SKELETON_2D_EDITOR_PLUGIN_H
diff --git a/editor/plugins/spatial_editor_plugin.cpp b/editor/plugins/spatial_editor_plugin.cpp
index 6fd93c2f28..9e7bfd5787 100644
--- a/editor/plugins/spatial_editor_plugin.cpp
+++ b/editor/plugins/spatial_editor_plugin.cpp
@@ -4691,6 +4691,8 @@ void SpatialEditor::_unhandled_key_input(Ref<InputEvent> p_event) {
if (!is_visible_in_tree() || get_viewport()->gui_has_modal_stack())
return;
+ snap_key_enabled = Input::get_singleton()->is_key_pressed(KEY_CONTROL);
+
Ref<InputEventKey> k = p_event;
if (k.is_valid()) {
@@ -4962,6 +4964,7 @@ SpatialEditor::SpatialEditor(EditorNode *p_editor) {
editor_selection->add_editor_plugin(this);
snap_enabled = false;
+ snap_key_enabled = false;
tool_mode = TOOL_MODE_SELECT;
hbc_menu = memnew(HBoxContainer);
diff --git a/editor/plugins/spatial_editor_plugin.h b/editor/plugins/spatial_editor_plugin.h
index d1fcdf8d54..7736db67b1 100644
--- a/editor/plugins/spatial_editor_plugin.h
+++ b/editor/plugins/spatial_editor_plugin.h
@@ -505,6 +505,7 @@ private:
ConfirmationDialog *settings_dialog;
bool snap_enabled;
+ bool snap_key_enabled;
LineEdit *snap_translate;
LineEdit *snap_rotate;
LineEdit *snap_scale;
@@ -579,7 +580,7 @@ public:
ToolMode get_tool_mode() const { return tool_mode; }
bool are_local_coords_enabled() const { return tool_option_button[SpatialEditor::TOOL_OPT_LOCAL_COORDS]->is_pressed(); }
- bool is_snap_enabled() const { return snap_enabled; }
+ bool is_snap_enabled() const { return snap_enabled ^ snap_key_enabled; }
float get_translate_snap() const { return snap_translate->get_text().to_double(); }
float get_rotate_snap() const { return snap_rotate->get_text().to_double(); }
float get_scale_snap() const { return snap_scale->get_text().to_double(); }
diff --git a/editor/script_editor_debugger.cpp b/editor/script_editor_debugger.cpp
index 36df5f6ccc..57beb9523f 100644
--- a/editor/script_editor_debugger.cpp
+++ b/editor/script_editor_debugger.cpp
@@ -1734,7 +1734,7 @@ void ScriptEditorDebugger::_error_list_item_rmb_selected(int p_item, const Vecto
bool single_item_selected = error_list->get_selected_items().size() == 1;
if (single_item_selected) {
- item_menu->add_icon_item(get_icon("CopyNodePath", "EditorIcons"), TTR("Copy Error"), ITEM_MENU_COPY_ERROR);
+ item_menu->add_icon_item(get_icon("ActionCopy", "EditorIcons"), TTR("Copy Error"), ITEM_MENU_COPY_ERROR);
}
if (item_menu->get_item_count() > 0) {
diff --git a/main/input_default.cpp b/main/input_default.cpp
index 5057c5f53a..323748346a 100644
--- a/main/input_default.cpp
+++ b/main/input_default.cpp
@@ -429,7 +429,7 @@ Point2 InputDefault::get_last_mouse_speed() const {
int InputDefault::get_mouse_button_mask() const {
- return mouse_button_mask; // do not trust OS implementaiton, should remove it - OS::get_singleton()->get_mouse_button_state();
+ return mouse_button_mask; // do not trust OS implementation, should remove it - OS::get_singleton()->get_mouse_button_state();
}
void InputDefault::warp_mouse_position(const Vector2 &p_to) {
diff --git a/methods.py b/methods.py
index f4d33fb6d8..ab49ae9dda 100644
--- a/methods.py
+++ b/methods.py
@@ -1432,7 +1432,7 @@ def use_windows_spawn_fix(self, platform=None):
# that makes object files with same names to be overwritten so the last wins and
# the library looses symbols defined by overwritten objects.
# By enabling quick append instead of the default mode (replacing), libraries will
- # got built correctly regardless the invokation strategy.
+ # got built correctly regardless the invocation strategy.
# Furthermore, since SCons will rebuild the library from scratch when an object file
# changes, no multiple versions of the same object file will be present.
self.Replace(ARFLAGS='q')
@@ -1607,7 +1607,7 @@ def detect_visual_c_compiler_version(tools_env):
# There is no flag to give to visual c compilers to set the architecture, ie scons bits argument (32,64,ARM etc)
# There are many different cl.exe files that are run, and each one compiles & links to a different architecture
# As far as I know, the only way to figure out what compiler will be run when Scons calls cl.exe via Program()
- # is to check the PATH variable and figure out which one will be called first. Code bellow does that and returns:
+ # is to check the PATH variable and figure out which one will be called first. Code below does that and returns:
# the following string values:
# "" Compiler not detected
@@ -1627,7 +1627,7 @@ def detect_visual_c_compiler_version(tools_env):
if 'VCINSTALLDIR' in tools_env:
# print("Checking VCINSTALLDIR")
- # find() works with -1 so big ifs bellow are needed... the simplest solution, in fact
+ # find() works with -1 so big ifs below are needed... the simplest solution, in fact
# First test if amd64 and amd64_x86 compilers are present in the path
vc_amd64_compiler_detection_index = tools_env["PATH"].find(tools_env["VCINSTALLDIR"] + "BIN\\amd64;")
if(vc_amd64_compiler_detection_index > -1):
diff --git a/modules/bullet/bullet_physics_server.cpp b/modules/bullet/bullet_physics_server.cpp
index 595e4951a2..61ce26e9fd 100644
--- a/modules/bullet/bullet_physics_server.cpp
+++ b/modules/bullet/bullet_physics_server.cpp
@@ -783,7 +783,7 @@ int BulletPhysicsServer::body_get_max_contacts_reported(RID p_body) const {
return body->get_max_collisions_detection();
}
-void BulletPhysicsServer::body_set_contacts_reported_depth_threshold(RID p_body, float p_treshold) {
+void BulletPhysicsServer::body_set_contacts_reported_depth_threshold(RID p_body, float p_threshold) {
WARN_PRINT("Not supported by bullet and even Godot");
}
diff --git a/modules/bullet/bullet_physics_server.h b/modules/bullet/bullet_physics_server.h
index 885d58d98d..e931915bba 100644
--- a/modules/bullet/bullet_physics_server.h
+++ b/modules/bullet/bullet_physics_server.h
@@ -239,7 +239,7 @@ public:
virtual void body_set_max_contacts_reported(RID p_body, int p_contacts);
virtual int body_get_max_contacts_reported(RID p_body) const;
- virtual void body_set_contacts_reported_depth_threshold(RID p_body, float p_treshold);
+ virtual void body_set_contacts_reported_depth_threshold(RID p_body, float p_threshold);
virtual float body_get_contacts_reported_depth_threshold(RID p_body) const;
virtual void body_set_omit_force_integration(RID p_body, bool p_omit);
diff --git a/modules/bullet/godot_motion_state.h b/modules/bullet/godot_motion_state.h
index fe5d8418b7..fa58e86589 100644
--- a/modules/bullet/godot_motion_state.h
+++ b/modules/bullet/godot_motion_state.h
@@ -87,7 +87,7 @@ public:
public:
/// Use this function to move kinematic body
- /// -- or set initial transfom before body creation.
+ /// -- or set initial transform before body creation.
void moveBody(const btTransform &newWorldTransform) {
bodyKinematicWorldTransf = newWorldTransform;
}
diff --git a/modules/bullet/space_bullet.cpp b/modules/bullet/space_bullet.cpp
index 56441f7ef2..e20a79f667 100644
--- a/modules/bullet/space_bullet.cpp
+++ b/modules/bullet/space_bullet.cpp
@@ -628,7 +628,7 @@ void SpaceBullet::destroy_world() {
void SpaceBullet::check_ghost_overlaps() {
- /// Algorith support variables
+ /// Algorithm support variables
btConvexShape *other_body_shape;
btConvexShape *area_shape;
btGjkPairDetector::ClosestPointInput gjk_input;
diff --git a/modules/gdnative/include/pluginscript/godot_pluginscript.h b/modules/gdnative/include/pluginscript/godot_pluginscript.h
index 671be3bbb9..d1671c014e 100644
--- a/modules/gdnative/include/pluginscript/godot_pluginscript.h
+++ b/modules/gdnative/include/pluginscript/godot_pluginscript.h
@@ -64,7 +64,7 @@ typedef struct {
//this is used by script languages that keep a reference counter of their own
//you can make make Ref<> not die when it reaches zero, so deleting the reference
//depends entirely from the script.
- // Note: You can set thoses function pointer to NULL if not needed.
+ // Note: You can set those function pointer to NULL if not needed.
void (*refcount_incremented)(godot_pluginscript_instance_data *p_data);
bool (*refcount_decremented)(godot_pluginscript_instance_data *p_data); // return true if it can die
} godot_pluginscript_instance_desc;
diff --git a/modules/gdscript/gdscript_compiler.cpp b/modules/gdscript/gdscript_compiler.cpp
index 1649fb52f2..048948dada 100644
--- a/modules/gdscript/gdscript_compiler.cpp
+++ b/modules/gdscript/gdscript_compiler.cpp
@@ -181,7 +181,7 @@ int GDScriptCompiler::_parse_expression(CodeGen &codegen, const GDScriptParser::
//wait, identifier could be a local variable or something else... careful here, must reference properly
//as stack may be more interesting to work with
- //This could be made much simpler by just indexing "self", but done this way (with custom self-addressing modes) increases peformance a lot.
+ //This could be made much simpler by just indexing "self", but done this way (with custom self-addressing modes) increases performance a lot.
const GDScriptParser::IdentifierNode *in = static_cast<const GDScriptParser::IdentifierNode *>(p_expression);
diff --git a/modules/gdscript/gdscript_parser.cpp b/modules/gdscript/gdscript_parser.cpp
index cd752a786c..ac7fd94141 100644
--- a/modules/gdscript/gdscript_parser.cpp
+++ b/modules/gdscript/gdscript_parser.cpp
@@ -4098,7 +4098,7 @@ void GDScriptParser::_parse_class(ClassNode *p_class) {
ConstantNode *cn = static_cast<ConstantNode *>(subexpr);
if (cn->value.get_type() == Variant::NIL) {
- _set_error("Can't accept a null constant expression for infering export type.");
+ _set_error("Can't accept a null constant expression for inferring export type.");
return;
}
member._export.type = cn->value.get_type();
@@ -4234,7 +4234,7 @@ void GDScriptParser::_parse_class(ClassNode *p_class) {
} break;
case GDScriptTokenizer::TK_PR_ENUM: {
- //mutiple constant declarations..
+ //multiple constant declarations..
int last_assign = -1; // Incremented by 1 right before the assingment.
String enum_name;
diff --git a/modules/mono/editor/godotsharp_editor.cpp b/modules/mono/editor/godotsharp_editor.cpp
index 0ef3adfdd0..975cf0f030 100644
--- a/modules/mono/editor/godotsharp_editor.cpp
+++ b/modules/mono/editor/godotsharp_editor.cpp
@@ -278,10 +278,11 @@ GodotSharpEditor::GodotSharpEditor(EditorNode *p_editor) {
String about_text =
String("C# support in Godot Engine is a brand new feature and a work in progress.\n") +
"It is at the alpha stage and thus not suitable for use in production.\n\n" +
- "As of Godot 3.0, C# support is not feature-complete and can crash in some situations. " +
- "Bugs and usability issues will be addressed gradually over 3.0.x and 3.x releases.\n" +
+ "As of Godot 3.0, C# support is not feature-complete and may crash in some situations. " +
+ "Bugs and usability issues will be addressed gradually over 3.0.x and 3.x releases, " +
+ "including compatibility breaking changes as new features are implemented for a better overall C# experience.\n\n" +
"The main missing feature is the ability to export games using C# assemblies - you will therefore be able to develop and run games in the editor, " +
- "but not to share them as standalone binaries. This feature is of course high on the priority list and should be available in 3.0.1.\n\n" +
+ "but not to share them as standalone binaries yet. This feature is of course high on the priority list and should be available as soon as possible.\n\n" +
"If you experience issues with this Mono build, please report them on Godot's issue tracker with details about your system, Mono version, IDE, etc.:\n\n" +
" https://github.com/godotengine/godot/issues\n\n" +
"Your critical feedback at this stage will play a great role in shaping the C# support in future releases, so thank you!";
diff --git a/modules/regex/doc_classes/RegEx.xml b/modules/regex/doc_classes/RegEx.xml
index 36de04f293..26f0501df3 100644
--- a/modules/regex/doc_classes/RegEx.xml
+++ b/modules/regex/doc_classes/RegEx.xml
@@ -4,14 +4,14 @@
Class for searching text for patterns using regular expressions.
</brief_description>
<description>
- Regular Expression (or regex) is a compact programming language that can be used to recognise strings that follow a specific pattern, such as URLs, email addresses, complete sentences, etc. For instance, a regex of [code]ab[0-9][/code] would find any string that is [code]ab[/code] followed by any number from [code]0[/code] to [code]9[/code]. For a more in-depth look, you can easily find various tutorials and detailed explainations on the Internet.
+ Regular Expression (or regex) is a compact programming language that can be used to recognise strings that follow a specific pattern, such as URLs, email addresses, complete sentences, etc. For instance, a regex of [code]ab[0-9][/code] would find any string that is [code]ab[/code] followed by any number from [code]0[/code] to [code]9[/code]. For a more in-depth look, you can easily find various tutorials and detailed explanations on the Internet.
To begin, the RegEx object needs to be compiled with the search pattern using [method compile] before it can be used.
[codeblock]
var regex = RegEx.new()
regex.compile("\\w-(\\d+)")
[/codeblock]
The search pattern must be escaped first for gdscript before it is escaped for the expression. For example, [code]compile("\\d+")[/code] would be read by RegEx as [code]\d+[/code]. Similarly, [code]compile("\"(?:\\\\.|[^\"])*\"")[/code] would be read as [code]"(?:\\.|[^"])*"[/code]
- Using [method search] you can find the pattern within the given text. If a pattern is found, [RegExMatch] is returned and you can retrieve details of the results using fuctions such as [method RegExMatch.get_string] and [method RegExMatch.get_start].
+ Using [method search] you can find the pattern within the given text. If a pattern is found, [RegExMatch] is returned and you can retrieve details of the results using functions such as [method RegExMatch.get_string] and [method RegExMatch.get_start].
[codeblock]
var regex = RegEx.new()
regex.compile("\\w-(\\d+)")
diff --git a/modules/visual_script/visual_script.cpp b/modules/visual_script/visual_script.cpp
index 5987fdf5da..ef680547ca 100644
--- a/modules/visual_script/visual_script.cpp
+++ b/modules/visual_script/visual_script.cpp
@@ -2182,7 +2182,7 @@ void VisualScriptInstance::create(const Ref<VisualScript> &p_script, Object *p_o
Ref<VisualScriptNode> node = F->get().node;
VisualScriptNodeInstance *instance = instances[F->key()];
- // conect to default values
+ // connect to default values
for (int i = 0; i < instance->input_port_count; i++) {
if (instance->input_ports[i] == -1) {
@@ -2192,7 +2192,7 @@ void VisualScriptInstance::create(const Ref<VisualScript> &p_script, Object *p_o
}
}
- // conect to trash
+ // connect to trash
for (int i = 0; i < instance->output_port_count; i++) {
if (instance->output_ports[i] == -1) {
instance->output_ports[i] = function.trash_pos; //trash is same for all
diff --git a/modules/visual_script/visual_script_nodes.cpp b/modules/visual_script/visual_script_nodes.cpp
index e0b4fde237..c5654a5a20 100644
--- a/modules/visual_script/visual_script_nodes.cpp
+++ b/modules/visual_script/visual_script_nodes.cpp
@@ -425,7 +425,7 @@ PropertyInfo VisualScriptOperator::get_input_value_port_info(int p_idx) const {
}
PropertyInfo VisualScriptOperator::get_output_value_port_info(int p_idx) const {
static const Variant::Type port_types[Variant::OP_MAX] = {
- //comparation
+ //comparison
Variant::BOOL, //OP_EQUAL,
Variant::BOOL, //OP_NOT_EQUAL,
Variant::BOOL, //OP_LESS,
@@ -466,7 +466,7 @@ PropertyInfo VisualScriptOperator::get_output_value_port_info(int p_idx) const {
}
static const char *op_names[] = {
- //comparation
+ //comparison
"Equal", //OP_EQUAL,
"NotEqual", //OP_NOT_EQUAL,
"Less", //OP_LESS,
@@ -506,7 +506,7 @@ String VisualScriptOperator::get_caption() const {
String VisualScriptOperator::get_text() const {
static const wchar_t *op_names[] = {
- //comparation
+ //comparison
L"A = B", //OP_EQUAL,
L"A \u2260 B", //OP_NOT_EQUAL,
L"A < B", //OP_LESS,
diff --git a/modules/websocket/lws_helper.h b/modules/websocket/lws_helper.h
index ac0c340aa9..a832d458b6 100644
--- a/modules/websocket/lws_helper.h
+++ b/modules/websocket/lws_helper.h
@@ -108,7 +108,7 @@ static bool _lws_poll(struct lws_context *context, _LWSRef *ref) {
static void _lws_make_protocols(void *p_obj, lws_callback_function *p_callback, PoolVector<String> p_names, _LWSRef **r_lws_ref) {
/* the input strings might go away after this call,
* we need to copy them. Will clear them when
- * detroying the context */
+ * destroying the context */
int i;
int len = p_names.size();
size_t data_size = sizeof(struct LWSPeer::PeerData);
diff --git a/platform/android/export/export.cpp b/platform/android/export/export.cpp
index 2a61f8d873..6b4d0ff8c4 100644
--- a/platform/android/export/export.cpp
+++ b/platform/android/export/export.cpp
@@ -257,7 +257,7 @@ class EditorExportAndroid : public EditorExportPlatform {
if (dpos == -1)
continue;
d = d.substr(0, dpos).strip_edges();
- //print_line("found devuce: "+d);
+ //print_line("found device: "+d);
ldevices.push_back(d);
}
@@ -996,7 +996,7 @@ public:
public:
virtual void get_preset_features(const Ref<EditorExportPreset> &p_preset, List<String> *r_features) {
- // Reenable when a GLES 2.0 backend is readded
+ // Re-enable when a GLES 2.0 backend is read
/*int api = p_preset->get("graphics/api");
if (api == 0)
r_features->push_back("etc");
diff --git a/platform/osx/os_osx.mm b/platform/osx/os_osx.mm
index 4c459772aa..6e42eb58bd 100644
--- a/platform/osx/os_osx.mm
+++ b/platform/osx/os_osx.mm
@@ -1092,7 +1092,7 @@ Error OS_OSX::initialize(const VideoMode &p_desired, int p_video_driver, int p_a
unsigned int attributeCount = 0;
- // OS X needs non-zero color size, so set resonable values
+ // OS X needs non-zero color size, so set reasonable values
int colorBits = 32;
// Fail if a robustness strategy was requested
@@ -1138,7 +1138,7 @@ Error OS_OSX::initialize(const VideoMode &p_desired, int p_video_driver, int p_a
*/
// NOTE: All NSOpenGLPixelFormats on the relevant cards support sRGB
- // frambuffer, so there's no need (and no way) to request it
+ // framebuffer, so there's no need (and no way) to request it
ADD_ATTR(0);
diff --git a/platform/uwp/export/export.cpp b/platform/uwp/export/export.cpp
index 620f6c0f24..7d7bee9227 100644
--- a/platform/uwp/export/export.cpp
+++ b/platform/uwp/export/export.cpp
@@ -1082,7 +1082,7 @@ public:
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "custom_template/debug", PROPERTY_HINT_GLOBAL_FILE, "zip"), ""));
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "custom_template/release", PROPERTY_HINT_GLOBAL_FILE, "zip"), ""));
- // Capabilites
+ // Capabilities
const char **basic = uwp_capabilities;
while (*basic) {
r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "capabilities/" + String(*basic).camelcase_to_underscore(false)), false));
diff --git a/platform/windows/detect.py b/platform/windows/detect.py
index 94a3efcd89..b8ee2cd19f 100644
--- a/platform/windows/detect.py
+++ b/platform/windows/detect.py
@@ -148,11 +148,11 @@ def configure(env):
## Compiler configuration
env['ENV'] = os.environ
- # This detection function needs the tools env (that is env['ENV'], not SCons's env), and that is why it's this far bellow in the code
+ # This detection function needs the tools env (that is env['ENV'], not SCons's env), and that is why it's this far below in the code
compiler_version_str = methods.detect_visual_c_compiler_version(env['ENV'])
print("Detected MSVC compiler: " + compiler_version_str)
- # If building for 64bit architecture, disable assembly optimisations for 32 bit builds (theora as of writting)... vc compiler for 64bit can not compile _asm
+ # If building for 64bit architecture, disable assembly optimisations for 32 bit builds (theora as of writing)... vc compiler for 64bit can not compile _asm
if(compiler_version_str == "amd64" or compiler_version_str == "x86_amd64"):
env["bits"] = "64"
env["x86_libtheora_opt_vc"] = False
diff --git a/platform/x11/os_x11.cpp b/platform/x11/os_x11.cpp
index 2027667af3..66c02561b5 100644
--- a/platform/x11/os_x11.cpp
+++ b/platform/x11/os_x11.cpp
@@ -751,7 +751,7 @@ void OS_X11::set_wm_fullscreen(bool p_enabled) {
XFree(xsh);
}
- // Using EWMH -- Extened Window Manager Hints
+ // Using EWMH -- Extended Window Manager Hints
XEvent xev;
Atom wm_state = XInternAtom(x11_display, "_NET_WM_STATE", False);
Atom wm_fullscreen = XInternAtom(x11_display, "_NET_WM_STATE_FULLSCREEN", False);
diff --git a/scene/2d/audio_stream_player_2d.cpp b/scene/2d/audio_stream_player_2d.cpp
index fc67d28a29..f998f23d3b 100644
--- a/scene/2d/audio_stream_player_2d.cpp
+++ b/scene/2d/audio_stream_player_2d.cpp
@@ -226,14 +226,14 @@ void AudioStreamPlayer2D::_notification(int p_what) {
setseek = setplay;
active = true;
setplay = -1;
- //do not update, this makes it easier to animate (will shut off otherise)
+ //do not update, this makes it easier to animate (will shut off otherwise)
//_change_notify("playing"); //update property in editor
}
//stop playing if no longer active
if (!active) {
set_physics_process_internal(false);
- //do not update, this makes it easier to animate (will shut off otherise)
+ //do not update, this makes it easier to animate (will shut off otherwise)
//_change_notify("playing"); //update property in editor
emit_signal("finished");
}
diff --git a/scene/2d/canvas_item.cpp b/scene/2d/canvas_item.cpp
index 8d7fce8cc4..5cca5705a0 100644
--- a/scene/2d/canvas_item.cpp
+++ b/scene/2d/canvas_item.cpp
@@ -779,13 +779,13 @@ void CanvasItem::draw_colored_polygon(const Vector<Point2> &p_points, const Colo
VisualServer::get_singleton()->canvas_item_add_polygon(canvas_item, p_points, colors, p_uvs, rid, rid_normal, p_antialiased);
}
-void CanvasItem::draw_mesh(const Ref<Mesh> &p_mesh, const Ref<Texture> &p_texture, const Ref<Texture> &p_normal_map, RID p_skeleton) {
+void CanvasItem::draw_mesh(const Ref<Mesh> &p_mesh, const Ref<Texture> &p_texture, const Ref<Texture> &p_normal_map) {
ERR_FAIL_COND(p_mesh.is_null());
RID texture_rid = p_texture.is_valid() ? p_texture->get_rid() : RID();
RID normal_map_rid = p_normal_map.is_valid() ? p_normal_map->get_rid() : RID();
- VisualServer::get_singleton()->canvas_item_add_mesh(canvas_item, p_mesh->get_rid(), texture_rid, normal_map_rid, p_skeleton);
+ VisualServer::get_singleton()->canvas_item_add_mesh(canvas_item, p_mesh->get_rid(), texture_rid, normal_map_rid);
}
void CanvasItem::draw_multimesh(const Ref<MultiMesh> &p_multimesh, const Ref<Texture> &p_texture, const Ref<Texture> &p_normal_map) {
@@ -1032,7 +1032,7 @@ void CanvasItem::_bind_methods() {
ClassDB::bind_method(D_METHOD("draw_colored_polygon", "points", "color", "uvs", "texture", "normal_map", "antialiased"), &CanvasItem::draw_colored_polygon, DEFVAL(PoolVector2Array()), DEFVAL(Variant()), DEFVAL(Variant()), DEFVAL(false));
ClassDB::bind_method(D_METHOD("draw_string", "font", "position", "text", "modulate", "clip_w"), &CanvasItem::draw_string, DEFVAL(Color(1, 1, 1)), DEFVAL(-1));
ClassDB::bind_method(D_METHOD("draw_char", "font", "position", "char", "next", "modulate"), &CanvasItem::draw_char, DEFVAL(Color(1, 1, 1)));
- ClassDB::bind_method(D_METHOD("draw_mesh", "mesh", "texture", "normal_map", "skeleton"), &CanvasItem::draw_mesh, DEFVAL(Ref<Texture>()), DEFVAL(RID()));
+ ClassDB::bind_method(D_METHOD("draw_mesh", "mesh", "texture", "normal_map"), &CanvasItem::draw_mesh, DEFVAL(Ref<Texture>()));
ClassDB::bind_method(D_METHOD("draw_multimesh", "mesh", "texture", "normal_map"), &CanvasItem::draw_mesh, DEFVAL(Ref<Texture>()));
ClassDB::bind_method(D_METHOD("draw_set_transform", "position", "rotation", "scale"), &CanvasItem::draw_set_transform);
diff --git a/scene/2d/canvas_item.h b/scene/2d/canvas_item.h
index d0bf584b38..980fcb4109 100644
--- a/scene/2d/canvas_item.h
+++ b/scene/2d/canvas_item.h
@@ -283,7 +283,7 @@ public:
void draw_polygon(const Vector<Point2> &p_points, const Vector<Color> &p_colors, const Vector<Point2> &p_uvs = Vector<Point2>(), Ref<Texture> p_texture = Ref<Texture>(), const Ref<Texture> &p_normal_map = Ref<Texture>(), bool p_antialiased = false);
void draw_colored_polygon(const Vector<Point2> &p_points, const Color &p_color, const Vector<Point2> &p_uvs = Vector<Point2>(), Ref<Texture> p_texture = Ref<Texture>(), const Ref<Texture> &p_normal_map = Ref<Texture>(), bool p_antialiased = false);
- void draw_mesh(const Ref<Mesh> &p_mesh, const Ref<Texture> &p_texture, const Ref<Texture> &p_normal_map, RID p_skeleton);
+ void draw_mesh(const Ref<Mesh> &p_mesh, const Ref<Texture> &p_texture, const Ref<Texture> &p_normal_map);
void draw_multimesh(const Ref<MultiMesh> &p_multimesh, const Ref<Texture> &p_texture, const Ref<Texture> &p_normal_map);
void draw_string(const Ref<Font> &p_font, const Point2 &p_pos, const String &p_text, const Color &p_modulate = Color(1, 1, 1), int p_clip_w = -1);
diff --git a/scene/2d/mesh_instance_2d.cpp b/scene/2d/mesh_instance_2d.cpp
index 184942663f..adbb227d0c 100644
--- a/scene/2d/mesh_instance_2d.cpp
+++ b/scene/2d/mesh_instance_2d.cpp
@@ -4,7 +4,7 @@ void MeshInstance2D::_notification(int p_what) {
if (p_what == NOTIFICATION_DRAW) {
if (mesh.is_valid()) {
- draw_mesh(mesh, texture, normal_map, RID());
+ draw_mesh(mesh, texture, normal_map);
}
}
}
diff --git a/scene/2d/skeleton_2d.cpp b/scene/2d/skeleton_2d.cpp
new file mode 100644
index 0000000000..705e82bcbb
--- /dev/null
+++ b/scene/2d/skeleton_2d.cpp
@@ -0,0 +1,210 @@
+#include "skeleton_2d.h"
+
+void Bone2D::_notification(int p_what) {
+
+ if (p_what == NOTIFICATION_ENTER_TREE) {
+ Node *parent = get_parent();
+ parent_bone = Object::cast_to<Bone2D>(parent);
+ skeleton = NULL;
+ while (parent) {
+ skeleton = Object::cast_to<Skeleton2D>(parent);
+ if (skeleton)
+ break;
+ if (!Object::cast_to<Bone2D>(parent))
+ break; //skeletons must be chained to Bone2Ds.
+ }
+
+ if (skeleton) {
+ Skeleton2D::Bone bone;
+ bone.bone = this;
+ skeleton->bones.push_back(bone);
+ skeleton->_make_bone_setup_dirty();
+ }
+ }
+ if (p_what == NOTIFICATION_LOCAL_TRANSFORM_CHANGED) {
+ if (skeleton) {
+ skeleton->_make_transform_dirty();
+ }
+ }
+
+ if (p_what == NOTIFICATION_EXIT_TREE) {
+ if (skeleton) {
+ for (int i = 0; i < skeleton->bones.size(); i++) {
+ if (skeleton->bones[i].bone == this) {
+ skeleton->bones.remove(i);
+ break;
+ }
+ }
+ skeleton->_make_bone_setup_dirty();
+ skeleton = NULL;
+ }
+ parent_bone = NULL;
+ }
+}
+void Bone2D::_bind_methods() {
+
+ ClassDB::bind_method(D_METHOD("set_rest", "rest"), &Bone2D::set_rest);
+ ClassDB::bind_method(D_METHOD("get_rest"), &Bone2D::get_rest);
+ ClassDB::bind_method(D_METHOD("apply_rest"), &Bone2D::apply_rest);
+}
+
+void Bone2D::set_rest(const Transform2D &p_rest) {
+ rest = p_rest;
+ if (skeleton)
+ skeleton->_make_bone_setup_dirty();
+}
+
+Transform2D Bone2D::get_rest() const {
+ return rest;
+}
+
+Transform2D Bone2D::get_skeleton_rest() const {
+
+ if (parent_bone) {
+ return parent_bone->get_skeleton_rest() * rest;
+ } else {
+ return rest;
+ }
+}
+
+void Bone2D::apply_rest() {
+ set_transform(rest);
+}
+
+String Bone2D::get_configuration_warning() const {
+ if (!skeleton) {
+ if (parent_bone) {
+ return TTR("This Bone2D chain should end at a Skeleton2D node.");
+ } else {
+ return TTR("A Bone2D only works with a Skeleton2D or another Bone2D as parent node.");
+ }
+ }
+
+ return Node2D::get_configuration_warning();
+}
+
+Bone2D::Bone2D() {
+ skeleton = NULL;
+ parent_bone = NULL;
+ set_notify_local_transform(true);
+}
+
+//////////////////////////////////////
+
+void Skeleton2D::_make_bone_setup_dirty() {
+
+ if (bone_setup_dirty)
+ return;
+ bone_setup_dirty = true;
+ if (is_inside_tree()) {
+ call_deferred("_update_bone_setup");
+ }
+}
+
+void Skeleton2D::_update_bone_setup() {
+
+ if (!bone_setup_dirty)
+ return;
+
+ bone_setup_dirty = false;
+ VS::get_singleton()->skeleton_allocate(skeleton, bones.size(), true);
+
+ bones.sort(); //sorty so they are always in the same order/index
+
+ for (int i = 0; i < bones.size(); i++) {
+ bones[i].rest_inverse = bones[i].bone->get_skeleton_rest(); //bind pose
+ }
+
+ transform_dirty = true;
+ _update_transform();
+}
+
+void Skeleton2D::_make_transform_dirty() {
+
+ if (transform_dirty)
+ return;
+ transform_dirty = true;
+ if (is_inside_tree()) {
+ call_deferred("_update_transform");
+ }
+}
+
+void Skeleton2D::_update_transform() {
+
+ if (bone_setup_dirty) {
+ _update_bone_setup();
+ return; //above will update transform anyway
+ }
+ if (!transform_dirty)
+ return;
+
+ transform_dirty = false;
+
+ Transform2D global_xform = get_global_transform();
+ Transform2D global_xform_inverse = global_xform.affine_inverse();
+
+ for (int i = 0; i < bones.size(); i++) {
+
+ Transform2D final_xform = bones[i].rest_inverse * bones[i].bone->get_relative_transform_to_parent(this);
+ VS::get_singleton()->skeleton_bone_set_transform_2d(skeleton, i, global_xform * (final_xform * global_xform_inverse));
+ }
+}
+
+int Skeleton2D::get_bone_count() const {
+
+ ERR_FAIL_COND_V(!is_inside_tree(), 0);
+
+ if (bone_setup_dirty) {
+ const_cast<Skeleton2D *>(this)->_update_bone_setup();
+ }
+
+ return bones.size();
+}
+
+Bone2D *Skeleton2D::get_bone(int p_idx) {
+
+ ERR_FAIL_COND_V(!is_inside_tree(), NULL);
+ ERR_FAIL_INDEX_V(p_idx, bones.size(), NULL);
+
+ return bones[p_idx].bone;
+}
+
+void Skeleton2D::_notification(int p_what) {
+
+ if (p_what == NOTIFICATION_READY) {
+
+ if (bone_setup_dirty)
+ _update_bone_setup();
+ if (transform_dirty)
+ _update_transform();
+ }
+
+ if (p_what == NOTIFICATION_TRANSFORM_CHANGED) {
+ _make_transform_dirty();
+ }
+}
+
+RID Skeleton2D::get_skeleton() const {
+ return skeleton;
+}
+void Skeleton2D::_bind_methods() {
+
+ ClassDB::bind_method(D_METHOD("_update_bone_setup"), &Skeleton2D::_update_bone_setup);
+ ClassDB::bind_method(D_METHOD("_update_transform"), &Skeleton2D::_update_transform);
+
+ ClassDB::bind_method(D_METHOD("get_bone_count"), &Skeleton2D::get_bone_count);
+ ClassDB::bind_method(D_METHOD("get_bone"), &Skeleton2D::get_bone);
+
+ ClassDB::bind_method(D_METHOD("get_skeleton"), &Skeleton2D::get_skeleton);
+}
+
+Skeleton2D::Skeleton2D() {
+ bone_setup_dirty = true;
+ transform_dirty = true;
+ skeleton = VS::get_singleton()->skeleton_create();
+}
+
+Skeleton2D::~Skeleton2D() {
+
+ VS::get_singleton()->free(skeleton);
+}
diff --git a/scene/2d/skeleton_2d.h b/scene/2d/skeleton_2d.h
new file mode 100644
index 0000000000..49199f684f
--- /dev/null
+++ b/scene/2d/skeleton_2d.h
@@ -0,0 +1,68 @@
+#ifndef SKELETON_2D_H
+#define SKELETON_2D_H
+
+#include "scene/2d/node_2d.h"
+
+class Skeleton2D;
+
+class Bone2D : public Node2D {
+ GDCLASS(Bone2D, Node2D)
+
+ Bone2D *parent_bone;
+ Skeleton2D *skeleton;
+ Transform2D rest;
+
+protected:
+ void _notification(int p_what);
+ static void _bind_methods();
+
+public:
+ void set_rest(const Transform2D &p_rest);
+ Transform2D get_rest() const;
+ void apply_rest();
+ Transform2D get_skeleton_rest() const;
+
+ String get_configuration_warning() const;
+
+ Bone2D();
+};
+
+class Skeleton2D : public Node2D {
+ GDCLASS(Skeleton2D, Node2D);
+
+ friend class Bone2D;
+
+ struct Bone {
+ bool operator<(const Bone &p_bone) const {
+ return p_bone.bone->is_greater_than(bone);
+ }
+ Bone2D *bone;
+ Transform2D rest_inverse;
+ };
+
+ Vector<Bone> bones;
+
+ bool bone_setup_dirty;
+ void _make_bone_setup_dirty();
+ void _update_bone_setup();
+
+ bool transform_dirty;
+ void _make_transform_dirty();
+ void _update_transform();
+
+ RID skeleton;
+
+protected:
+ void _notification(int p_what);
+ static void _bind_methods();
+
+public:
+ int get_bone_count() const;
+ Bone2D *get_bone(int p_idx);
+
+ RID get_skeleton() const;
+ Skeleton2D();
+ ~Skeleton2D();
+};
+
+#endif // SKELETON_2D_H
diff --git a/scene/3d/audio_stream_player_3d.cpp b/scene/3d/audio_stream_player_3d.cpp
index d448ef024d..c2a50ec7bb 100644
--- a/scene/3d/audio_stream_player_3d.cpp
+++ b/scene/3d/audio_stream_player_3d.cpp
@@ -536,14 +536,14 @@ void AudioStreamPlayer3D::_notification(int p_what) {
setseek = setplay;
active = true;
setplay = -1;
- //do not update, this makes it easier to animate (will shut off otherise)
+ //do not update, this makes it easier to animate (will shut off otherwise)
///_change_notify("playing"); //update property in editor
}
//stop playing if no longer active
if (!active) {
set_physics_process_internal(false);
- //do not update, this makes it easier to animate (will shut off otherise)
+ //do not update, this makes it easier to animate (will shut off otherwise)
//_change_notify("playing"); //update property in editor
emit_signal("finished");
}
diff --git a/scene/gui/dialogs.h b/scene/gui/dialogs.h
index e61ede7c3d..feb080dd06 100644
--- a/scene/gui/dialogs.h
+++ b/scene/gui/dialogs.h
@@ -108,7 +108,7 @@ class AcceptDialog : public WindowDialog {
HBoxContainer *hbc;
Label *label;
Button *ok;
- //Button *cancel; no more cancel (there is X on tht titlebar)
+ //Button *cancel; no more cancel (there is X on that titlebar)
bool hide_on_ok;
void _custom_action(const String &p_action);
diff --git a/scene/gui/file_dialog.cpp b/scene/gui/file_dialog.cpp
index ea687acbb6..4bd92d888d 100644
--- a/scene/gui/file_dialog.cpp
+++ b/scene/gui/file_dialog.cpp
@@ -319,10 +319,10 @@ void FileDialog::deselect_items() {
case MODE_OPEN_FILE:
case MODE_OPEN_FILES:
- get_ok()->set_text(TTR("Open"));
+ get_ok()->set_text(RTR("Open"));
break;
case MODE_OPEN_DIR:
- get_ok()->set_text(TTR("Select Current Folder"));
+ get_ok()->set_text(RTR("Select Current Folder"));
break;
}
}
@@ -339,7 +339,7 @@ void FileDialog::_tree_selected() {
file->set_text(d["name"]);
} else if (mode == MODE_OPEN_DIR) {
- get_ok()->set_text(TTR("Select this Folder"));
+ get_ok()->set_text(RTR("Select this Folder"));
}
get_ok()->set_disabled(_is_open_should_be_disabled());
@@ -843,7 +843,7 @@ FileDialog::FileDialog() {
HBoxContainer *hbc = memnew(HBoxContainer);
dir_up = memnew(ToolButton);
- dir_up->set_tooltip(TTR("Go to parent folder"));
+ dir_up->set_tooltip(RTR("Go to parent folder"));
hbc->add_child(dir_up);
dir_up->connect("pressed", this, "_go_up");
diff --git a/scene/gui/text_edit.cpp b/scene/gui/text_edit.cpp
index f13950461b..95d9173d39 100644
--- a/scene/gui/text_edit.cpp
+++ b/scene/gui/text_edit.cpp
@@ -628,7 +628,7 @@ void TextEdit::_notification(int p_what) {
VisualServer::get_singleton()->canvas_item_add_rect(ci, Rect2(Point2i(), get_size()), cache.background_color);
}
//compute actual region to start (may be inside say, a comment).
- //slow in very large documments :( but ok for source!
+ //slow in very large documents :( but ok for source!
for (int i = 0; i < cursor.line_ofs; i++) {
@@ -4470,7 +4470,7 @@ bool TextEdit::search(const String &p_key, uint32_t p_search_flags, int p_from_l
ERR_FAIL_INDEX_V(p_from_line, text.size(), false);
ERR_FAIL_INDEX_V(p_from_column, text[p_from_line].length() + 1, false);
- //search through the whole documment, but start by current line
+ //search through the whole document, but start by current line
int line = p_from_line;
int pos = -1;
diff --git a/scene/gui/texture_progress.cpp b/scene/gui/texture_progress.cpp
index 01b00c34ea..4a419098a0 100644
--- a/scene/gui/texture_progress.cpp
+++ b/scene/gui/texture_progress.cpp
@@ -158,7 +158,7 @@ void TextureProgress::draw_nine_patch_stretched(const Ref<Texture> &p_texture, F
if (p_ratio < 1.0) {
// Drawing a partially-filled 9-patch is a little tricky -
// texture is divided by 3 sections toward fill direction,
- // then middle section is streching while the other two aren't.
+ // then middle section is stretching while the other two aren't.
double width_total = 0.0;
double width_texture = 0.0;
diff --git a/scene/main/node.cpp b/scene/main/node.cpp
index ac85dd64af..cf22383e36 100644
--- a/scene/main/node.cpp
+++ b/scene/main/node.cpp
@@ -2010,7 +2010,7 @@ void Node::set_editable_instance(Node *p_node, bool p_editable) {
if (!p_editable) {
data.editable_instances.erase(p);
// Avoid this flag being needlessly saved;
- // also give more visual feedback if editable children is reenabled
+ // also give more visual feedback if editable children is re-enabled
set_display_folded(false);
} else {
data.editable_instances[p] = true;
diff --git a/scene/main/node.h b/scene/main/node.h
index 4655071228..341869f7ba 100644
--- a/scene/main/node.h
+++ b/scene/main/node.h
@@ -104,7 +104,7 @@ private:
StringName name;
SceneTree *tree;
bool inside_tree;
- bool ready_notified; //this is a small hack, so if a node is added during _ready() to the tree, it corretly gets the _ready() notification
+ bool ready_notified; //this is a small hack, so if a node is added during _ready() to the tree, it correctly gets the _ready() notification
bool ready_first;
#ifdef TOOLS_ENABLED
NodePath import_path; //path used when imported, used by scene editors to keep tracking
diff --git a/scene/main/scene_tree.cpp b/scene/main/scene_tree.cpp
index 55ae9fe1ec..136fd4cfd1 100644
--- a/scene/main/scene_tree.cpp
+++ b/scene/main/scene_tree.cpp
@@ -1778,7 +1778,7 @@ void SceneTree::_rpc(Node *p_from, int p_to, bool p_unreliable, bool p_set, cons
psc->id = last_send_cache_id++;
}
- //create base packet, lots of harcode because it must be tight
+ //create base packet, lots of hardcode because it must be tight
int ofs = 0;
diff --git a/scene/resources/bit_mask.cpp b/scene/resources/bit_mask.cpp
index 6932a98c17..29ffefd9d6 100644
--- a/scene/resources/bit_mask.cpp
+++ b/scene/resources/bit_mask.cpp
@@ -42,7 +42,7 @@ void BitMap::create(const Size2 &p_size) {
zeromem(bitmask.ptrw(), bitmask.size());
}
-void BitMap::create_from_image_alpha(const Ref<Image> &p_image, float p_treshold) {
+void BitMap::create_from_image_alpha(const Ref<Image> &p_image, float p_threshold) {
ERR_FAIL_COND(p_image.is_null() || p_image->empty());
Ref<Image> img = p_image->duplicate();
@@ -58,7 +58,7 @@ void BitMap::create_from_image_alpha(const Ref<Image> &p_image, float p_treshold
int bbyte = i / 8;
int bbit = i % 8;
- if (r[i * 2 + 1] / 255.0 > p_treshold) {
+ if (r[i * 2 + 1] / 255.0 > p_threshold) {
w[bbyte] |= (1 << bbit);
}
}
@@ -513,7 +513,7 @@ void BitMap::grow_mask(int p_pixels, const Rect2 &p_rect) {
void BitMap::_bind_methods() {
ClassDB::bind_method(D_METHOD("create", "size"), &BitMap::create);
- ClassDB::bind_method(D_METHOD("create_from_image_alpha", "image", "treshold"), &BitMap::create_from_image_alpha, DEFVAL(0.1));
+ ClassDB::bind_method(D_METHOD("create_from_image_alpha", "image", "threshold"), &BitMap::create_from_image_alpha, DEFVAL(0.1));
ClassDB::bind_method(D_METHOD("set_bit", "position", "bit"), &BitMap::set_bit);
ClassDB::bind_method(D_METHOD("get_bit", "position"), &BitMap::get_bit);
diff --git a/scene/resources/bit_mask.h b/scene/resources/bit_mask.h
index d69db00d51..dcd5edb4fb 100644
--- a/scene/resources/bit_mask.h
+++ b/scene/resources/bit_mask.h
@@ -54,7 +54,7 @@ protected:
public:
void create(const Size2 &p_size);
- void create_from_image_alpha(const Ref<Image> &p_image, float p_treshold = 0.1);
+ void create_from_image_alpha(const Ref<Image> &p_image, float p_threshold = 0.1);
void set_bit(const Point2 &p_pos, bool p_value);
bool get_bit(const Point2 &p_pos) const;
diff --git a/scene/resources/material.cpp b/scene/resources/material.cpp
index ceac65ffa7..a83ef198fb 100644
--- a/scene/resources/material.cpp
+++ b/scene/resources/material.cpp
@@ -1482,9 +1482,9 @@ bool SpatialMaterial::is_grow_enabled() const {
return grow_enabled;
}
-void SpatialMaterial::set_alpha_scissor_threshold(float p_treshold) {
- alpha_scissor_threshold = p_treshold;
- VS::get_singleton()->material_set_param(_get_material(), shader_names->alpha_scissor_threshold, p_treshold);
+void SpatialMaterial::set_alpha_scissor_threshold(float p_threshold) {
+ alpha_scissor_threshold = p_threshold;
+ VS::get_singleton()->material_set_param(_get_material(), shader_names->alpha_scissor_threshold, p_threshold);
}
float SpatialMaterial::get_alpha_scissor_threshold() const {
diff --git a/scene/resources/material.h b/scene/resources/material.h
index 10bbcfd642..2c297cda41 100644
--- a/scene/resources/material.h
+++ b/scene/resources/material.h
@@ -566,7 +566,7 @@ public:
void set_grow(float p_grow);
float get_grow() const;
- void set_alpha_scissor_threshold(float p_treshold);
+ void set_alpha_scissor_threshold(float p_threshold);
float get_alpha_scissor_threshold() const;
void set_on_top_of_alpha();
diff --git a/scene/resources/primitive_meshes.h b/scene/resources/primitive_meshes.h
index 1eaa007bd7..94a7a055a3 100644
--- a/scene/resources/primitive_meshes.h
+++ b/scene/resources/primitive_meshes.h
@@ -189,7 +189,7 @@ public:
};
/**
- Similar to quadmesh but with tesselation support
+ Similar to quadmesh but with tessellation support
*/
class PlaneMesh : public PrimitiveMesh {
diff --git a/scene/resources/style_box.cpp b/scene/resources/style_box.cpp
index de75bb3976..f256e0397d 100644
--- a/scene/resources/style_box.cpp
+++ b/scene/resources/style_box.cpp
@@ -650,14 +650,14 @@ void StyleBoxFlat::draw(RID p_canvas_item, const Rect2 &p_rect) const {
style_rect = style_rect.grow(-((aa_size + 1) / 2));
}
- //adapt borders (prevent weired overlapping/glitchy drawings)
+ //adapt borders (prevent weird overlapping/glitchy drawings)
int width = MAX(style_rect.size.width, 0);
int height = MAX(style_rect.size.height, 0);
int adapted_border[4] = { INT_MAX, INT_MAX, INT_MAX, INT_MAX };
adapt_values(MARGIN_TOP, MARGIN_BOTTOM, adapted_border, border_width, height, height, height);
adapt_values(MARGIN_LEFT, MARGIN_RIGHT, adapted_border, border_width, width, width, width);
- //adapt corners (prevent weired overlapping/glitchy drawings)
+ //adapt corners (prevent weird overlapping/glitchy drawings)
int adapted_corner[4] = { INT_MAX, INT_MAX, INT_MAX, INT_MAX };
adapt_values(CORNER_TOP_RIGHT, CORNER_BOTTOM_RIGHT, adapted_corner, corner_radius, height, height - adapted_border[MARGIN_BOTTOM], height - adapted_border[MARGIN_TOP]);
adapt_values(CORNER_TOP_LEFT, CORNER_BOTTOM_LEFT, adapted_corner, corner_radius, height, height - adapted_border[MARGIN_BOTTOM], height - adapted_border[MARGIN_TOP]);
diff --git a/servers/arvr_server.h b/servers/arvr_server.h
index 34f143c0e0..63b7edc73b 100644
--- a/servers/arvr_server.h
+++ b/servers/arvr_server.h
@@ -49,7 +49,7 @@ class ARVRPositionalTracker;
Also each positioning tracker is accessible from here.
I've added some additional info into this header file that should move
- into the documention, I will do so when we're close to accepting this PR
+ into the documentation, I will do so when we're close to accepting this PR
or as a separate PR once this has been merged into the master branch.
**/
diff --git a/servers/audio_server.cpp b/servers/audio_server.cpp
index 5c453a3113..783788a6a1 100644
--- a/servers/audio_server.cpp
+++ b/servers/audio_server.cpp
@@ -153,7 +153,7 @@ void AudioDriverManager::initialize(int p_driver) {
ERR_PRINT("AudioDriverManager: all drivers failed, falling back to dummy driver");
dummy_driver.set_singleton();
} else {
- ERR_PRINT("AudioDriverManager: dummy driver faild to init()");
+ ERR_PRINT("AudioDriverManager: dummy driver failed to init()");
}
}
@@ -858,7 +858,7 @@ void AudioServer::init() {
channel_disable_threshold_db = GLOBAL_DEF("audio/channel_disable_threshold_db", -60.0);
channel_disable_frames = float(GLOBAL_DEF("audio/channel_disable_time", 2.0)) * get_mix_rate();
- buffer_size = 1024; //harcoded for now
+ buffer_size = 1024; //hardcoded for now
temp_buffer.resize(get_channel_count());
diff --git a/servers/visual/rasterizer.h b/servers/visual/rasterizer.h
index 378a05cdfe..8bf112b0de 100644
--- a/servers/visual/rasterizer.h
+++ b/servers/visual/rasterizer.h
@@ -749,7 +749,6 @@ public:
struct CommandMesh : public Command {
RID mesh;
- RID skeleton;
RID texture;
RID normal_map;
CommandMesh() { type = TYPE_MESH; }
@@ -758,7 +757,6 @@ public:
struct CommandMultiMesh : public Command {
RID multimesh;
- RID skeleton;
RID texture;
RID normal_map;
CommandMultiMesh() { type = TYPE_MULTIMESH; }
@@ -924,7 +922,7 @@ public:
case Item::Command::TYPE_MESH: {
const Item::CommandMesh *mesh = static_cast<const Item::CommandMesh *>(c);
- AABB aabb = RasterizerStorage::base_singleton->mesh_get_aabb(mesh->mesh, mesh->skeleton);
+ AABB aabb = RasterizerStorage::base_singleton->mesh_get_aabb(mesh->mesh, RID());
r = Rect2(aabb.position.x, aabb.position.y, aabb.size.x, aabb.size.y);
@@ -1016,7 +1014,7 @@ public:
virtual void canvas_begin() = 0;
virtual void canvas_end() = 0;
- virtual void canvas_render_items(Item *p_item_list, int p_z, const Color &p_modulate, Light *p_light) = 0;
+ virtual void canvas_render_items(Item *p_item_list, int p_z, const Color &p_modulate, Light *p_light, const Transform2D &p_base_transform) = 0;
virtual void canvas_debug_viewport_shadows(Light *p_lights_with_shadow) = 0;
struct LightOccluderInstance : public RID_Data {
diff --git a/servers/visual/visual_server_canvas.cpp b/servers/visual/visual_server_canvas.cpp
index 330b2bd0d2..3e6e524117 100644
--- a/servers/visual/visual_server_canvas.cpp
+++ b/servers/visual/visual_server_canvas.cpp
@@ -46,7 +46,7 @@ void VisualServerCanvas::_render_canvas_item_tree(Item *p_canvas_item, const Tra
for (int i = 0; i < z_range; i++) {
if (!z_list[i])
continue;
- VSG::canvas_render->canvas_render_items(z_list[i], VS::CANVAS_ITEM_Z_MIN + i, p_modulate, p_lights);
+ VSG::canvas_render->canvas_render_items(z_list[i], VS::CANVAS_ITEM_Z_MIN + i, p_modulate, p_lights, p_transform);
}
}
@@ -214,7 +214,7 @@ void VisualServerCanvas::render_canvas(Canvas *p_canvas, const Transform2D &p_tr
_light_mask_canvas_items(VS::CANVAS_ITEM_Z_MIN + i, z_list[i], p_masked_lights);
}
- VSG::canvas_render->canvas_render_items(z_list[i], VS::CANVAS_ITEM_Z_MIN + i, p_canvas->modulate, p_lights);
+ VSG::canvas_render->canvas_render_items(z_list[i], VS::CANVAS_ITEM_Z_MIN + i, p_canvas->modulate, p_lights, p_transform);
}
} else {
@@ -742,7 +742,7 @@ void VisualServerCanvas::canvas_item_add_set_transform(RID p_item, const Transfo
canvas_item->commands.push_back(tr);
}
-void VisualServerCanvas::canvas_item_add_mesh(RID p_item, const RID &p_mesh, RID p_texture, RID p_normal_map, RID p_skeleton) {
+void VisualServerCanvas::canvas_item_add_mesh(RID p_item, const RID &p_mesh, RID p_texture, RID p_normal_map) {
Item *canvas_item = canvas_item_owner.getornull(p_item);
ERR_FAIL_COND(!canvas_item);
@@ -752,7 +752,6 @@ void VisualServerCanvas::canvas_item_add_mesh(RID p_item, const RID &p_mesh, RID
m->mesh = p_mesh;
m->texture = p_texture;
m->normal_map = p_normal_map;
- m->skeleton = p_skeleton;
canvas_item->commands.push_back(m);
}
@@ -776,7 +775,7 @@ void VisualServerCanvas::canvas_item_add_particles(RID p_item, RID p_particles,
canvas_item->commands.push_back(part);
}
-void VisualServerCanvas::canvas_item_add_multimesh(RID p_item, RID p_mesh, RID p_texture, RID p_normal_map, RID p_skeleton) {
+void VisualServerCanvas::canvas_item_add_multimesh(RID p_item, RID p_mesh, RID p_texture, RID p_normal_map) {
Item *canvas_item = canvas_item_owner.getornull(p_item);
ERR_FAIL_COND(!canvas_item);
@@ -784,7 +783,6 @@ void VisualServerCanvas::canvas_item_add_multimesh(RID p_item, RID p_mesh, RID p
Item::CommandMultiMesh *mm = memnew(Item::CommandMultiMesh);
ERR_FAIL_COND(!mm);
mm->multimesh = p_mesh;
- mm->skeleton = p_skeleton;
mm->texture = p_texture;
mm->normal_map = p_normal_map;
@@ -826,6 +824,15 @@ void VisualServerCanvas::canvas_item_set_z_as_relative_to_parent(RID p_item, boo
canvas_item->z_relative = p_enable;
}
+
+void VisualServerCanvas::canvas_item_attach_skeleton(RID p_item, RID p_skeleton) {
+
+ Item *canvas_item = canvas_item_owner.getornull(p_item);
+ ERR_FAIL_COND(!canvas_item);
+
+ canvas_item->skeleton = p_skeleton;
+}
+
void VisualServerCanvas::canvas_item_set_copy_to_backbuffer(RID p_item, bool p_enable, const Rect2 &p_rect) {
Item *canvas_item = canvas_item_owner.getornull(p_item);
diff --git a/servers/visual/visual_server_canvas.h b/servers/visual/visual_server_canvas.h
index 250ba5cb08..6a5a7623b6 100644
--- a/servers/visual/visual_server_canvas.h
+++ b/servers/visual/visual_server_canvas.h
@@ -51,6 +51,8 @@ public:
Vector<Item *> child_items;
+ RID skeleton;
+
Item() {
children_order_dirty = true;
E = NULL;
@@ -182,8 +184,8 @@ public:
void canvas_item_add_primitive(RID p_item, const Vector<Point2> &p_points, const Vector<Color> &p_colors, const Vector<Point2> &p_uvs, RID p_texture, float p_width = 1.0, RID p_normal_map = RID());
void canvas_item_add_polygon(RID p_item, const Vector<Point2> &p_points, const Vector<Color> &p_colors, const Vector<Point2> &p_uvs = Vector<Point2>(), RID p_texture = RID(), RID p_normal_map = RID(), bool p_antialiased = false);
void canvas_item_add_triangle_array(RID p_item, const Vector<int> &p_indices, const Vector<Point2> &p_points, const Vector<Color> &p_colors, const Vector<Point2> &p_uvs = Vector<Point2>(), RID p_texture = RID(), int p_count = -1, RID p_normal_map = RID());
- void canvas_item_add_mesh(RID p_item, const RID &p_mesh, RID p_texture = RID(), RID p_normal_map = RID(), RID p_skeleton = RID());
- void canvas_item_add_multimesh(RID p_item, RID p_mesh, RID p_texture = RID(), RID p_normal_map = RID(), RID p_skeleton = RID());
+ void canvas_item_add_mesh(RID p_item, const RID &p_mesh, RID p_texture = RID(), RID p_normal_map = RID());
+ void canvas_item_add_multimesh(RID p_item, RID p_mesh, RID p_texture = RID(), RID p_normal_map = RID());
void canvas_item_add_particles(RID p_item, RID p_particles, RID p_texture, RID p_normal, int p_h_frames, int p_v_frames);
void canvas_item_add_set_transform(RID p_item, const Transform2D &p_transform);
void canvas_item_add_clip_ignore(RID p_item, bool p_ignore);
@@ -191,6 +193,7 @@ public:
void canvas_item_set_z_index(RID p_item, int p_z);
void canvas_item_set_z_as_relative_to_parent(RID p_item, bool p_enable);
void canvas_item_set_copy_to_backbuffer(RID p_item, bool p_enable, const Rect2 &p_rect);
+ void canvas_item_attach_skeleton(RID p_item, RID p_skeleton);
void canvas_item_clear(RID p_item);
void canvas_item_set_draw_index(RID p_item, int p_index);
diff --git a/servers/visual/visual_server_raster.h b/servers/visual/visual_server_raster.h
index b34fbbdec9..a94e110b5d 100644
--- a/servers/visual/visual_server_raster.h
+++ b/servers/visual/visual_server_raster.h
@@ -581,8 +581,8 @@ public:
BIND7(canvas_item_add_primitive, RID, const Vector<Point2> &, const Vector<Color> &, const Vector<Point2> &, RID, float, RID)
BIND7(canvas_item_add_polygon, RID, const Vector<Point2> &, const Vector<Color> &, const Vector<Point2> &, RID, RID, bool)
BIND8(canvas_item_add_triangle_array, RID, const Vector<int> &, const Vector<Point2> &, const Vector<Color> &, const Vector<Point2> &, RID, int, RID)
- BIND5(canvas_item_add_mesh, RID, const RID &, RID, RID, RID)
- BIND5(canvas_item_add_multimesh, RID, RID, RID, RID, RID)
+ BIND4(canvas_item_add_mesh, RID, const RID &, RID, RID)
+ BIND4(canvas_item_add_multimesh, RID, RID, RID, RID)
BIND6(canvas_item_add_particles, RID, RID, RID, RID, int, int)
BIND2(canvas_item_add_set_transform, RID, const Transform2D &)
BIND2(canvas_item_add_clip_ignore, RID, bool)
@@ -590,6 +590,7 @@ public:
BIND2(canvas_item_set_z_index, RID, int)
BIND2(canvas_item_set_z_as_relative_to_parent, RID, bool)
BIND3(canvas_item_set_copy_to_backbuffer, RID, bool, const Rect2 &)
+ BIND2(canvas_item_attach_skeleton, RID, RID)
BIND1(canvas_item_clear, RID)
BIND2(canvas_item_set_draw_index, RID, int)
diff --git a/servers/visual/visual_server_wrap_mt.h b/servers/visual/visual_server_wrap_mt.h
index 5a126fb175..b91f80d137 100644
--- a/servers/visual/visual_server_wrap_mt.h
+++ b/servers/visual/visual_server_wrap_mt.h
@@ -499,8 +499,8 @@ public:
FUNC7(canvas_item_add_primitive, RID, const Vector<Point2> &, const Vector<Color> &, const Vector<Point2> &, RID, float, RID)
FUNC7(canvas_item_add_polygon, RID, const Vector<Point2> &, const Vector<Color> &, const Vector<Point2> &, RID, RID, bool)
FUNC8(canvas_item_add_triangle_array, RID, const Vector<int> &, const Vector<Point2> &, const Vector<Color> &, const Vector<Point2> &, RID, int, RID)
- FUNC5(canvas_item_add_mesh, RID, const RID &, RID, RID, RID)
- FUNC5(canvas_item_add_multimesh, RID, RID, RID, RID, RID)
+ FUNC4(canvas_item_add_mesh, RID, const RID &, RID, RID)
+ FUNC4(canvas_item_add_multimesh, RID, RID, RID, RID)
FUNC6(canvas_item_add_particles, RID, RID, RID, RID, int, int)
FUNC2(canvas_item_add_set_transform, RID, const Transform2D &)
FUNC2(canvas_item_add_clip_ignore, RID, bool)
@@ -508,6 +508,7 @@ public:
FUNC2(canvas_item_set_z_index, RID, int)
FUNC2(canvas_item_set_z_as_relative_to_parent, RID, bool)
FUNC3(canvas_item_set_copy_to_backbuffer, RID, bool, const Rect2 &)
+ FUNC2(canvas_item_attach_skeleton, RID, RID)
FUNC1(canvas_item_clear, RID)
FUNC2(canvas_item_set_draw_index, RID, int)
diff --git a/servers/visual_server.h b/servers/visual_server.h
index 521d0aece9..537588fd6f 100644
--- a/servers/visual_server.h
+++ b/servers/visual_server.h
@@ -846,8 +846,8 @@ public:
virtual void canvas_item_add_primitive(RID p_item, const Vector<Point2> &p_points, const Vector<Color> &p_colors, const Vector<Point2> &p_uvs, RID p_texture, float p_width = 1.0, RID p_normal_map = RID()) = 0;
virtual void canvas_item_add_polygon(RID p_item, const Vector<Point2> &p_points, const Vector<Color> &p_colors, const Vector<Point2> &p_uvs = Vector<Point2>(), RID p_texture = RID(), RID p_normal_map = RID(), bool p_antialiased = false) = 0;
virtual void canvas_item_add_triangle_array(RID p_item, const Vector<int> &p_indices, const Vector<Point2> &p_points, const Vector<Color> &p_colors, const Vector<Point2> &p_uvs = Vector<Point2>(), RID p_texture = RID(), int p_count = -1, RID p_normal_map = RID()) = 0;
- virtual void canvas_item_add_mesh(RID p_item, const RID &p_mesh, RID p_texture = RID(), RID p_normal_map = RID(), RID p_skeleton = RID()) = 0;
- virtual void canvas_item_add_multimesh(RID p_item, RID p_mesh, RID p_texture = RID(), RID p_normal_map = RID(), RID p_skeleton = RID()) = 0;
+ virtual void canvas_item_add_mesh(RID p_item, const RID &p_mesh, RID p_texture = RID(), RID p_normal_map = RID()) = 0;
+ virtual void canvas_item_add_multimesh(RID p_item, RID p_mesh, RID p_texture = RID(), RID p_normal_map = RID()) = 0;
virtual void canvas_item_add_particles(RID p_item, RID p_particles, RID p_texture, RID p_normal_map, int p_h_frames, int p_v_frames) = 0;
virtual void canvas_item_add_set_transform(RID p_item, const Transform2D &p_transform) = 0;
virtual void canvas_item_add_clip_ignore(RID p_item, bool p_ignore) = 0;
@@ -856,6 +856,8 @@ public:
virtual void canvas_item_set_z_as_relative_to_parent(RID p_item, bool p_enable) = 0;
virtual void canvas_item_set_copy_to_backbuffer(RID p_item, bool p_enable, const Rect2 &p_rect) = 0;
+ virtual void canvas_item_attach_skeleton(RID p_item, RID p_skeleton) = 0;
+
virtual void canvas_item_clear(RID p_item) = 0;
virtual void canvas_item_set_draw_index(RID p_item, int p_index) = 0;