Age | Commit message (Collapse) | Author |
|
Looking at the original PR, I believe this is the original intent, but it now means that previously dead code is now executed.
|
|
- 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.
|
|
|
|
|
|
|
|
GDScript: Fix setter being called in chains for shared types
|
|
When a type is shared (i.e. passed by reference) it doesn't need to be
called in a setter chain (e.g. `a.b.c = 0`) since it will be updated in
place.
This commit adds an instruction that jumps when the value is shared so
it can be used to skip those cases and avoid redundant calls of setters.
It also solves issues when assigning to sub-properties of read-only
properties.
|
|
Initialize them with the implicit method so they're not related to the
overriding of the `_ready` method of the script but instead are always
set.
|
|
So it's not shown on docs or when listing the methods. This also avoids
being able to call it using the `call()` function.
|
|
|
|
Fix logic errors in match-statement Array & Dictionary patterns
|
|
The `%` is used in scene unique nodes. Now `%` can also be used instead
of `$` for the shorthand, besides being allowed generally anywhere in
the path as the prefix for a node name.
|
|
|
|
* Map is unnecessary and inefficient in almost every case.
* Replaced by the new HashMap.
* Renamed Map to RBMap and Set to RBSet for cases that still make sense
(order matters) but use is discouraged.
There were very few cases where replacing by HashMap was undesired because
keeping the key order was intended.
I tried to keep those (as RBMap) as much as possible, but might have missed
some. Review appreciated!
|
|
Adds a new, cleaned up, HashMap implementation.
* Uses Robin Hood Hashing (https://en.wikipedia.org/wiki/Hash_table#Robin_Hood_hashing).
* Keeps elements in a double linked list for simpler, ordered, iteration.
* Allows keeping iterators for later use in removal (Unlike Map<>, it does not do much
for performance vs keeping the key, but helps replace old code).
* Uses a more modern C++ iterator API, deprecates the old one.
* Supports custom allocator (in case there is a wish to use a paged one).
This class aims to unify all the associative template usage and replace it by this one:
* Map<> (whereas key order does not matter, which is 99% of cases)
* HashMap<>
* OrderedHashMap<>
* OAHashMap<>
|
|
These typedefs don't save much typing compared to the full `Ref<Resource>`
and `Ref<RefCounted>`, yet they sometimes introduce confusion among
new contributors.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Fixes https://github.com/godotengine/godot/issues/53771.
|
|
|
|
or functions as callables.
|
|
Since enums resolve to a dictionary at runtime, calling dictionary
methods on an enum type is a valid use case. This ensures this is true
by adding test cases. This also makes enum values be treated as ints
when used in operations.
|
|
This makes sure that assigning values to enum-typed variables are
consistent. Same enum is always valid, different enum is always
invalid (without casting) and assigning `int` creates a warning
if there is no casting.
There are new test cases to ensure this behavior doesn't break in
the future.
|
|
|
|
'Compiler bug: unresolved assign' errors
|
|
cdemirer/fix-type-mutation-upon-assignment-with-operation
|
|
cdemirer/fix-member-property-only-getter-cant-be-set
|
|
cdemirer/fix-member-property-getter-dont-update-subscript-chain-root
|
|
Leak is caused by cyclic reference
|
|
Happy new year to the wonderful Godot community!
|
|
|
|
|
|
|
|
Also:
- Adds two stress tests to test_string.h
- Changes to .empty() on std::strings
|
|
|
|
Inline getters & setters are now FunctionNodes.
Their names are set in the parser, not in the compiler.
GDScript-Analyzer will now run through getter and setter.
Also report wrong type or signature errors regarding getset properties.
Added GDScript tests for getters and setters.
#53102
|
|
|
|
It was wrongly updating the assigned value with the result of the
operation.
|
|
|
|
|
|
Blackiris/fix-assignment-with-operator-on-type-member
Fix assignment with operator on type member
|
|
Which is useful when the key isn't a valid identifier, such as keys with
spaces or numeric keys.
|
|
Fix loading of interdependent autoloads
|
|
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".
|
|
|
|
Move the autoload resolution to runtime by loading it into the stack
with an extra instruction. This allows an autoload to use another
autoload singleton independent of load order.
|