Commit graph

5807 commits

Author SHA1 Message Date
K. S. Ernest (iFire) Lee c30cffe1b0
Merge pull request #52531 from V-Sekai/remove-gltf-packed-scene
Remove packed scene gltf.
2021-09-10 09:13:33 -07:00
K. S. Ernest (iFire) Lee 523b2d9199 Remove packed scene gltf
We determined through discussion that composing the packed scene from a node tree was a better design because it removed duplication of code.
2021-09-10 08:39:17 -07:00
George Marques 6423e891a6
Merge pull request #52063 from KoBeWi/double_comma_of_doom
Fix crash with consecutive commas in Dictionary
2021-09-10 11:24:51 -03:00
George Marques 6da061faf5
Merge pull request #49897 from Blackiris/fix-dollar-point-crash-on-editor
Fix crash when writing $. in the editor
2021-09-10 10:55:11 -03:00
George Marques 0b484c5f5f
Merge pull request #51456 from SaracenOne/super_init_fix
Call _init on base class if one does not exist.
2021-09-10 10:40:32 -03:00
kobewi c7452a9940 Fix crash with consecutive commas in Dictionary 2021-09-10 15:38:24 +02:00
George Marques 11e457e594
Merge pull request #51593 from KoBeWi/if
Prevent crash when awaiting in a getter/setter
2021-09-10 10:36:25 -03:00
George Marques 1234c2bdd9
Merge pull request #52081 from ThreeRhinosInAnElephantCostume/fixmatchfreeze
Fix gdscript pattern matching expressions
2021-09-10 09:28:18 -03:00
Ellen Poe f5d9c7b487 Replace stb_vorbis with libogg+libvorbis 2021-09-09 19:39:04 -07:00
Ignacio Roldán Etcheverry 6679be45aa
Merge pull request #52492 from raulsntos/fix-csharp-array-properties
Fix properties arrays in C# bindings generator
2021-09-09 20:38:58 +02:00
Vincent 70108fd850 implement individual mesh transform for meshlibrary items 2021-09-09 16:40:16 +02:00
Max Hilbrunner 75be697817
Merge pull request #52246 from Paulb23/verbatim-string
Syntax highlight c# verbatim string literal
2021-09-08 14:48:22 +02:00
Fabio Alessandrelli fd0a2b6cde
Merge pull request #52480 from mhilbrunner/network-rename
Multiplayer networking renames/simplification
2021-09-08 14:20:58 +02:00
Gilles Roudière 321ee7bda1
Merge pull request #52106 from Paulb23/text-edit-optimisation
Optimise TextEdit get line height and width
2021-09-08 14:04:41 +02:00
Raul Santos c6b1c8093f Fix properties arrays in C# bindings generator 2021-09-08 12:52:39 +02:00
Max Hilbrunner 5b25457794 Multiplayer networking renames/simplification
Removes _networking_ prefix from some methods and members, now that multiplayer has been largely moved out of Node and SceneTree and is seperated into its own set of classes.
2021-09-08 12:05:54 +02:00
AndreaCatania e3a06c3a9e Improve collision generation usability in the new 3D scene import workflow.
With this PR it's possible to add a collision during the Mesh import, directly in editor.
To generate the shape is possible to chose between the following options:
- Decompose Convex: The Mesh is decomposed in one or many Convex Shapes (Using the VHACD library).
- Simple Convex: Is generated a convex shape that enclose the entire mesh.
- Trimesh: Generate a trimesh shape using the Mesh faces.
- Box: Add a primitive box shape, where you can tweak the `size`, `position`, `rotation`.
- Sphere: Add a primitive sphere shape, where you can tweak the `radius`, `position`, `rotation`.
- Cylinder: Add a primitive cylinder shape, where you can tweak the `height`, `radius`, `position`, `rotation`.
- Capsule: Add a primitive capsule shape, where you can tweak the `height`, `radius`, `position`, `rotation`.

It's also possible to chose the generated body, so you can create:
- Rigid Body
- Static Body
- Area
2021-09-08 08:12:51 +02:00
Max Hilbrunner 643ae7063c
Merge pull request #51964 from bruvzg/request_camera_permission
[macOS] Request camera permission before session init.
2021-09-07 23:15:38 +02:00
Juan Linietsky ca11f8ad30
Merge pull request #52237 from ellenhp/polyphony
Add optional polyphonic playback to built-in audio player nodes
2021-09-07 17:38:51 -03:00
Max Hilbrunner 886ad727f8
Merge pull request #52267 from williamd67/lookup-symbol-builtin-functions
Show help for built-in functions (@GlobalScope)
2021-09-07 21:05:09 +02:00
Max Hilbrunner 9ada29e918
Merge pull request #52289 from Calinou/remove-old-msvc-support-ifdef
Remove `#ifdefs` for handling compilation with Visual Studio < 2015
2021-09-07 21:01:44 +02:00
Ellen Poe 0e3cab41eb Add polyphony to Audio Stream Player nodes 2021-09-07 09:44:39 -07:00
Max Hilbrunner acc776f7b6
Merge pull request #52442 from Faless/mp/4.x_rpc_manager
[Net] Move multiplayer classes to own subfolder. Split RPC from MultiplayerAPI.
2021-09-07 18:44:39 +02:00
Fabio Alessandrelli bf9aae09ba [Net] Move multiplayer to core subdir, split RPCManager.
Move multiplayer classes to "core/multiplayer" subdir.

