Commit graph

2761 commits

Author SHA1 Message Date
Yuri Sizov
0e1c9531b5 Merge pull request #75620 from jpcerrone/fix_shadow_warnings_not_going_away_after_ignoring
Fix for not being able to ignore shadowing warnings on class scope
2023-07-25 21:25:45 +02:00
jpcerrone
13c73500ab Fix for not being able to ignore shadowing warnings on class scope 2023-07-24 17:22:12 -03:00
Yuri Sizov
74d20fe17e Merge pull request #75216 from rune-scape/rune-dependancy-errors
Script editor (GDScript): Show depended script errors
2023-07-24 19:32:20 +02:00
Yuri Sizov
2bd904e3db Merge pull request #73196 from Vilcrow/fix-lookup-symbol
Fix jumping to function definition using `Ctrl+LMB` or the "Lookup Symbol" button
2023-07-24 19:32:12 +02:00
rune-scape
83b01708b2 Script editor: Show depended script errors 2023-07-24 15:49:39 +02:00
Yuri Sizov
de0f7935dd Merge pull request #79524 from aaronfranke/gds-test-inst-placeholder
Change GDScript tests to use InstancePlaceholder as the example abstract class
2023-07-21 17:15:32 +02:00
Fredia Huya-Kouadio
d17811c814 Re-architect how Android plugins are packaged and handled at export time
The previous packaging format for Godot Android plugins consisted of the plugin's `gdap` config file accompanied by binaries defined in the `gdap` file.
This format is now deprecated (starting with Godot 4.2), and instead Godot Android plugins are now packaged as `EditorExportPlugin` plugins.

