Commit graph

7954 commits

Author SHA1 Message Date
Joan Fons a6adb58493 Editor StringName and Viewport optimizations
* Added explicit return type to the SNAME macro.
* Add some extra SNAME usages.
* Change some ClassDB methods to use const StringName & arguments.
* Cache the Window parent in Control because it's used in
  is_layout_rtl(), which is called often.
* Only enable internal processing for viewports that need it.
* Change CanvasItem::group to be a StringName because it's only used as
  that.
2021-07-20 20:35:41 +02:00
Rémi Verschelde dfc1ec7fb9
Merge pull request #50606 from Chaosus/textedit_fix_guttertype
Fixed typos in `TextEdit::GutterType` enum
2021-07-19 16:40:42 +02:00
Rémi Verschelde 855c7c7414
Merge pull request #50566 from reduz/optimize-stringname-usage
Optimize StringName usage
2021-07-19 15:20:25 +02:00
Yuri Roubinsky 1597045b09 Fixed typos in TextEdit::GutterType enum 2021-07-19 11:18:54 +03:00
Rémi Verschelde 95def293a6
Merge pull request #48186 from EricEzaM/PR/tooltip-improvements
Made default tooltips (non-custom ones) disappear on mouse enter.
2021-07-19 09:02:06 +02:00
reduz 6631f66c2a Optimize StringName usage
* Added a new macro SNAME() that constructs and caches a local stringname.
* Subsequent usages use the cached version.
* Since these use a global static variable, a second refcounter of static usages need to be kept for cleanup time.
* Replaced all theme usages by this new macro.
* Replace all signal emission usages by this new macro.
* Replace all call_deferred usages by this new macro.

This is part of ongoing work to optimize GUI and the editor.
2021-07-18 21:20:02 -03:00
Yuri Roubinsky d63a284dff Prevent function gen in visual shader if no out connection is provided 2021-07-17 22:51:22 +03:00
reduz a3fb76cd45 Create many types of popups on demand
* LineEdit popups created on demand.
* TextEdit popups created on demand.
* SpinSlider popups created on demand.
* ResourcePicker popups created on demand.

Improves editor responsiveness.
2021-07-17 10:57:14 -03:00
Hugo Locurcio 523d6b2ae8
Merge pull request #47395 from sygi/shape_idx_collision
Add shape_idx to CollisionObject2D mouse_entered signal
2021-07-16 19:05:08 +02:00
Rémi Verschelde 60add98a4c
Merge pull request #49328 from nekomatata/sync-to-physics-3d
Support for 3D sync to physics
2021-07-15 23:18:59 +02:00
PouleyKetchoupp 7f92127959 Support for 3D sync to physics
Same implementation as in 2D.
2021-07-15 10:15:13 -07:00
PouleyKetchoupp d12b44ca13 Move sync to physics to StaticBody2D
Now static body is used for moving platforms through kinematic motion
property, so sync to physics needs to be in StaticBody2D instead of
CharacterBody2D.

Constant kinematic motion is also supported in combination with sync to
physics for smoother movements.
2021-07-15 10:13:27 -07:00
Rémi Verschelde f79e79d479
Merge pull request #38819 from EricEzaM/improve-to_string-for-nodes
Added Node name to print() of all Nodes by making to_string() in Object virtual, so it can be overriden in C++.
2021-07-15 15:11:21 +02:00
Eric M 3ca25ffe8a Added Node name to print() when printing Nodes. 2021-07-15 21:48:58 +10:00
fabriceci cee814e4df Fixing 2D moving platform logic
Fixing by applying the movement in two steps, first the platform
movement, and then the body movement. Plus, add the platform movement
when we are on_wall.
2021-07-15 11:54:43 +02:00
Rémi Verschelde 29c56f33a4
Merge pull request #48502 from KoBeWi/visual_button
Add set_pressed_no_signal method to BaseButton
2021-07-14 15:05:50 +02:00
Rémi Verschelde 8f6240a275
Merge pull request #49348 from Geometror/fix-particles-hidden-basecolor
Fix color properties of particle nodes/material
2021-07-14 15:05:20 +02:00
Rémi Verschelde 536825d004
Rename Curve3Texture to CurveXYZTexture
Neither name is a perfect match but `Curve3Texture` looked too similar to
`CurveTexture` and `Curve3D`, which made things confusing when picking a
texture type or browsing the API reference.
2021-07-14 00:30:58 +02:00
Rémi Verschelde bc6ea71771
Merge pull request #50063 from nekomatata/more-accurate-move-and-slide
Make move_and_slide collision detection more accurate
2021-07-13 20:41:09 +02:00
Rémi Verschelde 79137a0260
Merge pull request #50299 from YeldhamDev/window_wrap_controls_fix
Fix `Window`'s `wrap_controls` not actually doing anything
2021-07-13 18:04:33 +02:00
Rémi Verschelde b61b30e6ff
Merge pull request #50420 from KoBeWi/counter_headers
Add header theme type variations to labels
2021-07-13 17:57:03 +02:00
kobewi f4b361dd15 Add header theme type variations to labels 2021-07-13 15:42:09 +02:00
Rémi Verschelde 8747f25653
Merge pull request #50381 from reduz/implement-disable-classes
Implement the ability to disable classes
2021-07-13 15:31:38 +02:00
Rémi Verschelde b44b277f6f
Merge pull request #50169 from pycbouh/theme-type-variations 2021-07-13 15:13:00 +02:00
reduz 5ad4f26659 Implement the ability to disable classes
* This PR adds the ability to disable classes when building.
* For now it's only possible to do this via command like:
  `scons disable_classes=RayCast2D,Area3D`
