aboutsummaryrefslogtreecommitdiff
path: root/modules/gdscript (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Revert "Make inline blocks in GDScript more pythonic"Rémi Verschelde2017-04-081-9/+1
| | | | | This reverts commit 0c650c2511a69dc8af1069546aad4ff4d989923d. Fixes #8315.
* Add "Godot Engine contributors" copyright lineRémi Verschelde2017-04-0813-0/+13
|
* Add enum naming, by assinging a given enum's values to a DictBojidar Marinov2017-04-061-0/+20
| | | | (cherry picked from commit 88430f0962403779670c3e82bbbc3ef3f6022169)
* Adds enums to GDScriptBojidar Marinov2017-04-063-0/+87
| | | | | | Fixes #2966 (cherry picked from commit 4ee82a2c38c57fb980df1ed4727d47959ba9e983)
* Make inline blocks in GDScript more pythonicBojidar Marinov2017-03-241-1/+9
| | | | | | Fixes #8001 (cherry picked from commit 18ab88b3f1000cbcab5704402e402e1cdf65862f)
* Fix random crashes when using yield()Pedro J. Estébanez2017-03-211-1/+1
|
* Fixed typo in gdscript autocompletion.mbalint122017-03-191-1/+1
| | | | | | There was a missing '!' sign, but autocompletion shows parent script members too. (cherry picked from commit edaf77abd614d1260c6827f25045cc0473a08117)
* Bring that Whole New World to the Old Continent tooRémi Verschelde2017-03-1914-5234/+4703
| | | | | Applies the clang-format style to the 2.1 branch as done for master in 5dbf1809c6e3e905b94b8764e99491e608122261.
* Refactoring: rename tools/editor/ to editor/Rémi Verschelde2017-03-181-3/+3
| | | | | | | | The other subfolders of tools/ had already been moved to either editor/, misc/ or thirdparty/, so the hiding the editor code that deep was no longer meaningful. (Manual redo of 49c065d29ca07040c3fd810026121164ad86b247)
* Style: Various fixes to play nice with clang-formatRémi Verschelde2017-03-181-1/+1
| | | | (cherry picked from commit 2a0ddc1e89ec7b947152c8d0cb132d58f2c00a81)
* Style: Fix statements ending with ';;'Rémi Verschelde2017-03-183-3/+3
| | | | (cherry picked from commit f44ee891beaad397481dd88da41cb80e6539774f)
* Allow preload to accept a const string.Hein-Pieter van Braam2017-03-181-4/+25
| | | | | | | | | | | | | | In preload() parsing this code will lookup the identifier in the local constant database. If the identifier corresponds to a string constant it is used as the path for preload(). Currently this does not work for global constants, only constants declared in the same class as the preload is happening. We can implement a full fix too. Maybe we can use this PR to discuss the possibilities. This (partially) fixes #6798 (cherry picked from commit 3e5743ca3619d9767caeddac8520463db50291f6)
* Remove bounds check when resuming from yield.Hein-Pieter van Braam2017-03-181-1/+1
| | | | | | | | | | | | | | | | The code would get a pointer to the beginning of the call_args by using operator[] at the stack Vector. This does bound checking. When there are no call_args this bound check fails and the error mentioned in #7796 gets triggered. This bound check is actually not necessary as call_args just gets set to NULL and never dereferenced. This new code will just unconditionally set the pointer to the place where the call_args are if there are any. There is no NULL check for call_args anywhere so this is safe. Fixes #7796 (cherry picked from commit e8611966de4dfc9c28a7a4de1798f3f10ff87f80)
* Skip asserts on non-debug builds at compiler levelPedro J. Estébanez2017-03-131-0/+2
|
* Welcome in 2017, dear changelog reader!Rémi Verschelde2017-01-1213-13/+13
| | | | | | | | | | That year should bring the long-awaited OpenGL ES 3.0 compatible renderer with state-of-the-art rendering techniques tuned to work as low as middle end handheld devices - without compromising with the possibilities given for higher end desktop games of course. Great times ahead for the Godot community and the gamers that will play our games! (cherry picked from commit c7bc44d5ad9aae4902280012f7654e2318cd910e)
* Disallow assignment to expressionsBojidar Marinov2017-01-121-0/+9
| | | | | | | Fixes #6824 (cherry picked from commits 0b077162a32d37b81c302ab26523efda05de3913 and dcc4ee21c14c1d3fc40c2058e41f853e8ce989c6)
* Add named colors to GDScript/core.Bojidar Marinov2017-01-122-0/+38
| | | | | | Names and values taken from https://en.wikipedia.org/wiki/X11_color_names (cherry picked from commit 23381a530bb4a9c8e8c3e883a7d588bf832cd277)
* Ternary operator in GDScript (a if x else b)Bojidar Marinov2017-01-103-14/+125
| | | | Fixes #1961
* Allow for linebreaks in function calls and definitions and yeild/signal.Bojidar Marinov2017-01-101-2/+30
| | | | (Plus maybe a few other things)
* style: Fix PEP8 blank lines issues in Python filesRémi Verschelde2016-11-021-3/+0
| | | | | | | | | | | Done with `autopep8 --select=E3,W3`, fixes: - E301 - Add missing blank line. - E302 - Add missing 2 blank lines. - E303 - Remove extra blank lines. - E304 - Remove blank line following function decorator. - E309 - Add missing blank line. - W391 - Remove trailing blank lines.
* style: Start applying PEP8 to Python files, indentation issuesRémi Verschelde2016-11-021-2/+2
| | | | | | | | | | | | | | | | | | | Done with `autopep8 --select=E1`, fixes: - E101 - Reindent all lines. - E112 - Fix under-indented comments. - E113 - Fix over-indented comments. - E115 - Fix under-indented comments. - E116 - Fix over-indented comments. - E121 - Fix a badly indented line. - E122 - Fix a badly indented line. - E123 - Fix a badly indented line. - E124 - Fix a badly indented line. - E125 - Fix indentation undistinguish from the next logical line. - E126 - Fix a badly indented line. - E127 - Fix a badly indented line. - E128 - Fix a badly indented line. - E129 - Fix a badly indented line.
* Fixes #6487, GDscript compiler ignores OPCODE_LINE and OPCODE_BREAKPOINT in ↵yg2f2016-10-311-2/+4
| | | | | | | | | | | | | | Release mode When godot is in release mode, GDscript compiler does not generate bytecodes for OPCODE_LINE and OPCODE_BREAKPOINT anymore. This optimizes GDscript execution speed when the script contains a lot of comments in blocs executed in loops. Fixes #6487 (cherry picked from commit 217e09c79da008e15bd789260e8b2513689c90bd)
* SCsub: Add python shebang as a hint for syntax highlightingRémi Verschelde2016-10-301-0/+2
| | | | | | Also switch existing shebangs to "better" /usr/bin/env python. (cherry picked from commit fc8ccd5b8c8b779bffd0f4d7f22f2f964c939163)
* modules: Clone env in each moduleRémi Verschelde2016-10-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | This allows to pass include paths and flags only to a given thirdparty library, thus preventing conflicts between their files (e.g. between opus and openssl which both provide modes.h. This also has the nice effect of making the compilation command smaller for each module as it no longer related to all other modules, only the final linking brings them together. This however requires adding manually the ogg include path in opus and vorbis when building against the builtin ogg, since it is no longer in the global env. Also simplified template 'thirdparty_<module>_sources' to 'thirdparty_sources'. "Core" modules like cscript, gdscript, gridmap, ik and virtual_script still use the main env_modules, but it could be changed if need be. (cherry picked from commit da09c6131bcdace7e8e62c3dabc62890e9564c97) Obviously removed the parts about enet and visual_script.
* Adapt overlooked instances of zero-based column numbersPedro J. Estébanez2016-10-171-5/+5
| | | | (cherry picked from commit 1b3dcac28145bfc6cc1bf2327852209155f59082)
* Revert "Add warning when (pre)loading paths with leading / (#4280 - #3106)"Fabio Alessandrelli2016-10-172-12/+0
| | | | | | | | Also closes: #6801 This reverts commit e59820ac94b7c9706298d5559608937dfca332e5. (cherry picked from commit 11349a786be1fd02647493cfeff9883898ffd73e)
* Make text column numbers one-basedPedro J. Estébanez2016-10-171-1/+1
| | | | | | | | | | Make one-based the column number on the code editor Make one-based the column number for GDScript error messages Make one-based the column number for shader code error messages (cherry picked from commit 2f80965845dd40c4a7981b0d3f011f26c185d63f)
* i18n: Fix string that broke msgmergeRémi Verschelde2016-10-091-1/+1
| | | | (cherry picked from commit 2fb5a0030527ac04f1026d80bd8cf12ca3b3f38b)
* Throw an error when exporting a resource classFabio Alessandrelli2016-10-091-0/+10
| | | | | | | | | | "export var tex = Texture" will now throw an error to avoid crashing the editor: "Exported constant not a type or resource" Fixes #6719 . Closes #6729 (cherry picked from commit ee7df2c89ab0608c84f8c9390e1ed888dc1f805d)
* Add warning when (pre)loading paths with leading / (#4280 - #3106)Fabio Alessandrelli2016-10-092-1/+14
| | | | (cherry picked from commit e59820ac94b7c9706298d5559608937dfca332e5)
* Added constants from types in code completion, somehow this was never added.Juan Linietsky2016-09-181-1/+12
| | | | | | Stuff like Label.ALIGN_CENTER or Mesh.PRIMITIVE_TRIANGLES did not complete.. (cherry picked from commit b83350f4b2e968baac4d1551a6f21fe2e6b468ad)
* Clean up GDScript templateRăzvan Cosmin Rădulescu2016-09-181-7/+5
| | | | (cherry picked from commit 00e743b76ad89927d611f312cfc06d0511eac985)
* Fix #5891 by not expecting the script instance to be a GDInstanceBojidar Marinov2016-08-081-2/+1
| | | | | | It could be a placeholder instance as well (cherry picked from commit 76ea995228df510bfd4212e29f7cb76f13e25fb5)
* Document FuncRef, GDFunctionState, InstancePlaceholder, RID, World2Deska2016-07-301-1/+1
|
* Changed the way the step decimals are computed to a safer way, fixes many ↵Juan Linietsky2016-07-261-1/+1
| | | | issues.
* Set proper line into operators when parsing GDScript, fixes #5822Juan Linietsky2016-07-221-0/+11
|
* Fixed reloading of tool scripts within editor, they should work much better ↵Juan Linietsky2016-07-202-2/+22
| | | | now, closes #3194
* Forgot to clear signals on recompile, closes #5729Juan Linietsky2016-07-171-0/+1
|
* Allow semicolon after 'pass' keywordGeorge Marques2016-07-101-0/+4
|
* Revert removing of function call in gd_parserGeorge Marques2016-07-081-0/+1
| | | | | | The function call was removed in #5538 because of the unused return value, but the function itself has side effects and the absence of the call was causing crashes.
* Removed unused variables (first pass)Rémi Verschelde2016-07-075-58/+9
| | | | Fixes various gcc 5.4.0 warnings for -Wunused-variable and -Wunused-but-set-variable
* Merge pull request #5407 from RandomShaper/opt-self-indexingJuan Linietsky2016-07-011-3/+11
|\ | | | | Optimize member access with self
| * Optimize member access with selfPedro J. Estébanez2016-06-251-3/+11
| | | | | | | | Let the compiler take the fast path when a member is superfluously accessed with `self.`.
* | Only check for constants when parsing constants, should close #5497Juan Linietsky2016-06-302-20/+22
| |
* | Ability to put constants in constant expressions, closes #5264Juan Linietsky2016-06-291-0/+9
| |
* | Warn instad of crashing when class instance is gone after yield. Closes ↵Juan Linietsky2016-06-293-0/+30
| | | | | | | | #5247 , probably closes other yield related crashes
* | Properly show the source:line even in inner clases, closes #3766Juan Linietsky2016-06-282-1/+2
| |
* | Fix bug in inner class reference, closes #1411Juan Linietsky2016-06-281-4/+9
| |
* | Fixed bug related to resolving constants in a class, closes #1110Juan Linietsky2016-06-281-1/+1
| |
* | Fix extends issue, closes #4026Juan Linietsky2016-06-282-1/+7
| |