Commit graph

4514 commits

Author SHA1 Message Date
Hugo Locurcio 4c88a82f50
Move Mono unhandled exception setting to be located within a subsection
Settings that aren't within a subsection are difficult to reach when
other settings do have a subsection.

This also adds documentation for the project setting.
2021-11-10 20:57:35 +01:00
Rémi Verschelde 5defa1c167
Merge pull request #54805 from Klowner/3.4-gltf-cubic-spline-interpolate
Fix incorrect glTF cubic spline interpolation times/values size error
2021-11-10 08:04:43 +01:00
PouleyKetchoupp b93aeec4a2 Fix errors in KinematicBody when floor is destroyed or removed
In all physics servers, body_get_direct_state() now silently returns
nullptr when the body has been already freed or is removed from space,
so the client code can detect this state and invalidate the body rid.

In 2D, there is no change in behavior (just no more errors).

In 3D, the Bullet server returned a valid direct body state when the
body was removed from the physics space, but in this case it didn't
make sense to use the information from the body state.
2021-11-09 15:15:40 -07:00
Rémi Verschelde b0cd38b7e3
Merge pull request #42625 from RandomShaper/fix_dict_3.2 2021-11-09 15:55:43 +01:00
Mark Riedesel 999bba6916 Fix glTF cubic spline track interpolation incorrectly reporting times/values size mismatch (3.4 specific) 2021-11-09 09:47:37 -05:00
Pedro J. Estébanez a7aad78fd0 Add recursive comparison to Array and Dictionary
...and expose it to GDScript.

Co-authored-by: Emmanuel Leblond <emmanuel.leblond@gmail.com>
2021-11-09 15:08:22 +01:00
Hugo Locurcio 63d214f04b
Remove hash symbol in front of opcode error messages in GDScript
The hash symbol creates spurious issue references on GitHub if
the message is posted outside a code block, which means some issues
have a lot more references than originally intended.
2021-11-09 12:20:51 +01:00
Rémi Verschelde 3be409aa5e
Merge pull request #54039 from nekomatata/fix-soft-body-memory-corruption-bullet-3.x 2021-11-08 23:59:05 +01:00
Rémi Verschelde 2f10793467
Merge pull request #54117 from Pineapple/dont-ignore-type-mismatch-in-setter 2021-11-08 19:26:58 +01:00
Rémi Verschelde bd828c4d81
Merge pull request #54227 from akien-mga/3.x-gdscript-multiline-indexing 2021-11-08 15:03:24 +01:00
Rémi Verschelde d0b1e3d002
Merge pull request #53942 from raulsntos/no-boxing 2021-11-08 13:15:25 +01:00
Rémi Verschelde 837f2c5f82
Merge pull request #54746 from neikeq/issue-42076
C#: Don't use ActivityThread to determine Android nativeLibraryDir
2021-11-08 10:02:48 +01:00
Ignacio Roldán Etcheverry 690bf12c4c C#: Don't use ActivityThread to determine Android nativeLibraryDir 2021-11-08 02:35:06 +01:00
Rémi Verschelde 14c366ddd7
Bump version to 3.5-beta 2021-11-05 16:10:17 +01:00
Ignacio Roldán Etcheverry e282ee0a48 C#: Fix property set call boxing value when unboxed was expected 2021-11-03 13:02:53 +01:00
Ignacio Etcheverry b775573a21 Don't box params on Native->C# calls with Variant params
Godot uses Variant parameters for calls to script methods.
Up until now we were boxing such parameters when marshalling
them for invokation, even if they were value types.

Now Godot allocates the marshalled parameters on the stack,
reducing the GC allocations resulted from boxing.
2021-11-03 13:02:53 +01:00
Yuri Sizov d764e1fae7 Fix maximum allowed size atlas in CPU lightmapper 2021-11-02 15:50:50 +03:00
Rémi Verschelde e4996887ca
Merge pull request #48625 from The-O-King/compression_options 2021-11-02 08:58:22 +01:00
Lyuma e575b27b15 3.x backport glTF: Fix override materials and non-empty arrays
Keep track of MeshInstance and GeometryInstance override materials in the GLTFMesh object.
Ensure all arrays are non-empty to conform with "minItems":1 in glTF spec.
2021-11-01 23:40:12 -07:00
Omar El Sheikh 203295f17d Added Mesh Compression Import Options
Fleshed out the "Optimize Mesh" options found in the mesh import UI
Gave a checkbox to every vertex attribute that can be compressed

Surfaced option to enable/disable Octahedral compression for
normal/tangent vectors

Also surfaces the vertex position compression option which previously
inaccessible because the defaults did not compress vertex positions

Supports all current importers (obj, fbx, collada, gltf)
2021-11-01 12:54:28 -04:00
Raul Santos 21f68e7bdb
Ensure C# script properties are added to the end
Ensures that the `get_property_list` and `get_script_property_list`
methods push the script properties to the end of the given list, this
prevents the script property from appearing after the script variables.
2021-10-30 16:55:21 +02:00
Rémi Verschelde 14ef65e49b
Merge pull request #54348 from akien-mga/3.x-clang-format-dont-align-operands 2021-10-28 15:43:15 +02:00
Rémi Verschelde 87c80f529f
clang-format: Enable BreakBeforeTernaryOperators
clang-format keeps breaking the way it handles break *after* ternary operators,
so I give up and go with the only style they seem to actually test.
2021-10-28 14:50:33 +02:00
Rémi Verschelde 1b65550ec7
clang-format: Various fixes to comments alignment from clang-format 13
All reviewed manually and occasionally rewritten to avoid bad auto formatting.
2021-10-28 14:50:32 +02:00
Rémi Verschelde 42d385b312
clang-format: Disable alignment of operands, too unreliable
Sets `AlignOperands` to `DontAlign`.