* Eventually, a proper UI will be implemented to create a build config file to do this at large scale, as well as detect what is used in the project.
2021-07-13 09:25:14 -03:00
kobewi 50c63bdc4c Add set_pressed_no_signal method to BaseButton 2021-07-13 13:57:26 +02:00
Rémi Verschelde aab6dc301c
Merge pull request #50086 from Geometror/label-improve-layout-options
Improvements to Label's layout options
2021-07-13 13:10:42 +02:00
Rémi Verschelde f2ad067509
Merge pull request #48375 from bowling-allie/discrete-carry-bug 2021-07-13 10:33:34 +02:00
Rémi Verschelde 3adb129a54
Merge pull request #50135 from KoBeWi/🌲.update()
Update Tree when modified
2021-07-13 09:03:40 +02:00
Rémi Verschelde 65486cd15e
Merge pull request #50401 from Calinou/decal-add-node-configuration-warnings
Add node configuration warnings for the Decal node
2021-07-13 08:13:21 +02:00
Hugo Locurcio 1bbdc5cc65
Add node configuration warnings for the Decal node 2021-07-13 01:57:59 +02:00
Yuri Sizov 4ee0e6ddf5 Add type variations to Theme 2021-07-13 02:26:28 +03:00
Rémi Verschelde fc00a83901
Merge pull request #50262 from nekomatata/convex-hull-simplification
Options to clean/simplify convex hull generated from mesh
2021-07-12 22:15:40 +02:00
Rémi Verschelde 30d4732623
Merge pull request #50389 from Chaosus/vs_uniform_ref
Auto-set a first compatible uniform on dragging to create a UniformRef (VisualShaders)
2021-07-12 19:24:27 +02:00
Fabio Alessandrelli 88d68346ee [Net] Rename NetworkedMultiplayerPeer to MultiplayerPeer. 2021-07-12 16:36:34 +02:00
Fabio Alessandrelli 31142ac3ee [Net] Remove most multiplayer hooks from SceneTree.
Use `multiplayer` or `get_multiplayer()` instead of `get_tree()`.
2021-07-12 15:28:01 +02:00
Yuri Roubinsky 7d34701d63 Auto-set a first compatible uniform on dragging to create a UniformRef 2021-07-12 11:19:42 +03:00
QbieShay c4d8eecfe5 added offset for plane mesh and quad mesh 2021-07-11 14:33:08 +02:00
Yuri Roubinsky 9d4afa8b75
Merge pull request #50149 from Chaosus/vs_curve3d 2021-07-11 12:36:56 +03:00
Hugo Locurcio a2d5f191d8
Merge pull request #48622 from Geometror/reimplement-disableable-vsync 2021-07-10 01:02:23 +02:00
Michael Alexsander fe5605334a Fix Window's wrap_controls not actually doing anything 2021-07-08 20:06:16 -03:00
Rémi Verschelde 47e5fed485
Merge pull request #50261 from Razoric480/cache-color-picker-presets
Add cache to ColorPicker for color presets
2021-07-07 23:31:24 +02:00
PouleyKetchoupp 1de995ae99 Options to clean/simplify convex hull generated from mesh
Clean: remove duplicate and interior vertices (uses Bullet algorithm)
Simplify: modify the geometry for further simplification (uses VHACD
algorithm)

In the editor, single convex hull now uses the clean option.
Added a new editor entry to create a simplified convex hull, can be
useful for creating convex hull from highly tessellated triangle meshes.
2021-07-07 12:14:12 -07:00
Francois Belair 94a464f555 Add cache to color picker for presets
This prevents loading from the project metadata more than once,
significantly saving performance with nodes that have color pickers.
2021-07-07 14:17:44 -04:00
Hugo Locurcio 2c7813385d
Tweak the GradientTexture property hint to follow CurveTexture
This prevents setting too large values and crashing the editor.

Very low values are also no longer allowed since they are generally
not detailed enough to represent complex gradients, leading to confusion.
2021-07-07 19:17:02 +02:00
Rémi Verschelde 48a5226829
Merge pull request #50193 from reduz/fix-command-queue-crash
Fix Command Queue Crash
2021-07-07 16:36:13 +02:00
Rémi Verschelde f62da984af
Merge pull request #50214 from Calinou/occluderinstance3d-add-node-configuration-warnings
Add node configuration warnings to OccluderInstance3D
2021-07-07 16:04:02 +02:00
reduz d41e3f9aeb Fix Command Queue Crash
* No longer allow sending an object (texture) to the server as material parameter
* Keep a parameter cache locally in ShaderMaterial
2021-07-07 10:57:56 -03:00
Hugo Locurcio 8cc147076c
Add node configuration warnings to OccluderInstance3D 2021-07-07 13:59:52 +02:00
Rémi Verschelde e4c940ee6a
Merge pull request #50208 from kleonc/accept_dialog-remove_button
Add AcceptDialog::remove_button method
2021-07-07 09:12:03 +02:00