Move the RPCConfig and enums (TransferMode, RPCMode) to a separate
file (multiplayer.h), and bind them to the global namespace.

Move the RPC handling code to its own class (RPCManager).

Renames "get_rpc_sender_id" to "get_remote_sender_id".
2021-09-07 11:14:30 +02:00
Bastiaan Olij 461d31427c
Merge pull request #52205 from BastiaanOlij/blit_source_rect
Add source rectangle to blit
2021-09-07 09:21:13 +10:00
Camille Mohr-Daurat e1ae2708ee
Merge pull request #52271 from nekomatata/query-layer-default-mask
Harmonize default value for collision mask in ray/shape queries
2021-09-06 09:33:18 -07:00
Julien Nguyen a92d2c447b Fix extends with relative path to parent script 2021-09-05 00:11:04 +02:00
bruvzg 49e316f41e Add TextServer parentheses stack dynamic reallocation support. 2021-09-04 17:48:20 +03:00
Max Hilbrunner 0bdbce672c
Merge pull request #52341 from Calinou/scons-fix-missing-sconscript-warning
Fix missing SConscript warning when building using SCons
2021-09-04 11:51:47 +02:00
Raul Santos 48c66b80ad Add documentation to GodotSharp
- Adds documentation to almost every class and member in `GodotSharp`
- Fixes some old documentation to more closely follow the XML comments convention
2021-09-03 19:03:31 +02:00
Raul Santos 415529400b Fix constant tag documentation in C# bindings generator 2021-09-03 18:54:40 +02:00
Raul Santos 5508d4606b Fix PackedInt64Array typo in bindings_generator.h 2021-09-03 18:54:40 +02:00
Ignacio Roldán Etcheverry ade4e9320a
Merge pull request #50872 from aaronfranke/cs-format-mini-2
Some more C# formatting and style fixes
2021-09-03 18:44:36 +02:00
Fabio Alessandrelli d20031ccae
Merge pull request #52342 from Faless/enet/4.x_no_close_error
[Net] Silence ENetMultiplayerPeer close_connection.
2021-09-03 10:20:26 +02:00
Max Hilbrunner 8c82e305ba
Merge pull request #52329 from ZuBsPaCe/gdscript-unused-private-class-variable-fix
GDScript: Fix for UNUSED_PRIVATE_CLASS_VARIABLE
2021-09-03 10:04:11 +02:00
ZuBsPaCe c76ad6b158 GDScript: Count usages of member variables.
Otherwise private member variables will always lead to UNUSED_PRIVATE_CLASS_VARIABLE.
2021-09-03 07:44:46 +02:00
ThreeRhinosInAnElephantCostume 15ccd83ada Added tests for expression matching 2021-09-03 06:59:13 +02:00
George Marques da9daf4c3a
GDScript: Do not complete lambda arguments from parent class
Since lambdas are not overriding methods from the parent class, they
should not try to check inheritance for signature matching.
2021-09-02 19:54:55 -03:00
Aaron Franke 1933df0013
Some more C# formatting 2021-09-02 15:12:15 -05:00
Fabio Alessandrelli 027fbc9a6c [Net] Silence ENetMultiplayerPeer close_connection.
Used to print an error when it was not active, now it just returns
immediately as per the documentation.
2021-09-02 15:21:09 +02:00
Hugo Locurcio 828f9c6c29
Fix missing SConscript warning when building using SCons 2021-09-02 15:14:28 +02:00
SaracenOne 84852585b9 Check for GDScript member and class naming conflicts in a variety of conditions. 2021-09-02 07:16:06 +01:00
bruvzg 0089adbd30 [TextServer] Fix HarfBuzz handle init order. Fix MinGW build. 2021-09-01 23:18:03 +03:00
George Marques 3d13588057
GDScript: Fix loading of interdependent autoloads
Move the autoload resolution to runtime by loading it into the stack
with an extra instruction. This allows an autoload to use another
autoload singleton independent of load order.
2021-09-01 16:06:30 -03:00
Fabio Alessandrelli 58c30b2626
Merge pull request #51639 from Ev1lbl0w/gsoc21-dap
Implement more advanced features for DAP
2021-09-01 16:17:32 +02:00
George Marques 25ae279317
Merge pull request #52270 from KoBeWi/goodbye_polar
Remove cartesian2polar and polar2cartesian
2021-09-01 09:33:13 -03:00
George Marques cf59028972
Merge pull request #48237 from KoBeWi/they_came_from_angle
Add Vector2.from_angle() method
2021-09-01 09:32:42 -03:00
Hugo Locurcio fc0bfbb33b
Remove #ifdefs for handling compilation with Visual Studio < 2015
Godot 3.3 and later require Visual Studio 2017 to be compiled.
2021-08-31 20:04:17 +02:00
Ev1lbl0w 292ed61c18 Implemented advanced features of DAP
Respect client "supportsVariableType" capability

