Commit graph

37264 commits

Author SHA1 Message Date
Louis Dumont 79578a5625 Fixed crash when parsing an empty assignment.
Resolves #51620.
2021-08-25 18:48:08 +02:00
Max Hilbrunner ee4a8e6a85
Merge pull request #52087 from raulsntos/expose-simplify-path
Expose `String.SimplifyPath` in C#
2021-08-25 18:37:08 +02:00
Max Hilbrunner 4308800fba
Merge pull request #52086 from raulsntos/rename-string-is-abs-path-method
Rename `String.IsAbsPath()` to `String.IsAbsolutePath()`
2021-08-25 18:36:20 +02:00
Hugo Locurcio 181d93ed94
Merge pull request #52103 from Calinou/ci-diffs-color-codes
Print colored diffs when there are formatting failures in CI
2021-08-25 18:31:56 +02:00
PouleyKetchoupp 6a9ed72185 Clean physics direct body state usage in 2D and 3D physics
Use a C++ callback instead of Callable for synchronizing physics nodes' state with physics servers.

Remove usage of PhysicsDirectBodyState in physics nodes when not
necessary.

Store PhysicsDirectBodyState for bodies individually instead of a
singleton to avoid issues when accessing direct body state for multiple
bodies.

PhysicsDirectBodyState is initialized only when needed, so it doesn't
have to be created when using the physics server directly.

