Commit Graph

156 Commits

Author SHA1 Message Date
308d20aba5 added JSON singleton
There was no way to access JSON functionality in scripting languages
apart from GDScript because the JSON class wasn't exposed to ClassDB.
2017-09-15 15:40:27 +02:00
0fffa45158 Fix enums bindings
Add missed bindings for enums
Move some enums to class to have correct output of api.json
2017-09-13 20:57:07 +03:00
459f526119 Fix typos 'a' and 'an' 2017-09-02 21:19:06 +07:00
f9467ec1ea Fix signed and unsigned comparisons
The first in my quest to make Godot 3.x compile with -Werror on GCC7
2017-09-01 08:13:12 +02:00
bd282ff43f Use HTTPS URL for Godot's website in the headers 2017-08-27 14:16:55 +02:00
cacced7e50 Convert Object::cast_to() to the static version
Currently we rely on some undefined behavior when Object->cast_to() gets
called with a Null pointer. This used to work fine with GCC < 6 but
newer versions of GCC remove all codepaths in which the this pointer is
Null. However, the non-static cast_to() was supposed to be null safe.

This patch makes cast_to() Null safe and removes the now redundant Null
checks where they existed.

It is explained in this article: https://www.viva64.com/en/b/0226/
2017-08-24 23:08:24 +02:00
7f49e2a7a0 Merge pull request #10487 from marcelofg55/curscr_as_default
p_screen param from get_screen_* funcs now default to the current screen
2017-08-22 08:12:04 +02:00
df590fc2d3 Merge pull request #10340 from Rubonnek/remove-unnecessary-assignments
Removed unnecessary assignments
2017-08-22 00:58:12 +02:00
2cc8309249 Merge pull request #10351 from neikeq/enums-are-for-the-weak
ClassDB: Provide the enum name of integer constants
2017-08-21 19:56:08 -03:00
63f847b306 p_screen param from get_screen_* funcs now default to the current screen 2017-08-21 18:28:29 -03:00
738d2ab969 Removed unnecessary assignments 2017-08-21 15:15:55 -04:00
93f1fb1c2f Fixes for new two-dash long command line arguments
- Fixes some single-dash leftovers that were missed in the previous commit
- Reorder the help output for clarity, and document missing options
- Drop obsolete options: --noop, --pack, --editor-scene, --level, --import, --import-script, --no-quit
- Improve error message on malformed arguments and do not display help on error
- Always use long form of arguments when starting a new Godot process from C++, for clarity and easy grepping
- Cleanup obsolete code here and there
2017-08-21 08:09:22 +02:00
32dd9a9f66 ClassDB: Provide the enum name of integer constants 2017-08-20 22:07:43 +02:00
b9dcebb37c Revert "Second take at making command-line arguments more UNIX-like + main.cpp and help cleanup" 2017-08-19 17:47:27 -03:00
70b0857f6c Fixes for new two-dash long command line arguments
- Fixes some single-dash leftovers that were missed in the previous commit
- Reorder the help output for clarity, and document missing options
- Drop obsolete options: --noop, --pack, --editor-scene, --level, --import, --import-script, --no-quit
- Improve error message on malformed arguments and do not display help on error
- Cleanup obsolete code here and there
2017-08-19 16:48:11 +02:00
fd69604bd9 Adds editor_hint to Engine class 2017-08-19 01:03:12 +02:00
2f290038d6 Removes type information from method binds 2017-08-10 07:17:50 +02:00
5ae78fdf6a Makes all Godot API's methods Lower Case 2017-08-07 18:24:35 +07:00
2777f81d29 Add object type hint for docs 2017-07-23 18:57:03 +07:00
25678b1876 -Renamed GlobalConfig to ProjectSettings, makes more sense.
-Added system for feature overrides, it's pretty cool :)
2017-07-19 17:06:03 -03:00
49c7620326 Add object type hint for docs 2017-07-19 02:03:34 +07:00
0f765c86e5 Add GZIP compression support
- Fix a wrong call in PoolByteArray::compress
2017-07-13 14:41:10 -03:00
7358766ff6 IME window follow the input cursor.
Abstruct set_ime_position to OS class.
Update ime position for LineEdit and TextEdit.
2017-07-11 18:36:20 +08:00
5c779c574a Add compression support for File object 2017-06-19 16:38:37 -03:00
a81b706e09 Fixed thread check, solves: #3698 2017-06-13 17:49:28 +02:00
98a3296702 Removal of Image from Variant, converted to a Resource. 2017-05-17 07:37:45 -03:00
2398eb6ed4 Move core thirdparty files to thirdparty/{minizip,misc} 2017-04-28 21:19:23 +02:00
8589ca3903 Rename [gs]et_pos to [gs]et_position for Controls
Control set_pos -> set_position
Control set_global_pos -> set_global_position
[gs]et_mouse_pos -> [gs]et_mouse_position
[gs]et_global_mouse_pos -> [gs]et_global_mouse_position
fixes #8005
2017-04-10 08:27:34 +02:00
f29dc079dc Merge pull request #8333 from touilleMan/classdb-class_sget_property-binding
Add _ClassDB.class_[g|s]et_property to ClassDB exposed methods
2017-04-09 17:46:35 +02:00
42eba57bad Add return value in ClassDB.class_[g|s]et_property bindings 2017-04-09 14:04:01 +02:00
23c310be7b Add _ClassDB.class_[g|s]et_property to ClassDB exposed methods 2017-04-09 13:27:07 +02:00
df61dc4b2b Add "Godot Engine contributors" copyright line 2017-04-08 00:11:42 +02:00
6ab3213a55 fixed ClassDB inconsistencies
fixes #7960
2017-03-13 21:17:31 +01:00
5dbf1809c6 A Whole New World (clang-format edition)
I can show you the code
Pretty, with proper whitespace
Tell me, coder, now when did
You last write readable code?

