Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[4.3] Cherry-picks for the 4.3 branch (future 4.3.1) - 1st batch #97082

Merged
merged 190 commits into from
Sep 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
190 commits
Select commit Hold shift + click to select a range
e1af614
OpenGL: Unconditionally do `glDisable(GL_FRAMEBUFFER_SRGB)` because w…
dsnopek Aug 12, 2024
5caaa6c
Fix incorrect warning on SkeletonModifier
TokageItLab Aug 15, 2024
b927160
Remove superfluous `print_line` call
Naros Aug 15, 2024
13d5227
Apply patch for considering visual layers for DirectionalLight
SlashScreen Aug 11, 2024
2df506e
fix to ensure generated light probes do not get placed too close to m…
grenappels Oct 17, 2023
a7756d5
Fixed crash on PowerVR GE8320 GPUs
MileyHollenberg Jul 30, 2024
6595395
Fix LightmapGI not taking environment sky rotation into account when …
Calinou Aug 1, 2024
5a33e45
Fail when submit or sync called on main rendering device
clayjohn Aug 10, 2024
cbee164
Increase precision of skeleton transforms in the skeleton shader in t…
clayjohn Aug 12, 2024
a70df85
Fix uniform subgroup in shader will carry out to next group
jsjtxietian Jul 29, 2024
2eec361
Corrected rotation gizmo plane math for off-center perspective view.
MajorMcDoom Aug 11, 2024
302af18
Fix tooltip content being cut off at some display scales
aaronp64 May 14, 2024
91ed3cd
* Changed the VisualShaderNodeCustom template to use the correct over…
jonatanrojderd Jul 26, 2024
7984862
[BMFont] Fix importing fonts with `Match char height` enabled.
bruvzg Aug 14, 2024
8c5edcb
Run cleanup code on DisplayServer init failure to prevent crash on exit.
bruvzg Aug 14, 2024
fac1260
[.NET] Move search in files extension list definition to be after Sce…
bruvzg Aug 13, 2024
a7d79f9
Fix `TextServer::shaped_text_*_character_pos` for the first character…
bruvzg Aug 8, 2024
3dc376e
Fix shader crash when the comma used in `for` loop as a trailing
Chaosus Aug 10, 2024
cfa3366
Fix custom resources using incorrect icons
ianmccleary Jul 27, 2024
562e583
Fix split_floats behavior when spaces are used as separators
timothyqiu Aug 16, 2024
2b4ade1
Fix AudioStreamPlayer get_playback_position() for web build
yahkr Aug 6, 2024
4a64c95
Fix autoload node cannot be accessed by plugin on start-up
Hilderin Jul 26, 2024
1ebf488
Fix incorrect parsing of nested nodes when generating the POT
YeldhamDev Aug 12, 2024
b84dbab
Fix undefined `alpha_scissor` in standard shader
jsjtxietian Aug 15, 2024
6073b86
Fix typo in MultiplayerSpawner doc
Jordyfel Aug 12, 2024
ea5989e
Add NavigationLink function to change navigation map
smix8 Aug 12, 2024
c831bdb
D3D12: Be explicit about all-resources texture barriers
RandomShaper Jul 25, 2024
1f92092
Fix EditorSpinSlider when hidden
kitbdev Aug 1, 2024
2eb2052
Change "Node3D" to "Spatial" in VisualShader resource
tetrapod00 Aug 13, 2024
26b151a
Update the Android `fileLastModified` method to return values in seco…
m4gr3d Aug 15, 2024
a031407
Fix TileAtlasView bounds checks for transposed tiles
kleonc Aug 9, 2024
d915947
Fix transposed tiles drawing in GenericTilePolygonEditor
kleonc Aug 9, 2024
acba31b
Fix SoftBody3D pinned points breaking when reloading scene
jirisvd Dec 18, 2023
686591b
[ImageFont] Fix escape sequence parsing, add note to the docs.
bruvzg Aug 8, 2024
6aff947
pass in render_info to _fill_instance_data for alpha to fix overdraw …
kevinkuo52 Aug 16, 2024
6eea970
Fix Godot not quitting with `--doctool --gdscript-docs`.
anvilfolk Aug 16, 2024
6e78eec
Fix reload of GDExtension libraries in framework package on macos
TV4Fun Aug 4, 2024
63ff665
Fix GD0107 not applying to arrays and dictionaries containing nodes
juanjp600 Jul 21, 2024
bba8f85
Fix Pressing Escape doesn't exit freelook in the 3D editor
jsjtxietian Aug 5, 2024
7726ced
fix: project settings not properly saved after a file removal
Lunarisnia Aug 8, 2024
2d7266e
Ensure fog_sky_affect is used even when using a background color
clayjohn Aug 16, 2024
6b32324
prevent the click to get processed further after a paste action
Nodragem Aug 9, 2024
8ea6481
Add `stop_callable` to `AudioStreamPlayerInternal`
kus04e4ek Aug 11, 2024
3876287
Ensure selected node is a descendant of the edited scene
TokisanGames Aug 12, 2024
6d41487
OpenXR: Fix support for building against distro package
akien-mga Aug 16, 2024
6c20215
Add fixed fog to the sky in the Compatibility renderer
clayjohn Aug 16, 2024
b7fc063
Fix uid:// Paths Fail to Load at Editor Startup
Hilderin Aug 17, 2024
7266418
Fix node.duplicate, return nullptr if this operation fails.
RadiantUwU Aug 2, 2024
d8c13f8
Fix scene node selection problem when no auto expand
Hilderin Jul 26, 2024
4168220
Fix `EditorInterface.get_selected_paths()` working incorrectly when F…
fstxz Jul 24, 2024
f0f69a7
Fix Parallax2D repeats being not relative to its transform
kleonc Aug 18, 2024
c7dbcbd
Fix Skeleton2D.{_set|_get} always returning true
kleonc Aug 4, 2024
eaa8ecb
Fix bone2d scaling
TokageItLab May 8, 2024
39fb871
Fix no validation on Blender path on importation
Hilderin Jul 30, 2024
9af6e04
Fix backspace always unfolding previous line
smnast Mar 16, 2024
cff0ebd
Clear drag preview material on `NOTIFICATION_DRAG_END`
ryevdokimov Jan 13, 2024
bf5907b
StringName: Use inline static field definitions
kisg Jul 22, 2024
32f2b85
Redraw SubViewportContainer on SubViewport size change
jordi-star Dec 18, 2023
5676d39
Avoid potential crash on signal disconnection
RandomShaper Jul 25, 2024
c684d65
Use transformed roughness instead of raw roughness to calculate rough…
clayjohn Aug 12, 2024
df522db
Fix virtual binding for `ScriptLanguageExtension::_reload_scripts`
voidedWarranties Aug 18, 2024
1d0bcae
GLTF: Propagate owner for root node children
aaronfranke Aug 4, 2024
df6bbb2
Fix MenuBar popup placement assuming it's in viewport default canvas
kleonc Jun 6, 2024
d0c4f19
Fix gizmos without visible geometry not being selectable
juanjp600 Jul 19, 2024
ecbb9a9
Fix GLES3 crash with Mesh surface with exactly 65536 vertices
olawlor Aug 20, 2024
bd552ff
Fallback to theme icon when no custom icon is set in autocompletion
matheusmdx Aug 19, 2024
139f5ee
Add model_normal_matrix for fragment shader
jsjtxietian Dec 10, 2023
433509b
Fix small graph editor pins at higher display scales
aryan-11825114 Aug 17, 2024
b05470e
Fix display dialog while saving scene
Hilderin Aug 17, 2024
1ecf20c
Fix errors about `UndoRedo` history mismatch when deleting bezier track
mihe Aug 14, 2024
cf40a5b
Fix huge tscn icon in FileSystem split mode using list view
Giganzo Aug 8, 2024
b2c83b4
Relax motion vector updates to allow skipped frames for skeletons
zeux Aug 17, 2024
40dcdcb
Fix double free in FSR2 destructor
zeux Aug 17, 2024
20ce427
Remember "View Grid" (per-viewport) setting between editor sessions
tetrapod00 Aug 20, 2024
8496e07
Fix drag&drop between window on Windows
Hilderin Aug 16, 2024
0586006
Fix curve2d incorrect sample range description
jsjtxietian Aug 21, 2024
7874dad
Minor AnimationNodeBlendSpace2D documentation fixes
aaronp64 Aug 16, 2024
19bed8f
Fix Vector3 Slerp Normalizing Zero Vectors
Z0rb14n Jul 26, 2024
70a8761
Fix crash when calling OpenXRAPI::get_hand_tracker() and hand-trackin…
dsnopek Aug 22, 2024
497570b
Fix typo in Array code example
Tallivm Aug 24, 2024
9cf21b4
Fix some C# variable types In `AStar2D/3D` Class Reference
ItzCog Aug 22, 2024
2dd6968
Always store ID of PopupMenu items
KoBeWi Aug 20, 2024
219ddde
Honor `pitch_scale` value before playing audio sample
adamscott Aug 20, 2024
afc330e
Use wayland-egl-core.h instead of wayland-egl.h
jwinarske Aug 23, 2024
e59f59a
[Editor] Prevent unnecessary editor theme regeneration on unrelated s…
bruvzg Aug 20, 2024
99dde70
Fix relative paths for global class icons in C#
paulloz Aug 19, 2024
8e1d1a5
Compatibility: Fix crash when initializing certain compressed layered…
BlueCube3310 Aug 26, 2024
95a0525
Fix animation library copy-paste not preserving resource reference
mihe Jul 16, 2024
169b568
Fix C# code example for Object._get_property_list
jwodicka Aug 24, 2024
f9bcd4f
Enable revert button for `ShaderMaterial::next_pass` and `ShaderMater…
rakkarage Aug 22, 2024
0f33a4b
Fix invalid `Skeleton3D` bone pose updates
m4gr3d Aug 26, 2024
e5be133
Fix for multimesh motion vector corruption by resetting motion vector…
Lssikkes Aug 8, 2024
b605594
[Windows] Hide cursor before moving.
bruvzg Aug 27, 2024
1d775b5
[mbedTLS] Fix incorrect cert pinning with client_unsafe
Faless Aug 27, 2024
4d7feff
Fix snapping when zoomed in Polygon2D UV editor
kleonc Aug 7, 2024
4fabc1b
Fix script overwriting with external editor
kitbdev Aug 23, 2024
e2184c5
Support opening custom class documentation with "Open Documentation" …
jsjtxietian Aug 27, 2024
c4351c8
Fix RandomPCG::rand_weighted incorrectly returning -1
Togira123 Jul 3, 2024
30bba87
Fix crash when selecting ownerless 3D node.
SaracenOne Aug 28, 2024
9946eba
Windows: Call `AddDllDirectory()` with an absolute path
dsnopek Aug 27, 2024
682ee73
Fix memory leak on QOA import
DeeJayLSP Aug 28, 2024
1c9ba61
Fix missing project date showing the unix epoch
passivestar Aug 27, 2024
43fa723
Fix build logger unable to handle an event without an associated file
RedOrbweaver Aug 29, 2024
e549ab3
Fix SceneTreeDock invalid state after trying to remove internal Node
kleonc Aug 28, 2024
4acc73d
Make sure huf_decompress is only applied to 64-bit x86.
MBCX Aug 29, 2024
6ab9ec3
Add modf function and fix snap behavior
object71 Aug 30, 2024
e79157a
Only main binaries require entitlements. This fixes signing issues on…
LeonardoDemartino Aug 13, 2024
0a1724f
Use correct lightmap coefficients to ensure that the directional ligh…
clayjohn Aug 21, 2024
1e9f578
Fix no unsaved indicator Save As resource
Hilderin Aug 31, 2024
1984332
GDExtension: Show warning on missing PDB file, rather than error
dsnopek Aug 31, 2024
f3848b7
Fixes alpha materials being rendered with a reverse cull which is vis…
viksl Sep 1, 2024
f783cf7
Fix Polygon2D UV editor error when opening grid settings
larspet Aug 31, 2024
e72e42f
Fix collapsing TreeItem not updating horizontal scrollbar
timothyqiu Aug 27, 2024
1a5ac1f
[MP] Fix division by zero in network profiler
Faless Sep 2, 2024
5567fed
NoiseTexture2D/3D: Don't use a thread to regenerate when the build do…
NotWearingPants Aug 26, 2024
b60bf28
Fix physical bone update without simulating
TokageItLab Aug 29, 2024
430a69b
Fix SkyRD::Sky::free() freeing material
ComycSans Sep 2, 2024
1250b45
Various fixes for transmittance effect
clayjohn Jun 22, 2024
b1fda8f
Avoid indexing instances without a base in scene cull phase
clayjohn Aug 13, 2024
fd17fae
[RTL] Do not add final newline to the paragraph context.
bruvzg Sep 2, 2024
f8c9ec3
fix deadzone slider not working correctly
kerstop Aug 23, 2024
4d0f10a
Fix missing material override after two glb reimports
Hilderin Sep 1, 2024
1e5d7a0
Fix floating window corner radius
Giganzo Aug 29, 2024
fc5e7c7
Fix Path2D splitting
KoBeWi Aug 28, 2024
a2f64b3
Fix SubViewport/AudioStreamPlayer2D crash
aaronp64 Apr 24, 2024
ec20c3f
Fix Array.sort_custom example code
aaronp64 Aug 26, 2024
af8caff
Fix shadow mesh recursion.
RadiantUwU Aug 31, 2024
26cc137
Fix `AnimationPlayer` crash when it's made the scene root
ArshPanesar Jul 29, 2024
2b05cf1
Sky: No more auto-selecting REALTIME mode if radiance is not 256
Breush Sep 4, 2024
e09cada
Only use backbuffer mipmaps in SCREEN_TEXTURE when generated.
clayjohn Sep 3, 2024
b1c1c40
[Windows] Use the same API for all `OS_Windows::*_environment` functi…
bruvzg Sep 3, 2024
64cbde4
[Editor] Don't show popup when clicking empty in Favorites
AThousandShips Sep 4, 2024
cbcc5f8
Fix instant transformations not being committed when used in succession
ev13bird Sep 3, 2024
2635ff7
Prevent editing value on focus when `EditorSpinSlider` is read-only
detomon Jul 14, 2024
d842870
Fix selection stuck after saving scene
Hilderin Sep 4, 2024
00866dc
[Editor] Prevent duplicate `Open in Editor` buttons in scene tree dock
AThousandShips Sep 4, 2024
3783527
[Editor] Fix handle ID being passed for 3D Gizmo plugins
AThousandShips Mar 17, 2024
1629e9b
Fix shift clicking on Add Sun/Environment to Scene buttons
Giganzo Sep 4, 2024
d7a8654
Fix 2D debug navigation flickering with tile maps
smix8 Sep 5, 2024
61b2ad9
Fix Set Frame Title popup position
Giganzo Sep 3, 2024
c4525f2
GDScript: Do not produce `UNUSED_SIGNAL` warning for common implicit …
dalexeev Mar 19, 2024
fb1758c
Fixes godot crash or give unclear message when exporting with invalid…
jsjtxietian Aug 1, 2024
21a0a84
Fix StyleBoxFlat rectangles skewing independently
kleonc Aug 29, 2024
7f0cc1a
Fix "reparent to new node" not remembering index
RedMser Aug 30, 2024
02c4508
Fix "reparent to new node" when node has internal children
RedMser Sep 6, 2024
f5b5b6c
Fix interactive audio transitions fade in for clips with auto_advance
GustJc Aug 19, 2024
b2b882c
Fix super call in various `get_configuration_warnings` methods
AThousandShips Jun 19, 2024
f11f9e3
AudioServer: Fix code style issues
RandomShaper Jul 26, 2024
0b815cb
Fix leak when using audio samples instead of streams
adamscott Sep 4, 2024
cab91cf
fix clear button on Array[Node]
ajreckof Sep 5, 2024
f757cc9
RenderingDevice: Fix uncapped mipmap sizes causing div-by-zero
RandomShaper Sep 9, 2024
6b7f36e
[Windows] Fix broken apksigner detection.
bruvzg Sep 10, 2024
2816428
Enable MSAA support for all non-web platforms
Praytic Sep 2, 2024
e7e723b
Do not defer PathFollow3D transform updates
xiongyaohua Aug 27, 2024
c7a173a
Fix directory empty bug on Android
shahriarlabib000 Sep 8, 2024
88370e4
Fix undoing "Move tiles" TileMapLayer action when drag/drop areas ove…
kleonc Sep 11, 2024
1d790de
Fix parsing of `4.` in Expression
timothyqiu Jul 2, 2024
3fac9e4
Fixed OpenGL shadow textures not honoring texture type when reusing t…
Rudolph-B Sep 3, 2024
d51be1f
[Buildsystem] Improve cache handling
AThousandShips Sep 6, 2024
90f1c3e
Fix issue with GDScript binary tokens being non-deterministic
mihe Sep 11, 2024
69713da
[RTL] Fix font not updated for some spans.
bruvzg Sep 11, 2024
6dd8e7f
Update AnimationPlayer in real-time when bezier curve properties or b…
Dowsley Sep 11, 2024
4addddd
Compatibility: Fix alignment of compressed textures when retrieving
BlueCube3310 Sep 11, 2024
51c86eb
WAV: Fix one frame overflow at the end
DeeJayLSP Sep 9, 2024
f4b71b5
Fix polygon node losing its UV toolbar by adding a call to the show m…
object71 Sep 2, 2024
1370138
Fix slider size in compact mode
Giganzo Sep 9, 2024
927d7a9
Fix below what value is invalid in default_font_size doc
Giganzo Sep 9, 2024
d00e4fb
Fix double lock/group buttons when starting editor with empty scene
Giganzo Sep 5, 2024
34251cf
[Windows] Use `GetFileTime` for `FileAccess`
AThousandShips Aug 16, 2023
d92f901
Fix gamepad triggers not working on web exports
noidexe Jul 25, 2024
018f8be
Object: Let debug lock handle callee destruction within call chain gr…
RandomShaper Sep 11, 2024
3030d4b
Object: Add tests about the safety of tail destruction
RandomShaper Sep 12, 2024
a2e3c13
LSP: Omit some values based on specification version 3.17
HolonProduction Sep 8, 2024
7246e14
Fix editor_doc_cache locked on editor startup
Hilderin Sep 14, 2024
abe68d3
Fix description of `Array.sort_custom()`
Daylily-Zeleen Sep 15, 2024
47f34e8
Add missing "Quad" capture TransitionType enum hint
TokageItLab Sep 14, 2024
03168cc
LSP: Don't use smart resolve for completion
HolonProduction Sep 7, 2024
0a83f06
Fix `VSlider` grabber area.
WhalesState Sep 14, 2024
4944d59
[Windows] Run native file dialogs in thread to make it non-blocking.
bruvzg Jul 24, 2024
35b4a1f
[Windows] Emit native file dialog callback from event loop, fix selec…
bruvzg Aug 23, 2024
f7ad4dc
Remove debug print from Android `DisplayServer.screen_get_scale` impl…
rcadena Sep 16, 2024
4abc358
thorvg: Update to 0.14.7
akien-mga Aug 27, 2024
7a7e412
thorvg: Update to 0.14.8, and workaround Bezier precision regression
akien-mga Aug 30, 2024
99a8821
thorvg: Update to 0.14.9
akien-mga Sep 6, 2024
f273c7c
thorvg: Update to 0.14.10
akien-mga Sep 16, 2024
2c612ab
WorkerThreadPool: Fix end-of-yield logic potentially leading to deadl…
RandomShaper Aug 28, 2024
56a1d07
Added a more detailed error message when instatiating a scene with mi…
RPicster Sep 16, 2024
15129c0
Fix error reopening non existing scene on startup
Hilderin Sep 15, 2024
7b32e96
Fix syncing PhysicalBone internal poses individually
TokageItLab Sep 14, 2024
3a2804a
Fix for GLES3 radiance cubemap update
patwork Sep 16, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -1070,7 +1070,6 @@ if "check_c_headers" in env:
env.AppendUnique(CPPDEFINES=[headers[header]])


# FIXME: This method mixes both cosmetic progress stuff and cache handling...
methods.show_progress(env)
# TODO: replace this with `env.Dump(format="json")`
# once we start requiring SCons 4.0 as min version.
Expand Down Expand Up @@ -1102,3 +1101,5 @@ def purge_flaky_files():


atexit.register(purge_flaky_files)

methods.clean_cache(env)
2 changes: 1 addition & 1 deletion core/SCsub
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ if env["builtin_zstd"]:
"decompress/zstd_decompress_block.c",
"decompress/zstd_decompress.c",
]
if env["platform"] in ["android", "ios", "linuxbsd", "macos"]:
if env["platform"] in ["android", "ios", "linuxbsd", "macos"] and env["arch"] == "x86_64":
# Match platforms with ZSTD_ASM_SUPPORTED in common/portability_macros.h
thirdparty_zstd_sources.append("decompress/huf_decompress_amd64.S")
thirdparty_zstd_sources = [thirdparty_zstd_dir + file for file in thirdparty_zstd_sources]
Expand Down
9 changes: 0 additions & 9 deletions core/config/project_settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1489,15 +1489,6 @@ ProjectSettings::ProjectSettings() {
GLOBAL_DEF(PropertyInfo(Variant::INT, "audio/general/ios/session_category", PROPERTY_HINT_ENUM, "Ambient,Multi Route,Play and Record,Playback,Record,Solo Ambient"), 0);
GLOBAL_DEF("audio/general/ios/mix_with_others", false);

PackedStringArray extensions;
extensions.push_back("gd");
if (ClassDB::class_exists("CSharpScript")) {
extensions.push_back("cs");
}
extensions.push_back("gdshader");

GLOBAL_DEF(PropertyInfo(Variant::PACKED_STRING_ARRAY, "editor/script/search_in_file_extensions"), extensions);

_add_builtin_input_map();

// Keep the enum values in sync with the `DisplayServer::ScreenOrientation` enum.
Expand Down
11 changes: 1 addition & 10 deletions core/extension/gdextension.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -781,23 +781,14 @@ Error GDExtension::open_library(const String &p_path, const String &p_entry_symb
}
}

String actual_lib_path;
OS::GDExtensionData data = {
true, // also_set_library_path
&actual_lib_path, // r_resolved_path
&library_path, // r_resolved_path
Engine::get_singleton()->is_editor_hint(), // generate_temp_files
&abs_dependencies_paths, // library_dependencies
};
Error err = OS::get_singleton()->open_dynamic_library(abs_path, library, &data);

if (actual_lib_path.get_file() != abs_path.get_file()) {
// If temporary files are generated, let's change the library path to point at the original,
// because that's what we want to check to see if it's changed.
library_path = actual_lib_path.get_base_dir().path_join(p_path.get_file());
} else {
library_path = actual_lib_path;
}

ERR_FAIL_COND_V_MSG(err == ERR_FILE_NOT_FOUND, err, "GDExtension dynamic library not found: " + abs_path);
ERR_FAIL_COND_V_MSG(err != OK, err, "Can't open GDExtension dynamic library: " + abs_path);

Expand Down
2 changes: 1 addition & 1 deletion core/input/godotcontrollerdb.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ __XINPUT_DEVICE__,XInput Gamepad,a:b12,b:b13,x:b14,y:b15,start:b4,guide:b10,back
Default Android Gamepad,Default Controller,leftx:a0,lefty:a1,dpdown:h0.4,rightstick:b8,rightshoulder:b10,rightx:a2,start:b6,righty:a3,dpleft:h0.8,lefttrigger:a4,x:b2,dpup:h0.1,back:b4,leftstick:b7,leftshoulder:b9,y:b3,a:b0,dpright:h0.2,righttrigger:a5,b:b1,platform:Android,

# Web
standard,Standard Gamepad Mapping,leftx:a0,lefty:a1,rightx:a2,righty:a3,lefttrigger:b6,righttrigger:b7,a:b0,b:b1,x:b2,y:b3,leftshoulder:b4,rightshoulder:b5,back:b8,start:b9,leftstick:b10,rightstick:b11,dpup:b12,dpdown:b13,dpleft:b14,dpright:b15,guide:b16,leftstick:b10,rightstick:b11,platform:Web,
standard,Standard Gamepad Mapping,leftx:a0,lefty:a1,rightx:a2,righty:a3,lefttrigger:+a4,righttrigger:+a5,a:b0,b:b1,x:b2,y:b3,leftshoulder:b4,rightshoulder:b5,back:b8,start:b9,leftstick:b10,rightstick:b11,dpup:b12,dpdown:b13,dpleft:b14,dpright:b15,guide:b16,leftstick:b10,rightstick:b11,platform:Web,
Linux24c6581a,PowerA Xbox One Cabled,a:b0,b:b1,y:b3,x:b2,start:b7,guide:b8,back:b6,leftstick:b9,rightstick:b10,leftshoulder:b4,rightshoulder:b5,dpup:-a7,dpleft:-a6,dpdown:+a7,dpright:+a6,leftx:a0,lefty:a1,rightx:a3,righty:a4,lefttrigger:a2,righttrigger:a5,platform:Web,
Linux0e6f0301,Logic 3 Controller (xbox compatible),a:b0,b:b1,y:b3,x:b2,start:b7,guide:b8,back:b6,leftstick:b9,rightstick:b10,leftshoulder:b4,rightshoulder:b5,dpup:-a7,dpleft:-a6,dpdown:+a7,dpright:+a6,leftx:a0,lefty:a1,rightx:a3,righty:a4,lefttrigger:a2,righttrigger:a5,platform:Web,
Linux045e028e,Microsoft X-Box 360 pad,a:b0,b:b1,y:b3,x:b2,start:b7,guide:b8,back:b6,leftstick:b9,rightstick:b10,leftshoulder:b4,rightshoulder:b5,dpup:-a7,dpleft:-a6,dpdown:+a7,dpright:+a6,leftx:a0,lefty:a1,rightx:a3,righty:a4,lefttrigger:a2,righttrigger:a5,platform:Web,
Expand Down
10 changes: 3 additions & 7 deletions core/math/expression.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,7 @@

#include "expression.h"

#include "core/io/marshalls.h"
#include "core/math/math_funcs.h"
#include "core/object/class_db.h"
#include "core/object/ref_counted.h"
#include "core/os/os.h"
#include "core/variant/variant_parser.h"

Error Expression::_get_token(Token &r_token) {
while (true) {
Expand Down Expand Up @@ -392,7 +387,6 @@ Error Expression::_get_token(Token &r_token) {
if (is_digit(c)) {
} else if (c == 'e') {
reading = READING_EXP;

} else {
reading = READING_DONE;
}
Expand All @@ -419,7 +413,9 @@ Error Expression::_get_token(Token &r_token) {
is_first_char = false;
}

str_ofs--;
if (c != 0) {
str_ofs--;
}

r_token.type = TK_CONSTANT;

Expand Down
3 changes: 3 additions & 0 deletions core/math/math_funcs.h
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,9 @@ class Math {
static _ALWAYS_INLINE_ double fmod(double p_x, double p_y) { return ::fmod(p_x, p_y); }
static _ALWAYS_INLINE_ float fmod(float p_x, float p_y) { return ::fmodf(p_x, p_y); }

static _ALWAYS_INLINE_ double modf(double p_x, double *r_y) { return ::modf(p_x, r_y); }
static _ALWAYS_INLINE_ float modf(float p_x, float *r_y) { return ::modff(p_x, r_y); }

static _ALWAYS_INLINE_ double floor(double p_x) { return ::floor(p_x); }
static _ALWAYS_INLINE_ float floor(float p_x) { return ::floorf(p_x); }

Expand Down
5 changes: 5 additions & 0 deletions core/math/random_pcg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,11 @@ int64_t RandomPCG::rand_weighted(const Vector<float> &p_weights) {
}
}

for (int64_t i = weights_size - 1; i >= 0; --i) {
if (weights[i] > 0) {
return i;
}
}
return -1;
}

Expand Down
17 changes: 12 additions & 5 deletions core/object/object.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,17 @@
#ifdef DEBUG_ENABLED

struct _ObjectDebugLock {
Object *obj;
ObjectID obj_id;

_ObjectDebugLock(Object *p_obj) {
obj = p_obj;
obj->_lock_index.ref();
obj_id = p_obj->get_instance_id();
p_obj->_lock_index.ref();
}
~_ObjectDebugLock() {
obj->_lock_index.unref();
Object *obj_ptr = ObjectDB::get_instance(obj_id);
if (likely(obj_ptr)) {
obj_ptr->_lock_index.unref();
}
}
};

Expand Down Expand Up @@ -2097,7 +2100,11 @@ Object::~Object() {
// Disconnect signals that connect to this object.
while (connections.size()) {
Connection c = connections.front()->get();
bool disconnected = c.signal.get_object()->_disconnect(c.signal.get_name(), c.callable, true);
Object *obj = c.callable.get_object();
bool disconnected = false;
if (likely(obj)) {
disconnected = c.signal.get_object()->_disconnect(c.signal.get_name(), c.callable, true);
}
if (unlikely(!disconnected)) {
// If the disconnect has failed, abandon the connection to avoid getting trapped in an infinite loop here.
connections.pop_front();
Expand Down
1 change: 1 addition & 0 deletions core/object/script_language_extension.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ void ScriptLanguageExtension::_bind_methods() {
GDVIRTUAL_BIND(_debug_get_current_stack_info);

GDVIRTUAL_BIND(_reload_all_scripts);
GDVIRTUAL_BIND(_reload_scripts, "scripts", "soft_reload");
GDVIRTUAL_BIND(_reload_tool_script, "script", "soft_reload");

GDVIRTUAL_BIND(_get_recognized_extensions);
Expand Down
5 changes: 4 additions & 1 deletion core/object/worker_thread_pool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,10 @@ void WorkerThreadPool::_wait_collaboratively(ThreadData *p_caller_pool_thread, T
p_caller_pool_thread->signaled = false;

if (IS_WAIT_OVER) {
p_caller_pool_thread->yield_is_over = false;
if (unlikely(p_task == ThreadData::YIELDING)) {
p_caller_pool_thread->yield_is_over = false;
}

if (!exit_threads && was_signaled) {
// This thread was awaken for some additional reason, but it's about to exit.
// Let's find out what may be pending and forward the requests.
Expand Down
9 changes: 0 additions & 9 deletions core/string/string_name.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,19 +39,10 @@ StaticCString StaticCString::create(const char *p_ptr) {
return scs;
}

StringName::_Data *StringName::_table[STRING_TABLE_LEN];

StringName _scs_create(const char *p_chr, bool p_static) {
return (p_chr[0] ? StringName(StaticCString::create(p_chr), p_static) : StringName());
}

bool StringName::configured = false;
Mutex StringName::mutex;

#ifdef DEBUG_ENABLED
bool StringName::debug_stringname = false;
#endif

void StringName::setup() {
ERR_FAIL_COND(configured);
for (int i = 0; i < STRING_TABLE_LEN; i++) {
Expand Down
8 changes: 4 additions & 4 deletions core/string/string_name.h
Original file line number Diff line number Diff line change
Expand Up @@ -67,26 +67,26 @@ class StringName {
_Data() {}
};

static _Data *_table[STRING_TABLE_LEN];
static inline _Data *_table[STRING_TABLE_LEN];

_Data *_data = nullptr;

void unref();
friend void register_core_types();
friend void unregister_core_types();
friend class Main;
static Mutex mutex;
static inline Mutex mutex;
static void setup();
static void cleanup();
static bool configured;
static inline bool configured = false;
#ifdef DEBUG_ENABLED
struct DebugSortReferences {
bool operator()(const _Data *p_left, const _Data *p_right) const {
return p_left->debug_references > p_right->debug_references;
}
};

static bool debug_stringname;
static inline bool debug_stringname = false;
#endif

StringName(_Data *p_data) { _data = p_data; }
Expand Down
10 changes: 8 additions & 2 deletions core/string/ustring.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1537,13 +1537,16 @@ Vector<double> String::split_floats(const String &p_splitter, bool p_allow_empty
int from = 0;
int len = length();

String buffer = *this;
while (true) {
int end = find(p_splitter, from);
if (end < 0) {
end = len;
}
if (p_allow_empty || (end > from)) {
ret.push_back(String::to_float(&get_data()[from]));
buffer[end] = 0;
ret.push_back(String::to_float(&buffer.get_data()[from]));
buffer[end] = _cowdata.get(end);
}

if (end == len) {
Expand All @@ -1561,6 +1564,7 @@ Vector<float> String::split_floats_mk(const Vector<String> &p_splitters, bool p_
int from = 0;
int len = length();

String buffer = *this;
while (true) {
int idx;
int end = findmk(p_splitters, from, &idx);
Expand All @@ -1572,7 +1576,9 @@ Vector<float> String::split_floats_mk(const Vector<String> &p_splitters, bool p_
}

if (p_allow_empty || (end > from)) {
ret.push_back(String::to_float(&get_data()[from]));
buffer[end] = 0;
ret.push_back(String::to_float(&buffer.get_data()[from]));
buffer[end] = _cowdata.get(end);
}

if (end == len) {
Expand Down
4 changes: 2 additions & 2 deletions doc/classes/AStar2D.xml
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@
astar.ConnectPoints(2, 3, false);
astar.ConnectPoints(4, 3, false);
astar.ConnectPoints(1, 4, false);
int[] res = astar.GetIdPath(1, 3); // Returns [1, 2, 3]
long[] res = astar.GetIdPath(1, 3); // Returns [1, 2, 3]
[/csharp]
[/codeblocks]
If you change the 2nd point's weight to 3, then the result will be [code][1, 4, 3][/code] instead, because now even though the distance is longer, it's "easier" to get through point 4 than through point 2.
Expand Down Expand Up @@ -209,7 +209,7 @@
astar.ConnectPoints(1, 2, true);
astar.ConnectPoints(1, 3, true);

int[] neighbors = astar.GetPointConnections(1); // Returns [2, 3]
long[] neighbors = astar.GetPointConnections(1); // Returns [2, 3]
[/csharp]
[/codeblocks]
</description>
Expand Down
4 changes: 2 additions & 2 deletions doc/classes/AStar3D.xml
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@
astar.ConnectPoints(2, 3, false);
astar.ConnectPoints(4, 3, false);
astar.ConnectPoints(1, 4, false);
int[] res = astar.GetIdPath(1, 3); // Returns [1, 2, 3]
long[] res = astar.GetIdPath(1, 3); // Returns [1, 2, 3]
[/csharp]
[/codeblocks]
If you change the 2nd point's weight to 3, then the result will be [code][1, 4, 3][/code] instead, because now even though the distance is longer, it's "easier" to get through point 4 than through point 2.
Expand Down Expand Up @@ -236,7 +236,7 @@
astar.ConnectPoints(1, 2, true);
astar.ConnectPoints(1, 3, true);

int[] neighbors = astar.GetPointConnections(1); // Returns [2, 3]
long[] neighbors = astar.GetPointConnections(1); // Returns [2, 3]
[/csharp]
[/codeblocks]
</description>
Expand Down
4 changes: 2 additions & 2 deletions doc/classes/AnimationNodeBlendSpace2D.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
</brief_description>
<description>
A resource used by [AnimationNodeBlendTree].
[AnimationNodeBlendSpace1D] represents a virtual 2D space on which [AnimationRootNode]s are placed. Outputs the linear blend of the three adjacent animations using a [Vector2] weight. Adjacent in this context means the three [AnimationRootNode]s making up the triangle that contains the current value.
[AnimationNodeBlendSpace2D] represents a virtual 2D space on which [AnimationRootNode]s are placed. Outputs the linear blend of the three adjacent animations using a [Vector2] weight. Adjacent in this context means the three [AnimationRootNode]s making up the triangle that contains the current value.
You can add vertices to the blend space with [method add_blend_point] and automatically triangulate it by setting [member auto_triangles] to [code]true[/code]. Otherwise, use [method add_triangle] and [method remove_triangle] to triangulate the blend space by hand.
</description>
<tutorials>
Expand Down Expand Up @@ -93,7 +93,7 @@
<param index="0" name="point" type="int" />
<param index="1" name="pos" type="Vector2" />
<description>
Updates the position of the point at index [param point] on the blend axis.
Updates the position of the point at index [param point] in the blend space.
</description>
</method>
</methods>
Expand Down
6 changes: 3 additions & 3 deletions doc/classes/Array.xml
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@
var numbers = [1, 2, 3]
var extra = [4, 5, 6]
numbers.append_array(extra)
print(nums) # Prints [1, 2, 3, 4, 5, 6]
print(numbers) # Prints [1, 2, 3, 4, 5, 6]
[/codeblock]
</description>
</method>
Expand Down Expand Up @@ -715,7 +715,7 @@
<param index="0" name="func" type="Callable" />
<description>
Sorts the array using a custom [Callable].
[param func] is called as many times as necessary, receiving two array elements as arguments. The function should return [code]true[/code] if the first element should be moved [i]behind[/i] the second one, otherwise it should return [code]false[/code].
[param func] is called as many times as necessary, receiving two array elements as arguments. The function should return [code]true[/code] if the first element should be moved [i]before[/i] the second one, otherwise it should return [code]false[/code].
[codeblock]
func sort_ascending(a, b):
if a[1] &lt; b[1]:
Expand All @@ -728,7 +728,7 @@
print(my_items) # Prints [["Rice", 4], ["Tomato", 5], ["Apple", 9]]

# Sort descending, using a lambda function.
my_items.sort_custom(func(a, b): return a[0] &gt; b[0])
my_items.sort_custom(func(a, b): return a[1] &gt; b[1])
print(my_items) # Prints [["Apple", 9], ["Tomato", 5], ["Rice", 4]]
[/codeblock]
It may also be necessary to use this method to sort strings by natural order, with [method String.naturalnocasecmp_to], as in the following example:
Expand Down
2 changes: 1 addition & 1 deletion doc/classes/Curve2D.xml
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
<param index="0" name="idx" type="int" />
<param index="1" name="t" type="float" />
<description>
Returns the position between the vertex [param idx] and the vertex [code]idx + 1[/code], where [param t] controls if the point is the first vertex ([code]t = 0.0[/code]), the last vertex ([code]t = 1.0[/code]), or in between. Values of [param t] outside the range ([code]0.0 &gt;= t &lt;=1[/code]) give strange, but predictable results.
Returns the position between the vertex [param idx] and the vertex [code]idx + 1[/code], where [param t] controls if the point is the first vertex ([code]t = 0.0[/code]), the last vertex ([code]t = 1.0[/code]), or in between. Values of [param t] outside the range ([code]0.0 &lt;= t &lt;= 1.0[/code]) give strange, but predictable results.
If [param idx] is out of bounds it is truncated to the first or last vertex, and [param t] is ignored. If the curve has no points, the function sends an error to the console, and returns [code](0, 0)[/code].
</description>
</method>
Expand Down
13 changes: 13 additions & 0 deletions doc/classes/NavigationLink2D.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,12 @@
Returns whether or not the specified layer of the [member navigation_layers] bitmask is enabled, given a [param layer_number] between 1 and 32.
</description>
</method>
<method name="get_navigation_map" qualifiers="const">
<return type="RID" />
<description>
Returns the current navigation map [RID] used by this link.
</description>
</method>
<method name="get_rid" qualifiers="const">
<return type="RID" />
<description>
Expand Down Expand Up @@ -57,6 +63,13 @@
Based on [param value], enables or disables the specified layer in the [member navigation_layers] bitmask, given a [param layer_number] between 1 and 32.
</description>
</method>
<method name="set_navigation_map">
<return type="void" />
<param index="0" name="navigation_map" type="RID" />
<description>
Sets the [RID] of the navigation map this link should use. By default the link will automatically join the [World2D] default navigation map so this function is only required to override the default map.
</description>
</method>
</methods>
<members>
<member name="bidirectional" type="bool" setter="set_bidirectional" getter="is_bidirectional" default="true">
Expand Down
Loading
Loading