Commit Graph

4034 Commits

Author SHA1 Message Date
e956e80c1f Style: clang-format: Disable AllowShortIfStatementsOnASingleLine
Part of #33027, also discussed in #29848.

Enforcing the use of brackets even on single line statements would be
preferred, but `clang-format` doesn't have this functionality yet.
2020-05-10 13:12:16 +02:00
da898c116c Merge pull request #37160 from ThakeeNathees/saveing-cyclic-inheritance-crash-fix
Fix: saving gdscript with cyclic inheritance crash the editor
2020-05-10 13:11:40 +02:00
a128dd97d6 Merge pull request #37020 from aaronfranke/range
Allow using integer vectors for iteration and make range() use them
2020-05-10 13:11:07 +02:00
4686963ed7 Merge pull request #36937 from ThakeeNathees/statement-end-error-message-fix
Fix: more clearer unexpected statement end error messages
2020-05-10 13:10:55 +02:00
ec7b481170 Renamed plane's d to distance 2020-05-10 12:12:51 +02:00
c2ab35bdde fixed: saving gdscript with cyclic inheritance crash the editor
Fix: #9609
2020-05-10 09:07:09 +05:30
5758d87f09 more clearer unexpected statement end error messages 2020-05-10 02:35:27 +05:30
a4b829410c Merge pull request #38481 from RandomShaper/improve_yield
Fix object leaks caused by unfulfilled yields
2020-05-09 22:02:52 +02:00
b61a496aa7 Merge pull request #38357 from ThakeeNathees/dict2inst-crash-fix
fix: dict2inst crash when constructor has arguments
2020-05-09 22:00:04 +02:00
cf0953fefa Merge pull request #37598 from ThakeeNathees/GDScript-type-resolve-bug-fix
GDScript class var type resolve bug fixed
2020-05-09 21:59:26 +02:00
f5371bc6b8 Merge pull request #37033 from ThakeeNathees/python-like-str-escape
python like string escape implemented
2020-05-09 21:53:59 +02:00
c04cdc2bf1 Merge pull request #38412 from ThakeeNathees/static-func-var-access
parser error for static func access non-static variables
2020-05-09 21:32:28 +02:00
4441222194 C#: Remove StringExtensions.Empty() function
Causes issues with some editors as it's confused with `string.Empty`.
Should use `string.IsNullOrEmpty(str)` instead.
2020-05-09 20:48:00 +02:00
61306eb830 Merge pull request #38596 from neikeq/msbuild-restore
Mono: Use msbuild instead of nuget.exe for restoring
2020-05-09 20:16:52 +02:00
b61ffef0ab Mono: Use msbuild instead of nuget.exe for restoring
- Make GodotTools output directly to the SCons output directory.
- Removed xbuild_fallback from the build system.
2020-05-09 19:45:04 +02:00
cf4482e8c4 Change get_completion_identifier_is_function to return a bool
A minor bugfix
2020-05-09 13:45:00 -04:00
f7b50992b5 Allow using integer vectors for iteration and make range() use them 2020-05-09 13:43:35 -04:00
e0a001549e Mono: Fix hot-reloading of nested classes 2020-05-09 19:18:28 +02:00
ae33cf5f45 Merge pull request #36379 from aaronfranke/color-constructors
Add a Color constructor for Color with alpha
2020-05-07 21:16:51 +02:00
46bfe4452f Fix object leaks caused by unfulfilled yields
Now the stack saved in a `GDScriptFunctionState` is cleared as soon as the `yield()` operation is known not to be resumed because either the script, the instance or both are deleted.

This clears problems like leaked objects by eliminating cases of circular references between `GDScriptFunctionState`s preventing them and the objects they refer to in their saved stacks from being released. As an example, this makes using `SceneTreeTimer` safer.

Furthermore, with this change it's now possible to print early warnings about `yield()`s to released script/instances, as now we know they won't be successfully resumed as the condition for that happens. However, this PR doesn't add such messages, to keep the observed behavior the same for the time being.

