Commit Graph

8283 Commits

Author SHA1 Message Date
Raul Santos 8b07f95ba0
C#: Add float an double overloads to Mathf
- Add `float` and `double` overloads to all methods of `Mathf`.
This allows the methods to be usable with `float`, `double` or `real_t`.
- Use `System.MathF` in the `float` overloads which may result in
better performance.
- Constants remain as `real_t` for the time being.
- Add aggresive inlining for methods that wrap `System.Math` calls.
2023-01-24 15:01:26 +01:00
Magian 35bfce2afd C# Improve the "Tag" conversion of documents
[codeblocks] for Keep only the [CSharp] part.
[param] is changed to <c>.
[b] for bold text.
[i] for italic text.
4.0 now uses variant, so [variant] to <see cref="Godot.Variant"/>.
since Rider does not support [u], only comments have been modified.
2023-01-24 18:40:48 +08:00
Danil Alexeev 13215638a9
Clarify error message about script-level annotation 2023-01-24 13:10:45 +03:00
Rémi Verschelde a17e0a0250
Merge pull request #71932 from raulsntos/dotnet/lin2db-to-math
C#: Move `LinearToDb` and `DbToLinear` to Mathf
2023-01-24 09:54:32 +01:00
David Snopek 9196c47032 Correctly apply world_scale in WebXR 2023-01-23 21:26:38 -06:00
Rémi Verschelde 0f31e6569a
Merge pull request #71931 from bruvzg/ts_s
[TextServer] Fix ICU data loading and exporting with `internationalization/locale/include_text_server_data` setting.
2023-01-23 20:45:58 +01:00
Raul Santos b29193945d
C#: Move `LinearToDb` and `DbToLinear` to Mathf 2023-01-23 20:20:54 +01:00
bruvzg 15dafc49d3
[TextServer] Fix ICU data loading and exporting with `internationalization/locale/include_text_server_data` setting. 2023-01-23 21:13:32 +02:00
bruvzg 458f720ea9
[TextServer] Add fallback code in case of missing ICU data. 2023-01-23 20:50:30 +02:00
George Marques ba9491f870
Merge pull request #70948 from vnen/gdscript-ptr-method-name-in-debug 2023-01-23 12:24:15 -03:00
Rémi Verschelde 81fe3715b8
Merge pull request #71914 from vnen/gdscript-no-continue-match
GDScript: Remove function of `continue` for match statement
2023-01-23 15:35:55 +01:00
Rémi Verschelde 0927e2cffc
Merge pull request #63251 from SaracenOne/disable_data_generation_on_foreign_resources
Disable navmesh, lightmap, and VoxelGI generation on foreign data
2023-01-23 15:35:31 +01:00
George Marques 80e06b29e7
GDScript: Add names for disassembling function pointers
When instructions use function pointers, it's not possible to retrieve
their original names in the disassembly. This stores the names in
vectors (in debug builds) so they can be shown.
2023-01-23 11:04:31 -03:00
Rémi Verschelde a98431d1c1
Merge pull request #71909 from bruvzg/utf16_bidi_override_fix
Fix BiDi override for the characters outside BMP (e.g., emojis).
2023-01-23 12:26:24 +01:00
bruvzg 96ed1c19dd
Fix BiDi override for the characters outside BMP (e.g., emojis). 2023-01-23 12:51:35 +02:00
Rémi Verschelde 5b1df48c6c
Convert en_GB spelling to en_US with codespell 2023-01-23 11:02:20 +01:00
Rémi Verschelde 3a228ef224
Merge pull request #71900 from SaracenOne/blendshape_track_import_flag
Fix duplicating imported blendshape tracks
2023-01-23 10:24:37 +01:00
Rémi Verschelde 5726bf578d
Merge pull request #71676 from vnen/gdscript-unicode-identifiers
Add support for Unicode identifiers in GDScript and Expression
2023-01-23 10:24:33 +01:00
SaracenOne 03523572b9 Adds missing method call to set blendshape tracks as 'imported' when importing from a GLTF. 2023-01-23 07:40:06 +00:00
George Marques 9462ae4783
GDScript: Remove function of `continue` for match statement
The keyword is confusing and rarely is used in the intended way. It is
removed now in favor of a future feature (pattern guards) to avoid
breaking compatibility later.
2023-01-22 18:45:24 -03:00
Juan Linietsky 6a87cdf6d2 Disable OGG and MP3 looping by default on import
* From Godot 4.0 onwards, proper music looping is supported which requires setting the BPM and then the loop point in beats.
* As such, importing with loop by default does not serve much of a purpose. Its annoying to disable for SFX or clips that do not loop and it also requires manual intervention to loop music.
* This way, it should work out of the box for any sound effect or non looping audio clip, and manual work is required anyway for looping music.
2023-01-22 15:45:45 +01:00
RedworkDE 3f1241cb82 C#: Allow use of .NET 7
The editor will use .NET 7 if it is installed and fall back to .NET 6 otherwise.
Exported projects will use .NET 7 or .NET 6 depending on the value of TargetFramework in the csproj.
2023-01-21 23:11:37 +01:00
kobewi 615c517034 Use range iterators in LocalVector loops 2023-01-21 18:44:42 +01:00
George Marques 7548e043fc
Add support for Unicode identifiers in GDScript
This is using an adapted version of UAX#31 to not rely on the ICU
database (which isn't available in builds without TextServerAdvanced).
It allows most characters used in diverse scripts but not everything.
2023-01-21 13:39:40 -03:00
Rémi Verschelde ebd0b40f6e
Merge pull request #71687 from reduz/support-script-class-name-in-efs
Support script global resource name in EditorFileSystem
2023-01-21 16:54:23 +01:00
Juan Linietsky dddd8d43f6 Support script global resource name in EditorFileSystem
* Works for binary and text files.
* Makes EditorQuickOpen work with custom resources again.
* Information is cached and easily accessible.

Properly fixes #66179. Supersedes #66215 and supersedes #62417

**WARNING**: This required breaking backwards binary compatibility (.res and .scn files). Files saved after this PR is merged will no longer open in any earlier versions of Godot.
2023-01-21 14:19:27 +01:00
Raul Santos 04996df61e
C#: Restore `Scale` and `Rotation` properties 2023-01-21 04:59:13 +01:00
Adam Wardell e9d8c261a5 call update_exports from LSP didSave function
exports in the inspector were not properly appearing when a gdscript was saved using an external IDE
this commit adds a call to GDScript::UpdateExports toward the end of GDScriptTextDocument::didSave
2023-01-20 19:16:53 -08:00
George Marques 7e5c2f945d
Remove references to compiled GDScript in export
This feature was removed from GDScript so it should not be present on
the interface nor in the saved export presets.
2023-01-20 15:09:07 -03:00
Rémi Verschelde 822edfdb40
Merge pull request #71708 from dsnopek/openxr-opengl-steamvr-2
Get OpenXR with OpenGL working on SteamVR
2023-01-20 08:50:10 +01:00
Rémi Verschelde 7b84b133ee
Merge pull request #69181 from fire/gltf-runtime-image-fallback
Fixes cases where the runtime ResourceLoader cannot load gltf images.
2023-01-20 08:48:32 +01:00
David Snopek 481369760b Add depth and color formats to get OpenXR with OpenGL working on SteamVR 2023-01-19 21:22:34 -06:00
Rémi Verschelde 415d120aae
Merge pull request #70363 from V-Sekai/astcenc-standalone
Add astcenc compression and decompression.
2023-01-19 22:49:06 +01:00
Rémi Verschelde e7d045db8c
Merge pull request #71314 from stmSi/fix-ogg-packet-out-of-bound
Fix OGG page_data out of bound index crash
2023-01-19 21:57:11 +01:00
jordi 2e488072d0 Allow standalone ternary expressions 2023-01-19 14:27:57 -06:00
Rémi Verschelde 65883cc73b
Merge pull request #71598 from bruvzg/gdscript_bidi_override
Implement BiDi override mode for GDScript source.
2023-01-19 19:33:18 +01:00
K. S. Ernest (iFire) Lee a103400871 Fixes cases where the runtime ResourceLoader cannot load gltf images. 2023-01-19 09:10:28 -08:00
K. S. Ernest (iFire) Lee 696346f4cc
Add ASTC compression and decompression with Arm astcenc.
Co-authored-by: Gordon A Macpherson <gordon.a.macpherson@gmail.com>
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2023-01-19 16:27:59 +01:00
bruvzg e144e5dda5
Remove duplicate ucaps code from TextServerFallback. 2023-01-19 14:56:17 +02:00
bruvzg db7d8c2d87
[GDExtension] Expose some low level functions and String operators. 2023-01-19 12:50:49 +02:00
Rémi Verschelde 56ac1a67cd
Merge pull request #71620 from adamscott/move-icon-to-top
Update `@icon` and `@tool` definitions to add a note
2023-01-19 10:09:04 +01:00
Rémi Verschelde bcb57b42f6
Merge pull request #71450 from BastiaanOlij/fix_openxr_init_failure
Fixes issue where failed start of OpenXR causes issues
2023-01-19 10:08:50 +01:00
Rémi Verschelde 04a9752d8d
Merge pull request #67661 from cooperra/bmp-2bpp-loader
BMP loader: Fix 2 bits-per-pixel images
2023-01-19 10:08:21 +01:00
Adam Scott 807b7ed557 Update `@icon` definition to add a note 2023-01-18 19:48:01 -05:00
Rémi Verschelde 5dd3a6dbe2
Merge pull request #71638 from raulsntos/dotnet/export-plugin
C#: Implement `ExportPlugin::_get_name` and move `GLOBAL_DEF` to CSharpLanguage
2023-01-18 22:29:37 +01:00
Rémi Verschelde f2dbd011b6
Merge pull request #71569 from raulsntos/dotnet/sync-vectors
Sync C# vectors with Core
2023-01-18 22:28:00 +01:00
Raul Santos 3425d43fed
C#: Move `GLOBAL_DEF`s to CSharpLanguage ctor
Also documents the .NET project settings.
2023-01-18 21:53:58 +01:00
bruvzg 5361ec9f43
Implement BiDi override mode for GDScript source. 2023-01-18 19:22:20 +02:00
Raul Santos 62106fe5e3
C#: Implement `ExportPlugin::_get_name` 2023-01-18 18:17:38 +01:00
Rémi Verschelde bcaf048f33
Merge pull request #71379 from KoBeWi/destruction_of_compatibility_function
Remove set_drag_forwarding_compat()
2023-01-18 17:40:13 +01:00
ocean (they/them) 4854e723be Fix unnammed enum crash regression 2023-01-18 09:35:48 -05:00
Raul Santos 4bdcfe1443
Sync C# vectors with Core
- Remove `Vector2.Lerp` overload that takes a weight parameter of type `Vector2`.
- Remove `Vector3.Lerp` overload that takes a weight parameter of type `Vector3`.
- Remove `Color.Lerp` overload that takes a weight parameter of type `Color`.
- Remove `Angle` method from `Vector2i`.
- Remove `AngleTo` method from `Vector2i`.
- Remove `AngleToPoint` method from `Vector2i`.
- Remove `Cross` method from `Vector2i`.
- Remove `DistanceSquaredTo` method from `Vector2i` and `Vector3i`.
- Remove `DistanceTo` method from `Vector2i` and `Vector3i`.
- Remove `Dot` method from `Vector2i` and `Vector3i`.
- Remove `PosMod` method from `Vector2i` and `Vector3i`.
- Remove `Orthogonal` method from `Vector2i`.
- Remove `&` operator from `Vector2i` and `Vector3i`.
2023-01-17 18:07:33 +01:00
Rémi Verschelde 3a53990e9c
Merge pull request #71516 from raulsntos/dotnet/property-accessors
C#: Make property accessors internal
2023-01-17 17:30:49 +01:00
Rémi Verschelde 8a00992ab6
Merge pull request #71534 from Faless/mp/4.x_nested_spawn
[MP] Fix nested spawning during "ready".
2023-01-17 10:38:11 +01:00
Raul Santos ab5e532f1a
C#: Skip methods with pointer parameters 2023-01-17 04:32:05 +01:00
Fabio Alessandrelli ad3a4214c5 [MP] Fix nested spawning during "ready".
We want our spawns to be notified after ready, but we need to notify
them in the order they entered tree, so that nested spawners can be used
during "ready" (instead of having to await a frame).
2023-01-17 04:22:07 +01:00
Rémi Verschelde 4005fc4b8d
Merge pull request #71279 from vonagam/fix-iterator-number-type
GDScript: Fix typing of iterator in for loop
2023-01-16 22:21:26 +01:00
Rémi Verschelde 1c3653e083
Merge pull request #67774 from aaronfranke/script-annotations
Make script annotations be placed before `class_name` and `extends`
2023-01-16 22:20:44 +01:00
Rémi Verschelde 585a934454
Merge pull request #71434 from adamscott/fix-reduce-identifier-from-base-class-script-retrieval
Fix cyclic reference errors while reducing identifiers
2023-01-16 22:15:21 +01:00
Rémi Verschelde 5f7ac9fe10
Merge pull request #71496 from raulsntos/dotnet/sincos
C#: Implement `Mathf.SinCos`
2023-01-16 22:13:46 +01:00
Raul Santos 47e355f965
C#: Make property accessors internal 2023-01-16 15:15:26 +01:00
George Marques 629796c333
Merge pull request #69970 from poohcom1/fix/autocomplete-custom-class
Fixes https://github.com/godotengine/godot/issues/69941
2023-01-16 09:44:23 -03:00
Raul Santos 0ccb5f3954
C#: Implement `Mathf.SinCos`
Implement `Mathf.SinCos` that wraps a call to `System.Math.SinCos`,
this allows us to use the `SinCos` method more conveniently with
`real_t`.

Using `Math.SinCos` is often cheaper than separate calls to `Math.Sin`
and `Math.Cos`, and they are often used together.
2023-01-16 13:29:32 +01:00
Rémi Verschelde f96701eda6
Merge pull request #71461 from snoopdouglas/snoopdouglas/master
Class reference: snake_case .tscn & .gd filenames, _on_* callbacks
2023-01-16 09:41:36 +01:00
Rémi Verschelde da57e0059e
Merge pull request #70504 from KoBeWi/the_choosen_antipattern
Add EditorUndoRedoManager singleton
2023-01-16 09:24:50 +01:00
Rémi Verschelde 6a487cc243
Merge pull request #71477 from aaronfranke/gltf-append-doc
Improve the documentation of GLTFDocument's append methods
2023-01-16 09:24:27 +01:00
Rémi Verschelde ba551727ef
Merge pull request #71458 from raulsntos/dotnet/quaternion
C#: Make `Length` and `LengthSquared` into methods in `Quaternion`.
2023-01-16 09:20:53 +01:00
Rémi Verschelde 88c81bfbe5
Merge pull request #71456 from raulsntos/dotnet/sync-plane
C#: Sync `Plane` with Core
2023-01-16 09:20:30 +01:00
Rémi Verschelde 94312ab943
Merge pull request #71445 from raulsntos/dotnet/transforms
C#: Add missing `Transform{2D,3D}` and `Basis` constructors
2023-01-16 09:20:07 +01:00
Rémi Verschelde fda8e6b18d
Merge pull request #71431 from raulsntos/dotnet/scale-and-rotation
C#: Replace `Rotation` and `Scale` properties with get methods
2023-01-16 09:19:43 +01:00
Rémi Verschelde 2118f8e8a3
Merge pull request #70684 from filiperinaldi/fix_arm64_build_clang
Fix arm64 build when using Clang
2023-01-16 09:15:44 +01:00
Adam Scott 48e041458f Fix cyclic reference errors while reducing identifiers.
Co-authored-by: Dmitrii Maganov <vonagam@gmail.com>
2023-01-15 19:19:25 -05:00
kobewi b58111588a Add EditorUndoRedoManager singleton 2023-01-16 01:11:52 +01:00
Aaron Franke 208df30eeb
Improve the documentation of GLTFDocument's append methods 2023-01-15 14:27:08 -06:00
Raul Santos 7a19c87c7e
C#: Sync `Plane` with Core
- Add `Plane(Vector3)` constructor.
- Rename `IntersectRay` to `IntersectsRay`.
- Rename `IntersectSegment` to `IntersectsSegment`.
- Replace `Center` property with `GetCenter` method.
- Add and fix documentation about the _normal_ parameter
to Core and C# documentation.
2023-01-15 19:47:42 +01:00
poohcom1 aa4bceff3e Add identifier completion for custom classes.
Previously, custom class would only auto-complete for types in GDScript.
This applies it to identifiers as well.
2023-01-16 00:25:24 +07:00
Raul Santos 5136366112
C#: Add missing `Transform{2D,3D}` and `Basis` constructors
- Remove `Transform3D(Quaternion, Vector3)` constructor from C#.
- Add `Transform3D(Projection)` constructor to C#.
- Add documentation to the `Transform3D(Projection)` constructor in Core.
- Add `Transform3D` constructor with only real_t params to C# that mirrors `Transform2D`.
- Expose `Basis` constructor with only real_t params in C#.
- Add `Transform2D(real_t, Vector2, real_t, Vector2)` constructor to C#.
2023-01-15 15:45:43 +01:00
Doug Thompson a4c734ed32 Class reference: snake_case .gd filenames, _on_*
This is for:
https://github.com/godotengine/godot-docs/issues/6245
2023-01-15 13:26:29 +00:00
Raul Santos 0476fc5a07
C#: Replace `Rotation` and `Scale` properties with get methods
- Replace `Rotation` property with `GetRotation` method in `Transform2D`.
- Replace `Scale` property with `GetScale` method in `Transform2D`.
- Replace `Scale` property with `GetScale` method in `Basis`.

Core does not expose set methods.
2023-01-15 14:06:16 +01:00
Raul Santos 28a8caac26
C#: Make `Length` and `LengthSquared` into methods in `Quaternion`.
The `Length` and `LengthSquared` members are implemented as methods
in every other C# struct, `Quaternion` was the only one implementing
them as properties.
2023-01-15 14:03:44 +01:00
Rémi Verschelde d6d87b6ca4
Merge pull request #71374 from raulsntos/dotnet/remove-spherical_interpolate_with
C#: Remove `SphericalInterpolateWith` from Transform3D
2023-01-15 13:08:15 +01:00
Rémi Verschelde e51426cab9
Merge pull request #71423 from raulsntos/dotnet/intersects-without-include_borders
C#: Remove `includeBorders` parameter from `Rect2i.Intersects` and `AABB.Intersects`
2023-01-15 13:07:13 +01:00
Rémi Verschelde 90c1f4bba4
Merge pull request #71424 from raulsntos/dotnet/sync-basis
C#: Sync `Basis` with Core
2023-01-15 13:06:48 +01:00
Bastiaan Olij 909ec66ca3 Fixes issue where failed start of OpenXR causes issues 2023-01-15 16:57:42 +11:00
Raul Santos 949a2778ca
C#: Sync `Basis` with Core
- Remove `GetOrthogonalIndex` method (moved to `GridMap`).
- Remove `GetRow` and `SetRow` methods.
2023-01-14 20:06:45 +01:00
Yuri Sizov 4c1f11944e Update all outdated online documentation links 2023-01-14 19:38:00 +03:00
kobewi 59ea36b87c Remove set_drag_forwarding_compat() 2023-01-14 15:16:51 +01:00
Yuri Rubinsky 9bd5ef1836 Fix GDScript script templates to use a PascalCase style for `_CLASS_` 2023-01-14 16:21:05 +03:00
Raul Santos c990f7984e
C#: Remove `includeBorders` parameter from `Rect2i.Intersects` and `AABB.Intersects` 2023-01-14 04:39:40 +01:00
Raul Santos 4438315242
C#: Remove `SphericalInterpolateWith` from Transform3D 2023-01-14 02:10:59 +01:00
Raul Santos a6ba914f15
C#: Lookup signals and methods in Get method
Allows to retrieve `Callable`s and `Signal`s using `Get` like it works in GDScript.
2023-01-13 22:19:25 +01:00
Yuri Sizov 4c5e09f96a
Merge pull request #71339 from raulsntos/dotnet/is_finite
Add `IsFinite` to C# Variants
2023-01-13 23:34:51 +03:00
Yuri Sizov bdb3543c2a
Merge pull request #71343 from raulsntos/dotnet/is_zero_approx
Add `IsZeroApprox` to C# vectors
2023-01-13 23:31:24 +03:00
Dmitrii Maganov a1e0281b45 GDScript: Disallow type inference with untyped initializer 2023-01-13 20:51:29 +02:00
Raul Santos 14c16746f3
Add `IsZeroApprox` to C# vectors 2023-01-13 18:53:39 +01:00
Rémi Verschelde 8716c12ead
Merge pull request #71325 from reduz/refactor-project-setting-overrides
Refactor ProjectSetting overrides
2023-01-13 18:03:15 +01:00
Rémi Verschelde ef01b49227
Merge pull request #71329 from vnen/gdscript-fix-enum-value-resolution
GDScript: Fix infinite recursion in resolution of enum values
2023-01-13 18:02:58 +01:00
Rémi Verschelde 4c2dea108e
Merge pull request #70540 from vaartis/multiline-arrays-dictionaries
Implement export_multiline support for Array[String] and Dictionary
2023-01-13 18:01:55 +01:00
Raul Santos f852004cf5
Add `IsFinite` to C# Variants 2023-01-13 17:57:52 +01:00
Juan Linietsky 6f0e210093 Refactor ProjectSetting overrides
* Overrides no longer happen for set/get.
* They must be checked with a new function: `ProjectSettings::get_setting_with_override()`.
* GLOBAL_DEF/GLOBAL_GET updated to use this

This change solves many problems:
* General confusion about getting the actual or overriden setting.
* Feature tags available after settings are loaded were being ignored, they are now considered.
* Hacks required for the Project Settings editor to work.

Fixes #64100. Fixes #64014. Fixes #61908.
2023-01-13 15:13:56 +01:00
Dmitrii Maganov 40613ebd21 GDScript: Fix typing of iterator in for loop 2023-01-13 15:36:11 +02:00
George Marques 3a5e41293c
GDScript: Fix infinite recursion in resolution of enum values 2023-01-13 10:17:30 -03:00
stmSi f286e93fef Fix OGG page_data out of bound crash 2023-01-13 13:39:03 +06:30
Rémi Verschelde e62f57f51d
Merge pull request #70904 from huangjiaminhhh/master
Fix for navmesh baking when parsing StaticBody colliders
2023-01-12 22:24:37 +01:00
Rémi Verschelde 6dba67c27d
Merge pull request #71247 from rsjtdrjgfuzkfg/etcpak
etcpak: Fix ETCPAK_TYPE_ETC2_RA_AS_RG
2023-01-12 21:10:49 +01:00
Rémi Verschelde aaa5158ff9
Merge pull request #70733 from vonagam/fix-assigning-untyped
GDScript: Fix some issues with assignments that involve untyped things
2023-01-12 20:08:55 +01:00
Rémi Verschelde 40b9c246b6
Merge pull request #71197 from adamscott/add-default-virtual-path-gdscript
Add default virtual `gdscript://` path to `GDScript` instances
2023-01-12 17:56:09 +01:00
Rémi Verschelde def592114f
Merge pull request #70700 from vonagam/fix-abstract-extends
GDScript: Fix extending abstract classes, forbid their construction
2023-01-12 17:19:51 +01:00
Dmitrii Maganov 274d49790d GDScript: Fix extending abstract classes, forbid their construction 2023-01-12 17:47:10 +02:00
Adam Scott e3e55b29ce Add default virtual `gdscript://` path to `GDScript` instances 2023-01-12 10:27:38 -05:00
Dmitrii Maganov ef81b344be GDScript: Fix wrong marking of some lines related to Variant as unsafe 2023-01-12 17:21:33 +02:00
Dmitrii Maganov 38c214d483 GDScript: Fix some issues with assignments that involve untyped things 2023-01-12 17:07:45 +02:00
Rémi Verschelde c6f4c0ac54
Merge pull request #70899 from adamscott/fix-vector-inf
Fix parse error using Vector{2,3,4}.INF
2023-01-12 15:59:01 +01:00
Dmitrii Maganov 5980abbcec GDScript: Fix getting type from PropertyInfo for Variant arguments 2023-01-12 16:47:06 +02:00
George Marques 75515e4303
Merge pull request #70987 from vonagam/fix-parameter-conversion-assign 2023-01-12 11:34:13 -03:00
George Marques 7319fa6082
Merge pull request #70713 from vonagam/fix-unnamed-enum-outer-conflicts 2023-01-12 11:22:01 -03:00
Dmitrii Maganov 0f184379de GDScript: Fix small inconsistencies with resolve_datatype 2023-01-12 15:52:55 +02:00
Rémi Verschelde a5dedfe260
Merge pull request #70731 from smix8/navigationserver_performance_monitor_4.x
Add NavigationServer Performance Monitor
2023-01-12 10:36:18 +01:00
Rémi Verschelde dd1b3ff089
Merge pull request #71224 from rsjtdrjgfuzkfg/openxr-opengl
OpenXR: Do not use SRGB swapchains with OpenGL
2023-01-12 09:07:46 +01:00
Rémi Verschelde 2fcd298f96
Merge pull request #71034 from rsjtdrjgfuzkfg/openxr-android-warning
OpenXR: Fix android loader extension detection
2023-01-12 00:56:51 +01:00
Rémi Verschelde 11449e1079
Merge pull request #71228 from vnen/gdscript-fix-nil-address-crash
GDScript: Fix temp values being written without proper clear
2023-01-12 00:53:26 +01:00
rsjtdrjgfuzkfg a1a2c2c2ce etcpak: Fix ETCPAK_TYPE_ETC2_RA_AS_RG
This commit fixes texture compression via ETCPAK_TYPE_ETC2_RA_AS_RG,
switching to the right color channels and using the right compression
method. Textures imported with previous versions need to be re-imported
in order to render correctly.
2023-01-11 23:06:35 +01:00
George Marques 66fda2aeea
GDScript: Fix temp values being written without proper clear
Temporary values in the stack were not being properly cleared when the
return value of calls were discarded, which can cause memory issues
especially for reference types like PackedByteArray.
2023-01-11 14:24:23 -03:00
Yuri Sizov f73cb4c13d
Merge pull request #71168 from guilleatm/master
Improve description of `GetNodeOrDefault` in C# API
2023-01-11 19:27:04 +03:00
rsjtdrjgfuzkfg 17a957e214 OpenXR: Do not use SRGB swapchains with OpenGL
This commit removes SRGB swapchain options for use with OpenGL, to avoid
the hardware doing an additional SRGB conversion and thus causing colors
to differ from other rendering paths.
2023-01-11 15:47:53 +01:00
Guillermo 6137929f52 Improve description of `GetNodeOrDefault` in C# API
Indenting with spaces and added a line break

Co-authored-by: Raul Santos <raulsntos@gmail.com>
2023-01-11 15:02:08 +01:00
rsjtdrjgfuzkfg b51acac638 OpenXR: Fix initialization warning on Android
This commit adds proper checking for XR_KHR_loader_init support and
fixes the warning regarding missing extensions on Android to only appear
if neither XR_KHR_loader_init nor XR_KHR_loader_init_android are
supported by the runtime.
2023-01-11 15:00:22 +01:00
Rémi Verschelde 62b023ecd3
Merge pull request #70167 from rsjtdrjgfuzkfg/pico
OpenXR: Add Pico controller profile
2023-01-11 09:49:16 +01:00
Rémi Verschelde 54688a7535
Merge pull request #71127 from reduz/drag-forward-to-callables
Change set_drag_forwarding() to use callables.
2023-01-11 01:14:58 +01:00
Rémi Verschelde 5eb161a9c8
Merge pull request #70595 from adamscott/add-gdscript-editorconfig
Add GDScript `.editorconfig` rules
2023-01-11 01:10:10 +01:00
George Marques 04d0e851ea
GDScript: Fix use of conversion assign for variant values 2023-01-10 20:01:11 -03:00
Adam Scott 44d1d72af1 Add GDScript `.editorconfig` rules
- Uniformize `.gd` unit test files indentation to tabs (where needed)
2023-01-10 12:25:35 -05:00
Juan Linietsky e6a4debede Change set_drag_forwarding() to use callables.
* This solution is much cleaner than the one in 3.x thanks to the use of callables.
* Works without issues in any language (no need to worry about camel or snake case).
* Editor code uses a compatibility function (too much work to redo).

Fixes #59899
2023-01-10 14:09:24 +01:00
Rémi Verschelde c894edd4cb
Merge pull request #71140 from vonagam/fix-const-index-subscript-type
GDScript: Fix type for index subscript on constant
2023-01-10 07:58:29 +01:00
Dmitrii Maganov ff505c9875 GDScript: Fix type for index subscript on constant 2023-01-10 07:10:00 +02:00
Adam Scott fb175d92da Fix GDScript base and outer classes, signals and functions lookup order
- Add outer class lookup test
- Add signal lookup test

Co-authored-by: Dmitrii Maganov <vonagam@gmail.com>
2023-01-09 20:12:10 -05:00
Rémi Verschelde d3fc9d9e41
Merge pull request #71051 from vonagam/consts-are-deep-start
GDScript: Begin making constants deep, not shallow or flat
2023-01-09 23:22:59 +01:00
Rémi Verschelde 509da86205
Merge pull request #69590 from anvilfolk/enums
GDScript enum fixes & refactor
2023-01-09 23:10:37 +01:00
Rémi Verschelde 4d4fcd0a6f
Merge pull request #70721 from Faless/mp/4.x_fix_relay_option
[MP] Fix server_relay being unsettable.
2023-01-09 23:09:53 +01:00
Fabio Alessandrelli 566c48f193 [MP] Convert _spawn_custom to a Callable property.
Renamed to "spawn_function".
Allow both custom spawn and auto spawn list to co-exist.

This makes it possible to implement custom spawn without being forced to
attach a script to MultiplayerSpawner directly.
2023-01-09 21:04:40 +01:00
ocean (they/them) 366ec895b1 Assorted enum and native type fixes 2023-01-09 11:08:07 -05:00
Rémi Verschelde 64f2b970d8
Merge pull request #71114 from reduz/cleanup-property-hints
Removed unused property hints and `Object::get_translatable_strings()`
2023-01-09 16:57:31 +01:00
Juan Linietsky 0e0a6bb39b
Removed unused property hints and `Object::get_translatable_strings()`
* Remove unused `EditorPropertyMember` and related hints, previouly used by
  VisualScript. Such logic should be implemented in the VS module itself.
* As the above broke compatibility with the VS module, clean up the other
  hacks that were still in core in support of VisualScript.
* `PROPERTY_USAGE_INTERNATIONALIZED` was only used in Object's
  `get_translatable_strings()`, which is a legacy function not used anywhere.
  So both are removed.
* Reordered some usage flags after the above removal to minimize the diff.
* General clean up.

Fixes #30203.

Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2023-01-09 16:56:01 +01:00
Raul Santos 59e8fc1edf
C#: Add `[Flags]` attribute to core bitfield enums 2023-01-09 16:13:28 +01:00
Rémi Verschelde df952a32f8
Merge pull request #71107 from vnen/gdscript-fix-nil-address-assign
GDScript: Don't use the NIL address to hold return value of functions
2023-01-09 14:22:16 +01:00
Rémi Verschelde c2f7c2d31a
Merge pull request #70655 from vonagam/fix-assert-multiline
GDScript: Fix multiline and trailing comma for assert
2023-01-09 14:19:37 +01:00
George Marques a1309f1f42
GDScript: Allow using await on calls to void functions 2023-01-09 09:55:05 -03:00
George Marques a3816434a6
GDScript: Don't use the NIL address to hold return value of functions
This prevents that the NIL address is filled with another value, which
causes problems for some instructions that read from NIL.
2023-01-09 09:20:18 -03:00
Rémi Verschelde b6be2ac621
Merge pull request #71028 from adamscott/make-gdscript-clear-less-prone-to-heap-use-after-free
Resolve `GDScript::clear()` `heap-use-after-free` ASAN errors
2023-01-09 09:22:39 +01:00
Rémi Verschelde 6a86dfad29
Fix typos with codespell
Also includes #71080.

Co-authored-by: Psychpsyo <60073468+Psychpsyo@users.noreply.github.com>
2023-01-09 08:39:07 +01:00