Implement "breakpointLocations" request

Implement "restart" request

Implement "evaluate" request

Fix error messages not being shown, and improved wrong path message

Removed thread option and behavior

Implemented detailed inspection of complex variables

Fix "const"ness of functions

Added a configurable timeout for requests

Implement Godot custom data request/event

Implement syncing of breakpoints

Added support for debugging native platforms
2021-08-31 15:17:58 +01:00
Aaron Franke 33df50acdd
Fix missing renames in the GLTF module 2021-08-31 00:06:46 -05:00
kobewi 3f3739ccb5 Add Vector2.from_angle() method 2021-08-31 01:53:58 +02:00
Juan Linietsky bcd73fc00a
Merge pull request #52240 from Rubonnek/rename-rel-path
Rename `String::is_rel_path` to `String::is_relative_path`
2021-08-30 20:45:45 -03:00
PouleyKetchoupp 26bd432707 Harmonize default value for collision mask in ray/shape queries
The default mask for queries was 0, 0x7FFFFFFF or 0xFFFFFFFF depending
on the cases.

Now always using 0xFFFFFFFF (in the form of UINT32_MAX to make it clear)
in order to use all layers by default.
2021-08-30 16:42:49 -07:00
kobewi 017c94222e Remove cartesian2polar and polar2cartesian 2021-08-31 01:41:41 +02:00
William Deurwaarder b2f858870d Show help for built-in functions (@GlobalScope) 2021-08-30 21:51:56 +02:00
Juan Linietsky 6dab6e4136
Revert " Improve collision generation usability in the new 3D scene import workflow." 2021-08-30 11:30:36 -03:00
Camille Mohr-Daurat b60a51f023
Merge pull request #51985 from AndreaCatania/coll
Improve collision generation usability in the new 3D scene import workflow.
2021-08-30 07:25:51 -07:00
Paulb23 cf36fb405c syntax highlight c# verbatim string literal 2021-08-30 11:38:03 +01:00
Haoyu Qiu fd52e18d19 Try other resolved IPs if one fails to connect 2021-08-30 13:00:48 +08:00
Wilson E. Alvarez d11c1afc04
Rename String::is_rel_path to String::is_relative_path 2021-08-29 20:41:29 -04:00
Fabio Alessandrelli fafddbc143 [GDScript] [Net] Allow mixing rpc annotation paramters.
The strings no longer needs to be in order.
The last parameter (channel), still requires all the other parameters to
be present.
2021-08-30 00:54:38 +02:00
Fabio Alessandrelli 64b9f30b92 [Net] Rename RPC "puppet" to "auth" (authority). Drop "master".
This commit completely removes the RPC_MODE_MASTER ("master" keyword),
and renames the RPC_MODE_PUPPET to RPC_MODE_AUTHORITY ("auth" keyword).

This commit also renames the "Node.[get|set]_network_master" methods to
"Node.[get|set]_network_authority".

This commit also renames the RPC_MODE_REMOTE constant to RPC_MODE_ANY.

RPC_MODE_MASTER in Godot 3.x meant that a given RPC would be callable by
any puppet peer on the master, while RPC_MODE_PUPPET meant that it would
be callable by the master on any puppet.

Beside proving to be very confusing to the user (referring to where it
could be called instead of who can call it) the RPC_MODE_MASTER is quite
useless. It is almost the same as RPC_MODE_REMOTE (anyone can call) with
the exception that the network master cannot. While this could be useful
to check in some case, in such a function you would anyway need to check
in code who is the caller via get_rpc_sender_id(), so adding the check
there for those rare cases does not warrants a dedicated mode.
2021-08-30 00:54:38 +02:00
Fabio Alessandrelli ecb2e8297c [Editor] Editor debugger binds according to editor settings. 2021-08-29 18:03:12 +02:00
David Cambré 2fbea9dee6 Fix VisualScriptPropertySet value hint 2021-08-29 15:47:51 +02:00
Bastiaan Olij fbac863bfb Add source rectangle to blit 2021-08-29 14:57:16 +10:00
Hugo Locurcio 4f9509e6ba
Merge pull request #52085 from williamd67/fix-await-without-argument
Print error message when await is not followed by signal or coroutine
2021-08-28 23:01:34 +02:00
Max Hilbrunner 5d2c4faa89
Merge pull request #52164 from mhilbrunner/gd-style-fixup
GDScript test style fix
2021-08-28 20:16:17 +02:00
William Deurwaarder e77338978f Print error message when await is not followed by signal or coroutine
When await was not followed by a signal or coroutine the GDScript parser would
crash.

