Age | Commit message (Collapse) | Author |
|
The current code style guidelines forbid the use of `auto`.
Some uses of `auto` are still present, such as in UWP code (which
can't be currently tested) and macros (where removing `auto` isn't
easy).
|
|
The trampolines were casting double to `size_t` (likely a copy-paste
mistake), so the value was getting truncated.
|
|
|
|
`disconnect_event_signals` can be called twice (when managed instance
is disposed and from the ScriptInstance destructor).
|
|
Fix create c# script from editor after partial class type is necessary
|
|
Replace malloc's with Godot's memalloc macro
|
|
|
|
|
|
C#: Fix StringName leak warnings after generating bindings
|
|
`Main::cleanup()` prints warnings if it finds `StringName`s still alive.
We need the `BindingsGenerator` to be destructed before calling cleanup.
|
|
The following two bugs were fixed:
- For classes without namespace we were still generating `namespace {`
without a namespace identifier, causing a syntax error.
- For classes with nested namespaces we were generating only the innermost
part of the namespace was being generated, e.g.: for `Foo.Bar` we were
generating `namespace Bar {` instead of `namespace Foo.Bar {`.
This wasn't causing any build error, but because of the wrong namespace
Godot wasn't able to find the class associated with the script.
|
|
Added mono_unhandled_exception call to unhandled_exception hook
|
|
|
|
Add C# source generator for ScriptPathAttribute
|
|
This source generator adds a newly introduced attribute,
`ScriptPath` to all classes that:
- Are top-level classes (not inner/nested).
- Have the `partial` modifier.
- Inherit `Godot.Object`.
- The class name matches the file name.
A build error is thrown if the generator finds a class that meets these
conditions but is not declared `partial`, unless the class is annotated
with the `DisableGodotGenerators` attribute.
We also generate an `AssemblyHasScripts` assembly attribute which Godot
uses to get all the script classes in the assembly, eliminating the need
for Godot to search them. We can also avoid searching in assemblies that
don't have this attribute. This will be good for performance in the
future once we support multiple assemblies with Godot script classes.
This is an example of what the generated code looks like:
```
using Godot;
namespace Foo {
[ScriptPathAttribute("res://Player.cs")]
// Multiple partial declarations are allowed
[ScriptPathAttribute("res://Foo/Player.cs")]
partial class Player {}
}
[assembly:AssemblyHasScripts(new System.Type[] { typeof(Foo.Player) })]
```
The new attributes replace script metadata which we were generating by
determining the namespace of script classes with a very simple parser.
This fixes several issues with the old approach related to parser
errors and conditional compilation.
It also makes the task part of the MSBuild project build, rather than
a separate step executed by the Godot editor.
|
|
Co-authored-by: Ignacio Etcheverry <ignalfonsore@gmail.com>
|
|
|
|
|
|
|
|
Add C# array features from core PackedArrays
|
|
Add ClassDB tests to look for core API deps on editor API
|
|
|
|
|
|
|
|
-Added a new method in Resource: reset_state , used for reloading the same resource from disk
-Added a new cache mode "replace" in ResourceLoader, which reuses existing loaded sub-resources but resets their data from disk (or replaces them if they chaged type)
-Because the correct sub-resource paths are always loaded now, this fixes bugs with subresource folding or subresource ordering when saving.
|
|
|
|
search paths on macOS.
|
|
|
|
|
|
Modernize Thread
|
|
- Based on C++11's `thread` and `thread_local`
- No more need to allocate-deallocate or check for null
- No pointer anymore, just a member variable
- Platform-specific implementations no longer needed (except for the few cases of non-portable functions)
- Simpler for `NO_THREADS`
- Thread ids are now the same across platforms (main is 1; others follow)
|
|
Navigating to error line number in Rider from Godot editor debugger console is off-by-one.
|
|
Fixes https://github.com/JetBrains/godot-support/issues/61
|
|
http_escape and percent_encode have been unified into uri_encode, and http_unescape and percent_decode have been unified into uri_decode.
|
|
Also add BinToInt to C#
|
|
C#: Fix System.Collections.Generic.List marshalling
|
|
Drop unused xpmfix.sh script.
|
|
|
|
CI: Update to clang-format 11 and apply ternary operator changes
|
|
|
|
|
|
The ClassDB tests will detect when the core API has dependencies on
the editor API, which is not allowed.
This should prevent or warn early about issues like #44856
|
|
|
|
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 🎆
|
|
Those were missed in #44401 or added by later PRs.
|
|
Rename Math::stepify to snapped
|
|
|
|
|
|
|
|
Fixed #42149: bug where the default C# script template would sometimes produce an invalid class name
|