I can open your eyes
Make you see your bad indent
Force you to respect the style
The core devs agreed upon

A whole new world
A new fantastic code format
A de facto standard
With some sugar
Enforced with clang-format

A whole new world
A dazzling style we all dreamed of
And when we read it through
It's crystal clear
That now we're in a whole new world of code
2017-03-05 16:44:50 +01:00
e6952cad3a Merge pull request #7950 from RandomShaper/expose-more-geom
Expose uncapped versions of closest-point-to-segment utilities
2017-03-05 12:04:23 +01:00
0e0b6ec443 Expose uncapped versions of closest-point-to-segment utilities 2017-03-04 23:02:27 +01:00
94103c0c02 Add API to access battery power state
Done:
- X11, server (tested)
- Windows (developed, would be nice to retest)
- OSX (not tested)
Prepared (not developed):
- Android (code is here, but may not compile)
- iphone
- winrt
- bb10
- haiku
- javascript
2017-03-04 18:04:29 +01:00
eaa6433b3b Expose Geometry::get_closest_point_to_segment_2d() 2017-03-04 01:55:12 +01:00
de0045cf1b -renamed globals.h to global_config.cpp (this seems to have caused a few modified files)
-.pck and .zip exporting redone, seems to be working..
2017-02-21 00:06:30 -03:00
411ee71b4d Rename the _MD macro to D_METHOD
This new name also makes its purpose a little clearer

This is a step towards fixing #56
2017-02-13 12:50:02 +01:00
a7b1f9ee5a corrected ClassDB::insatnce() return type 2017-01-30 14:13:13 +01:00
96de0141cc Removed import/export system, will start new one from scratch. 2017-01-25 21:57:08 -03:00
831d9b925a Merge pull request #7563 from RayKoopa/extended_list_dir_begin
Add parameters to Directory.list_dir_begin() to skip navigational or hidden entries
2017-01-25 20:22:34 +01:00
1ce9bbc8ed Added parameters to skip hidden and/or navigational file system entries 2017-01-24 21:07:02 +01:00
5ec0610c60 Add ClassDB binding for File.get_modified_time
Closes #7613
2017-01-23 22:33:58 +01:00
e2a3f06f3d Style: Keep long lines for now
clang-format does not play well with tab-aligned multiline statements...
Some more research will be needed if we want to set a column limit.
2017-01-16 08:48:24 +01:00
40323407df Style: No break before list brace
clang-format does not handle that well *at all*.

For the reference, found the relevant pieces of code with:
`ag "=[ "$'\t'"]?"$'\n'"[ "$'\t'"]?{" --ignore=thirdparty`
2017-01-16 08:48:24 +01:00
54b20874b6 Fix _Directory::get_current_drive error condition 2017-01-14 18:47:06 +01:00
ce99286362 Merge pull request #7524 from neikeq/pr-dir-getcurdrive
Directory: Bind get_current_drive() method
2017-01-14 17:22:06 +01:00
0b2ae7313b Directory: Bind get_current_drive() method 2017-01-14 17:20:16 +01:00