This fix will check if await is followed by a signal or coroutine in case that
isn't true (element == nullptr) then an error message is printed.
2021-08-28 17:29:35 +02:00
Paulb23 eac8b91c25 Optimise TextServerAdvanced static string comparisions 2021-08-28 11:27:23 +01:00
AndreaCatania 2d2d24a538 Improve collision generation usability in the new 3D scene import workflow.
With this PR it's possible to add a collision during the Mesh import, directly in editor.
To generate the shape is possible to chose between the following options:
- Decompose Convex: The Mesh is decomposed in one or many Convex Shapes (Using the VHACD library).
- Simple Convex: Is generated a convex shape that enclose the entire mesh.
- Trimesh: Generate a trimesh shape using the Mesh faces.
- Box: Add a primitive box shape, where you can tweak the `size`, `position`, `rotation`.
- Sphere: Add a primitive sphere shape, where you can tweak the `radius`, `position`, `rotation`.
- Cylinder: Add a primitive cylinder shape, where you can tweak the `height`, `radius`, `position`, `rotation`.
- Capsule: Add a primitive capsule shape, where you can tweak the `height`, `radius`, `position`, `rotation`.

It's also possible to chose the generated body, so you can create:
- Rigid Body.
- Static Body.
- Area.
2021-08-28 08:34:15 +02:00
Bastiaan Olij b9c64df69b Fix double named size parameter 2021-08-28 13:30:43 +10:00
K. S. Ernest (iFire) Lee d04aa9a114
Merge pull request #52122 from V-Sekai/autoload_list
Use sorted map for autoloads in ProjectSettings to preserve order.
2021-08-27 14:41:40 -07:00
Max Hilbrunner f126634434 GDScript test style fix 2021-08-27 21:11:46 +02:00
Max Hilbrunner 4e67e9bca6
Merge pull request #52090 from balloonpopper/bug52060
Correct null and boolean values being capitalised by the str command
2021-08-27 21:05:47 +02:00
Juan Linietsky 54caaa21ce
Merge pull request #51296 from ellenhp/mix_in_audio_server
Move mixing out of the AudioStreamPlayback* nodes
2021-08-27 15:38:20 -03:00
Hugo Locurcio 33773a24dc
Merge pull request #52105 from ldmnt/master 2021-08-27 19:28:59 +02:00
Ellen Poe 53843ba872 Require AudioStream::mix to return the number of frames successfully mixed 2021-08-27 10:27:58 -07:00
bruvzg 4c3f7d1290 Makes FontData importable resource.
Adds multi-channel SDF font texture generation and rendering support.
Adds per-font oversampling support.
Adds FontData import plugins (for dynamic fonts, BMFonts and monospaced image fonts), font texture cache pre-generation and loading.
Adds BMFont binary format and outline support.
2021-08-27 15:43:18 +03:00
Lyuma 31f790299c Use OrderedHashMap for autoloads to preserve order 2021-08-26 21:55:26 -07:00
Bastiaan Olij c5f62fad90
Merge pull request #52003 from BastiaanOlij/xr_interface_extension
Adding GDExtension support to XRInterface
2021-08-27 11:51:43 +10:00
Juan Linietsky d19b12dbd2
Merge pull request #52107 from timothyqiu/overriden
Fix misspelled "overriden"
2021-08-26 13:07:52 -03:00
Bastiaan Olij 86ff7f8550 Adding GDExtension support to XRInterface 2021-08-26 23:24:44 +10:00
Balloonpopper 4fae7ae9dc Correct null and boolean values being capitalised by the str command 2021-08-26 17:11:34 +10:00
Gilles Roudière ae3a422427
Merge pull request #52102 from Calinou/gdscript-tests-add-readme
Add a README to link to the GDScript integration tests documentation
2021-08-25 20:37:09 +02:00
Haoyu Qiu eba7265a1c Fix misspelled "overriden"
In recent GDVIRTUAL PR and SkeletonModification3DJiggle doc.
2021-08-26 01:44:01 +08:00
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 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
ThreeRhinosInAnElephantCostume 6c258a89de Fixed pattern matching with expressions 2021-08-25 15:30:41 +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
Raul Santos 4e6e6bcd2f Rename String.IsAbsPath() to String.IsAbsolutePath() 2021-08-25 03:02:55 +02:00
George Marques 4918df4527
GDScript: Allow access to outer constant and enum values 2021-08-24 14:45:51 -03:00
Max Hilbrunner c314203a70 Fix Visual Script editor 2021-08-24 19:33:40 +02: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
Hugo Locurcio fc67e2e16d
Document ENetConnection compression must match between client and server 2021-08-23 17:08:41 +02:00
Max Hilbrunner 583b6a594a
Merge pull request #51971 from aaronfranke/https
Replace HTTP URLs with HTTPS for sites with HTTPS versions
2021-08-23 15:58:54 +02:00
Michael Alexsander 88db541705
Merge pull request #51947 from AnilBK/redundant-assignments
[cppcheck] Remove some redundant assignments.
2021-08-23 13:23:45 +00:00
reduz 5cecdfa8af Entirely removes BIND_VMETHOD in favor of GDVIRTUAL
* `_gui_input`, `_input`, `_unhandled_input` and `_unhandled_key_input` are now regular C++ virutal functions.
* Everything else converted to GDVIRTUAL
* BIND_VMETHOD is gone, always use the new syntax from now on.

