Commit Graph

529 Commits

Author SHA1 Message Date
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 0a8d5d7098 Bump version to 3.6-beta 2022-08-05 18:51:38 +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
David Snopek 8ad5889c1a Add NetworkedMultiplayerCustom so high-level multiplayer backends can be added from GDScript 2022-07-19 09:16:41 -05:00
Rémi Verschelde 4455b6c4a8 GDNative: Expose `String::num_uint64`, and use bool in `capitalized` versions
Exposed in Core API 1.3 added in 3.5.
2022-07-18 09:47:30 +02:00
Rémi Verschelde 99a923ce9e
Merge pull request #63116 from kdiduk/gdnative-dictionary-merge
[GDNative] Expose `Dictionary::merge()` over to GDNative CORE API v1.3
2022-07-17 19:37:34 +02:00
Kirill Diduk b5483a6aad [GDNative] Expose `Dictionary::merge()` over to GDNative CORE API v1.3 2022-07-17 19:12:51 +02:00
Jan Haller e69a0394d4 GDNative: fix StringName equal and less operators 2022-07-17 11:17:35 +02: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
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
bruvzg a8eb779ac3
Backport locale selection improvements. 2022-07-04 11:49:20 +03:00
Rémi Verschelde ef29a227bf
Merge pull request #55826 from kdiduk/gdnative-poolstringarray-join 2022-07-03 01:05:03 +02:00
Fabio Alessandrelli a77d514ec0 [GDNative] Fix GDN_EXPORT define with mingw.
The define is **not used by godot**, but in GDNative libraries.

I'm not sure it should be defined there in the first place, though we
shouldn't change that (for compatibility).

This commit changes the platform detection order to detect mingw
compiling for windows (which defines `__GNUC__`).

This commit also wraps the definition around a guard to let libraries
override it with a build-time define.
2022-06-18 13:03:06 +02:00
smix8 8bd7c6188b [3.5] Update NavigationServer backport
Backports features and bugfixes from current Godot 4.0 to 3.5 and brings functions and codebase of both version largely in sync to make tutorials more compatible and future backports easier.
2022-06-14 05:55:14 +02:00
Kirill Diduk bf60d655e2 [GDNative] Add missing declaration of `join` method for PoolStringArray class
The class PoolStringArray in GDScript has `join` method, and it even has documentation.
However, the corresponding definition of this method in GDNative headers were missing.

In this commit, the missing GDNative definition of `join` method has been added.
A new CORE API version 1.3 has been added with the new metod `join`.
2022-06-08 14:58:54 +02:00
Rémi Verschelde 80b82e4e66 i18n: Misc fixes translation strings
Adds some translator comments to solve some questions raised on Weblate.
2022-06-08 12:56:42 +02:00
Haoyu Qiu 067e738cb8 Fix various typos 2022-05-19 19:07:45 +08:00
Hugo Locurcio b087538119
Add an XML schema for documentation
This makes it easier to spot syntax errors when editing the
class reference. The schema is referenced locally so validation
can still work offline.

Each class XML's schema conformance is also checked on GitHub Actions.
2022-03-16 23:01:02 +01:00
Rémi Verschelde 7a16bb2ee4
Fix typos with codespell
Using codespell 2.2-dev from current git.

Added `misc/scripts/codespell.sh` to make it easier to run it once in a
while and update the skip and ignore lists.

