Commit graph

3731 commits

Author SHA1 Message Date
Pedro J. Estébanez
89892e4f32 Determine ProjectSettings' resource path early 2022-08-26 15:09:19 +02:00
Haoyu Qiu
2d93718cd2 Add clear method to pool arrays 2022-08-10 17:31:29 +08:00
Rémi Verschelde
8cec1c63c2
Merge pull request #63629 from dsnopek/fix-locale-remap-with-binary-resources-3.x
[3.x] Fix locale resource remapping with binary conversion on export
2022-08-08 20:03:56 +02:00
David Snopek
0cf4ba0d84 Fix locale resource remapping with binary conversion on export 2022-08-08 09:38:39 -05:00
Rémi Verschelde
6eee83579a
Merge pull request #64101 from timothyqiu/subsecond 2022-08-08 16:31:49 +02:00
Rémi Verschelde
7dc8ec0c61
Merge pull request #63643 from aaronfranke/3.x-mouse-mode-ch 2022-08-08 14:36:45 +02:00
Haoyu Qiu
1be078ebcb Fix Time.get_unix_time_from_system() not including msecs 2022-08-08 20:31:51 +08:00
Fabio Alessandrelli
ee5eb943f7 [File] Fix FileAccessCompressed::get_buffer return value.
It used to return the write index instead of the written bytes (i.e.
index + 1) when reading until last block.

(cherry picked from commit e8f7b79bb0)
2022-08-08 09:50:41 +02:00
Rémi Verschelde
0bed7ea63f
Merge pull request #61316 from bruvzg/tts_3x
[3.x] Backport text-to-speech support.
2022-08-05 23:45:51 +02:00
Rémi Verschelde
0dccbcd7ce
Merge pull request #61878 from bruvzg/backport_locale_select
[3.x] Backport locale selection improvements.
2022-08-05 23:45:17 +02:00
Rémi Verschelde
14c9325b5d
Merge pull request #62408 from Razoric480/raz/fix-no-cache
[3.x] Fix nested resources being cached if no-cache argument used
2022-08-05 23:43:54 +02:00
Rémi Verschelde
daa5b542b4
Merge pull request #56765 from madmiraal/fix-45592-2-3.x
[3.x] Fix mouse speed not changing fast enough
2022-08-05 22:37:44 +02:00
Rémi Verschelde
26762a71b6
Merge pull request #58537 from winterpixelgames/feature/virtual-keyboard-types-3.x 2022-08-05 19:37:13 +02:00
Fabio Alessandrelli
4e33610fb0 [Core] Use std type traits to check operations triviality.
(cherry picked from commit 6f02183f8c)
2022-08-04 15:20:28 +02:00
Rémi Verschelde
751b16a285 File: Re-add support to skip CR (\r) in File::get_as_text
This was removed in #63481, and we confirmed that it's better like this,
but we add back the possibility to strip CR as an option, to optionally
restore the previous behavior.

For performance this is done directly in `String::parse_utf8`.

Also fixes Android `FileAccess::get_line()` as this one _should_ strip CR.

Supersedes #63717.

(cherry picked from commit 1418f97c70)
2022-08-01 00:40:55 +02:00
David Snopek
5eaf83f2d7 Add error messages and docs to explain restrictions when calling NetworkedMultiplayerCustom.initialize() 2022-07-29 13:51:44 -05:00
Aaron Franke
0d6e2d1090
Add MOUSE_MODE_CONFINED_HIDDEN to MouseMode enum 2022-07-29 13:46:04 -05:00
David Snopek
738e76b710 Add error messages and docs to explain allowed transitions in NetworkedMultiplayerCustom.set_connection_status() 2022-07-29 09:02:53 -05:00
pattlebass
fb7ecc748f [3.x] HTML5: Add support for Input.vibrate_handheld() 2022-07-28 13:20:05 +03:00
Rémi Verschelde
6c8d9b8401
Merge pull request #63480 from m4gr3d/fix_remaining_scoped_storage_regressions_3x
[3.x] Address remaining scoped storage regressions
2022-07-26 18:15:14 +02:00
Fredia Huya-Kouadio
fc2c202312 Address remaining scoped storage regressions
- Accelerate common path used to check the storage scope for a given path
- Update the logic for the `get_as_text()` method - previous logic loads the content of a text file one byte at a time
2022-07-26 07:42:49 -07:00
Ricardo Buring
90725964a4 Fixup BVH debugging statements 2022-07-25 18:35:14 +02:00
Rémi Verschelde
818f1eed31 Code quality: Fix header guards consistency
Adds `header_guards.sh` bash script, used in CI to validate future
changes. Can be run locally to fix invalid header guards.
2022-07-25 14:53:37 +02:00
Rémi Verschelde
c8099e9524
Merge pull request #63223 from m4gr3d/fix_slow_copy_3x
[3.x] Address slow copy performance when using the `FileAccessFilesystemJAndroid` implementation
2022-07-22 00:21:59 +02:00
Fredia Huya-Kouadio
aab26ad7d2 Address slow copy performance when using the FileAccessFilesystemJAndroid implementation.
Read/write ops for this implementation are done through the java layer via jni, and so for good performance, it's key to avoid numerous repeated small read/write ops due the jni overhead.

