Commit graph

246 commits

Author SHA1 Message Date
Samuel Nicholas
5f89b15098
Print correct path when unable to find GDExtension library 2024-03-26 00:13:56 +01:00
ppphp
d4e1a74efb Add 'override' mark to ResourceFormat class 2024-03-25 04:06:34 +08:00
A Thousand Ships
0c19d0f5a0
Add extension support for argument count to ScriptInstance 2024-03-13 22:40:09 +01:00
Rémi Verschelde
a1c476f9d7
Merge pull request #87680 from AThousandShips/the_angry_count
Add methods to get argument count of methods
2024-03-13 22:16:43 +01:00
Thaddeus Crews
5a6e3cbcb0
SCons: Remove run_in_subprocess dependency 2024-03-11 13:20:09 -05:00
Rémi Verschelde
810f127022
Merge pull request #89365 from Repiteo/scons/run_in_subprocess-to-env.Run
SCons: Convert remaining `run_in_subprocess` to `env.Run`
2024-03-10 21:13:22 +01:00
Thaddeus Crews
8116d70d4b
SCons: Convert remaining run_in_subprocess to env.Run 2024-03-10 14:01:23 -05:00
Thaddeus Crews
fb299d0fb1
SCons: Ensure with statement where applicable 2024-03-10 12:57:57 -05:00
A Thousand Ships
59bcc2888c
Add methods to get argument count of methods
Added to:
* `Callable`s
* `Object`s
* `ClassDB`
* `Script(Instance)`s
2024-03-10 11:02:43 +01:00
Thaddeus Crews
d9fa40f2df
Enforce \n eol for Python writes
• Ensure utf-8 encoding if previously unspecified
2024-03-09 14:29:24 -06:00
Rémi Verschelde
50ca190286
Merge pull request #89055 from dsnopek/gdextension-script-free-lists
GDExtension: Pass count when freeing method and property lists for script instances
2024-03-04 13:33:45 +01:00
David Snopek
0badf07657 GDExtension: Pass count when freeing method and property lists for script instances 2024-03-02 10:13:37 -06:00
Rémi Verschelde
3a08c646ee
Pre-commit: Update to clang-format 17.0.6 and black 24.2.0 2024-02-28 14:25:35 +01:00
Robert Yevdokimov
13e82094ee Remove word duplicates in comments and strings, and fix casing and punctuation 2024-02-23 17:28:28 -05:00
Rémi Verschelde
b652a81da7
Merge pull request #82554 from dsnopek/gdextension-placeholders
Allow registering "runtime classes" from GDExtension
2024-02-20 17:13:24 +01:00
David Snopek
ea75307a11 Allow registering "runtime classes" 2024-02-20 09:20:58 -06:00
Rémi Verschelde
e076405f30
GDExtension: Fix -Wtype-limits warning in compatibility_maximum patch check
And cleanup some dead code in `version.h`, we now always define `VERSION_PATCH`.
2024-02-19 01:19:30 +01:00
Rémi Verschelde
dc41f2504b
Merge pull request #88417 from dsnopek/gdextension-compatibility-maximum
Allow GDExtensions to set a `compatibility_maximum`
2024-02-19 00:08:14 +01:00
David Snopek
99fd6ca98c Unbind GDExtension methods that can't reasonably be used 2024-02-16 16:31:09 -06:00
David Snopek
2afa3557b4 Allow GDExtensions to set a compatibility_maximum 2024-02-16 16:02:55 -06:00
Muller-Castro
a8bc9f3e78 Add const lvalue ref to core/* container parameters 2024-02-14 11:20:36 -03:00
Rémi Verschelde
fd43a7f3be
Merge pull request #88188 from dsnopek/gdextension-api-double-compatibility-hashes
Fix `gdextension_compat_hashes.cpp` for double precision builds
2024-02-12 23:29:41 +01:00
Rémi Verschelde
306dd5be3f
Merge pull request #87758 from dsnopek/gdextension-register-virtual-method
Allow GDExtensions to register virtual methods and call them on scripts
2024-02-12 23:29:37 +01:00
David Snopek
be11002e41 Allow GDExtensions to register virtual methods and call them on scripts 2024-02-12 13:29:18 -06:00
David Snopek
445e3018f5 Fix gdextension_compat_hashes.cpp for double precision builds 2024-02-10 19:05:33 -06:00
Mikhail Tishin
dc4c6cfb9b Add null check for gdextension deinitialization 2024-02-04 18:38:59 +03:00
Riteo
f468e59efd GDExtension: add an interface for loading extra documentation
Adds two new GDExtension interface methods:
 - `editor_help_load_xml_from_utf8_chars`
 - `editor_help_load_xml_from_utf8_chars_and_len`

Both of these methods parse the XML passed into an extra documentation
container which, when needed, is merged into the main doc container.

Co-Authored-By: Rémi Verschelde <rverschelde@gmail.com>
2024-01-26 13:53:33 +01:00
Muller-Castro
96a95cb974 Add const lvalue ref to container parameters 2024-01-05 14:49:57 -03:00
Daylily-Zeleen
fe6b073811 Distinguishs between dynamic library not found and can't be opened. 2024-01-01 20:01:57 +08:00
Ricardo Buring
82afe58aca Fix operator documentation in GDExtension API dump with docs
The type of the right operand is now taken into account.
2023-12-12 18:55:31 +01:00
David Snopek
5cf6d08dda Check that GDExtensionCompatHashes are valid when generating extension_api.json 2023-11-16 06:40:06 -06:00
Rémi Verschelde
dfe2df989d
Merge pull request #84493 from bruvzg/gde_ios_static_fix
[iOS, GDExtension] Fix loading and exporting static libraries and xcframeworks.
2023-11-10 10:44:56 +01:00
bruvzg
d4d5d68eda
[iOS, GDExtension] Fix loading and exporting static libraries and xcframeworks. 2023-11-09 20:04:40 +02:00
David Snopek
09fcc3a1ad Change GDExtension's library_path back to an absolute path 2023-11-09 11:24:57 -06:00
David Snopek
f86054e3a0 GDExtension: Save and compare modification times separately for reload 2023-11-02 08:29:22 -05:00
Rémi Verschelde
f7c43a8a19
Merge pull request #83800 from dsnopek/gdextension-callable-custom-object-id
GDExtension: Use `ObjectID` when creating custom callable
2023-10-25 10:29:58 +02:00
David Snopek
b0a33cac7c GDExtension: Use ObjectID when creating custom callable 2023-10-23 09:05:17 -05:00
Mario Liebisch
f2bcd7d61f
GDExtension: Fixed error on loading extensions
Previously, before loading an extension, the editor just tried to
retrieve the extension by path to test if it's been loaded already.

While this is handled gracefully, it ignored an error thrown inside
`GDExtensionManager::get_extension()`, that would essentially still
report a not yet loaded extension to the engine's log:

```
ERROR: Condition "!E" is true. Returning: Ref<GDExtension>()
   at: GDExtensionManager::get_extension (core\extension\gdextension_manager.cpp:165)
```

This change actively checks whether the extension path is known and only
then proceeds to actually return the already loaded extension or loads
and returns the new one otherwise.
2023-10-21 17:00:18 +02:00
David Snopek
b14f359c94 GDExtension: Fix variant_iter_get() actually calling iter_next() 2023-10-20 10:07:46 -05:00
Yuri Sizov
582ed157b5 Fix StringName leaks in GDExtension, core, and editor themes 2023-10-18 17:36:20 +02:00
Emmanuel Leblond
fd33c7b32f
Merge pull request #83415 from touilleMan/fix-comment-gdextension_interface
Fix comment in `gdextension_interface.h`
2023-10-16 21:42:01 +02:00
Emmanuel Leblond
5aa9f1ce64
Fix comment in gdextension_interface.h 2023-10-16 21:40:45 +02:00
Rémi Verschelde
eb9903b4ce
Merge pull request #83285 from dsnopek/gdextension-double-reload
GDExtension: Prevent issues with the editor trying to reload GDExtensions through its usual mechanism
2023-10-16 18:44:51 +02:00
Ricardo Buring
c87b2a606e Add brief description in GDExtension API dump with docs
Also rename the "documentation" key to "description" for internal
consistency.
2023-10-14 12:06:37 +02:00
David Snopek
16a86b9604 GDExtension: Prevent issues with the editor trying to reload GDExtensions through its usual mechanism 2023-10-13 13:24:29 -05:00
Rémi Verschelde
b40d90d333
Merge pull request #83107 from dsnopek/validated-method-vararg-message
GDExtension: Fix incorrect error message about vararg methods
2023-10-10 22:51:41 +02:00
David Snopek
87cb0bfa50 GDExtension: Fix incorrect error message about vararg methods 2023-10-10 08:46:25 -05:00
David Snopek
88b6fee547 GDExtension: Use correct return pointer for validated calls that return Variant 2023-10-10 08:31:08 -05:00
A Thousand Ships
f18aa00e85 Replace ERR_FAIL_COND with ERR_FAIL_NULL where applicable 2023-10-08 17:23:33 +02:00
Rémi Verschelde
a6a2d0d159
Merge pull request #82794 from dsnopek/gdextension-validated-call
GDExtension: Convert `validated_call()` to `ptrcall()` (rather than `call()`)
2023-10-06 16:50:57 +02:00