Creating `_gui_input` method and using the binder to register events will no longer work, simply override the virtual function now.
2021-08-23 08:10:13 -03:00
Aaron Franke ae1702bee5
Replace HTTP links with HTTPS for sites with HTTPS versions 2021-08-22 20:13:11 -05:00
reduz 3682978aee Replace BIND_VMETHOD by new GDVIRTUAL syntax
* New syntax is type safe.
* New syntax allows for type safe virtuals in native extensions.
* New syntax permits extremely fast calling.

Note: Everything was replaced where possible except for `_gui_input` `_input` and `_unhandled_input`.
These will require API rework on a separate PR as they work different than the rest of the functions.

Added a new method flag METHOD_FLAG_OBJECT_CORE, used internally. Allows to not dump the core virtuals like `_notification` to the json API, since each language will implement those as it is best fits.
2021-08-22 08:23:58 -03:00
Aaron Franke ba96f31fad
Merge pull request #51919 from raulsntos/csharp-renames
Rename C# string extensions to follow GDScript
2021-08-21 16:55:37 -05:00
bruvzg e6801a098e [macOS] Request camera permission before session init. 2021-08-22 00:34:02 +03:00
Julien Nguyen 9bc5119d4e Fix assignment with operator on type member 2021-08-21 21:56:11 +02:00
Anilforextra c86db8b710 Remove redundant assignments.
Use used_in_transfer instead of used_in_compute twice.
2021-08-21 19:20:07 +05:45
Rémi Verschelde f5422c55fc
Merge pull request #49105 from vnen/gdscript-inner-preload-type
GDScript: Fix inner classes and preloaded scripts as types
2021-08-20 17:07:18 +02:00
George Marques 2e84a46a0f
GDScript: Make singleton functions be seen as static
Since those can be called without an instance.
2021-08-20 10:52:58 -03:00
Raul Santos f6a700e264 Rename C# string extensions to follow GDScript
Follow up to d9d77291bc.

Renames `String.Extension` -> `String.GetExtension()` and
`String.BaseName()` -> `String.GetBaseName()`.
This makes those methods more consistent with GDScript and with
the `GetBaseDir` method.
2021-08-20 13:52:57 +02:00
Rémi Verschelde 75697c0dfd
Merge pull request #51916 from mhilbrunner/vs-fix
Fix VisualScriptEditor after namespaces
2021-08-20 13:32:39 +02:00
Max Hilbrunner 2c98eede23 Fix VisualScriptEditor after namespaces 2021-08-20 13:11:29 +02:00
Magian facb96034b check that the element type is indeed String 2021-08-20 18:35:04 +08:00
Ignacio Roldán Etcheverry d2c3a86844 C#: Fix bindings generator for Callable argument default value
Previously there weren't any Callable arguments with a default value,
but d4dd859991 introduced one.
2021-08-20 11:18:04 +02:00
Rémi Verschelde 603502c11c
Merge pull request #51902 from vnen/variant-internal-constructor
Fix initialization of objects in VariantInternal
2021-08-20 08:10:38 +02:00
George Marques a685535ad5
Fix initialization of objects in VariantInternal 2021-08-19 20:19:47 -03:00
George Marques 89695da337
GDScript: Fix memory leak when using self class as type 2021-08-18 18:58:45 -03:00
George Marques 1c8b076502
GDScript: Fix calling builtin static functions 2021-08-18 18:58:41 -03:00
George Marques 47545aeb1a
GDScript: Fix issue when calling new() on its own 2021-08-18 18:56:21 -03:00
George Marques 2ba4ee9198
GDScript: Fix inner classes and preloaded scripts as types 2021-08-18 18:56:21 -03:00
Rémi Verschelde c0bdea6a67
Merge pull request #51859 from nekomatata/bullet-body-motion-fixes
Fixes in Bullet body_test_motion
2021-08-18 22:46:10 +02:00
PouleyKetchoupp 45bc97b8b8 Fixes in Bullet body_test_motion
Synchronize fixes from the 3.x branch to keep Bullet code in sync for
later, even if it's disabled for now.
2021-08-18 13:18:19 -07:00
Magian 07a578d100 C# Array<String> Export Support Enum(String) 2021-08-18 20:30:51 +08:00
Max Hilbrunner 5161c97c9c Remove underscore hacks
Way less cruft. :)

Co-authored-by: Ignacio Roldán Etcheverry <neikeq@users.noreply.github.com>
2021-08-17 16:10:28 +02:00
Max Hilbrunner 81f7d1890b Namespaces instead of underscore prefix for binds
Thanks to neikeq for the initial work.

