summaryrefslogtreecommitdiff
path: root/modules/mono/csharp_script.cpp
AgeCommit message (Collapse)Author
2022-04-12Narrow FileAccess scope to prevent deadlocks.bruvzg
2022-04-11Make FileAccess and DirAccess classes reference counted.bruvzg
2022-03-28String: Remove TTR and DTR defines in non-tools buildRémi Verschelde
This ensures we don't use TTR in runtime code, as it's specifically meant to source translations for the editor.
2022-03-28Refactor GDScript/C# script templates logic to be editor-onlyRémi Verschelde
Not a full refactor as it still goes through ScriptLanguage so it's hacky, but at least it can now compile without this.
2022-03-09Remove VARIANT_ARG* macrosreduz
* Very old macros from the time Godot was created. * Limited arguments to 5 (then later changed to 8) in many places. * They were replaced by C++11 Variadic Templates. * Renamed methods that take argument pointers to have a "p" suffix. This was used in some places and not in others, so made it standard. * Also added a dereference check for Variant*. Helped catch a couple of bugs.
2022-03-06Remove duplicate editor settings definitionskobewi
2022-02-07Attach mono thread before getting nativeName fieldRaul Santos
In order to access the `nativeName` constant field from a C# class, the mono scope thread must be attached or the mono domain will be null.
2022-01-20Store panels and docks singletons in their own classestrollodel
2022-01-16Merge pull request #55679 from raulsntos/script_reload_fixIgnacio Roldán Etcheverry
C# scripts reload in editor fixed
2022-01-03Update copyright statements to 2022Rémi Verschelde
Happy new year to the wonderful Godot community!
2022-01-03Merge pull request #53957 from fabriceci/new-template-workflowRémi Verschelde
2022-01-02Improve editor template workflowfabriceci
Co-Authored-By: jmb462 <jmb462@gmail.com>
2021-12-28Fix getting properties state when reloading C#Raul Santos
When reloading C# classes and keep their properties values they are retrieved and stored in a state list. Retrieving the properties was only getting the fields of the C# class and not inherited fields so those properties values were lost on reload. Now we also try to find the field in the parent classes.
2021-12-06C# script reload fixedRaul Santos
Co-authored-by: Michael Bickel <mib@developium.net> Co-authored-by: Germanrc <german_1995a@hotmail.com>
2021-11-25Move logic for saving project features to ProjectSettings save_customAaron Franke
2021-11-12Use "enum class" for input enumsAaron Franke
2021-11-03Rename `PROPERTY_USAGE_NOEDITOR` to `PROPERTY_USAGE_NO_EDITOR`Hugo Locurcio
This is consistent with other constants that include `NO`, such as `PROPERTY_HINT_COLOR_NO_ALPHA`.
2021-10-30Ensure C# script properties are added to the endRaul Santos
Ensures that the `get_property_list` and `get_script_property_list` methods push the script properties to the end of the given list, this prevents the script property from appearing after the script variables.
2021-10-28clang-format: Enable `BreakBeforeTernaryOperators`Rémi Verschelde
clang-format keeps breaking the way it handles break *after* ternary operators, so I give up and go with the only style they seem to actually test.
2021-10-28clang-format: Disable alignment of operands, too unreliableRémi Verschelde
Sets `AlignOperands` to `DontAlign`. `clang-format` developers seem to mostly care about space-based indentation and every other version of clang-format breaks the bad mismatch of tabs and spaces that it seems to use for operand alignment. So it's better without, so that it respects our two-tabs `ContinuationIndentWidth`.
2021-10-22Keep order for C# exported membersRaul Santos
2021-10-19C#: Fix property set call boxing value when unboxed was expectedIgnacio Roldán Etcheverry
2021-10-01[Net] Rename RPC constants and annotation arguments.Fabio Alessandrelli
any -> any_peer sync -> call_local ordered -> unreliable_ordered Multiplayer.RPC_MODE_ANY -> RPC_MODE_ANY_PEER Multiplayer.TRANSFER_MODE_ORDERED -> TRANSFER_MODE_UNRELIABLE_ORDERED
2021-09-28Update C# RPC attributes to share new Any/Auth naming conventionEdward Auttonberry
Update attribute class references in mono cache
2021-09-17Merge pull request #51835 from magian1127/patch1Rémi Verschelde
2021-09-14Merge pull request #52633 from lewiji/mono-build-solution-shortcut-4.0Rémi Verschelde
2021-09-14Add editor keyboard shortcut for Mono Build solution buttonLewis James
Apply suggestions from code review Merging @akien-mga's suggestion with the matching change to the CS project Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2021-09-12Improve C# method listingPaul Joannon
- implement CSharpInstance::get_method_list - loop through parent classes in CSharpInstance::get_method_list and CSharpScript::get_script_method_list (#46408)
2021-09-08Merge pull request #52246 from Paulb23/verbatim-stringMax Hilbrunner
Syntax highlight c# verbatim string literal
2021-09-07[Net] Move multiplayer to core subdir, split RPCManager.Fabio Alessandrelli
Move multiplayer classes to "core/multiplayer" subdir. Move the RPCConfig and enums (TransferMode, RPCMode) to a separate file (multiplayer.h), and bind them to the global namespace. Move the RPC handling code to its own class (RPCManager). Renames "get_rpc_sender_id" to "get_remote_sender_id".
2021-08-30syntax highlight c# verbatim string literalPaulb23
2021-08-30[Net] Rename RPC "puppet" to "auth" (authority). Drop "master".Fabio Alessandrelli
This commit completely removes the RPC_MODE_MASTER ("master" keyword), and renames the RPC_MODE_PUPPET to RPC_MODE_AUTHORITY ("auth" keyword). This commit also renames the "Node.[get|set]_network_master" methods to "Node.[get|set]_network_authority". This commit also renames the RPC_MODE_REMOTE constant to RPC_MODE_ANY. RPC_MODE_MASTER in Godot 3.x meant that a given RPC would be callable by any puppet peer on the master, while RPC_MODE_PUPPET meant that it would be callable by the master on any puppet. Beside proving to be very confusing to the user (referring to where it could be called instead of who can call it) the RPC_MODE_MASTER is quite useless. It is almost the same as RPC_MODE_REMOTE (anyone can call) with the exception that the network master cannot. While this could be useful to check in some case, in such a function you would anyway need to check in code who is the caller via get_rpc_sender_id(), so adding the check there for those rare cases does not warrants a dedicated mode.
2021-08-20check that the element type is indeed StringMagian
2021-08-18C# Array<String> Export Support Enum(String)Magian
2021-08-16Merge pull request #51698 from Paulb23/text-editor-settingsRémi Verschelde
Reorganise text editor settings
2021-08-16Reorganise text editor settingsPaulb23
2021-08-16Fix C# native instance bindings after recent re-writeIgnacio Roldán Etcheverry
This was needed after: 44691448911f1d29d4d79dbdd5553734761e57c4
2021-08-03Fix 'script_class' null access when reloading a deleted C# script31
2021-07-27Use C++ iterators in the Mono moduleRaul Santos
2021-07-26Use Ref<T> references as iterators where relevantRémi Verschelde
And const when possible.
2021-07-25Use const references where possible for List range iteratorsRémi Verschelde
2021-07-23Use C++ iterators for Lists in many situationsAaron Franke
2021-07-20[Net] Single `rpc` annotation. "sync" no longer part of mode.Fabio Alessandrelli
- Move the "sync" property for RPCs to RPCConfig. - Unify GDScript annotations into a single one: - `@rpc(master)` # default - `@rpc(puppet)` - `@rpc(any)` # former `@remote` - Implement three additional `@rpc` options: - The second parameter is the "sync" option (which also calls the function locally when RPCing). One of "sync", "nosync". - The third parameter is the transfer mode (reliable, unreliable, ordered). - The third parameter is the channel (unused for now).
2021-07-12[Net] Rename NetworkedMultiplayerPeer to MultiplayerPeer.Fabio Alessandrelli
2021-07-08Redo how instance bindings workreduz
* The harcoded 8 slots are no more and impose limits in the new extension system. * New system is limitless, although it will impose small performance hit with a mutex. * Use a token to request the instance binding. **Warning**: Mono will most likely break as a result of this, will need to be modified to use the new system.
2021-06-19Rename `instance()`->`instantiate()` when it's a verbLightning_A
2021-06-19Consolidate JSON, JSONParseResults and JSONParser into JSONMarcel Admiraal
Renames JSON.parse_string() to parse() Renames JSON.decode_data() to stringify()
2021-06-13Fix slow load/save of scenes with many instances of the same scriptPedro J. Estébanez
2021-06-13Improve & fix Mono buildPedro J. Estébanez
- Fix C++ compile errors about pending variable renames after the `Reference` to `RefCount` change. - Fix C# compile errors due to the recent rename of `EnablePlugin()` and `Build()`, which are now underscore-prefixed in bindings. - Additional rename: `godot_icall_Reference_Dtor` to `godot_icall_RefCounted_Dtor`.
2021-06-11Rename Reference to RefCountedPedro J. Estébanez