summaryrefslogtreecommitdiff
path: root/core/object
AgeCommit message (Collapse)Author
2022-11-06Fix default values not showing up on virtual classesAaron Franke
2022-11-05Don't allow instancing virtual node types in the Create New Node dialogAaron Franke
2022-11-02Merge pull request #67693 from Mickeon/slight-hint-shufflingRémi Verschelde
Fix unordered values of PROPERTY_HINT_INT_IS_POINTER & ARRAY_TYPE
2022-10-31Merge pull request #67578 from KoBeWi/GEDITORRémi Verschelde
Unify usage of GLOBAL/EDITOR_GET
2022-10-21Fix unordered values of PROPERTY_HINT_INT_IS_POINTER & ARRAY_TYPEMicky
2022-10-18Unify usage of GLOBAL/EDITOR_GETkobewi
2022-10-18Minor code improvementskobewi
2022-10-16GDExtension: add support for abstract and virtual classesRicardo Buring
2022-10-13Merge pull request #66427 from Mickeon/object-methods-autocompletionRémi Verschelde
Add autocompletion to several Object methods
2022-10-12Merge pull request #67300 from Mickeon/indexed-objectionRémi Verschelde
Rename `set`/`get_indexed`'s "property" to "property_path"
2022-10-12Rename `set`/`get_indexed`'s "property" to "property_path"Micky
Also touches up the Documentation slightly.
2022-10-12Fix _unnamed_arg so that arguments defined by GDExtension show up in docs.Quentin Quaadgras
The Godot API (gdnative_interface.h) allows methods to be registered on extension classes with `classdb_register_extension_class_method` a `GDNativeExtensionClassMethodInfo` can be provided to this function along with a `get_argument_info_func` which according to the comment indicates that argument names should be definable here. Unfortunately, setting the name field in the `GDNativePropertyInfo` struct has no effect on the editor documentation, which continues to display "_unnamed_arg" for each argument. I discovered that `get_argument_info` is responsible for this as it always overrides the `info.name`. I've added an if condition that will only override the name when it is empty. I've tested this with my GDExtension module and I can confirm that with this commit, the argument name shows up in the builtin docs. eg. in Lookup Symbol.
2022-10-11Implement ScriptExtension::get_documentationEmmanuel Leblond
2022-10-10SCons: Re-enable treating `#warning` as error with `werror`Rémi Verschelde
Replace all TODO uses of `#warning` by proper TODO comments, and will open matching bug reports to keep track of them. We don't have a great track record fixing TODOs, but I'd wager we're even worse for fixing these "TODO #warning" so we should prohibit this usage.
2022-10-10SCons: Cleanup GCC warnings configurationRémi Verschelde
- Outright disable spammy warnings due to past or present GCC bugs: * `-Wno-strict-overflow` for GCC 7. * `-Wno-type-limits` for GCC before 11 (regressed in 9/10, might work in earlier releases but at this stage we don't care). * `-Wno-return-type` for GCC 12/13 (regression, still not fixed). - Enable extra warnings conditionally when broken on earlier GCC: * `-Wnoexcept` was removed due to an upstream regression in GCC 9, could be re-enabled (but commented out for now as we actually have `-Wnoexcept` warnings to fix. * `-Wlogical-op` was broken on our variadic templates before GCC 11, now seems fine.
2022-10-08Validate input in `ScriptServer::register_language`Haoyu Qiu
2022-10-07Fix MSVC warnings, rename shadowed variables, fix uninitialized values, ↵bruvzg
change warnings=all to use /W4.
2022-10-05free NativeExtensionMethodBinds on unregisterWaridley
2022-10-05Merge pull request #66839 from aaronfranke/editor-prop-hide-sliderRémi Verschelde
Fix `hide_slider` vs `no_slider` inconsistency in editor property code
2022-10-03Fix hide_slider vs no_slider inconsistency in editor property codeAaron Franke
2022-10-03Remove unsupported `NO_SAFE_CAST`/`-fno-rtti` from Android buildRémi Verschelde
Android was the last platform to still attempt to disable RTTI (for binary size), but both the Android editor and now the ICU library used by templates need RTTI. There could still be the possibility to support this for non-ICU template builds (i.e. without the TextServerAdvanced module), but since this isn't one of the build configurations we test regularly it's pretty risky to keep this option only for that specific use case. And our code is already littered with `dynamic_cast`s which weren't guarded with `!defined(NO_SAFE_CAST)`.
2022-09-30Fix typos with codespellRémi Verschelde
Using codespell 2.3-dev from current git. And fix typo in `methods.py` for `vsproj=yes` option (still won't work though).
2022-09-28Rename `script_instance` to `_script_instance` in the `GDVIRTUAL*` wrappers ↵bruvzg
to avoid shadowing `Object` member.
2022-09-26MethodBind: Silence GCC `-Wmaybe-uninitialized` caused by UBSANRémi Verschelde
A priori this doesn't appear to be an actual bug, but a known consequence of using UBSAN. We silence this one to still have the possibility to get more warnings raised by UBSAN, in case they are useful. Works around and closes #66343.
2022-09-26Add autocompletion to several Object methodsMicky
Add autocompletion for the following Object methods: - `connect`, `is_connected`, `disconnect`, `emit_signal`, `has_signal`; - `call`, `call_deferred`, `callv`, `has_method`; - `set`, `set_deferred`, `get`; - `set_meta`, `remove_meta`, `has_meta`, `remove_meta`.
2022-09-22Merge pull request #66110 from Zylann/reference_get_countRémi Verschelde
get_reference_count()`
2022-09-21Rename and expose `RefCounted::get_reference_count()`Marc Gilleron
2022-09-18Change UndoRedo to use Callableskobewi
2022-09-06Rename CONNECT_ONESHOT TO CONNECT_ONE_SHOTMicky
For consistency. Every other exposed `one_shot` is spaced out like this.
2022-09-02Rename `or_lesser` range property hint to `or_less`Hugo Locurcio
"less" should be used for quantity, rather than "lesser". Existing scripts that use `or_lesser` in `_get_property_list()` will need to be updated to account for this change.
2022-08-31Improve null and object printing to avoid confusion with arraysHugo Locurcio
- Use different syntax for object printing to avoid confusion with arrays. - Print null as `<null>` to avoid confusion with a string `"null"`. - Display `<empty>` in editor resource pickers to avoid confusion with array-based properties.
2022-08-26[macOS export] Simplify code signing options, add support for rcodesign tool ↵bruvzg
for signing and notarization.
2022-08-24Merge pull request #64691 from TokageItLab/Quaternion-editorRémi Verschelde
2022-08-24Implement Quaternion EditorSilc Renew
2022-08-24Merge pull request #64009 from KoBeWi/arrayy_lmaoRémi Verschelde
Replace Array return types with TypedArray (part 2)
2022-08-23Replace Array return types with TypedArray 2kobewi
2022-08-23[GDExtension] Fix `_property_can_revert` and `_property_get_revert` methods ↵bruvzg
using incorrect string type.
2022-08-23Merge pull request #64511 from derammo/derammo_fix_has_property_default_valueRémi Verschelde
2022-08-22Make `_validate_property` a multilevel methodYuri Sizov
2022-08-20added missing virtual to ScriptExtensionderammo
_has_property_default_value is a required virtual for ScriptExtension but it was not bound, and could therefore not be implemented this made it impossible to implement a ScriptExtension that runs
2022-08-19Merge pull request #64334 from YuriSizov/core-bind-property-revert-methodsYuri Sizov
Make `property_*_revert` methods multilevel and expose them for scripting
2022-08-18Make `property_*_revert` methods multilevel and expose them for scriptingYuri Sizov
2022-08-12Fix instance binding unreference callback regressionIgnacio Roldán Etcheverry
This was a regression from 44691448911f1d29d4d79dbdd5553734761e57c4 The callback should be called, not only be called when the refcount reaches 0. For example, the C# callback needs to know when the refcount reaches 1, in order to swap to a weak GC handle.
2022-08-08Add checks for empty/unnamed arguments to make_rst.pyYuri Sizov
2022-08-06Merge pull request #63712 from object71/fix-export-issuesRémi Verschelde
2022-08-03Removed faulty function update after get_property_list.Hristo Stamenov
The function tried to rearrange properties but that lead to problems with duplication or deleted properties. Implemented the logic that that function did inside the get_property_list both for tool scripts and non-tool scripts.
2022-08-02Clean-up array editingreduz
2022-08-01Improve easing inspector usabilityHugo Locurcio
- Add `positive_only` property hint to disallow using negative presets. These values are clamped in several places in the editor already, so this avoids displaying presets that don't work. - Move the Zero preset at the end of the positive list to match the custom property editor. It's also used less often than Linear, Ease In and Ease Out. - Rename presets to be consistent between the easing property editor and custom property editor. - Remove unused `inout` hint which was redundant since it was already the default.
2022-07-29Remove Signal connect bindsJuan Linietsky
Remove the optional argument p_binds from `Object::connect` since it was deprecated by Callable.bind(). Changed all uses of it to Callable.bind()
2022-07-26[Net] Modularize multiplayer, expose MultiplayerAPI to extensions.Fabio Alessandrelli
- RPC configurations are now dictionaries. - Script.get_rpc_methods renamed to Script.get_rpc_config. - Node.rpc[_id] and Callable.rpc now return an Error. - Refactor MultiplayerAPI to allow extension. - New MultiplayerAPI.rpc method with Array argument (for scripts). - Move the default MultiplayerAPI implementation to a module.