summaryrefslogtreecommitdiffstats
path: root/modules/visual_script/visual_script_func_nodes.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Use const references where possible for List range iteratorsRémi Verschelde2021-07-251-12/+12
|
* Use C++ iterators for Lists in many situationsAaron Franke2021-07-231-28/+28
|
* Revert unnecessary changes to VisualScriptEmitSignalDavid Cambré2021-07-231-11/+1
| | | | Revert unnecessary changes to VisualScriptEmitSignal, commit 2032b56005b2f6add6b105a00f04c05f9b292eec
* Merge pull request #49749 from ↵Rémi Verschelde2021-07-211-48/+98
|\ | | | | | | | | DavidCambre/VisualScriptFunction_Call_Set_Get_Improvement-2 VisualScriptFunctionNodes Improvements
| * Improve and streamline VisualScriptFuncNodes Call Set GetDavid Cambré2021-07-211-48/+98
| | | | | | | | | | | | | | This PR improves and streamlines the workflow for VisualScriptFunctionNodes Call Set Get Uniform design. Drag in set-get from tree is now working. Removes redundant method_select popup.
* | Use PROPERTY_USAGE_NONE instead of 0 for no property usageAaron Franke2021-07-011-14/+14
|/ | | | Also use const more often.
* Rename `instance()`->`instantiate()` when it's a verbLightning_A2021-06-191-8/+8
|
* [Net] Refactor RPCs, remove RSETsFabio Alessandrelli2021-06-011-7/+9
| | | | | | | | | | In this PR: - Removed rset - rpc_config can now optionally configure transfer mode (reliable/unreliable/ordered) and channel (channels are not actually implemented yet.) - Refactor how the RPC id is computed to minimize the logic in Node and scripts that now only needs a single `get_rpc_methods` function.
* Fixes small typos and grammar correctionAnshul7sp12021-03-121-3/+3
|
* Removed _change_notifyreduz2021-02-101-24/+24
| | | | | | -For inspector refresh, the inspector now detects if a property change by polling a few times per second and then does update the control if so. This process is very cheap. -For property list refresh, a new signal (property_list_changed) was added to Object. _change_notify() is replaced by notify_property_list_changed() -Changed all objects using the old method to the signal, or just deleted the calls to _change_notify(<property>) since they are unnecesary now.
* Update copyright statements to 2021Rémi Verschelde2021-01-011-2/+2
| | | | | | | | | | | | | | Happy new year to the wonderful Godot community! 2020 has been a tough year for most of us personally, but a good year for Godot development nonetheless with a huge amount of work done towards Godot 4.0 and great improvements backported to the long-lived 3.2 branch. We've had close to 400 contributors to engine code this year, authoring near 7,000 commit! (And that's only for the `master` branch and for the engine code, there's a lot more when counting docs, demos and other first-party repos.) Here's to a great year 2021 for all Godot users 🎆
* Remove empty lines around braces with the formatting scriptAaron Franke2020-11-161-1/+0
|
* Refactor variant built-in methods yet again.reduz2020-11-111-16/+18
| | | | | | * Using C-style function pointers now, InternalMethod is gone. * This ensures much better performance in typed code. * Renamed builtin_funcs to utility_funcs, to avoid naming confusion
* Refactored variant constructor logicreduz2020-11-091-6/+9
|
* Reorganized core/ directory, it was too fatty alreadyreduz2020-11-071-1/+1
| | | | | | -Removed FuncRef, since Callable makes it obsolete -Removed int_types.h as its obsolete in c++11+ -Changed color names code
* Refactored variant setters/gettersreduz2020-11-071-9/+9
| | | | | | -Discern between named, indexed and keyed -Get direct access to functions for typed GDScript and GDNative bindings -Small changes to some classes in order to work with the new setget binder
* Bind missing constant in VisualScriptPropertyGetTomasz Chabora2020-10-121-0/+1
|
* Style: Enforce braces around if blocks and loopsRémi Verschelde2020-05-141-76/+142
| | | | | Using clang-tidy's `readability-braces-around-statements`. https://clang.llvm.org/extra/clang-tidy/checks/readability-braces-around-statements.html
* Style: Enforce separation line between function definitionsRémi Verschelde2020-05-141-0/+15
| | | | | | | | | | | | | | | | | | | | | | | I couldn't find a tool that enforces it, so I went the manual route: ``` find -name "thirdparty" -prune \ -o -name "*.cpp" -o -name "*.h" -o -name "*.m" -o -name "*.mm" \ -o -name "*.glsl" > files perl -0777 -pi -e 's/\n}\n([^#])/\n}\n\n\1/g' $(cat files) misc/scripts/fix_style.sh -c ``` This adds a newline after all `}` on the first column, unless they are followed by `#` (typically `#endif`). This leads to having lots of places with two lines between function/class definitions, but clang-format then fixes it as we enforce max one line of separation. This doesn't fix potential occurrences of function definitions which are indented (e.g. for a helper class defined in a .cpp), but it's better than nothing. Also can't be made to run easily on CI/hooks so we'll have to be careful with new code. Part of #33027.
* Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocksRémi Verschelde2020-05-141-215/+0
| | | | | | | | | | | | | | Which means that reduz' beloved style which we all became used to will now be changed automatically to remove the first empty line. This makes us lean closer to 1TBS (the one true brace style) instead of hybridating it with some Allman-inspired spacing. There's still the case of braces around single-statement blocks that needs to be addressed (but clang-format can't help with that, but clang-tidy may if we agree about it). Part of #33027.
* Replace NULL with nullptrlupoDharkael2020-04-021-28/+28
|
* Reworked signal connection system, added support for Callable and Signal ↵Juan Linietsky2020-02-201-25/+25
| | | | objects and made them default.
* Update copyright statements to 2020Rémi Verschelde2020-01-011-2/+2
| | | | | | | | | | | Happy new year to the wonderful Godot community! We're starting a new decade with a well-established, non-profit, free and open source game engine, and tons of further improvements in the pipeline from hundreds of contributors. Godot will keep getting better, and we're looking forward to all the games that the community will keep developing and releasing with it.
* Make VisualScript check inheritance for port infoAaron Franke2019-10-091-2/+2
|
* Visualscript editor graph unification & refactoringSwarnim Arun2019-09-261-9/+4
| | | | Removes the need to have separate graphs per function for the VisualScript Nodes, and refactoring UI and other improvements such as fuzzy search, right click search boxes and in-graph editable nodes
* Visualscript: Add types for base type get and set.K. S. Ernest (iFIre) Lee2019-07-191-9/+23
|
* Fixes minor issues found by static analyzerqarmin2019-07-071-7/+0
|
* Some code changed with Clang-Tidyqarmin2019-06-261-5/+2
|
* Style: Apply new changes from clang-format 8.0Rémi Verschelde2019-04-091-1/+2
| | | | | | It seems to stay compatible with formatting done by clang-format 6.0 and 7.0, so contributors can keep using those versions for now (they will not undo those changes).
* calculate inputs count from arg types instead of namesMarcin Zawiejski2019-03-041-3/+2
|
* Update copyright statements to 2019Rémi Verschelde2019-01-011-2/+2
| | | | Happy new year to the wonderful Godot community!
* Make core/ includes absolute, remove subfolders from include pathRémi Verschelde2018-09-121-3/+3
| | | | | | This allows more consistency in the manner we include core headers, where previously there would be a mix of absolute, relative and include path-dependent includes.
* Make some debug prints verbose-only, remove othersRémi Verschelde2018-08-241-1/+0
|
* Improve VisualScript UXK. S. Ernest (iFire) Lee2018-07-241-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Prototype faster function call ux. * Work on general search ux. * Able to create nodes from search. * Show class for variables but not methods. * Get actions search working. * Descriptions now show for both methods and properties. * Enable zooming on mouse wheel up and down. * Make the drag trigger on right mouse button. * Search now shows for action visual script nodes. * Able to search visual node names. * Search works better. * Change zooming scale to hide artifacts better. * Remove zoom changes * Select from base should check properties too like the other functions. * Seq_connect flag is needed to set sequence lines correctly. * Remove comment * Code cleanup with function names and arguments. * Use brief description for search descriptions. * Clean and fix bug with input nodes connecting with sequence lines. * Add a warning and fix some edge conditions with sequence into data lines and vice versa. * Don't search functions when pulling from a sequence node. * Don't show actions when pulling from a data line. * Set set and get properties. * Convert visual script operators to the correct type * Create a function preset finds only functions. * Singletons can now find functions. * Add shift-a for generic search. * Add brief descriptions for Visual Script nodes. * Search boxes can now filter names. * Add bigger hit zones to node connect. * For the drop zones, make all the rect2 areas the same size. * Function names in visual script node should be lower case so that search works better. * Use the convention of capitalize() for set, set, visual script nodes and methods. * Make search more general. Ignore "_" and make case-insensitive. Also made the search window smaller and remove extra info from search * Make type_cast use the connecting node's type and remove use of found variable. * Fix case where you call an instance's call function where it becomes an invalid call. * Make get_visual_node_names use a set of filters, move action creations and fix bug with sequence node connections. * Make the window bigger. * Make connect_data and connect_seq more robust. * Add icons to search items. * Add vs constructors in shift-a menu. * Operators, builtins and constructors show type name. Fix several problems with port connections. * In shift-a mode search everything. * Code cleanup * Work on autocompleting the type. * Use type guess in action creation. * Check if type hint string exists in object variables when generating the visual script search. * Add the hint to SceneTree. * Add original type detection. * Make type casting great again. This puts the type casted base type as the data output type string hint. * Pass the type in a VisualScriptFunctionCall too. * Set the base type correctly in VisualScriptFunctionGet and VisualScriptFunctionSet using hint string. * Make sure the instance is passed in VisualScriptPropertySet. * Restore search on the node's type. * Remove dependencies from graph_edit. * Remove dependencies from property_selector and name the class visual_script_property_selector. * Extract hot zones into a function. * Move hot_zones constants into default theme. * Bigger capture zones. * Clean messy port_grab_distance variables. * Remove RMB functionality. * Remove memory leak on showing visual script descriptions. * Read the port_grab_distance constants on enter tree and theme changed.
* More stuff!Pieter-Jan Briers2018-05-011-48/+28
|
* Move things into the title bars of Visual Script nodes.Pieter-Jan Briers2018-04-301-21/+11
| | | | | | This is an attempt to make VS slightly nicer to use. WiP.
* Bind many more properties to scriptsBojidar Marinov2018-01-121-7/+7
| | | | | | | Notable potentially breaking changes: - PROPERTY_USAGE_NOEDITOR is now PROPERTY_USAGE_STORAGE | PROPERTY_USAGE_NETWORK, without PROPERTY_USAGE_INTERNAL - Some properties were renamed, and sometimes even shadowed by new ones - New getter methods (some virtual) were added
* Add missing copyright headers and fix formattingRémi Verschelde2018-01-051-0/+1
| | | | | | Using `misc/scripts/fix_headers.py` on all Godot files. Some missing header guards were added, and the header inclusion order was fixed in the Bullet module.
* Update copyright statements to 2018Rémi Verschelde2018-01-011-2/+2
| | | | Happy new year to the wonderful Godot community!
* Move singleton management from ProjectSettings to EngineLeon Krause2017-11-141-8/+8
|
* Fix "Invalid outputs" error when calling a void method from visual scriptBojidar Marinov2017-11-081-0/+2
| | | | Fixes #11851
* VisualScript crashfix when returns are too fewMarcelo Fernandez2017-09-301-2/+8
|
* Fixed constness of variant functions, as well as visual script sequence ↵Juan Linietsky2017-09-251-2/+2
| | | | ports. Closes #11258
* Move Variant::evaluate() switch to computed gotoHein-Pieter van Braam2017-09-171-1/+1
| | | | | | | | | | | | | In an effort to make GDScript a little faster replace the double switch() with a computed goto on compilers that set __GNUC__. For compilers that don't support computed goto it will fall back to regular switch/case statements. In addition disable using boolean values in a mathematical context. Now boolean values can only be compared with other booleans. Booleans will also no longer be coerced to integers. This PR replaces #11308 and fixes #11291
* Fix enums bindingsMaxim Sheronov2017-09-131-0/+20
| | | | | Add missed bindings for enums Move some enums to class to have correct output of api.json
* Use HTTPS URL for Godot's website in the headersRémi Verschelde2017-08-271-1/+1
|
* Added/Fixed null pointer checksWilson E. Alvarez2017-08-261-3/+3
|
* Convert Object::cast_to() to the static versionHein-Pieter van Braam2017-08-241-17/+8
| | | | | | | | | | | | Currently we rely on some undefined behavior when Object->cast_to() gets called with a Null pointer. This used to work fine with GCC < 6 but newer versions of GCC remove all codepaths in which the this pointer is Null. However, the non-static cast_to() was supposed to be null safe. This patch makes cast_to() Null safe and removes the now redundant Null checks where they existed. It is explained in this article: https://www.viva64.com/en/b/0226/
* Merge pull request #10351 from neikeq/enums-are-for-the-weakJuan Linietsky2017-08-211-10/+11
|\ | | | | ClassDB: Provide the enum name of integer constants
| * ClassDB: Provide the enum name of integer constantsIgnacio Etcheverry2017-08-201-10/+11
| |