(cherry picked from commit 1bdb82c64e)
2022-02-11 09:50:59 +01:00
Max Hilbrunner 6cecb2210e Fix GDNative docs links 2022-01-24 11:29:20 +01:00
Rémi Verschelde c938104a88
Merge pull request #56630 from Pineapple/replace-find-last 2022-01-18 16:36:52 +01:00
Marcel Admiraal 949ea2b326 Simplify InputDefault::joy_axis code by using float instead of struct JoyAxis 2022-01-14 15:36:35 +00:00
Rémi Verschelde a627cdafc5
Update copyright statements to 2022
Happy new year to the wonderful Godot community!
2022-01-13 15:54:13 +01:00
Bartłomiej T. Listwon 22750b1c03 Replace String::find_last with rfind where possible (backward compatible with old API) 2022-01-08 22:40:44 +01:00
Max Hilbrunner 717801c9cb Fix docs links in 3.x after docs reorg 2022-01-05 11:54:52 +01:00
Rémi Verschelde 796f875870
Revert "Expose Variant operator= to GDNative" 2021-12-02 11:45:11 +01:00
Rémi Verschelde e154ce78cb
Merge pull request #54508 from BimDav/variant_operator_assign_gdnative 2021-12-01 17:08:39 +01:00
Aaron Franke 1d8cef8236
[3.x] Backport some APIs in math structs 2021-11-27 01:19:45 -06:00
Marcel Admiraal 4d3690eba5 Remove unimplemented methods 2021-11-18 12:47:36 +00:00
Rémi Verschelde 3ac2999f22
Replace Godot docs URL with `$DOCS_URL` in XML class reference 2021-11-15 17:22:47 +01:00
Rémi Verschelde 14c366ddd7
Bump version to 3.5-beta 2021-11-05 16:10:17 +01:00
BimDav 084b21c4a8 expose Variant operator= to GDNative 2021-11-02 12:11:27 +01: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 c7eb3d25e7
doc: Fix style inconsistencies for `[b]Note:[/b]` paragraphs
(cherry picked from commit 788b3aa27a)
2021-10-06 09:29:32 +02:00
Gergely Kis 1583c89a45 Fix GDNativeLibrary::get_current_library_path()
Return a const String reference to make sure that when its address
is used as a handle in NativeScriptLanguage::init_library(),
it refers to the heap instead of a temporary object on the stack.
2021-10-03 08:24:49 +02:00
Rémi Verschelde f0b37b1519
doc: Point URLs to 3.4 version of the online docs 2021-08-12 17:08:10 +02:00
Rémi Verschelde a418d09617
Merge pull request #51166 from RandomShaper/fix_can_reset_3.x 2021-08-09 09:19:25 +02:00
Rémi Verschelde f5836b40d4
doc: Use self-closing tags for `return` and `argument`
For the time being we don't support writing a description for those, preferring
having all details in the method's description.

Using self-closing tags saves half the lines, and prevents contributors from
thinking that they should write the argument or return documentation there.

(cherry picked from commit 7adf4cc9b5)
2021-08-03 10:20:19 +02:00
Pedro J. Estébanez d272464e6e Implement inherits_script() for NativeScript and PluginScript
(cherry picked from commit 2dcd064056)
2021-08-02 17:58:04 +02:00
Pedro J. Estébanez 7426b3fa91 Add Script::inherits_script()
Partial cherry-pick of 5d4dc2d45c.

Co-authored-by: Juan Linietsky <reduzio@gmail.com>
2021-08-02 15:18:30 +02:00
David Snopek a27f4de2ef Update GDNative API version for changes from #50659 2021-07-21 10:30:31 -05:00
David Snopek 5b2dcc5f6b Add get_buffered_amount() to WebRTCDataChannel 2021-07-20 16:52:33 -05:00
Rémi Verschelde 9a04e2afeb
Revert "Fix gdnative api generation for methods that return enums"
This reverts commit aaacc753a7.
2021-07-13 17:02:59 +02:00
Ranie Jade Ramiso aaacc753a7
Fix gdnative api generation for methods that return enums
(cherry picked from commit 78f55698f2)
2021-07-06 13:36:07 +02:00
Marcel Admiraal 5a58516231 Remove duplicate ERR_PRINTS macro 2021-06-16 11:56:25 +01:00
Paweł Fertyk 6e67b7a93e
Check for _language in PluginScript.instance_has
(cherry picked from commit 4b25892501)
2021-06-01 12:53:31 +02:00
Hugo Locurcio a38b447413
Highlight control flow keywords with a different color
This makes them easier to distinguish from other keywords.
2021-05-25 00:31:39 +02:00