diff --git a/.gitignore b/.gitignore index f6ad7711d4ee..3979ae5edb02 100644 --- a/.gitignore +++ b/.gitignore @@ -21,6 +21,7 @@ project.properties platform/android/java/app/libs/* platform/android/java/libs/* platform/android/java/lib/.cxx/ +platform/android/java/nativeSrcsConfigs/.cxx/ # General c++ generated files *.lib diff --git a/core/array.cpp b/core/array.cpp index e488034c6aa7..14f75c8ea4c8 100644 --- a/core/array.cpp +++ b/core/array.cpp @@ -117,6 +117,11 @@ void Array::push_back(const Variant &p_value) { _p->array.push_back(p_value); } +void Array::append_array(const Array &p_array) { + + _p->array.append_array(p_array._p->array); +} + Error Array::resize(int p_new_size) { return _p->array.resize(p_new_size); diff --git a/core/array.h b/core/array.h index 63454420e215..910b231e7b4f 100644 --- a/core/array.h +++ b/core/array.h @@ -64,6 +64,7 @@ class Array { void push_back(const Variant &p_value); _FORCE_INLINE_ void append(const Variant &p_value) { push_back(p_value); } //for python compatibility + void append_array(const Array &p_array); Error resize(int p_new_size); void insert(int p_pos, const Variant &p_value); diff --git a/core/image.cpp b/core/image.cpp index 8cb95a8df802..674c3e997676 100644 --- a/core/image.cpp +++ b/core/image.cpp @@ -2335,6 +2335,7 @@ ImageMemLoadFunc Image::_png_mem_loader_func = NULL; ImageMemLoadFunc Image::_jpg_mem_loader_func = NULL; ImageMemLoadFunc Image::_webp_mem_loader_func = NULL; ImageMemLoadFunc Image::_tga_mem_loader_func = NULL; +ImageMemLoadFunc Image::_bmp_mem_loader_func = NULL; void (*Image::_image_compress_bc_func)(Image *, float, Image::CompressSource) = NULL; void (*Image::_image_compress_bptc_func)(Image *, float, Image::CompressSource) = NULL; @@ -2784,6 +2785,7 @@ void Image::_bind_methods() { ClassDB::bind_method(D_METHOD("load_jpg_from_buffer", "buffer"), &Image::load_jpg_from_buffer); ClassDB::bind_method(D_METHOD("load_webp_from_buffer", "buffer"), &Image::load_webp_from_buffer); ClassDB::bind_method(D_METHOD("load_tga_from_buffer", "buffer"), &Image::load_tga_from_buffer); + ClassDB::bind_method(D_METHOD("load_bmp_from_buffer", "buffer"), &Image::load_bmp_from_buffer); ADD_PROPERTY(PropertyInfo(Variant::DICTIONARY, "data", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_STORAGE), "_set_data", "_get_data"); @@ -3104,6 +3106,14 @@ Error Image::load_tga_from_buffer(const PoolVector &p_array) { return _load_from_buffer(p_array, _tga_mem_loader_func); } +Error Image::load_bmp_from_buffer(const PoolVector &p_array) { + ERR_FAIL_NULL_V_MSG( + _bmp_mem_loader_func, + ERR_UNAVAILABLE, + "The BMP module isn't enabled. Recompile the Godot editor or export template binary with the `module_bmp_enabled=yes` SCons option."); + return _load_from_buffer(p_array, _bmp_mem_loader_func); +} + Error Image::_load_from_buffer(const PoolVector &p_array, ImageMemLoadFunc p_loader) { int buffer_size = p_array.size(); diff --git a/core/image.h b/core/image.h index ace8e4730664..2fff89bc6e28 100644 --- a/core/image.h +++ b/core/image.h @@ -132,6 +132,7 @@ class Image : public Resource { static ImageMemLoadFunc _jpg_mem_loader_func; static ImageMemLoadFunc _webp_mem_loader_func; static ImageMemLoadFunc _tga_mem_loader_func; + static ImageMemLoadFunc _bmp_mem_loader_func; static void (*_image_compress_bc_func)(Image *, float, CompressSource p_source); static void (*_image_compress_bptc_func)(Image *, float p_lossy_quality, CompressSource p_source); @@ -333,6 +334,7 @@ class Image : public Resource { Error load_jpg_from_buffer(const PoolVector &p_array); Error load_webp_from_buffer(const PoolVector &p_array); Error load_tga_from_buffer(const PoolVector &p_array); + Error load_bmp_from_buffer(const PoolVector &p_array); Image(const uint8_t *p_mem_png_jpg, int p_len = -1); Image(const char **p_xpm); diff --git a/core/io/http_client.cpp b/core/io/http_client.cpp index 9614c0d1f911..f5ee5c24c8aa 100644 --- a/core/io/http_client.cpp +++ b/core/io/http_client.cpp @@ -749,7 +749,8 @@ HTTPClient::HTTPClient() { ssl = false; blocking = false; handshaking = false; - read_chunk_size = 4096; + // 64 KiB by default (favors fast download speeds at the cost of memory usage). + read_chunk_size = 65536; } HTTPClient::~HTTPClient() { diff --git a/core/math/random_number_generator.cpp b/core/math/random_number_generator.cpp index 1a1bffb56245..c6d8acf7daf4 100644 --- a/core/math/random_number_generator.cpp +++ b/core/math/random_number_generator.cpp @@ -35,7 +35,6 @@ RandomNumberGenerator::RandomNumberGenerator() {} void RandomNumberGenerator::_bind_methods() { ClassDB::bind_method(D_METHOD("set_seed", "seed"), &RandomNumberGenerator::set_seed); ClassDB::bind_method(D_METHOD("get_seed"), &RandomNumberGenerator::get_seed); - ADD_PROPERTY(PropertyInfo(Variant::INT, "seed"), "set_seed", "get_seed"); ClassDB::bind_method(D_METHOD("randi"), &RandomNumberGenerator::randi); ClassDB::bind_method(D_METHOD("randf"), &RandomNumberGenerator::randf); @@ -43,4 +42,8 @@ void RandomNumberGenerator::_bind_methods() { ClassDB::bind_method(D_METHOD("randf_range", "from", "to"), &RandomNumberGenerator::randf_range); ClassDB::bind_method(D_METHOD("randi_range", "from", "to"), &RandomNumberGenerator::randi_range); ClassDB::bind_method(D_METHOD("randomize"), &RandomNumberGenerator::randomize); + + ADD_PROPERTY(PropertyInfo(Variant::INT, "seed"), "set_seed", "get_seed"); + // Default value is non-deterministic, override it for doc generation purposes. + ADD_PROPERTY_DEFAULT("seed", 0); } diff --git a/core/math/transform_2d.cpp b/core/math/transform_2d.cpp index 953e5559e0f5..679c3a1ca001 100644 --- a/core/math/transform_2d.cpp +++ b/core/math/transform_2d.cpp @@ -257,7 +257,7 @@ Transform2D Transform2D::interpolate_with(const Transform2D &p_transform, real_t real_t dot = v1.dot(v2); - dot = (dot < -1.0) ? -1.0 : ((dot > 1.0) ? 1.0 : dot); //clamp dot to [-1,1] + dot = CLAMP(dot, -1.0, 1.0); Vector2 v; diff --git a/core/variant_call.cpp b/core/variant_call.cpp index d3ff10b1175f..0c8113423328 100644 --- a/core/variant_call.cpp +++ b/core/variant_call.cpp @@ -534,6 +534,7 @@ struct _VariantCall { VCALL_LOCALMEM0R(Array, pop_back); VCALL_LOCALMEM0R(Array, pop_front); VCALL_LOCALMEM1(Array, append); + VCALL_LOCALMEM1(Array, append_array); VCALL_LOCALMEM1(Array, resize); VCALL_LOCALMEM2(Array, insert); VCALL_LOCALMEM1(Array, remove); @@ -1799,6 +1800,7 @@ void register_variant_methods() { ADDFUNC1NC(ARRAY, NIL, Array, push_back, NIL, "value", varray()); ADDFUNC1NC(ARRAY, NIL, Array, push_front, NIL, "value", varray()); ADDFUNC1NC(ARRAY, NIL, Array, append, NIL, "value", varray()); + ADDFUNC1NC(ARRAY, NIL, Array, append_array, ARRAY, "array", varray()); ADDFUNC1NC(ARRAY, NIL, Array, resize, INT, "size", varray()); ADDFUNC2NC(ARRAY, NIL, Array, insert, INT, "position", NIL, "value", varray()); ADDFUNC1NC(ARRAY, NIL, Array, remove, INT, "position", varray()); diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml index 0e97a65d04dc..59de0b912b93 100644 --- a/doc/classes/@GlobalScope.xml +++ b/doc/classes/@GlobalScope.xml @@ -1174,10 +1174,10 @@ [codeblock] var err = method_that_returns_error() if err != OK: - print("Failure!) + print("Failure!") # Or, equivalent: if err: - print("Still failing!) + print("Still failing!") [/codeblock] diff --git a/doc/classes/Array.xml b/doc/classes/Array.xml index d0ea8d483f9c..02e98af4cc56 100644 --- a/doc/classes/Array.xml +++ b/doc/classes/Array.xml @@ -20,6 +20,7 @@ var array2 = [3, "Four"] print(array1 + array2) # ["One", 2, 3, "Four"] [/codeblock] + Note that concatenating with [code]+=[/code] operator will create a new array. If you want to append another array to an existing array, [method append_array] is more efficient. [b]Note:[/b] Arrays are always passed by reference. To get a copy of an array which can be modified independently of the original array, use [method duplicate]. @@ -95,6 +96,19 @@ Appends an element at the end of the array (alias of [method push_back]). + + + + + Appends another array at the end of this array. + [codeblock] + var array1 = [1, 2, 3] + var array2 = [4, 5, 6] + array1.append_array(array2) + print(array1) # Prints [1, 2, 3, 4, 5, 6]. + [/codeblock] + + diff --git a/doc/classes/CanvasItem.xml b/doc/classes/CanvasItem.xml index ab899dead153..376fb542dc5e 100644 --- a/doc/classes/CanvasItem.xml +++ b/doc/classes/CanvasItem.xml @@ -594,7 +594,7 @@ - Emitted when the item rect has changed. + Emitted when the item's [Rect2] boundaries (position or size) have changed, or when an action is taking place that may have impacted these boundaries (e.g. changing [member Sprite.texture]). diff --git a/doc/classes/Control.xml b/doc/classes/Control.xml index 95a1ac1baa76..e85c55893620 100644 --- a/doc/classes/Control.xml +++ b/doc/classes/Control.xml @@ -58,25 +58,26 @@ - + - Virtual method to be implemented by the user. Returns a [Control] node that should be used as a tooltip instead of the default one. Use [code]for_text[/code] parameter to determine what text the tooltip should contain (likely the contents of [member hint_tooltip]). - The returned node must be of type [Control] or Control-derieved. It can have child nodes of any type. It is freed when the tooltip disappears, so make sure you always provide a new instance, not e.g. a node from scene. When [code]null[/code] or non-Control node is returned, the default tooltip will be used instead. + Virtual method to be implemented by the user. Returns a [Control] node that should be used as a tooltip instead of the default one. The [code]for_text[/code] includes the contents of the [member hint_tooltip] property. + The returned node must be of type [Control] or Control-derived. It can have child nodes of any type. It is freed when the tooltip disappears, so make sure you always provide a new instance (if you want to use a pre-existing node from your scene tree, you can duplicate it and pass the duplicated instance).When [code]null[/code] or a non-Control node is returned, the default tooltip will be used instead. + The returned node will be added as child to a [PopupPanel], so you should only provide the contents of that panel. That [PopupPanel] can be themed using [method Theme.set_stylebox] for the type [code]"TooltipPanel"[/code] (see [member hint_tooltip] for an example). [b]Note:[/b] The tooltip is shrunk to minimal size. If you want to ensure it's fully visible, you might want to set its [member rect_min_size] to some non-zero value. - Example of usage with custom-constructed node: + Example of usage with a custom-constructed node: [codeblock] func _make_custom_tooltip(for_text): var label = Label.new() label.text = for_text return label [/codeblock] - Example of usage with custom scene instance: + Example of usage with a custom scene instance: [codeblock] func _make_custom_tooltip(for_text): - var tooltip = preload("SomeTooltipScene.tscn").instance() + var tooltip = preload("res://SomeTooltipScene.tscn").instance() tooltip.get_node("Label").text = for_text return tooltip [/codeblock] @@ -846,6 +847,15 @@ Changes the tooltip text. The tooltip appears when the user's mouse cursor stays idle over this control for a few moments, provided that the [member mouse_filter] property is not [constant MOUSE_FILTER_IGNORE]. You can change the time required for the tooltip to appear with [code]gui/timers/tooltip_delay_sec[/code] option in Project Settings. + The tooltip popup will use either a default implementation, or a custom one that you can provide by overriding [method _make_custom_tooltip]. The default tooltip includes a [PopupPanel] and [Label] whose theme properties can be customized using [Theme] methods with the [code]"TooltipPanel"[/code] and [code]"TooltipLabel"[/code] respectively. For example: + [codeblock] + var style_box = StyleBoxFlat.new() + style_box.set_bg_color(Color(1, 1, 0)) + style_box.set_border_width_all(2) + # We assume here that the `theme` property has been assigned a custom Theme beforehand. + theme.set_stylebox("panel", "TooltipPanel", style_box) + theme.set_color("font_color", "TooltipLabel", Color(0, 1, 1)) + [/codeblock] Distance between the node's bottom edge and its parent control, based on [member anchor_bottom]. diff --git a/doc/classes/EditorPlugin.xml b/doc/classes/EditorPlugin.xml index d53effe43940..bd6bb163e508 100644 --- a/doc/classes/EditorPlugin.xml +++ b/doc/classes/EditorPlugin.xml @@ -192,6 +192,19 @@ + Called by the engine when the 2D editor's viewport is updated. Use the [code]overlay[/code] [Control] for drawing. You can update the viewport manually by calling [method update_overlays]. + [codeblock] + func forward_canvas_draw_over_viewport(overlay): + # Draw a circle at cursor position. + overlay.draw_circle(overlay.get_local_mouse_position(), 64) + + func forward_canvas_gui_input(event): + if event is InputEventMouseMotion: + # Redraw viewport when cursor is moved. + update_overlays() + return true + return false + [/codeblock] @@ -200,6 +213,8 @@ + This method is the same as [method forward_canvas_draw_over_viewport], except it draws on top of everything. Useful when you need an extra layer that shows over anything else. + You need to enable calling of this method by using [method set_force_draw_over_forwarding_enabled]. @@ -226,6 +241,37 @@ [/codeblock] + + + + + + + Called by the engine when the 3D editor's viewport is updated. Use the [code]overlay[/code] [Control] for drawing. You can update the viewport manually by calling [method update_overlays]. + [codeblock] + func forward_spatial_draw_over_viewport(overlay): + # Draw a circle at cursor position. + overlay.draw_circle(overlay.get_local_mouse_position(), 64) + + func forward_spatial_gui_input(camera, event): + if event is InputEventMouseMotion: + # Redraw viewport when cursor is moved. + update_overlays() + return true + return false + [/codeblock] + + + + + + + + + This method is the same as [method forward_spatial_draw_over_viewport], except it draws on top of everything. Useful when you need an extra layer that shows over anything else. + You need to enable calling of this method by using [method set_force_draw_over_forwarding_enabled]. + + @@ -475,6 +521,7 @@ + Enables calling of [method forward_canvas_force_draw_over_viewport] for the 2D editor and [method forward_spatial_force_draw_over_viewport] for the 3D editor when their viewports are updated. You need to call this method only once and it will work permanently for this plugin. @@ -506,7 +553,7 @@ - Updates the overlays of the editor (2D/3D) viewport. + Updates the overlays of the 2D and 3D editor viewport. Causes methods [method forward_canvas_draw_over_viewport], [method forward_canvas_force_draw_over_viewport], [method forward_spatial_draw_over_viewport] and [method forward_spatial_force_draw_over_viewport] to be called. diff --git a/doc/classes/HTTPClient.xml b/doc/classes/HTTPClient.xml index fc9b07c19a45..623a5ce24768 100644 --- a/doc/classes/HTTPClient.xml +++ b/doc/classes/HTTPClient.xml @@ -9,6 +9,7 @@ A [HTTPClient] should be reused between multiple requests or to connect to different hosts instead of creating one client per request. Supports SSL and SSL server certificate verification. HTTP status codes in the 2xx range indicate success, 3xx redirection (i.e. "try again, but over here"), 4xx something was wrong with the request, and 5xx something went wrong on the server's side. For more information on HTTP, see https://developer.mozilla.org/en-US/docs/Web/HTTP (or read RFC 2616 to get it straight from the source: https://tools.ietf.org/html/rfc2616). [b]Note:[/b] When performing HTTP requests from a project exported to HTML5, keep in mind the remote server may not allow requests from foreign origins due to [url=https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS]CORS[/url]. If you host the server in question, you should modify its backend to allow requests from foreign origins by adding the [code]Access-Control-Allow-Origin: *[/code] HTTP header. + [b]Note:[/b] SSL/TLS support is currently limited to TLS 1.0, TLS 1.1, and TLS 1.2. Attempting to connect to a TLS 1.3-only server will return an error. https://docs.godotengine.org/en/3.2/tutorials/networking/http_client_class.html @@ -180,7 +181,7 @@ The connection to use for this client. - + The size of the buffer used and maximum bytes to read per iteration. See [method read_response_body_chunk]. diff --git a/doc/classes/HTTPRequest.xml b/doc/classes/HTTPRequest.xml index 41d7fc16f628..06a71f0df0c6 100644 --- a/doc/classes/HTTPRequest.xml +++ b/doc/classes/HTTPRequest.xml @@ -23,7 +23,7 @@ # Note: Don't make simultaneous requests using a single HTTPRequest node. # The snippet below is provided for reference only. var body = {"name": "Godette"} - var error = http_request.request("https://httpbin.org/post", [], true, HTTPClient.METHOD_POST, body) + error = http_request.request("https://httpbin.org/post", [], true, HTTPClient.METHOD_POST, body) if error != OK: push_error("An error occurred in the HTTP request.") @@ -65,6 +65,7 @@ texture_rect.texture = texture [/codeblock] [b]Note:[/b] When performing HTTP requests from a project exported to HTML5, keep in mind the remote server may not allow requests from foreign origins due to [url=https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS]CORS[/url]. If you host the server in question, you should modify its backend to allow requests from foreign origins by adding the [code]Access-Control-Allow-Origin: *[/code] HTTP header. + [b]Note:[/b] SSL/TLS support is currently limited to TLS 1.0, TLS 1.1, and TLS 1.2. Attempting to connect to a TLS 1.3-only server will return an error. https://docs.godotengine.org/en/3.2/tutorials/networking/http_request_class.html @@ -124,9 +125,9 @@ Maximum allowed size for response bodies. - + The size of the buffer used and maximum bytes to read per iteration. See [member HTTPClient.read_chunk_size]. - Set this to a higher value (e.g. 65536 for 64 KiB) when downloading large files to achieve better speeds at the cost of memory. + Set this to a lower value (e.g. 4096 for 4 KiB) when downloading small files to decrease memory usage at the cost of download speeds. The file to download into. Will output any received file into it. diff --git a/doc/classes/Image.xml b/doc/classes/Image.xml index 1526dba0fe2d..edc715622c55 100644 --- a/doc/classes/Image.xml +++ b/doc/classes/Image.xml @@ -333,6 +333,16 @@ Loads an image from file [code]path[/code]. See [url=https://docs.godotengine.org/en/3.2/getting_started/workflow/assets/importing_images.html#supported-image-formats]Supported image formats[/url] for a list of supported image formats and limitations. + + + + + + + Loads an image from the binary contents of a BMP file. + [b]Note:[/b] Godot's BMP module doesn't support 16-bit per pixel images. Only 1-bit, 4-bit, 8-bit, 24-bit, and 32-bit per pixel images are supported. + + diff --git a/doc/classes/LineEdit.xml b/doc/classes/LineEdit.xml index 18065ee48d4e..8fe8e9a71c8f 100644 --- a/doc/classes/LineEdit.xml +++ b/doc/classes/LineEdit.xml @@ -76,6 +76,13 @@ Returns the [PopupMenu] of this [LineEdit]. By default, this menu is displayed when right-clicking on the [LineEdit]. + + + + + Returns the scroll offset due to [member caret_position], as a number of characters. + + diff --git a/doc/classes/NinePatchRect.xml b/doc/classes/NinePatchRect.xml index f543d0e121e5..7667025433dc 100644 --- a/doc/classes/NinePatchRect.xml +++ b/doc/classes/NinePatchRect.xml @@ -32,10 +32,10 @@ - Doesn't do anything at the time of writing. + The stretch mode to use for horizontal stretching/tiling. See [enum NinePatchRect.AxisStretchMode] for possible values. - Doesn't do anything at the time of writing. + The stretch mode to use for vertical stretching/tiling. See [enum NinePatchRect.AxisStretchMode] for possible values. If [code]true[/code], draw the panel's center. Else, only draw the 9-slice's borders. @@ -69,13 +69,15 @@ - Doesn't do anything at the time of writing. + Stretches the center texture across the NinePatchRect. This may cause the texture to be distorted. - Doesn't do anything at the time of writing. + Repeats the center texture across the NinePatchRect. This won't cause any visible distortion. The texture must be seamless for this to work without displaying artifacts between edges. + [b]Note:[/b] Only supported when using the GLES3 renderer. When using the GLES2 renderer, this will behave like [constant AXIS_STRETCH_MODE_STRETCH]. - Doesn't do anything at the time of writing. + Repeats the center texture across the NinePatchRect, but will also stretch the texture to make sure each tile is visible in full. This may cause the texture to be distorted, but less than [constant AXIS_STRETCH_MODE_STRETCH]. The texture must be seamless for this to work without displaying artifacts between edges. + [b]Note:[/b] Only supported when using the GLES3 renderer. When using the GLES2 renderer, this will behave like [constant AXIS_STRETCH_MODE_STRETCH]. diff --git a/doc/classes/PacketPeerUDP.xml b/doc/classes/PacketPeerUDP.xml index e601ee464a54..b67de5e38ad9 100644 --- a/doc/classes/PacketPeerUDP.xml +++ b/doc/classes/PacketPeerUDP.xml @@ -25,7 +25,7 @@ Calling this method connects this UDP peer to the given [code]host[/code]/[code]port[/code] pair. UDP is in reality connectionless, so this option only means that incoming packets from different addresses are automatically discarded, and that outgoing packets are always sent to the connected address (future calls to [method set_dest_address] are not allowed). This method does not send any data to the remote peer, to do that, use [method PacketPeer.put_var] or [method PacketPeer.put_packet] as usual. See also [UDPServer]. - Note: Connecting to the remote peer does not help to protect from malicious attacks like IP spoofing, etc. Think about using an encryption technique like SSL or DTLS if you feel like your application is transferring sensitive information. + [b]Note:[/b] Connecting to the remote peer does not help to protect from malicious attacks like IP spoofing, etc. Think about using an encryption technique like SSL or DTLS if you feel like your application is transferring sensitive information. @@ -123,6 +123,18 @@ Waits for a packet to arrive on the listening port. See [method listen]. + [b]Note:[/b] [method wait] can't be interrupted once it has been called. This can be worked around by allowing the other party to send a specific "death pill" packet like this: + [codeblock] + # Server + socket.set_dest_address("127.0.0.1", 789) + socket.put_packet("Time to stop".to_ascii()) + + # Client + while socket.wait() == OK: + var data = socket.get_packet().get_string_from_ascii() + if data == "Time to stop": + return + [/codeblock] diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml index 824d5c868267..af935b1d61b2 100644 --- a/doc/classes/ProjectSettings.xml +++ b/doc/classes/ProjectSettings.xml @@ -447,19 +447,24 @@ Sets the window background to transparent when it starts. - Force the window to be always on top. + Forces the main window to be always on top. + [b]Note:[/b] This setting is ignored on iOS, Android, and HTML5. - Force the window to be borderless. + Forces the main window to be borderless. + [b]Note:[/b] This setting is ignored on iOS, Android, and HTML5. - Sets the window to full screen when it starts. + Sets the main window to full screen when the project starts. Note that this is not [i]exclusive[/i] fullscreen. On Windows and Linux, a borderless window is used to emulate fullscreen. On macOS, a new desktop is used to display the running project. + Regardless of the platform, enabling fullscreen will change the window size to match the monitor's size. Therefore, make sure your project supports [url=https://docs.godotengine.org/en/latest/tutorials/rendering/multiple_resolutions.html]multiple resolutions[/url] when enabling fullscreen mode. + [b]Note:[/b] This setting is ignored on iOS, Android, and HTML5. Sets the game's main viewport height. On desktop platforms, this is the default window size. Stretch mode settings also use this as a reference when enabled. Allows the window to be resizable by default. + [b]Note:[/b] This setting is ignored on iOS and Android. If greater than zero, overrides the window height when running the game. Useful for testing stretch modes. @@ -830,6 +835,8 @@ Specifies the maximum amount of log files allowed (used for rotation). + + Godot uses a message queue to defer some function calls. If you run out of space on it (you will see an error), you can increase the size here. @@ -1069,6 +1076,14 @@ Shaders have a time variable that constantly increases. At some point, it needs to be rolled back to zero to avoid precision errors on shader animations. This setting specifies when (in seconds). + + + + + + + + Choose between default mode where corner scalings are preserved matching the artwork, and scaling mode. Not available in GLES3 when [member rendering/batching/options/use_batching] is off. diff --git a/doc/classes/RandomNumberGenerator.xml b/doc/classes/RandomNumberGenerator.xml index 41c450f6fc8e..8925102694b8 100644 --- a/doc/classes/RandomNumberGenerator.xml +++ b/doc/classes/RandomNumberGenerator.xml @@ -74,9 +74,10 @@ - + The seed used by the random number generator. A given seed will give a reproducible sequence of pseudo-random numbers. [b]Note:[/b] The RNG does not have an avalanche effect, and can output similar random streams given similar seeds. Consider using a hash function to improve your seed quality if they're sourced externally. + [b]Note:[/b] The default value of this property is pseudo-random, and changes when calling [method randomize]. The [code]0[/code] value documented here is a placeholder, and not the actual default seed. diff --git a/doc/classes/Tabs.xml b/doc/classes/Tabs.xml index 026a3f022330..9e53745feffa 100644 --- a/doc/classes/Tabs.xml +++ b/doc/classes/Tabs.xml @@ -4,7 +4,7 @@ Tabs control. - Simple tabs control, similar to [TabContainer] but is only in charge of drawing tabs, not interact with children. + Simple tabs control, similar to [TabContainer] but is only in charge of drawing tabs, not interacting with children. diff --git a/editor/editor_inspector.cpp b/editor/editor_inspector.cpp index 0d8a1e3835ed..01498a69d77f 100644 --- a/editor/editor_inspector.cpp +++ b/editor/editor_inspector.cpp @@ -1480,9 +1480,9 @@ void EditorInspector::update_tree() { String group_base; VBoxContainer *category_vbox = NULL; - List - plist; + List plist; object->get_property_list(&plist, true); + _update_script_class_properties(*object, plist); HashMap item_path; Map section_map; @@ -1538,7 +1538,28 @@ void EditorInspector::update_tree() { category_vbox = NULL; //reset String type = p.name; - category->icon = EditorNode::get_singleton()->get_class_icon(type, "Object"); + if (!ClassDB::class_exists(type) && !ScriptServer::is_global_class(type) && p.hint_string.length() && FileAccess::exists(p.hint_string)) { + Ref