Also, now a backup of the function name in `GDScriptFunctionState` is used, since the script may not be valid by the time the function name is needed for the resume-after-yield error messages.
2020-05-05 17:54:15 +02:00
4d50f747d5 Merge pull request #37293 from Janglee123/ctrl-click-improvements
Improved go-to definition (Ctrl + Click)
2020-05-05 16:49:15 +02:00
be7a353c70 Improved go-to definition (Ctrl + Click)
Co-Authored-By: Bojidar Marinov <bojidar.marinov.bg@gmail.com>
2020-05-05 10:46:12 +05:30
878adb22b7 Merge pull request #37717 from qarmin/world_fix
Change non-existent World to World3D
2020-05-04 16:37:40 +02:00
3c200b23fb Merge pull request #32534 from Xrayez/fix-dict2inst-init
Make `dict2inst` to work with arbitrary `_init` parameters
2020-05-03 09:58:07 +02:00
1309bfa97a Merge pull request #38275 from DSteve595/indented-block-line
Mark "Indented block expected" error after function declaration
2020-05-03 09:57:29 +02:00
ce978517e0 parser error for static func access non-static variables
Fix: #38408
2020-05-03 11:45:11 +05:30
e6e5ba32cd Mention offending function name in "Indented block expected" error 2020-05-02 17:10:34 -07:00
596d426151 Remove some C++11 polyfill defines that are no longer needed 2020-05-03 00:42:04 +02:00
d883b90988 Merge pull request #38105 from AndreaCatania/AndreaCatania-patch-2
Removed noisy ERR check from Multiplayer API.
2020-05-01 13:53:55 +02:00
7001d06f9d Make dict2inst to work with arbitrary _init parameters
This is achieved by skipping initializer call while creating an instance
of a GDScript. This is implemented by passing -1 as an argument count
to `_new` and interpreting any value below 0 to mean that the initializer
should not be called during instantiation, because internal members of
an instance are going to be overridden afterwards.
2020-04-30 18:30:04 +03:00
2175397210 tinyexr: Enable C++11 threaded loading 2020-04-30 15:31:02 +02:00
9f6b20936e fix: dict2inst crash when constructor has arguments 2020-04-30 17:35:53 +05:30
a6e3c84c68 Merge pull request #38328 from Nannaquin/master
Fix growMargin() not returning modified Rect2/Rect2i in Mono
2020-04-30 03:39:37 +02:00
90df1d67cb Color with alpha constructor 2020-04-29 14:41:12 -04:00
92d4a0cbd2 Merge pull request #38288 from RandomShaper/imvu/fix_not_freed_gdsfuncstate
Fix leaked objects when game ends with yields in progress
2020-04-29 17:30:28 +02:00
0ac6f4c40b Fix growMargin() not returning modified Rect2/Rect2i 2020-04-29 11:29:57 -04:00
39a0cdac5f Merge pull request #38279 from BigRed-118/assert_mark_as_safe_regression_bug
Fix for marking assert lines as safe bug
2020-04-29 16:24:38 +02:00
c427334393 Fix leaked objects when game ends with yields in progress 2020-04-29 13:55:10 +02:00
540156b387 [Core] Rename linear_interpolate to lerp 2020-04-29 04:02:49 -04:00
ad3c3e1bbb [Mono] Rename LinearInterpolate to Lerp 2020-04-29 04:02:24 -04:00
41af228b76 Merge pull request #36960 from pycbouh/docs-improve-shortcuts
Improve shortcut formatting in docs
2020-04-29 09:40:52 +02:00
088cf37bf2 Merge pull request #37314 from nekomatata/bullet-fix-damping
Better damping implementation for Bullet rigid bodies
2020-04-28 21:39:05 +02:00
fdf58a5858 Rename InputFilter back to Input
It changed name as part of the DisplayServer and input refactoring
in #37317, with the rationale that input no longer goes through the
main loop, so the previous Input singleton now only does filtering.

But the gains in consistency are quite limited in the renaming, and
it breaks compatibility for all scripts and tutorials that access
the Input singleton via the scripting language. A temporary option
was suggested to keep the scripting singleton named `Input` even if
its type is `InputFilter`, but that adds inconsistency and breaks C#.

Fixes godotengine/godot-proposals#639.
Fixes #37319.
Fixes #37690.
2020-04-28 15:19:49 +02:00
39f7a40925 Merge pull request #37163 from madmiraal/fix-csg-normal
Fix CSG vertex normal calculation.
2020-04-28 14:28:31 +02:00
bd081df519 Fix for marking assert lines as safe bug
Calling _reduce_node_type from GDScriptParser::_parse_block for assert
was using a current class with a scope that didn't include all
functions. Now calling in GDScriptParser::_check_block_types uses the
right class type. We also now check the assert node message. The assert
line was added to the set_errors associated with assert, since before
the error would be reported on the next line
2020-04-27 20:25:54 -05:00
717f053e37 Merge pull request #38121 from JFonS/add_unwrap_caching
Add caching the lightmap unwrapping on import
2020-04-27 18:51:32 +02:00
9353a2bbd1 Better damping implementation for Bullet rigid bodies
Apply old method for linear & angular damping in Bullet, in order to
make it easier to tweak and consistent with Godot Physics.
2020-04-27 18:24:33 +02:00
f61587b158 Merge pull request #36927 from ThakeeNathees/export-var-type-reduce-implimented
Fix: export var type reduce() implemented
2020-04-27 17:01:04 +02:00
f7e2ff5223 Merge pull request #38253 from nekomatata/bullet-update-2.90
Update to bullet master (2.90)
2020-04-27 16:44:17 +02:00
cd487201c6 export var type reduce() implemented 2020-04-27 19:26:57 +05:30