`clang-format` developers seem to mostly care about space-based indentation and
every other version of clang-format breaks the bad mismatch of tabs and spaces
that it seems to use for operand alignment. So it's better without, so that it
respects our two-tabs `ContinuationIndentWidth`.
2021-10-28 13:23:38 +02:00
Rémi Verschelde 23955fc282
Merge pull request #54262 from raulsntos/csproj-globbing-3.x 2021-10-26 21:56:58 +02:00
Rémi Verschelde 5d0ec1779d
Merge pull request #54272 from pycbouh/gdscript-ignore-groups-completion-3.x 2021-10-26 20:02:01 +02:00
Yuri Sizov b3fc278dcf Ignore property groups and categories in GDScript code completion 2021-10-26 20:01:49 +03:00
Max Hilbrunner e29126914d
Save all 64 bits of get_ticks_msec() in more cases
(cherry picked from commit 5dc02eb8b0)
2021-10-26 18:23:31 +02:00
Raul Santos ced4f3519d Avoid modifying csproj globbing includes
Check if the found globbing include already matches the new path on
moving scripts to avoid modifying users' csproj files.
2021-10-26 18:21:19 +02:00
Lyuma e49f8c5823 3.x: Fix validation errors due to chunk padding and empty skins.
GLB chunk padding length calculation was backwards and missing for the BIN chunk.
Fixed error caused by "skins":[] when no skins were present.
Finally, encode animations before textures to avoid accessor misalignment due to texture byteLength.
2021-10-25 21:17:13 -07:00
Rémi Verschelde 92664f03a9
GDScript: Support multiline indexing with []
Fixes #35417.
2021-10-25 15:50:59 +02:00
Raul Santos da419bbeed Keep order for C# exported members 2021-10-24 21:14:20 +02:00
Aaron Franke 5659120af3
[3.x] Add support for the RISC-V architecture
Supports RV64GC (RISC-V 64-bit with general-purpose and compressed-instruction extensions)
2021-10-22 12:51:23 -05:00
Bartłomiej T. Listwon 5a7bd296af Don't ignore the type mismatch in setter function 2021-10-22 12:43:13 +02:00
PouleyKetchoupp 63f6d91a1a Fix SoftBody memory corruption when using invalid mesh
In case of failure the new soft body wasn't created but the previous one
wasn't destroyed, causing discrepancies with visual server updates.
2021-10-20 10:39:16 -07:00
Rémi Verschelde 89076410de
WebM: Disable SIMD optimization with YASM on Windows
It triggers a crash when playing V9 videos.

Could likely be fixed if anyone wants to work on it, but so far nobody seems to
want to and WebM support is dropped in 4.0, so this workaround should help for
now.

Fixes #50862.
2021-10-18 15:48:45 +02:00
Rémi Verschelde fddbbf445b
SCons: Fix missing mono .gen.cpp sources after #53860
(cherry picked from commit d6aab5c1bf)
2021-10-16 16:47:08 +02:00
Raul Santos 977898709f Fix hint_string for C# enum arrays 2021-10-15 19:07:31 +02:00
Rémi Verschelde f04a1bec63
Merge pull request #53628 from raulsntos/fix-list-marshal-3.x 2021-10-15 17:36:00 +02:00
Rémi Verschelde b8761569f6
Merge pull request #53582 from raulsntos/mono-marshal-generics-3.x 2021-10-15 17:35:32 +02:00
Rémi Verschelde 5ff8d0e8a7
Merge pull request #53577 from raulsntos/fix-mono-to-variant-array-3.x 2021-10-15 17:35:09 +02:00
Raul Santos 059750cd0d Support marshaling generic Godot.Object
Allows using generic C# types in signals as long as they inherit
from `Godot.Object`.
2021-10-13 18:22:06 +02:00
Ev1lbl0w e57f8fd083
Fix VisualScript crash with null object 2021-10-13 12:19:29 +01:00
M. Huri 37ccfb18ff Fixed a typo in csg module 2021-10-12 11:13:29 +07:00
Yuri Sizov b6b65e08d1 Remove redundant String operation from GDScript enum exports 2021-10-11 02:12:30 +03:00
Infinixius 0f328bcbdc
Fix small typos regarding WebSocketPeer
(cherry picked from commit 547ed239c0)
2021-10-10 12:27:47 +02:00
Raul Santos fd160b642e Fix C# List<T> marshalling 2021-10-10 11:41:37 +02:00
Rémi Verschelde 302ad4e600
Merge pull request #52918 from Calinou/add-new-light-attenuation-3.x 2021-10-08 23:08:49 +02:00
Hugo Locurcio 85e080fcc0
Backport new 3D point light attenuation as an option
This provides more realistic lighting with a very small performance cost.
The option is available in both GLES3 and GLES2, and can be enabled in
the Project Settings. This goes well with the ACES Fitted tonemapping mode
that was recently added.

When enabled, this also makes upgrading Godot 3.x projects to Godot 4.0 easier,
since lighting in 3.x will better match how it'll look in Godot 4.0.
2021-10-08 22:15:22 +02:00