The alternative is to allocate a (conversatively-sized) large buffer to reduce the number of read/write ops over the jni boundary.
2022-07-21 08:21:12 -07:00
Rémi Verschelde
4ef99b409d
Merge pull request #63163 from dsnopek/multiplayer-peer-custom-3.x 2022-07-20 22:41:15 +02:00
fabriceci
43e9816fb1 Fix the calculation of the angular velocity when the rotation speed is not high.
(cherry picked from commit db7c91e0ad)
2022-07-19 17:16:21 +02:00
Pedro J. Estébanez
4e1f30390d Use the right memory ordering in SafeNumeric operations
(cherry picked from commit 02a584d8e6)
2022-07-19 17:10:26 +02:00
David Snopek
8ad5889c1a Add NetworkedMultiplayerCustom so high-level multiplayer backends can be added from GDScript 2022-07-19 09:16:41 -05:00
Aaron Franke
f60cc50667
[3.x] Add forwards-compatible aliases for pool/packed arrays 2022-07-18 12:37:15 -05:00
Kirill Diduk
910c67b268 [GDNative] Expose String::join() to GDNative Core API v1.3 2022-07-16 16:31:32 +02:00
Kirill Diduk
2cd87ef226 [GDNative] Refactoring: add const to has and join methods of pooled arrays 2022-07-16 14:08:42 +02:00
Rémi Verschelde
101cbe5d5b
Merge pull request #62723 from hansemro/eraser-detect-3.x 2022-07-15 00:13:15 +02:00
Francois Belair
2ceb93bbef Fix custom res caching sub-res even if no-cache
Fixes #59686, fixes #59752
2022-07-13 11:18:26 -04:00
Kirill Diduk
7b8b91f505 [GDScript][GDNative] Add 'sort' and 'has' methods to pooled arrays
This is a backport from 4.0 to 3.x that adds 'sort' and 'has' methods
to the following types:
- PoolByteArray
- PoolIntArray
- PoolRealArray
- PoolStringArray
- PoolVector2Array
- PoolVector3Array
- PoolColorArray

For all the types above, the methods 'sort' and 'has' have been
exposed to the GDNative API (v. 1.3)

Since the method 'has' was already implemented in GDScript before,
in this commit it has been only exposed to GDNative API.

The classes documentation is updated.

The method 'sort' uses the exisging class "Sorter".

Pooled arrays in 4.0 are rewritten, that's why this backport is not
completely indentical to the original PR made for 4.0 (see #32144).
2022-07-07 23:24:31 +02:00
Brian Semrau
ce24b48e50 Add support for multiple virtual keyboard types 2022-07-07 14:22:28 -04:00
Rémi Verschelde
be85923dc5
Merge pull request #54083 from Rubonnek/add_bin_messages_3x 2022-07-05 23:04:15 +02:00
Wilson E. Alvarez
a97a016381
Add error messages to String::bin_to_int64, and accept capital B in prefix
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2022-07-05 11:59:21 -04:00
Wilson E. Alvarez
f12a1b6214
Add error messages String::hex_to_int functions, and accept capital X in prefix
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2022-07-05 10:16:55 -04:00
Hansem Ro
193d5c11f3 [3.x, macOS, Windows, X11] Add stylus inverted/eraser support to InputEventMouseMotion event 2022-07-04 16:12:11 -07:00
bruvzg
a8eb779ac3
Backport locale selection improvements. 2022-07-04 11:49:20 +03:00
Estelle Linkpy Reid
7a2d3b04a5 Corrected InputEventKey::as_text to return a non-empty string for physical keys. 2022-07-02 15:34:15 +02:00
bruvzg
6489fe890e
Backport text-to-speech support. 2022-07-01 11:04:50 +03:00
Rémi Verschelde
a7559fcb6e Errors: Fallback to fprintf if OS singleton doesn't exist
Otherwise we would crash if something prints an error before init or
after destruction of the `OS` singleton which handles printing/logging.

(cherry picked from commit c83084fccb)
2022-06-30 19:23:02 +02:00
Rémi Verschelde
d74ff8dd93
Merge pull request #62440 from timothyqiu/thread-func-base
[3.x] Check thread func in base scripts for argument info
2022-06-28 08:11:11 +02:00
Haoyu Qiu
f740b4f481 Check thread func in base scripts for argument info 2022-06-27 11:24:04 +08:00
ne0fhyk
24e3b3b88d Add full support for Android scoped storage.
This was done by refactoring directory and file access handling for the Android platform so that any general filesystem access type go through the Android layer.
This allows us to validate whether the access is unrestricted, or whether it falls under scoped storage and thus act appropriately.
2022-06-26 16:53:02 -07:00
Marcel Admiraal
b8b7c21583 Ensure AudioFrame variables l and r are always initialised
(cherry picked from commit d3f0994572)
2022-06-20 14:58:57 +02:00
Rémi Verschelde
acd4a01b8c ProjectSettings: Ensure 'editor/' settings aren't nested
Having a mix of settings with and without subcategory makes the 'Editor'
section stand out with a weird UX, as instead of simply being a foldable
section like the others, it also holds its own top-level settings and is
therefore selectable.

This wasn't the case in 3.4, and is fixed in 4.0 by refactoring, so for
3.5 we should preserve the 3.4 UX, even if it's not the best.
2022-06-19 11:47:19 +02:00
Theraot
6007d7f0ed Added missing p_bidirectional to AStar2D methods
The methods disconnect_points and are_points_connected  now have an optional p_bidirectional parameter matching AStar.

(cherry picked from commit 3590cdfd34)
2022-06-16 20:49:01 +02:00