The `EditorExportPlugin` class has been updated with the following methods to provide the necessary set of functionality:
- `_supports_platform`: returns true if the plugin supports the given platform
- `_get_android_dependencies`: retrieve the set of android dependencies (e.g: `org.godot.example:my-plugin:0.0.0`) provided by the plugin
- `_get_android_dependencies_maven_repos`: retrieve the urls of the maven repos for the provided android dependencies
- `_get_android_libraries`: retrieve the local paths of the android libraries (AAR files) provided by the plugin
- `_get_android_manifest_activity_element_contents`: update the contents of the `<activity>` element in the generated Android manifest
- `_get_android_manifest_application_element_contents`: update the contents of the `<application>` element in the generated Android manifest
- `_get_android_manifest_element_contents`: update the contents of the `<manifest>` element in the generated Android manifest
2023-07-18 19:14:53 +02:00
Yuri Sizov
2c55214068
Merge pull request #79205 from anvilfolk/populate-class-members
GDScript: Solve `_populate_class_members()` cyclic dependency problem
2023-07-17 19:15:16 +02:00
Aaron Franke
6a8a9cd279
Change GDScript tests to use InstancePlaceholder as the example abstract 2023-07-15 18:28:08 -05:00
Yuri Sizov
d5a30f7af8 Merge pull request #79163 from anvilfolk/fullscripterror
GDScript: Add static analysis error reporting in GDScriptCache::get_full_script()
2023-07-14 18:49:32 +02:00
S.V.I. Vilcrow
56e2fad319 Fixed the jumping to function definition using 'Ctrl+LMB' and the 'Lookup Symbol' button. 2023-07-12 21:30:35 +03:00
George Marques
cbfe2b61b6
GDScript: Properly track extents of constants and patterns
Even in the case of errors.
2023-07-12 10:57:11 -03:00
Rémi Verschelde
8a06ec979e
Change explicit 'Godot 4.0' references to 'Godot 4'
Fixes #79276.
2023-07-10 13:08:11 +02:00
ocean (they/them)
7d29ac0bf2 GDScript: solve _populate_class_members() cyclic dependency problem 2023-07-08 15:34:20 -04:00
ocean (they/them)
955049670f GDScript: Add static analysis error reporting in GDScriptCache::get_full_script() 2023-07-07 11:16:22 -04:00
Rémi Verschelde
69dbbcc313
Merge pull request #79092 from akien-mga/doctool-remove-version-attribute
Doctool: Remove version attribute from XML header
2023-07-07 08:34:55 +02:00
Rémi Verschelde
b3c2b52025
Merge pull request #78953 from anvilfolk/enum-desc
Fix regression with GDScript enum descriptions now showing up in documentation.
2023-07-07 08:31:44 +02:00
Rémi Verschelde
81064cc239
Doctool: Remove version attribute from XML header
We don't use that info for anything, and it generates unnecessary diffs
every time we bump the minor version (and CI failures if we forget to
sync some files from opt-in modules (mono, text_server_fb).
2023-07-06 10:08:21 +02:00
Rémi Verschelde
346f1ab86b
Bump version to 4.2-dev
Keep on waitin'
2023-07-05 22:07:03 +02:00
ocean (they/them)
d48636c3bf Fix regression with enum descriptions now showing up in documentation. 2023-07-02 11:29:52 -04:00
Gilles Roudière
538c4b62b7 Explain a bit more RPCs options 2023-06-27 11:25:15 +02:00
Rémi Verschelde
af16013905
Merge pull request #78571 from MewPurPur/include-extension-info
Document file extensions of GDScript, CSharpScript, and Shader
2023-06-22 18:32:25 +02:00
MewPurPur
8848c395b6 Add information about file extension to GDScript, CSharpScript, and Shader 2023-06-22 18:56:08 +02:00
Danil Alexeev
84c8946565
GDScript: Remove unnecessary name check in _get_property_list() 2023-06-22 12:41:44 +03:00
Rémi Verschelde
f2ce0b6741
Merge pull request #78521 from jpcerrone/fix_static_vars_refs
Fix errors destroying script with static variables
2023-06-21 21:52:15 +02:00
Rémi Verschelde
faf3faa8c8
Merge pull request #77744 from dalexeev/gds-reset-block-locals-on-exit
GDScript: Reset local variables on exit from block
2023-06-21 21:51:05 +02:00
ocean (they/them)
6c28b8edd3 GDScript: fix regression when checking for virtual function implementation.
Unfortunately it appears the virtual function checks in #77324 are not
trustworthy at runtime, because objects can have scripts attached, but
this information is not always available at compile-time. These checks
need to be removed.

The rest of the PR is still useful, making all method flags available to
the analyzer, so a full revert isn't necessary/desirable.

This reopens #76938, which will need another solution.
2023-06-21 15:13:45 -04:00
jpcerrone
8ce8216d17 Fix errors destroying script with static variables
Fixes #78376
After #78138 'script_list' is now cleared in 'GDScriptLanguage::finish'
Because of that, we can safely remove the removal from that list that
happens on 'GDScript::~GDScript'.
2023-06-21 12:33:21 -03:00
今井きなみ
bf04c55175 Fix lambda parsing continuing on subsequent lines #73273 2023-06-21 12:56:57 +02:00
Yuri Sizov
f1e79e2581 Make container element type comparison safe 2023-06-20 17:04:57 +02:00
Rémi Verschelde
248e5245e4
Merge pull request #73540 from mashumafi/fix-typed-array-add
Fix: Typed arrays aren't working with +
2023-06-20 15:12:39 +02:00
Danil Alexeev
a0577eb23b
GDScript: Fix _get_script_name() function collision for SCU build 2023-06-20 12:03:54 +03:00
Danil Alexeev
5d3f5e8cf2
GDScript: Fix crash in disassembler 2023-06-19 23:50:33 +03:00
Rémi Verschelde
c211c22abc
Merge pull request #78389 from rune-scape/rune-match-stringnames
GDScript: Strings and StringNames match
2023-06-19 21:18:42 +02:00
Rémi Verschelde
ae00187b58
Merge pull request #77129 from dalexeev/gds-fix-static-var-bugs-part-1
GDScript: Fix some bugs with static variables and functions
2023-06-19 21:18:18 +02:00
Rémi Verschelde
5f9175f969
Merge pull request #76954 from Rindbee/return-null-on-fail-load-script
Returns null and does not cache when the source code of the script fails to load
2023-06-19 21:17:47 +02:00
Rémi Verschelde
cfae05094a
Merge pull request #72824 from dalexeev/gds-invalid-char-error
GDScript: Fix invalid character error message
2023-06-19 15:39:58 +02:00
Ben
0803467334
Fix "Go to definition" for GDScript type hints
Fixes #68475.
2023-06-19 15:29:25 +02:00
Fabio Alessandrelli
116f783db7
Merge pull request #76207 from dalexeev/clarify-rpc-docs
Clarify `@rpc` annotation arguments docs
2023-06-18 21:34:34 +02:00
Rémi Verschelde
fcc39d498b
Merge pull request #75051 from AleryBerry/fix-error-message-lua-style
GDScript: Fix error message for LUA-style dictionary
2023-06-18 16:28:36 +02:00
Rémi Verschelde
1a62f1e4fc
Merge pull request #74741 from vnen/variant-not-for-everyone
Allow boolean operators for all Variant types
2023-06-18 16:28:10 +02:00
Rémi Verschelde
4db1d09bf5
Merge pull request #73657 from mashumafi/callable-ctor
Fix: Get constructor as Callable
2023-06-18 16:27:42 +02:00
Rémi Verschelde
1ce2425c0e
Merge pull request #73363 from dalexeev/gds-fix-min-int-not-representable
GDScript: Fix `MIN_INT` not representable as numeric literal
2023-06-18 16:27:16 +02:00
Rémi Verschelde
11ee6fcef0
Merge pull request #68311 from RobertMasek/fix-go-to-definition
Fix functionality of Go To Definition for properties set/get
2023-06-18 16:26:42 +02:00
Danil Alexeev
aebbbda080
GDScript: Fix some bugs with static variables and functions 2023-06-16 22:52:11 +03:00
Rémi Verschelde
49b774e009
Merge pull request #77324 from anvilfolk/oh-no-its-virtual
GDScript: add errors when calling unimplemented virtual functions
2023-06-15 15:26:18 +02:00
Rémi Verschelde
3b4504afea
Merge pull request #75944 from akien-mga/style-modules-includes
Style: Harmonize header includes in modules
2023-06-15 15:26:14 +02:00
Rémi Verschelde
12e8bc558d
Merge pull request #73203 from dalexeev/gds-fix-num-literal
GDScript: Fix repeated `_` are allowed after decimal point
2023-06-15 15:26:09 +02:00
Rindbee
cbce374f68 Returns null and does not cache when the source code of the script fails to load
This usually means that an `ERR_FILE*` error occurred.

Previously, using `GDScriptCache::get_full_script()` would ignore errors during loading.
Now, all errors are not ignored.

Judging in which period the error occurred, it can be judged based on the return value:
1. null + err : Error during script loading (load_source_code()).
2. script + err: Error during script parsing.
2023-06-15 21:06:10 +08:00
Rémi Verschelde
25b2f1780a
Style: Harmonize header includes in modules
This applies our existing style guide, and adds a new rule to that style
guide for modular components such as platform ports and modules:

Includes from the platform port or module ("local" includes) should be listed
first in their own block using relative paths, before Godot's "core" includes
which use "absolute" (project folder relative) paths, and finally thirdparty
includes.

Includes in `#ifdef`s come after their relevant section, i.e. the overall
structure is:

- Local includes
  * Conditional local includes
- Core includes
  * Conditional core includes
- Thirdparty includes
  * Conditional thirdparty includes
2023-06-15 14:35:45 +02:00