Co-authored-by: Ignacio Roldán Etcheverry <neikeq@users.noreply.github.com>
2021-08-17 16:10:09 +02:00
Rémi Verschelde 21a0af2686
Merge pull request #51762 from nekomatata/fix-crash-gdscript-cache
Fix crash when failing to load script from cache
2021-08-17 13:34:07 +02:00
PouleyKetchoupp 9973bf93ed Fix crash when failing to load script from cache 2021-08-16 16:27:25 -07:00
Rémi Verschelde cfdac0973c
Merge pull request #51698 from Paulb23/text-editor-settings
Reorganise text editor settings
2021-08-16 18:48:58 +02:00
Paulb23 bcfc591f86 Reorganise text editor settings 2021-08-16 17:18:49 +01:00
Ignacio Roldán Etcheverry 5ea500e599 Fix C# native instance bindings after recent re-write
This was needed after: 4469144891
2021-08-16 17:16:36 +02:00
Ricard Rovira Cubeles a8d12b5a61 Add constant to vector function parameters that don't actually modify their input.
Add more overloads of vector multiplication, required by templates to compile with float=64.
2021-08-15 16:45:37 +02:00
Rémi Verschelde 81512a3732
Style: Cleanup code using text_editor/completion/use_single_quotes 2021-08-13 21:27:57 +02:00
Rémi Verschelde 9e37336124
Merge pull request #51508 from AndreaCatania/mem-placement
Refactors the memnew_placement.
2021-08-13 14:58:02 +02:00
Rémi Verschelde 85e315d6e8
Merge pull request #51607 from aaronfranke/includes
Fix some unnecessary includes
2021-08-13 14:38:56 +02:00
AndreaCatania 98ceb60eb4 Refactors the memnew_placement.
With this commit the macro `memnew_placement` uses the standard memory
placement syntax: `new (mem) TheClass()`, and removes the outdated and
not used syntax:
```
_ALWAYS_INLINE_ void *operator new(size_t p_size, void *p_pointer, size_t check, const char *p_description) {
```

Thanks to this change, the function `memnew_placement` call is compatible with
any class, and can also initialize classes with non-empty constructor:
```
// This is valid, like before.
memnew_placement(mem, Variant);

// This works too:
memnew_placement(mem, Variant(123));
```
2021-08-13 10:18:34 +02:00
Anilforextra d73d8b8d78 Fix duplicate conditions. 2021-08-13 12:22:38 +05:45
Aaron Franke eb4902a455
Fix some unnecessary includes 2021-08-13 00:27:38 -05:00
kobewi 8a605d227d Prevent crash when awaiting in a getter/setter 2021-08-13 00:19:55 +02:00
Aaron Franke 03e2544d50
Use real_t and double where appropriate in Particles 2021-08-12 11:35:31 -05:00
Rémi Verschelde c89ad92c96
Merge pull request #51532 from nekomatata/layer-mask-accessors
Uniformize layer names, script methods and documentation
2021-08-12 17:55:11 +02:00
PouleyKetchoupp 989acbbe81 Uniformize layer names, script methods and documentation
- Back to 1-based layer names to make it clearer in editor UI
- Layer bit accessors are renamed to layer value and 1-based too
- Uniform errors and documentation in render and physics
- Fix a few remaining collision_layer used in place of collision_mask
2021-08-12 08:06:42 -07:00
Rémi Verschelde 6e9439198c
Resource: Remove unused _use_builtin_script() virtual method
And another piece of dead code found while searching for "use_builtin".
2021-08-12 12:16:17 +02:00
Marcel Admiraal cf771342cb Fix multiple issues with CSGPolygon 2021-08-12 09:52:38 +01:00
PouleyKetchoupp f9176a39ce Make radius & height in CapsuleShape3D independent
Also changed CapsuleMesh to make settings consistent between render and
physics.
2021-08-11 14:54:53 -07:00
Rémi Verschelde a57d420224
Merge pull request #51500 from timothyqiu/navmesh-doc 2021-08-11 14:12:56 +02:00
Haoyu Qiu 60298328ca Improve NavigationMesh typing, parameter validation and documentation 2021-08-11 18:18:10 +08:00
Rémi Verschelde c00303ff55
Merge pull request #47378 from aaronfranke/use-input-enums
Use key enum instead of plain integers for input code
2021-08-11 11:20:45 +02:00
Rémi Verschelde 2c88e1c15d
Merge pull request #51178 from Geometror/layout-options-textline-textparagraph
Various text layout improvements (TextLine, TextParagraph, Label, TextServer)
2021-08-11 07:51:57 +02:00
Hendrik Brucker 403f4902d0 Various text layout improvements (TextLine, TextParagraph, Label, TextServer) 2021-08-11 00:09:48 +02:00
Aaron Franke fa3a32a2d6
Use Key enum instead of plain integers 2021-08-10 16:26:55 -05:00
K. S. Ernest (iFire) Lee 18bd0fee5a
Merge pull request #49343 from theoway/node_auto_arrangement_graph_edit
Node Auto Arrangement in GraphEdit/VisualScript/VisualShader
2021-08-10 15:42:04 -04:00
Umang Kalra 12fc3f1eef Automatic arrangement of nodes in VisualScript/VisualShaders editors
This PR and commit adds the functionality to arrange nodes in VisualScript/VisualShader editor. The layout generated by this 
feature is compact, with minimum crossings between connections
& uniform horizontal & vertical gaps between the nodes. 

This work has been sponsored by GSoC '21.

Full list of additions/changes:
• Added arrange_nodes() method in GraphEdit module.
    • This method computes new positions for all the selected
      nodes by forming blocks and compressing them.
      The nodes are moved to these new positions. 
    • Adding this method to GraphEdit makes it available for 
      use in VisualScript/VisualShaders editors and its other
      subclasses. 
