Pawel Lampe
1a15a3adf6
Fix GDScript parser crash on 'dollar mixed with assignment' expression
...
fixes #53696
2021-11-21 21:18:46 +01:00
Max Hilbrunner
626ca50676
Improve GDScript indentation error message
2021-10-28 13:01:53 +02:00
reduz
d03b7fbe09
Refactored Node3D rotation modes
...
* Made the Basis euler orders indexed via enum.
* Node3D has a new rotation_order property to choose Euler rotation order.
* Node3D has also a rotation_mode property to choose between Euler, Quaternion and Basis
Exposing these modes as well as the order makes Godot a lot friendlier for animators, which can choose the best way to interpolate rotations.
The new *Basis* mode makes the (exposed) transform property obsolete, so it was removed (can still be accessed by code of course).
2021-10-25 14:34:00 -03:00
Rémi Verschelde
4387f9645b
Merge pull request #52940 from groud/toast_notification
2021-10-19 09:57:13 +02:00
Rémi Verschelde
3f888966c0
Merge pull request #53843 from vnen/gdscript-typed-array-subscript-constant
...
Fix inferred typed array marked as constant
2021-10-15 16:49:29 +02:00
George Marques
540821a264
GDScript: Fix inferred typed array marked as constant
2021-10-15 10:40:50 -03:00
George Marques
056a54db7b
GDScript: Properly return value with await on non-coroutine
...
If the keyword `await` is used without a coroutine, it should still
return the value synchronally.
2021-10-14 19:58:10 -03:00
Rémi Verschelde
472ff40f71
Merge pull request #53807 from vnen/dont-share-arrays-and-dicts
2021-10-14 20:42:22 +02:00
George Marques
4c14051b3f
Zero Dictionary and Array variants when changing type with reset
...
So they don't reference to the old values anymore and instead refer to
a new value.
2021-10-14 11:22:17 -03:00
George Marques
bf322bacdd
Merge pull request #53726 from briansemrau/gd-outer-class
...
GDScript 2.0: Access outer scope classes
2021-10-14 10:12:52 -03:00
Gilles Roudière
0587e5e018
Implement toast notifications in the editor
2021-10-14 13:30:54 +02:00
Brian Semrau
0ff0f64cd4
GDScript: Access outer scope classes
2021-10-13 22:39:12 -04:00
Rémi Verschelde
e4288bf728
Merge pull request #53720 from vnen/gdscript-typed-array-custom-class
2021-10-12 16:51:50 +02:00
George Marques
34288b24a6
GDScript: Fix typed array with custom classes
2021-10-12 10:41:04 -03:00
George Marques
45f546c1d8
GDScript: Make setter parameter type same as variable type
2021-10-12 09:39:23 -03:00
George Marques
f930d54140
Merge pull request #53103 from ZuBsPaCe/gdscript-analyze-properties-fix
...
GDScript: Report property type errors
2021-10-11 11:01:39 -03:00
mashumafi
575d4e00b6
Enhance and cleanup stringify for Vector
2021-10-09 06:19:25 +00:00
ZuBsPaCe
551ceb590b
GDScript: Report property type errors
...
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
2021-10-08 22:06:15 +02:00
Rémi Verschelde
49e7e049ab
Merge pull request #53422 from KoBeWi/add_LUA_to_Godot
2021-10-07 23:37:37 +02:00
Rémi Verschelde
98b81ad35c
Merge pull request #53479 from vnen/gdscript-subscript-object-self
2021-10-06 19:48:23 +02:00
George Marques
1f55bd190c
GDScript: Allow subscript on self and object types
2021-10-06 12:01:34 -03:00
George Marques
6bdb28f5e4
GDScript: Avoid hard errors on inferred types
...
Since inference isn't always correct, they are now treated as unsafe
instead of errors.
This also removes inferred type when a variable is reassigned. Since
it's not aware of branching, the types might become invalid in a later
context.
2021-10-06 11:42:19 -03:00
George Marques
d6c799006a
GDScript: Make all warnings enabled in test generation
...
The test generation doesn't initialize the language (since it's already
initialized in main), but it still needs the warning enabled so it
matches the actual tests.
2021-10-06 11:39:00 -03:00
kobewi
9e5fdbc79d
Fix LUA-style assignment in Dictionary
2021-10-05 12:17:13 +02:00
George Marques
84956fee4b
GDScript: Fix member assignment with operation
...
It was wrongly updating the assigned value with the result of the
operation.
2021-10-04 14:09:54 -03:00
Lightning_A
c63b18507d
Use range iterators for Map
2021-09-30 15:09:12 -06:00
Rémi Verschelde
27d4e2f09f
Merge pull request #53216 from vnen/gdscript-builtin-type-not-id
2021-09-29 17:04:24 +02:00
George Marques
72c07708e8
GDScript: Don't allow builtin type names as identifiers
2021-09-29 11:23:16 -03:00
George Marques
991f4d8527
GDScript: Fix assignment with operation for properties
2021-09-29 10:54:16 -03:00
Rémi Verschelde
679f70c1e1
Merge pull request #52906 from vnen/gdscript-show-error-on-yield
2021-09-21 20:36:39 +02:00
Rémi Verschelde
b3b4860d2e
Merge pull request #52905 from vnen/gdscript-single-line-declaration
2021-09-21 20:35:36 +02:00
George Marques
262d6c6bef
GDScript: Show specific error when "yield" is used
...
To help people porting code, it gives a hint to use "await" instead of a
generic error.
2021-09-21 14:38:14 -03:00
George Marques
e5ebc9710d
GDScript: Allow classes declaration to be done in single line
...
Incidentally, allow multiple statements in single line functions when
using semicolon as a terminator.
2021-09-21 14:14:46 -03:00
George Marques
bab0afc821
GDScript: Allow multiple lines in signal parameters declaration
2021-09-21 13:40:39 -03:00
Rémi Verschelde
82c12060b2
Merge pull request #52718 from Calinou/gdscript-add-integration-tests-2
2021-09-21 14:13:24 +02:00
Rémi Verschelde
424ddcba37
Merge pull request #52792 from vnen/gdscript-subscript-missing-index
2021-09-17 20:16:29 +02:00
Rémi Verschelde
7762e8b1c1
Merge pull request #52788 from vnen/gdscript-compare-with-null
2021-09-17 19:35:55 +02:00
George Marques
651319de11
GDScript: Properly catch error when missing index in subscript
2021-09-17 14:31:51 -03:00
George Marques
455e142d37
Allow comparing equality between builtin types and null
2021-09-17 12:33:52 -03:00
George Marques
4e69341c01
GDScript: Avoid inferred types from giving hard errors
2021-09-17 11:52:30 -03:00
Hugo Locurcio
c6ca09dc6f
Add more integration tests to the GDScript test suite
...
This also fixes a typo in the `bitwise_float_right_operand.gd` test.
2021-09-15 19:57:39 +02:00
Rémi Verschelde
a4187c9235
Merge pull request #52706 from vnen/gdscript-ternary-operator-crash
...
GDScript: Show error when missing expression after ternary else
2021-09-15 17:20:52 +02:00
George Marques
107af38fd1
GDScript: Show error when missing expression after ternary else
2021-09-15 11:43:36 -03:00
George Marques
d49046938a
GDScript: Show error on unary operators without argument
2021-09-15 11:08:59 -03:00
George Marques
5d31ce4b16
GDScript: Allow string keys on Lua-style dictionaries
...
Which is useful when the key isn't a valid identifier, such as keys with
spaces or numeric keys.
2021-09-15 09:56:24 -03:00
Hugo Locurcio
c0083c0f90
Add dozens of new integration tests to the GDScript test suite
...
This also ignores `.out` files in the file format static checks.
2021-09-14 18:42:08 +02:00
ThreeRhinosInAnElephantCostume
2c71134aa4
Fix an undefined behaviour
2021-09-13 22:59:28 +02:00
George Marques
e9186cfebf
Fix GDScript test cases
2021-09-13 15:02:01 -03:00
Rémi Verschelde
0c2ab55a58
Merge pull request #52100 from vnen/gdscript-access-outer-constants
...
GDScript: Allow access to outer constant and enum values
2021-09-13 18:04:35 +02:00
Rémi Verschelde
4059cf2f02
Merge pull request #52068 from ThreeRhinosInAnElephantCostume/fixgdscript
...
Fix parse error on statement-less files with only newlines, add a warning for empty files.
2021-09-13 17:30:31 +02:00