Marcel Admiraal
0fb4dbf1bd
Avoid creating joy_names map entries when using Map operator[]
2021-04-17 20:29:04 +01:00
George Marques
a6c5938909
Remove return value type adjust of builtin method calls
...
Make calls faster with the caveat that the caller needs to make sure
that the return value type is already correct.
2021-04-16 12:04:34 -03:00
Rémi Verschelde
200d9a734c
Merge pull request #47701 from vnen/gdscript-test-runner
2021-04-16 10:34:39 +02:00
Rémi Verschelde
a3ca7844b3
Merge pull request #47726 from dalexeev/patch-1
...
Fix `Color::get_{r,g,b,a}8`
2021-04-16 10:30:53 +02:00
Bartłomiej T. Listwon
1eaaf2f9a2
Separate set.h from map.h
2021-04-14 11:43:45 +02:00
Julien Nguyen
026b8497d1
Fix PackedFloat32Array get index not working
2021-04-12 23:33:06 +02:00
Fabio Alessandrelli
4d5c8e0b18
This renames PacketPeerUDP.listen to bind.
2021-04-12 21:05:33 +02:00
dam
da8c2310b5
Allow local port control on net_socket connections
2021-04-12 21:05:33 +02:00
Johannes
33d6eccdec
Fix _File::get_buffer
length always set to p_length
2021-04-11 23:11:13 +02:00
Rémi Verschelde
c1b4755aa1
Merge pull request #47761 from reduz/packedbytearray-marshalling
...
Add marshalling to PackedByteArray
2021-04-10 19:17:31 +02:00
Fabio Alessandrelli
6138396e00
Merge pull request #47512 from DanielKriz/bugfix/uri_encode
...
fix wrong encoding format in uri_encode
2021-04-10 18:58:40 +02:00
reduz
e67c63108b
Add marshalling to PackedByteArray
...
-Decode/Encode functions for u8,s8,u16,s16,u32,s32,u64,s64,half,float,double,variant
-Improved binder template to allow this
Given in Godot 4.0 PackedByteArray is passed as reference, it is now possible to have these functions there, which makes the most sense.
2021-04-10 13:09:22 -03:00
Daniel Kříž
13c999d9d7
fix wrong encoding in uri_encode
2021-04-10 17:54:18 +02:00
Danil Alexeev
e63976d4b2
Fix Color::get_{r,g,b,a}8
...
Closes #47022 .
2021-04-09 16:11:02 +03:00
George Marques
b25ab27d4a
Set resource path earlier on ProjectSettings setup
...
Since loading the config might use the resource path, it needs to be
set before that happens.
2021-04-08 09:35:06 -03:00
Rémi Verschelde
f83486b430
Sync controller mappings DB with SDL2 community repo
...
Synced with gabomdq/SDL_GameControllerDB@01dce71403 .
2021-04-06 22:39:35 +02:00
George Marques
f8dd7917ec
Add flag to stop printing to stdout/stderr
...
This allows the terminal output to be suppressed but still be captured
by print/error handlers.
2021-04-06 07:36:41 -03:00
Rémi Verschelde
d83761ba80
Style: Apply clang-tidy's readability-braces-around-statements
2021-04-05 14:09:59 +02:00
Rémi Verschelde
9bbe51dc27
Style: Apply clang-tidy's modernize-use-nullptr
2021-04-05 14:05:07 +02:00
jmb462
400843c172
fix crash on null class in ClassDB.get_property() and set_property()
2021-04-02 20:05:01 +02:00
Rémi Verschelde
4b6e9f3157
Merge pull request #46991 from madmiraal/rename-invert-reverse
...
Rename Array.invert() to Array.reverse()
2021-04-01 13:32:22 +02:00
rafallus
9196722935
Fix Quat multiplication
...
x, y, z values were updated too early
2021-03-29 13:57:34 -06:00
Rémi Verschelde
aba03110ba
Merge pull request #46830 from vnen/gdscript-typed-arrays
...
GDScript typed arrays
2021-03-29 16:47:38 +02:00
Juan Linietsky
4763835c11
Optimize image channel detection
...
Speeds up compression
2021-03-26 15:44:00 -03:00
Rémi Verschelde
c6b9ceadf2
Merge pull request #47163 from bruvzg/macos_sandbox_file_dialog
...
FileDialog: add Back/Forward buttons, add message for inaccessible folders.
2021-03-26 00:00:25 +01:00
Rémi Verschelde
cde67f0315
Sync controller mappings DB with SDL2 community repo
...
Synced with gabomdq/SDL_GameControllerDB@807ac1fbf9 .
2021-03-23 13:18:43 +01:00
Rémi Verschelde
6610289fdd
Merge pull request #40804 from naithar/fix/json-parse
...
JSON parser fix
2021-03-23 13:07:04 +01:00
Aaron Franke
a5324787c8
Rename some more global enums (Key, Joy, MIDI)
2021-03-23 07:13:23 -04:00
Aaron Franke
10d7fccb54
Rename ButtonList enum and members to MouseButton
2021-03-23 07:13:23 -04:00
Rémi Verschelde
12f7c1cb25
Merge pull request #47231 from Faless/js/4.x_gamepad_db_dualsense
...
[HTML5] Logitech Dual Action Gamepad FF/Linux
2021-03-23 11:54:20 +01:00
bruvzg
b202a0dd2a
FileDialog: add Back/Forward buttons, add message for inaccessible folders.
2021-03-23 08:03:41 +02:00
Rémi Verschelde
6a84ade316
Merge pull request #45234 from madmiraal/rename-phashtranslation
...
Rename PHashTranslation to OptimizedTranslation
2021-03-23 00:12:12 +01:00
Rémi Verschelde
11718dbef9
Merge pull request #45562 from aaronfranke/core-modules-real_t
...
Use real_t in GridMap and VariantParser
2021-03-23 00:10:04 +01:00
Rémi Verschelde
8fb382afb8
Merge pull request #34587 from YeldhamDev/translation_resource_notification_removal
...
Remove translation change notification when setting the locale of a Translation resource
2021-03-22 23:30:20 +01:00
Juan Linietsky
8d64f3bd76
Add a "keep" import mode to keep files as-is and export them.
2021-03-22 17:19:19 -03:00
Juan Linietsky
97a3a66220
Improved 3D Scene Importer
...
* Added option for importers to show an Advanced settings dialog
* Created advanced settings dialog for Scene Importer
* Cleaned up importers (remove many old/unused options)
* Added the ability to customize every node, material, mesh and animation individually
* Saving to animations and meshes to files is now a manual process, making it more predictable
* Added the ability for materials to be replaced by external files (or to be made external, up to you).
* When doubleclicking an impoted scene in the filesystem dock, it automatically shows the import settings instead of asking to open it.
WARNING: Lightmap UV unwrap is not working, it needs to be re-made.
2021-03-22 12:16:40 -03:00
Fabio Alessandrelli
70d5f652a2
[HTML5] Logitech Dual Action Gamepad FF/Linux
2021-03-21 15:59:31 +01:00
Marcel Admiraal
755c70b871
Rename Array.invert() to Array.reverse()
...
Does the same internally for List and Vector<>, which includes all
PackedArray types.
2021-03-21 10:20:08 +00:00
Marcel Admiraal
07f1cd5ff8
Rename PHashTranslation to OptimizedTranslation
2021-03-20 10:02:47 +00:00
Aaron Franke
affe3c817a
Use real_t in GridMap and VariantParser
2021-03-19 00:56:34 -04:00
George Marques
997a8ae9e8
Make Variant setget use set() method of Array
...
This ensure that typed arrays are properly checked when setting an
element.
Moved the macro to a straight declaration since the macro was only used
for Array and it now is quite specific to the Array class.
2021-03-18 10:18:59 -03:00
George Marques
fbfdd5e110
Add functions to retrieve type of a typed Array
2021-03-18 10:18:58 -03:00
George Marques
497dab94be
Don't check type when assigning Array
...
The array should just assimilate the type of the other one since
assignment in this case means a change in the reference.
This also adds a `typed_assign` function for the cases where type
validation is wanted.
2021-03-18 10:18:58 -03:00
Alex Hirsch
c28428fe4d
Allow nullptr with zero length in FileAccess get_buffer
...
fix #47071
2021-03-16 22:55:11 +01:00
Rémi Verschelde
97ce8708e8
Merge pull request #47076 from Faless/debugger/4.x_remote_peer_backoff
...
[Net] Make debugger peer less CPU intensive.
2021-03-16 22:14:21 +01:00
Fabio Alessandrelli
87353c90fa
[Net] Make debugger peer less CPU intensive.
...
Make sure that RemoteDebuggerPeer wait at least 100us between polls
(effectively forcing a min tick of 100 microseconds).
This greatly improve performances (the call to poll was useless since
during low traffic, writes would always be available, and during high
traffic, reads would always be available, effectively making it a
busy-waiting loop). We could further improve this, by separating the two
polls, and adjust the min tick based on load, but this is most likely
more than enough already without sacrificing too much on high loads.
2021-03-16 21:48:15 +01:00
Fredia Huya-Kouadio
862e2df1a4
Fix bug causing project.godot
to be ignored when project.binary
is missing
2021-03-16 09:38:35 -07:00
Rémi Verschelde
224f5cab99
Merge pull request #46378 from reduz/static-method-in-variant-types
...
Add static method support to core Variant types
2021-03-16 15:44:04 +01:00
reduz
ecfa570ccb
Add static method support to core Variant types
...
* Properly exposed, including validated and variant call
* Bound static functions in String and Color
* Did not add support for scripting languages, will have to be added manually.
2021-03-16 10:53:05 -03:00
Rémi Verschelde
8051307efe
Merge pull request #46810 from W4RH4WK/file-access-get-buffer-parameter-checks
...
Add parameter checks to FileAccess get_buffer functions
2021-03-14 01:11:55 +01:00
Anshul7sp1
91181c2086
Fixes small typos and grammar correction
2021-03-12 19:05:16 +05:30
Aitor Cereceto
1e820b3d9d
[46188] fix: get unix from datetime when empty dict
2021-03-12 09:27:21 +01:00
Gilles Roudière
ba1344408f
Implement Navigation layers
2021-03-10 11:23:06 +01:00
Rémi Verschelde
83b1acdc60
Merge pull request #45545 from abaire/relaxes_gltf_name_sanitization
...
Relaxes node name sanitization in gltf documents.
2021-03-09 14:54:33 +01:00
Alex Hirsch
cdf3099c68
Add parameter checkes to FileAccess get_buffer functions
...
fix #46540
2021-03-09 13:55:20 +01:00
bruvzg
741e1cf672
Move caller_id init to Thread constructor to fix UWP build.
2021-03-09 08:40:30 +02:00
Rémi Verschelde
afd0df7921
Merge pull request #46386 from KoBeWi/projekt_settingz
...
Clarify ProjectSettings.save for exported projects
2021-03-07 10:17:59 +01:00
kobewi
156c402f2b
Allow to save override.cfg with ProjectSettings
2021-03-07 01:21:44 +01:00
bruvzg
9887c2b4f0
Improve thread IDs to avoid collisions with threads not created by the Godot API.
2021-03-07 00:17:20 +02:00
Ev1lbl0w
1f0b60c47d
Fix negative VRAM values
2021-03-05 21:48:20 +00:00
Alex Hirsch
6985967c3b
Add missing ERR_FAIL_INDEX check to Variant::construct
...
Other functions in the same file validate parameters using the ERR_FAIL
macros. This validation was missing for Variant::construct resulting in
a crash when called with invalid data (p_type < 0).
fix #46067
2021-03-04 18:50:37 +01:00
Rafał Mikrut
2cbdcb03a1
Don't allow to use in bit shift negative operands
2021-03-04 16:25:40 +01:00
Rémi Verschelde
614566ddb5
RemoteDebugger: Fix possible division by zero
2021-03-04 12:55:53 +01:00
Pedro Rodrigues
a3a731ed92
Fix crash on HTTPClient::poll method
...
The problem happened because `poll` assumed that when the SSL flag was
true, the `connection` would be a subclass of StreamPeerSSL. However
that invariant could be broken by calling HTTPClient::set_connection
with a `connection` that is not a subclass of StreamPeerSSL.
Fixes #46138
2021-03-03 21:00:30 +00:00
Rémi Verschelde
8fbe644b6e
Merge pull request #46423 from kleonc/color_from_hsv_fix
...
Make Color::from_hsv use Color::set_hsv
2021-03-01 19:37:58 +01:00
bruvzg
76b653528d
JSON parser: add UTF-16 surrogate pairs support.
2021-03-01 13:23:12 +02:00
Mateo Kuruk Miccino
89283b7b53
Logger: Cache 'flush_stdout_on_print' to improve performance, and works before ProjectSettings starts.
...
ProjectSetting: Now 'application/run/flush_stdout_on_print' requires a restart of the Editor to take effect
2021-02-28 19:36:10 -03:00
Mateo Kuruk Miccino
472673b38d
ResourceLoader: Fix inverse 'if' on the cache mode
2021-02-27 21:53:27 -03:00
Fabio Alessandrelli
dfbeb5ae29
Fix thread_process_array when NO_THREADS.
2021-02-26 12:13:20 +01:00
Rémi Verschelde
94f78f276b
Merge pull request #45061 from razonixx/Add_warning_when_dir_is_inaccesible
...
Add descriptive error message when trying to access a dir fails
2021-02-25 22:39:59 +01:00
Rémi Verschelde
f3f6c62b14
Merge pull request #46424 from RandomShaper/fix_no_threads
...
Fix SafeNumeric::conditional_increment() for NO_THREADS
2021-02-25 22:31:32 +01:00
Carlos Cabello
edb8c11970
Add descriptive error message when trying to access a dir fails
2021-02-25 22:24:21 +01:00
Pedro J. Estébanez
b1edb69249
Fix SafeNumeric::conditional_increment() for NO_THREADS
2021-02-25 21:22:01 +01:00
Rémi Verschelde
6ef0538f18
Merge pull request #38929 from touilleMan/exit-status-on-godot-error
...
Fix Godot returned status code on unexpected error
2021-02-25 21:16:34 +01:00
kleonc
b59a06da25
Make Color::from_hsv use Color::set_hsv
2021-02-25 19:50:43 +01:00
Emmanuel Leblond
60d2c1fd47
Remove GDScript bindings for OS.get/set_exit_code, SceneTree.quit(<exit_code>) should be used instead
2021-02-25 18:34:50 +01:00
Emmanuel Leblond
0e4abcb77f
Fix Godot returned status code on unexpected error
2021-02-25 18:01:37 +01:00
Rémi Verschelde
5d8025ec66
Merge pull request #38844 from hbina/patch-5
...
Avoid copying vector in constructor of PathMD5
2021-02-25 17:49:47 +01:00
Hugo Locurcio
355803db1b
Improve the OS.get_environment()
/OS.set_environment()
documentation
2021-02-25 15:38:51 +01:00
Rémi Verschelde
ba048b8b6e
Merge pull request #46414 from RandomShaper/fix_thread_self_join
...
Prevent thread wait on itself for finish
2021-02-25 14:27:20 +01:00
Bastiaan Olij
4c8f5b998f
Expose set_environment to GDScript
2021-02-25 23:36:14 +11:00
Pedro J. Estébanez
afc5af8dfa
Prevent thread wait on itself for finish
2021-02-25 13:16:27 +01:00
Rémi Verschelde
c0614bc059
Merge pull request #46401 from kleonc/geometry2d_make_atlas_crash_fix
...
Geometry2D::make_atlas Fail is passed invalid rect size
2021-02-25 07:18:39 +01:00
kleonc
988f4cdc90
Geometry2D::make_atlas Fail is passed invalid rect size
2021-02-24 23:38:30 +01:00
Rafał Mikrut
bb6ece1450
Change CRASH_COND to ERR_FAIL in Cowdata::set
2021-02-24 21:36:08 +01:00
abaire
61cc1c8624
Relaxes Node naming constraints in glTF documents to match the Editor.
2021-02-24 08:22:27 -08:00
Rémi Verschelde
65305ea001
Merge pull request #46371 from EricEzaM/PR/fix-osx-inputmap-spammed-errors
...
Fixed 'nonexistent action' errors spammed at startup on OSX
2021-02-24 16:52:52 +01:00
Eric M
d91e915d79
Fixed 'nonexistent action' errors spammed at startup on OSX
2021-02-24 23:16:22 +10:00
Liz Haas
2aee71d52d
Input: Throw error if action doesn't exist
...
Thow errors if requesting an unexisting InputMap action.
Makes `Input.is_action_*` methods consistents with `Event.is_action_*` which already throw errors.
fixes #33303
2021-02-24 13:49:21 +01:00
Rémi Verschelde
049d654c49
Merge pull request #46354 from reduz/importer-defaults-editor
...
Added Import Defaults Editor in Project Settings
2021-02-24 13:19:05 +01:00
Rémi Verschelde
5a10f52ee8
Merge pull request #45914 from HenryWConklin/45841-xml-entities
...
Add support for numeric XML entities to XMLParser
2021-02-24 13:03:46 +01:00
Rémi Verschelde
19bfbcfec2
Merge pull request #46195 from AndyBarcia/FixLanguageCodesIncosistencies
...
Fix some inconsistent ISO-639 language codes
2021-02-24 11:52:08 +01:00
reduz
b6fce5d750
Added Import Defaults Editor in Project Settings
...
-Change importer defaults in project settings.
-Ability to change them or reset them.
2021-02-23 14:18:02 -03:00
George Marques
f1088e1b70
Bind ClockDirection enum
...
It's the only enum in math_defs.h not bound, and it's used by Plane.
2021-02-23 13:56:28 -03:00
Rémi Verschelde
e254715e79
Merge pull request #46316 from akien-mga/input-ui_redo-swap-order
...
Input: Swap events for ui_redo to favor Shift+Ctrl+Z over Ctrl+Y
2021-02-23 08:10:37 +01:00
Delf Neumärker
f054f760e6
Fix unchecked array access in build_*_planes
2021-02-22 16:32:51 +01:00
Rémi Verschelde
12cc660d7d
Input: Swap events for ui_redo to favor Shift+Ctrl+Z over Ctrl+Y
...
That's the most common one we've been using for the general editor, and while the script editor
also supports Ctrl+Y, it should have lower priority.
In theory this code should make both be supported the same but for some reason the general editor
only seems to use the first entry (the script editor does support both).
2021-02-22 15:04:09 +01:00
Rémi Verschelde
efddb8a0cb
Merge pull request #46194 from Calinou/os-delay-no-negative
...
Don't allow negative values for `OS.delay_usec()`/`OS.delay_msec()`
2021-02-19 15:14:36 +01:00
Rémi Verschelde
0d1d719178
doc: Sync classref with current source
...
And fix various bogus bindings following previous PRs.
2021-02-19 14:39:14 +01:00
Pedro J. Estébanez
e3ec31f999
Improve robustness of atomics
...
And fix increment in `CowData` not being conditional anymore after the recent changes.
Co-authored-by: Hein-Pieter van Braam-Stewart <hp@tmm.cx>
2021-02-19 03:05:56 +01:00