• Button with an icon has been added to call arrange_nodes() in GraphEdit. 
    • This button is inherited by VisualScript/VisualShaders editors
       to invoke the method.
• Undo/redo is functional with this method.
    • By using signals in arrange_nodes(), position changes are registered 
       in undo/redo stack of the subclass that is using the method. 
• Metadata of the method has been updated in ClassDB
• Method description has been added to class reference of GraphEdit
2021-08-11 00:44:28 +05:30
kobewi e0572f7ef7 Fix crash when parsing Dictionary 2021-08-10 15:57:56 +02:00
Rémi Verschelde 50d5569ad4
Merge pull request #51457 from nekomatata/moving-platforms-3d
Fix 3D moving platform logic
2021-08-10 14:12:01 +02:00
PouleyKetchoupp ec9fed69f4 Fix 3D moving platform logic
Same thing that was already done in 2D, applies moving platform motion
by using a call to move_and_collide that excludes the platform itself,
instead of making it part of the body motion.

Helps with handling walls and slopes correctly when the character walks
on the moving platform.

Also made some minor adjustments to the 2D version and documentation.

Co-authored-by: fabriceci <fabricecipolla@gmail.com>
2021-08-09 20:21:04 -07:00
SaracenOne 861bb3a488 Automatically call the _init function on base class if one does not exist. 2021-08-10 02:41:44 +01:00
Aaron Franke 430ad75963
Some work on double support 2021-08-09 17:43:48 -05:00
Rémi Verschelde c68b109f27
Merge pull request #51453 from Blackiris/fix-new-inherited-script
Fix infinite loop when creating a newly inherited GDScript file
2021-08-10 00:38:16 +02:00
Julien Nguyen 51b7179b5a Fix infinite loop when creating a newly inherited GdScript file 2021-08-09 23:52:31 +02:00
Rémi Verschelde 2de5d2361a
Merge pull request #51446 from nekomatata/fix-moving-platform-rotation
Fix applied rotation from moving platforms in move_and_slide
2021-08-09 23:20:44 +02:00
PouleyKetchoupp 5650c83e4b Fix applied rotation from moving platforms in move_and_slide
When synchronizing CharacterBody motion with moving the platform using
direct body state, only the linear velocity was taken into account.

This change exposes velocity at local point in direct body state and
uses it in move_and_slide to get the proper velocity that includes
rotations.
2021-08-09 12:30:17 -07:00
Aaron Franke 84f720966c
Use doubles for time in many other places 2021-08-09 14:05:42 -05:00
Rémi Verschelde 6e11017401
Merge pull request #51338 from V-Sekai/gltf-lights
Continue when glTF2 lights fail to parse.
2021-08-09 09:31:31 +02:00
Rémi Verschelde fa1a66dd68
Merge pull request #51180 from RandomShaper/native_script_inherits
Implement inherits_script() for NativeScript and PluginScript
2021-08-09 09:18:57 +02:00
K. S. Ernest (iFire) Lee 0c79a8fa22 Continue when glTF2 lights fail to parse. 2021-08-09 00:09:19 -07:00
bruvzg 7c3c5603d0 [Text Server] Improve object (image/table) inline alignment. 2021-08-08 22:35:47 +03:00
Rémi Verschelde 35b08b7cbc
Merge pull request #51322 from raulsntos/fix-msbuild-exception
Ensure MSBuildPanel buttons are instantiated
2021-08-07 12:19:26 +02:00
AndreaCatania e4e4a02d3d Removes const from set functions on the Gizmos 2021-08-07 09:15:57 +02:00
Raul Santos f20db58271 Ensure MSBuildPanel buttons are instantiated 2021-08-06 22:30:38 +02:00
Francois Belair 070d634966 Fix LSP completion crashing on scene-less scripts 2021-08-06 14:55:05 -04:00
Rémi Verschelde c44ebb020d
HTML5: Fix warnings and re-enable werror=yes on CI
Add a missing call to disable warnings on a forked env for freetype's
`sfnt.c`.
2021-08-06 12:12:37 +02:00
Rémi Verschelde 6ded4f52e8
Merge pull request #51283 from Razoric480/lsp-parse-from
Fix LSP parsing get_node only from the scene root
2021-08-06 10:13:09 +02:00
Rémi Verschelde 2f1bc509dc
Merge pull request #51301 from Faless/mp/4.x_gd_default_rpc
[Net] Default @rpc annotation should be puppet, not master.
2021-08-06 09:08:09 +02:00
Rémi Verschelde ba0982c51c
Merge pull request #51008 from raulsntos/csharp-renames 2021-08-06 09:07:02 +02:00
Fabio Alessandrelli d7dca072aa [Net] Default @rpc annotation should be puppet, not master. 2021-08-06 02:39:22 +02:00
Fabio Alessandrelli a816d74fdf [Net] Fix ENetMultiplayerPeer status during connection.
While the client emitting "peer_connect" for the server, the status was
still set to CONNECTION_CONNECTING, causing bugs in the upper layer.
2021-08-06 02:00:56 +02:00
Francois Belair 03f8fa9f62 Fix LSP parsing get_node only from the scene root 2021-08-05 12:30:06 -04:00
Raul Santos 2deefd938f Reduce C# Dictionary internal calls
- Implements new `KeyValuePairs` and `KeyValuePairAt` internal calls
to get the `key` and the `value` in one call.
- Caches the `DictionaryEntry` to reuse properties without repeating
internal calls.
2021-08-05 17:30:28 +02:00
Raul Santos 0669ffcd15 Add documentation to Dictionary in C#
Adds documentation to `Godot.Collections.Dictionary` in C#.
2021-08-05 17:30:27 +02:00
Raul Santos d2655cb131 Rename RotationQuaternion to be more similar to get_rotation_quaternion
Renames `RotationQuaternion` to be more consistent with `get_rotation_quaternion`
2021-08-05 17:29:55 +02:00
Raul Santos 5330c83690 Rename RandSeed to RandFromSeed and use ref param
Renames `RandSeed` method to be more consistent with `Math::rand_from_seed`
2021-08-05 17:29:55 +02:00
Rémi Verschelde a544e77822
Merge pull request #51247 from pycbouh/docs-extract-theme-items
Add theme item descriptions to the online documentation
2021-08-05 00:18:56 +02:00
Rémi Verschelde 73b1f5ac79
Merge pull request #48615 from Razoric480/lsp-rename
Implement LSP didSave notification and rename request
2021-08-05 00:18:31 +02:00
Yuri Sizov bf2839ea3e Add theme item descriptions to the online documentation 2021-08-04 22:27:10 +03:00
Rémi Verschelde 0cee8831b2
Merge pull request #51005 from Faless/mp/4.x_channels
[Net] Implement RPC channels in MultiplayerAPI.
2021-08-04 09:31:33 +02:00
31 6fd2edddc0 Fix 'script_class' null access when reloading a deleted C# script 2021-08-03 22:43:42 -05:00
Raul Santos ad460cde79 Simplify C# print methods
- Extracts the parameters logic to a single method
- Simplify the handling of null parameters
2021-08-03 23:12:27 +02:00
Yuri Sizov d3e413c659 Fix the editor theme application for the Mono build log 2021-08-03 22:13:32 +03:00
Fabio Alessandrelli 80fc90e82a
Merge pull request #50454 from Ev1lbl0w/gsoc21-dap
Implemented initial DAP support
2021-08-03 17:12:37 +02:00
Pedro J. Estébanez 2dcd064056 Implement inherits_script() for NativeScript and PluginScript 2021-08-02 17:50:50 +02:00
Haoyu Qiu 0ca38ffe76 Validates VisualScript.add_node input node 2021-08-02 23:36:13 +08:00
Ev1lbl0w 7bccd5487e
Implemented initial DAP support
Implemented "output" event