Move PhysicsDirectBodyState2D and PhysicsDirectBodyState3D to separate
cpp files.
2021-08-25 08:57:42 -07:00
Hugo Locurcio 38424714b1
Print colored diffs when there are formatting failures in CI
This makes diffs more readable in CI logs.
2021-08-25 17:17:29 +02:00
Hugo Locurcio 9c2ec6e697
Add a README to link to the GDScript integration tests documentation
This makes the documentation about creating and running GDScript
integration tests more discoverable.
2021-08-25 16:51:28 +02:00
Raul Santos 126b1ea149 Expose String.SimplifyPath in C# 2021-08-25 16:51:14 +02:00
JFonS 353bb45e21
Merge pull request #51995 from drcd1/sphere-mesh-normals-fix
Fixes the normals of SphereMesh when the sphere/hemisphere is oblong
2021-08-25 16:22:20 +02:00
George Marques c3378d5650
Merge pull request #52098 from mhilbrunner/fix-ci
Fix CI after concurrency
2021-08-25 10:40:23 -03:00
Max Hilbrunner 5139a19877 Fix CI after concurrency 2021-08-25 15:04:05 +02:00
K. S. Ernest (iFire) Lee 04e1aa4328
Merge pull request #52079 from mhilbrunner/ci-concurrency
CI: Cancel previous builds if new commit is pushed
2021-08-25 05:56:07 -07:00
Max Hilbrunner 40bb1ded7e CI: Cancel previous builds if new commit is pushed 2021-08-25 14:54:48 +02:00
Max Hilbrunner 4bb65b2bc6
Merge pull request #52023 from mhilbrunner/vs-fix-reloaded
Fix VisualScriptEditor after namespaces
2021-08-25 14:41:28 +02:00
Morris Tabor 75dd294732 Fix emitting duplicate edges for convex hulls
Identical to https://github.com/godotengine/godot/pull/52059
2021-08-25 14:18:45 +02:00
reduz e2f8df8c5b Add ability to register singletons from engine API
* Exposed functions in Engine to register and unregister singletons.
* Added the concept of user singletons, which can be removed (the system ones can't).
2021-08-25 08:32:25 -03:00
kleonc d35ef5fab0 Tree Fix line rendering when drag and dropping TreeItem 2021-08-25 13:29:54 +02:00
JFonS c334989e00
Merge pull request #51821 from Calinou/builtin-shaders-add-comments
Add comments at the top of each built-in shader to ease debugging
2021-08-25 11:37:57 +02:00
Hugo Locurcio 6a6c0890c2
Remove leftovers of anisotropy in the VoxelGI shader code
Anisotropy support was removed when VoxelGI was reworked as it was
too demanding on the GPU.
2021-08-25 10:23:28 +02:00
Hugo Locurcio bb0122c933
Merge pull request #48374 from Calinou/gradienttexture-add-hdr-property
Add an `use_hdr` property to GradientTexture to allow storing HDR colors
2021-08-25 08:03:34 +02:00
Hugo Locurcio 3db8359324
Merge pull request #47829 from Calinou/improve-crash-handler-display
Improve crash handler message display
2021-08-25 08:03:10 +02:00
K. S. Ernest (iFire) Lee 24f562bd1e
Merge pull request #52024 from V-Sekai/anim-length
Calculate proper animation length.
2021-08-24 19:29:02 -07:00
K. S. Ernest (iFire) Lee ffe54af0db Calculate proper animation length. 2021-08-24 18:50:22 -07:00
Raul Santos 4e6e6bcd2f Rename String.IsAbsPath() to String.IsAbsolutePath() 2021-08-25 03:02:55 +02:00
PouleyKetchoupp 3d5dc80348 Rename RayShape to SeparationRayShape
Makes it clearer that it's used for special cases when picking a
collision shape.
2021-08-24 17:34:55 -07:00
PouleyKetchoupp aa4791735d Rename slips_on_slope to slide_on_slope
Also added some precision to the documentation.
2021-08-24 17:34:55 -07:00
PouleyKetchoupp d9720d4395 Fix CharacterBody motion with RayShape
Make separation ray shapes work properly in move_and_slide, wihtout the
specific code in CharacterBody like before.

Now most of the logic is handled inside the physics server. The only
thing that's needed is to use ray shapes only for recovery and ignore
them when performing the motion itself (unless we're snapping or slips
on slope is on).
2021-08-24 17:34:55 -07:00
PouleyKetchoupp 829fb4fba1 Fix RayShape collision detection
One-way collision is disabled for both rigid bodies and character
bodies.

Kinematic margin is now applied to ray shapes to help getting consistent
results in slopes and flat surfaces.

Convex shapes don't return inverted normals when a segment test starts
inside (raycasting will be made consistent in a separate patch).

Ray shapes also discard contacts when fully contained inside a shape
and when the contact direction is inverted, so the behavior is
consistent with all shape types. Now they always separate only when
intersecting the top of a shape (for downward rays).
2021-08-24 16:03:05 -07:00
PouleyKetchoupp 45c7af9862 Restore RayShape as a regular shape type
Partial revert from previously removing ray shapes completely, added
back as a shape type but without the specific character controller code.
2021-08-24 16:03:05 -07:00
Camille Mohr-Daurat c89a5fb8be
Merge pull request #51904 from nekomatata/move-and-slide-fixes-3d
Port recent move_and_slide fixes to 3D
2021-08-24 16:01:12 -07:00
William Deurwaarder d875706e01 RichTextLabel returns member (Array) for custom effects for Editor
As RichTextLabel returned a copy of the member (Vector) the editor was notified
that the value had changed which caused the dropdown menu to be immediately
closed after opening.

The fix is to return the member (Array) in stead of a copy which is the same
instance and thereby does not notify the editor that the value has changed.
2021-08-24 22:02:24 +02:00
PouleyKetchoupp bae06008c8 Port recent move_and_slide fixes to 3D
Improves stop on slopes, sliding on walls and gravity handling by
porting existing changes from CharacterBody2D to CharacterBody3D.

Co-authored-by: fabriceci <fabricecipolla@gmail.com>
2021-08-24 11:30:01 -07:00
reduz 96f8254b24 Implement error return documetation
Adds ability to add error return documetation to the binder and class reference.
Usage example:

```C++
void MyClass::_bind_method() {
	[..]
	BIND_METHOD_ERR_RETURN_DOC("load", ERR_FILE_CANT_OPEN, ERR_FILE_UNRECOGNIZED);
}
```

One function of ConfigFile was changed as example.
2021-08-24 15:28:29 -03:00
Max Hilbrunner c314203a70 Fix Visual Script editor 2021-08-24 19:33:40 +02:00
PouleyKetchoupp 9c9e528e3e Fix point gravity calculation
Removing the + 1 in point gravity formula when using distance scale to
make it more accurate for standard gravitation.

Fixes precession in orbits for games using gravitation.

Also moved gravity calculation to area to use it for both rigid bodies
and soft bodies in 3D (same change in 2D for consistency).

Co-authored-by: Ryan Peach <ryan.peach@keysight.com>
2021-08-24 09:32:28 -07:00
Max Hilbrunner ca7f53dd25
Merge pull request #52001 from floppyhammer/fix-window-decor-size-on-windows
Fix window decoration size on Windows
2021-08-24 17:28:47 +02:00
Max Hilbrunner 7e0f1fa2ec
Merge pull request #52041 from Rubonnek/expose-simplify-path
Expose `String.simplify_path`
2021-08-24 17:06:16 +02:00
Michael Alexsander 9500950af6
Merge pull request #52067 from timothyqiu/rtl-cursor
Make `RichTextLabel` honour default cursor shape property
2021-08-24 14:45:55 +00:00
Max Hilbrunner 8a2730cac3
Merge pull request #52044 from Rubonnek/update-string-abs-rel-docs
Update documentation for is_absolute_path and is_rel_path
2021-08-24 16:24:18 +02:00
Juan Linietsky 61141793ca
Merge pull request #51999 from lyuma/set_surface_material
Implement methods in EditorSceneImporterMesh, and add documentation.
2021-08-24 11:17:48 -03:00
Haoyu Qiu d12cceadd2 Make RichTextLabel honour default cursor shape property 2021-08-24 22:07:42 +08:00
Juan Linietsky 6609ce1944
Merge pull request #52000 from lyuma/set_editable_instance
Make Node editable_instance methods available to GDScript
2021-08-24 08:31:34 -03:00
Wilson E. Alvarez 17821603b4
Expose String.simplify_path 2021-08-24 00:48:45 -04:00
Lyuma 7eb6ae2798 Make Node editable_instance methods available to GDScript 2021-08-23 21:45:18 -07:00
Ignacio Roldán Etcheverry e95fa21b45
Merge pull request #47295 from omegachysis/script-bind-mutex
Fix race condition on `script_binding` in C#
2021-08-24 06:09:43 +02:00
Juan Linietsky 13bd020a23
Merge pull request #52045 from reduz/expose-rid-creation-utilities
Expose RID creation utilities.
2021-08-23 22:30:43 -03:00
reduz 65ca132a80 Expose RID creation utilities.
* Exposed as utility functions.
* Not very useful for script, but vital for creating servers using native extensions.
2021-08-23 21:55:45 -03:00
Wilson E. Alvarez 69caa1ab4c
Update documentation for is_absolute_path and is_rel_path 2021-08-23 19:55:06 -04:00
Camille Mohr-Daurat 770a1d00a3
Merge pull request #51751 from jeffrey-cochran/windforce
Created an area-specific wind force that interacts with soft bodies
2021-08-23 16:48:19 -07:00
Juan Linietsky aa3c3a9ebb
Merge pull request #52036 from reduz/native-extension-argument-pointers
Implement NativeExtension pointer arguments
2021-08-23 20:36:48 -03:00