Refactored "seq" field generation

Prevent debugging when editor and client are in different projects

Removed unneeded references to peer on the parser

Refactored way to detect project path

Implemented "setBreakpoints" request

Fix double events when terminating from client

Refactored "stopped" event

Implemented "stopped" with breakpoint event

Implemented "stackTrace", "scopes" and "variables" request

Report incoming number of stack dump variables

Implemented proper reporting of scopes and variables from stack frames

Prevent editor from grabbing focus when a DAP session is active

Implemented "next" and "stepIn" requests

Implemented "Source" checksum computing

Switched expected errors from macros to silent guards

Refactored message_id

Respect client settings regarding lines/columns behavior

Refactored nested DAP fields

Implement reporting of "Members" and "Globals" scopes as well

Fix error messages not being shown, and improved wrong path message
2021-08-02 10:43:35 +01:00
Rémi Verschelde 8465ecc3ae
Merge pull request #51036 from winterpixelgames/master-ws-fix
WebsocketPeer outbound buffer fixes and buffer size query
2021-08-01 11:12:15 +02:00
Jordan Schidlowsky de02cf44ae Websocket peer outbound buffer fixes. Expose outbound buffered amount. 2021-07-31 19:48:31 -06:00
Rémi Verschelde 6acbcf7a86
Merge pull request #50625 from nekomatata/body-one-direction-layers
One-directional collision layer check for rigid bodies and soft bodies
2021-07-31 22:12:46 +02:00
Haoyu Qiu 284c6c81eb Make action names translatable 2021-07-31 22:19:51 +08:00
Aaron Franke 2733b9abd8
Remove obsolete "dectime" method
Replaced by "move_toward"
2021-07-30 16:41:28 -05:00
Haoyu Qiu 0f1e107ede Do nothing when dragging CSGBox handle perpendicular to the camera 2021-07-31 02:25:05 +08:00
Fabio Alessandrelli 2cf39b97ae [Net] Implement RPC channels in MultiplayerAPI. 2021-07-30 17:29:50 +02:00
Rémi Verschelde 23bf04ae9a
Merge pull request #51052 from V-Sekai/gltf-fallbacks
glTF2 fallback load PNG and JPG
2021-07-30 17:04:29 +02:00
Rémi Verschelde 83ccf39adc
Merge pull request #51067 from akien-mga/doc-return-argument-self-closing-tags
doc: Use self-closing tags for `return` and `argument`
2021-07-30 16:42:52 +02:00