diff options
1142 files changed, 11139 insertions, 8534 deletions
@@ -18,6 +18,7 @@ Bastiaan Olij <mux213@gmail.com> Benjamin <mafortion.benjamin@gmail.com> Bernhard Liebl <Bernhard.Liebl@gmx.org> <poke1024@gmx.de> Bernhard Liebl <Bernhard.Liebl@gmx.org> <poke1024@gmx.org> +Bruno Lourenço <madequa@users.noreply.github.com> <bmlourenco@gmail.com> Chaosus <chaosus89@gmail.com> Chris Bradfield <chris@kidscancode.org> <cb@scribe.net> Clay John <claynjohn@gmail.com> diff --git a/.travis.yml b/.travis.yml index 7350849d6a..c8b123c79c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -94,7 +94,7 @@ matrix: - name: Linux export template (release_debug, GCC 5, without 3D support) stage: build - env: PLATFORM=x11 TOOLS=no TARGET=release_debug CACHE_NAME=${PLATFORM}-gcc-5 EXTRA_ARGS="disable_3d=yes" + env: PLATFORM=x11 TOOLS=no TARGET=release_debug CACHE_NAME=${PLATFORM}-gcc-5 EXTRA_ARGS="CXXFLAGS=-fno-strict-aliasing disable_3d=yes" os: linux compiler: gcc addons: diff --git a/AUTHORS.md b/AUTHORS.md index 4dfb97641a..8be2d05455 100644 --- a/AUTHORS.md +++ b/AUTHORS.md @@ -46,6 +46,7 @@ name is available. Bernard Liebl (poke1024) BÅ‚ażej SzczygieÅ‚ (zaps166) Bojidar Marinov (bojidar-bg) + Bruno Lourenço (MadEqua) bruvzg Cameron Reikes (creikey) Camille Mohr-Daurat (pouleyKetchoupp) @@ -56,6 +57,7 @@ name is available. Dana Olson (adolson) Daniel J. Ramirez (djrm) Daniel Rakos (aqnuep) + dankan1890 David Sichma (DavidSichma) Dharkael (lupoDharkael) Dmitry Koteroff (Krakean) @@ -64,6 +66,7 @@ name is available. Emmanuel Leblond (touilleMan) Eoin O'Neill (Eoin-ONeill-Yokai) Eric Lasota (elasota) + Eric Rybicki (ericrybick) Erik Selecký (rxlecky) est31 Fabian Mathews (supagu) diff --git a/CHANGELOG.md b/CHANGELOG.md index 060a270426..15a73f7021 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,731 @@ All notable changes to this project will be documented in this file. -The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). + +## [3.2] - 2020-01-29 + +### Added + +- Support for [pseudo-3D depth in 2D](https://godotengine.org/article/godot-32-will-get-pseudo-3d-support-2d-engine). +- Support for importing 3D scenes using Assimp. + - Many formats are supported, including FBX. +- [Support for generating audio procedurally and analyzing audio spectrums.](https://godotengine.org/article/godot-32-will-get-new-audio-features) +- WebRTC support. + - Includes support for the high-level multiplayer API. + - Supports NAT traversal using STUN or TURN. +- Support for automatically building Android templates before exporting. + - This makes 3rd-party SDK integration easier. +- Support for [texture atlases in 2D](https://godotengine.org/article/atlas-support-returns-godot-3-2). +- Major improvements to the visual shader system. ([News post 1](https://godotengine.org/article/major-update-for-visual-shader-in-godot-3-2), [News post 2](https://godotengine.org/article/major-update-visual-shaders-godot-3-2-part-2)) + - Redesigned visual shader editor with drag-and-drop capability. + - Textures can be dragged from the FileSystem dock to be added as nodes. + - Most functions available in GLSL are now exposed. + - Many constants such as `Pi` or `Tau` can now be used directly. + - Support for boolean uniforms and sampler inputs. + - New Sampler port type. + - New conditional nodes. + - New Expression node, allowing shader code to be written in visual shaders. + - Support for plugins (custom nodes). + - Custom nodes can be drag-and-dropped from the FileSystem dock. + - Ability to copy and paste nodes. + - Ability to delete multiple nodes at once by pressing <kbd>Delete</kbd>. + - The node creation menu is now displayed when dragging a connection to an empty space on the graph. + - GLES3-only functions are now distinguished from others in the creation dialog. + - Ability to preview the code generated by the visual shader. + - Ability to convert visual shaders to text-based shaders. + - See the [complete list of new functions](https://github.com/godotengine/godot/pull/26164). +- Improved visual scripting. + - Visual scripting now uses an unified graph where all functions are represented. + - Nodes can now be edited directly in the graph. + - Support for fuzzy searching. + - The `tool` mode can now be enabled in visual scripts. + - New Deconstruct node to deconstruct a complex value into a scalar value. + - Miscellaneous UI improvements. +- Support for enabling/disabling parts of the editor or specific nodes. + - This is helpful for education, or when working with artists to help prevent inadvertent changes. +- Language server for GDScript. + - This can be used to get better integration with external editors. +- Version control integration in the editor. + - This integration is VCS-agnostic (GDNative plugins provide specific VCS support). +- Improved GridMap editor. + - The copied mesh is now displayed during pasting. + - The duplication/paste indicator is now rotated correctly around the pivot point. + - Ability to cancel paste and selection by pressing <kbd>Escape</kbd>. + - Erasing is now done using <kbd>RMB</kbd> instead of <kbd>Shift + RMB</kbd>. + - Freelook can still be accessed by pressing <kbd>Shift + F</kbd>. +- Improved MeshLibrary generation. + - When appending to an existing MeshLibrary, previews are now only generated for newly-added or modified meshes. + - Tweaked the previews' camera angle and light directions for better results. + - Materials assigned to the MeshInstance instead of the Mesh are now exported to the MeshLibrary. + - This is useful when exporting meshes from an imported scene (such as glTF), as it allows materials to persist across re-imports. +- [Improved Control anchor and margin workflow.](https://github.com/godotengine/godot/pull/27559) +- [Network profiler.](https://github.com/godotengine/godot/pull/31870) +- Improved NavigationMesh generation. + - GridMaps can now be used to bake navigation meshes. + - EditorNavigationMeshGenerator can now be used in `tool` scripts. + - Support for generating navigation meshes from static colliders. + - When using static colliders as a geometry source, a layer mask can be specified to ignore certain colliders. + - The generator no longer relies on the global transform, making it possible to generate navmeshes on nodes that are not in the scene tree. + - Navigation gizmos are now updated after every new bake. +- Support for skinning in 3D skeletons. +- CameraServer singleton to retrieve images from mobile cameras or webcams as textures. +- A crosshair is now displayed when using freelook in the 3D editor. +- Project camera override button at the top of the 2D and 3D editors. + - When enabled, the editor viewport's camera will be replicated in the running project. +- RichTextLabel can now be extended with real-time effects and custom BBCodes. + - Effects are implemented using the ItemFX resource. +- `[img=<width>x<height>]` tag to resize an image displayed in a RichTextLabel. + - If `<width>` or `<height>` is 0, the image will be adjusted to keep its original aspect. +- Revamped node connection dialog for improved ease of use. +- The Signals dock now displays a signal's description in a tooltip when hovering it. +- Input actions can now be reordered by dragging them. +- Animation frames can now be reordered by dragging them. +- Ruler tool to measure distances and angles in the 2D editor. +- "Clear Guides" menu option in the 2D editor to remove all guides. +- The 2D editor grid now displays a "primary" line every 8 lines for easier measurements. + - This value can be adjusted in the Configure Snap dialog. +- Projects can now have a description set in the Project Settings. + - This description is displayed as a tooltip when hovering the project in the Project Manager. +- All Variant types can now be added as project settings using the editor (instead of just `bool`, `int`, `float` and `String`). +- Pressing <kbd>Ctrl + F</kbd> now focuses the search field in the Project Settings and Editor Settings. +- Quick Open dialog (<kbd>Shift + Alt + O</kbd>) to open any resource in the project. + - Unlike the existing dialogs, it's not limited to scenes or scripts. +- Ability to convert a Sprite to a Mesh2D, Polygon2D, CollisionPolygon2D or LightOccluder2D. +- MultiMeshInstance2D node for using MultiMesh in 2D. +- PointMesh primitive. + - Drawn as a rectangle with a constant size on screen, which is cheaper compared to using triangle-based billboards. +- 2D polygon boolean operations and Delaunay triangulation are now available in the Geometry singleton. +- [New convex decomposition](https://godotengine.org/article/godot-3-2-adds-support-convex-decomposition) using the [V-HACD](https://github.com/kmammou/v-hacd) library. + - Can decompose meshes into multiple convex shapes for increased accuracy. +- Support for grouping nodes in the 3D editor. +- "Slow" modifier in freelook (accessed by holding <kbd>Alt</kbd>). +- The 2D editor panning limits can now be disabled in the Editor Settings. +- "Undo Close Tab" option in the scene tabs context menu. +- The editor is now capped to 20 FPS when the window is unfocused. + - This decreases CPU/GPU usage if something causes the editor to redraw continuously (such as particles). +- The editor's FPS cap can now be adjusted in the Editor Settings (both when focused and unfocused). +- Version information is now displayed at the bottom of the editor. + - This is intended to make the Godot version easily visible in video tutorials. +- Support for constants in the shader language. +- Support for local and varying arrays in the shader language. +- Support for `switch` statements in the shader language. +- Support for `do {...} while (...)` loops in the shader language. + - Unlike `while`, the expression in the `do` block will always be run at least once. +- Support for hexadecimal number literals in the shader language. +- Ported several GLES3 shader functions such as `round()` to GLES2. +- `SHADOW_VEC` shader parameter to alter 2D shadow computations in custom shaders. +- Filter search box in the remote scene tree dock. +- Ability to expand/collapse nodes recursively in the scene tree dock by holding <kbd>Shift</kbd> and clicking on a folding arrow. +- Support for depth of field, glow and BCS in the GLES2 renderer. +- MSAA support in the GLES2 renderer. +- Ability to render viewports directly to the screen in the GLES2 renderer. + - This can be faster on low-end devices, but it comes at a convenience cost. +- Project settings to set the maximum number of lights and reflections in the GLES3 renderer. + - Decreasing these values can lead to faster shader compilations, resulting in lower loading times. +- Heightmap collision shape for efficient terrain collisions. +- AStar2D class, making A* use easier in 2D. +- Disabled collision shapes can now be added directly, without having to disable them manually after one step. +- Context menu options to close other scene tabs, scene tabs to the right, or all scene tabs. +- The audio bus volumes can now be snapped by holding <kbd>Ctrl</kbd> while dragging the slider. +- Hovering an audio bus' volume slider now displays its volume in a tooltip. +- Values in the Gradient and Curve editors can now be snapped by holding <kbd>Ctrl</kbd>. + - Precise snapping can be obtained by holding <kbd>Shift</kbd> as well. +- Support for snapping when scaling nodes in the 2D editor. +- Precise snapping in the 3D editor when holding <kbd>Shift</kbd>. +- "Align Rotation with View" in the 3D editor. + - Unlike "Align Transform with View", only the selected node's rotation will be modified. + - "Align Selection with View" has been renamed to "Align Transform with View". +- All 3D gizmos now make use of snapping if enabled. +- CSG shapes are now highlighted with a translucent overlay when selected. + - Shapes in Union mode will use a blue overlay color by default. + - Shapes in Subtraction mode will use an orange overlay color by default. + - Shapes in Intersection mode will use a white overlay color. +- Ability to move a vertex along a single axis when holding <kbd>Shift</kbd> in polygon editors. +- Support for binary literals in GDScript (e.g. `0b101010` for `42`). +- AutoLoads can now be used as a type in GDScript. +- Ability to define script templates on a per-project basis. + - Template files should be placed into a `script_templates/` directory in the project and have an extension that matches the language (`.gd` for GDScript, `.cs` for C#). + - The path to the script templates directory can be changed in the Project Settings. +- Ability to limit the minimum and maximum window size using `OS.set_min_window_size()` and `OS.set_max_window_size()`. +- `Node.process_priority` property to set or get a node's processing priority. + - This was previously only available as `Node.set_process_priority()` (without an associated getter). +- `Node.editor_description` property for documentation purposes. + - When hovering a node with a description in the scene tree dock, the description will be displayed in a tooltip. +- `Button.keep_pressed_outside` property to keep a button pressed when moving the pointer outside while pressed. +- `Button.expand_icon` property to make a button's icon expand/shrink with the button's size. +- `Popup.set_as_minsize()` method to shrink a popup to its minimum size. +- `Tree.get_icon_modulate()` and `Tree.set_icon_modulate()` methods to change an icon's color in a Tree. +- `Tree.call_recursive()` method to call a method on a TreeItem and its children recursively. +- `Light.use_gi_probe` property to exclude specific lights from GIProbe computations. +- TranslationServer method `get_loaded_locales()` to retrieve the list of languages with a translation loaded. +- `FRUSTUM` 3D camera mode to create tilted frustums for mirror or portal effects. +- `CanvasItem.draw_rect()` now has `width` and `antialiased` properties to match `draw_line()`'s functionality. +- `Engine.get_idle_frames()` and `Engine.get_physics_frames()` to get the number of idle and physics frame iterations since the project started. + - Unlike `Engine.get_frames_drawn()`, `Engine.get_idle_frames()` will be incremented even if the render loop is disabled. +- `Engine.get_physics_interpolation_fraction()` to get the fraction through the current physics tick at the time of the current frame. + - This can be used to implement fixed timestep interpolation. +- Support for shadow-to-opacity in 3D to render shadows in augmented reality contexts. +- Ability to change a Position2D gizmo's size. +- New Vector2 and Vector3 methods: + - `move_toward()` to retrieve a vector moved towards another by a specified number of units. + - `direction_to()` to retrieve a normalized vector pointing from a vector to another. + - This is a shorter alternative to `(b - a).normalized()`. +- AStar functions `set_point_disabled()` and `is_point_disabled()` to selectively disable points. +- Tween now emits a `tween_all_completed` signal when all tweens are completed. +- `Input.get_current_cursor_shape()` to retrieve the current cursor shape. +- `InputEventAction` now has a `strength` property to simulate analog inputs. +- `String.repeat()` method to repeat a string several times and return it. +- `String.count()` method to count the number of occurrences of a substring in a string. +- `String.humanize_size()` method to display a file size as an human-readable string. +- `String.strip_escapes()` to strip non-printable escape characters from a string, including tabulations and newlines (but not spaces). +- `String.sha1_text()` and `String.sha1_buffer()` methods to return a string's SHA-1 hash. +- Line2D `clear_points()` method to clear all points. +- Line2D now has a "Width Curve" property to make its width vary at different points. +- `assert()` now accepts an optional second parameter to display a custom message when the assertion fails. +- `posmod()` built-in GDScript function that behaves like `fposmod()`, but returns an integer value. +- `smoothstep()` built-in GDScript function for smooth easing of values. +- `lerp_angle()` built-in GDScript function to interpolate between two angles. +- `ord()` built-in GDScript function to return the Unicode code point of an 1-character string. +- `PoolByteArray.hex_encode()` method to get a string of hexadecimal numbers. +- `Font.get_wordwrap_string_size()` method to return the rectangle size needed to draw a word-wrapped text. +- `Camera.get_camera_rid()` method to retrieve a Camera's RID. +- `Array.slice()` method to duplicate a subset of an Array and return it. +- The GraphEdit box selection colors can now be changed by tweaking the `selection_fill` and `selection_stroke` theme items. +- Toggleable HSV mode for ColorPicker. +- ColorPicker properties to toggle the visibility and editability of presets. +- The default ColorPicker mode (RGB, HSV, RAW) can now be changed in the Editor Settings. +- ColorPicker now displays an indicator to denote "overbright" colors (which can't be displayed as-is in the preview). +- Hovering a Color property in the editor inspector now displays a tooltip with the exact values. +- `Color.transparent` constant (equivalent to `Color(1, 1, 1, 0)`). +- `KinematicBody.get_floor_normal()` and `KinematicBody2D.get_floor_normal()` to retrieve the collided floor's normal. +- `VehicleWheel.get_rpm()` method to retrieve a vehicle wheel's rotations per minute. +- Per-wheel throttle, brake and steering in VehicleBody. +- `GeometryInstance.set_custom_aabb()` to set a custom bounding box (used for view frustum culling). +- `FuncRef.call_funcv()` to call a FuncRef with an array containing arguments. + - In contrast to `FuncRef.call_func()`, only a single array argument is expected. +- `Mesh.get_aabb()` is now exposed to scripting. +- `PhysicalBone.apply_impulse()` and `PhysicalBone.apply_central_impulse()` methods to push ragdolls around. +- `ProjectSettings.load_resource_pack()` now features an optional `replace_files` argument (defaulting to `true`), which controls whether the loaded resource pack can override existing files in the virtual filesystem. +- `SpinBox.apply()` method to evaluate and apply the expression in the SpinBox's value immediately. +- `ConfigFile.erase_section_key()` method to remove a single key from a ConfigFile. +- `OS.execute()` now returns the process' exit code when blocking mode is enabled. +- `OS.is_window_focused()` method that returns `true` if the window is currently focused. + - Tracking the focus state manually using `NOTIFICATION_WM_FOCUS_IN` and `NOTIFICATION_WM_FOCUS_OUT` is no longer needed to achieve this. +- `OS.low_processor_mode_sleep_usec` is now exposed as a property. + - This makes it possible to change its value at runtime, rather than just defining it once in the Project Settings. +- `SceneTree.quit()` now accepts an optional argument with an exit code. + - If set to a value greater than or equal to 0, it will override the `OS.exit_code` property. +- `VisualServer.get_video_adapter_name()` and `VisualServer.get_video_adapter_vendor()` methods to retreive the user's graphics card model and vendor. +- `VisualServer.multimesh_create()` is now exposed to scripting. +- Ability to override how scripted objects are converted to strings by defining a `_to_string()` method. +- Export hints for 2D and 3D physics/render layers. +- Editor plugins can now add new tabs to the Project Settings. +- Standalone ternary expression warning in GDScript. +- Variable shadowing warning in GDScript. + - Will be displayed if: + - a block variable shadows a member variable, + - a subclass variable shadows a member variable, + - a function argument shadows a member variable. +- Script reflection methods are now exposed to GDScript. + - See `Script.get_script_property_list()`, `Script.get_script_method_list()`, `Script.get_script_signal_list()`, `Script.get_script_constant_map()` and `Script.get_property_default_value()`. +- `randfn(mean, deviation)` method to generate random numbers following a normal Gaussian distribution. +- Ability to read the standard error stream when using `OS.execute()` (disabled by default). +- Option to disable boot splash filtering (nearest-neighbor interpolation). +- The GridMap editor now offers a search field and size slider. +- DynamicFont resources now have a thumbnail in the editor. +- Minimap in the script editor. +- Bookmarks in the script editor for easier code navigation. +- Filter search box for the script list and member list. +- Singletons and `class_name`-declared classes are now highlighted with a separate color in the script editor. +- The editor help now displays class properties' default and overridden values. +- The script editor's Find in Files dialog can now search in user-defined file types (`editor/search_in_file_extensions` in the Project Settings). +- The script editor search now displays the number of matches. +- The script editor search now selects the current match for easier replacing. +- "Evaluate Expression" contextual option in the script editor. + - This option evaluates the selected expression and replaces it (e.g. `2 + 2` becomes `4`). +- Autocompletion support for `change_scene()`. +- Ability to skip breakpoints while debugging. +- Drag-and-drop support in the TileSet editor. +- Ability to attach scripts to nodes by dragging a name from the script list to a node in the scene tree. +- Icons are now displayed next to code completion items, making their type easier to distinguish. +- TileMap property `centered_textures` can be used to center textures on their tile, instead of using the tile's top-left corner as position for the texture. +- "Ignore" flag to ignore specific tiles when autotiling in the TileMap editor. +- Keyboard shortcuts to rotate tiles in the TileMap editor. + - Default shortcuts are <kbd>A</kbd> (rotate left), <kbd>S</kbd> (rotate right), <kbd>X</kbd> (flip horizontally), <kbd>Y</kbd> (flip vertically). +- Ability to keep a node's local transform when reparenting it by holding <kbd>Shift</kbd>. +- Basis constants `IDENTITY`, `FLIP_X`, `FLIP_Y`, `FLIP_Z`. +- Ability to create sprite frames in AnimatedSprite from a sprite sheet. +- `frame_coords` property in Sprite and Sprite3D to set/get the coordinates of the frame to display from the sprite sheet. +- `billboard` property in Sprite3D. +- Reimplemented support for editing multiple keys at once in the animation editor. +- Support for FPS snapping in the Animation editor. +- Autokeying in the Animation editor. + - Keyframes will be created automatically when translating, rotating or scaling nodes if a track exists already. + - Keys must be inserted manually for the first time. +- AnimationNodeBlendTreeEditor improvements. + - Ability to exclude multiple selected nodes at once. + - Context menu to add new nodes (activated by right-clicking). +- The AnimationPlayer Call Method mode is now configurable. + - Method calls can be "deferred" or "immediate", "deferred" being the default. +- OccluderPolygon2D is now draggable in the editor. +- The tooltip position offset is now configurable. +- The default cursor used when hovering RichTextLabels can now be changed. +- "Dialog Autowrap" property in AcceptDialog to wrap the label's text automatically. +- The 2D editor's panning shortcut can now be changed. +- The shortcuts to quit the editor can now be changed. +- Support for emission masks in CPUParticles2D. +- `direction` property in CPUParticles and ParticlesMaterial. +- `lifetime_randomness` property in CPUParticles and ParticlesMaterial. +- CPUParticles now uses a different gizmo icon to distinguish them from Particles. +- "Restart" button to restart particle emission in the editor. +- AnimatedSprites' animations can now be played backwards. +- TextureRects can now have their texture flipped horizontally or vertically. +- StyleBoxFlat shadows can now have an offset. +- StyleBoxFlat now computes UV coordinates for its `canvas_item` vertices, which can be used in custom shaders. +- Profiler data can now be exported to a CSV file. +- The 2D polygon editor now displays vertex numbers when hovering vertices. +- RectangleShapes now have a third handle to drag both axes at once. +- Global class resources are now displayed in the Resource property inspector. +- Double-clicking an easing property in the inspector will now make the editor display a numeric field. + - This makes it easier to enter precise values for properties such as light attenuation. +- `interface/editor/default_float_step` editor setting to configure floating-point values' default step in the Inspector. +- Audio buses are now stylized to look like boxes that can be dragged. +- The default audio bus layout file path can now be changed in the Project Settings. +- The LineEdit and TextEdit controls now display their contextual menu when pressing the <kbd>Menu</kbd> key. +- `shortcut_keys_enabled` and `selecting_enabled` LineEdit and TextEdit properties to disable keyboard shortcuts and selecting text. +- The LineEdit "disabled" font color can now be changed. +- The TextEdit "readonly" font color can now be changed. +- LineEdit can now have its `right_icon` set in scripts. +- The `nine_patch_stretch` TextureProgress property now enables stretching when using a radial fill mode. +- Support for loading and saving encrypted files in ConfigFile. +- `get_path()` and `get_path_absolute()` are now implemented in FileAccessEncrypted. +- "Disabled" attenuation model for AudioStreamPlayer3D, making the sound not fade with distance while keeping it positional. +- AudioEffectPitchShift's FFT size and oversampling are now adjustable. +- TextEdit's tab drawing and folding is now exposed to GDScript. +- Orphan node monitor in the Performance singleton. + - Counts the number of nodes that were created but aren't instanced in the scene tree. +- Ability to change eye height in VR. +- CSV files can now be imported as non-translation files. +- Scene resources such as materials can now be imported as `.tres` files. +- Support for importing 1-bit, 4-bit and 8-bit BMP files. + - Size dimensions must be a multiple of 8 for 1-bit images and 2 for 4-bit images. +- `use_lld=yes` flag to link with [LLD](https://lld.llvm.org/) on Linux when compiling with Clang. + - This results in faster iteration times when developing Godot itself or modules. +- `use_thinlto=yes` flag to link with [ThinLTO](https://clang.llvm.org/docs/ThinLTO.html) when using Clang. +- Multicast support in PacketPeerUDP. +- `NetworkedMultiplayerEnet.server_relay` property to disable server relaying. + - This can be used to increase security when building a fully-authoritative server. +- Automatic timeout for TCP connections (defaults to 30 seconds, can be changed in the Project Settings). +- `HTTPRequest.timeout` property (defaults to 0, which is disabled). +- `HTTPRequest.download_chunk_size` property. + - This value can be adjusted to reduce the allocation overhead and file writes when downloading large files. + - The default value was increased for faster downloads (4 KB → 64 KB). +- WebSocket improvements. + - Support for SSL in WebSocketServer. + - WebSocketClient can now use custom SSL certificates (except on HTML5). + - WebSocketClient can now define custom headers. +- The editor now features a built-in Web server for testing HTML5 projects. +- Button to remove all missing projects in the Project Manager. +- Reimplemented support for embedding project data in the PCK file. +- Ability to take editor screenshots by pressing <kbd>Ctrl + F12</kbd>. +- Editor plugins can now set the current active editor as well as toggle the distraction-free mode. +- **Android:** [Support for adaptive icons.](https://docs.godotengine.org/en/latest/getting_started/workflow/export/exporting_for_android.html#providing-launcher-icons) + - All icon densities are now generated automatically by the exporter. + - Only 3 images now need to be supplied to support all icon formats and densities (legacy icon, adaptive foreground, adaptive background). +- **Android:** Support for the Oculus Mobile SDK. +- **Android:** Support for requesting permissions at runtime. +- **Android:** `NOTIFICATION_APP_PAUSED` and `NOTIFICATION_APP_RESUMED` notifications are now emitted when the app is paused and resumed. +- **Android:** Support for pen input devices. +- **Android/iOS:** Support for vibrating the device. +- [**HTML5:** Partial clipboard support.](https://github.com/godotengine/godot/pull/29298) +- **iOS:** Support for [ARKit](https://developer.apple.com/augmented-reality/). +- **iOS:** `OS.get_model_name()` now returns a value with the device name. +- **iOS:** The Home indicator is now hidden by default to avoid being in the way of the running project. + - It can be restored in the Project Settings. +- **Windows:** Ability to toggle the console window in the Editor Settings. +- **Windows:** Project setting to enable Vsync using the compositor (DWM), disabled by default. + - On some hardware, this may fix stuttering issues when running a project in windowed mode. +- **Windows:** Support for code signing using `signtool` on Windows and `osslsigncode` on other platforms. +- **Windows:** Support for using Clang and ThinLTO when compiling using MinGW. +- **Windows/macOS:** `OS.set_native_icon()` method to set an `.ico` or `.icns` window/taskbar icon at runtime. +- **Windows/macOS/X11:** Support for graphic tablet pen pressure and tilt in InputEventMouseMotion. +- **macOS:** LineEdit now supports keyboard shortcuts commonly available on macOS. +- **macOS:** Multiple instances of the editor can now be opened at once. +- **macOS:** Recent and favorite projects are now listed in the project manager dock menu. +- **macOS:** The list of open scenes is now displayed in the editor dock menu. +- **macOS:** Support for modifying global and dock menus. +- **macOS:** Improved support for code signing when exporting projects. +- **macOS:** Support for defining camera and microphone usage descriptions when exporting a project. +- **macOS/X11:** [A zsh completion file for the editor is now available.](https://github.com/godotengine/godot/blob/master/misc/dist/shell/_godot.zsh-completion) +- **X11:** The instance PID is now set as the `_NET_WM_PID` window attribute, so that external programs can easily access it. +- **Mono:** Support for exporting to Android and HTML5. +- **Mono:** Support for using Rider as an external editor. +- **Mono:** Support for attaching external profilers like dotTrace using the `MONO_ENV_OPTIONS` environment variable. +- **Mono:** New DynamicGodotObject class to access dynamic properties from scripts written in GDScript. +- **Mono:** Support for resource type hints in exported arrays. +- **Mono:** New `mono/unhandled_exception_policy` project setting to keep running after an unhandled exception. +- [**Mono:** New Godot constants to conditionally react to system variables at compile-time.](https://github.com/godotengine/godot/pull/28786) +- **Mono:** Support for Visual Studio 2019's MSBuild. + +### Changed + +- Tween and Timer now display an error message if they are started without being added to the scene tree first. +- Tweaked Timer's wait time property hint to allow values with 3 decimals and above 4096. +- Functions called from a signal can no longer disconnect the node from the signal they're connected to (unless using `call_deferred()`). +- Tabs and space indentation can no longer be mixed in the same GDScript file. + - Each file must now use only tabs or spaces for indentation (not both). +- `assert()` in GDScript must now always be used with parentheses. + - `assert(true)` is still valid, but `assert true` isn't valid anymore. + - This is to account for the optional second parameter that defines a custom message. +- The "Trim" and "Normalize" WAV import options are now disabled by default. + - This makes the default behavior more consistent with Ogg import. +- Ogg samples now have an icon in the editor, like WAV samples. +- Camera2D drag margins are now disabled by default. + - If porting a project from Godot 3.1 where drag margins were used, these must be enabled manually again. +- `Camera.project_position()` now requires a second `depth` argument to determine the distance of the point from the camera. + - To get the old behavior back, pass the Camera's `near` property value as the second argument. +- `Skeleton.set_bone_global_pose()` was replaced by `Skeleton.set_bone_global_pose_override()`. +- UDP broadcasting is now disabled by default and must be enabled by calling `set_broadcast_enabled(true)` on the PacketPeerUDP instance. +- The editor and project manager now open slightly faster. +- Improved the Project Manager user interface. + - New, simpler design with more space available for the project list. + - Improved reporting of missing projects. + - The search field is now focused when starting the Project Manager if there is at least one project in the list. + - The search field now searches in both the project name and path. + - If the search term contains a `/`, the whole path will be used to match the search them. Otherwise, only the last path component will be searched in. +- Refactored the Project Manager to be more efficient, especially with large project lists. +- Images in the Project Manager and Asset Library are now resized with Lanczos filtering for a smoother appearance. +- The editor now uses the font hinting algorithm that best matches the OS' default. + - Hinting is set to "None" on macOS, and set to "Light" on Windows and Linux. + - This can be changed in the Editor Settings. +- The editor window dimming when a popup appears is now less intense (60% → 50%). + - The animation was also removed as it made the editor feel sluggish at lower FPS. +- Several editor menus have been reorganized for consistency and conciseness. +- Undo/Redo now supports more actions throughout the editor. +- Increased the height of the ItemList editor popup. + - This makes it easier to edit large amounts of items. +- Opening a folder in FileDialog will now scroll back to the top. +- Folder icons in FileDialog can now be displayed with a different color using the `folder_icon_modulate` constant, making them easier to distinguish from files. + - Folder icons in editor file dialogs are now tinted with the accent color. +- Improved colors in the light editor theme for better readability and consistency. +- Improved A* performance significantly by using a binary heap and OAHashMap. +- Tweaked the AABB transform algorithm to be ~1.2 times faster. +- Optimized the variant reference function, making complex scripts slightly faster. +- Disabled high-quality voxel cone tracing by default. + - This makes GIProbe much faster out of the box, at the cost of less realistic reflections. +- Lowered the default maximum directional shadow distance (200 → 100). + - This makes directional shadow rendering consistent between the editor and running project when using the default Camera node settings. +- Tweaked the default depth fog maximum distance to be independent of the Camera's `far` value (0..100). + - This makes fog display consistent between the editor and a running project. +- Tweaked the default height fog values to be more logical (0..100 → 10..0). + - This means height fog will be drawn from top-to-bottom, instead of being drawn from bottom-to-top. +- Significantly improved SSAO performance by using a lower sample count. + - SSAO now uses 3×3 blurring by default, resulting in less visible noise patterns. +- When "Keep 3D Linear" is enabled, colors are no longer clamped to [0, 1] when using Linear tonemapping. + - This allows rendering HDR values in floating-point texture targets for further processing or saving HDR data into files. +- The lightmap baker now calculates lightmap sizes dynamically based on surface area. +- Improved 3D KinematicBody performance and reliability. +- Orbiting in the 3D editor can now be done while holding <kbd>Alt</kbd>, for better compatibility with graphics tablets. +- Keys and actions are now released when the window loses focus. +- Tweens can now have a duration of 0. +- Particles and CPUParticles' Sphere emission shape now uses an uniform density sphere. +- `Viewport.size_override_stretch` is now exposed as a property (rather than just setter/getter methods). +- One-click deploy to Android now requires just one click if only one device is connected. +- The Project Manager will now infer a project name from the project path if the name was left to the default value. +- The WebSockets implementation now uses the smaller [wslay](https://tatsuhiro-t.github.io/wslay/) library instead of libwebsockets. +- Box selections in the editor now use a subtle outline for better visibility. +- Most 2D lines are now antialiased in the editor. +- CheckButtons now use a simpler design in the editor. +- Messages originating from the editor are now faded in the editor log. + - This makes messages printed by the project stand out more. +- Folding arrows in the editor inspector are now displayed at the left for consistency with other foldable elements. +- Hovering or dragging guides in the 2D editor will now turn the cursor into a "resizing" shape. +- The editor update spinner is now hidden by default. + - It can be enabled again in the Editor Settings. +- The "Update Always" option is now editor-wide instead of being project-specific. +- ColorPicker, OptionButton and MenuButton now use toggle mode, making them appear pressed when clicked. +- The ColorPicker preview was moved below the picker area to be closer to the sliders. +- Increased the Light2D height range from -100..100 to -2048..2048. + - Lower and higher values can be entered manually too. +- Decreased the `rotation_degrees` range in various nodes to -360..360 to be easier to adjust using the slider. + - Lower and higher values can still be entered manually, which is useful for animation purposes. +- The default RichTextLabel color is now `#ffffff`, matching the default Label color for better consistency. +- SpinBoxes now calculate the entered value using the Expression class. + - For example, writing `2 + 2` in a SpinBox then pressing Enter will result in `4`. +- Saved resources no longer contain dependency indices and metadata such as node folding, resulting in more VCS-friendly files. +- The script editor's line length guideline is now enabled by default. +- The script editor state (such as breakpoints or the current line) is now preserved across editor sessions. +- The script editor's "Auto Brace Complete" setting is now enabled by default. +- The scripts panel toggle button is now located at the bottom-left of the script editor (instead of the File menu). +- Editor plugins can now be enabled without having an init script defined. +- Custom nodes added by plugins now have a translucent script icon in the scene tree dock. +- `EditorInterface.get_current_path()` to get the full path currently displayed in the FileSystem dock in an editor plugin. +- Copy constructors are now allowed for built-in types in GDScript. + - This allows constructs such as `Vector2(Vector2(12, 34))`, which may be useful to simplify code in some cases. +- `weakref(null)` is now allowed in GDScript. + - This makes checking for a valid reference more concise, as `if my_ref.get_ref()` is now sufficient (no need for `if my_ref and my_ref.get_ref()`). +- The number of signal connections and groups is now displayed in a tooltip when hovering the associated buttons in the scene tree dock. +- The right mouse button can now be used to pan in the 2D editor. + - This is to improve usability when using a touchpad. + - The middle mouse button can still be used to pan in the 2D editor. +- Zooming is now allowed while panning in the 2D editor. +- When the "Scroll To Pan" editor setting is enabled, the 2D editor can now be zoomed in by holding <kbd>Ctrl</kbd> and scrolling the mouse wheel. +- Zoom percentages in the 2D editor are now relative to the editor scale if the editor scale is higher than 100%. +- The 2D editor now displays the current zoom percentage. + - The zoom percentage can be clicked to reset the zoom level to 100%. +- Improved sorting options in the Asset Library. +- Images now load faster in the Asset Library. +- A loading placeholder is now displayed while icons are loading in the Asset Library. +- Images failing to load in the Asset Library display a "broken file" icon. +- Improved the Asset Library page loading transitions. +- Tweaked the Asset Library detail page layout for better readability. +- Audio mixer faders now use a non-linear algorithm to better fit human hearing. +- Tooltips now appear faster when hovering elements in the editor (0.7 seconds → 0.5 seconds). +- Increased the low-processor usage mode's default maximum refresh rate (125 FPS → 144 FPS). + - This makes the editor feel slightly smoother on 144 Hz displays. +- Tree scrolling when dragging now uses a larger drag margin, making drag-and-drop more convenient. +- Holding <kbd>Ctrl</kbd> now toggles snapping in GraphEdit. +- Improved the timeline's appearance in the animation editor. +- Improved snapping in the animation editor. + - Snapping can be toggled temporarily by holding the <kbd>Ctrl</kbd> key. + - Snapping can be made more precise by holding the <kbd>Shift</kbd> key. + - Timeline snapping is now toggled by the Snap setting (like when moving keyframes). +- Keyframes are now easier to select in the animation editor. +- Selected keyframes now appear slightly larger in the animation editor. +- Boolean and color keyframe icons are now aligned to other keyframes in the animation editor. +- The Animation editor's line widths are now resized to match the editor scale. +- BPTC compression is now available for all HDR image formats. +- `Image.save_exr()` to save an image in EXR format, which supports high bit depths. +- Improved path and polygon editors. + - New handle icons for path and polygon points. + - Smooth path point and curve tangents now use different icons to be distinguished from sharp points. + - Tangent lines are now gray in the Path2D and Path editors. + - Path2D lines are now antialiased. +- Increased the TileSet and polygon UV editor's maximum zoom levels (400% → 1600%). +- Decreased the maximum allowed StyleBoxFlat corner detail (128 → 20). + - This prevents slowness and glitches caused by using overly detailed corners. +- 3D collision shapes and RayCasts are now drawn in gray when disabled. +- Improved RayCast2D and one-way collision drawing. + - Disabled RayCast2Ds are now displayed in gray. + - One-way collision arrows are now orange by default, making them easier to distinguish them from RayCast2Ds. + - Tweaked RayCast2D and one-way collision line shapes to look more like arrows. +- Improved rendering in the curve editor. + - The grid is now rendered correctly when using a light theme. + - The main line and edge line colors have been swapped for better visibility. + - Tangent line widths are now resized to match the editor scale. +- Improved rendering in the performance monitor. + - Dark colors are now used on light backgrounds for better visibility. + - Graph lines are now thinner and opaque. + - Graph line widths are now resized to match the editor scale. + - Rounded values now display trailing zeroes to make their precision clearer. +- TileMap support for transform operations on cell textures bigger than the cell size has been reworked to properly support isometric tiles. + - Breaks compatibility with some TileMaps from previous Godot versions. An opt-in `compatibility_mode` property can be used to restore the previous behavior. +- Some TileMap editor options were moved to the toolbar. +- The TileMap editor now displays coordinate information in the 2D viewport's bottom-left corner. + - This fixes the TileMap editor width changing when hovering tiles in a small window. +- Brackets are now only inserted when necessary when autocompleting methods in the script editor. +- Improved dialogs when saving or removing an editor layout. +- Whitespace-only selections no longer cause the script editor to highlight all occurrences. +- Saving a script will now add a newline at the end of file if none was present already. +- Reorganized sections in the editor help to be in a more logical order. +- The editor help now uses horizontal margins if the screen is wide enough. + - This makes sure lines keep a reasonable length for better readability. +- Increased line spacing in the editor help and asset library descriptions. +- The editor help now displays bold text using a bold font (instead of using a monospace font). +- The editor help now displays code using a slightly different color to be easier to distinguish. +- The editor help now displays types after parameter names to follow the GDScript static typing syntax. +- Editor help is now accessed using <kbd>Shift + F1</kbd>, for consistency with other applications. + - Contextural help is now accessed using <kbd>Alt + F1</kbd> to accommodate for this change. +- The script editor's Find in Files dialog is now always available, even when no script is opened. +- Pressing <kbd>Shift + Enter</kbd> in the script editor Find dialog will now go to the previous match. +- Improved the node deletion confirmation message. + - If there is only one node to delete, its name is displayed in the message. + - If there is more than one node to delete, the number of nodes to delete is displayed. +- Improved the "Snap Object to Floor" functionality in the 3D editor. + - An error message is now displayed if no nodes could be snapped. + - Increased the maximum snapping height (10 → 20). + - Increased the maximum snapping tolerance (0.1 → 0.2). +- 2D/3D selections, rotations and selected texts are now highlighted with the editor theme's accent color. +- 3D light gizmos are now tinted using the light's color, making navigation easier while using the unshaded display mode. +- Improved the 3D light and AudioStreamPlayer3D gizmos to better represent their depth in the 3D world. +- Tweaked the 3D manipulator gizmo's colors for better visibility. +- Tweaked the 2D and 3D axis colors for consistency with gizmo colors. +- Increased the default 3D manipulator gizmo opacity (0.2 → 0.4). +- The multiline text editor popup dialog's width is now capped on large displays. + - This prevents lines from becoming very long, which could hamper text readability. +- Non-printable escape characters are now stripped when pasting text into a LineEdit. +- The TextEdit caret color now matches the default font color, making it easier to see. +- Empty exported NodePath properties now return `null` instead of `self`. +- Built-in scripts are no longer allowed to use `class_name` as it wasn't working properly. +- The second parameter of `substr()` is now optional and defaults to `-1`. +- More editor actions can now have shortcuts assigned (such as Revert Scene or Export). +- The project export path may now be written in a relative path. + - Directories will be created recursively if the target directory doesn't exist. +- Items in the FileSystem dock can now be deselected by clicking empty space. +- "Set as Main Scene" context option for scenes in the FileSystem dock. +- The unused class variable GDScript warning is now disabled by default due to false positives. +- Warning-ignore comments now allow whitespace after the `#` character. +- Improved error reporting in the Particles emission point creation dialog. +- The number of warnings and errors that can be received in the remote debugger is now capped per second rather than per frame. + - The default limit is 100 errors and 100 warnings per second, making it possible for the script editor to report up to 100 warnings before having messages hidden. +- UTF-8 characters are now supported in input action names. +- All platforms now use the `custom_template` property in each export preset to store the path to the custom export template (instead of `custom_package` for some platforms). +- Tween methods' `trans_type` and `ease_type` arguments are now optional, defaulting to `TRANS_LINEAR` and `EASE_IN_OUT` respectively. +- `PCKPacker.pck_start()` and `PCKPacker.flush()`'s `alignment` and `verbose` arguments (respectively) are now optional, defaulting to `0` and `false`. +- Exported PCK files now contain the Godot patch version in their header. + - This can be used by external tools to detect the Godot version more accurately. +- Exporting a project PCK or ZIP from the command line must now be done with the new `--export-pack` command-line argument. + - This was done to remove the ambiguity when exporting a project to macOS from the command line. +- Updated FreeType to 2.10, which changes how font metrics are calculated. + - This may affect the appearance of some Controls, see [this issue](https://github.com/godotengine/godot/issues/28335) for details. +- The SCons build system now automatically detects the host platform. + - `platform=<platform>` is no longer required when compiling for the host platform. + - `platform=list` can be used to list the supported target platforms. +- **Windows:** Drive letters in file paths are now capitalized. +- **macOS:** <kbd>Control + H</kbd> and <kbd>Control + D</kbd> in TextEdit now delete the character at the left and right of the cursor (respectively). +- **macOS:** <kbd>Command + Left</kbd> in TextEdit now moves the cursor to the first non-whitespace character. +- **macOS:** Non-resizable windows are now allowed to enter fullscreen mode. +- **macOS:** The editor's title bar now uses dark mode on Mojave. +- **X11:** `OS.set_window_postion()` now takes window decorations into account. + +### Removed + +- Unused Panel `panelf` and `panelnc` styles. +- thekla_atlas dependency, as light baking now relies on [xatlas](https://github.com/jpcy/xatlas) for UV unwrapping. +- Rating icons in the Asset Library, as this feature isn't implemented in the backend. +- Some editor languages are no longer available due to missing support for RTL and text shaping in Godot: + - Affected languages are Arabic, Bengali, Persian, Hebrew, Hindi, Malayalam, Sinhalese, Tamil, Telugu and Urdu. + - These languages will be re-added once Godot supports RTL and text shaping. +- **Android:** ARMv6 support. +- **iOS:** ARMv7 support. + - ARMv7 export templates can still be compiled from source to support the iPhone 5 and older. + +### Fixed + +- The Project Manager now remembers the sorting option that was previously set. +- The editor and project manager now have a minimum window size defined. + - This prevents controls from overlapping each other by resizing the window to a very small size. +- Fixed radiance map generation, resulting in improved 3D performance and visual quality. +- Fixed issues with PBR environment mapping. + - Materials should now look closer to what they look like in Substance Designer/Painter. +- Depth of field now affects transparent objects. +- Radiance is now generated when using a clear color sky. +- Contact shadows no longer display when shadow casting is disabled. +- Larger data types can now be constructed by swizzling in the shader language. + - For instance, `vec2 test2 = vec2(0.0, 1.0); vec3 test3 = test2.xxx;` now works as in GLSL. +- The `AMBIENT_LIGHT_DISABLED` and `SHADOWS_DISABLED` flags now work when using the GLES2 renderer. +- The Keep background mode now works when using the GLES2 renderer. +- Several fixes to the GLES2 renderer: + - Fixed transparency order. + - Fixed vertex lighting being too bright. + - Fixed occasional light flickering. + - Fixed shadows cast from transparent materials. + - Fog is no longer computed on unshaded materials. + - This matches the GLES3 renderer's behavior. + - GLES2 shader uniforms now use `highp` precision by default. + - This prevents linking issues on some Android devices. + - Negative OmniLights and SpotLights now work as expected. + - The 3D editor's View Information pane now displays statistics correctly when using the GLES2 renderer. +- Textures compressed with ETC now support transparency by falling back to RGBA4444 or LA8. +- Alternate display modes are now marked as disabled in the editor when using the GLES2 renderer, as these are only supported when using GLES3. +- Fixed several inconsistencies between Particles and CPUParticles. +- Fixed particles scale randomization. +- Particles are now set to emit correctly when restarting. +- CheckBox and CheckButton now use the `check_vadjust` custom constant to adjust the icon Y position as intended. +- Fixed various issues with tab-related icons. +- Fixed issues in WebM colorspace corrections, resulting in better color output. +- CSG is now taken into account when generating navigation meshes. +- Curve2D and Curve3D interpolated values now behave as expected. +- Numeric slider grabbers in the editor inspector now update when scrolling using the mouse wheel. +- Scene modifications are no longer lost when renaming a file in the FileSystem dock. +- "Show in FileSystem" now clears the current search, so that the selected item can be seen immediately. +- LineEdit and TextEdit's context menus no longer display editing options if they are read-only. +- SpinBox mouse events are now correctly triggered by its LineEdit part. +- Per-word navigation in LineEdit and TextEdit now handles UTF-8 characters correctly. +- LineEdit placeholders, Tabs' names and WindowDialog titles now react correctly to translation changes. +- Fixed UI navigation when using gamepad analog sticks. +- Buttons' state is now reset when they exit the scene tree. + - This prevents them from lingering in a "hovered" or "pressed" state. +- Tooltips now disappear when hiding the node they belong to. +- Encoded packet flags are no longer sent in the ENet multiplayer protocol, as ENet itself already sends that data. + - This saves 4 bytes per packet. +- Audio trimming is now less aggressive, cutting at -50 dB instead of -30 dB. +- Audio trimming now has a small fade-out period, preventing audible pops. +- Audio mix rate and output latency settings are now consistently applied on all platforms. +- Fixed multichannel panning for AudioStreamPlayer3D. +- Opening a recent built-in script will now load the associated scene automtaically since doing so is required to edit the script. +- Declaring a class with `class_name` that has the same name as a singleton will now display a clearer error message. +- `script` is no longer allowed as a member variable name in GDScript, as that conflicts with the internal `script` property used by Object. +- Assigning a variable with a function index will no longer evaluate the function twice. + - For instance, doing `a[function()] += 1` will no longer evaluate `function()` twice. + - If the function has side effects, this may change the resulting program behavior. +- GDScript type checks are now enabled in release export templates. +- The Label font shadow now draws the font outline as well (if the base font has one). +- `Font.draw_char()` now draws the font outline as well (if the base font has one). +- The editor no longer redraws continuously when selecting a Control in a Container. +- Added some missing feature tags to the Project Settings "Override For..." menu. +- The `low_processor_mode_sleep_usec` project setting no longer affects the editor. +- Typed arrays and dictionaries no longer have their values shared across instances. +- `self` and object types can now be indexed as a dictionary again (like in Godot 3.0 and prior). +- Fixed `to_lower()` conversion with Cyrillic characters. +- The Find in Files replace dialog now allows empty replacement texts. +- The bottom panel no longer disappears when opening the theme editor on small displays. +- The script editor's color picker now changes only one color if multiple colors are present on the same line. +- The script editor's line length guideline is now drawn behind text. +- The script editor's line length guideline is now drawn at the correct position when font hinting is disabled. +- The script editor now automatically indents a line if the previous one ends with `[` or `(`. + - This makes it possible to wrap arrays or function declarations/calls without pressing <kbd>Tab</kbd> every line. +- Fixed autocompletion in the script editor. + - The script editor can now autocomplete enum values. + - The script editor can now autocomplete node paths starting with `$"` or `$'`. +- Custom script editor templates can now use type hints. +- Shift operators with a number not between 0 and 63 (inclusive) will now result in a compile-time error in GDScript. +- Warnings no longer count towards the "Too many errors!" message. +- AnimationTrackEdit now displays invalid value keys again (as it did in 3.0). +- Fixed the display of function/audio/animation tracks in the blend tree animation filter. +- The editor shortcuts menu no longer displays all unassigned shortcuts when searching for a substring of "None". +- The editor's performance monitor now displays memory/file sizes larger than 2 GB correctly. +- The editor debugger now displays keyboard shortcuts when hovering the "Step Into", "Step Over", "Break" and "Continue" buttons. +- The editor debugger now always handles connections. + - Subsequent connections will be dropped immediately to avoid locking. +- Large rotation offset/snap values no longer appear to be cut off in the Configure Snap dialog. +- Documentation tooltips in the editor now wrap to multiple lines correctly. +- Locked 3D nodes are no longer selectable in the 3D viewport, matching the 2D editor's behavior. +- All 3D gizmos now notify changes correctly, which means the inspector now displays up-to-date properties after using them. +- The 3D manipulator gizmo's size is now capped at low viewport heights, preventing it from outgrowing the viewport's bounds. +- The editor filesystem now refreshes on file changes if the project is located on an exFAT filesystem. +- Fixed many cases of colors not changing correctly when switching the editor from a dark theme to a light theme (or vice versa) without restarting. +- The Show in File Manager context menu option now works with files marked as favorite. +- The random number generator's seed is now properly set up. +- Antialiased and rounded StyleBoxFlat corners now handle different border widths correctly. +- The StyleBox preview now accounts for shadows and content margins. + - This fixes the preview going out of bounds in the inspector. +- Text resources no longer contain an extraneous line break at the end of file. +- Transform's `FLIP_Y` and `FLIP_Z` constants now work as expected. +- Fixed importing BMP images. +- The positional command-line argument is now only considered to be a scene path if it ends with `.scn`, `.tscn` or `.escn`. + - This makes it possible to parse command-line arguments in a standard fashion (`--foo bar` now works, not just `--foo=bar`). + - This also makes it possible to use file associations or drag-and-drop and have the positional argument parsed by the project. +- The `--audio-driver` and `--video-driver` command-line arguments are now validated; an error message will be printed if an invalid value is passed. +- The `--check-only` command-line argument now returns a non-zero exit code if an invalid script is passed using `--script`. +- Exporting a project via the command-line now returns a non-zero exit code if an error occurred during exporting. +- Console output is no longer colored when standard output isn't a TTY. + - This prevents Godot from writing ANSI escape codes when redirecting standard output or standard error to a file. +- **Android:** Gamepads are now correctly detected when the application starts. +- **Android:** Fix some keyboards being detected as gamepads and not working as a result. +- **Android:** The editor now detects if the device is connected using wireless `adb` and will debug using Wi-Fi in this case. +- **HTML5:** Fixed the pointer position on hiDPI displays. +- **HTML5:** `OS.get_system_time_msec()` now returns the correct value like on other platforms. +- **iOS:** On iOS 11 or later, gestures near screen edges are now handled by Godot instead of the OS. +- **Windows:** Line endings are now converted to CRLF when setting clipboard content. +- **Windows:** Getting the path to the Downloads directory using `OS.get_system_dir()` now works correctly. + - This fixes line endings being invisible when pasting into other applications. +- **macOS:** `OS.get_real_window_size()` and `OS.set_window_size()` are now handled correctly on hiDPI displays. +- **X11:** `OS.get_window_position()` now returns absolute coordinates. +- **X11:** Fixed audio playing on the wrong speakers when using PulseAudio on 5.1 setups. +- **X11:** `OS.set_window_maximized()` now gives up after 0.5 seconds. + - This makes the editor no longer freeze on startup when using fvwm. ## [3.1] - 2019-03-13 @@ -59,7 +783,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). - unreachable code after a `return` statement, - … - Warnings can be disabled in the Project Settings or by writing special comments. -- [GDScript keyword `class_name` to register scripts as classes.](http://docs.godotengine.org/en/latest/getting_started/step_by_step/scripting_continued.html#register-scripts-as-classes) +- [GDScript keyword `class_name` to register scripts as classes.](https://docs.godotengine.org/en/latest/getting_started/step_by_step/scripting_continued.html#register-scripts-as-classes) - Simple expression language independent from GDScript, used by inspector boxes that accept numeric values. - Can also be used in projects. - C# projects can now be exported for Windows, Linux, and macOS targets. @@ -288,7 +1012,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). - Rewritten audio engine from scratch. - Supports audio routing with arbitrary number of channels, including Area-based audio redirection ([video](https://youtu.be/K2XOBaJ5OQ0)). - More than a dozen of audio effects included. -- Rewritten 3D physics using [Bullet](http://bulletphysics.org/). +- Rewritten 3D physics using [Bullet](https://bulletphysics.org/). - UDP-based high-level networking API using [ENet](http://enet.bespin.org/). - IPv6 support for all of the engine's networking APIs. - Visual scripting. @@ -306,7 +1030,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). - Setters and getters for node properties. - Underscores in number literals are now allowed for improved readability (for example,`1_000_000`). - Improved performance (+20% to +40%, based on various benchmarks). -- [Feature tags](http://docs.godotengine.org/en/latest/getting_started/workflow/export/feature_tags.html) in the Project Settings, for custom per-platform settings. +- [Feature tags](https://docs.godotengine.org/en/latest/getting_started/workflow/export/feature_tags.html) in the Project Settings, for custom per-platform settings. - Full support for the [glTF 2.0](https://www.khronos.org/gltf/) 3D interchange format. - Freelook and fly navigation to the 3D editor. - Built-in editor logging (logging standard output to a file), disabled by default. @@ -359,7 +1083,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). - Exporting to Windows now changes the exported project's icon using `rcedit` (requires WINE if exporting from Linux or macOS). - Improved build system. - Support for compiling using Visual Studio 2017. - - [SCons](http://scons.org/) 3.0 and Python 3 are now supported (SCons 2.5 and Python 2.7 still work). + - [SCons](https://scons.org/) 3.0 and Python 3 are now supported (SCons 2.5 and Python 2.7 still work). - Link-time optimization can now be enabled by passing `use_lto=yes` to the SCons command line. - Produces faster and sometimes smaller binaries. - Currently only supported with GCC and MSVC. @@ -374,11 +1098,11 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). - Increased the default 3D editor camera's field of view (55 → 70). - Increased the default 3D Camera node's field of view (65 → 70). - Changed the default editor font (Droid Sans → [Noto Sans](https://www.google.com/get/noto/)). -- Changed the default script editor font (Source Code Pro → [Hack](http://sourcefoundry.org/hack/)) +- Changed the default script editor font (Source Code Pro → [Hack](https://sourcefoundry.org/hack/)) - Renamed `engine.cfg` to `project.godot`. - This allows users to open a project by double-clicking the file if Godot is associated to `.godot` files. - Some methods from the `OS` singleton were moved to the new `Engine` singleton. -- Switched from [GLEW](http://glew.sourceforge.net/) to [GLAD](http://glad.dav1d.de/) for OpenGL wrapping. +- Switched from [GLEW](http://glew.sourceforge.net/) to [GLAD](https://glad.dav1d.de/) for OpenGL wrapping. - Changed the SCons build flag for simple logs (`colored=yes` → `verbose=no`). - The HTML5 platform now uses WebGL 2.0 (instead of 1.0). - Redesigned the Godot logo to be more legible at small sizes. @@ -396,5 +1120,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/). - HTML5 export using asm.js. - Only WebAssembly is supported now, since all browsers supporting WebGL 2.0 also support WebAssembly. -[Unreleased]: https://github.com/godotengine/godot/compare/3.0-stable...HEAD +[Unreleased]: https://github.com/godotengine/godot/compare/3.2-stable...HEAD +[3.2]: https://github.com/godotengine/godot/compare/3.1-stable...3.2-stable +[3.1]: https://github.com/godotengine/godot/compare/3.0-stable...3.1-stable [3.0]: https://github.com/godotengine/godot/compare/2.1-stable...3.0-stable diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index c27bee2b5c..ba04008680 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,70 +1,106 @@ # How to contribute efficiently -Sections covered in this file: +## Table of contents -* [Reporting bugs or proposing features](#reporting-bugs-or-proposing-features) -* [Contributing pull requests](#contributing-pull-requests) -* [Contributing to Godot's translation](#contributing-to-godots-translation) -* [Communicating with developers](#communicating-with-developers) +- [Reporting bugs](#reporting-bugs) +- [Proposing features or improvements](#proposing-features-or-improvements) +- [Contributing pull requests](#contributing-pull-requests) +- [Contributing to Godot's translation](#contributing-to-godots-translation) +- [Communicating with developers](#communicating-with-developers) **Please read the first section before reporting a bug!** -## Reporting bugs or proposing features +## Reporting bugs The golden rule is to **always open *one* issue for *one* bug**. If you notice several bugs and want to report them, make sure to create one new issue for each of them. -Everything referred to hereafter as "bug" also applies for feature requests. +If you're reporting a new bug, you'll make our life simpler (and the +fix will come sooner) by following these guidelines: -If you are reporting a new issue, you will make our life much simpler (and the -fix come much sooner) by following these guidelines: +### Search first in the existing database -#### Search first in the existing database +Issues are often reported several times by various users. It's good practice to +**search first in the [issue tracker](https://github.com/godotengine/godot/issues) +before reporting your issue**. If you don't find a relevant match or if you're +unsure, don't hesitate to **open a new issue**. The bugsquad will handle it +from there if it's a duplicate. -Issues are often reported several times by various users. It's a good practice -to **search first** in the issues database before reporting your issue. If you -don't find a relevant match or if you are unsure, don't hesitate to **open a -new issue**. The bugsquad will handle it from there if it's a duplicate. - -#### Specify the platform +### Specify the platform Godot runs on a large variety of platforms and operating systems and devices. -If you believe your issue is device/platform dependent (for example if it is -related to the rendering, crashes or compilation errors), please specify: -* Operating system -* Device (including architecture, e.g. x86, x86_64, arm, etc.) -* GPU model (and driver in use if you know it) +**In your bug reports, please always specify:** + +- Operating system and version (e.g. Windows 10, macOS 10.15, Ubuntu 19.10) +- Godot version (e.g. 3.2, 3.1.2, or the Git commit hash if you're using a development branch) + +For bugs that are likely OS-specific and/or graphics-related, please also specify: + +- Device (CPU model including architecture, e.g. x86, x86_64, ARM, etc.) +- GPU model (and the driver version in use if you know it) + +**Bug reports not including the required information may be closed at the +maintainers' discretion.** If in doubt, always include all the requested +information; it's better to include too much information than not enough +information. -#### Specify steps to reproduce +### Specify steps to reproduce Many bugs can't be reproduced unless specific steps are taken. Please **specify the exact steps** that must be taken to reproduce the condition, and try to -keep them as minimal as possible. +keep them as minimal as possible. If you're describing a procedure to follow +in the editor, don't hesitate to include screenshots. -#### Provide a simple, example project +Making your bug report easy to reproduce will make it easier for contributors +to fix the bug. -Sometimes an unexpected behavior happens in your project. In such case, +### Provide a simple, example project + +Sometimes, unexpected behavior can happen in your project. In such case, understand that: -* What happens to you may not happen to other users. -* We can't take the time to look at your project, understand how it is set up + +- What happens to you may not happen to other users. +- We can't take the time to look at your project, understand how it is set up and then figure out why it's failing. -To speed up our work, please prepare for us **a simple project** that isolates +To speed up our work, **please upload a minimal project** that isolates and reproduces the issue. This is always the **best way for us to fix it**. -You can attach a zip file with the minimal project directly to the bug report, +You can attach a ZIP file with the minimal project directly to the bug report, by drag and dropping the file in the GitHub edition field. +We recommend always attaching a minimal reproduction project, even if the issue +may seem simple to reproduce manually. + +**If you've been asked by a maintainer to upload a minimal reproduction project, +you *must* do so within 7 days.** Otherwise, your bug report will be closed as +it'll be considered too difficult to diagnose. + +Now that you've read the guidelines, click the link below to create a +bug report: + +- **[Report a bug](https://github.com/godotengine/godot/issues/new?assignees=&labels=&template=bug_report.md&title=)** + +## Proposing features or improvements + +**Since August 2019, the main issue tracker no longer accepts feature proposals.** +Instead, head to the [Godot Proposals repository](https://github.com/godotengine/godot-proposals) +and follow the instructions in the README file. High-quality feature proposals +are more likely to be well-received by the maintainers and community, so do +your best :) + +See [this article](https://godotengine.org/article/introducing-godot-proposals-repository) +for detailed rationale on this change. + ## Contributing pull requests -If you want to add new engine functionalities, please make sure that: +If you want to add new engine features, please make sure that: -* This functionality is desired, which means that it solves a common use case +- This functionality is desired, which means that it solves a common use case that several users will need in their real-life projects. -* You talked to other developers on how to implement it best (on either - communication channel, and maybe in a GitHub issue first before making your - PR). -* Even if it does not get merged, your PR is useful for future work by another +- You talked to other developers on how to implement it best. See also + [Proposing features or improvements](#proposing-features-or-improvements). +- Even if it doesn't get merged, your PR is useful for future work by another developer. Similar rules can be applied when contributing bug fixes - it's always best to @@ -80,10 +116,10 @@ In addition to the following tips, also take a look at the [Engine development guide](https://docs.godotengine.org/en/latest/development/cpp/) for an introduction to developing on Godot. -The [Contributing docs](http://docs.godotengine.org/en/latest/community/contributing/index.html) +The [Contributing docs](https://docs.godotengine.org/en/latest/community/contributing/index.html) also have important information on the PR workflow and the code style we use. -#### Be nice to the git history +### Be nice to the Git history Try to make simple PRs that handle one specific topic. Just like for reporting issues, it's better to open 3 different PRs that each address a different issue @@ -99,33 +135,31 @@ commit, try to merge them together before making your pull request (see ``git rebase -i`` and relevant help about rebasing or amending commits on the Internet). -This git style guide has some good practices to have in mind: -[Git Style Guide](https://github.com/agis-/git-style-guide) +This [Git style guide](https://github.com/agis-/git-style-guide) has some +good practices to have in mind. -See our [PR workflow](http://docs.godotengine.org/en/latest/community/contributing/pr_workflow.html) +See our [PR workflow](https://docs.godotengine.org/en/latest/community/contributing/pr_workflow.html) documentation for tips on using Git, amending commits and rebasing branches. -#### Format your commit logs with readability in mind +### Format your commit messages with readability in mind -The way you format your commit logs is quite important to ensure that the -commit history and changelog will be easy to read and understand. A git commit -log is formatted as a short title (first line) and an extended description +The way you format your commit messages is quite important to ensure that the +commit history and changelog will be easy to read and understand. A Git commit +message is formatted as a short title (first line) and an extended description (everything after the first line and an empty separation line). The short title is the most important part, as it is what will appear in the `shortlog` changelog (one line per commit, so no description shown) or in the -GitHub interface unless you click the "expand" button. As the name tells it, -try to keep that first line relatively short (ideally <= 50 chars, though it's -rare to be able to tell enough in so few characters, so you can go a bit -higher) - it should describe what the commit does globally, while details would -go in the description. Typically, if you can't keep the title short because you -have too much stuff to mention, it means that you should probably split your -changes in several commits :) - -Here's an example of a well-formatted commit log (note how the extended +GitHub interface unless you click the "expand" button. As the name says, try to +keep that first line under 72 characters. It should describe what the commit +does globally, while details would go in the description. Typically, if you +can't keep the title short because you have too much stuff to mention, it means +you should probably split your changes in several commits :) + +Here's an example of a well-formatted commit message (note how the extended description is also manually wrapped at 80 chars for readability): -``` +```text Prevent French fries carbonization by fixing heat regulation When using the French fries frying module, Godot would not regulate the heat @@ -139,9 +173,9 @@ of cooking oil under normal atmospheric conditions. Fixes #1789, long live the Realm! ``` -*Note:* When using the GitHub online editor (or worse, the drag and drop -feature), *please* edit the commit title to something meaningful. Commits named -"Update my_file.cpp" will not be accepted. +**Note:** When using the GitHub online editor or its drag-and-drop +feature, *please* edit the commit title to something meaningful. Commits named +"Update my_file.cpp" won't be accepted. ## Contributing to Godot's translation @@ -162,6 +196,7 @@ discussions and support, others more for development discussions. To communicate with developers (e.g. to discuss a feature you want to implement or a bug you want to fix), the following channels can be used: + - [GitHub issues](https://github.com/godotengine/godot/issues): If there is an existing issue about a topic you want to discuss, just add a comment to it - all developers watch the repository and will get an email notification. You @@ -182,6 +217,6 @@ or a bug you want to fix), the following channels can be used: page](https://listengine.tuxfamily.org/godotengine.org/devel/) for subscription instructions. -Thanks! +Thanks for your interest in contributing! -The Godot development team +—The Godot development team @@ -25,6 +25,7 @@ generous deed immortalized in the next stable release of Godot Engine. AD Ford Alan Beauchamp Anand Mallik + Andres Hernandez Andrew Dunai Brandon Lamb Christopher Montesano @@ -38,8 +39,6 @@ generous deed immortalized in the next stable release of Godot Engine. Jacob McKenney Javary Co. Jeffery Chiu - Jeppe Zapp - John Benard (Linuxydable) Justin Arnold Justo Delgado Baudà Kyle Szklenski @@ -65,7 +64,6 @@ generous deed immortalized in the next stable release of Godot Engine. Ed Morley Florian Krick Florian Rämisch - GiulianoB Jakub Grzesik Manuele Finocchiaro Officine Pixel S.n.c. @@ -75,8 +73,6 @@ generous deed immortalized in the next stable release of Godot Engine. Taylor Ritenour Zaven Muradyan - _ - Alexander Trey Saunders Asher Glick Austen McRae Bernhard Werner @@ -110,11 +106,9 @@ generous deed immortalized in the next stable release of Godot Engine. thechris Tom Langwaldt tukon - Unseen Domains William Wold Alex Khayrullin - Branwyn “Bee†Tylwyth Chris Goddard Chris Serino Christian Padilla @@ -127,7 +121,6 @@ generous deed immortalized in the next stable release of Godot Engine. Joshua Flores Krzysztof Jankowski Lord Bloodhound - Nathan Lundquist Pascal Grüter Petr Malac Rami @@ -136,6 +129,7 @@ generous deed immortalized in the next stable release of Godot Engine. Robert Willes Ronnie Ashlock Thomas Bjarnelöf + Unseen Domains Valryia Vincent Henderson Wojciech Chojnacki @@ -148,18 +142,17 @@ generous deed immortalized in the next stable release of Godot Engine. André Frélicot Andrew Bowen aoshiwik - Ben Botwin Carlos de Sousa Marques Chase Taranto Chris Petrich Christian Leth Jeppesen Christoph Schröder Cody Parker + Craig Ostrin D Daniel Eichler David White Eric Monson - Erik Hatfield Eugenio Hugo Salgüero Jáñez Fain flesk @@ -233,23 +226,21 @@ generous deed immortalized in the next stable release of Godot Engine. Albin Jonasson Svärdsby Alder Stefano Alessandro Senese + alex clavelle Alex Davies-Moore Allen Schade Andreas Evers Andreas Krampitz André Simões - Andrés RodrÃguez Andrew Thomas Andrzej Skalski Angelos Arnaoutis - Anthony Bongiovanni Anthony Staunton AP Condomines Arda Erol Arseniy M Arthur S. Muszynski Asger - Atilla Kiran Aubrey Falconer Avencherus B A @@ -269,7 +260,6 @@ generous deed immortalized in the next stable release of Godot Engine. Chris Brown Chris Chapin Christian Baune - Christian Chipont Christian Winter Christoffer Sundbom Christopher Schmitt @@ -292,12 +282,12 @@ generous deed immortalized in the next stable release of Godot Engine. Dragontrapper Dr Ewan Murray Duobix + Duodecimal + Dylan Todd Eduardo Teixeira Edward Herbert Egon Elbre - Ellen Marie Dash Elmeri '- Duy Kevin Nguyen - Emanuel Kotzayan Eric Ellingson Eric Williams Erkki Seppälä @@ -314,6 +304,7 @@ generous deed immortalized in the next stable release of Godot Engine. gamedev by Celio Gary Hulst George Marques + GiulianoB Greg Olson GREGORY C FEIN Greg P @@ -321,7 +312,6 @@ generous deed immortalized in the next stable release of Godot Engine. Guldoman Hal A Heribert Hirth - Hiroshi Naruo Hunter Jones Hylpher Iiari @@ -337,7 +327,6 @@ generous deed immortalized in the next stable release of Godot Engine. Jennifer Graves Jeremy Kahn Jesse Dubay - Joao Senerchia Joe Alden Joel Fivat Joel Setterberg @@ -372,6 +361,7 @@ generous deed immortalized in the next stable release of Godot Engine. KsyTek Games Kuan Cheang kycho + Leonardo Dimano Levi Lindsey Linus Lind Lundgren Lionel Gaillard @@ -383,7 +373,6 @@ generous deed immortalized in the next stable release of Godot Engine. Malik Nejer Marcus Richter Markus Michael Egger - Martin Candela Martin Holas Martin LiÅ¡ka Matthew Little @@ -407,6 +396,7 @@ generous deed immortalized in the next stable release of Godot Engine. Natrim nee Neil Blakey-Milner + Neil Wang Nerdforge Nicholas Nick Macholl @@ -414,7 +404,6 @@ generous deed immortalized in the next stable release of Godot Engine. Nicolás Montaña Nicolas SAN AGUSTIN Nima Farid - Nithin Jino NZ Oleg Reva Olivier @@ -433,6 +422,7 @@ generous deed immortalized in the next stable release of Godot Engine. Pitsanu Tongprasin Point08 Poryg + Rad Cat Rafa Laguna rainerLinux Raphael Leroux @@ -448,13 +438,12 @@ generous deed immortalized in the next stable release of Godot Engine. Roger Smith Roland RzÄ…sa Roman Tinkov - Ronan Jouchet + Ronan Ryan Groom Ryan Hentz Sam.C Sam Edson Samuele Zolfanelli - Sanka.X Sasori Olkof Scott D. Yelich Sebastian Michailidis @@ -474,6 +463,7 @@ generous deed immortalized in the next stable release of Godot Engine. tiansheng li Tim Drumheller Timothy B. MacDonald + tinyBigGames LLC Tobbun Tom Fulp Tom Glenn diff --git a/core/bind/core_bind.cpp b/core/bind/core_bind.cpp index 4586dc6d14..e61e392a79 100644 --- a/core/bind/core_bind.cpp +++ b/core/bind/core_bind.cpp @@ -110,7 +110,7 @@ PoolStringArray _ResourceLoader::get_dependencies(const String &p_path) { #ifndef DISABLE_DEPRECATED bool _ResourceLoader::has(const String &p_path) { - WARN_PRINTS("ResourceLoader.has() is deprecated, please replace it with the equivalent has_cached() or the new exists()."); + WARN_PRINT("ResourceLoader.has() is deprecated, please replace it with the equivalent has_cached() or the new exists()."); return has_cached(p_path); } #endif // DISABLE_DEPRECATED @@ -1266,7 +1266,7 @@ void _OS::_bind_methods() { ClassDB::bind_method(D_METHOD("get_processor_count"), &_OS::get_processor_count); ClassDB::bind_method(D_METHOD("get_executable_path"), &_OS::get_executable_path); - ClassDB::bind_method(D_METHOD("execute", "path", "arguments", "blocking", "output", "read_stderr"), &_OS::execute, DEFVAL(Array()), DEFVAL(false)); + ClassDB::bind_method(D_METHOD("execute", "path", "arguments", "blocking", "output", "read_stderr"), &_OS::execute, DEFVAL(true), DEFVAL(Array()), DEFVAL(false)); ClassDB::bind_method(D_METHOD("kill", "pid"), &_OS::kill); ClassDB::bind_method(D_METHOD("shell_open", "uri"), &_OS::shell_open); ClassDB::bind_method(D_METHOD("get_process_id"), &_OS::get_process_id); @@ -1393,7 +1393,7 @@ void _OS::_bind_methods() { ADD_PROPERTY_DEFAULT("current_screen", 0); ADD_PROPERTY_DEFAULT("exit_code", 0); ADD_PROPERTY_DEFAULT("vsync_enabled", true); - ADD_PROPERTY_DEFAULT("vsync_via_compositor", true); + ADD_PROPERTY_DEFAULT("vsync_via_compositor", false); ADD_PROPERTY_DEFAULT("low_processor_usage_mode", false); ADD_PROPERTY_DEFAULT("low_processor_usage_mode_sleep_usec", 6900); ADD_PROPERTY_DEFAULT("keep_screen_on", true); @@ -2773,8 +2773,9 @@ _Thread::_Thread() { _Thread::~_Thread() { - ERR_FAIL_COND_MSG(active, "Reference to a Thread object object was lost while the thread is still running..."); + ERR_FAIL_COND_MSG(active, "Reference to a Thread object was lost while the thread is still running..."); } + ///////////////////////////////////// PoolStringArray _ClassDB::get_class_list() const { @@ -3024,6 +3025,16 @@ float _Engine::get_frames_per_second() const { return Engine::get_singleton()->get_frames_per_second(); } +uint64_t _Engine::get_physics_frames() const { + + return Engine::get_singleton()->get_physics_frames(); +} + +uint64_t _Engine::get_idle_frames() const { + + return Engine::get_singleton()->get_idle_frames(); +} + void _Engine::set_time_scale(float p_scale) { Engine::get_singleton()->set_time_scale(p_scale); } @@ -3108,6 +3119,8 @@ void _Engine::_bind_methods() { ClassDB::bind_method(D_METHOD("get_frames_drawn"), &_Engine::get_frames_drawn); ClassDB::bind_method(D_METHOD("get_frames_per_second"), &_Engine::get_frames_per_second); + ClassDB::bind_method(D_METHOD("get_physics_frames"), &_Engine::get_physics_frames); + ClassDB::bind_method(D_METHOD("get_idle_frames"), &_Engine::get_idle_frames); ClassDB::bind_method(D_METHOD("get_main_loop"), &_Engine::get_main_loop); @@ -3204,7 +3217,7 @@ Ref<JSONParseResult> _JSON::parse(const String &p_json) { result->error = JSON::parse(p_json, result->result, result->error_string, result->error_line); if (result->error != OK) { - ERR_PRINTS(vformat("Error parsing JSON at line %s: %s", result->error_line, result->error_string)); + ERR_PRINT(vformat("Error parsing JSON at line %s: %s", result->error_line, result->error_string)); } return result; } diff --git a/core/bind/core_bind.h b/core/bind/core_bind.h index 7c5031cad4..87da51f97e 100644 --- a/core/bind/core_bind.h +++ b/core/bind/core_bind.h @@ -227,7 +227,7 @@ public: int get_low_processor_usage_mode_sleep_usec() const; String get_executable_path() const; - int execute(const String &p_path, const Vector<String> &p_arguments, bool p_blocking, Array p_output = Array(), bool p_read_stderr = false); + int execute(const String &p_path, const Vector<String> &p_arguments, bool p_blocking = true, Array p_output = Array(), bool p_read_stderr = false); Error kill(int p_pid); Error shell_open(String p_uri); @@ -747,6 +747,8 @@ public: int get_target_fps() const; float get_frames_per_second() const; + uint64_t get_physics_frames() const; + uint64_t get_idle_frames() const; int get_frames_drawn(); diff --git a/core/class_db.cpp b/core/class_db.cpp index 65f0c6008c..8800f51778 100644 --- a/core/class_db.cpp +++ b/core/class_db.cpp @@ -541,7 +541,7 @@ Object *ClassDB::instance(const StringName &p_class) { } #ifdef TOOLS_ENABLED if (ti->api == API_EDITOR && !Engine::get_singleton()->is_editor_hint()) { - ERR_PRINTS("Class '" + String(p_class) + "' can only be instantiated by editor."); + ERR_PRINT("Class '" + String(p_class) + "' can only be instantiated by editor."); return NULL; } #endif diff --git a/core/color.cpp b/core/color.cpp index 5cbe02067e..1baa8af45d 100644 --- a/core/color.cpp +++ b/core/color.cpp @@ -511,7 +511,7 @@ Color Color::from_hsv(float p_h, float p_s, float p_v, float p_a) const { // FIXME: Remove once Godot 3.1 has been released float Color::gray() const { - WARN_DEPRECATED_MSG("Color.gray() is deprecated and will be removed in a future version. Use Color.get_v() for a better grayscale approximation."); + WARN_DEPRECATED_MSG("'Color.gray()' is deprecated and will be removed in a future version. Use 'Color.v' for a better grayscale approximation."); return (r + g + b) / 3.0; } diff --git a/core/color_names.inc b/core/color_names.inc index b0ef507d92..428a8473fe 100644 --- a/core/color_names.inc +++ b/core/color_names.inc @@ -1,4 +1,4 @@ -// Names from https://en.wikipedia.org/wiki/List_of_colors (through https://raw.githubusercontent.com/SuperUserNameMan/color_to_name/616a7cddafefda91478b7bc26167de97fb5badb1/godot_version.gd), slightly edited and normalized +// Names from https://en.wikipedia.org/wiki/X11_color_names #include "core/map.h" static Map<String, Color> _named_colors; diff --git a/core/error_macros.cpp b/core/error_macros.cpp index 6dd7dd5e1c..f6da990562 100644 --- a/core/error_macros.cpp +++ b/core/error_macros.cpp @@ -106,7 +106,7 @@ void _err_print_error(const char *p_function, const char *p_file, int p_line, co void _err_print_index_error(const char *p_function, const char *p_file, int p_line, int64_t p_index, int64_t p_size, const char *p_index_str, const char *p_size_str, const char *p_message, bool fatal) { String fstr(fatal ? "FATAL: " : ""); - String err(fstr + "Index " + p_index_str + "=" + itos(p_index) + " out of size (" + p_size_str + "=" + itos(p_size) + ")"); + String err(fstr + "Index " + p_index_str + " = " + itos(p_index) + " is out of bounds (" + p_size_str + " = " + itos(p_size) + ")."); _err_print_error(p_function, p_file, p_line, err.utf8().get_data(), p_message); } diff --git a/core/error_macros.h b/core/error_macros.h index ed7f601089..80ceede043 100644 --- a/core/error_macros.h +++ b/core/error_macros.h @@ -32,21 +32,8 @@ #define ERROR_MACROS_H #include "core/typedefs.h" -/** - * Error macros. Unlike exceptions and asserts, these macros try to maintain consistency and stability - * inside the code. It is recommended to always return processable data, so in case of an error, the - * engine can stay working well. - * In most cases, bugs and/or invalid data are not fatal and should never allow a perfectly running application - * to fail or crash. - */ - -/** - * Pointer to the error macro printing function. Reassign to any function to have errors printed - */ - -/** Function used by the error macros */ -// function, file, line, error, explanation +class String; enum ErrorHandlerType { ERR_HANDLER_ERROR, @@ -55,7 +42,8 @@ enum ErrorHandlerType { ERR_HANDLER_SHADER, }; -class String; +// Pointer to the error handler printing function. Reassign to any function to have errors printed. +// Parameters: userdata, function, file, line, error, explanation, type. typedef void (*ErrorHandlerFunc)(void *, const char *, const char *, int p_line, const char *, const char *, ErrorHandlerType p_type); struct ErrorHandlerList { @@ -75,6 +63,7 @@ struct ErrorHandlerList { void add_error_handler(ErrorHandlerList *p_handler); void remove_error_handler(ErrorHandlerList *p_handler); +// Functions used by the error macros. void _err_print_error(const char *p_function, const char *p_file, int p_line, const char *p_error, ErrorHandlerType p_type = ERR_HANDLER_ERROR); void _err_print_error(const char *p_function, const char *p_file, int p_line, const String &p_error, ErrorHandlerType p_type = ERR_HANDLER_ERROR); void _err_print_error(const char *p_function, const char *p_file, int p_line, const char *p_error, const char *p_message, ErrorHandlerType p_type = ERR_HANDLER_ERROR); @@ -84,15 +73,6 @@ void _err_print_error(const char *p_function, const char *p_file, int p_line, co void _err_print_index_error(const char *p_function, const char *p_file, int p_line, int64_t p_index, int64_t p_size, const char *p_index_str, const char *p_size_str, const char *p_message = "", bool fatal = false); void _err_print_index_error(const char *p_function, const char *p_file, int p_line, int64_t p_index, int64_t p_size, const char *p_index_str, const char *p_size_str, const String &p_message, bool fatal = false); -#ifndef _STR -#define _STR(m_x) #m_x -#define _MKSTR(m_x) _STR(m_x) -#endif - -#define _FNL __FILE__ ":" - -/** An index has failed if m_index<0 or m_index >=m_size, the function exits */ - #ifdef __GNUC__ //#define FUNCTION_STR __PRETTY_FUNCTION__ - too annoying #define FUNCTION_STR __FUNCTION__ @@ -100,15 +80,16 @@ void _err_print_index_error(const char *p_function, const char *p_file, int p_li #define FUNCTION_STR __FUNCTION__ #endif -// Don't use this directly; instead, use any of the CRASH_* macros #ifdef _MSC_VER -#define GENERATE_TRAP \ - __debugbreak(); \ - /* Avoid warning about control paths */ \ - for (;;) { \ - } +/** + * Don't use GENERATE_TRAP() directly, should only be used be the macros below. + */ +#define GENERATE_TRAP() __debugbreak() #else -#define GENERATE_TRAP __builtin_trap(); +/** + * Don't use GENERATE_TRAP() directly, should only be used be the macros below. + */ +#define GENERATE_TRAP() __builtin_trap() #endif // Used to strip debug messages in release mode @@ -118,327 +99,550 @@ void _err_print_index_error(const char *p_function, const char *p_file, int p_li #define DEBUG_STR(m_msg) "" #endif -// (*): See https://stackoverflow.com/questions/257418/do-while-0-what-is-it-good-for +/** + * Error macros. + * WARNING: These macros work in the opposite way to assert(). + * + * Unlike exceptions and asserts, these macros try to maintain consistency and stability. + * In most cases, bugs and/or invalid data are not fatal. They should never allow a perfectly + * running application to fail or crash. + * Always try to return processable data, so the engine can keep running well. + * Use the _MSG versions to print a meaningful message to help with debugging. + * + * Note: See https://stackoverflow.com/questions/257418/do-while-0-what-is-it-good-for + */ + +// Index out of bounds error macros. +// These macros should be used instead of `ERR_FAIL_COND` for bounds checking. + +// Integer index out of bounds error macros. +/** + * Try using `ERR_FAIL_INDEX_MSG`. + * Only use this macro if there is no sensible error message. + * + * Ensures an integer index `m_index` is less than `m_size` and greater than or equal to 0. + * If not, the current function returns. + */ #define ERR_FAIL_INDEX(m_index, m_size) \ do { \ if (unlikely((m_index) < 0 || (m_index) >= (m_size))) { \ _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size)); \ return; \ } \ - } while (0); // (*) + } while (0) +/** + * Ensures an integer index `m_index` is less than `m_size` and greater than or equal to 0. + * If not, prints `m_msg` and the current function returns. + */ #define ERR_FAIL_INDEX_MSG(m_index, m_size, m_msg) \ do { \ if (unlikely((m_index) < 0 || (m_index) >= (m_size))) { \ _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), DEBUG_STR(m_msg)); \ return; \ } \ - } while (0); // (*) - -/** An index has failed if m_index<0 or m_index >=m_size, the function exits. -* This function returns an error value, if returning Error, please select the most -* appropriate error condition from error_macros.h -*/ + } while (0) +/** + * Try using `ERR_FAIL_INDEX_V_MSG`. + * Only use this macro if there is no sensible error message. + * + * Ensures an integer index `m_index` is less than `m_size` and greater than or equal to 0. + * If not, the current function returns `m_retval`. + */ #define ERR_FAIL_INDEX_V(m_index, m_size, m_retval) \ do { \ if (unlikely((m_index) < 0 || (m_index) >= (m_size))) { \ _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size)); \ return m_retval; \ } \ - } while (0); // (*) + } while (0) +/** + * Ensures an integer index `m_index` is less than `m_size` and greater than or equal to 0. + * If not, prints `m_msg` and the current function returns `m_retval`. + */ #define ERR_FAIL_INDEX_V_MSG(m_index, m_size, m_retval, m_msg) \ do { \ if (unlikely((m_index) < 0 || (m_index) >= (m_size))) { \ _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), DEBUG_STR(m_msg)); \ return m_retval; \ } \ - } while (0); // (*) + } while (0) + +/** + * Try using `ERR_FAIL_INDEX_MSG` or `ERR_FAIL_INDEX_V_MSG`. + * Only use this macro if there is no sensible fallback i.e. the error is unrecoverable, and + * there is no sensible error message. + * + * Ensures an integer index `m_index` is less than `m_size` and greater than or equal to 0. + * If not, the application crashes. + */ +#define CRASH_BAD_INDEX(m_index, m_size) \ + do { \ + if (unlikely((m_index) < 0 || (m_index) >= (m_size))) { \ + _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), "", true); \ + GENERATE_TRAP(); \ + } \ + } while (0) + +/** + * Try using `ERR_FAIL_INDEX_MSG` or `ERR_FAIL_INDEX_V_MSG`. + * Only use this macro if there is no sensible fallback i.e. the error is unrecoverable. + * + * Ensures an integer index `m_index` is less than `m_size` and greater than or equal to 0. + * If not, prints `m_msg` and the application crashes. + */ +#define CRASH_BAD_INDEX_MSG(m_index, m_size, m_msg) \ + do { \ + if (unlikely((m_index) < 0 || (m_index) >= (m_size))) { \ + _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), DEBUG_STR(m_msg), true); \ + GENERATE_TRAP(); \ + } \ + } while (0) + +// Unsigned integer index out of bounds error macros. + +/** + * Try using `ERR_FAIL_UNSIGNED_INDEX_MSG`. + * Only use this macro if there is no sensible error message. + * + * Ensures an unsigned integer index `m_index` is less than `m_size`. + * If not, the current function returns. + */ +#define ERR_FAIL_UNSIGNED_INDEX(m_index, m_size) \ + do { \ + if (unlikely((m_index) >= (m_size))) { \ + _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size)); \ + return; \ + } \ + } while (0) -/** An index has failed if m_index >=m_size, the function exits. -* This function returns an error value, if returning Error, please select the most -* appropriate error condition from error_macros.h -*/ +/** + * Ensures an unsigned integer index `m_index` is less than `m_size`. + * If not, prints `m_msg` and the current function returns. + */ +#define ERR_FAIL_UNSIGNED_INDEX_MSG(m_index, m_size, m_msg) \ + do { \ + if (unlikely((m_index) >= (m_size))) { \ + _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), DEBUG_STR(m_msg)); \ + return; \ + } \ + } while (0) +/** + * Try using `ERR_FAIL_UNSIGNED_INDEX_V_MSG`. + * Only use this macro if there is no sensible error message. + * + * Ensures an unsigned integer index `m_index` is less than `m_size`. + * If not, the current function returns `m_retval`. + */ #define ERR_FAIL_UNSIGNED_INDEX_V(m_index, m_size, m_retval) \ do { \ if (unlikely((m_index) >= (m_size))) { \ _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size)); \ return m_retval; \ } \ - } while (0); // (*) + } while (0) +/** + * Ensures an unsigned integer index `m_index` is less than `m_size`. + * If not, prints `m_msg` and the current function returns `m_retval`. + */ #define ERR_FAIL_UNSIGNED_INDEX_V_MSG(m_index, m_size, m_retval, m_msg) \ do { \ if (unlikely((m_index) >= (m_size))) { \ _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), DEBUG_STR(m_msg)); \ return m_retval; \ } \ - } while (0); // (*) + } while (0) -/** Use this one if there is no sensible fallback, that is, the error is unrecoverable. -* We'll return a null reference and try to keep running. -*/ -#define CRASH_BAD_INDEX(m_index, m_size) \ +/** + * Try using `ERR_FAIL_UNSIGNED_INDEX_MSG` or `ERR_FAIL_UNSIGNED_INDEX_V_MSG`. + * Only use this macro if there is no sensible fallback i.e. the error is unrecoverable, and + * there is no sensible error message. + * + * Ensures an unsigned integer index `m_index` is less than `m_size`. + * If not, the application crashes. + */ +#define CRASH_BAD_UNSIGNED_INDEX(m_index, m_size) \ do { \ - if (unlikely((m_index) < 0 || (m_index) >= (m_size))) { \ + if (unlikely((m_index) >= (m_size))) { \ _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), "", true); \ - GENERATE_TRAP \ + GENERATE_TRAP(); \ } \ - } while (0); // (*) + } while (0) -#define CRASH_BAD_INDEX_MSG(m_index, m_size, m_msg) \ - do { \ - if (unlikely((m_index) < 0 || (m_index) >= (m_size))) { \ - _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), m_msg, true); \ - GENERATE_TRAP \ - } \ - } while (0); // (*) +/** + * Try using `ERR_FAIL_UNSIGNED_INDEX_MSG` or `ERR_FAIL_UNSIGNED_INDEX_V_MSG`. + * Only use this macro if there is no sensible fallback i.e. the error is unrecoverable. + * + * Ensures an unsigned integer index `m_index` is less than `m_size`. + * If not, prints `m_msg` and the application crashes. + */ +#define CRASH_BAD_UNSIGNED_INDEX_MSG(m_index, m_size, m_msg) \ + do { \ + if (unlikely((m_index) >= (m_size))) { \ + _err_print_index_error(FUNCTION_STR, __FILE__, __LINE__, m_index, m_size, _STR(m_index), _STR(m_size), DEBUG_STR(m_msg), true); \ + GENERATE_TRAP(); \ + } \ + } while (0) -/** An error condition happened (m_cond tested true) (WARNING this is the opposite as assert(). - * the function will exit. - */ +// Null reference error macros. +/** + * Try using `ERR_FAIL_NULL_MSG`. + * Only use this macro if there is no sensible error message. + * + * Ensures a pointer `m_param` is not null. + * If it is null, the current function returns. + */ #define ERR_FAIL_NULL(m_param) \ - { \ + do { \ if (unlikely(!m_param)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Parameter ' " _STR(m_param) " ' is null."); \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Parameter \"" _STR(m_param) "\" is null."); \ return; \ } \ - } + } while (0) +/** + * Ensures a pointer `m_param` is not null. + * If it is null, prints `m_msg` and the current function returns. + */ #define ERR_FAIL_NULL_MSG(m_param, m_msg) \ - { \ + do { \ if (unlikely(!m_param)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Parameter ' " _STR(m_param) " ' is null.", DEBUG_STR(m_msg)); \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Parameter \"" _STR(m_param) "\" is null.", DEBUG_STR(m_msg)); \ return; \ } \ - } + } while (0) +/** + * Try using `ERR_FAIL_NULL_V_MSG`. + * Only use this macro if there is no sensible error message. + * + * Ensures a pointer `m_param` is not null. + * If it is null, the current function returns `m_retval`. + */ #define ERR_FAIL_NULL_V(m_param, m_retval) \ - { \ + do { \ if (unlikely(!m_param)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Parameter ' " _STR(m_param) " ' is null."); \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Parameter \"" _STR(m_param) "\" is null."); \ return m_retval; \ } \ - } + } while (0) +/** + * Ensures a pointer `m_param` is not null. + * If it is null, prints `m_msg` and the current function returns `m_retval`. + */ #define ERR_FAIL_NULL_V_MSG(m_param, m_retval, m_msg) \ - { \ + do { \ if (unlikely(!m_param)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Parameter ' " _STR(m_param) " ' is null.", DEBUG_STR(m_msg)); \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Parameter \"" _STR(m_param) "\" is null.", DEBUG_STR(m_msg)); \ return m_retval; \ } \ - } + } while (0) -/** An error condition happened (m_cond tested true) (WARNING this is the opposite as assert(). - * the function will exit. +/** + * Try using `ERR_FAIL_COND_MSG`. + * Only use this macro if there is no sensible error message. + * If checking for null use ERR_FAIL_NULL_MSG instead. + * If checking index bounds use ERR_FAIL_INDEX_MSG instead. + * + * Ensures `m_cond` is false. + * If `m_cond` is true, the current function returns. */ - #define ERR_FAIL_COND(m_cond) \ - { \ + do { \ if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition ' " _STR(m_cond) " ' is true."); \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition \"" _STR(m_cond) "\" is true."); \ return; \ } \ - } + } while (0) +/** + * Ensures `m_cond` is false. + * If `m_cond` is true, prints `m_msg` and the current function returns. + * + * If checking for null use ERR_FAIL_NULL_MSG instead. + * If checking index bounds use ERR_FAIL_INDEX_MSG instead. + */ #define ERR_FAIL_COND_MSG(m_cond, m_msg) \ - { \ + do { \ if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition ' " _STR(m_cond) " ' is true.", DEBUG_STR(m_msg)); \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition \"" _STR(m_cond) "\" is true.", DEBUG_STR(m_msg)); \ return; \ } \ - } - -/** Use this one if there is no sensible fallback, that is, the error is unrecoverable. - */ - -#define CRASH_COND(m_cond) \ - { \ - if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "FATAL: Condition ' " _STR(m_cond) " ' is true."); \ - GENERATE_TRAP \ - } \ - } - -#define CRASH_COND_MSG(m_cond, m_msg) \ - { \ - if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "FATAL: Condition ' " _STR(m_cond) " ' is true.", DEBUG_STR(m_msg)); \ - GENERATE_TRAP \ - } \ - } + } while (0) -/** An error condition happened (m_cond tested true) (WARNING this is the opposite as assert(). - * the function will exit. - * This function returns an error value, if returning Error, please select the most - * appropriate error condition from error_macros.h +/** + * Try using `ERR_FAIL_COND_V_MSG`. + * Only use this macro if there is no sensible error message. + * If checking for null use ERR_FAIL_NULL_V_MSG instead. + * If checking index bounds use ERR_FAIL_INDEX_V_MSG instead. + * + * Ensures `m_cond` is false. + * If `m_cond` is true, the current function returns `m_retval`. */ - #define ERR_FAIL_COND_V(m_cond, m_retval) \ - { \ + do { \ if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition ' " _STR(m_cond) " ' is true. returned: " _STR(m_retval)); \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition \"" _STR(m_cond) "\" is true. returned: " _STR(m_retval)); \ return m_retval; \ } \ - } + } while (0) +/** + * Ensures `m_cond` is false. + * If `m_cond` is true, prints `m_msg` and the current function returns `m_retval`. + * + * If checking for null use ERR_FAIL_NULL_V_MSG instead. + * If checking index bounds use ERR_FAIL_INDEX_V_MSG instead. + */ #define ERR_FAIL_COND_V_MSG(m_cond, m_retval, m_msg) \ - { \ + do { \ if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition ' " _STR(m_cond) " ' is true. returned: " _STR(m_retval), DEBUG_STR(m_msg)); \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition \"" _STR(m_cond) "\" is true. returned: " _STR(m_retval), DEBUG_STR(m_msg)); \ return m_retval; \ } \ - } + } while (0) -/** An error condition happened (m_cond tested true) (WARNING this is the opposite as assert(). - * the loop will skip to the next iteration. - */ - -#define ERR_CONTINUE(m_cond) \ - { \ - if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition ' " _STR(m_cond) " ' is true. Continuing..:"); \ - continue; \ - } \ - } - -#define ERR_CONTINUE_MSG(m_cond, m_msg) \ - { \ - if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition ' " _STR(m_cond) " ' is true. Continuing..:", DEBUG_STR(m_msg)); \ - continue; \ - } \ - } - -/** An error condition happened (m_cond tested true) (WARNING this is the opposite as assert(). - * the loop will break +/** + * Try using `ERR_CONTINUE_MSG`. + * Only use this macro if there is no sensible error message. + * + * Ensures `m_cond` is false. + * If `m_cond` is true, the current loop continues. */ - -#define ERR_BREAK(m_cond) \ - { \ +#define ERR_CONTINUE(m_cond) \ + do { \ if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition ' " _STR(m_cond) " ' is true. Breaking..:"); \ - break; \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition \"" _STR(m_cond) "\" is true. Continuing."); \ + continue; \ } \ - } + } while (0) -#define ERR_BREAK_MSG(m_cond, m_msg) \ - { \ +/** + * Ensures `m_cond` is false. + * If `m_cond` is true, prints `m_msg` and the current loop continues. + */ +#define ERR_CONTINUE_MSG(m_cond, m_msg) \ + do { \ if (unlikely(m_cond)) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition ' " _STR(m_cond) " ' is true. Breaking..:", DEBUG_STR(m_msg)); \ - break; \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition \"" _STR(m_cond) "\" is true. Continuing.", DEBUG_STR(m_msg)); \ + continue; \ } \ - } + } while (0) + +/** + * Try using `ERR_BREAK_MSG`. + * Only use this macro if there is no sensible error message. + * + * Ensures `m_cond` is false. + * If `m_cond` is true, the current loop breaks. + */ +#define ERR_BREAK(m_cond) \ + do { \ + if (unlikely(m_cond)) { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition \"" _STR(m_cond) "\" is true. Breaking."); \ + break; \ + } \ + } while (0) + +/** + * Ensures `m_cond` is false. + * If `m_cond` is true, prints `m_msg` and the current loop breaks. + */ +#define ERR_BREAK_MSG(m_cond, m_msg) \ + do { \ + if (unlikely(m_cond)) { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Condition \"" _STR(m_cond) "\" is true. Breaking.", DEBUG_STR(m_msg)); \ + break; \ + } \ + } while (0) + +/** + * Try using `ERR_FAIL_COND_MSG` or `ERR_FAIL_COND_V_MSG`. + * Only use this macro if there is no sensible fallback i.e. the error is unrecoverable, and + * there is no sensible error message. + * + * Ensures `m_cond` is false. + * If `m_cond` is true, the application crashes. + */ +#define CRASH_COND(m_cond) \ + do { \ + if (unlikely(m_cond)) { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "FATAL: Condition \"" _STR(m_cond) "\" is true."); \ + GENERATE_TRAP(); \ + } \ + } while (0) -/** Print an error string and return +/** + * Try using `ERR_FAIL_COND_MSG` or `ERR_FAIL_COND_V_MSG`. + * Only use this macro if there is no sensible fallback i.e. the error is unrecoverable. + * + * Ensures `m_cond` is false. + * If `m_cond` is true, prints `m_msg` and the application crashes. */ +#define CRASH_COND_MSG(m_cond, m_msg) \ + do { \ + if (unlikely(m_cond)) { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "FATAL: Condition \"" _STR(m_cond) "\" is true.", DEBUG_STR(m_msg)); \ + GENERATE_TRAP(); \ + } \ + } while (0) +// Generic error macros. + +/** + * Try using `ERR_FAIL_COND_MSG` or `ERR_FAIL_MSG`. + * Only use this macro if more complex error detection or recovery is required, and + * there is no sensible error message. + * + * The current function returns. + */ #define ERR_FAIL() \ - { \ + do { \ _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Method/Function Failed."); \ return; \ - } + } while (0) +/** + * Try using `ERR_FAIL_COND_MSG`. + * Only use this macro if more complex error detection or recovery is required. + * + * Prints `m_msg`, and the current function returns. + */ #define ERR_FAIL_MSG(m_msg) \ - { \ + do { \ _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Method/Function Failed.", DEBUG_STR(m_msg)); \ return; \ - } + } while (0) -/** Print an error string and return with value +/** + * Try using `ERR_FAIL_COND_V_MSG` or `ERR_FAIL_V_MSG`. + * Only use this macro if more complex error detection or recovery is required, and + * there is no sensible error message. + * + * The current function returns `m_retval`. */ - -#define ERR_FAIL_V(m_value) \ - { \ +#define ERR_FAIL_V(m_retval) \ + do { \ _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Method/Function Failed, returning: " __STR(m_value)); \ - return m_value; \ - } + return m_retval; \ + } while (0) -#define ERR_FAIL_V_MSG(m_value, m_msg) \ - { \ +/** + * Try using `ERR_FAIL_COND_V_MSG`. + * Only use this macro if more complex error detection or recovery is required. + * + * Prints `m_msg`, and the current function returns `m_retval`. + */ +#define ERR_FAIL_V_MSG(m_retval, m_msg) \ + do { \ _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "Method/Function Failed, returning: " __STR(m_value), DEBUG_STR(m_msg)); \ - return m_value; \ - } + return m_retval; \ + } while (0) -/** Use this one if there is no sensible fallback, that is, the error is unrecoverable. +/** + * Try using `ERR_FAIL_COND_MSG`, `ERR_FAIL_COND_V_MSG`, `ERR_CONTINUE_MSG` or ERR_BREAK_MSG. + * Only use this macro at the start of a function that has not been implemented yet, or + * if more complex error detection or recovery is required. + * + * Prints `m_msg`. */ +#define ERR_PRINT(m_msg) \ + do { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, DEBUG_STR(m_msg)); \ + } while (0) -#define CRASH_NOW() \ - { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "FATAL: Method/Function Failed."); \ - GENERATE_TRAP \ - } - -#define CRASH_NOW_MSG(m_msg) \ - { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "FATAL: Method/Function Failed.", DEBUG_STR(m_msg)); \ - GENERATE_TRAP \ - } - -/** Print an error string. +/** + * Prints `m_msg` once during the application lifetime. */ +#define ERR_PRINT_ONCE(m_msg) \ + do { \ + static bool first_print = true; \ + if (first_print) { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, DEBUG_STR(m_msg)); \ + first_print = false; \ + } \ + } while (0) -#define ERR_PRINT(m_string) \ - { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, m_string); \ - } +// Print warning message macros. -#define ERR_PRINTS(m_string) \ - { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, m_string); \ - } - -#define ERR_PRINT_ONCE(m_string) \ - { \ - static bool first_print = true; \ - if (first_print) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, m_string); \ - first_print = false; \ - } \ - } +/** + * Prints `m_msg`. + * + * If warning about deprecated usage, use `WARN_DEPRECATED` or `WARN_DEPRECATED_MSG` instead. + */ +#define WARN_PRINT(m_msg) \ + do { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, DEBUG_STR(m_msg), ERR_HANDLER_WARNING); \ + } while (0) -/** Print a warning string. +/** + * Prints `m_msg` once during the application lifetime. + * + * If warning about deprecated usage, use `WARN_DEPRECATED` or `WARN_DEPRECATED_MSG` instead. */ +#define WARN_PRINT_ONCE(m_msg) \ + do { \ + static bool first_print = true; \ + if (first_print) { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, DEBUG_STR(m_msg), ERR_HANDLER_WARNING); \ + first_print = false; \ + } \ + } while (0) -#define WARN_PRINT(m_string) \ - { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, m_string, ERR_HANDLER_WARNING); \ - } +// Print deprecated warning message macros. -#define WARN_PRINTS(m_string) \ - { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, m_string, ERR_HANDLER_WARNING); \ - } +/** + * Warns that the current function is deprecated. + */ +#define WARN_DEPRECATED \ + do { \ + static volatile bool warning_shown = false; \ + if (!warning_shown) { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "This method has been deprecated and will be removed in the future.", ERR_HANDLER_WARNING); \ + warning_shown = true; \ + } \ + } while (0) -#define WARN_PRINT_ONCE(m_string) \ - { \ - static bool first_print = true; \ - if (first_print) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, m_string, ERR_HANDLER_WARNING); \ - first_print = false; \ - } \ - } +/** + * Warns that the current function is deprecated and prints `m_msg`. + */ +#define WARN_DEPRECATED_MSG(m_msg) \ + do { \ + static volatile bool warning_shown = false; \ + if (!warning_shown) { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "This method has been deprecated and will be removed in the future.", DEBUG_STR(m_msg), ERR_HANDLER_WARNING); \ + warning_shown = true; \ + } \ + } while (0) -#define WARN_DEPRECATED \ - { \ - static volatile bool warning_shown = false; \ - if (!warning_shown) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "This method has been deprecated and will be removed in the future", ERR_HANDLER_WARNING); \ - warning_shown = true; \ - } \ - } +/** + * Do not use. + * If the application should never reach this point use CRASH_NOW_MSG(m_msg) to explain why. + * + * The application crashes. + */ +#define CRASH_NOW() \ + do { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "FATAL: Method/Function Failed."); \ + GENERATE_TRAP(); \ + } while (0) -#define WARN_DEPRECATED_MSG(m_msg) \ - { \ - static volatile bool warning_shown = false; \ - if (!warning_shown) { \ - _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "This method has been deprecated and will be removed in the future", m_msg, ERR_HANDLER_WARNING); \ - warning_shown = true; \ - } \ - } +/** + * Only use if the application should never reach this point. + * + * Prints `m_msg`, and then the application crashes. + */ +#define CRASH_NOW_MSG(m_msg) \ + do { \ + _err_print_error(FUNCTION_STR, __FILE__, __LINE__, "FATAL: Method/Function Failed.", DEBUG_STR(m_msg)); \ + GENERATE_TRAP(); \ + } while (0) #endif diff --git a/core/image.cpp b/core/image.cpp index 672f850a1f..09b07bba13 100644 --- a/core/image.cpp +++ b/core/image.cpp @@ -421,6 +421,8 @@ void Image::convert(Format p_new_format) { if (p_new_format == format) return; + ERR_FAIL_COND_MSG(write_lock.ptr(), "Cannot convert image when it is locked."); + if (format > FORMAT_RGBE9995 || p_new_format > FORMAT_RGBE9995) { ERR_FAIL_MSG("Cannot convert to <-> from compressed formats. Use compress() and decompress() instead."); @@ -880,8 +882,8 @@ void Image::resize_to_po2(bool p_square) { void Image::resize(int p_width, int p_height, Interpolation p_interpolation) { ERR_FAIL_COND_MSG(data.size() == 0, "Cannot resize image before creating it, use create() or create_from_data() first."); - ERR_FAIL_COND_MSG(!_can_modify(format), "Cannot resize in compressed or custom image formats."); + ERR_FAIL_COND_MSG(write_lock.ptr(), "Cannot resize image when it is locked."); bool mipmap_aware = p_interpolation == INTERPOLATE_TRILINEAR /* || p_interpolation == INTERPOLATE_TRICUBIC */; @@ -1877,7 +1879,7 @@ Image::AlphaMode Image::detect_alpha() const { Error Image::load(const String &p_path) { #ifdef DEBUG_ENABLED if (p_path.begins_with("res://") && ResourceLoader::exists(p_path)) { - WARN_PRINTS("Loaded resource as image file, this will not work on export: '" + p_path + "'. Instead, import the image file as an Image resource and load it normally as a resource."); + WARN_PRINT("Loaded resource as image file, this will not work on export: '" + p_path + "'. Instead, import the image file as an Image resource and load it normally as a resource."); } #endif return ImageLoader::load_image(p_path, this); @@ -2027,8 +2029,7 @@ Rect2 Image::get_used_rect() const { for (int j = 0; j < height; j++) { for (int i = 0; i < width; i++) { - bool opaque = get_pixel(i, j).a > 0.99; - if (!opaque) + if (!(get_pixel(i, j).a > 0)) continue; if (i > maxx) maxx = i; @@ -2064,6 +2065,7 @@ void Image::blit_rect(const Ref<Image> &p_src, const Rect2 &p_src_rect, const Po ERR_FAIL_COND(dsize == 0); ERR_FAIL_COND(srcdsize == 0); ERR_FAIL_COND(format != p_src->format); + ERR_FAIL_COND_MSG(!_can_modify(format), "Cannot blit_rect in compressed or custom image formats."); Rect2i clipped_src_rect = Rect2i(0, 0, p_src->width, p_src->height).clip(p_src_rect); @@ -2284,6 +2286,7 @@ void Image::blend_rect_mask(const Ref<Image> &p_src, const Ref<Image> &p_mask, c } void Image::fill(const Color &c) { + ERR_FAIL_COND_MSG(!_can_modify(format), "Cannot fill in compressed or custom image formats."); lock(); diff --git a/core/io/config_file.cpp b/core/io/config_file.cpp index 5c25cad770..99da512247 100644 --- a/core/io/config_file.cpp +++ b/core/io/config_file.cpp @@ -275,7 +275,7 @@ Error ConfigFile::_internal_load(const String &p_path, FileAccess *f) { memdelete(f); return OK; } else if (err != OK) { - ERR_PRINTS("ConfgFile::load - " + p_path + ":" + itos(lines) + " error: " + error_text + "."); + ERR_PRINT("ConfgFile::load - " + p_path + ":" + itos(lines) + " error: " + error_text + "."); memdelete(f); return err; } diff --git a/core/io/image_loader.cpp b/core/io/image_loader.cpp index 05929ee8ed..720f25f91b 100644 --- a/core/io/image_loader.cpp +++ b/core/io/image_loader.cpp @@ -53,7 +53,7 @@ Error ImageLoader::load_image(String p_file, Ref<Image> p_image, FileAccess *p_c Error err; f = FileAccess::open(p_file, FileAccess::READ, &err); if (!f) { - ERR_PRINTS("Error opening file '" + p_file + "'."); + ERR_PRINT("Error opening file '" + p_file + "'."); return err; } } @@ -66,7 +66,7 @@ Error ImageLoader::load_image(String p_file, Ref<Image> p_image, FileAccess *p_c continue; Error err = loader[i]->load_image(p_image, f, p_force_linear, p_scale); if (err != OK) { - ERR_PRINTS("Error loading image: " + p_file); + ERR_PRINT("Error loading image: " + p_file); } if (err != ERR_FILE_UNRECOGNIZED) { diff --git a/core/io/ip.cpp b/core/io/ip.cpp index ea791fb327..23f6ca25d0 100644 --- a/core/io/ip.cpp +++ b/core/io/ip.cpp @@ -184,7 +184,7 @@ IP_Address IP::get_resolve_item_address(ResolverID p_id) const { resolver->mutex->lock(); if (resolver->queue[p_id].status != IP::RESOLVER_STATUS_DONE) { - ERR_PRINTS("Resolve of '" + resolver->queue[p_id].hostname + "'' didn't complete yet."); + ERR_PRINT("Resolve of '" + resolver->queue[p_id].hostname + "'' didn't complete yet."); resolver->mutex->unlock(); return IP_Address(); } diff --git a/core/io/multiplayer_api.cpp b/core/io/multiplayer_api.cpp index 2708cb8c01..fbed460a4e 100644 --- a/core/io/multiplayer_api.cpp +++ b/core/io/multiplayer_api.cpp @@ -111,6 +111,7 @@ void MultiplayerAPI::poll() { Error err = network_peer->get_packet(&packet, len); if (err != OK) { ERR_PRINT("Error getting packet!"); + break; // Something is wrong! } rpc_sender_id = sender; @@ -252,7 +253,7 @@ Node *MultiplayerAPI::_process_get_node(int p_from, const uint8_t *p_packet, int node = root_node->get_node(np); if (!node) - ERR_PRINTS("Failed to get path from RPC: " + String(np) + "."); + ERR_PRINT("Failed to get path from RPC: " + String(np) + "."); } else { // Use cached path. int id = target; @@ -268,7 +269,7 @@ Node *MultiplayerAPI::_process_get_node(int p_from, const uint8_t *p_packet, int node = root_node->get_node(ni->path); if (!node) - ERR_PRINTS("Failed to get cached path from RPC: " + String(ni->path) + "."); + ERR_PRINT("Failed to get cached path from RPC: " + String(ni->path) + "."); } return node; } @@ -323,7 +324,7 @@ void MultiplayerAPI::_process_rpc(Node *p_node, const StringName &p_name, int p_ if (ce.error != Variant::CallError::CALL_OK) { String error = Variant::get_call_error_text(p_node, p_name, (const Variant **)argp.ptr(), argc, ce); error = "RPC - " + error; - ERR_PRINTS(error); + ERR_PRINT(error); } } @@ -361,7 +362,7 @@ void MultiplayerAPI::_process_rset(Node *p_node, const StringName &p_name, int p p_node->set(p_name, value, &valid); if (!valid) { String error = "Error setting remote property '" + String(p_name) + "', not found in object of type " + p_node->get_class() + "."; - ERR_PRINTS(error); + ERR_PRINT(error); } } @@ -682,7 +683,7 @@ void MultiplayerAPI::rpcp(Node *p_node, int p_peer_id, bool p_unreliable, const if (ce.error != Variant::CallError::CALL_OK) { String error = Variant::get_call_error_text(p_node, p_method, p_arg, p_argcount, ce); error = "rpc() aborted in local call: - " + error + "."; - ERR_PRINTS(error); + ERR_PRINT(error); return; } } @@ -697,7 +698,7 @@ void MultiplayerAPI::rpcp(Node *p_node, int p_peer_id, bool p_unreliable, const if (ce.error != Variant::CallError::CALL_OK) { String error = Variant::get_call_error_text(p_node, p_method, p_arg, p_argcount, ce); error = "rpc() aborted in script local call: - " + error + "."; - ERR_PRINTS(error); + ERR_PRINT(error); return; } } @@ -734,7 +735,7 @@ void MultiplayerAPI::rsetp(Node *p_node, int p_peer_id, bool p_unreliable, const if (!valid) { String error = "rset() aborted in local set, property not found: - " + String(p_property) + "."; - ERR_PRINTS(error); + ERR_PRINT(error); return; } } else if (p_node->get_script_instance()) { @@ -752,7 +753,7 @@ void MultiplayerAPI::rsetp(Node *p_node, int p_peer_id, bool p_unreliable, const if (!valid) { String error = "rset() aborted in local script set, property not found: - " + String(p_property) + "."; - ERR_PRINTS(error); + ERR_PRINT(error); return; } } diff --git a/core/io/packet_peer.cpp b/core/io/packet_peer.cpp index ae0520df6e..9e53d773ba 100644 --- a/core/io/packet_peer.cpp +++ b/core/io/packet_peer.cpp @@ -37,7 +37,8 @@ PacketPeer::PacketPeer() : last_get_error(OK), - allow_object_decoding(false) { + allow_object_decoding(false), + encode_buffer_max_size(8 * 1024 * 1024) { } void PacketPeer::set_allow_object_decoding(bool p_enable) { @@ -50,6 +51,19 @@ bool PacketPeer::is_object_decoding_allowed() const { return allow_object_decoding; } +void PacketPeer::set_encode_buffer_max_size(int p_max_size) { + + ERR_FAIL_COND_MSG(p_max_size < 1024, "Max encode buffer must be at least 1024 bytes"); + ERR_FAIL_COND_MSG(p_max_size > 256 * 1024 * 1024, "Max encode buffer cannot exceed 256 MiB"); + encode_buffer_max_size = next_power_of_2(p_max_size); + encode_buffer.resize(0); +} + +int PacketPeer::get_encode_buffer_max_size() const { + + return encode_buffer_max_size; +} + Error PacketPeer::get_packet_buffer(PoolVector<uint8_t> &r_buffer) { const uint8_t *buffer; @@ -100,12 +114,18 @@ Error PacketPeer::put_var(const Variant &p_packet, bool p_full_objects) { if (len == 0) return OK; - uint8_t *buf = (uint8_t *)alloca(len); - ERR_FAIL_COND_V_MSG(!buf, ERR_OUT_OF_MEMORY, "Out of memory."); - err = encode_variant(p_packet, buf, len, p_full_objects || allow_object_decoding); + ERR_FAIL_COND_V_MSG(len > encode_buffer_max_size, ERR_OUT_OF_MEMORY, "Failed to encode variant, encode size is bigger then encode_buffer_max_size. Consider raising it via 'set_encode_buffer_max_size'."); + + if (unlikely(encode_buffer.size() < len)) { + encode_buffer.resize(0); // Avoid realloc + encode_buffer.resize(next_power_of_2(len)); + } + + PoolVector<uint8_t>::Write w = encode_buffer.write(); + err = encode_variant(p_packet, w.ptr(), len, p_full_objects || allow_object_decoding); ERR_FAIL_COND_V_MSG(err != OK, err, "Error when trying to encode Variant."); - return put_packet(buf, len); + return put_packet(w.ptr(), len); } Variant PacketPeer::_bnd_get_var(bool p_allow_objects) { @@ -142,7 +162,10 @@ void PacketPeer::_bind_methods() { ClassDB::bind_method(D_METHOD("set_allow_object_decoding", "enable"), &PacketPeer::set_allow_object_decoding); ClassDB::bind_method(D_METHOD("is_object_decoding_allowed"), &PacketPeer::is_object_decoding_allowed); + ClassDB::bind_method(D_METHOD("get_encode_buffer_max_size"), &PacketPeer::get_encode_buffer_max_size); + ClassDB::bind_method(D_METHOD("set_encode_buffer_max_size", "max_size"), &PacketPeer::set_encode_buffer_max_size); + ADD_PROPERTY(PropertyInfo(Variant::INT, "encode_buffer_max_size"), "set_encode_buffer_max_size", "get_encode_buffer_max_size"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "allow_object_decoding"), "set_allow_object_decoding", "is_object_decoding_allowed"); }; diff --git a/core/io/packet_peer.h b/core/io/packet_peer.h index f1870e8ef1..2b13f2e952 100644 --- a/core/io/packet_peer.h +++ b/core/io/packet_peer.h @@ -51,6 +51,9 @@ class PacketPeer : public Reference { bool allow_object_decoding; + int encode_buffer_max_size; + PoolVector<uint8_t> encode_buffer; + public: virtual int get_available_packet_count() const = 0; virtual Error get_packet(const uint8_t **r_buffer, int &r_buffer_size) = 0; ///< buffer is GONE after next get_packet @@ -69,6 +72,9 @@ public: void set_allow_object_decoding(bool p_enable); bool is_object_decoding_allowed() const; + void set_encode_buffer_max_size(int p_max_size); + int get_encode_buffer_max_size() const; + PacketPeer(); ~PacketPeer() {} }; diff --git a/core/io/packet_peer_udp.cpp b/core/io/packet_peer_udp.cpp index 5c98c4fcab..a8cfd741bb 100644 --- a/core/io/packet_peer_udp.cpp +++ b/core/io/packet_peer_udp.cpp @@ -222,7 +222,7 @@ Error PacketPeerUDP::_poll() { if (rb.space_left() < read + 24) { #ifdef TOOLS_ENABLED - WARN_PRINTS("Buffer full, dropping packets!"); + WARN_PRINT("Buffer full, dropping packets!"); #endif continue; } diff --git a/core/io/pck_packer.cpp b/core/io/pck_packer.cpp index 8bc73103e9..fb83f0ac90 100644 --- a/core/io/pck_packer.cpp +++ b/core/io/pck_packer.cpp @@ -63,6 +63,10 @@ void PCKPacker::_bind_methods() { Error PCKPacker::pck_start(const String &p_file, int p_alignment) { + if (file != NULL) { + memdelete(file); + } + file = FileAccess::open(p_file, FileAccess::WRITE); ERR_FAIL_COND_V_MSG(!file, ERR_CANT_CREATE, "Can't open file to write: " + String(p_file) + "."); diff --git a/core/io/resource_format_binary.cpp b/core/io/resource_format_binary.cpp index 272d5c1116..97dca98185 100644 --- a/core/io/resource_format_binary.cpp +++ b/core/io/resource_format_binary.cpp @@ -1113,7 +1113,7 @@ Error ResourceFormatLoaderBinary::rename_dependencies(const String &p_path, cons memdelete(da); //use the old approach - WARN_PRINTS("This file is old, so it can't refactor dependencies, opening and resaving '" + p_path + "'."); + WARN_PRINT("This file is old, so it can't refactor dependencies, opening and resaving '" + p_path + "'."); Error err; f = FileAccess::open(p_path, FileAccess::READ, &err); @@ -1635,7 +1635,7 @@ void ResourceFormatSaverBinaryInstance::_find_resources(const Variant &p_variant if (!p_main && (!bundle_resources) && res->get_path().length() && res->get_path().find("::") == -1) { if (res->get_path() == path) { - ERR_PRINTS("Circular reference to resource being saved found: '" + local_path + "' will be null next time it's loaded."); + ERR_PRINT("Circular reference to resource being saved found: '" + local_path + "' will be null next time it's loaded."); return; } int idx = external_resources.size(); diff --git a/core/io/resource_importer.cpp b/core/io/resource_importer.cpp index c2d90ed204..f147170ff7 100644 --- a/core/io/resource_importer.cpp +++ b/core/io/resource_importer.cpp @@ -74,7 +74,7 @@ Error ResourceFormatImporter::_get_path_and_type(const String &p_path, PathAndTy memdelete(f); return OK; } else if (err != OK) { - ERR_PRINTS("ResourceFormatImporter::load - " + p_path + ".import:" + itos(lines) + " error: " + error_text); + ERR_PRINT("ResourceFormatImporter::load - " + p_path + ".import:" + itos(lines) + " error: " + error_text); memdelete(f); return err; } @@ -279,7 +279,7 @@ void ResourceFormatImporter::get_internal_resource_path_list(const String &p_pat memdelete(f); return; } else if (err != OK) { - ERR_PRINTS("ResourceFormatImporter::get_internal_resource_path_list - " + p_path + ".import:" + itos(lines) + " error: " + error_text); + ERR_PRINT("ResourceFormatImporter::get_internal_resource_path_list - " + p_path + ".import:" + itos(lines) + " error: " + error_text); memdelete(f); return; } diff --git a/core/io/resource_loader.cpp b/core/io/resource_loader.cpp index 7471ab4241..0e1ada9475 100644 --- a/core/io/resource_loader.cpp +++ b/core/io/resource_loader.cpp @@ -815,7 +815,7 @@ String ResourceLoader::_path_remap(const String &p_path, bool *r_translation_rem if (err == ERR_FILE_EOF) { break; } else if (err != OK) { - ERR_PRINTS("Parse error: " + p_path + ".remap:" + itos(lines) + " error: " + error_text + "."); + ERR_PRINT("Parse error: " + p_path + ".remap:" + itos(lines) + " error: " + error_text + "."); break; } @@ -1013,7 +1013,7 @@ void ResourceLoader::finalize() { #ifndef NO_THREADS const LoadingMapKey *K = NULL; while ((K = loading_map.next(K))) { - ERR_PRINTS("Exited while resource is being loaded: " + K->path); + ERR_PRINT("Exited while resource is being loaded: " + K->path); } loading_map.clear(); memdelete(loading_map_mutex); diff --git a/core/io/xml_parser.cpp b/core/io/xml_parser.cpp index 53e7da91a7..bd450dd84f 100644 --- a/core/io/xml_parser.cpp +++ b/core/io/xml_parser.cpp @@ -471,6 +471,10 @@ Error XMLParser::open_buffer(const Vector<uint8_t> &p_buffer) { ERR_FAIL_COND_V(p_buffer.size() == 0, ERR_INVALID_DATA); + if (data) { + memdelete_arr(data); + } + length = p_buffer.size(); data = memnew_arr(char, length + 1); copymem(data, p_buffer.ptr(), length); @@ -489,6 +493,10 @@ Error XMLParser::open(const String &p_path) { length = file->get_len(); ERR_FAIL_COND_V(length < 1, ERR_FILE_CORRUPT); + if (data) { + memdelete_arr(data); + } + data = memnew_arr(char, length + 1); file->get_buffer((uint8_t *)data, length); data[length] = 0; diff --git a/core/io/zip_io.cpp b/core/io/zip_io.cpp index 582b7c906b..40e902d874 100644 --- a/core/io/zip_io.cpp +++ b/core/io/zip_io.cpp @@ -97,6 +97,7 @@ int zipio_close(voidpf opaque, voidpf stream) { FileAccess *&f = *(FileAccess **)opaque; if (f) { f->close(); + memdelete(f); f = NULL; } return 0; diff --git a/core/math/basis.cpp b/core/math/basis.cpp index d15cb71db9..ddf5f13d55 100644 --- a/core/math/basis.cpp +++ b/core/math/basis.cpp @@ -800,7 +800,7 @@ void Basis::set_quat(const Quat &p_quat) { void Basis::set_axis_angle(const Vector3 &p_axis, real_t p_phi) { // Rotation matrix from axis and angle, see https://en.wikipedia.org/wiki/Rotation_matrix#Rotation_matrix_from_axis_angle #ifdef MATH_CHECKS - ERR_FAIL_COND_MSG(!p_axis.is_normalized(), "Axis must be normalized."); + ERR_FAIL_COND_MSG(!p_axis.is_normalized(), "The axis Vector3 must be normalized."); #endif Vector3 axis_sq(p_axis.x * p_axis.x, p_axis.y * p_axis.y, p_axis.z * p_axis.z); real_t cosine = Math::cos(p_phi); diff --git a/core/math/bsp_tree.cpp b/core/math/bsp_tree.cpp index f155d626d7..7ad907db97 100644 --- a/core/math/bsp_tree.cpp +++ b/core/math/bsp_tree.cpp @@ -341,7 +341,7 @@ static int _bsp_create_node(const Face3 *p_faces, const Vector<int> &p_indices, ERR_FAIL_COND_V(p_nodes.size() == BSP_Tree::MAX_NODES, -1); // should not reach here - ERR_FAIL_COND_V(p_indices.size() == 0, -1) + ERR_FAIL_COND_V(p_indices.size() == 0, -1); int ic = p_indices.size(); const int *indices = p_indices.ptr(); diff --git a/core/math/camera_matrix.cpp b/core/math/camera_matrix.cpp index 165bb9f823..380bae871a 100644 --- a/core/math/camera_matrix.cpp +++ b/core/math/camera_matrix.cpp @@ -247,7 +247,7 @@ real_t CameraMatrix::get_z_near() const { return new_plane.d; } -void CameraMatrix::get_viewport_size(real_t &r_width, real_t &r_height) const { +Vector2 CameraMatrix::get_viewport_half_extents() const { const real_t *matrix = (const real_t *)this->matrix; ///////--- Near Plane ---/////// @@ -273,8 +273,7 @@ void CameraMatrix::get_viewport_size(real_t &r_width, real_t &r_height) const { Vector3 res; near_plane.intersect_3(right_plane, top_plane, &res); - r_width = res.x; - r_height = res.y; + return Vector2(res.x, res.y); } bool CameraMatrix::get_endpoints(const Transform &p_transform, Vector3 *p_8points) const { @@ -563,9 +562,8 @@ CameraMatrix::operator String() const { real_t CameraMatrix::get_aspect() const { - real_t w, h; - get_viewport_size(w, h); - return w / h; + Vector2 vp_he = get_viewport_half_extents(); + return vp_he.x / vp_he.y; } int CameraMatrix::get_pixels_per_meter(int p_for_pixel_width) const { diff --git a/core/math/camera_matrix.h b/core/math/camera_matrix.h index 59e34c0855..2eed6d25d6 100644 --- a/core/math/camera_matrix.h +++ b/core/math/camera_matrix.h @@ -73,7 +73,7 @@ struct CameraMatrix { Vector<Plane> get_projection_planes(const Transform &p_transform) const; bool get_endpoints(const Transform &p_transform, Vector3 *p_8points) const; - void get_viewport_size(real_t &r_width, real_t &r_height) const; + Vector2 get_viewport_half_extents() const; void invert(); CameraMatrix inverse() const; diff --git a/core/math/quat.cpp b/core/math/quat.cpp index 418abf4384..61cd41b23d 100644 --- a/core/math/quat.cpp +++ b/core/math/quat.cpp @@ -100,7 +100,7 @@ void Quat::set_euler_yxz(const Vector3 &p_euler) { // This implementation uses YXZ convention (Z is the first rotation). Vector3 Quat::get_euler_yxz() const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!is_normalized(), Vector3(0, 0, 0)); + ERR_FAIL_COND_V_MSG(!is_normalized(), Vector3(0, 0, 0), "The quaternion must be normalized."); #endif Basis m(*this); return m.get_euler_yxz(); @@ -145,15 +145,15 @@ bool Quat::is_normalized() const { Quat Quat::inverse() const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!is_normalized(), Quat(), "The quaternion must be normalized."); #endif return Quat(-x, -y, -z, w); } Quat Quat::slerp(const Quat &q, const real_t &t) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!is_normalized(), Quat()); - ERR_FAIL_COND_V(!q.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!is_normalized(), Quat(), "The start quaternion must be normalized."); + ERR_FAIL_COND_V_MSG(!q.is_normalized(), Quat(), "The end quaternion must be normalized."); #endif Quat to1; real_t omega, cosom, sinom, scale0, scale1; @@ -199,8 +199,8 @@ Quat Quat::slerp(const Quat &q, const real_t &t) const { Quat Quat::slerpni(const Quat &q, const real_t &t) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!is_normalized(), Quat()); - ERR_FAIL_COND_V(!q.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!is_normalized(), Quat(), "The start quaternion must be normalized."); + ERR_FAIL_COND_V_MSG(!q.is_normalized(), Quat(), "The end quaternion must be normalized."); #endif const Quat &from = *this; @@ -221,8 +221,8 @@ Quat Quat::slerpni(const Quat &q, const real_t &t) const { Quat Quat::cubic_slerp(const Quat &q, const Quat &prep, const Quat &postq, const real_t &t) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!is_normalized(), Quat()); - ERR_FAIL_COND_V(!q.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!is_normalized(), Quat(), "The start quaternion must be normalized."); + ERR_FAIL_COND_V_MSG(!q.is_normalized(), Quat(), "The end quaternion must be normalized."); #endif //the only way to do slerp :| real_t t2 = (1.0 - t) * t * 2; @@ -238,7 +238,7 @@ Quat::operator String() const { void Quat::set_axis_angle(const Vector3 &axis, const real_t &angle) { #ifdef MATH_CHECKS - ERR_FAIL_COND(!axis.is_normalized()); + ERR_FAIL_COND_MSG(!axis.is_normalized(), "The axis Vector3 must be normalized."); #endif real_t d = axis.length(); if (d == 0) diff --git a/core/math/quat.h b/core/math/quat.h index c337192a5b..11ae03dffb 100644 --- a/core/math/quat.h +++ b/core/math/quat.h @@ -84,7 +84,7 @@ public: _FORCE_INLINE_ Vector3 xform(const Vector3 &v) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!is_normalized(), v); + ERR_FAIL_COND_V_MSG(!is_normalized(), v, "The quaternion must be normalized."); #endif Vector3 u(x, y, z); Vector3 uv = u.cross(v); diff --git a/core/math/vector2.cpp b/core/math/vector2.cpp index b306ad3d09..f4259e388b 100644 --- a/core/math/vector2.cpp +++ b/core/math/vector2.cpp @@ -187,7 +187,7 @@ Vector2 Vector2::move_toward(const Vector2 &p_to, const real_t p_delta) const { // slide returns the component of the vector along the given plane, specified by its normal vector. Vector2 Vector2::slide(const Vector2 &p_normal) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!p_normal.is_normalized(), Vector2()); + ERR_FAIL_COND_V_MSG(!p_normal.is_normalized(), Vector2(), "The normal Vector2 must be normalized."); #endif return *this - p_normal * this->dot(p_normal); } @@ -198,7 +198,7 @@ Vector2 Vector2::bounce(const Vector2 &p_normal) const { Vector2 Vector2::reflect(const Vector2 &p_normal) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!p_normal.is_normalized(), Vector2()); + ERR_FAIL_COND_V_MSG(!p_normal.is_normalized(), Vector2(), "The normal Vector2 must be normalized."); #endif return 2.0 * p_normal * this->dot(p_normal) - *this; } diff --git a/core/math/vector2.h b/core/math/vector2.h index 351c974cf3..1dec830821 100644 --- a/core/math/vector2.h +++ b/core/math/vector2.h @@ -242,7 +242,7 @@ Vector2 Vector2::linear_interpolate(const Vector2 &p_b, real_t p_t) const { Vector2 Vector2::slerp(const Vector2 &p_b, real_t p_t) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!is_normalized(), Vector2()); + ERR_FAIL_COND_V_MSG(!is_normalized(), Vector2(), "The start Vector2 must be normalized."); #endif real_t theta = angle_to(p_b); return rotated(theta * p_t); diff --git a/core/math/vector3.h b/core/math/vector3.h index 9bf7c41729..4ad3017109 100644 --- a/core/math/vector3.h +++ b/core/math/vector3.h @@ -454,7 +454,7 @@ void Vector3::zero() { // slide returns the component of the vector along the given plane, specified by its normal vector. Vector3 Vector3::slide(const Vector3 &p_normal) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!p_normal.is_normalized(), Vector3()); + ERR_FAIL_COND_V_MSG(!p_normal.is_normalized(), Vector3(), "The normal Vector3 must be normalized."); #endif return *this - p_normal * this->dot(p_normal); } @@ -465,7 +465,7 @@ Vector3 Vector3::bounce(const Vector3 &p_normal) const { Vector3 Vector3::reflect(const Vector3 &p_normal) const { #ifdef MATH_CHECKS - ERR_FAIL_COND_V(!p_normal.is_normalized(), Vector3()); + ERR_FAIL_COND_V_MSG(!p_normal.is_normalized(), Vector3(), "The normal Vector3 must be normalized."); #endif return 2.0 * p_normal * this->dot(p_normal) - *this; } diff --git a/core/message_queue.cpp b/core/message_queue.cpp index d130934826..42390935d4 100644 --- a/core/message_queue.cpp +++ b/core/message_queue.cpp @@ -52,7 +52,7 @@ Error MessageQueue::push_call(ObjectID p_id, const StringName &p_method, const V type = ObjectDB::get_instance(p_id)->get_class(); print_line("Failed method: " + type + ":" + p_method + " target ID: " + itos(p_id)); statistics(); - ERR_FAIL_V_MSG(ERR_OUT_OF_MEMORY, "Message queue out of memory. Try increasing 'message_queue_size_kb' in project settings."); + ERR_FAIL_V_MSG(ERR_OUT_OF_MEMORY, "Message queue out of memory. Try increasing 'memory/limits/message_queue/max_size_kb' in project settings."); } Message *msg = memnew_placement(&buffer[buffer_end], Message); @@ -102,7 +102,7 @@ Error MessageQueue::push_set(ObjectID p_id, const StringName &p_prop, const Vari type = ObjectDB::get_instance(p_id)->get_class(); print_line("Failed set: " + type + ":" + p_prop + " target ID: " + itos(p_id)); statistics(); - ERR_FAIL_V_MSG(ERR_OUT_OF_MEMORY, "Message queue out of memory. Try increasing 'message_queue_size_kb' in project settings."); + ERR_FAIL_V_MSG(ERR_OUT_OF_MEMORY, "Message queue out of memory. Try increasing 'memory/limits/message_queue/max_size_kb' in project settings."); } Message *msg = memnew_placement(&buffer[buffer_end], Message); @@ -131,7 +131,7 @@ Error MessageQueue::push_notification(ObjectID p_id, int p_notification) { if ((buffer_end + room_needed) >= buffer_size) { print_line("Failed notification: " + itos(p_notification) + " target ID: " + itos(p_id)); statistics(); - ERR_FAIL_V_MSG(ERR_OUT_OF_MEMORY, "Message queue out of memory. Try increasing 'message_queue_size_kb' in project settings."); + ERR_FAIL_V_MSG(ERR_OUT_OF_MEMORY, "Message queue out of memory. Try increasing 'memory/limits/message_queue/max_size_kb' in project settings."); } Message *msg = memnew_placement(&buffer[buffer_end], Message); @@ -250,7 +250,7 @@ void MessageQueue::_call_function(Object *p_target, const StringName &p_func, co p_target->call(p_func, argptrs, p_argcount, ce); if (p_show_error && ce.error != Variant::CallError::CALL_OK) { - ERR_PRINTS("Error calling deferred method: " + Variant::get_call_error_text(p_target, p_func, argptrs, p_argcount, ce) + "."); + ERR_PRINT("Error calling deferred method: " + Variant::get_call_error_text(p_target, p_func, argptrs, p_argcount, ce) + "."); } } diff --git a/core/object.cpp b/core/object.cpp index 35ccc38d4e..937b1ae8d4 100644 --- a/core/object.cpp +++ b/core/object.cpp @@ -1185,13 +1185,11 @@ Error Object::emit_signal(const StringName &p_name, const Variant **p_args, int const Connection &c = slot_map.getv(i).conn; - Object *target; -#ifdef DEBUG_ENABLED - target = ObjectDB::get_instance(slot_map.getk(i)._id); - ERR_CONTINUE(!target); -#else - target = c.target; -#endif + Object *target = ObjectDB::get_instance(slot_map.getk(i)._id); + if (!target) { + // Target might have been deleted during signal callback, this is expected and OK. + continue; + } const Variant **args = p_args; int argc = p_argcount; @@ -1215,9 +1213,9 @@ Error Object::emit_signal(const StringName &p_name, const Variant **p_args, int MessageQueue::get_singleton()->push_call(target->get_instance_id(), c.method, args, argc, true); } else { Variant::CallError ce; - s->lock++; + _emitting = true; target->call(c.method, args, argc, ce); - s->lock--; + _emitting = false; if (ce.error != Variant::CallError::CALL_OK) { #ifdef DEBUG_ENABLED @@ -1227,7 +1225,7 @@ Error Object::emit_signal(const StringName &p_name, const Variant **p_args, int if (ce.error == Variant::CallError::CALL_ERROR_INVALID_METHOD && !ClassDB::class_exists(target->get_class_name())) { //most likely object is not initialized yet, do not throw error. } else { - ERR_PRINTS("Error calling method from signal '" + String(p_name) + "': " + Variant::get_call_error_text(target, c.method, args, argc, ce) + "."); + ERR_PRINT("Error calling method from signal '" + String(p_name) + "': " + Variant::get_call_error_text(target, c.method, args, argc, ce) + "."); err = ERR_METHOD_NOT_FOUND; } } @@ -1519,10 +1517,6 @@ void Object::_disconnect(const StringName &p_signal, Object *p_to_object, const Signal *s = signal_map.getptr(p_signal); ERR_FAIL_COND_MSG(!s, vformat("Nonexistent signal '%s' in %s.", p_signal, to_string())); - ERR_FAIL_COND_MSG(s->lock > 0, - vformat("Attempt to disconnect %s signal '%s' while in emission callback '%s' (in target %s). Use CONNECT_DEFERRED (to be able to safely disconnect) or CONNECT_ONESHOT (for automatic disconnection) as connection flags.", - to_string(), p_signal, p_to_method, p_to_object->to_string())); - Signal::Target target(p_to_object->get_instance_id(), p_to_method); ERR_FAIL_COND_MSG(!s->slot_map.has(target), "Disconnecting nonexistent signal '" + p_signal + "', slot: " + itos(target._id) + ":" + target.method + "."); @@ -1926,6 +1920,7 @@ Object::Object() { _instance_id = ObjectDB::add_instance(this); _can_translate = true; _is_queued_for_deletion = false; + _emitting = false; instance_binding_count = 0; memset(_script_instance_bindings, 0, sizeof(void *) * MAX_SCRIPT_INSTANCE_BINDINGS); script_instance = NULL; @@ -1948,15 +1943,15 @@ Object::~Object() { const StringName *S = NULL; + if (_emitting) { + //@todo this may need to actually reach the debugger prioritarily somehow because it may crash before + ERR_PRINT("Object " + to_string() + " was freed or unreferenced while a signal is being emitted from it. Try connecting to the signal using 'CONNECT_DEFERRED' flag, or use queue_free() to free the object (if this object is a Node) to avoid this error and potential crashes."); + } + while ((S = signal_map.next(NULL))) { Signal *s = &signal_map[*S]; - if (s->lock > 0) { - //@todo this may need to actually reach the debugger prioritarily somehow because it may crash before - ERR_PRINTS("Object was freed or unreferenced while signal '" + String(*S) + "' is being emitted from it. Try connecting to the signal using 'CONNECT_DEFERRED' flag, or use queue_free() to free the object (if this object is a Node) to avoid this error and potential crashes."); - } - //brute force disconnect for performance int slot_count = s->slot_map.size(); const VMap<Signal::Target, Signal::Slot>::Pair *slot_list = s->slot_map.get_array(); diff --git a/core/object.h b/core/object.h index ad1865da7b..865c155764 100644 --- a/core/object.h +++ b/core/object.h @@ -465,8 +465,7 @@ private: MethodInfo user; VMap<Target, Slot> slot_map; - int lock; - Signal() { lock = 0; } + Signal() {} }; HashMap<StringName, Signal> signal_map; @@ -481,6 +480,7 @@ private: bool _predelete(); void _postinitialize(); bool _can_translate; + bool _emitting; #ifdef TOOLS_ENABLED bool _edited; uint32_t _edited_version; diff --git a/core/os/dir_access.cpp b/core/os/dir_access.cpp index 0477db82be..f65fc00077 100644 --- a/core/os/dir_access.cpp +++ b/core/os/dir_access.cpp @@ -285,7 +285,7 @@ Error DirAccess::copy(String p_from, String p_to, int p_chmod_flags) { FileAccess *fsrc = FileAccess::open(p_from, FileAccess::READ, &err); if (err) { - ERR_PRINTS("Failed to open " + p_from); + ERR_PRINT("Failed to open " + p_from); return err; } @@ -294,7 +294,7 @@ Error DirAccess::copy(String p_from, String p_to, int p_chmod_flags) { fsrc->close(); memdelete(fsrc); - ERR_PRINTS("Failed to open " + p_to); + ERR_PRINT("Failed to open " + p_to); return err; } diff --git a/core/os/midi_driver.cpp b/core/os/midi_driver.cpp index 614ce99b2e..3e020a1585 100644 --- a/core/os/midi_driver.cpp +++ b/core/os/midi_driver.cpp @@ -52,7 +52,12 @@ void MIDIDriver::receive_input_packet(uint64_t timestamp, uint8_t *data, uint32_ uint32_t param_position = 1; if (length >= 1) { - if ((data[0] & 0x80) == 0x00) { + if (data[0] >= 0xF0) { + // channel does not apply to system common messages + event->set_channel(0); + event->set_message(data[0]); + last_received_message = data[0]; + } else if ((data[0] & 0x80) == 0x00) { // running status event->set_channel(last_received_message & 0xF); event->set_message(last_received_message >> 4); diff --git a/core/os/os.cpp b/core/os/os.cpp index 81dea159a6..7e5c9d6ef8 100644 --- a/core/os/os.cpp +++ b/core/os/os.cpp @@ -188,7 +188,7 @@ int OS::get_process_id() const { void OS::vibrate_handheld(int p_duration_ms) { - WARN_PRINTS("vibrate_handheld() only works with Android and iOS"); + WARN_PRINT("vibrate_handheld() only works with Android and iOS"); } bool OS::is_stdout_verbose() const { @@ -221,7 +221,7 @@ bool OS::has_virtual_keyboard() const { return false; } -void OS::show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect) { +void OS::show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect, int p_max_input_length) { } void OS::hide_virtual_keyboard() { diff --git a/core/os/os.h b/core/os/os.h index 714c4e3f09..89b3414b3e 100644 --- a/core/os/os.h +++ b/core/os/os.h @@ -267,7 +267,7 @@ public: virtual int get_low_processor_usage_mode_sleep_usec() const; virtual String get_executable_path() const; - virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL) = 0; + virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking = true, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL) = 0; virtual Error kill(const ProcessID &p_pid) = 0; virtual int get_process_id() const; virtual void vibrate_handheld(int p_duration_ms = 500); @@ -380,7 +380,7 @@ public: }; virtual bool has_virtual_keyboard() const; - virtual void show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect = Rect2()); + virtual void show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect = Rect2(), int p_max_input_length = -1); virtual void hide_virtual_keyboard(); // returns height of the currently shown virtual keyboard (0 if keyboard is hidden) diff --git a/core/project_settings.cpp b/core/project_settings.cpp index a01a8a35c6..59d7e82850 100644 --- a/core/project_settings.cpp +++ b/core/project_settings.cpp @@ -206,7 +206,7 @@ bool ProjectSettings::_get(const StringName &p_name, Variant &r_ret) const { name = feature_overrides[name]; } if (!props.has(name)) { - WARN_PRINTS("Property not found: " + String(name)); + WARN_PRINT("Property not found: " + String(name)); return false; } r_ret = props[name].variant; @@ -579,7 +579,7 @@ Error ProjectSettings::_load_settings_text(const String &p_path) { _convert_to_last_version(config_version); return OK; } else if (err != OK) { - ERR_PRINTS("Error parsing " + p_path + " at line " + itos(lines) + ": " + error_text + " File might be corrupted."); + ERR_PRINT("Error parsing " + p_path + " at line " + itos(lines) + ": " + error_text + " File might be corrupted."); memdelete(f); return err; } @@ -612,7 +612,7 @@ Error ProjectSettings::_load_settings_text_or_binary(const String &p_text_path, return OK; } else if (err_text != ERR_FILE_NOT_FOUND) { // If the text-based file exists but can't be loaded, we want to know it - ERR_PRINTS("Couldn't load file '" + p_text_path + "', error code " + itos(err_text) + "."); + ERR_PRINT("Couldn't load file '" + p_text_path + "', error code " + itos(err_text) + "."); return err_text; } diff --git a/core/translation.cpp b/core/translation.cpp index 02297cffc8..cf76de1c9e 100644 --- a/core/translation.cpp +++ b/core/translation.cpp @@ -966,7 +966,7 @@ void TranslationServer::set_locale(const String &p_locale) { print_verbose(vformat("Unsupported locale '%s', falling back to '%s'.", p_locale, trimmed_locale)); if (!is_locale_valid(trimmed_locale)) { - ERR_PRINTS(vformat("Unsupported locale '%s', falling back to 'en'.", trimmed_locale)); + ERR_PRINT(vformat("Unsupported locale '%s', falling back to 'en'.", trimmed_locale)); locale = "en"; } else { locale = trimmed_locale; diff --git a/core/type_info.h b/core/type_info.h index c9b2055241..68bc1cc554 100644 --- a/core/type_info.h +++ b/core/type_info.h @@ -277,7 +277,7 @@ struct GetTypeInfo<const T *, typename EnableIf<TypeInherits<Object, T>::value>: template <typename T> inline StringName __constant_get_enum_name(T param, const String &p_constant) { if (GetTypeInfo<T>::VARIANT_TYPE == Variant::NIL) - ERR_PRINTS("Missing VARIANT_ENUM_CAST for constant's enum: " + p_constant); + ERR_PRINT("Missing VARIANT_ENUM_CAST for constant's enum: " + p_constant); return GetTypeInfo<T>::get_class_info().class_name; } diff --git a/core/undo_redo.cpp b/core/undo_redo.cpp index 5d1144e1f5..577879d448 100644 --- a/core/undo_redo.cpp +++ b/core/undo_redo.cpp @@ -293,7 +293,7 @@ void UndoRedo::_process_operation_list(List<Operation>::Element *E) { Variant::CallError ce; obj->call(op.name, (const Variant **)argptrs.ptr(), argc, ce); if (ce.error != Variant::CallError::CALL_OK) { - ERR_PRINTS("Error calling method from signal '" + String(op.name) + "': " + Variant::get_call_error_text(obj, op.name, (const Variant **)argptrs.ptr(), argc, ce)); + ERR_PRINT("Error calling method from signal '" + String(op.name) + "': " + Variant::get_call_error_text(obj, op.name, (const Variant **)argptrs.ptr(), argc, ce)); } #ifdef TOOLS_ENABLED Resource *res = Object::cast_to<Resource>(obj); diff --git a/core/ustring.cpp b/core/ustring.cpp index 8a1fbfd383..08418463a0 100644 --- a/core/ustring.cpp +++ b/core/ustring.cpp @@ -3324,7 +3324,7 @@ String String::humanize_size(uint64_t p_size) { int prefix_idx = 0; - while (prefix_idx < prefixes.size() && p_size > (_div * 1024)) { + while (prefix_idx < prefixes.size() - 1 && p_size > (_div * 1024)) { _div *= 1024; prefix_idx++; } diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml index e84e265983..7c863a3563 100644 --- a/doc/classes/@GlobalScope.xml +++ b/doc/classes/@GlobalScope.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="@GlobalScope" category="Core" version="3.2"> +<class name="@GlobalScope" version="4.0"> <brief_description> Global scope constants and variables. </brief_description> @@ -42,8 +42,13 @@ <member name="JSON" type="JSON" setter="" getter=""> The [JSON] singleton. </member> + <member name="JavaClassWrapper" type="JavaClassWrapper" setter="" getter=""> + The [JavaClassWrapper] singleton. + [b]Note:[/b] Only implemented on Android. + </member> <member name="JavaScript" type="JavaScript" setter="" getter=""> The [JavaScript] singleton. + [b]Note:[/b] Only implemented on HTML5. </member> <member name="Marshalls" type="Reference" setter="" getter=""> The [Marshalls] singleton. @@ -1162,10 +1167,10 @@ Since [constant OK] has value 0, and all other failure codes are positive integers, it can also be used in boolean checks, e.g.: [codeblock] var err = method_that_returns_error() - if (err != OK): + if err != OK: print("Failure!) # Or, equivalent: - if (err): + if err: print("Still failing!) [/codeblock] </constant> @@ -1449,7 +1454,7 @@ Default method flags. </constant> <constant name="TYPE_NIL" value="0" enum="Variant.Type"> - Variable is of type [Nil] (only applied for [code]null[/code]). + Variable is [code]null[/code]. </constant> <constant name="TYPE_BOOL" value="1" enum="Variant.Type"> Variable is of type [bool]. diff --git a/doc/classes/AABB.xml b/doc/classes/AABB.xml index af5598f126..3f2f27d121 100644 --- a/doc/classes/AABB.xml +++ b/doc/classes/AABB.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AABB" category="Built-In Types" version="3.2"> +<class name="AABB" version="4.0"> <brief_description> Axis-Aligned Bounding Box. </brief_description> diff --git a/doc/classes/ARVRAnchor.xml b/doc/classes/ARVRAnchor.xml index 2177ed8930..87181f572d 100644 --- a/doc/classes/ARVRAnchor.xml +++ b/doc/classes/ARVRAnchor.xml @@ -1,10 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ARVRAnchor" inherits="Spatial" category="Core" version="3.2"> +<class name="ARVRAnchor" inherits="Spatial" version="4.0"> <brief_description> An anchor point in AR space. </brief_description> <description> - The ARVR Anchor point is a spatial node that maps a real world location identified by the AR platform to a position within the game world. For example, as long as plane detection in ARKit is on, ARKit will identify and update the position of planes (tables, floors, etc) and create anchors for them. + The [ARVRAnchor] point is a spatial node that maps a real world location identified by the AR platform to a position within the game world. For example, as long as plane detection in ARKit is on, ARKit will identify and update the position of planes (tables, floors, etc) and create anchors for them. This node is mapped to one of the anchors through its unique ID. When you receive a signal that a new anchor is available, you should add this node to your scene for that anchor. You can predefine nodes and set the ID; the nodes will simply remain on 0,0,0 until a plane is recognized. Keep in mind that, as long as plane detection is enabled, the size, placing and orientation of an anchor will be updated as the detection logic learns more about the real world out there especially if only part of the surface is in view. </description> @@ -29,7 +29,7 @@ <return type="Mesh"> </return> <description> - If provided by the ARVR Interface, this returns a mesh object for the anchor. For an anchor, this can be a shape related to the object being tracked or it can be a mesh that provides topology related to the anchor and can be used to create shadows/reflections on surfaces or for generating collision shapes. + If provided by the [ARVRInterface], this returns a mesh object for the anchor. For an anchor, this can be a shape related to the object being tracked or it can be a mesh that provides topology related to the anchor and can be used to create shadows/reflections on surfaces or for generating collision shapes. </description> </method> <method name="get_plane" qualifiers="const"> diff --git a/doc/classes/ARVRCamera.xml b/doc/classes/ARVRCamera.xml index 1c468f193f..a571d26c83 100644 --- a/doc/classes/ARVRCamera.xml +++ b/doc/classes/ARVRCamera.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ARVRCamera" inherits="Camera" category="Core" version="3.2"> +<class name="ARVRCamera" inherits="Camera" version="4.0"> <brief_description> A camera node with a few overrules for AR/VR applied, such as location tracking. </brief_description> @@ -8,6 +8,7 @@ The position and orientation of this node is automatically updated by the ARVR Server to represent the location of the HMD if such tracking is available and can thus be used by game logic. Note that, in contrast to the ARVR Controller, the render thread has access to the most up-to-date tracking data of the HMD and the location of the ARVRCamera can lag a few milliseconds behind what is used for rendering as a result. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/vr/index.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/ARVRController.xml b/doc/classes/ARVRController.xml index 24d8b48077..e485bd6f1a 100644 --- a/doc/classes/ARVRController.xml +++ b/doc/classes/ARVRController.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ARVRController" inherits="Spatial" category="Core" version="3.2"> +<class name="ARVRController" inherits="Spatial" version="4.0"> <brief_description> A spatial node representing a spatially-tracked controller. </brief_description> @@ -9,6 +9,7 @@ The position of the controller node is automatically updated by the [ARVRServer]. This makes this node ideal to add child nodes to visualize the controller. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/vr/index.html</link> </tutorials> <methods> <method name="get_controller_name" qualifiers="const"> diff --git a/doc/classes/ARVRInterface.xml b/doc/classes/ARVRInterface.xml index 41effcaecb..d9757ad023 100644 --- a/doc/classes/ARVRInterface.xml +++ b/doc/classes/ARVRInterface.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ARVRInterface" inherits="Reference" category="Core" version="3.2"> +<class name="ARVRInterface" inherits="Reference" version="4.0"> <brief_description> Base class for an AR/VR interface implementation. </brief_description> @@ -8,6 +8,7 @@ Interfaces should be written in such a way that simply enabling them will give us a working setup. You can query the available interfaces through [ARVRServer]. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/vr/index.html</link> </tutorials> <methods> <method name="get_camera_feed_id"> @@ -120,7 +121,7 @@ We don't know the status of the tracking or this interface does not provide feedback. </constant> <constant name="ARVR_NOT_TRACKING" value="4" enum="Tracking_status"> - Tracking is not functional (camera not plugged in or obscured, lighthouses turned off, etc.) + Tracking is not functional (camera not plugged in or obscured, lighthouses turned off, etc.). </constant> </constants> </class> diff --git a/doc/classes/ARVROrigin.xml b/doc/classes/ARVROrigin.xml index b6b55741aa..9a386fd154 100644 --- a/doc/classes/ARVROrigin.xml +++ b/doc/classes/ARVROrigin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ARVROrigin" inherits="Spatial" category="Core" version="3.2"> +<class name="ARVROrigin" inherits="Spatial" version="4.0"> <brief_description> The origin point in AR/VR. </brief_description> @@ -10,6 +10,7 @@ For example, if your character is driving a car, the ARVROrigin node should be a child node of this car. Or, if you're implementing a teleport system to move your character, you should change the position of this node. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/vr/index.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/ARVRPositionalTracker.xml b/doc/classes/ARVRPositionalTracker.xml index c4acfd3b51..a151f8d652 100644 --- a/doc/classes/ARVRPositionalTracker.xml +++ b/doc/classes/ARVRPositionalTracker.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ARVRPositionalTracker" inherits="Object" category="Core" version="3.2"> +<class name="ARVRPositionalTracker" inherits="Object" version="4.0"> <brief_description> A tracked object. </brief_description> @@ -9,6 +9,7 @@ The [ARVRController] and [ARVRAnchor] both consume objects of this type and should be used in your project. The positional trackers are just under-the-hood objects that make this all work. These are mostly exposed so that GDNative-based interfaces can interact with them. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/vr/index.html</link> </tutorials> <methods> <method name="get_hand" qualifiers="const"> diff --git a/doc/classes/ARVRServer.xml b/doc/classes/ARVRServer.xml index b71a18858f..6f0e4488fa 100644 --- a/doc/classes/ARVRServer.xml +++ b/doc/classes/ARVRServer.xml @@ -1,12 +1,13 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ARVRServer" inherits="Object" category="Core" version="3.2"> +<class name="ARVRServer" inherits="Object" version="4.0"> <brief_description> - The AR/VR server. + Server for AR and VR features. </brief_description> <description> - The AR/VR server is the heart of our AR/VR solution and handles all the processing. + The AR/VR server is the heart of our Advanced and Virtual Reality solution and handles all the processing. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/vr/index.html</link> </tutorials> <methods> <method name="center_on_hmd"> @@ -47,14 +48,14 @@ <argument index="0" name="idx" type="int"> </argument> <description> - Gets the interface registered at a given index in our list of interfaces. + Returns the interface registered at a given index in our list of interfaces. </description> </method> <method name="get_interface_count" qualifiers="const"> <return type="int"> </return> <description> - Gets the number of interfaces currently registered with the AR/VR server. If your project supports multiple AR/VR platforms, you can look through the available interface, and either present the user with a selection or simply try to initialize each interface and use the first one that returns [code]true[/code]. + Returns the number of interfaces currently registered with the AR/VR server. If your project supports multiple AR/VR platforms, you can look through the available interface, and either present the user with a selection or simply try to initialize each interface and use the first one that returns [code]true[/code]. </description> </method> <method name="get_interfaces" qualifiers="const"> @@ -68,25 +69,28 @@ <return type="int"> </return> <description> + Returns the absolute timestamp (in μs) of the last [ARVRServer] commit of the AR/VR eyes to [VisualServer]. The value comes from an internal call to [method OS.get_ticks_usec]. </description> </method> <method name="get_last_frame_usec"> <return type="int"> </return> <description> + Returns the duration (in μs) of the last frame. This is computed as the difference between [method get_last_commit_usec] and [method get_last_process_usec] when committing. </description> </method> <method name="get_last_process_usec"> <return type="int"> </return> <description> + Returns the absolute timestamp (in μs) of the last [ARVRServer] process callback. The value comes from an internal call to [method OS.get_ticks_usec]. </description> </method> <method name="get_reference_frame" qualifiers="const"> <return type="Transform"> </return> <description> - Gets the reference frame transform. Mostly used internally and exposed for GDNative build interfaces. + Returns the reference frame transform. Mostly used internally and exposed for GDNative build interfaces. </description> </method> <method name="get_tracker" qualifiers="const"> @@ -95,19 +99,20 @@ <argument index="0" name="idx" type="int"> </argument> <description> - Gets the positional tracker at the given ID. + Returns the positional tracker at the given ID. </description> </method> <method name="get_tracker_count" qualifiers="const"> <return type="int"> </return> <description> - Gets the number of trackers currently registered. + Returns the number of trackers currently registered. </description> </method> </methods> <members> <member name="primary_interface" type="ARVRInterface" setter="set_primary_interface" getter="get_primary_interface"> + The primary [ARVRInterface] currently bound to the [ARVRServer]. </member> <member name="world_scale" type="float" setter="set_world_scale" getter="get_world_scale" default="1.0"> Allows you to adjust the scale to your game's units. Most AR/VR platforms assume a scale of 1 game world unit = 1 real world meter. diff --git a/doc/classes/AStar.xml b/doc/classes/AStar.xml index 6304bd34f6..ccbb033444 100644 --- a/doc/classes/AStar.xml +++ b/doc/classes/AStar.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AStar" inherits="Reference" category="Core" version="3.2"> +<class name="AStar" inherits="Reference" version="4.0"> <brief_description> An implementation of A* to find shortest paths among connected points in space. </brief_description> diff --git a/doc/classes/AStar2D.xml b/doc/classes/AStar2D.xml index 3002e3c351..d620ef2a79 100644 --- a/doc/classes/AStar2D.xml +++ b/doc/classes/AStar2D.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AStar2D" inherits="Reference" category="Core" version="3.2"> +<class name="AStar2D" inherits="Reference" version="4.0"> <brief_description> - AStar class representation that uses 2d-vectors as edges. + AStar class representation that uses 2D vectors as edges. </brief_description> <description> This is a wrapper for the [AStar] class which uses 2D vectors instead of 3D vectors. diff --git a/doc/classes/AcceptDialog.xml b/doc/classes/AcceptDialog.xml index 8acaaa4819..b0b9c155bb 100644 --- a/doc/classes/AcceptDialog.xml +++ b/doc/classes/AcceptDialog.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AcceptDialog" inherits="WindowDialog" category="Core" version="3.2"> +<class name="AcceptDialog" inherits="WindowDialog" version="4.0"> <brief_description> Base dialog for user notification. </brief_description> diff --git a/doc/classes/AnimatedSprite.xml b/doc/classes/AnimatedSprite.xml index 10ee4222c8..ff56067cda 100644 --- a/doc/classes/AnimatedSprite.xml +++ b/doc/classes/AnimatedSprite.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimatedSprite" inherits="Node2D" category="Core" version="3.2"> +<class name="AnimatedSprite" inherits="Node2D" version="4.0"> <brief_description> Sprite node that can use multiple textures for animation. </brief_description> diff --git a/doc/classes/AnimatedSprite3D.xml b/doc/classes/AnimatedSprite3D.xml index eac5822d53..e24119c6c7 100644 --- a/doc/classes/AnimatedSprite3D.xml +++ b/doc/classes/AnimatedSprite3D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimatedSprite3D" inherits="SpriteBase3D" category="Core" version="3.2"> +<class name="AnimatedSprite3D" inherits="SpriteBase3D" version="4.0"> <brief_description> 2D sprite node in 3D world, that can use multiple 2D textures for animation. </brief_description> diff --git a/doc/classes/AnimatedTexture.xml b/doc/classes/AnimatedTexture.xml index 5c43ce4d74..d4c25049d2 100644 --- a/doc/classes/AnimatedTexture.xml +++ b/doc/classes/AnimatedTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimatedTexture" inherits="Texture" category="Core" version="3.2"> +<class name="AnimatedTexture" inherits="Texture" version="4.0"> <brief_description> Proxy texture for simple frame-based animations. </brief_description> diff --git a/doc/classes/Animation.xml b/doc/classes/Animation.xml index 9924f75289..c3d9216657 100644 --- a/doc/classes/Animation.xml +++ b/doc/classes/Animation.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Animation" inherits="Resource" category="Core" version="3.2"> +<class name="Animation" inherits="Resource" version="4.0"> <brief_description> Contains data used to animate everything in the engine. </brief_description> diff --git a/doc/classes/AnimationNode.xml b/doc/classes/AnimationNode.xml index 79ec0f0a47..331a30bd9e 100644 --- a/doc/classes/AnimationNode.xml +++ b/doc/classes/AnimationNode.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNode" inherits="Resource" category="Core" version="3.2"> +<class name="AnimationNode" inherits="Resource" version="4.0"> <brief_description> Base resource for [AnimationTree] nodes. </brief_description> @@ -8,6 +8,7 @@ Inherit this when creating nodes mainly for use in [AnimationNodeBlendTree], otherwise [AnimationRootNode] should be used instead. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="add_input"> @@ -16,7 +17,7 @@ <argument index="0" name="name" type="String"> </argument> <description> - Adds an input to the node. This is only useful for nodes created for use in an [AnimationNodeBlendTree] + Adds an input to the node. This is only useful for nodes created for use in an [AnimationNodeBlendTree]. </description> </method> <method name="blend_animation"> @@ -33,7 +34,7 @@ <argument index="4" name="blend" type="float"> </argument> <description> - Blend an animation by "blend" amount (name must be valid in the linked [AnimationPlayer]). A time and delta mas be passed, as well as whether seek happened. + Blend an animation by [code]blend[/code] amount (name must be valid in the linked [AnimationPlayer]). A [code]time[/code] and [code]delta[/code] may be passed, as well as whether [code]seek[/code] happened. </description> </method> <method name="blend_input"> @@ -52,7 +53,7 @@ <argument index="5" name="optimize" type="bool" default="true"> </argument> <description> - Blend an input. This is only useful for nodes created for an [AnimationNodeBlendTree]. Time is a delta, unless "seek" is [code]true[/code], in which case it is absolute. A filter mode may be optionally passed. + Blend an input. This is only useful for nodes created for an [AnimationNodeBlendTree]. The [code]time[/code] parameter is a relative delta, unless [code]seek[/code] is [code]true[/code], in which case it is absolute. A filter mode may be optionally passed (see [enum FilterAction] for options). </description> </method> <method name="blend_node"> @@ -164,10 +165,9 @@ <argument index="1" name="seek" type="bool"> </argument> <description> - Called when a custom node is processed. The argument "time" is relative, unless "seek" is [code]true[/code] (in which case it is absolute). - Here, call the [method blend_input], [method blend_node] or [method blend_animation] functions. - You can also use [method get_parameter] and [method set_parameter] to modify local memory. - This function returns the time left for the current animation to finish (if unsure, just pass the value from the main blend being called). + User-defined callback called when a custom node is processed. The [code]time[/code] parameter is a relative delta, unless [code]seek[/code] is [code]true[/code], in which case it is absolute. + Here, call the [method blend_input], [method blend_node] or [method blend_animation] functions. You can also use [method get_parameter] and [method set_parameter] to modify local memory. + This function should return the time left for the current animation to finish (if unsure, pass the value from the main blend being called). </description> </method> <method name="remove_input"> diff --git a/doc/classes/AnimationNodeAdd2.xml b/doc/classes/AnimationNodeAdd2.xml index bb7857717d..48983a624e 100644 --- a/doc/classes/AnimationNodeAdd2.xml +++ b/doc/classes/AnimationNodeAdd2.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeAdd2" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeAdd2" inherits="AnimationNode" version="4.0"> <brief_description> Blends two animations additively inside of an [AnimationNodeBlendTree]. </brief_description> @@ -7,6 +7,7 @@ A resource to add to an [AnimationNodeBlendTree]. Blends two animations additively based on an amount value in the [code][0.0, 1.0][/code] range. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/AnimationNodeAdd3.xml b/doc/classes/AnimationNodeAdd3.xml index d338c2cf9e..1bfebc91fc 100644 --- a/doc/classes/AnimationNodeAdd3.xml +++ b/doc/classes/AnimationNodeAdd3.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeAdd3" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeAdd3" inherits="AnimationNode" version="4.0"> <brief_description> Blends two of three animations additively inside of an [AnimationNodeBlendTree]. </brief_description> @@ -11,6 +11,7 @@ - A +add animation to blend with when the blend amount is in the [code][0.0, 1.0][/code] range </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/AnimationNodeAnimation.xml b/doc/classes/AnimationNodeAnimation.xml index a964877068..369969a2d4 100644 --- a/doc/classes/AnimationNodeAnimation.xml +++ b/doc/classes/AnimationNodeAnimation.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeAnimation" inherits="AnimationRootNode" category="Core" version="3.2"> +<class name="AnimationNodeAnimation" inherits="AnimationRootNode" version="4.0"> <brief_description> Input animation to use in an [AnimationNodeBlendTree]. </brief_description> @@ -7,6 +7,7 @@ A resource to add to an [AnimationNodeBlendTree]. Only features one output set using the [member animation] property. Use it as an input for [AnimationNode] that blend animations together. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/AnimationNodeBlend2.xml b/doc/classes/AnimationNodeBlend2.xml index cac97b9ee7..2b56167225 100644 --- a/doc/classes/AnimationNodeBlend2.xml +++ b/doc/classes/AnimationNodeBlend2.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeBlend2" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeBlend2" inherits="AnimationNode" version="4.0"> <brief_description> Blends two animations linearly inside of an [AnimationNodeBlendTree]. </brief_description> @@ -7,6 +7,7 @@ A resource to add to an [AnimationNodeBlendTree]. Blends two animations linearly based on an amount value in the [code][0.0, 1.0][/code] range. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/AnimationNodeBlend3.xml b/doc/classes/AnimationNodeBlend3.xml index 3b5c1f0b99..5a306a225d 100644 --- a/doc/classes/AnimationNodeBlend3.xml +++ b/doc/classes/AnimationNodeBlend3.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeBlend3" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeBlend3" inherits="AnimationNode" version="4.0"> <brief_description> Blends two of three animations linearly inside of an [AnimationNodeBlendTree]. </brief_description> @@ -11,6 +11,7 @@ - A +blend animation to blend with when the blend amount is in the [code][0.0, 1.0][/code] range </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/AnimationNodeBlendSpace1D.xml b/doc/classes/AnimationNodeBlendSpace1D.xml index 82d5716ee3..6e82f0afb7 100644 --- a/doc/classes/AnimationNodeBlendSpace1D.xml +++ b/doc/classes/AnimationNodeBlendSpace1D.xml @@ -1,15 +1,16 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeBlendSpace1D" inherits="AnimationRootNode" category="Core" version="3.2"> +<class name="AnimationNodeBlendSpace1D" inherits="AnimationRootNode" version="4.0"> <brief_description> Blends linearly between two of any number of [AnimationNode] of any type placed on a virtual axis. </brief_description> <description> A resource to add to an [AnimationNodeBlendTree]. This is a virtual axis on which you can add any type of [AnimationNode] using [method add_blend_point]. - Outputs the linear blend of the two [code]AnimationNode[/code] closest to the node's current [code]value[/code]. + Outputs the linear blend of the two [AnimationNode]s closest to the node's current value. You can set the extents of the axis using the [member min_space] and [member max_space]. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="add_blend_point"> @@ -22,7 +23,7 @@ <argument index="2" name="at_index" type="int" default="-1"> </argument> <description> - Adds a new point that represents a [code]node[/code] on the virtual axis at a given position set by [code]pos[/code]. You can insert it at a specific index using the [code]at_index[/code] argument. If you use the default value for [code]at_index[/code] , the point is inserted at the end of the blend points array. + Adds a new point that represents a [code]node[/code] on the virtual axis at a given position set by [code]pos[/code]. You can insert it at a specific index using the [code]at_index[/code] argument. If you use the default value for [code]at_index[/code], the point is inserted at the end of the blend points array. </description> </method> <method name="get_blend_point_count" qualifiers="const"> @@ -38,7 +39,7 @@ <argument index="0" name="point" type="int"> </argument> <description> - Returns the [code]AnimationNode[/code] referenced by the point at index [code]point[/code]. + Returns the [AnimationNode] referenced by the point at index [code]point[/code]. </description> </method> <method name="get_blend_point_position" qualifiers="const"> @@ -67,7 +68,7 @@ <argument index="1" name="node" type="AnimationRootNode"> </argument> <description> - Changes the AnimationNode referenced by the point at index [code]point[/code]. + Changes the [AnimationNode] referenced by the point at index [code]point[/code]. </description> </method> <method name="set_blend_point_position"> diff --git a/doc/classes/AnimationNodeBlendSpace2D.xml b/doc/classes/AnimationNodeBlendSpace2D.xml index d8ea7fea5b..f8680ba8ec 100644 --- a/doc/classes/AnimationNodeBlendSpace2D.xml +++ b/doc/classes/AnimationNodeBlendSpace2D.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeBlendSpace2D" inherits="AnimationRootNode" category="Core" version="3.2"> +<class name="AnimationNodeBlendSpace2D" inherits="AnimationRootNode" version="4.0"> <brief_description> - Blends linearly between three [AnimationNode] of any type placed in a 2d space. + Blends linearly between three [AnimationNode] of any type placed in a 2D space. </brief_description> <description> A resource to add to an [AnimationNodeBlendTree]. @@ -9,6 +9,7 @@ You can add vertices to the blend space with [method add_blend_point] and automatically triangulate it by setting [member auto_triangles] to [code]true[/code]. Otherwise, use [method add_triangle] and [method remove_triangle] to create up the blend space by hand. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="add_blend_point"> @@ -21,7 +22,7 @@ <argument index="2" name="at_index" type="int" default="-1"> </argument> <description> - Adds a new point that represents a [code]node[/code] at the position set by [code]pos[/code]. You can insert it at a specific index using the [code]at_index[/code] argument. If you use the default value for [code]at_index[/code] , the point is inserted at the end of the blend points array. + Adds a new point that represents a [code]node[/code] at the position set by [code]pos[/code]. You can insert it at a specific index using the [code]at_index[/code] argument. If you use the default value for [code]at_index[/code], the point is inserted at the end of the blend points array. </description> </method> <method name="add_triangle"> @@ -36,7 +37,7 @@ <argument index="3" name="at_index" type="int" default="-1"> </argument> <description> - Creates a new triangle using three points [code]x[/code], [code]y[/code], and [code]z[/code]. Triangles can overlap. You can insert the triangle at a specific index using the [code]at_index[/code] argument. If you use the default value for [code]at_index[/code] , the point is inserted at the end of the blend points array. + Creates a new triangle using three points [code]x[/code], [code]y[/code], and [code]z[/code]. Triangles can overlap. You can insert the triangle at a specific index using the [code]at_index[/code] argument. If you use the default value for [code]at_index[/code], the point is inserted at the end of the blend points array. </description> </method> <method name="get_blend_point_count" qualifiers="const"> @@ -52,7 +53,7 @@ <argument index="0" name="point" type="int"> </argument> <description> - Returns the [code]AnimationRootNode[/code] referenced by the point at index [code]point[/code]. + Returns the [AnimationRootNode] referenced by the point at index [code]point[/code]. </description> </method> <method name="get_blend_point_position" qualifiers="const"> @@ -108,7 +109,7 @@ <argument index="1" name="node" type="AnimationRootNode"> </argument> <description> - Changes the AnimationNode referenced by the point at index [code]point[/code]. + Changes the [AnimationNode] referenced by the point at index [code]point[/code]. </description> </method> <method name="set_blend_point_position"> diff --git a/doc/classes/AnimationNodeBlendTree.xml b/doc/classes/AnimationNodeBlendTree.xml index 76a0d65920..5a86af6865 100644 --- a/doc/classes/AnimationNodeBlendTree.xml +++ b/doc/classes/AnimationNodeBlendTree.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeBlendTree" inherits="AnimationRootNode" category="Core" version="3.2"> +<class name="AnimationNodeBlendTree" inherits="AnimationRootNode" version="4.0"> <brief_description> </brief_description> <description> </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="add_node"> diff --git a/doc/classes/AnimationNodeOneShot.xml b/doc/classes/AnimationNodeOneShot.xml index 099548f60a..b6e4ed9c98 100644 --- a/doc/classes/AnimationNodeOneShot.xml +++ b/doc/classes/AnimationNodeOneShot.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeOneShot" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeOneShot" inherits="AnimationNode" version="4.0"> <brief_description> </brief_description> <description> </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="get_mix_mode" qualifiers="const"> diff --git a/doc/classes/AnimationNodeOutput.xml b/doc/classes/AnimationNodeOutput.xml index bfe28319c6..f4bded2cd1 100644 --- a/doc/classes/AnimationNodeOutput.xml +++ b/doc/classes/AnimationNodeOutput.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeOutput" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeOutput" inherits="AnimationNode" version="4.0"> <brief_description> </brief_description> <description> </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/AnimationNodeStateMachine.xml b/doc/classes/AnimationNodeStateMachine.xml index 9a21492b8a..39a9af5ead 100644 --- a/doc/classes/AnimationNodeStateMachine.xml +++ b/doc/classes/AnimationNodeStateMachine.xml @@ -1,10 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeStateMachine" inherits="AnimationRootNode" category="Core" version="3.2"> +<class name="AnimationNodeStateMachine" inherits="AnimationRootNode" version="4.0"> <brief_description> State machine for control of animations. </brief_description> <description> - Contains multiple nodes representing animation states, connected in a graph. Node transitions can be configured to happen automatically or via code, using a shortest-path algorithm. Retrieve the AnimationNodeStateMachinePlayback object from the [AnimationTree] node to control it programmatically. + Contains multiple nodes representing animation states, connected in a graph. Node transitions can be configured to happen automatically or via code, using a shortest-path algorithm. Retrieve the [AnimationNodeStateMachinePlayback] object from the [AnimationTree] node to control it programmatically. [b]Example:[/b] [codeblock] var state_machine = $AnimationTree.get("parameters/playback") @@ -12,6 +12,7 @@ [/codeblock] </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="add_node"> @@ -159,7 +160,7 @@ <argument index="1" name="to" type="String"> </argument> <description> - Deletes the given transition. + Deletes the transition between the two specified nodes. </description> </method> <method name="remove_transition_by_index"> @@ -168,7 +169,7 @@ <argument index="0" name="idx" type="int"> </argument> <description> - Deletes the given transition. + Deletes the given transition by index. </description> </method> <method name="rename_node"> diff --git a/doc/classes/AnimationNodeStateMachinePlayback.xml b/doc/classes/AnimationNodeStateMachinePlayback.xml index 09cd369bc4..0198237bed 100644 --- a/doc/classes/AnimationNodeStateMachinePlayback.xml +++ b/doc/classes/AnimationNodeStateMachinePlayback.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeStateMachinePlayback" inherits="Resource" category="Core" version="3.2"> +<class name="AnimationNodeStateMachinePlayback" inherits="Resource" version="4.0"> <brief_description> - Playback control for AnimationNodeStateMachine. + Playback control for [AnimationNodeStateMachine]. </brief_description> <description> Allows control of [AnimationTree] state machines created with [AnimationNodeStateMachine]. Retrieve with [code]$AnimationTree.get("parameters/playback")[/code]. @@ -12,6 +12,7 @@ [/codeblock] </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="get_current_node" qualifiers="const"> @@ -25,6 +26,7 @@ <return type="PoolStringArray"> </return> <description> + Returns the current travel path as computed internally by the A* algorithm. </description> </method> <method name="is_playing" qualifiers="const"> diff --git a/doc/classes/AnimationNodeStateMachineTransition.xml b/doc/classes/AnimationNodeStateMachineTransition.xml index 08ff9997cf..d40a6f1e46 100644 --- a/doc/classes/AnimationNodeStateMachineTransition.xml +++ b/doc/classes/AnimationNodeStateMachineTransition.xml @@ -1,18 +1,19 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeStateMachineTransition" inherits="Resource" category="Core" version="3.2"> +<class name="AnimationNodeStateMachineTransition" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> <members> <member name="advance_condition" type="String" setter="set_advance_condition" getter="get_advance_condition" default=""""> - Turn on auto advance when this condition is set. The provided name will become a boolean parameter on the [AnimationTree] that can be controlled from code (see [url=https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html#controlling-from-code][/url]). For example, if [member AnimationTree.tree_root] is an [AnimationNodeStateMachine] and [member advance_condition] is set to "idle": + Turn on auto advance when this condition is set. The provided name will become a boolean parameter on the [AnimationTree] that can be controlled from code (see [url=https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html#controlling-from-code][/url]). For example, if [member AnimationTree.tree_root] is an [AnimationNodeStateMachine] and [member advance_condition] is set to [code]"idle"[/code]: [codeblock] - $animation_tree["parameters/conditions/idle"] = is_on_floor and linear_velocity.x == 0 + $animation_tree["parameters/conditions/idle"] = is_on_floor and (linear_velocity.x == 0) [/codeblock] </member> <member name="auto_advance" type="bool" setter="set_auto_advance" getter="has_auto_advance" default="false"> @@ -34,6 +35,7 @@ <signals> <signal name="advance_condition_changed"> <description> + Emitted when [member advance_condition] is changed. </description> </signal> </signals> diff --git a/doc/classes/AnimationNodeTimeScale.xml b/doc/classes/AnimationNodeTimeScale.xml index 9ce773c4e2..229f9bbba2 100644 --- a/doc/classes/AnimationNodeTimeScale.xml +++ b/doc/classes/AnimationNodeTimeScale.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeTimeScale" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeTimeScale" inherits="AnimationNode" version="4.0"> <brief_description> </brief_description> <description> </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/AnimationNodeTimeSeek.xml b/doc/classes/AnimationNodeTimeSeek.xml index d593f5489c..5a9cbe4861 100644 --- a/doc/classes/AnimationNodeTimeSeek.xml +++ b/doc/classes/AnimationNodeTimeSeek.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeTimeSeek" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeTimeSeek" inherits="AnimationNode" version="4.0"> <brief_description> </brief_description> <description> </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/AnimationNodeTransition.xml b/doc/classes/AnimationNodeTransition.xml index 82839b6bab..bf94fe0466 100644 --- a/doc/classes/AnimationNodeTransition.xml +++ b/doc/classes/AnimationNodeTransition.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationNodeTransition" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationNodeTransition" inherits="AnimationNode" version="4.0"> <brief_description> </brief_description> <description> </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="get_input_caption" qualifiers="const"> @@ -45,134 +46,6 @@ </method> </methods> <members> - <member name="input_0/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_0/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_1/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_1/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_10/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_10/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_11/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_11/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_12/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_12/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_13/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_13/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_14/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_14/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_15/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_15/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_16/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_16/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_17/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_17/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_18/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_18/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_19/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_19/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_2/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_2/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_20/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_20/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_21/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_21/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_22/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_22/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_23/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_23/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_24/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_24/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_25/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_25/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_26/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_26/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_27/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_27/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_28/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_28/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_29/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_29/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_3/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_3/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_30/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_30/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_31/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_31/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_4/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_4/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_5/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_5/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_6/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_6/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_7/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_7/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_8/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_8/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> - <member name="input_9/auto_advance" type="bool" setter="set_input_as_auto_advance" getter="is_input_set_as_auto_advance"> - </member> - <member name="input_9/name" type="String" setter="set_input_caption" getter="get_input_caption"> - </member> <member name="input_count" type="int" setter="set_enabled_inputs" getter="get_enabled_inputs" default="0"> </member> <member name="xfade_time" type="float" setter="set_cross_fade_time" getter="get_cross_fade_time" default="0.0"> diff --git a/doc/classes/AnimationPlayer.xml b/doc/classes/AnimationPlayer.xml index a47b4a590e..3e8315f686 100644 --- a/doc/classes/AnimationPlayer.xml +++ b/doc/classes/AnimationPlayer.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationPlayer" inherits="Node" category="Core" version="3.2"> +<class name="AnimationPlayer" inherits="Node" version="4.0"> <brief_description> Container and player of [Animation] resources. </brief_description> <description> An animation player is used for general-purpose playback of [Animation] resources. It contains a dictionary of animations (referenced by name) and custom blend times between their transitions. Additionally, animations can be played and blended in different channels. + [AnimationPlayer] is more suited than [Tween] for animations where you know the final values in advance. For example, fading a screen in and out is more easily done with an [AnimationPlayer] node thanks to the animation tools provided by the editor. That particular example can also be implemented with a [Tween] node, but it requires doing everything by code. Updating the target properties of animations occurs at process time. </description> <tutorials> diff --git a/doc/classes/AnimationRootNode.xml b/doc/classes/AnimationRootNode.xml index 735f3215e9..46759b7f4d 100644 --- a/doc/classes/AnimationRootNode.xml +++ b/doc/classes/AnimationRootNode.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationRootNode" inherits="AnimationNode" category="Core" version="3.2"> +<class name="AnimationRootNode" inherits="AnimationNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AnimationTrackEditPlugin.xml b/doc/classes/AnimationTrackEditPlugin.xml index 2dcabb051f..8490d48718 100644 --- a/doc/classes/AnimationTrackEditPlugin.xml +++ b/doc/classes/AnimationTrackEditPlugin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationTrackEditPlugin" inherits="Reference" category="Core" version="3.2"> +<class name="AnimationTrackEditPlugin" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AnimationTree.xml b/doc/classes/AnimationTree.xml index d1c24e466d..2a7db37eea 100644 --- a/doc/classes/AnimationTree.xml +++ b/doc/classes/AnimationTree.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationTree" inherits="Node" category="Core" version="3.2"> +<class name="AnimationTree" inherits="Node" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AnimationTreePlayer.xml b/doc/classes/AnimationTreePlayer.xml index 0d7a34b179..e09e646960 100644 --- a/doc/classes/AnimationTreePlayer.xml +++ b/doc/classes/AnimationTreePlayer.xml @@ -1,13 +1,14 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AnimationTreePlayer" inherits="Node" category="Core" version="3.2"> +<class name="AnimationTreePlayer" inherits="Node" version="4.0"> <brief_description> - Animation Player that uses a node graph for blending Animations. + Animation player that uses a node graph for blending animations. </brief_description> <description> A node graph tool for blending multiple animations bound to an [AnimationPlayer]. Especially useful for animating characters or other skeleton-based rigs. It can combine several animations to form a desired pose. It takes [Animation]s from an [AnimationPlayer] node and mixes them depending on the graph. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/animation_tree.html</link> </tutorials> <methods> <method name="add_node"> @@ -27,7 +28,7 @@ <argument index="0" name="delta" type="float"> </argument> <description> - Shifts position in the animation timeline. Delta is the time in seconds to shift. Events between the current frame and [code]delta[/code] are handled. + Shifts position in the animation timeline. [code]delta[/code] is the time in seconds to shift. Events between the current frame and [code]delta[/code] are handled. </description> </method> <method name="animation_node_get_animation" qualifiers="const"> @@ -54,6 +55,7 @@ <argument index="0" name="id" type="String"> </argument> <description> + Returns the absolute playback timestamp of the animation node with name [code]id[/code]. </description> </method> <method name="animation_node_set_animation"> @@ -122,10 +124,8 @@ </argument> <description> Sets the blend amount of a Blend2 node given its name and value. - A Blend2 Node blends two animations with the amount between 0 and 1. - At 0, Output is input a. - Towards 1, the influence of a gets lessened, the influence of b gets raised. - At 1, Output is input b. + A Blend2 node blends two animations (A and B) with the amount between 0 and 1. + At 0, output is input A. Towards 1, the influence of A gets lessened, the influence of B gets raised. At 1, output is input B. </description> </method> <method name="blend2_node_set_filter_path"> @@ -138,7 +138,7 @@ <argument index="2" name="enable" type="bool"> </argument> <description> - If [code]enable[/code] is [code]true[/code], the blend2 node with ID [code]id[/code] turns off the track modifying the property at [code]path[/code]. The modified node's children continue to animate. + If [code]enable[/code] is [code]true[/code], the Blend2 node with name [code]id[/code] turns off the track modifying the property at [code]path[/code]. The modified node's children continue to animate. </description> </method> <method name="blend3_node_get_amount" qualifiers="const"> @@ -159,12 +159,8 @@ </argument> <description> Sets the blend amount of a Blend3 node given its name and value. - A Blend3 Node blends three animations with the amount between -1 and 1. - At -1, Output is input b-. - From -1 to 0, the influence of b- gets lessened, the influence of a gets raised and the influence of b+ is 0. - At 0, Output is input a. - From 0 to 1, the influence of a gets lessened, the influence of b+ gets raised and the influence of b+ is 0. - At 1, Output is input b+. + A Blend3 Node blends three animations (A, B-, B+) with the amount between -1 and 1. + At -1, output is input B-. From -1 to 0, the influence of B- gets lessened, the influence of A gets raised and the influence of B+ is 0. At 0, output is input A. From 0 to 1, the influence of A gets lessened, the influence of B+ gets raised and the influence of B+ is 0. At 1, output is input B+. </description> </method> <method name="blend4_node_get_amount" qualifiers="const"> @@ -186,7 +182,7 @@ <description> Sets the blend amount of a Blend4 node given its name and value. A Blend4 Node blends two pairs of animations. - The two pairs are blended like blend2 and then added together. + The two pairs are blended like Blend2 and then added together. </description> </method> <method name="connect_nodes"> @@ -226,7 +222,7 @@ <argument index="0" name="id" type="String"> </argument> <description> - Returns mix amount of a Mix node given its name. + Returns the mix amount of a Mix node given its name. </description> </method> <method name="mix_node_set_amount"> @@ -237,7 +233,7 @@ <argument index="1" name="ratio" type="float"> </argument> <description> - Sets mix amount of a Mix node given its name and value. + Sets the mix amount of a Mix node given its name and value. A Mix node adds input b to input a by the amount given by ratio. </description> </method> @@ -296,7 +292,7 @@ <argument index="1" name="new_name" type="String"> </argument> <description> - Rename a node in the graph. + Renames a node in the graph. </description> </method> <method name="node_set_position"> @@ -307,7 +303,7 @@ <argument index="1" name="screen_position" type="Vector2"> </argument> <description> - Sets position of a node in the graph given its name and position. + Sets the position of a node in the graph given its name and position. </description> </method> <method name="oneshot_node_get_autorestart_delay" qualifiers="const"> @@ -316,7 +312,7 @@ <argument index="0" name="id" type="String"> </argument> <description> - Returns autostart delay of a OneShot node given its name. + Returns the autostart delay of a OneShot node given its name. </description> </method> <method name="oneshot_node_get_autorestart_random_delay" qualifiers="const"> @@ -325,7 +321,7 @@ <argument index="0" name="id" type="String"> </argument> <description> - Returns autostart random delay of a OneShot node given its name. + Returns the autostart random delay of a OneShot node given its name. </description> </method> <method name="oneshot_node_get_fadein_time" qualifiers="const"> @@ -334,7 +330,7 @@ <argument index="0" name="id" type="String"> </argument> <description> - Returns fade in time of a OneShot node given its name. + Returns the fade in time of a OneShot node given its name. </description> </method> <method name="oneshot_node_get_fadeout_time" qualifiers="const"> @@ -343,7 +339,7 @@ <argument index="0" name="id" type="String"> </argument> <description> - Returns fade out time of a OneShot node given its name. + Returns the fade out time of a OneShot node given its name. </description> </method> <method name="oneshot_node_has_autorestart" qualifiers="const"> @@ -372,7 +368,7 @@ <argument index="1" name="enable" type="bool"> </argument> <description> - Sets autorestart property of a OneShot node given its name and value. + Sets the autorestart property of a OneShot node given its name and value. </description> </method> <method name="oneshot_node_set_autorestart_delay"> @@ -383,7 +379,7 @@ <argument index="1" name="delay_sec" type="float"> </argument> <description> - Sets autorestart delay of a OneShot node given its name and value in seconds. + Sets the autorestart delay of a OneShot node given its name and value in seconds. </description> </method> <method name="oneshot_node_set_autorestart_random_delay"> @@ -394,7 +390,7 @@ <argument index="1" name="rand_sec" type="float"> </argument> <description> - Sets autorestart random delay of a OneShot node given its name and value in seconds. + Sets the autorestart random delay of a OneShot node given its name and value in seconds. </description> </method> <method name="oneshot_node_set_fadein_time"> @@ -405,7 +401,7 @@ <argument index="1" name="time_sec" type="float"> </argument> <description> - Sets fade in time of a OneShot node given its name and value in seconds. + Sets the fade in time of a OneShot node given its name and value in seconds. </description> </method> <method name="oneshot_node_set_fadeout_time"> @@ -416,7 +412,7 @@ <argument index="1" name="time_sec" type="float"> </argument> <description> - Sets fade out time of a OneShot node given its name and value in seconds. + Sets the fade out time of a OneShot node given its name and value in seconds. </description> </method> <method name="oneshot_node_set_filter_path"> @@ -429,7 +425,7 @@ <argument index="2" name="enable" type="bool"> </argument> <description> - If [code]enable[/code] is [code]true[/code], the oneshot node with ID [code]id[/code] turns off the track modifying the property at [code]path[/code]. The modified node's children continue to animate. + If [code]enable[/code] is [code]true[/code], the OneShot node with ID [code]id[/code] turns off the track modifying the property at [code]path[/code]. The modified node's children continue to animate. </description> </method> <method name="oneshot_node_start"> @@ -479,7 +475,7 @@ <argument index="0" name="id" type="String"> </argument> <description> - Returns time scale value of the TimeScale node with name [code]id[/code]. + Returns the time scale value of the TimeScale node with name [code]id[/code]. </description> </method> <method name="timescale_node_set_scale"> @@ -491,7 +487,7 @@ </argument> <description> Sets the time scale of the TimeScale node with name [code]id[/code] to [code]scale[/code]. - The timescale node is used to speed [Animation]s up if the scale is above 1 or slow them down if it is below 1. + The TimeScale node is used to speed [Animation]s up if the scale is above 1 or slow them down if it is below 1. If applied after a blend or mix, affects all input animations to that blend or mix. </description> </method> @@ -533,7 +529,7 @@ <argument index="0" name="id" type="String"> </argument> <description> - Returns the number of inputs for the transition node with name [code]id[/code]. You can add inputs by rightclicking on the transition node. + Returns the number of inputs for the transition node with name [code]id[/code]. You can add inputs by right-clicking on the transition node. </description> </method> <method name="transition_node_get_xfade_time" qualifiers="const"> @@ -553,7 +549,7 @@ <argument index="1" name="input_idx" type="int"> </argument> <description> - Returns [code]true[/code] if the input at [code]input_idx[/code] on transition node with name [code]id[/code] is set to automatically advance to the next input upon completion. + Returns [code]true[/code] if the input at [code]input_idx[/code] on the transition node with name [code]id[/code] is set to automatically advance to the next input upon completion. </description> </method> <method name="transition_node_set_current"> @@ -609,11 +605,11 @@ </member> <member name="base_path" type="NodePath" setter="set_base_path" getter="get_base_path" default="NodePath("..")"> The node from which to relatively access other nodes. - It accesses the Bones, so it should point to the same Node the AnimationPlayer would point its Root Node at. + It accesses the bones, so it should point to the same node the [AnimationPlayer] would point its Root Node at. </member> <member name="master_player" type="NodePath" setter="set_master_player" getter="get_master_player" default="NodePath("")"> The path to the [AnimationPlayer] from which this [AnimationTreePlayer] binds animations to animation nodes. - Once set, Animation nodes can be added to the AnimationTreePlayer. + Once set, [Animation] nodes can be added to the [AnimationTreePlayer]. </member> <member name="playback_process_mode" type="int" setter="set_animation_process_mode" getter="get_animation_process_mode" enum="AnimationTreePlayer.AnimationProcessMode" default="1"> The thread in which to update animations. diff --git a/doc/classes/Area.xml b/doc/classes/Area.xml index 4b0858935d..f2f9284ae3 100644 --- a/doc/classes/Area.xml +++ b/doc/classes/Area.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Area" inherits="CollisionObject" category="Core" version="3.2"> +<class name="Area" inherits="CollisionObject" version="4.0"> <brief_description> General-purpose area node for detection and 3D physics influence. </brief_description> diff --git a/doc/classes/Area2D.xml b/doc/classes/Area2D.xml index be3acee9ef..715e9b3286 100644 --- a/doc/classes/Area2D.xml +++ b/doc/classes/Area2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Area2D" inherits="CollisionObject2D" category="Core" version="3.2"> +<class name="Area2D" inherits="CollisionObject2D" version="4.0"> <brief_description> 2D area for detection and 2D physics influence. </brief_description> diff --git a/doc/classes/Array.xml b/doc/classes/Array.xml index c192cee1fe..08455bb7bc 100644 --- a/doc/classes/Array.xml +++ b/doc/classes/Array.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Array" category="Built-In Types" version="3.2"> +<class name="Array" version="4.0"> <brief_description> Generic array datatype. </brief_description> @@ -8,11 +8,11 @@ [b]Example:[/b] [codeblock] var array = ["One", 2, 3, "Four"] - print(array[0]) # One - print(array[2]) # 3 - print(array[-1]) # Four + print(array[0]) # One. + print(array[2]) # 3. + print(array[-1]) # Four. array[2] = "Three" - print(array[-2]) # Three + print(array[-2]) # Three. [/codeblock] Arrays are always passed by reference. </description> @@ -322,7 +322,12 @@ <method name="sort"> <description> Sorts the array. - [b]Note:[/b] strings are sorted in alphabetical, not natural order. + [b]Note:[/b] Strings are sorted in alphabetical order (as opposed to natural order). This may lead to unexpected behavior when sorting an array of strings ending with a sequence of numbers. Consider the following example: + [codeblock] + var strings = ["string1", "string2", "string10", "string11"] + strings.sort() + print(strings) # Prints [string1, string10, string11, string2] + [/codeblock] </description> </method> <method name="sort_custom"> @@ -342,7 +347,7 @@ var my_items = [[5, "Potato"], [9, "Rice"], [4, "Tomato"]] my_items.sort_custom(MyCustomSorter, "sort_ascending") - print(my_items) # Prints [[4, Tomato], [5, Potato], [9, Rice]] + print(my_items) # Prints [[4, Tomato], [5, Potato], [9, Rice]]. [/codeblock] </description> </method> diff --git a/doc/classes/ArrayMesh.xml b/doc/classes/ArrayMesh.xml index 62ff0edbd2..821c6db717 100644 --- a/doc/classes/ArrayMesh.xml +++ b/doc/classes/ArrayMesh.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ArrayMesh" inherits="Mesh" category="Core" version="3.2"> +<class name="ArrayMesh" inherits="Mesh" version="4.0"> <brief_description> [Mesh] type that provides utility for constructing a surface from arrays. </brief_description> <description> - The [ArrayMesh] is used to construct a [Mesh] by specifying the attributes as arrays. The most basic example is the creation of a single triangle + The [ArrayMesh] is used to construct a [Mesh] by specifying the attributes as arrays. + The most basic example is the creation of a single triangle: [codeblock] var vertices = PoolVector3Array() vertices.push_back(Vector3(0, 1, 0)) @@ -20,9 +21,10 @@ var m = MeshInstance.new() m.mesh = arr_mesh [/codeblock] - The [code]MeshInstance[/code] is ready to be added to the SceneTree to be shown. + The [MeshInstance] is ready to be added to the [SceneTree] to be shown. </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/content/procedural_geometry/arraymesh.html</link> </tutorials> <methods> <method name="add_blend_shape"> @@ -185,6 +187,7 @@ </methods> <members> <member name="blend_shape_mode" type="int" setter="set_blend_shape_mode" getter="get_blend_shape_mode" enum="Mesh.BlendShapeMode" default="1"> + Sets the blend shape mode to one of [enum Mesh.BlendShapeMode]. </member> <member name="custom_aabb" type="AABB" setter="set_custom_aabb" getter="get_custom_aabb" default="AABB( 0, 0, 0, 0, 0, 0 )"> Overrides the [AABB] with one defined by user for use with frustum culling. Especially useful to avoid unexpected culling when using a shader to offset vertices. @@ -232,10 +235,10 @@ Array format will include vertices (mandatory). </constant> <constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat"> - Array format will include normals + Array format will include normals. </constant> <constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat"> - Array format will include tangents + Array format will include tangents. </constant> <constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat"> Array format will include a color array. diff --git a/doc/classes/AtlasTexture.xml b/doc/classes/AtlasTexture.xml index db6ac1bc6d..7150490371 100644 --- a/doc/classes/AtlasTexture.xml +++ b/doc/classes/AtlasTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AtlasTexture" inherits="Texture" category="Core" version="3.2"> +<class name="AtlasTexture" inherits="Texture" version="4.0"> <brief_description> Packs multiple small textures in a single, bigger one. Helps to optimize video memory costs and render calls. </brief_description> diff --git a/doc/classes/AudioBusLayout.xml b/doc/classes/AudioBusLayout.xml index fb36440a67..09746913bd 100644 --- a/doc/classes/AudioBusLayout.xml +++ b/doc/classes/AudioBusLayout.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioBusLayout" inherits="Resource" category="Core" version="3.2"> +<class name="AudioBusLayout" inherits="Resource" version="4.0"> <brief_description> Stores information about the audio buses. </brief_description> diff --git a/doc/classes/AudioEffect.xml b/doc/classes/AudioEffect.xml index 3e7863a44c..60bf15ce57 100644 --- a/doc/classes/AudioEffect.xml +++ b/doc/classes/AudioEffect.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffect" inherits="Resource" category="Core" version="3.2"> +<class name="AudioEffect" inherits="Resource" version="4.0"> <brief_description> Audio effect for audio. </brief_description> diff --git a/doc/classes/AudioEffectAmplify.xml b/doc/classes/AudioEffectAmplify.xml index 3003238eb9..1334a81661 100644 --- a/doc/classes/AudioEffectAmplify.xml +++ b/doc/classes/AudioEffectAmplify.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectAmplify" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectAmplify" inherits="AudioEffect" version="4.0"> <brief_description> Adds an amplifying audio effect to an audio bus. Increases or decreases the volume of the selected audio bus. diff --git a/doc/classes/AudioEffectBandLimitFilter.xml b/doc/classes/AudioEffectBandLimitFilter.xml index f85c8cdd32..e8b398c8f4 100644 --- a/doc/classes/AudioEffectBandLimitFilter.xml +++ b/doc/classes/AudioEffectBandLimitFilter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectBandLimitFilter" inherits="AudioEffectFilter" category="Core" version="3.2"> +<class name="AudioEffectBandLimitFilter" inherits="AudioEffectFilter" version="4.0"> <brief_description> Adds a band limit filter to the audio bus. </brief_description> diff --git a/doc/classes/AudioEffectBandPassFilter.xml b/doc/classes/AudioEffectBandPassFilter.xml index 359eb9d669..ad3dbc5256 100644 --- a/doc/classes/AudioEffectBandPassFilter.xml +++ b/doc/classes/AudioEffectBandPassFilter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectBandPassFilter" inherits="AudioEffectFilter" category="Core" version="3.2"> +<class name="AudioEffectBandPassFilter" inherits="AudioEffectFilter" version="4.0"> <brief_description> Adds a band pass filter to the audio bus. </brief_description> diff --git a/doc/classes/AudioEffectChorus.xml b/doc/classes/AudioEffectChorus.xml index 4da125ba63..30913a1529 100644 --- a/doc/classes/AudioEffectChorus.xml +++ b/doc/classes/AudioEffectChorus.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectChorus" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectChorus" inherits="AudioEffect" version="4.0"> <brief_description> Adds a chorus audio effect. </brief_description> diff --git a/doc/classes/AudioEffectCompressor.xml b/doc/classes/AudioEffectCompressor.xml index 6834804ea7..fe0d63777f 100644 --- a/doc/classes/AudioEffectCompressor.xml +++ b/doc/classes/AudioEffectCompressor.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectCompressor" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectCompressor" inherits="AudioEffect" version="4.0"> <brief_description> Adds a compressor audio effect to an audio bus. Reduces sounds that exceed a certain threshold level, smooths out the dynamics and increases the overall volume. diff --git a/doc/classes/AudioEffectDelay.xml b/doc/classes/AudioEffectDelay.xml index aea6ead983..e55e0cb2ad 100644 --- a/doc/classes/AudioEffectDelay.xml +++ b/doc/classes/AudioEffectDelay.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectDelay" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectDelay" inherits="AudioEffect" version="4.0"> <brief_description> Adds a delay audio effect to an audio bus. Plays input signal back after a period of time. Two tap delay and feedback options. diff --git a/doc/classes/AudioEffectDistortion.xml b/doc/classes/AudioEffectDistortion.xml index 0ee7d73f88..3cfeaadb23 100644 --- a/doc/classes/AudioEffectDistortion.xml +++ b/doc/classes/AudioEffectDistortion.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectDistortion" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectDistortion" inherits="AudioEffect" version="4.0"> <brief_description> Adds a distortion audio effect to an Audio bus. Modify the sound to make it dirty. diff --git a/doc/classes/AudioEffectEQ.xml b/doc/classes/AudioEffectEQ.xml index d30b6fc71d..c27c2f221c 100644 --- a/doc/classes/AudioEffectEQ.xml +++ b/doc/classes/AudioEffectEQ.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectEQ" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectEQ" inherits="AudioEffect" version="4.0"> <brief_description> Base class for audio equalizers. Gives you control over frequencies. Use it to create a custom equalizer if [AudioEffectEQ6], [AudioEffectEQ10] or [AudioEffectEQ21] don't fit your needs. diff --git a/doc/classes/AudioEffectEQ10.xml b/doc/classes/AudioEffectEQ10.xml index e94c4c71df..c9fb03e23c 100644 --- a/doc/classes/AudioEffectEQ10.xml +++ b/doc/classes/AudioEffectEQ10.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectEQ10" inherits="AudioEffectEQ" category="Core" version="3.2"> +<class name="AudioEffectEQ10" inherits="AudioEffectEQ" version="4.0"> <brief_description> Adds a 10-band equalizer audio effect to an Audio bus. Gives you control over frequencies from 31 Hz to 16000 Hz. Each frequency can be modulated between -60/+24 dB. diff --git a/doc/classes/AudioEffectEQ21.xml b/doc/classes/AudioEffectEQ21.xml index dd26e06ee8..7ff8a1756e 100644 --- a/doc/classes/AudioEffectEQ21.xml +++ b/doc/classes/AudioEffectEQ21.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectEQ21" inherits="AudioEffectEQ" category="Core" version="3.2"> +<class name="AudioEffectEQ21" inherits="AudioEffectEQ" version="4.0"> <brief_description> Adds a 21-band equalizer audio effect to an Audio bus. Gives you control over frequencies from 22 Hz to 22000 Hz. Each frequency can be modulated between -60/+24 dB. diff --git a/doc/classes/AudioEffectEQ6.xml b/doc/classes/AudioEffectEQ6.xml index eb3dc738ef..b47da5ed2a 100644 --- a/doc/classes/AudioEffectEQ6.xml +++ b/doc/classes/AudioEffectEQ6.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectEQ6" inherits="AudioEffectEQ" category="Core" version="3.2"> +<class name="AudioEffectEQ6" inherits="AudioEffectEQ" version="4.0"> <brief_description> Adds a 6-band equalizer audio effect to an Audio bus. Gives you control over frequencies from 32 Hz to 10000 Hz. Each frequency can be modulated between -60/+24 dB. diff --git a/doc/classes/AudioEffectFilter.xml b/doc/classes/AudioEffectFilter.xml index 5daad6748f..f548fb49cc 100644 --- a/doc/classes/AudioEffectFilter.xml +++ b/doc/classes/AudioEffectFilter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectFilter" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectFilter" inherits="AudioEffect" version="4.0"> <brief_description> Adds a filter to the audio bus. </brief_description> diff --git a/doc/classes/AudioEffectHighPassFilter.xml b/doc/classes/AudioEffectHighPassFilter.xml index 589195da02..82a3c74941 100644 --- a/doc/classes/AudioEffectHighPassFilter.xml +++ b/doc/classes/AudioEffectHighPassFilter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectHighPassFilter" inherits="AudioEffectFilter" category="Core" version="3.2"> +<class name="AudioEffectHighPassFilter" inherits="AudioEffectFilter" version="4.0"> <brief_description> Adds a high-pass filter to the Audio Bus. </brief_description> diff --git a/doc/classes/AudioEffectHighShelfFilter.xml b/doc/classes/AudioEffectHighShelfFilter.xml index cccd18afcc..cf620e4417 100644 --- a/doc/classes/AudioEffectHighShelfFilter.xml +++ b/doc/classes/AudioEffectHighShelfFilter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectHighShelfFilter" inherits="AudioEffectFilter" category="Core" version="3.2"> +<class name="AudioEffectHighShelfFilter" inherits="AudioEffectFilter" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioEffectInstance.xml b/doc/classes/AudioEffectInstance.xml index eb8bcfdf2a..dc76880a36 100644 --- a/doc/classes/AudioEffectInstance.xml +++ b/doc/classes/AudioEffectInstance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectInstance" inherits="Reference" category="Core" version="3.2"> +<class name="AudioEffectInstance" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioEffectLimiter.xml b/doc/classes/AudioEffectLimiter.xml index ee6252809a..2fbea06aed 100644 --- a/doc/classes/AudioEffectLimiter.xml +++ b/doc/classes/AudioEffectLimiter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectLimiter" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectLimiter" inherits="AudioEffect" version="4.0"> <brief_description> Adds a soft-clip limiter audio effect to an Audio bus. </brief_description> diff --git a/doc/classes/AudioEffectLowPassFilter.xml b/doc/classes/AudioEffectLowPassFilter.xml index c0319a6713..e7a66d03bd 100644 --- a/doc/classes/AudioEffectLowPassFilter.xml +++ b/doc/classes/AudioEffectLowPassFilter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectLowPassFilter" inherits="AudioEffectFilter" category="Core" version="3.2"> +<class name="AudioEffectLowPassFilter" inherits="AudioEffectFilter" version="4.0"> <brief_description> Adds a low-pass filter to the Audio bus. </brief_description> diff --git a/doc/classes/AudioEffectLowShelfFilter.xml b/doc/classes/AudioEffectLowShelfFilter.xml index 1e60e637fc..7cf09b0f05 100644 --- a/doc/classes/AudioEffectLowShelfFilter.xml +++ b/doc/classes/AudioEffectLowShelfFilter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectLowShelfFilter" inherits="AudioEffectFilter" category="Core" version="3.2"> +<class name="AudioEffectLowShelfFilter" inherits="AudioEffectFilter" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioEffectNotchFilter.xml b/doc/classes/AudioEffectNotchFilter.xml index 4b5cfd7e51..2393674a2e 100644 --- a/doc/classes/AudioEffectNotchFilter.xml +++ b/doc/classes/AudioEffectNotchFilter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectNotchFilter" inherits="AudioEffectFilter" category="Core" version="3.2"> +<class name="AudioEffectNotchFilter" inherits="AudioEffectFilter" version="4.0"> <brief_description> Adds a notch filter to the Audio bus. </brief_description> diff --git a/doc/classes/AudioEffectPanner.xml b/doc/classes/AudioEffectPanner.xml index e3a2dfcf21..19c4cd1457 100644 --- a/doc/classes/AudioEffectPanner.xml +++ b/doc/classes/AudioEffectPanner.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectPanner" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectPanner" inherits="AudioEffect" version="4.0"> <brief_description> Adds a panner audio effect to an Audio bus. Pans sound left or right. </brief_description> diff --git a/doc/classes/AudioEffectPhaser.xml b/doc/classes/AudioEffectPhaser.xml index 445f78dd73..b1d229e150 100644 --- a/doc/classes/AudioEffectPhaser.xml +++ b/doc/classes/AudioEffectPhaser.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectPhaser" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectPhaser" inherits="AudioEffect" version="4.0"> <brief_description> Adds a phaser audio effect to an Audio bus. Combines the original signal with a copy that is slightly out of phase with the original. diff --git a/doc/classes/AudioEffectPitchShift.xml b/doc/classes/AudioEffectPitchShift.xml index 1f891dfb32..afe364de63 100644 --- a/doc/classes/AudioEffectPitchShift.xml +++ b/doc/classes/AudioEffectPitchShift.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectPitchShift" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectPitchShift" inherits="AudioEffect" version="4.0"> <brief_description> Adds a pitch-shifting audio effect to an Audio bus. Raises or lowers the pitch of original sound. diff --git a/doc/classes/AudioEffectRecord.xml b/doc/classes/AudioEffectRecord.xml index 4f97797b37..189e3c7059 100644 --- a/doc/classes/AudioEffectRecord.xml +++ b/doc/classes/AudioEffectRecord.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectRecord" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectRecord" inherits="AudioEffect" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioEffectReverb.xml b/doc/classes/AudioEffectReverb.xml index a0664e727f..26eb2be753 100644 --- a/doc/classes/AudioEffectReverb.xml +++ b/doc/classes/AudioEffectReverb.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectReverb" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectReverb" inherits="AudioEffect" version="4.0"> <brief_description> Adds a reverberation audio effect to an Audio bus. Simulates the sound of acoustic environments such as rooms, concert halls, caverns, or an open spaces. diff --git a/doc/classes/AudioEffectSpectrumAnalyzer.xml b/doc/classes/AudioEffectSpectrumAnalyzer.xml index a56e4f2692..4c08b18f1d 100644 --- a/doc/classes/AudioEffectSpectrumAnalyzer.xml +++ b/doc/classes/AudioEffectSpectrumAnalyzer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectSpectrumAnalyzer" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectSpectrumAnalyzer" inherits="AudioEffect" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioEffectSpectrumAnalyzerInstance.xml b/doc/classes/AudioEffectSpectrumAnalyzerInstance.xml index ca068d572d..53428cdfb8 100644 --- a/doc/classes/AudioEffectSpectrumAnalyzerInstance.xml +++ b/doc/classes/AudioEffectSpectrumAnalyzerInstance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectSpectrumAnalyzerInstance" inherits="AudioEffectInstance" category="Core" version="3.2"> +<class name="AudioEffectSpectrumAnalyzerInstance" inherits="AudioEffectInstance" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioEffectStereoEnhance.xml b/doc/classes/AudioEffectStereoEnhance.xml index 6cb692b5d7..663e3e982c 100644 --- a/doc/classes/AudioEffectStereoEnhance.xml +++ b/doc/classes/AudioEffectStereoEnhance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioEffectStereoEnhance" inherits="AudioEffect" category="Core" version="3.2"> +<class name="AudioEffectStereoEnhance" inherits="AudioEffect" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioServer.xml b/doc/classes/AudioServer.xml index 2d3ceebed5..72acf616a9 100644 --- a/doc/classes/AudioServer.xml +++ b/doc/classes/AudioServer.xml @@ -1,10 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioServer" inherits="Object" category="Core" version="3.2"> +<class name="AudioServer" inherits="Object" version="4.0"> <brief_description> Server interface for low-level audio access. </brief_description> <description> - AudioServer is a low-level server interface for audio access. It is in charge of creating sample data (playable audio) as well as its playback via a voice interface. + [AudioServer] is a low-level server interface for audio access. It is in charge of creating sample data (playable audio) as well as its playback via a voice interface. </description> <tutorials> <link>https://docs.godotengine.org/en/latest/tutorials/audio/audio_buses.html</link> @@ -32,25 +32,27 @@ Adds an [AudioEffect] effect to the bus [code]bus_idx[/code] at [code]at_position[/code]. </description> </method> - <method name="capture_get_device_list"> - <return type="Array"> + <method name="capture_get_device"> + <return type="String"> </return> <description> - Returns the names of all audio input devices detected on the system. + Name of the current device for audio input (see [method capture_get_device_list]). </description> </method> - <method name="capture_start"> - <return type="int" enum="Error"> + <method name="capture_get_device_list"> + <return type="Array"> </return> <description> - Attempts to start recording from the audio driver's capture device. On success, the return value is [constant OK]. + Returns the names of all audio input devices detected on the system. </description> </method> - <method name="capture_stop"> - <return type="int" enum="Error"> + <method name="capture_set_device"> + <return type="void"> </return> + <argument index="0" name="name" type="String"> + </argument> <description> - Attempts to stop recording from the audio driver's capture device. On success, the return value is [constant OK]. + Sets which audio input device is used for audio capture. </description> </method> <method name="generate_bus_layout" qualifiers="const"> @@ -99,6 +101,7 @@ <argument index="2" name="channel" type="int" default="0"> </argument> <description> + Returns the [AudioEffectInstance] assigned to the given bus and effect indices (and optionally channel). </description> </method> <method name="get_bus_index" qualifiers="const"> @@ -159,32 +162,11 @@ Returns the volume of the bus at index [code]bus_idx[/code] in dB. </description> </method> - <method name="get_capture_buffer"> - <return type="PoolIntArray"> - </return> - <description> - Returns an [PoolIntArray] containing audio frames from the capture device. - </description> - </method> - <method name="get_capture_position"> - <return type="int"> - </return> - <description> - Returns the write position of the capture device buffer. - </description> - </method> - <method name="get_capture_size"> - <return type="int"> - </return> - <description> - Returns the size of the capture device buffer. - </description> - </method> <method name="get_device_list"> <return type="Array"> </return> <description> - Returns the names of all audio output devices detected on the system. + Returns the names of all audio devices detected on the system. </description> </method> <method name="get_mix_rate" qualifiers="const"> @@ -212,12 +194,14 @@ <return type="float"> </return> <description> + Returns the relative time since the last mix occurred. </description> </method> <method name="get_time_to_next_mix" qualifiers="const"> <return type="float"> </return> <description> + Returns the relative time until the next mix occurs. </description> </method> <method name="is_bus_bypassing_effects" qualifiers="const"> @@ -262,7 +246,8 @@ <return type="void"> </return> <description> - Locks the audio driver's main loop. Remember to unlock it afterwards. + Locks the audio driver's main loop. + [b]Note:[/b] Remember to unlock it afterwards. </description> </method> <method name="move_bus"> @@ -409,9 +394,6 @@ <member name="bus_count" type="int" setter="set_bus_count" getter="get_bus_count" default="1"> Number of available audio buses. </member> - <member name="capture_device" type="String" setter="capture_set_device" getter="capture_get_device" default=""""> - Name of the current device for audio input (see [method capture_get_device_list]). - </member> <member name="device" type="String" setter="set_device" getter="get_device" default=""Default""> Name of the current device for audio output (see [method get_device_list]). </member> @@ -420,14 +402,6 @@ </member> </members> <signals> - <signal name="audio_mix_callback"> - <description> - </description> - </signal> - <signal name="audio_update_callback"> - <description> - </description> - </signal> <signal name="bus_layout_changed"> <description> Emitted when the [AudioBusLayout] changes. @@ -442,10 +416,10 @@ A 3.1 channel surround setup was detected. </constant> <constant name="SPEAKER_SURROUND_51" value="2" enum="SpeakerMode"> - A 5.1 channel surround setup was detected. + A 5.1 channel surround setup was detected. </constant> <constant name="SPEAKER_SURROUND_71" value="3" enum="SpeakerMode"> - A 7.1 channel surround setup was detected. + A 7.1 channel surround setup was detected. </constant> </constants> </class> diff --git a/doc/classes/AudioStream.xml b/doc/classes/AudioStream.xml index 15662b7eff..d5c8e42515 100644 --- a/doc/classes/AudioStream.xml +++ b/doc/classes/AudioStream.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStream" inherits="Resource" category="Core" version="3.2"> +<class name="AudioStream" inherits="Resource" version="4.0"> <brief_description> Base class for audio streams. </brief_description> diff --git a/doc/classes/AudioStreamGenerator.xml b/doc/classes/AudioStreamGenerator.xml index 9a1e4432f1..e93da411cd 100644 --- a/doc/classes/AudioStreamGenerator.xml +++ b/doc/classes/AudioStreamGenerator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamGenerator" inherits="AudioStream" category="Core" version="3.2"> +<class name="AudioStreamGenerator" inherits="AudioStream" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioStreamGeneratorPlayback.xml b/doc/classes/AudioStreamGeneratorPlayback.xml index 448284e670..2552cd50a4 100644 --- a/doc/classes/AudioStreamGeneratorPlayback.xml +++ b/doc/classes/AudioStreamGeneratorPlayback.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamGeneratorPlayback" inherits="AudioStreamPlaybackResampled" category="Core" version="3.2"> +<class name="AudioStreamGeneratorPlayback" inherits="AudioStreamPlaybackResampled" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioStreamMicrophone.xml b/doc/classes/AudioStreamMicrophone.xml index afa60655ea..e73e50e3a9 100644 --- a/doc/classes/AudioStreamMicrophone.xml +++ b/doc/classes/AudioStreamMicrophone.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamMicrophone" inherits="AudioStream" category="Core" version="3.2"> +<class name="AudioStreamMicrophone" inherits="AudioStream" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioStreamPlayback.xml b/doc/classes/AudioStreamPlayback.xml index 92e654a50f..f928d54526 100644 --- a/doc/classes/AudioStreamPlayback.xml +++ b/doc/classes/AudioStreamPlayback.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamPlayback" inherits="Reference" category="Core" version="3.2"> +<class name="AudioStreamPlayback" inherits="Reference" version="4.0"> <brief_description> Meta class for playing back audio. </brief_description> diff --git a/doc/classes/AudioStreamPlaybackResampled.xml b/doc/classes/AudioStreamPlaybackResampled.xml index 07e7e70bf1..faa563fdd8 100644 --- a/doc/classes/AudioStreamPlaybackResampled.xml +++ b/doc/classes/AudioStreamPlaybackResampled.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamPlaybackResampled" inherits="AudioStreamPlayback" category="Core" version="3.2"> +<class name="AudioStreamPlaybackResampled" inherits="AudioStreamPlayback" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/AudioStreamPlayer.xml b/doc/classes/AudioStreamPlayer.xml index 0eadf27c4d..2d65defad3 100644 --- a/doc/classes/AudioStreamPlayer.xml +++ b/doc/classes/AudioStreamPlayer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamPlayer" inherits="Node" category="Core" version="3.2"> +<class name="AudioStreamPlayer" inherits="Node" version="4.0"> <brief_description> Plays back audio non-positionally. </brief_description> diff --git a/doc/classes/AudioStreamPlayer2D.xml b/doc/classes/AudioStreamPlayer2D.xml index ec3b7872b7..66254b504a 100644 --- a/doc/classes/AudioStreamPlayer2D.xml +++ b/doc/classes/AudioStreamPlayer2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamPlayer2D" inherits="Node2D" category="Core" version="3.2"> +<class name="AudioStreamPlayer2D" inherits="Node2D" version="4.0"> <brief_description> Plays audio in 2D. </brief_description> diff --git a/doc/classes/AudioStreamPlayer3D.xml b/doc/classes/AudioStreamPlayer3D.xml index 5e12e06650..f476bec323 100644 --- a/doc/classes/AudioStreamPlayer3D.xml +++ b/doc/classes/AudioStreamPlayer3D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamPlayer3D" inherits="Spatial" category="Core" version="3.2"> +<class name="AudioStreamPlayer3D" inherits="Spatial" version="4.0"> <brief_description> Plays 3D sound in 3D space. </brief_description> diff --git a/doc/classes/AudioStreamRandomPitch.xml b/doc/classes/AudioStreamRandomPitch.xml index a2ee314d92..7e93b3267c 100644 --- a/doc/classes/AudioStreamRandomPitch.xml +++ b/doc/classes/AudioStreamRandomPitch.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamRandomPitch" inherits="AudioStream" category="Core" version="3.2"> +<class name="AudioStreamRandomPitch" inherits="AudioStream" version="4.0"> <brief_description> Plays audio with random pitch shifting. </brief_description> diff --git a/doc/classes/AudioStreamSample.xml b/doc/classes/AudioStreamSample.xml index bb418f3c36..898879ae27 100644 --- a/doc/classes/AudioStreamSample.xml +++ b/doc/classes/AudioStreamSample.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamSample" inherits="AudioStream" category="Core" version="3.2"> +<class name="AudioStreamSample" inherits="AudioStream" version="4.0"> <brief_description> Stores audio data loaded from WAV files. </brief_description> diff --git a/doc/classes/BackBufferCopy.xml b/doc/classes/BackBufferCopy.xml index 945af0c701..1f7554f978 100644 --- a/doc/classes/BackBufferCopy.xml +++ b/doc/classes/BackBufferCopy.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BackBufferCopy" inherits="Node2D" category="Core" version="3.2"> +<class name="BackBufferCopy" inherits="Node2D" version="4.0"> <brief_description> Copies a region of the screen (or the whole screen) to a buffer so it can be accessed in your shader scripts through the [code]texture(SCREEN_TEXTURE, ...)[/code] function. </brief_description> diff --git a/doc/classes/BakedLightmap.xml b/doc/classes/BakedLightmap.xml index 4a1381295f..587ff7f304 100644 --- a/doc/classes/BakedLightmap.xml +++ b/doc/classes/BakedLightmap.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BakedLightmap" inherits="VisualInstance" category="Core" version="3.2"> +<class name="BakedLightmap" inherits="VisualInstance" version="4.0"> <brief_description> Prerendered indirect light map for a scene. </brief_description> @@ -18,7 +18,7 @@ <argument index="1" name="create_visual_debug" type="bool" default="false"> </argument> <description> - Bakes the lightmaps within the currently edited scene. + Bakes the lightmaps within the currently edited scene. Returns a [enum BakeError] to signify if the bake was successful, or if unsuccessful, how the bake failed. </description> </method> <method name="debug_bake"> @@ -81,14 +81,19 @@ More precise bake mode but can take considerably longer to bake. </constant> <constant name="BAKE_ERROR_OK" value="0" enum="BakeError"> + Baking was successful. </constant> <constant name="BAKE_ERROR_NO_SAVE_PATH" value="1" enum="BakeError"> + Returns if no viable save path is found. This can happen where an [member image_path] is not specified or when the save location is invalid. </constant> <constant name="BAKE_ERROR_NO_MESHES" value="2" enum="BakeError"> + Currently unused. </constant> <constant name="BAKE_ERROR_CANT_CREATE_IMAGE" value="3" enum="BakeError"> + Returns when the baker cannot save per-mesh textures to file. </constant> <constant name="BAKE_ERROR_USER_ABORTED" value="4" enum="BakeError"> + Returns if user cancels baking. </constant> </constants> </class> diff --git a/doc/classes/BakedLightmapData.xml b/doc/classes/BakedLightmapData.xml index 68bbfb8f60..9193fb3b68 100644 --- a/doc/classes/BakedLightmapData.xml +++ b/doc/classes/BakedLightmapData.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BakedLightmapData" inherits="Resource" category="Core" version="3.2"> +<class name="BakedLightmapData" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/BaseButton.xml b/doc/classes/BaseButton.xml index 21f46efe84..2147b2b4b0 100644 --- a/doc/classes/BaseButton.xml +++ b/doc/classes/BaseButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BaseButton" inherits="Control" category="Core" version="3.2"> +<class name="BaseButton" inherits="Control" version="4.0"> <brief_description> Base class for different kinds of buttons. </brief_description> @@ -112,6 +112,7 @@ The state of buttons are disabled. </constant> <constant name="DRAW_HOVER_PRESSED" value="4" enum="DrawMode"> + The state of buttons are both hovered and pressed. </constant> <constant name="ACTION_MODE_BUTTON_PRESS" value="0" enum="ActionMode"> Require just a press to consider the button clicked. diff --git a/doc/classes/Basis.xml b/doc/classes/Basis.xml index b8fe23c2c9..e2b5c23c11 100644 --- a/doc/classes/Basis.xml +++ b/doc/classes/Basis.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Basis" category="Built-In Types" version="3.2"> +<class name="Basis" version="4.0"> <brief_description> 3×3 matrix datatype. </brief_description> diff --git a/doc/classes/BitMap.xml b/doc/classes/BitMap.xml index 7f03c22b70..f0ac7d1160 100644 --- a/doc/classes/BitMap.xml +++ b/doc/classes/BitMap.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BitMap" inherits="Resource" category="Core" version="3.2"> +<class name="BitMap" inherits="Resource" version="4.0"> <brief_description> Boolean matrix. </brief_description> diff --git a/doc/classes/BitmapFont.xml b/doc/classes/BitmapFont.xml index 5b7c3def63..87cccca310 100644 --- a/doc/classes/BitmapFont.xml +++ b/doc/classes/BitmapFont.xml @@ -1,8 +1,8 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BitmapFont" inherits="Font" category="Core" version="3.2"> +<class name="BitmapFont" inherits="Font" version="4.0"> <brief_description> Renders text using fonts under the [url=https://www.angelcode.com/products/bmfont/]BMFont[/url] format. - Handles files with the [code].fnt[/code] extension + Handles files with the [code].fnt[/code] extension. </brief_description> <description> Renders text using [code]*.fnt[/code] fonts containing texture atlases. Supports distance fields. For using vector font files like TTF directly, see [DynamicFont]. diff --git a/doc/classes/Bone2D.xml b/doc/classes/Bone2D.xml index 21e08f13f9..910d488dfd 100644 --- a/doc/classes/Bone2D.xml +++ b/doc/classes/Bone2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Bone2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Bone2D" inherits="Node2D" version="4.0"> <brief_description> Joint used with [Skeleton2D] to control and animate other nodes. </brief_description> diff --git a/doc/classes/BoneAttachment.xml b/doc/classes/BoneAttachment.xml index a6145b6a78..d15322254b 100644 --- a/doc/classes/BoneAttachment.xml +++ b/doc/classes/BoneAttachment.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BoneAttachment" inherits="Spatial" category="Core" version="3.2"> +<class name="BoneAttachment" inherits="Spatial" version="4.0"> <brief_description> A node that will attach to a bone. </brief_description> diff --git a/doc/classes/BoxContainer.xml b/doc/classes/BoxContainer.xml index ae0a20b8f6..214afd519b 100644 --- a/doc/classes/BoxContainer.xml +++ b/doc/classes/BoxContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BoxContainer" inherits="Container" category="Core" version="3.2"> +<class name="BoxContainer" inherits="Container" version="4.0"> <brief_description> Base class for box containers. </brief_description> diff --git a/doc/classes/BoxShape.xml b/doc/classes/BoxShape.xml index 9e3977b342..3a5f05ef79 100644 --- a/doc/classes/BoxShape.xml +++ b/doc/classes/BoxShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BoxShape" inherits="Shape" category="Core" version="3.2"> +<class name="BoxShape" inherits="Shape" version="4.0"> <brief_description> Box shape resource. </brief_description> diff --git a/doc/classes/Button.xml b/doc/classes/Button.xml index 3b73580294..23c357ac68 100644 --- a/doc/classes/Button.xml +++ b/doc/classes/Button.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Button" inherits="BaseButton" category="Core" version="3.2"> +<class name="Button" inherits="BaseButton" version="4.0"> <brief_description> Standard themed Button. </brief_description> @@ -43,26 +43,37 @@ </constants> <theme_items> <theme_item name="disabled" type="StyleBox"> + [StyleBox] used when the [Button] is disabled. </theme_item> <theme_item name="focus" type="StyleBox"> + [StyleBox] used when the [Button] is focused. It is displayed over the current [StyleBox], so using [StyleBoxEmpty] will just disable the focus visual effect. </theme_item> <theme_item name="font" type="Font"> + [Font] of the [Button]'s text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> + Default text [Color] of the [Button]. </theme_item> <theme_item name="font_color_disabled" type="Color" default="Color( 0.9, 0.9, 0.9, 0.2 )"> + Text [Color] used when the [Button] is disabled. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 0.94, 0.94, 0.94, 1 )"> + Text [Color] used when the [Button] is being hovered. </theme_item> <theme_item name="font_color_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + Text [Color] used when the [Button] is being pressed. </theme_item> <theme_item name="hover" type="StyleBox"> + [StyleBox] used when the [Button] is being hovered. </theme_item> <theme_item name="hseparation" type="int" default="2"> + The horizontal space between [Button]'s icon and text. </theme_item> <theme_item name="normal" type="StyleBox"> + Default [StyleBox] for the [Button]. </theme_item> <theme_item name="pressed" type="StyleBox"> + [StyleBox] used when the [Button] is being pressed. </theme_item> </theme_items> </class> diff --git a/doc/classes/ButtonGroup.xml b/doc/classes/ButtonGroup.xml index 2c1f3163e0..b7f3234b36 100644 --- a/doc/classes/ButtonGroup.xml +++ b/doc/classes/ButtonGroup.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ButtonGroup" inherits="Resource" category="Core" version="3.2"> +<class name="ButtonGroup" inherits="Resource" version="4.0"> <brief_description> Group of Buttons. </brief_description> diff --git a/doc/classes/CPUParticles.xml b/doc/classes/CPUParticles.xml index e68b0feb2d..b9cc655784 100644 --- a/doc/classes/CPUParticles.xml +++ b/doc/classes/CPUParticles.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CPUParticles" inherits="GeometryInstance" category="Core" version="3.2"> +<class name="CPUParticles" inherits="GeometryInstance" version="4.0"> <brief_description> CPU-based 3D particle emitter. </brief_description> @@ -25,6 +25,7 @@ <argument index="0" name="param" type="int" enum="CPUParticles.Parameter"> </argument> <description> + Returns the base value of the parameter specified by [enum Parameter]. </description> </method> <method name="get_param_curve" qualifiers="const"> @@ -33,6 +34,7 @@ <argument index="0" name="param" type="int" enum="CPUParticles.Parameter"> </argument> <description> + Returns the [Curve] of the parameter specified by [enum Parameter]. </description> </method> <method name="get_param_randomness" qualifiers="const"> @@ -41,6 +43,7 @@ <argument index="0" name="param" type="int" enum="CPUParticles.Parameter"> </argument> <description> + Returns the randomness factor of the parameter specified by [enum Parameter]. </description> </method> <method name="get_particle_flag" qualifiers="const"> @@ -49,6 +52,7 @@ <argument index="0" name="flag" type="int" enum="CPUParticles.Flags"> </argument> <description> + Returns the enabled state of the given flag (see [enum Flags] for options). </description> </method> <method name="restart"> @@ -66,6 +70,7 @@ <argument index="1" name="value" type="float"> </argument> <description> + Sets the base value of the parameter specified by [enum Parameter]. </description> </method> <method name="set_param_curve"> @@ -76,6 +81,7 @@ <argument index="1" name="curve" type="Curve"> </argument> <description> + Sets the [Curve] of the parameter specified by [enum Parameter]. </description> </method> <method name="set_param_randomness"> @@ -86,6 +92,7 @@ <argument index="1" name="randomness" type="float"> </argument> <description> + Sets the randomness factor of the parameter specified by [enum Parameter]. </description> </method> <method name="set_particle_flag"> @@ -96,6 +103,7 @@ <argument index="1" name="enable" type="bool"> </argument> <description> + Enables or disables the given flag (see [enum Flags] for options). </description> </method> </methods> @@ -164,10 +172,13 @@ The rectangle's extents if [member emission_shape] is set to [constant EMISSION_SHAPE_BOX]. </member> <member name="emission_colors" type="PoolColorArray" setter="set_emission_colors" getter="get_emission_colors" default="PoolColorArray( )"> + Sets the [Color]s to modulate particles by when using [constant EMISSION_SHAPE_POINTS] or [constant EMISSION_SHAPE_DIRECTED_POINTS]. </member> <member name="emission_normals" type="PoolVector3Array" setter="set_emission_normals" getter="get_emission_normals"> + Sets the direction the particles will be emitted in when using [constant EMISSION_SHAPE_DIRECTED_POINTS]. </member> <member name="emission_points" type="PoolVector3Array" setter="set_emission_points" getter="get_emission_points" default="PoolVector3Array( )"> + Sets the initial positions to spawn particles when using [constant EMISSION_SHAPE_POINTS] or [constant EMISSION_SHAPE_DIRECTED_POINTS]. </member> <member name="emission_shape" type="int" setter="set_emission_shape" getter="get_emission_shape" enum="CPUParticles.EmissionShape" default="0"> Particles will be emitted inside this region. See [enum EmissionShape] for possible values. @@ -367,5 +378,8 @@ <constant name="EMISSION_SHAPE_DIRECTED_POINTS" value="4" enum="EmissionShape"> Particles will be emitted at a position chosen randomly among [member emission_points]. Particle velocity and rotation will be set based on [member emission_normals]. Particle color will be modulated by [member emission_colors]. </constant> + <constant name="EMISSION_SHAPE_MAX" value="5" enum="EmissionShape"> + Represents the size of the [enum EmissionShape] enum. + </constant> </constants> </class> diff --git a/doc/classes/CPUParticles2D.xml b/doc/classes/CPUParticles2D.xml index c8dbffb4cb..e747feeae8 100644 --- a/doc/classes/CPUParticles2D.xml +++ b/doc/classes/CPUParticles2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CPUParticles2D" inherits="Node2D" category="Core" version="3.2"> +<class name="CPUParticles2D" inherits="Node2D" version="4.0"> <brief_description> CPU-based 2D particle emitter. </brief_description> @@ -26,6 +26,7 @@ <argument index="0" name="param" type="int" enum="CPUParticles2D.Parameter"> </argument> <description> + Returns the base value of the parameter specified by [enum Parameter]. </description> </method> <method name="get_param_curve" qualifiers="const"> @@ -34,6 +35,7 @@ <argument index="0" name="param" type="int" enum="CPUParticles2D.Parameter"> </argument> <description> + Returns the [Curve] of the parameter specified by [enum Parameter]. </description> </method> <method name="get_param_randomness" qualifiers="const"> @@ -42,6 +44,7 @@ <argument index="0" name="param" type="int" enum="CPUParticles2D.Parameter"> </argument> <description> + Returns the randomness factor of the parameter specified by [enum Parameter]. </description> </method> <method name="get_particle_flag" qualifiers="const"> @@ -50,6 +53,7 @@ <argument index="0" name="flag" type="int" enum="CPUParticles2D.Flags"> </argument> <description> + Returns the enabled state of the given flag (see [enum Flags] for options). </description> </method> <method name="restart"> @@ -67,6 +71,7 @@ <argument index="1" name="value" type="float"> </argument> <description> + Sets the base value of the parameter specified by [enum Parameter]. </description> </method> <method name="set_param_curve"> @@ -77,6 +82,7 @@ <argument index="1" name="curve" type="Curve"> </argument> <description> + Sets the [Curve] of the parameter specified by [enum Parameter]. </description> </method> <method name="set_param_randomness"> @@ -87,6 +93,7 @@ <argument index="1" name="randomness" type="float"> </argument> <description> + Sets the randomness factor of the parameter specified by [enum Parameter]. </description> </method> <method name="set_particle_flag"> @@ -97,6 +104,7 @@ <argument index="1" name="enable" type="bool"> </argument> <description> + Enables or disables the given flag (see [enum Flags] for options). </description> </method> </methods> @@ -162,10 +170,13 @@ Particle draw order. Uses [enum DrawOrder] values. </member> <member name="emission_colors" type="PoolColorArray" setter="set_emission_colors" getter="get_emission_colors"> + Sets the [Color]s to modulate particles by when using [constant EMISSION_SHAPE_POINTS] or [constant EMISSION_SHAPE_DIRECTED_POINTS]. </member> <member name="emission_normals" type="PoolVector2Array" setter="set_emission_normals" getter="get_emission_normals"> + Sets the direction the particles will be emitted in when using [constant EMISSION_SHAPE_DIRECTED_POINTS]. </member> <member name="emission_points" type="PoolVector2Array" setter="set_emission_points" getter="get_emission_points"> + Sets the initial positions to spawn particles when using [constant EMISSION_SHAPE_POINTS] or [constant EMISSION_SHAPE_DIRECTED_POINTS]. </member> <member name="emission_rect_extents" type="Vector2" setter="set_emission_rect_extents" getter="get_emission_rect_extents"> The rectangle's extents if [member emission_shape] is set to [constant EMISSION_SHAPE_RECTANGLE]. @@ -188,8 +199,6 @@ <member name="flag_align_y" type="bool" setter="set_particle_flag" getter="get_particle_flag" default="false"> Align Y axis of particle with the direction of its velocity. </member> - <member name="flatness" type="float" setter="set_flatness" getter="get_flatness" default="0.0"> - </member> <member name="fract_delta" type="bool" setter="set_fractional_delta" getter="get_fractional_delta" default="true"> If [code]true[/code], results in fractional delta calculation which has a smoother particles display effect. </member> @@ -360,5 +369,8 @@ <constant name="EMISSION_SHAPE_DIRECTED_POINTS" value="4" enum="EmissionShape"> Particles will be emitted at a position chosen randomly among [member emission_points]. Particle velocity and rotation will be set based on [member emission_normals]. Particle color will be modulated by [member emission_colors]. </constant> + <constant name="EMISSION_SHAPE_MAX" value="5" enum="EmissionShape"> + Represents the size of the [enum EmissionShape] enum. + </constant> </constants> </class> diff --git a/doc/classes/Camera.xml b/doc/classes/Camera.xml index aca53d4ed0..84f6fa8b8e 100644 --- a/doc/classes/Camera.xml +++ b/doc/classes/Camera.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Camera" inherits="Spatial" category="Core" version="3.2"> +<class name="Camera" inherits="Spatial" version="4.0"> <brief_description> Camera node, displays from a point of view. </brief_description> diff --git a/doc/classes/Camera2D.xml b/doc/classes/Camera2D.xml index b575fa72e0..73892481e6 100644 --- a/doc/classes/Camera2D.xml +++ b/doc/classes/Camera2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Camera2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Camera2D" inherits="Node2D" version="4.0"> <brief_description> Camera node for 2D scenes. </brief_description> diff --git a/doc/classes/CameraFeed.xml b/doc/classes/CameraFeed.xml index f490faf369..14d0559c85 100644 --- a/doc/classes/CameraFeed.xml +++ b/doc/classes/CameraFeed.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CameraFeed" inherits="Reference" category="Core" version="3.2"> +<class name="CameraFeed" inherits="Reference" version="4.0"> <brief_description> A camera feed gives you access to a single physical camera attached to your device. </brief_description> diff --git a/doc/classes/CameraServer.xml b/doc/classes/CameraServer.xml index 850794c1da..82d1faf716 100644 --- a/doc/classes/CameraServer.xml +++ b/doc/classes/CameraServer.xml @@ -1,9 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CameraServer" inherits="Object" category="Core" version="3.2"> +<class name="CameraServer" inherits="Object" version="4.0"> <brief_description> - The CameraServer keeps track of different cameras accessible in Godot. These are external cameras such as webcams or the cameras on your phone. + Server keeping track of different cameras accessible in Godot. </brief_description> <description> + The [CameraServer] keeps track of different cameras accessible in Godot. These are external cameras such as webcams or the cameras on your phone. + It is notably used to provide AR modules with a video feed from the camera. </description> <tutorials> </tutorials> @@ -55,14 +57,14 @@ <argument index="0" name="id" type="int"> </argument> <description> - Emitted when a [CameraFeed] is added (webcam is plugged in). + Emitted when a [CameraFeed] is added (e.g. webcam is plugged in). </description> </signal> <signal name="camera_feed_removed"> <argument index="0" name="id" type="int"> </argument> <description> - Emitted when a [CameraFeed] is removed (webcam is removed). + Emitted when a [CameraFeed] is removed (e.g. webcam is unplugged). </description> </signal> </signals> diff --git a/doc/classes/CameraTexture.xml b/doc/classes/CameraTexture.xml index e2bff76998..d4b7310819 100644 --- a/doc/classes/CameraTexture.xml +++ b/doc/classes/CameraTexture.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CameraTexture" inherits="Texture" category="Core" version="3.2"> +<class name="CameraTexture" inherits="Texture" version="4.0"> <brief_description> - This texture gives access to the camera texture provided by a [CameraFeed]. - [b]Note:[/b] Many cameras supply YCbCr images which need to be converted in a shader. + Texture provided by a [CameraFeed]. </brief_description> <description> + This texture gives access to the camera texture provided by a [CameraFeed]. + [b]Note:[/b] Many cameras supply YCbCr images which need to be converted in a shader. </description> <tutorials> </tutorials> diff --git a/doc/classes/CanvasItem.xml b/doc/classes/CanvasItem.xml index 54d917c931..b8e09708e3 100644 --- a/doc/classes/CanvasItem.xml +++ b/doc/classes/CanvasItem.xml @@ -1,13 +1,13 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CanvasItem" inherits="Node" category="Core" version="3.2"> +<class name="CanvasItem" inherits="Node" version="4.0"> <brief_description> Base class of anything 2D. </brief_description> <description> - Base class of anything 2D. Canvas items are laid out in a tree; children inherit and extend their parent's transform. CanvasItem is extended by [Control] for anything GUI-related, and by [Node2D] for anything related to the 2D engine. - Any CanvasItem can draw. For this, [method update] must be called, then [constant NOTIFICATION_DRAW] will be received on idle time to request redraw. Because of this, canvas items don't need to be redrawn on every frame, improving the performance significantly. Several functions for drawing on the CanvasItem are provided (see [code]draw_*[/code] functions). However, they can only be used inside the [method Object._notification], signal or [method _draw] virtual functions. - Canvas items are drawn in tree order. By default, children are on top of their parents so a root CanvasItem will be drawn behind everything. This behavior can be changed on a per-item basis. - A CanvasItem can also be hidden, which will also hide its children. It provides many ways to change parameters such as modulation (for itself and its children) and self modulation (only for itself), as well as its blend mode. + Base class of anything 2D. Canvas items are laid out in a tree; children inherit and extend their parent's transform. [CanvasItem] is extended by [Control] for anything GUI-related, and by [Node2D] for anything related to the 2D engine. + Any [CanvasItem] can draw. For this, [method update] must be called, then [constant NOTIFICATION_DRAW] will be received on idle time to request redraw. Because of this, canvas items don't need to be redrawn on every frame, improving the performance significantly. Several functions for drawing on the [CanvasItem] are provided (see [code]draw_*[/code] functions). However, they can only be used inside the [method Object._notification], signal or [method _draw] virtual functions. + Canvas items are drawn in tree order. By default, children are on top of their parents so a root [CanvasItem] will be drawn behind everything. This behavior can be changed on a per-item basis. + A [CanvasItem] can also be hidden, which will also hide its children. It provides many ways to change parameters such as modulation (for itself and its children) and self modulation (only for itself), as well as its blend mode. Ultimately, a transform notification can be requested, which will notify the node that its global position changed in case the parent tree changed. </description> <tutorials> @@ -19,7 +19,7 @@ <return type="void"> </return> <description> - Called (if exists) to draw the canvas item. + Overridable function called by the engine (if defined) to draw the canvas item. </description> </method> <method name="draw_arc"> @@ -125,6 +125,7 @@ <argument index="4" name="modulate" type="Color" default="Color( 1, 1, 1, 1 )"> </argument> <description> + Draws a [Mesh] in 2D, using the provided texture. See [MeshInstance2D] for related documentation. </description> </method> <method name="draw_multiline"> @@ -167,6 +168,7 @@ <argument index="2" name="normal_map" type="Texture" default="null"> </argument> <description> + Draws a [MultiMesh] in 2D with the provided texture. See [MultiMeshInstance2D] for related documentation. </description> </method> <method name="draw_polygon"> @@ -385,70 +387,70 @@ <return type="Transform2D"> </return> <description> - Gets the transform matrix of this item's canvas. + Returns the transform matrix of this item's canvas. </description> </method> <method name="get_global_mouse_position" qualifiers="const"> <return type="Vector2"> </return> <description> - Gets the global position of the mouse. + Returns the global position of the mouse. </description> </method> <method name="get_global_transform" qualifiers="const"> <return type="Transform2D"> </return> <description> - Gets the global transform matrix of this item. + Returns the global transform matrix of this item. </description> </method> <method name="get_global_transform_with_canvas" qualifiers="const"> <return type="Transform2D"> </return> <description> - Gets the global transform matrix of this item in relation to the canvas. + Returns the global transform matrix of this item in relation to the canvas. </description> </method> <method name="get_local_mouse_position" qualifiers="const"> <return type="Vector2"> </return> <description> - Gets the mouse position relative to this item's position. + Returns the mouse position relative to this item's position. </description> </method> <method name="get_transform" qualifiers="const"> <return type="Transform2D"> </return> <description> - Gets the transform matrix of this item. + Returns the transform matrix of this item. </description> </method> <method name="get_viewport_rect" qualifiers="const"> <return type="Rect2"> </return> <description> - Gets the viewport's boundaries as a [Rect2]. + Returns the viewport's boundaries as a [Rect2]. </description> </method> <method name="get_viewport_transform" qualifiers="const"> <return type="Transform2D"> </return> <description> - Gets this item's transform in relation to the viewport. + Returns this item's transform in relation to the viewport. </description> </method> <method name="get_world_2d" qualifiers="const"> <return type="World2D"> </return> <description> - Gets the [World2D] where this item is in. + Returns the [World2D] where this item is in. </description> </method> <method name="hide"> <return type="void"> </return> <description> - Hide the CanvasItem if it's currently visible. + Hide the [CanvasItem] if it's currently visible. </description> </method> <method name="is_local_transform_notification_enabled" qualifiers="const"> @@ -528,14 +530,14 @@ <return type="void"> </return> <description> - Show the CanvasItem if it's currently hidden. For controls that inherit [Popup], the correct way to make them visible is to call one of the multiple [code]popup*()[/code] functions instead. + Show the [CanvasItem] if it's currently hidden. For controls that inherit [Popup], the correct way to make them visible is to call one of the multiple [code]popup*()[/code] functions instead. </description> </method> <method name="update"> <return type="void"> </return> <description> - Queue the CanvasItem for update. [constant NOTIFICATION_DRAW] will be called on idle time to request redraw. + Queue the [CanvasItem] for update. [constant NOTIFICATION_DRAW] will be called on idle time to request redraw. </description> </method> </methods> @@ -568,7 +570,7 @@ <signals> <signal name="draw"> <description> - Emitted when the CanvasItem must redraw. This can only be connected realtime, as deferred will not allow drawing. + Emitted when the [CanvasItem] must redraw. This can only be connected realtime, as deferred will not allow drawing. </description> </signal> <signal name="hide"> @@ -607,19 +609,19 @@ Disables blending mode. Colors including alpha are written as-is. Only applicable for render targets with a transparent background. No lighting will be applied. </constant> <constant name="NOTIFICATION_TRANSFORM_CHANGED" value="2000"> - The CanvasItem's transform has changed. This notification is only received if enabled by [method set_notify_transform] or [method set_notify_local_transform]. + The [CanvasItem]'s transform has changed. This notification is only received if enabled by [method set_notify_transform] or [method set_notify_local_transform]. </constant> <constant name="NOTIFICATION_DRAW" value="30"> - The CanvasItem is requested to draw. + The [CanvasItem] is requested to draw. </constant> <constant name="NOTIFICATION_VISIBILITY_CHANGED" value="31"> - The CanvasItem's visibility has changed. + The [CanvasItem]'s visibility has changed. </constant> <constant name="NOTIFICATION_ENTER_CANVAS" value="32"> - The CanvasItem has entered the canvas. + The [CanvasItem] has entered the canvas. </constant> <constant name="NOTIFICATION_EXIT_CANVAS" value="33"> - The CanvasItem has exited the canvas. + The [CanvasItem] has exited the canvas. </constant> </constants> </class> diff --git a/doc/classes/CanvasItemMaterial.xml b/doc/classes/CanvasItemMaterial.xml index 5963e00d9e..1265d2f268 100644 --- a/doc/classes/CanvasItemMaterial.xml +++ b/doc/classes/CanvasItemMaterial.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CanvasItemMaterial" inherits="Material" category="Core" version="3.2"> +<class name="CanvasItemMaterial" inherits="Material" version="4.0"> <brief_description> A material for [CanvasItem]s. </brief_description> @@ -18,12 +18,20 @@ The manner in which material reacts to lighting. </member> <member name="particles_anim_h_frames" type="int" setter="set_particles_anim_h_frames" getter="get_particles_anim_h_frames"> + The number of columns in the spritesheet assigned as [Texture] for a [Particles2D] or [CPUParticles2D]. + [b]Note:[/b] This property is only used and visible in the editor if [member particles_animation] is [code]true[/code]. </member> <member name="particles_anim_loop" type="bool" setter="set_particles_anim_loop" getter="get_particles_anim_loop"> + If [code]true[/code], the particles animation will loop. + [b]Note:[/b] This property is only used and visible in the editor if [member particles_animation] is [code]true[/code]. </member> <member name="particles_anim_v_frames" type="int" setter="set_particles_anim_v_frames" getter="get_particles_anim_v_frames"> + The number of rows in the spritesheet assigned as [Texture] for a [Particles2D] or [CPUParticles2D]. + [b]Note:[/b] This property is only used and visible in the editor if [member particles_animation] is [code]true[/code]. </member> <member name="particles_animation" type="bool" setter="set_particles_animation" getter="get_particles_animation" default="false"> + If [code]true[/code], enable spritesheet-based animation features when assigned to [Particles2D] and [CPUParticles2D] nodes. The [member ParticlesMaterial.anim_speed] or [member CPUParticles2D.anim_speed] should also be set to a positive value for the animation to play. + This property (and other [code]particles_anim_*[/code] properties that depend on it) has no effect on other types of nodes. </member> </members> <constants> diff --git a/doc/classes/CanvasLayer.xml b/doc/classes/CanvasLayer.xml index 2e56009f50..8202a29d44 100644 --- a/doc/classes/CanvasLayer.xml +++ b/doc/classes/CanvasLayer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CanvasLayer" inherits="Node" category="Core" version="3.2"> +<class name="CanvasLayer" inherits="Node" version="4.0"> <brief_description> Canvas drawing layer. </brief_description> @@ -24,8 +24,10 @@ The custom [Viewport] node assigned to the [CanvasLayer]. If [code]null[/code], uses the default viewport instead. </member> <member name="follow_viewport_enable" type="bool" setter="set_follow_viewport" getter="is_following_viewport" default="false"> + Sets the layer to follow the viewport in order to simulate a pseudo 3D effect. </member> <member name="follow_viewport_scale" type="float" setter="set_follow_viewport_scale" getter="get_follow_viewport_scale" default="1.0"> + Scales the layer when using [member follow_viewport_enable]. Layers moving into the foreground should have increasing scales, while layers moving into the background should have decreasing scales. </member> <member name="layer" type="int" setter="set_layer" getter="get_layer" default="1"> Layer index for draw order. Lower values are drawn first. diff --git a/doc/classes/CanvasModulate.xml b/doc/classes/CanvasModulate.xml index 95214b8c6a..19f8912cd8 100644 --- a/doc/classes/CanvasModulate.xml +++ b/doc/classes/CanvasModulate.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CanvasModulate" inherits="Node2D" category="Core" version="3.2"> +<class name="CanvasModulate" inherits="Node2D" version="4.0"> <brief_description> Tint the entire canvas. </brief_description> diff --git a/doc/classes/CapsuleMesh.xml b/doc/classes/CapsuleMesh.xml index 3cdb9b3e22..fab11d44cc 100644 --- a/doc/classes/CapsuleMesh.xml +++ b/doc/classes/CapsuleMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CapsuleMesh" inherits="PrimitiveMesh" category="Core" version="3.2"> +<class name="CapsuleMesh" inherits="PrimitiveMesh" version="4.0"> <brief_description> Class representing a capsule-shaped [PrimitiveMesh]. </brief_description> diff --git a/doc/classes/CapsuleShape.xml b/doc/classes/CapsuleShape.xml index 0b55ca3472..c83e832281 100644 --- a/doc/classes/CapsuleShape.xml +++ b/doc/classes/CapsuleShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CapsuleShape" inherits="Shape" category="Core" version="3.2"> +<class name="CapsuleShape" inherits="Shape" version="4.0"> <brief_description> Capsule shape for collisions. </brief_description> diff --git a/doc/classes/CapsuleShape2D.xml b/doc/classes/CapsuleShape2D.xml index a13abadf36..290d260f0f 100644 --- a/doc/classes/CapsuleShape2D.xml +++ b/doc/classes/CapsuleShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CapsuleShape2D" inherits="Shape2D" category="Core" version="3.2"> +<class name="CapsuleShape2D" inherits="Shape2D" version="4.0"> <brief_description> Capsule shape for 2D collisions. </brief_description> diff --git a/doc/classes/CenterContainer.xml b/doc/classes/CenterContainer.xml index d792b1b180..435f4eb06b 100644 --- a/doc/classes/CenterContainer.xml +++ b/doc/classes/CenterContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CenterContainer" inherits="Container" category="Core" version="3.2"> +<class name="CenterContainer" inherits="Container" version="4.0"> <brief_description> Keeps children controls centered. </brief_description> diff --git a/doc/classes/CharFXTransform.xml b/doc/classes/CharFXTransform.xml index ef9a366c86..c16e448498 100644 --- a/doc/classes/CharFXTransform.xml +++ b/doc/classes/CharFXTransform.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CharFXTransform" inherits="Reference" category="Core" version="3.2"> +<class name="CharFXTransform" inherits="Reference" version="4.0"> <brief_description> Controls how an individual character will be displayed in a [RichTextEffect]. </brief_description> @@ -7,7 +7,7 @@ By setting various properties on this object, you can control how individual characters will be displayed in a [RichTextEffect]. </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/gui/bbcode_in_richtextlabel.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/gui/bbcode_in_richtextlabel.html</link> <link>https://github.com/Eoin-ONeill-Yokai/Godot-Rich-Text-Effect-Test-Project</link> </tutorials> <methods> diff --git a/doc/classes/CheckBox.xml b/doc/classes/CheckBox.xml index 97ef4dbe95..ffcc22703f 100644 --- a/doc/classes/CheckBox.xml +++ b/doc/classes/CheckBox.xml @@ -1,10 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CheckBox" inherits="Button" category="Core" version="3.2"> +<class name="CheckBox" inherits="Button" version="4.0"> <brief_description> - Binary choice user interface widget. + Binary choice user interface widget. See also [CheckButton]. </brief_description> <description> - A checkbox allows the user to make a binary choice (choosing only one of two possible options). + A checkbox allows the user to make a binary choice (choosing only one of two possible options). It's similar to [CheckButton] in functionality, but it has a different apperance. To follow established UX patterns, it's recommended to use CheckBox when toggling it has [b]no[/b] immediate effect on something. For instance, it should be used when toggling it will only do something once a confirmation button is pressed. </description> <tutorials> </tutorials> @@ -18,41 +18,58 @@ </constants> <theme_items> <theme_item name="check_vadjust" type="int" default="0"> - The vertical offset used when rendering the check icons. + The vertical offset used when rendering the check icons (in pixels). </theme_item> <theme_item name="checked" type="Texture"> + The check icon to display when the [CheckBox] is checked. </theme_item> <theme_item name="disabled" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckBox] is disabled. </theme_item> <theme_item name="focus" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckBox] is focused. </theme_item> <theme_item name="font" type="Font"> + The [Font] to use for the [CheckBox] text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> + The [CheckBox] text's font color. </theme_item> <theme_item name="font_color_disabled" type="Color" default="Color( 0.9, 0.9, 0.9, 0.2 )"> + The [CheckBox] text's font color when it's disabled. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 0.94, 0.94, 0.94, 1 )"> + The [CheckBox] text's font color when it's hovered. </theme_item> <theme_item name="font_color_hover_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + The [CheckBox] text's font color when it's hovered and pressed. </theme_item> <theme_item name="font_color_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + The [CheckBox] text's font color when it's pressed. </theme_item> <theme_item name="hover" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckBox] is hovered. </theme_item> <theme_item name="hover_pressed" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckBox] is hovered and pressed. </theme_item> <theme_item name="hseparation" type="int" default="4"> + The separation between the check icon and the text (in pixels). </theme_item> <theme_item name="normal" type="StyleBox"> + The [StyleBox] to display as a background. </theme_item> <theme_item name="pressed" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckBox] is pressed. </theme_item> <theme_item name="radio_checked" type="Texture"> + If the [CheckBox] is configured as a radio button, the icon to display when the [CheckBox] is checked. </theme_item> <theme_item name="radio_unchecked" type="Texture"> + If the [CheckBox] is configured as a radio button, the icon to display when the [CheckBox] is unchecked. </theme_item> <theme_item name="unchecked" type="Texture"> + The check icon to display when the [CheckBox] is unchecked. </theme_item> </theme_items> </class> diff --git a/doc/classes/CheckButton.xml b/doc/classes/CheckButton.xml index 5b867b6a3a..6c024a3753 100644 --- a/doc/classes/CheckButton.xml +++ b/doc/classes/CheckButton.xml @@ -1,10 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CheckButton" inherits="Button" category="Core" version="3.2"> +<class name="CheckButton" inherits="Button" version="4.0"> <brief_description> - Checkable button. + Checkable button. See also [CheckBox]. </brief_description> <description> - CheckButton is a toggle button displayed as a check field. + CheckButton is a toggle button displayed as a check field. It's similar to [CheckBox] in functionality, but it has a different apperance. To follow established UX patterns, it's recommended to use CheckButton when toggling it has an [b]immediate[/b] effect on something. For instance, it should be used if toggling it enables/disables a setting without requiring the user to press a confirmation button. </description> <tutorials> </tutorials> @@ -18,41 +18,58 @@ </constants> <theme_items> <theme_item name="check_vadjust" type="int" default="0"> - The vertical offset used when rendering the icons. + The vertical offset used when rendering the toggle icons (in pixels). </theme_item> <theme_item name="disabled" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckButton] is disabled. </theme_item> <theme_item name="focus" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckButton] is focused. </theme_item> <theme_item name="font" type="Font"> + The [Font] to use for the [CheckButton] text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> + The [CheckButton] text's font color. </theme_item> <theme_item name="font_color_disabled" type="Color" default="Color( 0.9, 0.9, 0.9, 0.2 )"> + The [CheckButton] text's font color when it's disabled. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 0.94, 0.94, 0.94, 1 )"> + The [CheckButton] text's font color when it's hovered. </theme_item> <theme_item name="font_color_hover_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + The [CheckButton] text's font color when it's hovered and pressed. </theme_item> <theme_item name="font_color_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + The [CheckButton] text's font color when it's pressed. </theme_item> <theme_item name="hover" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckButton] is hovered. </theme_item> <theme_item name="hover_pressed" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckButton] is hovered and pressed. </theme_item> <theme_item name="hseparation" type="int" default="4"> + The separation between the toggle icon and the text (in pixels). </theme_item> <theme_item name="normal" type="StyleBox"> + The [StyleBox] to display as a background. </theme_item> <theme_item name="off" type="Texture"> + The icon to display when the [CheckButton] is unchecked. </theme_item> <theme_item name="off_disabled" type="Texture"> + The icon to display when the [CheckButton] is unchecked and disabled. </theme_item> <theme_item name="on" type="Texture"> + The icon to display when the [CheckButton] is checked. </theme_item> <theme_item name="on_disabled" type="Texture"> + The icon to display when the [CheckButton] is checked and disabled. </theme_item> <theme_item name="pressed" type="StyleBox"> + The [StyleBox] to display as a background when the [CheckButton] is pressed. </theme_item> </theme_items> </class> diff --git a/doc/classes/CircleShape2D.xml b/doc/classes/CircleShape2D.xml index 4cff7b5cd4..db889b0f1b 100644 --- a/doc/classes/CircleShape2D.xml +++ b/doc/classes/CircleShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CircleShape2D" inherits="Shape2D" category="Core" version="3.2"> +<class name="CircleShape2D" inherits="Shape2D" version="4.0"> <brief_description> Circular shape for 2D collisions. </brief_description> diff --git a/doc/classes/ClassDB.xml b/doc/classes/ClassDB.xml index fd08643dd5..4d7ccb65e8 100644 --- a/doc/classes/ClassDB.xml +++ b/doc/classes/ClassDB.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ClassDB" inherits="Object" category="Core" version="3.2"> +<class name="ClassDB" inherits="Object" version="4.0"> <brief_description> Class information repository. </brief_description> diff --git a/doc/classes/ClippedCamera.xml b/doc/classes/ClippedCamera.xml index 9eda79bbae..4cdc098c2f 100644 --- a/doc/classes/ClippedCamera.xml +++ b/doc/classes/ClippedCamera.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ClippedCamera" inherits="Camera" category="Core" version="3.2"> +<class name="ClippedCamera" inherits="Camera" version="4.0"> <brief_description> A [Camera] that includes collision. </brief_description> diff --git a/doc/classes/CollisionObject.xml b/doc/classes/CollisionObject.xml index c30aeafcf3..34758d71b2 100644 --- a/doc/classes/CollisionObject.xml +++ b/doc/classes/CollisionObject.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CollisionObject" inherits="Spatial" category="Core" version="3.2"> +<class name="CollisionObject" inherits="Spatial" version="4.0"> <brief_description> Base node for collision objects. </brief_description> diff --git a/doc/classes/CollisionObject2D.xml b/doc/classes/CollisionObject2D.xml index b9ec9480cf..e8f7a59e4c 100644 --- a/doc/classes/CollisionObject2D.xml +++ b/doc/classes/CollisionObject2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CollisionObject2D" inherits="Node2D" category="Core" version="3.2"> +<class name="CollisionObject2D" inherits="Node2D" version="4.0"> <brief_description> Base node for 2D collision objects. </brief_description> @@ -44,6 +44,7 @@ <argument index="0" name="owner_id" type="int"> </argument> <description> + Returns the [code]one_way_collision_margin[/code] of the shape owner identified by given [code]owner_id[/code]. </description> </method> <method name="get_shape_owners"> @@ -199,6 +200,7 @@ <argument index="1" name="margin" type="float"> </argument> <description> + Sets the [code]one_way_collision_margin[/code] of the shape owner identified by given [code]owner_id[/code] to [code]margin[/code] pixels. </description> </method> <method name="shape_owner_set_transform"> diff --git a/doc/classes/CollisionPolygon.xml b/doc/classes/CollisionPolygon.xml index 994f589190..ac519d3817 100644 --- a/doc/classes/CollisionPolygon.xml +++ b/doc/classes/CollisionPolygon.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CollisionPolygon" inherits="Spatial" category="Core" version="3.2"> +<class name="CollisionPolygon" inherits="Spatial" version="4.0"> <brief_description> Editor-only class for defining a collision polygon in 3D space. </brief_description> diff --git a/doc/classes/CollisionPolygon2D.xml b/doc/classes/CollisionPolygon2D.xml index 1d935a3e99..c4fd417918 100644 --- a/doc/classes/CollisionPolygon2D.xml +++ b/doc/classes/CollisionPolygon2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CollisionPolygon2D" inherits="Node2D" category="Core" version="3.2"> +<class name="CollisionPolygon2D" inherits="Node2D" version="4.0"> <brief_description> Defines a 2D collision polygon. </brief_description> diff --git a/doc/classes/CollisionShape.xml b/doc/classes/CollisionShape.xml index c34c0be839..7787bf957d 100644 --- a/doc/classes/CollisionShape.xml +++ b/doc/classes/CollisionShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CollisionShape" inherits="Spatial" category="Core" version="3.2"> +<class name="CollisionShape" inherits="Spatial" version="4.0"> <brief_description> Node that represents collision shape data in 3D space. </brief_description> diff --git a/doc/classes/CollisionShape2D.xml b/doc/classes/CollisionShape2D.xml index 4166ee31d3..4903f0d3a5 100644 --- a/doc/classes/CollisionShape2D.xml +++ b/doc/classes/CollisionShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CollisionShape2D" inherits="Node2D" category="Core" version="3.2"> +<class name="CollisionShape2D" inherits="Node2D" version="4.0"> <brief_description> Node that represents collision shape data in 2D space. </brief_description> diff --git a/doc/classes/Color.xml b/doc/classes/Color.xml index 1d4225542a..0d3f51309b 100644 --- a/doc/classes/Color.xml +++ b/doc/classes/Color.xml @@ -1,11 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Color" category="Built-In Types" version="3.2"> +<class name="Color" version="4.0"> <brief_description> Color in RGBA format with some support for ARGB format. </brief_description> <description> A color is represented by red, green, and blue [code](r, g, b)[/code] components. Additionally, [code]a[/code] represents the alpha component, often used for transparency. Values are in floating-point and usually range from 0 to 1. Some properties (such as [member CanvasItem.modulate]) may accept values greater than 1. - You can also create a color from standardized color names by using [method @GDScript.ColorN]. + You can also create a color from standardized color names by using [method @GDScript.ColorN] or directly using the color constants defined here. The standardized color set is based on the [url=https://en.wikipedia.org/wiki/X11_color_names]X11 color names[/url]. </description> <tutorials> </tutorials> @@ -18,11 +18,11 @@ <description> Constructs a color from an HTML hexadecimal color string in ARGB or RGB format. See also [method @GDScript.ColorN]. [codeblock] - # Each of the following creates the same color RGBA(178, 217, 10, 255) - var c1 = Color("#ffb2d90a") # ARGB format with "#" - var c2 = Color("ffb2d90a") # ARGB format - var c3 = Color("#b2d90a") # RGB format with "#" - var c4 = Color("b2d90a") # RGB format + # Each of the following creates the same color RGBA(178, 217, 10, 255). + var c1 = Color("#ffb2d90a") # ARGB format with "#". + var c2 = Color("ffb2d90a") # ARGB format. + var c3 = Color("#b2d90a") # RGB format with "#". + var c4 = Color("b2d90a") # RGB format. [/codeblock] </description> </method> @@ -308,296 +308,442 @@ </members> <constants> <constant name="gray" value="Color( 0.75, 0.75, 0.75, 1 )"> + Gray color. </constant> <constant name="aliceblue" value="Color( 0.94, 0.97, 1, 1 )"> + Alice blue color. </constant> <constant name="antiquewhite" value="Color( 0.98, 0.92, 0.84, 1 )"> + Antique white color. </constant> <constant name="aqua" value="Color( 0, 1, 1, 1 )"> + Aqua color. </constant> <constant name="aquamarine" value="Color( 0.5, 1, 0.83, 1 )"> + Aquamarine color. </constant> <constant name="azure" value="Color( 0.94, 1, 1, 1 )"> + Azure color. </constant> <constant name="beige" value="Color( 0.96, 0.96, 0.86, 1 )"> + Beige color. </constant> <constant name="bisque" value="Color( 1, 0.89, 0.77, 1 )"> + Bisque color. </constant> <constant name="black" value="Color( 0, 0, 0, 1 )"> + Black color. </constant> <constant name="blanchedalmond" value="Color( 1, 0.92, 0.8, 1 )"> + Blanche almond color. </constant> <constant name="blue" value="Color( 0, 0, 1, 1 )"> + Blue color. </constant> <constant name="blueviolet" value="Color( 0.54, 0.17, 0.89, 1 )"> + Blue violet color. </constant> <constant name="brown" value="Color( 0.65, 0.16, 0.16, 1 )"> + Brown color. </constant> <constant name="burlywood" value="Color( 0.87, 0.72, 0.53, 1 )"> + Burly wood color. </constant> <constant name="cadetblue" value="Color( 0.37, 0.62, 0.63, 1 )"> + Cadet blue color. </constant> <constant name="chartreuse" value="Color( 0.5, 1, 0, 1 )"> + Chartreuse color. </constant> <constant name="chocolate" value="Color( 0.82, 0.41, 0.12, 1 )"> + Chocolate color. </constant> <constant name="coral" value="Color( 1, 0.5, 0.31, 1 )"> + Coral color. </constant> <constant name="cornflower" value="Color( 0.39, 0.58, 0.93, 1 )"> + Cornflower color. </constant> <constant name="cornsilk" value="Color( 1, 0.97, 0.86, 1 )"> + Corn silk color. </constant> <constant name="crimson" value="Color( 0.86, 0.08, 0.24, 1 )"> + Crimson color. </constant> <constant name="cyan" value="Color( 0, 1, 1, 1 )"> + Cyan color. </constant> <constant name="darkblue" value="Color( 0, 0, 0.55, 1 )"> + Dark blue color. </constant> <constant name="darkcyan" value="Color( 0, 0.55, 0.55, 1 )"> + Dark cyan color. </constant> <constant name="darkgoldenrod" value="Color( 0.72, 0.53, 0.04, 1 )"> + Dark goldenrod color. </constant> <constant name="darkgray" value="Color( 0.66, 0.66, 0.66, 1 )"> + Dark gray color. </constant> <constant name="darkgreen" value="Color( 0, 0.39, 0, 1 )"> + Dark green color. </constant> <constant name="darkkhaki" value="Color( 0.74, 0.72, 0.42, 1 )"> + Dark khaki color. </constant> <constant name="darkmagenta" value="Color( 0.55, 0, 0.55, 1 )"> + Dark magenta color. </constant> <constant name="darkolivegreen" value="Color( 0.33, 0.42, 0.18, 1 )"> + Dark olive green color. </constant> <constant name="darkorange" value="Color( 1, 0.55, 0, 1 )"> + Dark orange color. </constant> <constant name="darkorchid" value="Color( 0.6, 0.2, 0.8, 1 )"> + Dark orchid color. </constant> <constant name="darkred" value="Color( 0.55, 0, 0, 1 )"> + Dark red color. </constant> <constant name="darksalmon" value="Color( 0.91, 0.59, 0.48, 1 )"> + Dark salmon color. </constant> <constant name="darkseagreen" value="Color( 0.56, 0.74, 0.56, 1 )"> + Dark sea green color. </constant> <constant name="darkslateblue" value="Color( 0.28, 0.24, 0.55, 1 )"> + Dark slate blue color. </constant> <constant name="darkslategray" value="Color( 0.18, 0.31, 0.31, 1 )"> + Dark slate gray color. </constant> <constant name="darkturquoise" value="Color( 0, 0.81, 0.82, 1 )"> + Dark turquoise color. </constant> <constant name="darkviolet" value="Color( 0.58, 0, 0.83, 1 )"> + Dark violet color. </constant> <constant name="deeppink" value="Color( 1, 0.08, 0.58, 1 )"> + Deep pink color. </constant> <constant name="deepskyblue" value="Color( 0, 0.75, 1, 1 )"> + Deep sky blue color. </constant> <constant name="dimgray" value="Color( 0.41, 0.41, 0.41, 1 )"> + Dim gray color. </constant> <constant name="dodgerblue" value="Color( 0.12, 0.56, 1, 1 )"> + Dodger blue color. </constant> <constant name="firebrick" value="Color( 0.7, 0.13, 0.13, 1 )"> + Firebrick color. </constant> <constant name="floralwhite" value="Color( 1, 0.98, 0.94, 1 )"> + Floral white color. </constant> <constant name="forestgreen" value="Color( 0.13, 0.55, 0.13, 1 )"> + Forest green color. </constant> <constant name="fuchsia" value="Color( 1, 0, 1, 1 )"> + Fuchsia color. </constant> <constant name="gainsboro" value="Color( 0.86, 0.86, 0.86, 1 )"> + Gainsboro color. </constant> <constant name="ghostwhite" value="Color( 0.97, 0.97, 1, 1 )"> + Ghost white color. </constant> <constant name="gold" value="Color( 1, 0.84, 0, 1 )"> + Gold color. </constant> <constant name="goldenrod" value="Color( 0.85, 0.65, 0.13, 1 )"> + Goldenrod color. </constant> <constant name="green" value="Color( 0, 1, 0, 1 )"> + Green color. </constant> <constant name="greenyellow" value="Color( 0.68, 1, 0.18, 1 )"> + Green yellow color. </constant> <constant name="honeydew" value="Color( 0.94, 1, 0.94, 1 )"> + Honeydew color. </constant> <constant name="hotpink" value="Color( 1, 0.41, 0.71, 1 )"> + Hot pink color. </constant> <constant name="indianred" value="Color( 0.8, 0.36, 0.36, 1 )"> + Indian red color. </constant> <constant name="indigo" value="Color( 0.29, 0, 0.51, 1 )"> + Indigo color. </constant> <constant name="ivory" value="Color( 1, 1, 0.94, 1 )"> + Ivory color. </constant> <constant name="khaki" value="Color( 0.94, 0.9, 0.55, 1 )"> + Khaki color. </constant> <constant name="lavender" value="Color( 0.9, 0.9, 0.98, 1 )"> + Lavender color. </constant> <constant name="lavenderblush" value="Color( 1, 0.94, 0.96, 1 )"> + Lavender blush color. </constant> <constant name="lawngreen" value="Color( 0.49, 0.99, 0, 1 )"> + Lawn green color. </constant> <constant name="lemonchiffon" value="Color( 1, 0.98, 0.8, 1 )"> + Lemon chiffon color. </constant> <constant name="lightblue" value="Color( 0.68, 0.85, 0.9, 1 )"> + Light blue color. </constant> <constant name="lightcoral" value="Color( 0.94, 0.5, 0.5, 1 )"> + Light coral color. </constant> <constant name="lightcyan" value="Color( 0.88, 1, 1, 1 )"> + Light cyan color. </constant> <constant name="lightgoldenrod" value="Color( 0.98, 0.98, 0.82, 1 )"> + Light goldenrod color. </constant> <constant name="lightgray" value="Color( 0.83, 0.83, 0.83, 1 )"> + Light gray color. </constant> <constant name="lightgreen" value="Color( 0.56, 0.93, 0.56, 1 )"> + Light green color. </constant> <constant name="lightpink" value="Color( 1, 0.71, 0.76, 1 )"> + Light pink color. </constant> <constant name="lightsalmon" value="Color( 1, 0.63, 0.48, 1 )"> + Light salmon color. </constant> <constant name="lightseagreen" value="Color( 0.13, 0.7, 0.67, 1 )"> + Light sea green color. </constant> <constant name="lightskyblue" value="Color( 0.53, 0.81, 0.98, 1 )"> + Light sky blue color. </constant> <constant name="lightslategray" value="Color( 0.47, 0.53, 0.6, 1 )"> + Light slate gray color. </constant> <constant name="lightsteelblue" value="Color( 0.69, 0.77, 0.87, 1 )"> + Light steel blue color. </constant> <constant name="lightyellow" value="Color( 1, 1, 0.88, 1 )"> + Light yellow color. </constant> <constant name="lime" value="Color( 0, 1, 0, 1 )"> + Lime color. </constant> <constant name="limegreen" value="Color( 0.2, 0.8, 0.2, 1 )"> + Lime green color. </constant> <constant name="linen" value="Color( 0.98, 0.94, 0.9, 1 )"> + Linen color. </constant> <constant name="magenta" value="Color( 1, 0, 1, 1 )"> + Magenta color. </constant> <constant name="maroon" value="Color( 0.69, 0.19, 0.38, 1 )"> + Maroon color. </constant> <constant name="mediumaquamarine" value="Color( 0.4, 0.8, 0.67, 1 )"> + Medium aquamarine color. </constant> <constant name="mediumblue" value="Color( 0, 0, 0.8, 1 )"> + Medium blue color. </constant> <constant name="mediumorchid" value="Color( 0.73, 0.33, 0.83, 1 )"> + Medium orchid color. </constant> <constant name="mediumpurple" value="Color( 0.58, 0.44, 0.86, 1 )"> + Medium purple color. </constant> <constant name="mediumseagreen" value="Color( 0.24, 0.7, 0.44, 1 )"> + Medium sea green color. </constant> <constant name="mediumslateblue" value="Color( 0.48, 0.41, 0.93, 1 )"> + Medium slate blue color. </constant> <constant name="mediumspringgreen" value="Color( 0, 0.98, 0.6, 1 )"> + Medium spring green color. </constant> <constant name="mediumturquoise" value="Color( 0.28, 0.82, 0.8, 1 )"> + Medium turquoise color. </constant> <constant name="mediumvioletred" value="Color( 0.78, 0.08, 0.52, 1 )"> + Medium violet red color. </constant> <constant name="midnightblue" value="Color( 0.1, 0.1, 0.44, 1 )"> + Midnight blue color. </constant> <constant name="mintcream" value="Color( 0.96, 1, 0.98, 1 )"> + Mint cream color. </constant> <constant name="mistyrose" value="Color( 1, 0.89, 0.88, 1 )"> + Misty rose color. </constant> <constant name="moccasin" value="Color( 1, 0.89, 0.71, 1 )"> + Moccasin color. </constant> <constant name="navajowhite" value="Color( 1, 0.87, 0.68, 1 )"> + Navajo white color. </constant> <constant name="navyblue" value="Color( 0, 0, 0.5, 1 )"> + Navy blue color. </constant> <constant name="oldlace" value="Color( 0.99, 0.96, 0.9, 1 )"> + Old lace color. </constant> <constant name="olive" value="Color( 0.5, 0.5, 0, 1 )"> + Olive color. </constant> <constant name="olivedrab" value="Color( 0.42, 0.56, 0.14, 1 )"> + Olive drab color. </constant> <constant name="orange" value="Color( 1, 0.65, 0, 1 )"> + Orange color. </constant> <constant name="orangered" value="Color( 1, 0.27, 0, 1 )"> + Orange red color. </constant> <constant name="orchid" value="Color( 0.85, 0.44, 0.84, 1 )"> + Orchid color. </constant> <constant name="palegoldenrod" value="Color( 0.93, 0.91, 0.67, 1 )"> + Pale goldenrod color. </constant> <constant name="palegreen" value="Color( 0.6, 0.98, 0.6, 1 )"> + Pale green color. </constant> <constant name="paleturquoise" value="Color( 0.69, 0.93, 0.93, 1 )"> + Pale turquoise color. </constant> <constant name="palevioletred" value="Color( 0.86, 0.44, 0.58, 1 )"> + Pale violet red color. </constant> <constant name="papayawhip" value="Color( 1, 0.94, 0.84, 1 )"> + Papaya whip color. </constant> <constant name="peachpuff" value="Color( 1, 0.85, 0.73, 1 )"> + Peach puff color. </constant> <constant name="peru" value="Color( 0.8, 0.52, 0.25, 1 )"> + Peru color. </constant> <constant name="pink" value="Color( 1, 0.75, 0.8, 1 )"> + Pink color. </constant> <constant name="plum" value="Color( 0.87, 0.63, 0.87, 1 )"> + Plum color. </constant> <constant name="powderblue" value="Color( 0.69, 0.88, 0.9, 1 )"> + Powder blue color. </constant> <constant name="purple" value="Color( 0.63, 0.13, 0.94, 1 )"> + Purple color. </constant> <constant name="rebeccapurple" value="Color( 0.4, 0.2, 0.6, 1 )"> + Rebecca purple color. </constant> <constant name="red" value="Color( 1, 0, 0, 1 )"> + Red color. </constant> <constant name="rosybrown" value="Color( 0.74, 0.56, 0.56, 1 )"> + Rosy brown color. </constant> <constant name="royalblue" value="Color( 0.25, 0.41, 0.88, 1 )"> + Royal blue color. </constant> <constant name="saddlebrown" value="Color( 0.55, 0.27, 0.07, 1 )"> + Saddle brown color. </constant> <constant name="salmon" value="Color( 0.98, 0.5, 0.45, 1 )"> + Salmon color. </constant> <constant name="sandybrown" value="Color( 0.96, 0.64, 0.38, 1 )"> + Sandy brown color. </constant> <constant name="seagreen" value="Color( 0.18, 0.55, 0.34, 1 )"> + Sea green color. </constant> <constant name="seashell" value="Color( 1, 0.96, 0.93, 1 )"> + Seashell color. </constant> <constant name="sienna" value="Color( 0.63, 0.32, 0.18, 1 )"> + Sienna color. </constant> <constant name="silver" value="Color( 0.75, 0.75, 0.75, 1 )"> + Silver color. </constant> <constant name="skyblue" value="Color( 0.53, 0.81, 0.92, 1 )"> + Sky blue color. </constant> <constant name="slateblue" value="Color( 0.42, 0.35, 0.8, 1 )"> + Slate blue color. </constant> <constant name="slategray" value="Color( 0.44, 0.5, 0.56, 1 )"> + Slate gray color. </constant> <constant name="snow" value="Color( 1, 0.98, 0.98, 1 )"> + Snow color. </constant> <constant name="springgreen" value="Color( 0, 1, 0.5, 1 )"> + Spring green color. </constant> <constant name="steelblue" value="Color( 0.27, 0.51, 0.71, 1 )"> + Steel blue color. </constant> <constant name="tan" value="Color( 0.82, 0.71, 0.55, 1 )"> + Tan color. </constant> <constant name="teal" value="Color( 0, 0.5, 0.5, 1 )"> + Teal color. </constant> <constant name="thistle" value="Color( 0.85, 0.75, 0.85, 1 )"> + Thistle color. </constant> <constant name="tomato" value="Color( 1, 0.39, 0.28, 1 )"> + Tomato color. </constant> <constant name="transparent" value="Color( 1, 1, 1, 0 )"> + Transparent color (white with no alpha). </constant> <constant name="turquoise" value="Color( 0.25, 0.88, 0.82, 1 )"> + Turquoise color. </constant> <constant name="violet" value="Color( 0.93, 0.51, 0.93, 1 )"> + Violet color. </constant> <constant name="webgray" value="Color( 0.5, 0.5, 0.5, 1 )"> + Web gray color. </constant> <constant name="webgreen" value="Color( 0, 0.5, 0, 1 )"> + Web green color. </constant> <constant name="webmaroon" value="Color( 0.5, 0, 0, 1 )"> + Web maroon color. </constant> <constant name="webpurple" value="Color( 0.5, 0, 0.5, 1 )"> + Web purple color. </constant> <constant name="wheat" value="Color( 0.96, 0.87, 0.7, 1 )"> + Wheat color. </constant> <constant name="white" value="Color( 1, 1, 1, 1 )"> + White color. </constant> <constant name="whitesmoke" value="Color( 0.96, 0.96, 0.96, 1 )"> + White smoke color. </constant> <constant name="yellow" value="Color( 1, 1, 0, 1 )"> + Yellow color. </constant> <constant name="yellowgreen" value="Color( 0.6, 0.8, 0.2, 1 )"> + Yellow green color. </constant> </constants> </class> diff --git a/doc/classes/ColorPicker.xml b/doc/classes/ColorPicker.xml index 07ce76fdb2..d315c6a387 100644 --- a/doc/classes/ColorPicker.xml +++ b/doc/classes/ColorPicker.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ColorPicker" inherits="BoxContainer" category="Core" version="3.2"> +<class name="ColorPicker" inherits="BoxContainer" version="4.0"> <brief_description> Color picker control. </brief_description> diff --git a/doc/classes/ColorPickerButton.xml b/doc/classes/ColorPickerButton.xml index e8c78fb6bf..d9023a4f3a 100644 --- a/doc/classes/ColorPickerButton.xml +++ b/doc/classes/ColorPickerButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ColorPickerButton" inherits="Button" category="Core" version="3.2"> +<class name="ColorPickerButton" inherits="Button" version="4.0"> <brief_description> Button that pops out a [ColorPicker]. </brief_description> @@ -43,10 +43,12 @@ </signal> <signal name="picker_created"> <description> + Emitted when the [ColorPicker] is created (the button is pressed for the first time). </description> </signal> <signal name="popup_closed"> <description> + Emitted when the [ColorPicker] is closed. </description> </signal> </signals> @@ -54,28 +56,40 @@ </constants> <theme_items> <theme_item name="bg" type="Texture"> + The background of the color preview rect on the button. </theme_item> <theme_item name="disabled" type="StyleBox"> + [StyleBox] used when the [ColorPickerButton] is disabled. </theme_item> <theme_item name="focus" type="StyleBox"> + [StyleBox] used when the [ColorPickerButton] is focused. It is displayed over the current [StyleBox], so using [StyleBoxEmpty] will just disable the focus visual effect. </theme_item> <theme_item name="font" type="Font"> + [Font] of the [ColorPickerButton]'s text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 1, 1, 1, 1 )"> + Default text [Color] of the [ColorPickerButton]. </theme_item> <theme_item name="font_color_disabled" type="Color" default="Color( 0.9, 0.9, 0.9, 0.3 )"> + Text [Color] used when the [ColorPickerButton] is disabled. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 1, 1, 1, 1 )"> + Text [Color] used when the [ColorPickerButton] is being hovered. </theme_item> <theme_item name="font_color_pressed" type="Color" default="Color( 0.8, 0.8, 0.8, 1 )"> + Text [Color] used when the [ColorPickerButton] is being pressed. </theme_item> <theme_item name="hover" type="StyleBox"> + [StyleBox] used when the [ColorPickerButton] is being hovered. </theme_item> <theme_item name="hseparation" type="int" default="2"> + The horizontal space between [ColorPickerButton]'s icon and text. </theme_item> <theme_item name="normal" type="StyleBox"> + Default [StyleBox] for the [ColorPickerButton]. </theme_item> <theme_item name="pressed" type="StyleBox"> + [StyleBox] used when the [ColorPickerButton] is being pressed. </theme_item> </theme_items> </class> diff --git a/doc/classes/ColorRect.xml b/doc/classes/ColorRect.xml index 2ff0a7eee3..92f42b6dd3 100644 --- a/doc/classes/ColorRect.xml +++ b/doc/classes/ColorRect.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ColorRect" inherits="Control" category="Core" version="3.2"> +<class name="ColorRect" inherits="Control" version="4.0"> <brief_description> Colored rectangle. </brief_description> diff --git a/doc/classes/ConcavePolygonShape.xml b/doc/classes/ConcavePolygonShape.xml index a09b5005b9..3ae07ee52f 100644 --- a/doc/classes/ConcavePolygonShape.xml +++ b/doc/classes/ConcavePolygonShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ConcavePolygonShape" inherits="Shape" category="Core" version="3.2"> +<class name="ConcavePolygonShape" inherits="Shape" version="4.0"> <brief_description> Concave polygon shape. </brief_description> diff --git a/doc/classes/ConcavePolygonShape2D.xml b/doc/classes/ConcavePolygonShape2D.xml index a6fe2486ea..6fb32436a8 100644 --- a/doc/classes/ConcavePolygonShape2D.xml +++ b/doc/classes/ConcavePolygonShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ConcavePolygonShape2D" inherits="Shape2D" category="Core" version="3.2"> +<class name="ConcavePolygonShape2D" inherits="Shape2D" version="4.0"> <brief_description> Concave polygon 2D shape resource for physics. </brief_description> diff --git a/doc/classes/ConeTwistJoint.xml b/doc/classes/ConeTwistJoint.xml index 4c95a4bef9..8682391a73 100644 --- a/doc/classes/ConeTwistJoint.xml +++ b/doc/classes/ConeTwistJoint.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ConeTwistJoint" inherits="Joint" category="Core" version="3.2"> +<class name="ConeTwistJoint" inherits="Joint" version="4.0"> <brief_description> A twist joint between two 3D bodies. </brief_description> diff --git a/doc/classes/ConfigFile.xml b/doc/classes/ConfigFile.xml index d99f90d09a..7eaa815a87 100644 --- a/doc/classes/ConfigFile.xml +++ b/doc/classes/ConfigFile.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ConfigFile" inherits="Reference" category="Core" version="3.2"> +<class name="ConfigFile" inherits="Reference" version="4.0"> <brief_description> Helper class to handle INI-style files. </brief_description> @@ -26,6 +26,7 @@ config.save("user://settings.cfg") [/codeblock] Keep in mind that section and property names can't contain spaces. Anything after a space will be ignored on save and on load. + ConfigFiles can also contain manually written comment lines starting with a semicolon ([code];[/code]). Those lines will be ignored when parsing the file. Note that comments will be lost when saving the ConfigFile. This can still be useful for dedicated server configuration files, which are typically never overwritten without explicit user action. </description> <tutorials> </tutorials> diff --git a/doc/classes/ConfirmationDialog.xml b/doc/classes/ConfirmationDialog.xml index 01a2eebce5..801d9508dd 100644 --- a/doc/classes/ConfirmationDialog.xml +++ b/doc/classes/ConfirmationDialog.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ConfirmationDialog" inherits="AcceptDialog" category="Core" version="3.2"> +<class name="ConfirmationDialog" inherits="AcceptDialog" version="4.0"> <brief_description> Dialog for confirmation of actions. </brief_description> diff --git a/doc/classes/Container.xml b/doc/classes/Container.xml index 8a3aac88b5..4593e00e05 100644 --- a/doc/classes/Container.xml +++ b/doc/classes/Container.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Container" inherits="Control" category="Core" version="3.2"> +<class name="Container" inherits="Control" version="4.0"> <brief_description> Base node for containers. </brief_description> diff --git a/doc/classes/Control.xml b/doc/classes/Control.xml index d309015453..556ebb93bf 100644 --- a/doc/classes/Control.xml +++ b/doc/classes/Control.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Control" inherits="CanvasItem" category="Core" version="3.2"> +<class name="Control" inherits="CanvasItem" version="4.0"> <brief_description> All user interface nodes inherit from Control. A control's anchors and margins adapt its position and size relative to its parent. </brief_description> diff --git a/doc/classes/ConvexPolygonShape.xml b/doc/classes/ConvexPolygonShape.xml index d15a0a7336..544f304051 100644 --- a/doc/classes/ConvexPolygonShape.xml +++ b/doc/classes/ConvexPolygonShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ConvexPolygonShape" inherits="Shape" category="Core" version="3.2"> +<class name="ConvexPolygonShape" inherits="Shape" version="4.0"> <brief_description> Convex polygon shape for 3D physics. </brief_description> diff --git a/doc/classes/ConvexPolygonShape2D.xml b/doc/classes/ConvexPolygonShape2D.xml index 050ca23e05..e17048e061 100644 --- a/doc/classes/ConvexPolygonShape2D.xml +++ b/doc/classes/ConvexPolygonShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ConvexPolygonShape2D" inherits="Shape2D" category="Core" version="3.2"> +<class name="ConvexPolygonShape2D" inherits="Shape2D" version="4.0"> <brief_description> Convex polygon shape for 2D physics. </brief_description> diff --git a/doc/classes/Crypto.xml b/doc/classes/Crypto.xml index bce7895973..fb373145f9 100644 --- a/doc/classes/Crypto.xml +++ b/doc/classes/Crypto.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Crypto" inherits="Reference" category="Core" version="3.2"> +<class name="Crypto" inherits="Reference" version="4.0"> <brief_description> Access to advanced cryptographic functionalities. </brief_description> @@ -22,6 +22,7 @@ key.save("user://generated.key") cert.save("user://generated.crt") [/codeblock] + [b]Note:[/b] Not available in HTML5 exports. </description> <tutorials> </tutorials> diff --git a/doc/classes/CryptoKey.xml b/doc/classes/CryptoKey.xml index 8c825c9e1c..fe7f4b63f0 100644 --- a/doc/classes/CryptoKey.xml +++ b/doc/classes/CryptoKey.xml @@ -1,11 +1,12 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CryptoKey" inherits="Resource" category="Core" version="3.2"> +<class name="CryptoKey" inherits="Resource" version="4.0"> <brief_description> A cryptographic key (RSA). </brief_description> <description> The CryptoKey class represents a cryptographic key. Keys can be loaded and saved like any other [Resource]. They can be used to generate a self-signed [X509Certificate] via [method Crypto.generate_self_signed_certificate] and as private key in [method StreamPeerSSL.accept_stream] along with the appropriate certificate. + [b]Note:[/b] Not available in HTML5 exports. </description> <tutorials> </tutorials> diff --git a/doc/classes/CubeMap.xml b/doc/classes/CubeMap.xml index 6db1cf2d64..78731a7cd0 100644 --- a/doc/classes/CubeMap.xml +++ b/doc/classes/CubeMap.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CubeMap" inherits="Resource" category="Core" version="3.2"> +<class name="CubeMap" inherits="Resource" version="4.0"> <brief_description> A CubeMap is a 6-sided 3D texture. </brief_description> diff --git a/doc/classes/CubeMesh.xml b/doc/classes/CubeMesh.xml index 67e559ab07..1f64b4a21f 100644 --- a/doc/classes/CubeMesh.xml +++ b/doc/classes/CubeMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CubeMesh" inherits="PrimitiveMesh" category="Core" version="3.2"> +<class name="CubeMesh" inherits="PrimitiveMesh" version="4.0"> <brief_description> Generate an axis-aligned cuboid [PrimitiveMesh]. </brief_description> diff --git a/doc/classes/Curve.xml b/doc/classes/Curve.xml index 0fb559296e..26872e1f8e 100644 --- a/doc/classes/Curve.xml +++ b/doc/classes/Curve.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Curve" inherits="Resource" category="Core" version="3.2"> +<class name="Curve" inherits="Resource" version="4.0"> <brief_description> A mathematic curve. </brief_description> diff --git a/doc/classes/Curve2D.xml b/doc/classes/Curve2D.xml index 4e449a2032..f6eacfb33b 100644 --- a/doc/classes/Curve2D.xml +++ b/doc/classes/Curve2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Curve2D" inherits="Resource" category="Core" version="3.2"> +<class name="Curve2D" inherits="Resource" version="4.0"> <brief_description> Describes a Bézier curve in 2D space. </brief_description> diff --git a/doc/classes/Curve3D.xml b/doc/classes/Curve3D.xml index 4a0873a986..52b0052908 100644 --- a/doc/classes/Curve3D.xml +++ b/doc/classes/Curve3D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Curve3D" inherits="Resource" category="Core" version="3.2"> +<class name="Curve3D" inherits="Resource" version="4.0"> <brief_description> Describes a Bézier curve in 3D space. </brief_description> diff --git a/doc/classes/CurveTexture.xml b/doc/classes/CurveTexture.xml index e8df560a4c..10c7a4a086 100644 --- a/doc/classes/CurveTexture.xml +++ b/doc/classes/CurveTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CurveTexture" inherits="Texture" category="Core" version="3.2"> +<class name="CurveTexture" inherits="Texture" version="4.0"> <brief_description> A texture that shows a curve. </brief_description> diff --git a/doc/classes/CylinderMesh.xml b/doc/classes/CylinderMesh.xml index 8e9397791a..3a81e98c3a 100644 --- a/doc/classes/CylinderMesh.xml +++ b/doc/classes/CylinderMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CylinderMesh" inherits="PrimitiveMesh" category="Core" version="3.2"> +<class name="CylinderMesh" inherits="PrimitiveMesh" version="4.0"> <brief_description> Class representing a cylindrical [PrimitiveMesh]. </brief_description> diff --git a/doc/classes/CylinderShape.xml b/doc/classes/CylinderShape.xml index 5dff156775..54adbd3b04 100644 --- a/doc/classes/CylinderShape.xml +++ b/doc/classes/CylinderShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CylinderShape" inherits="Shape" category="Core" version="3.2"> +<class name="CylinderShape" inherits="Shape" version="4.0"> <brief_description> Cylinder shape for collisions. </brief_description> diff --git a/doc/classes/DampedSpringJoint2D.xml b/doc/classes/DampedSpringJoint2D.xml index 270d948f5e..e1b6bb6866 100644 --- a/doc/classes/DampedSpringJoint2D.xml +++ b/doc/classes/DampedSpringJoint2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="DampedSpringJoint2D" inherits="Joint2D" category="Core" version="3.2"> +<class name="DampedSpringJoint2D" inherits="Joint2D" version="4.0"> <brief_description> Damped spring constraint for 2D physics. </brief_description> diff --git a/doc/classes/Dictionary.xml b/doc/classes/Dictionary.xml index 7cb6b1b754..8432744ea7 100644 --- a/doc/classes/Dictionary.xml +++ b/doc/classes/Dictionary.xml @@ -1,19 +1,64 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Dictionary" category="Built-In Types" version="3.2"> +<class name="Dictionary" version="4.0"> <brief_description> Dictionary type. </brief_description> <description> - Dictionary type. Associative container which contains values referenced by unique keys. Dictionaries are always passed by reference. + Dictionary type. Associative container which contains values referenced by unique keys. Dictionary are composed of pairs of keys (which must be unique) and values. You can define a dictionary by placing a comma separated list of [code]key: value[/code] pairs in curly braces [code]{}[/code]. Erasing elements while iterating over them [b]is not supported[/b]. Creating a dictionary: [codeblock] - var d = {4: 5, "A key": "A value", 28: [1, 2, 3]} + var my_dir = {} # Creates an empty dictionary. + var points_dir = {"White": 50, "Yellow": 75, "Orange": 100} + var my_dir = { + key1: value1, + key2: value2, + key3: value3, + } + [/codeblock] + You can access values of a dictionary by referencing appropriate key in above example [code]points_dir["White"][/code] would return value of 50. + [codeblock] + export(String, "White", "Yellow", "Orange") var my_color + var points_dir = {"White": 50, "Yellow": 75, "Orange": 100} + + func _ready(): + var points = points_dir[my_color] + [/codeblock] + In the above code [code]points[/code] will be assigned the value that is paired with the appropriate color selected in [code]my_color[/code]. + Dictionaries can contain more complex data: + [codeblock] + my_dir = {"First Array": [1, 2, 3, 4]} # Assigns an Array to a String key. [/codeblock] To add a key to an existing dictionary, access it like an existing key and assign to it: [codeblock] - d[4] = "hello" # Add integer 4 as a key and assign the String "hello" as its value. - d["Godot"] = 3.01 # Add String "Godot" as a key and assign the value 3.01 to it. + var points_dir = {"White": 50, "Yellow": 75, "Orange": 100} + var points_dir["Blue"] = 150 # Add "Blue" as a key and assign 150 as its value. + [/codeblock] + Finally, dictionaries can contain different types of keys and values in the same dictionary: + [codeblock] + var my_dir = {"String Key": 5, 4: [1, 2, 3], 7: "Hello"} # This is a valid dictionary. + [/codeblock] + [b]Note:[/b] Unlike [Array]s you can't compare dictionaries directly: + [codeblock] + array1 = [1, 2, 3] + array2 = [1, 2, 3] + + func compare_arrays(): + print(array1 == array2) # Will print true. + + dir1 = {"a": 1, "b": 2, "c": 3} + dir2 = {"a": 1, "b": 2, "c": 3} + + func compare_dictionaries(): + print(dir1 == dir2) # Will NOT print true. + [/codeblock] + You need to first calculate the dictionary's hash with [method hash] before you can compare them: + [codeblock] + dir1 = {"a": 1, "b": 2, "c": 3} + dir2 = {"a": 1, "b": 2, "c": 3} + + func compare_dictionaries(): + print(dir1.hash() == dir2.hash()) # Will print true. [/codeblock] </description> <tutorials> diff --git a/doc/classes/DirectionalLight.xml b/doc/classes/DirectionalLight.xml index 502256ae63..8dddf921d3 100644 --- a/doc/classes/DirectionalLight.xml +++ b/doc/classes/DirectionalLight.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="DirectionalLight" inherits="Light" category="Core" version="3.2"> +<class name="DirectionalLight" inherits="Light" version="4.0"> <brief_description> Directional light from a distance, as from the Sun. </brief_description> diff --git a/doc/classes/Directory.xml b/doc/classes/Directory.xml index 91256359fb..ed4257a809 100644 --- a/doc/classes/Directory.xml +++ b/doc/classes/Directory.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Directory" inherits="Reference" category="Core" version="3.2"> +<class name="Directory" inherits="Reference" version="4.0"> <brief_description> Type used to handle the filesystem. </brief_description> @@ -13,7 +13,7 @@ if dir.open(path) == OK: dir.list_dir_begin() var file_name = dir.get_next() - while (file_name != ""): + while file_name != "": if dir.current_is_dir(): print("Found directory: " + file_name) else: diff --git a/doc/classes/DynamicFont.xml b/doc/classes/DynamicFont.xml index ac8595d783..c2fb4d53cc 100644 --- a/doc/classes/DynamicFont.xml +++ b/doc/classes/DynamicFont.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="DynamicFont" inherits="Font" category="Core" version="3.2"> +<class name="DynamicFont" inherits="Font" version="4.0"> <brief_description> DynamicFont renders vector font files at runtime. </brief_description> diff --git a/doc/classes/DynamicFontData.xml b/doc/classes/DynamicFontData.xml index 399e103930..2b4ec17bf1 100644 --- a/doc/classes/DynamicFontData.xml +++ b/doc/classes/DynamicFontData.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="DynamicFontData" inherits="Resource" category="Core" version="3.2"> +<class name="DynamicFontData" inherits="Resource" version="4.0"> <brief_description> Used with [DynamicFont] to describe the location of a font file. </brief_description> diff --git a/doc/classes/EditorExportPlugin.xml b/doc/classes/EditorExportPlugin.xml index 4e4e29dc4e..5de68cae71 100644 --- a/doc/classes/EditorExportPlugin.xml +++ b/doc/classes/EditorExportPlugin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorExportPlugin" inherits="Reference" category="Core" version="3.2"> +<class name="EditorExportPlugin" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/EditorFeatureProfile.xml b/doc/classes/EditorFeatureProfile.xml index 92622cc25d..5fac4f7822 100644 --- a/doc/classes/EditorFeatureProfile.xml +++ b/doc/classes/EditorFeatureProfile.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorFeatureProfile" inherits="Reference" category="Core" version="3.2"> +<class name="EditorFeatureProfile" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/EditorFileDialog.xml b/doc/classes/EditorFileDialog.xml index 6b1215949a..91adf6f2af 100644 --- a/doc/classes/EditorFileDialog.xml +++ b/doc/classes/EditorFileDialog.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorFileDialog" inherits="ConfirmationDialog" category="Core" version="3.2"> +<class name="EditorFileDialog" inherits="ConfirmationDialog" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/EditorFileSystem.xml b/doc/classes/EditorFileSystem.xml index 798658c8d0..a05fbf2be7 100644 --- a/doc/classes/EditorFileSystem.xml +++ b/doc/classes/EditorFileSystem.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorFileSystem" inherits="Node" category="Core" version="3.2"> +<class name="EditorFileSystem" inherits="Node" version="4.0"> <brief_description> Resource filesystem, as the editor sees it. </brief_description> diff --git a/doc/classes/EditorFileSystemDirectory.xml b/doc/classes/EditorFileSystemDirectory.xml index cb2ed28b38..bbd3ee9b17 100644 --- a/doc/classes/EditorFileSystemDirectory.xml +++ b/doc/classes/EditorFileSystemDirectory.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorFileSystemDirectory" inherits="Object" category="Core" version="3.2"> +<class name="EditorFileSystemDirectory" inherits="Object" version="4.0"> <brief_description> A directory for the resource filesystem. </brief_description> diff --git a/doc/classes/EditorImportPlugin.xml b/doc/classes/EditorImportPlugin.xml index 0da87a9371..0aac59c727 100644 --- a/doc/classes/EditorImportPlugin.xml +++ b/doc/classes/EditorImportPlugin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorImportPlugin" inherits="ResourceImporter" category="Core" version="3.2"> +<class name="EditorImportPlugin" inherits="ResourceImporter" version="4.0"> <brief_description> Registers a custom resource importer in the editor. Use the class to parse any file and import it as a new resource type. </brief_description> diff --git a/doc/classes/EditorInspector.xml b/doc/classes/EditorInspector.xml index 450d2bf64c..7834390247 100644 --- a/doc/classes/EditorInspector.xml +++ b/doc/classes/EditorInspector.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorInspector" inherits="ScrollContainer" category="Core" version="3.2"> +<class name="EditorInspector" inherits="ScrollContainer" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/EditorInspectorPlugin.xml b/doc/classes/EditorInspectorPlugin.xml index a713e06585..eaddd9917c 100644 --- a/doc/classes/EditorInspectorPlugin.xml +++ b/doc/classes/EditorInspectorPlugin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorInspectorPlugin" inherits="Reference" category="Core" version="3.2"> +<class name="EditorInspectorPlugin" inherits="Reference" version="4.0"> <brief_description> Plugin for adding custom property editors on inspector. </brief_description> @@ -100,7 +100,7 @@ <argument index="5" name="usage" type="int"> </argument> <description> - Called to allow adding property specific editors to the inspector. Usually these inherit [EditorProperty] + Called to allow adding property specific editors to the inspector. Usually these inherit [EditorProperty]. Returning [code]true[/code] removes the built-in editor for this property, otherwise allows to insert a custom editor before the built-in one. </description> </method> </methods> diff --git a/doc/classes/EditorInterface.xml b/doc/classes/EditorInterface.xml index 20ae0f3391..fea746f32d 100644 --- a/doc/classes/EditorInterface.xml +++ b/doc/classes/EditorInterface.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorInterface" inherits="Node" category="Core" version="3.2"> +<class name="EditorInterface" inherits="Node" version="4.0"> <brief_description> Godot editor's interface. </brief_description> diff --git a/doc/classes/EditorNavigationMeshGenerator.xml b/doc/classes/EditorNavigationMeshGenerator.xml index 3956e12509..1201b6cca1 100644 --- a/doc/classes/EditorNavigationMeshGenerator.xml +++ b/doc/classes/EditorNavigationMeshGenerator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorNavigationMeshGenerator" inherits="Object" category="Core" version="3.2"> +<class name="EditorNavigationMeshGenerator" inherits="Object" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/EditorPlugin.xml b/doc/classes/EditorPlugin.xml index 89e2f0580b..eaaa87c6f9 100644 --- a/doc/classes/EditorPlugin.xml +++ b/doc/classes/EditorPlugin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorPlugin" inherits="Node" category="Core" version="3.2"> +<class name="EditorPlugin" inherits="Node" version="4.0"> <brief_description> Used by the editor to extend its functionality. </brief_description> diff --git a/doc/classes/EditorProperty.xml b/doc/classes/EditorProperty.xml index 5c24f0bebc..b93274491a 100644 --- a/doc/classes/EditorProperty.xml +++ b/doc/classes/EditorProperty.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorProperty" inherits="Container" category="Core" version="3.2"> +<class name="EditorProperty" inherits="Container" version="4.0"> <brief_description> Custom control to edit properties for adding into the inspector. </brief_description> @@ -113,7 +113,7 @@ <signal name="property_changed"> <argument index="0" name="property" type="String"> </argument> - <argument index="1" name="value" type="Nil"> + <argument index="1" name="value" type="Variant"> </argument> <description> Do not emit this manually, use the [method emit_changed] method instead. @@ -138,7 +138,7 @@ <signal name="property_keyed_with_value"> <argument index="0" name="property" type="String"> </argument> - <argument index="1" name="value" type="Nil"> + <argument index="1" name="value" type="Variant"> </argument> <description> Emit it if you want to key a property with a single value. diff --git a/doc/classes/EditorResourceConversionPlugin.xml b/doc/classes/EditorResourceConversionPlugin.xml index 2638836c68..1976eb802c 100644 --- a/doc/classes/EditorResourceConversionPlugin.xml +++ b/doc/classes/EditorResourceConversionPlugin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorResourceConversionPlugin" inherits="Reference" category="Core" version="3.2"> +<class name="EditorResourceConversionPlugin" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/EditorResourcePreview.xml b/doc/classes/EditorResourcePreview.xml index 9d3f4b0b12..8e0f8842e9 100644 --- a/doc/classes/EditorResourcePreview.xml +++ b/doc/classes/EditorResourcePreview.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorResourcePreview" inherits="Node" category="Core" version="3.2"> +<class name="EditorResourcePreview" inherits="Node" version="4.0"> <brief_description> Helper to generate previews of resources or files. </brief_description> diff --git a/doc/classes/EditorResourcePreviewGenerator.xml b/doc/classes/EditorResourcePreviewGenerator.xml index 4e61943c8f..0436f7ce06 100644 --- a/doc/classes/EditorResourcePreviewGenerator.xml +++ b/doc/classes/EditorResourcePreviewGenerator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorResourcePreviewGenerator" inherits="Reference" category="Core" version="3.2"> +<class name="EditorResourcePreviewGenerator" inherits="Reference" version="4.0"> <brief_description> Custom generator of previews. </brief_description> diff --git a/doc/classes/EditorSceneImporter.xml b/doc/classes/EditorSceneImporter.xml index 96d8ce698d..db85b859e5 100644 --- a/doc/classes/EditorSceneImporter.xml +++ b/doc/classes/EditorSceneImporter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorSceneImporter" inherits="Reference" category="Core" version="3.2"> +<class name="EditorSceneImporter" inherits="Reference" version="4.0"> <brief_description> Imports scenes from third-parties' 3D files. </brief_description> diff --git a/doc/classes/EditorSceneImporterAssimp.xml b/doc/classes/EditorSceneImporterAssimp.xml index e2d73be870..ede3c75b09 100644 --- a/doc/classes/EditorSceneImporterAssimp.xml +++ b/doc/classes/EditorSceneImporterAssimp.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorSceneImporterAssimp" inherits="EditorSceneImporter" category="Core" version="3.2"> +<class name="EditorSceneImporterAssimp" inherits="EditorSceneImporter" version="4.0"> <brief_description> Multi-format 3D asset importer based on [url=http://assimp.org/]Assimp[/url]. </brief_description> diff --git a/doc/classes/EditorScenePostImport.xml b/doc/classes/EditorScenePostImport.xml index df6cdd4b35..56fc0e3d1a 100644 --- a/doc/classes/EditorScenePostImport.xml +++ b/doc/classes/EditorScenePostImport.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorScenePostImport" inherits="Reference" category="Core" version="3.2"> +<class name="EditorScenePostImport" inherits="Reference" version="4.0"> <brief_description> Post-processes scenes after import. </brief_description> diff --git a/doc/classes/EditorScript.xml b/doc/classes/EditorScript.xml index 981e0a6180..410301351f 100644 --- a/doc/classes/EditorScript.xml +++ b/doc/classes/EditorScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorScript" inherits="Reference" category="Core" version="3.2"> +<class name="EditorScript" inherits="Reference" version="4.0"> <brief_description> Base script that can be used to add extension functions to the editor. </brief_description> diff --git a/doc/classes/EditorSelection.xml b/doc/classes/EditorSelection.xml index 57df71ab01..caafd3c15f 100644 --- a/doc/classes/EditorSelection.xml +++ b/doc/classes/EditorSelection.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorSelection" inherits="Object" category="Core" version="3.2"> +<class name="EditorSelection" inherits="Object" version="4.0"> <brief_description> Manages the SceneTree selection in the editor. </brief_description> diff --git a/doc/classes/EditorSettings.xml b/doc/classes/EditorSettings.xml index 18e8ee2d7e..30fc1e0c7b 100644 --- a/doc/classes/EditorSettings.xml +++ b/doc/classes/EditorSettings.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorSettings" inherits="Resource" category="Core" version="3.2"> +<class name="EditorSettings" inherits="Resource" version="4.0"> <brief_description> Object that holds the project-independent editor settings. </brief_description> diff --git a/doc/classes/EditorSpatialGizmo.xml b/doc/classes/EditorSpatialGizmo.xml index 419a0c5248..e7c5ca9c0f 100644 --- a/doc/classes/EditorSpatialGizmo.xml +++ b/doc/classes/EditorSpatialGizmo.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorSpatialGizmo" inherits="SpatialGizmo" category="Core" version="3.2"> +<class name="EditorSpatialGizmo" inherits="SpatialGizmo" version="4.0"> <brief_description> Custom gizmo for editing Spatial objects. </brief_description> diff --git a/doc/classes/EditorSpatialGizmoPlugin.xml b/doc/classes/EditorSpatialGizmoPlugin.xml index 777d558a8e..eba75438b9 100644 --- a/doc/classes/EditorSpatialGizmoPlugin.xml +++ b/doc/classes/EditorSpatialGizmoPlugin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorSpatialGizmoPlugin" inherits="Resource" category="Core" version="3.2"> +<class name="EditorSpatialGizmoPlugin" inherits="Resource" version="4.0"> <brief_description> Used by the editor to define Spatial gizmo types. </brief_description> @@ -49,7 +49,7 @@ <argument index="0" name="spatial" type="Spatial"> </argument> <description> - Override this method to return a custom [EditorSpatialGizmo] for the spatial nodes of your choice, return [code]null[/code] for the rest of nodes. (See also [method has_gizmo]) + Override this method to return a custom [EditorSpatialGizmo] for the spatial nodes of your choice, return [code]null[/code] for the rest of nodes. See also [method has_gizmo]. </description> </method> <method name="create_handle_material"> diff --git a/doc/classes/EditorSpinSlider.xml b/doc/classes/EditorSpinSlider.xml index bf01ebfe82..381f4fae04 100644 --- a/doc/classes/EditorSpinSlider.xml +++ b/doc/classes/EditorSpinSlider.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorSpinSlider" inherits="Range" category="Core" version="3.2"> +<class name="EditorSpinSlider" inherits="Range" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/EditorVCSInterface.xml b/doc/classes/EditorVCSInterface.xml index 23d608dea8..bb356c2183 100644 --- a/doc/classes/EditorVCSInterface.xml +++ b/doc/classes/EditorVCSInterface.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EditorVCSInterface" inherits="Object" category="Core" version="3.2"> +<class name="EditorVCSInterface" inherits="Object" version="4.0"> <brief_description> Version Control System (VCS) interface which reads and writes to the local VCS in use. </brief_description> @@ -51,14 +51,14 @@ <return type="String"> </return> <description> - Return the project name of the VCS working directory + Returns the project name of the VCS working directory. </description> </method> <method name="get_vcs_name"> <return type="String"> </return> <description> - Return the name of the VCS if the VCS has been initialized, else return an empty string. + Returns the name of the VCS if the VCS has been initialized, else return an empty string. </description> </method> <method name="initialize"> @@ -67,7 +67,7 @@ <argument index="0" name="project_root_path" type="String"> </argument> <description> - Initialize the VCS addon if not already. Uses the argument value as the path to the working directory of the project. Creates the initial commit if required. Returns [code]true[/code] if no failure occurs, else returns [code]false[/code]. + Initializes the VCS addon if not already. Uses the argument value as the path to the working directory of the project. Creates the initial commit if required. Returns [code]true[/code] if no failure occurs, else returns [code]false[/code]. </description> </method> <method name="is_addon_ready"> @@ -97,7 +97,7 @@ <argument index="0" name="file_path" type="String"> </argument> <description> - Stage the file which should be committed when [method EditorVCSInterface.commit] is called. Argument should contain the absolute path. + Stages the file which should be committed when [method EditorVCSInterface.commit] is called. Argument should contain the absolute path. </description> </method> <method name="unstage_file"> @@ -106,7 +106,7 @@ <argument index="0" name="file_path" type="String"> </argument> <description> - Unstage the file which was staged previously to be committed, so that it is no longer committed when [method EditorVCSInterface.commit] is called. Argument should contain the absolute path. + Unstages the file which was staged previously to be committed, so that it is no longer committed when [method EditorVCSInterface.commit] is called. Argument should contain the absolute path. </description> </method> </methods> diff --git a/doc/classes/EncodedObjectAsID.xml b/doc/classes/EncodedObjectAsID.xml index 7221aa845b..fc68b47645 100644 --- a/doc/classes/EncodedObjectAsID.xml +++ b/doc/classes/EncodedObjectAsID.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="EncodedObjectAsID" inherits="Reference" category="Core" version="3.2"> +<class name="EncodedObjectAsID" inherits="Reference" version="4.0"> <brief_description> Holds a reference to an [Object]'s instance ID. </brief_description> diff --git a/doc/classes/Engine.xml b/doc/classes/Engine.xml index 04e203793b..8cdb9c1c3f 100644 --- a/doc/classes/Engine.xml +++ b/doc/classes/Engine.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Engine" inherits="Object" category="Core" version="3.2"> +<class name="Engine" inherits="Object" version="4.0"> <brief_description> Access to basic engine properties. </brief_description> @@ -41,7 +41,7 @@ <return type="int"> </return> <description> - Returns the total number of frames drawn. + Returns the total number of frames drawn. If the render loop is disabled with [code]--disable-render-loop[/code] via command line, this returns [code]0[/code]. See also [method get_idle_frames]. </description> </method> <method name="get_frames_per_second" qualifiers="const"> @@ -51,6 +51,13 @@ Returns the frames per second of the running game. </description> </method> + <method name="get_idle_frames" qualifiers="const"> + <return type="int"> + </return> + <description> + Returns the total number of frames passed since engine initialization which is advanced on each [b]idle frame[/b], regardless of whether the render loop is enabled. See also [method get_frames_drawn]. + </description> + </method> <method name="get_license_info" qualifiers="const"> <return type="Dictionary"> </return> @@ -72,6 +79,13 @@ Returns the main loop object (see [MainLoop] and [SceneTree]). </description> </method> + <method name="get_physics_frames" qualifiers="const"> + <return type="int"> + </return> + <description> + Returns the total number of frames passed since engine initialization which is advanced on each [b]physics frame[/b]. + </description> + </method> <method name="get_physics_interpolation_fraction" qualifiers="const"> <return type="float"> </return> diff --git a/doc/classes/Environment.xml b/doc/classes/Environment.xml index 702ea0a999..da4b1d883a 100644 --- a/doc/classes/Environment.xml +++ b/doc/classes/Environment.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Environment" inherits="Resource" category="Core" version="3.2"> +<class name="Environment" inherits="Resource" version="4.0"> <brief_description> Resource for environment nodes (like [WorldEnvironment]) that define multiple rendering options. </brief_description> diff --git a/doc/classes/Expression.xml b/doc/classes/Expression.xml index f85413b8b4..b0a2802e43 100644 --- a/doc/classes/Expression.xml +++ b/doc/classes/Expression.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Expression" inherits="Reference" category="Core" version="3.2"> +<class name="Expression" inherits="Reference" version="4.0"> <brief_description> A class that stores an expression you can execute. </brief_description> diff --git a/doc/classes/File.xml b/doc/classes/File.xml index 9eff0a4d27..7fa87c2b60 100644 --- a/doc/classes/File.xml +++ b/doc/classes/File.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="File" inherits="Reference" category="Core" version="3.2"> +<class name="File" inherits="Reference" version="4.0"> <brief_description> Type to handle file reading and writing operations. </brief_description> diff --git a/doc/classes/FileDialog.xml b/doc/classes/FileDialog.xml index d8f4ca21c8..5cf252c173 100644 --- a/doc/classes/FileDialog.xml +++ b/doc/classes/FileDialog.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="FileDialog" inherits="ConfirmationDialog" category="Core" version="3.2"> +<class name="FileDialog" inherits="ConfirmationDialog" version="4.0"> <brief_description> Dialog for selecting files or directories in the filesystem. </brief_description> diff --git a/doc/classes/Font.xml b/doc/classes/Font.xml index e751a07082..6543a3ecf1 100644 --- a/doc/classes/Font.xml +++ b/doc/classes/Font.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Font" inherits="Resource" category="Core" version="3.2"> +<class name="Font" inherits="Resource" version="4.0"> <brief_description> Internationalized font and text drawing support. </brief_description> diff --git a/doc/classes/FuncRef.xml b/doc/classes/FuncRef.xml index 9803ae0838..37c3597a95 100644 --- a/doc/classes/FuncRef.xml +++ b/doc/classes/FuncRef.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="FuncRef" inherits="Reference" category="Core" version="3.2"> +<class name="FuncRef" inherits="Reference" version="4.0"> <brief_description> Reference to a function in an object. </brief_description> diff --git a/doc/classes/GIProbe.xml b/doc/classes/GIProbe.xml index a9192d1942..76d9620ecf 100644 --- a/doc/classes/GIProbe.xml +++ b/doc/classes/GIProbe.xml @@ -1,8 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GIProbe" inherits="VisualInstance" category="Core" version="3.2"> +<class name="GIProbe" inherits="VisualInstance" version="4.0"> <brief_description> + Real-time global illumination (GI) probe. </brief_description> <description> + [GIProbe]s are used to provide high-quality real-time indirect light to scenes. They precompute the effect of objects that emit light and the effect of static geometry to simulate the behavior of complex light in real-time. [GIProbe]s need to be baked before using, however, once baked, dynamic objects will receive light from them. Further, lights can be fully dynamic or baked. + Having [GIProbe]s in a scene can be expensive, the quality of the probe can be turned down in exchange for better performance in the [ProjectSettings] using [member ProjectSettings.rendering/quality/voxel_cone_tracing/high_quality]. </description> <tutorials> <link>https://docs.godotengine.org/en/latest/tutorials/3d/gi_probes.html</link> @@ -16,45 +19,62 @@ <argument index="1" name="create_visual_debug" type="bool" default="false"> </argument> <description> + Bakes the effect from all [GeometryInstance]s marked with [member GeometryInstance.use_in_baked_light] and [Light]s marked with either [constant Light.BAKE_INDIRECT] or [constant Light.BAKE_ALL]. If [code]create_visual_debug[/code] is [code]true[/code], after baking the light, this will generate a [MultiMesh] that has a cube representing each solid cell with each cube colored to the cell's albedo color. This can be used to visualize the [GIProbe]'s data and debug any issues that may be occurring. </description> </method> <method name="debug_bake"> <return type="void"> </return> <description> + Calls [method bake] with [code]create_visual_debug[/code] enabled. </description> </method> </methods> <members> <member name="bias" type="float" setter="set_bias" getter="get_bias" default="1.5"> + Offsets the lookup of the light contribution from the [GIProbe]. This can be used to avoid self-shadowing, but may introduce light leaking at higher values. This and [member normal_bias] should be played around with to minimize self-shadowing and light leaking. + [b]Note:[/b] [code]bias[/code] should usually be above 1.0 as that is the size of the voxels. </member> <member name="compress" type="bool" setter="set_compress" getter="is_compressed" default="false"> + If [code]true[/code], the data for this [GIProbe] will be compressed. Compression saves space, but results in far worse visual quality. </member> <member name="data" type="GIProbeData" setter="set_probe_data" getter="get_probe_data"> + The [GIProbeData] resource that holds the data for this [GIProbe]. </member> <member name="dynamic_range" type="int" setter="set_dynamic_range" getter="get_dynamic_range" default="4"> + The maximum brightness that the [GIProbe] will recognize. Brightness will be scaled within this range. </member> <member name="energy" type="float" setter="set_energy" getter="get_energy" default="1.0"> + Energy multiplier. Makes the lighting contribution from the [GIProbe] brighter. </member> <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3( 10, 10, 10 )"> + The size of the area covered by the [GIProbe]. If you make the extents larger without increasing the subdivisions with [member subdiv], the size of each cell will increase and result in lower detailed lighting. </member> <member name="interior" type="bool" setter="set_interior" getter="is_interior" default="false"> + If [code]true[/code], ignores the sky contribution when calculating lighting. </member> <member name="normal_bias" type="float" setter="set_normal_bias" getter="get_normal_bias" default="0.0"> + Offsets the lookup into the [GIProbe] based on the object's normal direction. Can be used to reduce some self-shadowing artifacts. </member> <member name="propagation" type="float" setter="set_propagation" getter="get_propagation" default="0.7"> + How much light propagates through the probe internally. A higher value allows light to spread further. </member> <member name="subdiv" type="int" setter="set_subdiv" getter="get_subdiv" enum="GIProbe.Subdiv" default="1"> + Number of times to subdivide the grid that the [GIProbe] operates on. A higher number results in finer detail and thus higher visual quality, while lower numbers result in better performance. </member> </members> <constants> <constant name="SUBDIV_64" value="0" enum="Subdiv"> + Use 64 subdivisions. This is the lowest quality setting, but the fastest. Use it if you can, but especially use it on lower-end hardware. </constant> <constant name="SUBDIV_128" value="1" enum="Subdiv"> + Use 128 subdivisions. This is the default quality setting. </constant> <constant name="SUBDIV_256" value="2" enum="Subdiv"> + Use 256 subdivisions. </constant> <constant name="SUBDIV_512" value="3" enum="Subdiv"> + Use 512 subdivisions. This is the highest quality setting, but the slowest. On lower-end hardware this could cause the GPU to stall. </constant> <constant name="SUBDIV_MAX" value="4" enum="Subdiv"> Represents the size of the [enum Subdiv] enum. diff --git a/doc/classes/GIProbeData.xml b/doc/classes/GIProbeData.xml index 84bd695f43..bb1ee4d054 100644 --- a/doc/classes/GIProbeData.xml +++ b/doc/classes/GIProbeData.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GIProbeData" inherits="Resource" category="Core" version="3.2"> +<class name="GIProbeData" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/Generic6DOFJoint.xml b/doc/classes/Generic6DOFJoint.xml index bc34f3ac0d..29ebf9f5d6 100644 --- a/doc/classes/Generic6DOFJoint.xml +++ b/doc/classes/Generic6DOFJoint.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Generic6DOFJoint" inherits="Joint" category="Core" version="3.2"> +<class name="Generic6DOFJoint" inherits="Joint" version="4.0"> <brief_description> The generic 6-degrees-of-freedom joint can implement a variety of joint types by locking certain axes' rotation or translation. </brief_description> diff --git a/doc/classes/Geometry.xml b/doc/classes/Geometry.xml index 3824baa4dc..739c860b28 100644 --- a/doc/classes/Geometry.xml +++ b/doc/classes/Geometry.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Geometry" inherits="Object" category="Core" version="3.2"> +<class name="Geometry" inherits="Object" version="4.0"> <brief_description> + Helper node to calculate generic geometry operations. </brief_description> <description> + Geometry provides users with a set of helper functions to create geometric shapes, compute intersections between shapes, and process various other geometric operations. </description> <tutorials> </tutorials> @@ -113,7 +115,7 @@ <argument index="2" name="s2" type="Vector3"> </argument> <description> - Returns the 3d point on the 3d segment ([code]s1[/code], [code]s2[/code]) that is closest to [code]point[/code]. The returned point will always be inside the specified segment. + Returns the 3D point on the 3D segment ([code]s1[/code], [code]s2[/code]) that is closest to [code]point[/code]. The returned point will always be inside the specified segment. </description> </method> <method name="get_closest_point_to_segment_2d"> @@ -126,7 +128,7 @@ <argument index="2" name="s2" type="Vector2"> </argument> <description> - Returns the 2d point on the 2d segment ([code]s1[/code], [code]s2[/code]) that is closest to [code]point[/code]. The returned point will always be inside the specified segment. + Returns the 2D point on the 2D segment ([code]s1[/code], [code]s2[/code]) that is closest to [code]point[/code]. The returned point will always be inside the specified segment. </description> </method> <method name="get_closest_point_to_segment_uncapped"> @@ -139,7 +141,7 @@ <argument index="2" name="s2" type="Vector3"> </argument> <description> - Returns the 3d point on the 3d line defined by ([code]s1[/code], [code]s2[/code]) that is closest to [code]point[/code]. The returned point can be inside the segment ([code]s1[/code], [code]s2[/code]) or outside of it, i.e. somewhere on the line extending from the segment. + Returns the 3D point on the 3D line defined by ([code]s1[/code], [code]s2[/code]) that is closest to [code]point[/code]. The returned point can be inside the segment ([code]s1[/code], [code]s2[/code]) or outside of it, i.e. somewhere on the line extending from the segment. </description> </method> <method name="get_closest_point_to_segment_uncapped_2d"> @@ -152,7 +154,7 @@ <argument index="2" name="s2" type="Vector2"> </argument> <description> - Returns the 2d point on the 2d line defined by ([code]s1[/code], [code]s2[/code]) that is closest to [code]point[/code]. The returned point can be inside the segment ([code]s1[/code], [code]s2[/code]) or outside of it, i.e. somewhere on the line extending from the segment. + Returns the 2D point on the 2D line defined by ([code]s1[/code], [code]s2[/code]) that is closest to [code]point[/code]. The returned point can be inside the segment ([code]s1[/code], [code]s2[/code]) or outside of it, i.e. somewhere on the line extending from the segment. </description> </method> <method name="get_closest_points_between_segments"> @@ -167,7 +169,7 @@ <argument index="3" name="q2" type="Vector3"> </argument> <description> - Given the two 3d segments ([code]p1[/code], [code]p2[/code]) and ([code]q1[/code], [code]q2[/code]), finds those two points on the two segments that are closest to each other. Returns a [PoolVector3Array] that contains this point on ([code]p1[/code], [code]p2[/code]) as well the accompanying point on ([code]q1[/code], [code]q2[/code]). + Given the two 3D segments ([code]p1[/code], [code]p2[/code]) and ([code]q1[/code], [code]q2[/code]), finds those two points on the two segments that are closest to each other. Returns a [PoolVector3Array] that contains this point on ([code]p1[/code], [code]p2[/code]) as well the accompanying point on ([code]q1[/code], [code]q2[/code]). </description> </method> <method name="get_closest_points_between_segments_2d"> @@ -182,7 +184,7 @@ <argument index="3" name="q2" type="Vector2"> </argument> <description> - Given the two 2d segments ([code]p1[/code], [code]p2[/code]) and ([code]q1[/code], [code]q2[/code]), finds those two points on the two segments that are closest to each other. Returns a [PoolVector2Array] that contains this point on ([code]p1[/code], [code]p2[/code]) as well the accompanying point on ([code]q1[/code], [code]q2[/code]). + Given the two 2D segments ([code]p1[/code], [code]p2[/code]) and ([code]q1[/code], [code]q2[/code]), finds those two points on the two segments that are closest to each other. Returns a [PoolVector2Array] that contains this point on ([code]p1[/code], [code]p2[/code]) as well the accompanying point on ([code]q1[/code], [code]q2[/code]). </description> </method> <method name="get_uv84_normal_bit"> @@ -191,6 +193,7 @@ <argument index="0" name="normal" type="Vector3"> </argument> <description> + Used internally by the engine. </description> </method> <method name="intersect_polygons_2d"> @@ -348,7 +351,7 @@ <argument index="4" name="c" type="Vector3"> </argument> <description> - Tests if the 3d ray starting at [code]from[/code] with the direction of [code]dir[/code] intersects the triangle specified by [code]a[/code], [code]b[/code] and [code]c[/code]. If yes, returns the point of intersection as [Vector3]. If no intersection takes place, an empty [Variant] is returned. + Tests if the 3D ray starting at [code]from[/code] with the direction of [code]dir[/code] intersects the triangle specified by [code]a[/code], [code]b[/code] and [code]c[/code]. If yes, returns the point of intersection as [Vector3]. If no intersection takes place, an empty [Variant] is returned. </description> </method> <method name="segment_intersects_circle"> @@ -363,7 +366,7 @@ <argument index="3" name="circle_radius" type="float"> </argument> <description> - Given the 2d segment ([code]segment_from[/code], [code]segment_to[/code]), returns the position on the segment (as a number between 0 and 1) at which the segment hits the circle that is located at position [code]circle_position[/code] and has radius [code]circle_radius[/code]. If the segment does not intersect the circle, -1 is returned (this is also the case if the line extending the segment would intersect the circle, but the segment does not). + Given the 2D segment ([code]segment_from[/code], [code]segment_to[/code]), returns the position on the segment (as a number between 0 and 1) at which the segment hits the circle that is located at position [code]circle_position[/code] and has radius [code]circle_radius[/code]. If the segment does not intersect the circle, -1 is returned (this is also the case if the line extending the segment would intersect the circle, but the segment does not). </description> </method> <method name="segment_intersects_convex"> diff --git a/doc/classes/GeometryInstance.xml b/doc/classes/GeometryInstance.xml index 02f2c27043..fccd75edad 100644 --- a/doc/classes/GeometryInstance.xml +++ b/doc/classes/GeometryInstance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GeometryInstance" inherits="VisualInstance" category="Core" version="3.2"> +<class name="GeometryInstance" inherits="VisualInstance" version="4.0"> <brief_description> Base node for geometry-based visual instances. </brief_description> @@ -15,6 +15,7 @@ <argument index="0" name="flag" type="int" enum="GeometryInstance.Flags"> </argument> <description> + Returns the [enum GeometryInstance.Flags] that have been set for this object. </description> </method> <method name="set_custom_aabb"> @@ -34,6 +35,7 @@ <argument index="1" name="value" type="bool"> </argument> <description> + Sets the [enum GeometryInstance.Flags] specified. See [enum GeometryInstance.Flags] for options. </description> </method> </methods> diff --git a/doc/classes/Gradient.xml b/doc/classes/Gradient.xml index 247a7afe85..3ce70045ef 100644 --- a/doc/classes/Gradient.xml +++ b/doc/classes/Gradient.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Gradient" inherits="Resource" category="Core" version="3.2"> +<class name="Gradient" inherits="Resource" version="4.0"> <brief_description> A color interpolator resource which can be used to generate colors between user-defined color points. </brief_description> diff --git a/doc/classes/GradientTexture.xml b/doc/classes/GradientTexture.xml index 3492b2e261..fc9c3fd1bb 100644 --- a/doc/classes/GradientTexture.xml +++ b/doc/classes/GradientTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GradientTexture" inherits="Texture" category="Core" version="3.2"> +<class name="GradientTexture" inherits="Texture" version="4.0"> <brief_description> Gradient-filled texture. </brief_description> diff --git a/doc/classes/GraphEdit.xml b/doc/classes/GraphEdit.xml index 802134d3b6..e35fc2b7d1 100644 --- a/doc/classes/GraphEdit.xml +++ b/doc/classes/GraphEdit.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GraphEdit" inherits="Control" category="Core" version="3.2"> +<class name="GraphEdit" inherits="Control" version="4.0"> <brief_description> GraphEdit is an area capable of showing various GraphNodes. It manages connection events between them. </brief_description> diff --git a/doc/classes/GraphNode.xml b/doc/classes/GraphNode.xml index 8fda9c20a5..3387150429 100644 --- a/doc/classes/GraphNode.xml +++ b/doc/classes/GraphNode.xml @@ -1,11 +1,12 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GraphNode" inherits="Container" category="Core" version="3.2"> +<class name="GraphNode" inherits="Container" version="4.0"> <brief_description> - A GraphNode is a container with several input and output slots allowing connections between GraphNodes. Slots can have different, incompatible types. + A GraphNode is a container with potentially several input and output slots allowing connections between GraphNodes. Slots can have different, incompatible types. </brief_description> <description> - A GraphNode is a container defined by a title. It can have one or more input and output slots, which can be enabled (shown) or disabled (not shown) and have different (incompatible) types. Colors can also be assigned to slots. A tuple of input and output slots is defined for each GUI element included in the GraphNode. Input and output connections are left and right slots, but only enabled slots are counted as connections. - To add a slot to GraphNode, add any [Control]-derived child node to it. + A GraphNode is a container. Each GraphNode can have several input and output slots, sometimes referred to as ports, allowing connections between GraphNodes. To add a slot to GraphNode, add any [Control]-derived child node to it. + After adding at least one child to GraphNode new sections will be automatically created in the Inspector called 'Slot'. When 'Slot' is expanded you will see list with index number for each slot. You can click on each of them to expand further. + In the Inspector you can enable (show) or disable (hide) slots. By default all slots are disabled so you may not see any slots on your GraphNode initially. You can assign a type to each slot. Only slots of the same type will be able to connect to each other. You can also assign colors to slots. A tuple of input and output slots is defined for each GUI element included in the GraphNode. Input connections are on the left and output connections are on the right side of GraphNode. Only enabled slots are counted as connections. </description> <tutorials> </tutorials> @@ -192,14 +193,14 @@ </member> <member name="resizable" type="bool" setter="set_resizable" getter="is_resizable" default="false"> If [code]true[/code], the user can resize the GraphNode. - [b]Note:[/b] Dragging the handle will only trigger the [signal resize_request] signal, the GraphNode needs to be resized manually. + [b]Note:[/b] Dragging the handle will only emit the [signal resize_request] signal, the GraphNode needs to be resized manually. </member> <member name="selected" type="bool" setter="set_selected" getter="is_selected" default="false"> If [code]true[/code], the GraphNode is selected. </member> <member name="show_close" type="bool" setter="set_show_close_button" getter="is_close_button_visible" default="false"> If [code]true[/code], the close button will be visible. - [b]Note:[/b] Pressing it will only trigger the [signal close_request] signal, the GraphNode needs to be removed manually. + [b]Note:[/b] Pressing it will only emit the [signal close_request] signal, the GraphNode needs to be removed manually. </member> <member name="title" type="String" setter="set_title" getter="get_title" default=""""> The text displayed in the GraphNode's title bar. diff --git a/doc/classes/GridContainer.xml b/doc/classes/GridContainer.xml index e8c764f412..472578f29b 100644 --- a/doc/classes/GridContainer.xml +++ b/doc/classes/GridContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GridContainer" inherits="Container" category="Core" version="3.2"> +<class name="GridContainer" inherits="Container" version="4.0"> <brief_description> Grid container used to arrange elements in a grid like layout. </brief_description> diff --git a/doc/classes/GrooveJoint2D.xml b/doc/classes/GrooveJoint2D.xml index 6b87fa5cfe..643b7aefea 100644 --- a/doc/classes/GrooveJoint2D.xml +++ b/doc/classes/GrooveJoint2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GrooveJoint2D" inherits="Joint2D" category="Core" version="3.2"> +<class name="GrooveJoint2D" inherits="Joint2D" version="4.0"> <brief_description> Groove constraint for 2D physics. </brief_description> diff --git a/doc/classes/HBoxContainer.xml b/doc/classes/HBoxContainer.xml index e2abbe16cc..7c76b8b001 100644 --- a/doc/classes/HBoxContainer.xml +++ b/doc/classes/HBoxContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HBoxContainer" inherits="BoxContainer" category="Core" version="3.2"> +<class name="HBoxContainer" inherits="BoxContainer" version="4.0"> <brief_description> Horizontal box container. </brief_description> @@ -14,6 +14,7 @@ </constants> <theme_items> <theme_item name="separation" type="int" default="4"> + The horizontal space between the [HBoxContainer]'s elements. </theme_item> </theme_items> </class> diff --git a/doc/classes/HScrollBar.xml b/doc/classes/HScrollBar.xml index 90f14dd344..129e15b489 100644 --- a/doc/classes/HScrollBar.xml +++ b/doc/classes/HScrollBar.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HScrollBar" inherits="ScrollBar" category="Core" version="3.2"> +<class name="HScrollBar" inherits="ScrollBar" version="4.0"> <brief_description> Horizontal scroll bar. </brief_description> diff --git a/doc/classes/HSeparator.xml b/doc/classes/HSeparator.xml index c34364c573..aa83b67934 100644 --- a/doc/classes/HSeparator.xml +++ b/doc/classes/HSeparator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HSeparator" inherits="Separator" category="Core" version="3.2"> +<class name="HSeparator" inherits="Separator" version="4.0"> <brief_description> Horizontal separator. </brief_description> diff --git a/doc/classes/HSlider.xml b/doc/classes/HSlider.xml index 4e7d9bc9f3..2999580e83 100644 --- a/doc/classes/HSlider.xml +++ b/doc/classes/HSlider.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HSlider" inherits="Slider" category="Core" version="3.2"> +<class name="HSlider" inherits="Slider" version="4.0"> <brief_description> Horizontal slider. </brief_description> diff --git a/doc/classes/HSplitContainer.xml b/doc/classes/HSplitContainer.xml index 3a425705c6..6191087c2e 100644 --- a/doc/classes/HSplitContainer.xml +++ b/doc/classes/HSplitContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HSplitContainer" inherits="SplitContainer" category="Core" version="3.2"> +<class name="HSplitContainer" inherits="SplitContainer" version="4.0"> <brief_description> Horizontal split container. </brief_description> diff --git a/doc/classes/HTTPClient.xml b/doc/classes/HTTPClient.xml index 3a63b2dc07..bdcbb11ef0 100644 --- a/doc/classes/HTTPClient.xml +++ b/doc/classes/HTTPClient.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HTTPClient" inherits="Reference" category="Core" version="3.2"> +<class name="HTTPClient" inherits="Reference" version="4.0"> <brief_description> Hyper-text transfer protocol client. </brief_description> @@ -100,7 +100,7 @@ <return type="int" enum="Error"> </return> <description> - This needs to be called in order to have any request processed. Check results with [method get_status] + This needs to be called in order to have any request processed. Check results with [method get_status]. </description> </method> <method name="query_string_from_dict"> diff --git a/doc/classes/HTTPRequest.xml b/doc/classes/HTTPRequest.xml index 748ed504c3..313f21d8f9 100644 --- a/doc/classes/HTTPRequest.xml +++ b/doc/classes/HTTPRequest.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HTTPRequest" inherits="Node" category="Core" version="3.2"> +<class name="HTTPRequest" inherits="Node" version="4.0"> <brief_description> A node with the ability to send HTTP(S) requests. </brief_description> @@ -170,7 +170,7 @@ Request exceeded its maximum size limit, see [member body_size_limit]. </constant> <constant name="RESULT_REQUEST_FAILED" value="8" enum="Result"> - Request failed. (Unused) + Request failed (currently unused). </constant> <constant name="RESULT_DOWNLOAD_FILE_CANT_OPEN" value="9" enum="Result"> HTTPRequest couldn't open the download file. diff --git a/doc/classes/HashingContext.xml b/doc/classes/HashingContext.xml index 802b186ef3..bc585df4a0 100644 --- a/doc/classes/HashingContext.xml +++ b/doc/classes/HashingContext.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HashingContext" inherits="Reference" category="Core" version="3.2"> +<class name="HashingContext" inherits="Reference" version="4.0"> <brief_description> Context to compute cryptographic hashes over multiple iterations. </brief_description> @@ -27,6 +27,7 @@ # Print the result as hex string and array. printt(res.hex_encode(), Array(res)) [/codeblock] + [b]Note:[/b] Not available in HTML5 exports. </description> <tutorials> </tutorials> diff --git a/doc/classes/HeightMapShape.xml b/doc/classes/HeightMapShape.xml index cb7da8af26..f94089066c 100644 --- a/doc/classes/HeightMapShape.xml +++ b/doc/classes/HeightMapShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HeightMapShape" inherits="Shape" category="Core" version="3.2"> +<class name="HeightMapShape" inherits="Shape" version="4.0"> <brief_description> Height map shape for 3D physics (Bullet only). </brief_description> diff --git a/doc/classes/HingeJoint.xml b/doc/classes/HingeJoint.xml index 4582e36da6..53fa74cace 100644 --- a/doc/classes/HingeJoint.xml +++ b/doc/classes/HingeJoint.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="HingeJoint" inherits="Joint" category="Core" version="3.2"> +<class name="HingeJoint" inherits="Joint" version="4.0"> <brief_description> A hinge between two 3D bodies. </brief_description> diff --git a/doc/classes/IP.xml b/doc/classes/IP.xml index bfc645b8e7..152f381a83 100644 --- a/doc/classes/IP.xml +++ b/doc/classes/IP.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="IP" inherits="Object" category="Core" version="3.2"> +<class name="IP" inherits="Object" version="4.0"> <brief_description> Internet protocol (IP) support functions such as DNS resolution. </brief_description> diff --git a/doc/classes/IP_Unix.xml b/doc/classes/IP_Unix.xml index 2a97c40ef8..79cdf2ce08 100644 --- a/doc/classes/IP_Unix.xml +++ b/doc/classes/IP_Unix.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="IP_Unix" inherits="IP" category="Core" version="3.2"> +<class name="IP_Unix" inherits="IP" version="4.0"> <brief_description> UNIX IP support. See [IP]. </brief_description> diff --git a/doc/classes/Image.xml b/doc/classes/Image.xml index 0303585120..2cd17cb5c5 100644 --- a/doc/classes/Image.xml +++ b/doc/classes/Image.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Image" inherits="Resource" category="Core" version="3.2"> +<class name="Image" inherits="Resource" version="4.0"> <brief_description> Image datatype. </brief_description> @@ -71,6 +71,7 @@ <argument index="0" name="bump_scale" type="float" default="1.0"> </argument> <description> + Converts a bumpmap to a normalmap. A bumpmap provides a height offset per-pixel, while a normalmap provides a normal direction per pixel. </description> </method> <method name="clear_mipmaps"> @@ -165,7 +166,7 @@ <return type="int" enum="Image.AlphaMode"> </return> <description> - Returns [constant ALPHA_BLEND] if the image has data for alpha values. Returns [constant ALPHA_BIT] if all the alpha values are below a certain threshold or the maximum value. Returns [constant ALPHA_NONE] if no data for alpha values is found. + Returns [constant ALPHA_BLEND] if the image has data for alpha values. Returns [constant ALPHA_BIT] if all the alpha values are stored in a single bit. Returns [constant ALPHA_NONE] if no data for alpha values is found. </description> </method> <method name="expand_x2_hq2x"> @@ -284,7 +285,7 @@ <return type="Rect2"> </return> <description> - Returns a [Rect2] enclosing the visible portion of the image. + Returns a [Rect2] enclosing the visible portion of the image, considering each pixel with a non-zero alpha channel as visible. </description> </method> <method name="get_width" qualifiers="const"> @@ -405,6 +406,7 @@ <return type="Image"> </return> <description> + Converts a standard RGBE (Red Green Blue Exponent) image to an sRGB image. </description> </method> <method name="save_exr" qualifiers="const"> @@ -502,8 +504,10 @@ The maximal height allowed for [Image] resources. </constant> <constant name="FORMAT_L8" value="0" enum="Format"> + Texture format with a single 8-bit depth representing luminance. </constant> <constant name="FORMAT_LA8" value="1" enum="Format"> + OpenGL texture format with two values, luminance and alpha each stored with 8 bits. </constant> <constant name="FORMAT_R8" value="2" enum="Format"> OpenGL texture format [code]RED[/code] with a single component and a bitdepth of 8. @@ -643,26 +647,37 @@ Performs Lanczos interpolation. This is the slowest image resizing mode, but it typically gives the best results, especially when downscalng images. </constant> <constant name="ALPHA_NONE" value="0" enum="AlphaMode"> + Image does not have alpha. </constant> <constant name="ALPHA_BIT" value="1" enum="AlphaMode"> + Image stores alpha in a single bit. </constant> <constant name="ALPHA_BLEND" value="2" enum="AlphaMode"> + Image uses alpha. </constant> <constant name="COMPRESS_S3TC" value="0" enum="CompressMode"> + Use S3TC compression. </constant> <constant name="COMPRESS_PVRTC2" value="1" enum="CompressMode"> + Use PVRTC2 compression. </constant> <constant name="COMPRESS_PVRTC4" value="2" enum="CompressMode"> + Use PVRTC4 compression. </constant> <constant name="COMPRESS_ETC" value="3" enum="CompressMode"> + Use ETC compression. </constant> <constant name="COMPRESS_ETC2" value="4" enum="CompressMode"> + Use ETC2 compression. </constant> <constant name="COMPRESS_SOURCE_GENERIC" value="0" enum="CompressSource"> + Source texture (before compression) is a regular texture. Default for all textures. </constant> <constant name="COMPRESS_SOURCE_SRGB" value="1" enum="CompressSource"> + Source texture (before compression) is in sRGB space. </constant> <constant name="COMPRESS_SOURCE_NORMAL" value="2" enum="CompressSource"> + Source texture (before compression) is a normal texture (e.g. it can be compressed into two channels). </constant> </constants> </class> diff --git a/doc/classes/ImageTexture.xml b/doc/classes/ImageTexture.xml index 03bf739760..7e3e818773 100644 --- a/doc/classes/ImageTexture.xml +++ b/doc/classes/ImageTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ImageTexture" inherits="Texture" category="Core" version="3.2"> +<class name="ImageTexture" inherits="Texture" version="4.0"> <brief_description> A [Texture] based on an [Image]. </brief_description> diff --git a/doc/classes/ImmediateGeometry.xml b/doc/classes/ImmediateGeometry.xml index 416128c9b1..bb58192313 100644 --- a/doc/classes/ImmediateGeometry.xml +++ b/doc/classes/ImmediateGeometry.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ImmediateGeometry" inherits="GeometryInstance" category="Core" version="3.2"> +<class name="ImmediateGeometry" inherits="GeometryInstance" version="4.0"> <brief_description> Draws simple geometry from code. </brief_description> diff --git a/doc/classes/Input.xml b/doc/classes/Input.xml index 3f94ad2d2c..b7afe57218 100644 --- a/doc/classes/Input.xml +++ b/doc/classes/Input.xml @@ -1,10 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Input" inherits="Object" category="Core" version="3.2"> +<class name="Input" inherits="Object" version="4.0"> <brief_description> - A Singleton that deals with inputs. + A singleton that deals with inputs. </brief_description> <description> - A Singleton that deals with inputs. This includes key presses, mouse buttons and movement, joypads, and input actions. Actions and their events can be set in the [b]Input Map[/b] tab in the [b]Project > Project Settings[/b], or with the [InputMap] class. + A singleton that deals with inputs. This includes key presses, mouse buttons and movement, joypads, and input actions. Actions and their events can be set in the [b]Input Map[/b] tab in the [b]Project > Project Settings[/b], or with the [InputMap] class. </description> <tutorials> <link>https://docs.godotengine.org/en/latest/tutorials/inputs/index.html</link> @@ -277,6 +277,8 @@ <argument index="3" name="guid" type="String"> </argument> <description> + Notifies the [Input] singleton that a connection has changed, to update the state for the [code]device[/code] index. + This is used internally and should not have to be called from user scripts. See [signal joy_connection_changed] for the signal emitted when this is triggered internally. </description> </method> <method name="parse_input_event"> diff --git a/doc/classes/InputDefault.xml b/doc/classes/InputDefault.xml index e96b885d10..ea4d08c628 100644 --- a/doc/classes/InputDefault.xml +++ b/doc/classes/InputDefault.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputDefault" inherits="Input" category="Core" version="3.2"> +<class name="InputDefault" inherits="Input" version="4.0"> <brief_description> Default implementation of the [Input] class. </brief_description> diff --git a/doc/classes/InputEvent.xml b/doc/classes/InputEvent.xml index ccb5c5400a..9e3764206b 100644 --- a/doc/classes/InputEvent.xml +++ b/doc/classes/InputEvent.xml @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEvent" inherits="Resource" category="Core" version="3.2"> +<class name="InputEvent" inherits="Resource" version="4.0"> <brief_description> - Generic input event + Generic input event. </brief_description> <description> Base class of all sort of input event. See [method Node._input]. diff --git a/doc/classes/InputEventAction.xml b/doc/classes/InputEventAction.xml index 46c47e357f..2dac693a52 100644 --- a/doc/classes/InputEventAction.xml +++ b/doc/classes/InputEventAction.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventAction" inherits="InputEvent" category="Core" version="3.2"> +<class name="InputEventAction" inherits="InputEvent" version="4.0"> <brief_description> Input event type for actions. </brief_description> diff --git a/doc/classes/InputEventGesture.xml b/doc/classes/InputEventGesture.xml index 59750a0902..9cacd3e6fd 100644 --- a/doc/classes/InputEventGesture.xml +++ b/doc/classes/InputEventGesture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventGesture" inherits="InputEventWithModifiers" category="Core" version="3.2"> +<class name="InputEventGesture" inherits="InputEventWithModifiers" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/InputEventJoypadButton.xml b/doc/classes/InputEventJoypadButton.xml index dcdda83681..19aa97e1ec 100644 --- a/doc/classes/InputEventJoypadButton.xml +++ b/doc/classes/InputEventJoypadButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventJoypadButton" inherits="InputEvent" category="Core" version="3.2"> +<class name="InputEventJoypadButton" inherits="InputEvent" version="4.0"> <brief_description> Input event for gamepad buttons. </brief_description> diff --git a/doc/classes/InputEventJoypadMotion.xml b/doc/classes/InputEventJoypadMotion.xml index eb05cd2f99..01e02b79b1 100644 --- a/doc/classes/InputEventJoypadMotion.xml +++ b/doc/classes/InputEventJoypadMotion.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventJoypadMotion" inherits="InputEvent" category="Core" version="3.2"> +<class name="InputEventJoypadMotion" inherits="InputEvent" version="4.0"> <brief_description> Input event type for gamepad joysticks and other motions. For buttons, see [code]InputEventJoypadButton[/code]. </brief_description> diff --git a/doc/classes/InputEventKey.xml b/doc/classes/InputEventKey.xml index cf9faaa26d..637f697f01 100644 --- a/doc/classes/InputEventKey.xml +++ b/doc/classes/InputEventKey.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventKey" inherits="InputEventWithModifiers" category="Core" version="3.2"> +<class name="InputEventKey" inherits="InputEventWithModifiers" version="4.0"> <brief_description> Input event type for keyboard events. </brief_description> @@ -15,6 +15,7 @@ </return> <description> Returns the scancode combined with modifier keys such as [code]Shift[/code] or [code]Alt[/code]. See also [InputEventWithModifiers]. + To get a human-readable representation of the [InputEventKey] with modifiers, use [code]OS.get_scancode_string(event.get_scancode_with_modifiers())[/code] where [code]event[/code] is the [InputEventKey]. </description> </method> </methods> @@ -26,10 +27,11 @@ If [code]true[/code], the key's state is pressed. If [code]false[/code], the key's state is released. </member> <member name="scancode" type="int" setter="set_scancode" getter="get_scancode" default="0"> - Key scancode, one of the [enum KeyList] constants. + The key scancode, which corresponds to one of the [enum KeyList] constants. + To get a human-readable representation of the [InputEventKey], use [code]OS.get_scancode_string(event.scancode)[/code] where [code]event[/code] is the [InputEventKey]. </member> <member name="unicode" type="int" setter="set_unicode" getter="get_unicode" default="0"> - Key Unicode identifier when relevant. Unicode identifiers for the composite characters and complex scripts may not be available unless IME input mode is active. See [method OS.set_ime_active] for more information. + The key Unicode identifier (when relevant). Unicode identifiers for the composite characters and complex scripts may not be available unless IME input mode is active. See [method OS.set_ime_active] for more information. </member> </members> <constants> diff --git a/doc/classes/InputEventMIDI.xml b/doc/classes/InputEventMIDI.xml index fe77e46c6c..13bb9d8b85 100644 --- a/doc/classes/InputEventMIDI.xml +++ b/doc/classes/InputEventMIDI.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventMIDI" inherits="InputEvent" category="Core" version="3.2"> +<class name="InputEventMIDI" inherits="InputEvent" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/InputEventMagnifyGesture.xml b/doc/classes/InputEventMagnifyGesture.xml index f5add435f5..3e539b2f97 100644 --- a/doc/classes/InputEventMagnifyGesture.xml +++ b/doc/classes/InputEventMagnifyGesture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventMagnifyGesture" inherits="InputEventGesture" category="Core" version="3.2"> +<class name="InputEventMagnifyGesture" inherits="InputEventGesture" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/InputEventMouse.xml b/doc/classes/InputEventMouse.xml index 56ba33702b..e3c9d688d2 100644 --- a/doc/classes/InputEventMouse.xml +++ b/doc/classes/InputEventMouse.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventMouse" inherits="InputEventWithModifiers" category="Core" version="3.2"> +<class name="InputEventMouse" inherits="InputEventWithModifiers" version="4.0"> <brief_description> Base input event type for mouse events. </brief_description> diff --git a/doc/classes/InputEventMouseButton.xml b/doc/classes/InputEventMouseButton.xml index 4cf7174ab1..b83588a877 100644 --- a/doc/classes/InputEventMouseButton.xml +++ b/doc/classes/InputEventMouseButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventMouseButton" inherits="InputEventMouse" category="Core" version="3.2"> +<class name="InputEventMouseButton" inherits="InputEventMouse" version="4.0"> <brief_description> Input event type for mouse button events. </brief_description> diff --git a/doc/classes/InputEventMouseMotion.xml b/doc/classes/InputEventMouseMotion.xml index 5cd6a0c285..1549353d45 100644 --- a/doc/classes/InputEventMouseMotion.xml +++ b/doc/classes/InputEventMouseMotion.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventMouseMotion" inherits="InputEventMouse" category="Core" version="3.2"> +<class name="InputEventMouseMotion" inherits="InputEventMouse" version="4.0"> <brief_description> Input event type for mouse motion events. </brief_description> diff --git a/doc/classes/InputEventPanGesture.xml b/doc/classes/InputEventPanGesture.xml index dab2c74543..83161cd163 100644 --- a/doc/classes/InputEventPanGesture.xml +++ b/doc/classes/InputEventPanGesture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventPanGesture" inherits="InputEventGesture" category="Core" version="3.2"> +<class name="InputEventPanGesture" inherits="InputEventGesture" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/InputEventScreenDrag.xml b/doc/classes/InputEventScreenDrag.xml index be2eafbe7c..d7e0c2454c 100644 --- a/doc/classes/InputEventScreenDrag.xml +++ b/doc/classes/InputEventScreenDrag.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventScreenDrag" inherits="InputEvent" category="Core" version="3.2"> +<class name="InputEventScreenDrag" inherits="InputEvent" version="4.0"> <brief_description> Input event type for screen drag events. Only available on mobile devices. </brief_description> diff --git a/doc/classes/InputEventScreenTouch.xml b/doc/classes/InputEventScreenTouch.xml index 6239fbc949..4a5cd36423 100644 --- a/doc/classes/InputEventScreenTouch.xml +++ b/doc/classes/InputEventScreenTouch.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventScreenTouch" inherits="InputEvent" category="Core" version="3.2"> +<class name="InputEventScreenTouch" inherits="InputEvent" version="4.0"> <brief_description> Input event type for screen touch events. (only available on mobile devices) diff --git a/doc/classes/InputEventWithModifiers.xml b/doc/classes/InputEventWithModifiers.xml index 9b31dd4639..63465ad28c 100644 --- a/doc/classes/InputEventWithModifiers.xml +++ b/doc/classes/InputEventWithModifiers.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputEventWithModifiers" inherits="InputEvent" category="Core" version="3.2"> +<class name="InputEventWithModifiers" inherits="InputEvent" version="4.0"> <brief_description> Base class for keys events with modifiers. </brief_description> diff --git a/doc/classes/InputMap.xml b/doc/classes/InputMap.xml index 5b83f943cf..aa3400dd97 100644 --- a/doc/classes/InputMap.xml +++ b/doc/classes/InputMap.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InputMap" inherits="Object" category="Core" version="3.2"> +<class name="InputMap" inherits="Object" version="4.0"> <brief_description> Singleton that manages [InputEventAction]. </brief_description> diff --git a/doc/classes/InstancePlaceholder.xml b/doc/classes/InstancePlaceholder.xml index 4b98166ef2..c1d920c2c1 100644 --- a/doc/classes/InstancePlaceholder.xml +++ b/doc/classes/InstancePlaceholder.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InstancePlaceholder" inherits="Node" category="Core" version="3.2"> +<class name="InstancePlaceholder" inherits="Node" version="4.0"> <brief_description> Placeholder for the root [Node] of a [PackedScene]. </brief_description> diff --git a/doc/classes/InterpolatedCamera.xml b/doc/classes/InterpolatedCamera.xml index ca3a5d0733..66df7e9531 100644 --- a/doc/classes/InterpolatedCamera.xml +++ b/doc/classes/InterpolatedCamera.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="InterpolatedCamera" inherits="Camera" category="Core" version="3.2"> +<class name="InterpolatedCamera" inherits="Camera" version="4.0"> <brief_description> Camera which moves toward another node. </brief_description> diff --git a/doc/classes/ItemList.xml b/doc/classes/ItemList.xml index 51d13627ad..006066dea3 100644 --- a/doc/classes/ItemList.xml +++ b/doc/classes/ItemList.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ItemList" inherits="Control" category="Core" version="3.2"> +<class name="ItemList" inherits="Control" version="4.0"> <brief_description> Control that provides a list of selectable items (and/or icons) in a single column, or optionally in multiple columns. </brief_description> diff --git a/doc/classes/JSON.xml b/doc/classes/JSON.xml index e834f5cb39..7bd2edcb1c 100644 --- a/doc/classes/JSON.xml +++ b/doc/classes/JSON.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="JSON" inherits="Object" category="Core" version="3.2"> +<class name="JSON" inherits="Object" version="4.0"> <brief_description> Helper class for parsing JSON data. </brief_description> diff --git a/doc/classes/JSONParseResult.xml b/doc/classes/JSONParseResult.xml index 01cffe6262..4444e08593 100644 --- a/doc/classes/JSONParseResult.xml +++ b/doc/classes/JSONParseResult.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="JSONParseResult" inherits="Reference" category="Core" version="3.2"> +<class name="JSONParseResult" inherits="Reference" version="4.0"> <brief_description> Data class wrapper for decoded JSON. </brief_description> diff --git a/doc/classes/JSONRPC.xml b/doc/classes/JSONRPC.xml index 10d9e5943e..1e74159f58 100644 --- a/doc/classes/JSONRPC.xml +++ b/doc/classes/JSONRPC.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="JSONRPC" inherits="Object" category="Core" version="3.2"> +<class name="JSONRPC" inherits="Object" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/JavaClass.xml b/doc/classes/JavaClass.xml new file mode 100644 index 0000000000..69b7a9b718 --- /dev/null +++ b/doc/classes/JavaClass.xml @@ -0,0 +1,13 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="JavaClass" inherits="Reference" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + </methods> + <constants> + </constants> +</class> diff --git a/doc/classes/JavaClassWrapper.xml b/doc/classes/JavaClassWrapper.xml new file mode 100644 index 0000000000..7bad336af9 --- /dev/null +++ b/doc/classes/JavaClassWrapper.xml @@ -0,0 +1,21 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<class name="JavaClassWrapper" inherits="Object" version="4.0"> + <brief_description> + </brief_description> + <description> + </description> + <tutorials> + </tutorials> + <methods> + <method name="wrap"> + <return type="JavaClass"> + </return> + <argument index="0" name="name" type="String"> + </argument> + <description> + </description> + </method> + </methods> + <constants> + </constants> +</class> diff --git a/doc/classes/JavaScript.xml b/doc/classes/JavaScript.xml index 7737001a6c..68f6c32a53 100644 --- a/doc/classes/JavaScript.xml +++ b/doc/classes/JavaScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="JavaScript" inherits="Object" category="Core" version="3.2"> +<class name="JavaScript" inherits="Object" version="4.0"> <brief_description> Singleton that connects the engine with the browser's JavaScript context in HTML5 export. </brief_description> diff --git a/doc/classes/Joint.xml b/doc/classes/Joint.xml index fe50cdac10..34da997292 100644 --- a/doc/classes/Joint.xml +++ b/doc/classes/Joint.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Joint" inherits="Spatial" category="Core" version="3.2"> +<class name="Joint" inherits="Spatial" version="4.0"> <brief_description> Base class for all 3D joints. </brief_description> diff --git a/doc/classes/Joint2D.xml b/doc/classes/Joint2D.xml index 63d083d470..fb0e184c26 100644 --- a/doc/classes/Joint2D.xml +++ b/doc/classes/Joint2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Joint2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Joint2D" inherits="Node2D" version="4.0"> <brief_description> Base node for all joint constraints in 2D physics. </brief_description> diff --git a/doc/classes/KinematicBody.xml b/doc/classes/KinematicBody.xml index f796b15307..2cf49f417c 100644 --- a/doc/classes/KinematicBody.xml +++ b/doc/classes/KinematicBody.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="KinematicBody" inherits="PhysicsBody" category="Core" version="3.2"> +<class name="KinematicBody" inherits="PhysicsBody" version="4.0"> <brief_description> Kinematic body 3D node. </brief_description> @@ -25,14 +25,14 @@ <return type="Vector3"> </return> <description> - Returns the normal vector of the floor. + Returns the surface normal of the floor at the last collision point. Only valid after calling [method move_and_slide] or [method move_and_slide_with_snap] and when [method is_on_floor] returns [code]true[/code]. </description> </method> <method name="get_floor_velocity" qualifiers="const"> <return type="Vector3"> </return> <description> - Returns the velocity of the floor. Only updates when calling [method move_and_slide]. + Returns the linear velocity of the floor at the last collision point. Only valid after calling [method move_and_slide] or [method move_and_slide_with_snap] and when [method is_on_floor] returns [code]true[/code]. </description> </method> <method name="get_slide_collision"> @@ -106,7 +106,7 @@ <description> Moves the body along a vector. If the body collides with another, it will slide along the other body rather than stop immediately. If the other body is a [KinematicBody] or [RigidBody], it will also be affected by the motion of the other body. You can use this to make moving or rotating platforms, or to make nodes push other nodes. [code]linear_velocity[/code] is the velocity vector (typically meters per second). Unlike in [method move_and_collide], you should [i]not[/i] multiply it by [code]delta[/code] — the physics engine handles applying the velocity. - [code]floor_normal[/code] is the up direction, used to determine what is a wall and what is a floor or a ceiling. If set to the default value of [code]Vector3(0, 0, 0)[/code], everything is considered a wall. This is useful for topdown games. + [code]up_direction[/code] is the up direction, used to determine what is a wall and what is a floor or a ceiling. If set to the default value of [code]Vector3(0, 0, 0)[/code], everything is considered a wall. If [code]stop_on_slope[/code] is [code]true[/code], body will not slide on slopes if you include gravity in [code]linear_velocity[/code]. If the body collides, it will change direction a maximum of [code]max_slides[/code] times before it stops. [code]floor_max_angle[/code] is the maximum angle (in radians) where a slope is still considered a floor (or a ceiling), rather than a wall. The default value equals 45 degrees. @@ -121,7 +121,7 @@ </argument> <argument index="1" name="snap" type="Vector3"> </argument> - <argument index="2" name="floor_normal" type="Vector3" default="Vector3( 0, 0, 0 )"> + <argument index="2" name="up_direction" type="Vector3" default="Vector3( 0, 0, 0 )"> </argument> <argument index="3" name="stop_on_slope" type="bool" default="false"> </argument> diff --git a/doc/classes/KinematicBody2D.xml b/doc/classes/KinematicBody2D.xml index 1de75cd71b..58d7b1f831 100644 --- a/doc/classes/KinematicBody2D.xml +++ b/doc/classes/KinematicBody2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="KinematicBody2D" inherits="PhysicsBody2D" category="Core" version="3.2"> +<class name="KinematicBody2D" inherits="PhysicsBody2D" version="4.0"> <brief_description> Kinematic body 2D node. </brief_description> @@ -17,14 +17,14 @@ <return type="Vector2"> </return> <description> - Returns the normal vector of the floor. + Returns the surface normal of the floor at the last collision point. Only valid after calling [method move_and_slide] or [method move_and_slide_with_snap] and when [method is_on_floor] returns [code]true[/code]. </description> </method> <method name="get_floor_velocity" qualifiers="const"> <return type="Vector2"> </return> <description> - Returns the velocity of the floor. Only updates when calling [method move_and_slide]. + Returns the linear velocity of the floor at the last collision point. Only valid after calling [method move_and_slide] or [method move_and_slide_with_snap] and when [method is_on_floor] returns [code]true[/code]. </description> </method> <method name="get_slide_collision"> @@ -91,7 +91,7 @@ </return> <argument index="0" name="linear_velocity" type="Vector2"> </argument> - <argument index="1" name="floor_normal" type="Vector2" default="Vector2( 0, 0 )"> + <argument index="1" name="up_direction" type="Vector2" default="Vector2( 0, 0 )"> </argument> <argument index="2" name="stop_on_slope" type="bool" default="false"> </argument> @@ -104,7 +104,7 @@ <description> Moves the body along a vector. If the body collides with another, it will slide along the other body rather than stop immediately. If the other body is a [KinematicBody2D] or [RigidBody2D], it will also be affected by the motion of the other body. You can use this to make moving or rotating platforms, or to make nodes push other nodes. [code]linear_velocity[/code] is the velocity vector in pixels per second. Unlike in [method move_and_collide], you should [i]not[/i] multiply it by [code]delta[/code] — the physics engine handles applying the velocity. - [code]floor_normal[/code] is the up direction, used to determine what is a wall and what is a floor or a ceiling. If set to the default value of [code]Vector2(0, 0)[/code], everything is considered a wall. This is useful for topdown games. + [code]up_direction[/code] is the up direction, used to determine what is a wall and what is a floor or a ceiling. If set to the default value of [code]Vector2(0, 0)[/code], everything is considered a wall. This is useful for topdown games. If [code]stop_on_slope[/code] is [code]true[/code], body will not slide on slopes when you include gravity in [code]linear_velocity[/code] and the body is standing still. If the body collides, it will change direction a maximum of [code]max_slides[/code] times before it stops. [code]floor_max_angle[/code] is the maximum angle (in radians) where a slope is still considered a floor (or a ceiling), rather than a wall. The default value equals 45 degrees. @@ -119,7 +119,7 @@ </argument> <argument index="1" name="snap" type="Vector2"> </argument> - <argument index="2" name="floor_normal" type="Vector2" default="Vector2( 0, 0 )"> + <argument index="2" name="up_direction" type="Vector2" default="Vector2( 0, 0 )"> </argument> <argument index="3" name="stop_on_slope" type="bool" default="false"> </argument> diff --git a/doc/classes/KinematicCollision.xml b/doc/classes/KinematicCollision.xml index 46e4176e9f..858a1e69c0 100644 --- a/doc/classes/KinematicCollision.xml +++ b/doc/classes/KinematicCollision.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="KinematicCollision" inherits="Reference" category="Core" version="3.2"> +<class name="KinematicCollision" inherits="Reference" version="4.0"> <brief_description> Collision data for [KinematicBody] collisions. </brief_description> @@ -37,7 +37,7 @@ The colliding body's shape's normal at the point of collision. </member> <member name="position" type="Vector3" setter="" getter="get_position" default="Vector3( 0, 0, 0 )"> - The point of collision. + The point of collision, in global coordinates. </member> <member name="remainder" type="Vector3" setter="" getter="get_remainder" default="Vector3( 0, 0, 0 )"> The moving object's remaining movement vector. diff --git a/doc/classes/KinematicCollision2D.xml b/doc/classes/KinematicCollision2D.xml index 4c9337f82d..ec6e16e25a 100644 --- a/doc/classes/KinematicCollision2D.xml +++ b/doc/classes/KinematicCollision2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="KinematicCollision2D" inherits="Reference" category="Core" version="3.2"> +<class name="KinematicCollision2D" inherits="Reference" version="4.0"> <brief_description> Collision data for [KinematicBody2D] collisions. </brief_description> @@ -37,7 +37,7 @@ The colliding body's shape's normal at the point of collision. </member> <member name="position" type="Vector2" setter="" getter="get_position" default="Vector2( 0, 0 )"> - The point of collision. + The point of collision, in global coordinates. </member> <member name="remainder" type="Vector2" setter="" getter="get_remainder" default="Vector2( 0, 0 )"> The moving object's remaining movement vector. diff --git a/doc/classes/Label.xml b/doc/classes/Label.xml index 9222611090..263fb6c022 100644 --- a/doc/classes/Label.xml +++ b/doc/classes/Label.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Label" inherits="Control" category="Core" version="3.2"> +<class name="Label" inherits="Control" version="4.0"> <brief_description> Displays plain text in a line or wrapped inside a rectangle. For formatted text, use [RichTextLabel]. </brief_description> @@ -101,22 +101,31 @@ </constants> <theme_items> <theme_item name="font" type="Font"> + [Font] used for the [Label]'s text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 1, 1, 1, 1 )"> + Default text [Color] of the [Label]. </theme_item> <theme_item name="font_color_shadow" type="Color" default="Color( 0, 0, 0, 0 )"> + [Color] of the text's shadow effect. </theme_item> <theme_item name="font_outline_modulate" type="Color" default="Color( 1, 1, 1, 1 )"> + The tint of [Font]'s outline. See [member DynamicFont.outline_color]. </theme_item> <theme_item name="line_spacing" type="int" default="3"> + Vertical space between lines in multiline [Label]. </theme_item> <theme_item name="normal" type="StyleBox"> + Background [StyleBox] for the [Label]. </theme_item> <theme_item name="shadow_as_outline" type="int" default="0"> + Boolean value. If set to 1 ([code]true[/code]), the shadow will be displayed around the whole text as an outline. </theme_item> <theme_item name="shadow_offset_x" type="int" default="1"> + The horizontal offset of the text's shadow. </theme_item> <theme_item name="shadow_offset_y" type="int" default="1"> + The vertical offset of the text's shadow. </theme_item> </theme_items> </class> diff --git a/doc/classes/LargeTexture.xml b/doc/classes/LargeTexture.xml index 4dbda34a46..ab39462870 100644 --- a/doc/classes/LargeTexture.xml +++ b/doc/classes/LargeTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="LargeTexture" inherits="Texture" category="Core" version="3.2"> +<class name="LargeTexture" inherits="Texture" version="4.0"> <brief_description> A [Texture] capable of storing many smaller textures with offsets. </brief_description> diff --git a/doc/classes/Light.xml b/doc/classes/Light.xml index 6ef7c2652d..763f3b4b41 100644 --- a/doc/classes/Light.xml +++ b/doc/classes/Light.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Light" inherits="VisualInstance" category="Core" version="3.2"> +<class name="Light" inherits="VisualInstance" version="4.0"> <brief_description> Provides a base class for different kinds of light nodes. </brief_description> @@ -16,6 +16,7 @@ <argument index="0" name="param" type="int" enum="Light.Param"> </argument> <description> + Returns the value of the specified [enum Light.Param] parameter. </description> </method> <method name="set_param"> @@ -26,6 +27,7 @@ <argument index="1" name="value" type="float"> </argument> <description> + Sets the value of the specified [enum Light.Param] parameter. </description> </method> </methods> @@ -67,38 +69,54 @@ If [code]true[/code], the light will cast shadows. </member> <member name="shadow_reverse_cull_face" type="bool" setter="set_shadow_reverse_cull_face" getter="get_shadow_reverse_cull_face" default="false"> + If [code]true[/code], reverses the backface culling of the mesh. This can be useful when you have a flat mesh that has a light behind it. If you need to cast a shadow on both sides of the mesh, set the mesh to use double-sided shadows with [constant GeometryInstance.SHADOW_CASTING_SETTING_DOUBLE_SIDED]. </member> </members> <constants> <constant name="PARAM_ENERGY" value="0" enum="Param"> + Constant for accessing [member light_energy]. </constant> <constant name="PARAM_INDIRECT_ENERGY" value="1" enum="Param"> + Constant for accessing [member light_indirect_energy]. </constant> <constant name="PARAM_SPECULAR" value="2" enum="Param"> + Constant for accessing [member light_specular]. </constant> <constant name="PARAM_RANGE" value="3" enum="Param"> + Constant for accessing [member OmniLight.omni_range] or [member SpotLight.spot_range]. </constant> <constant name="PARAM_ATTENUATION" value="4" enum="Param"> + Constant for accessing [member OmniLight.omni_attenuation] or [member SpotLight.spot_attenuation]. </constant> <constant name="PARAM_SPOT_ANGLE" value="5" enum="Param"> + Constant for accessing [member SpotLight.spot_angle]. </constant> <constant name="PARAM_SPOT_ATTENUATION" value="6" enum="Param"> + Constant for accessing [member SpotLight.spot_angle_attenuation]. </constant> <constant name="PARAM_CONTACT_SHADOW_SIZE" value="7" enum="Param"> + Constant for accessing [member shadow_contact]. </constant> <constant name="PARAM_SHADOW_MAX_DISTANCE" value="8" enum="Param"> + Constant for accessing [member DirectionalLight.directional_shadow_max_distance]. </constant> <constant name="PARAM_SHADOW_SPLIT_1_OFFSET" value="9" enum="Param"> + Constant for accessing [member DirectionalLight.directional_shadow_split_1]. </constant> <constant name="PARAM_SHADOW_SPLIT_2_OFFSET" value="10" enum="Param"> + Constant for accessing [member DirectionalLight.directional_shadow_split_2]. </constant> <constant name="PARAM_SHADOW_SPLIT_3_OFFSET" value="11" enum="Param"> + Constant for accessing [member DirectionalLight.directional_shadow_split_3]. </constant> <constant name="PARAM_SHADOW_NORMAL_BIAS" value="12" enum="Param"> + Constant for accessing [member DirectionalLight.directional_shadow_normal_bias]. </constant> <constant name="PARAM_SHADOW_BIAS" value="13" enum="Param"> + Constant for accessing [member shadow_bias]. </constant> <constant name="PARAM_SHADOW_BIAS_SPLIT_SCALE" value="14" enum="Param"> + Constant for accessing [member DirectionalLight.directional_shadow_bias_split_scale]. </constant> <constant name="PARAM_MAX" value="15" enum="Param"> Represents the size of the [enum Param] enum. diff --git a/doc/classes/Light2D.xml b/doc/classes/Light2D.xml index cdc0270269..5f3ad1b865 100644 --- a/doc/classes/Light2D.xml +++ b/doc/classes/Light2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Light2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Light2D" inherits="Node2D" version="4.0"> <brief_description> Casts light in a 2D environment. </brief_description> @@ -8,7 +8,7 @@ [b]Note:[/b] Light2D can also be used as a mask. </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/2d/2d_lights_and_shadows.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/2d/2d_lights_and_shadows.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/LightOccluder2D.xml b/doc/classes/LightOccluder2D.xml index c7d52e6ef4..a02f7a0f75 100644 --- a/doc/classes/LightOccluder2D.xml +++ b/doc/classes/LightOccluder2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="LightOccluder2D" inherits="Node2D" category="Core" version="3.2"> +<class name="LightOccluder2D" inherits="Node2D" version="4.0"> <brief_description> Occludes light cast by a Light2D, casting shadows. </brief_description> @@ -7,7 +7,7 @@ Occludes light cast by a Light2D, casting shadows. The LightOccluder2D must be provided with an [OccluderPolygon2D] in order for the shadow to be computed. </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/2d/2d_lights_and_shadows.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/2d/2d_lights_and_shadows.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/Line2D.xml b/doc/classes/Line2D.xml index 9eaf70711e..b5983e00b9 100644 --- a/doc/classes/Line2D.xml +++ b/doc/classes/Line2D.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Line2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Line2D" inherits="Node2D" version="4.0"> <brief_description> A 2D line. </brief_description> <description> A line through several points in 2D space. + [b]Note:[/b] By default, Godot can only draw up to 4,096 polygon points at a time. To increase this limit, open the Project Settings and increase [member ProjectSettings.rendering/limits/buffers/canvas_polygon_buffer_size_kb] and [member ProjectSettings.rendering/limits/buffers/canvas_polygon_index_buffer_size_kb]. </description> <tutorials> </tutorials> diff --git a/doc/classes/LineEdit.xml b/doc/classes/LineEdit.xml index 31cfc15649..512401d2de 100644 --- a/doc/classes/LineEdit.xml +++ b/doc/classes/LineEdit.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="LineEdit" inherits="Control" category="Core" version="3.2"> +<class name="LineEdit" inherits="Control" version="4.0"> <brief_description> Control that provides single-line string editing. </brief_description> <description> - LineEdit provides a single-line string editor, used for text fields. It features many built-in shortcuts which will always be available: + LineEdit provides a single-line string editor, used for text fields. + It features many built-in shortcuts which will always be available ([code]Ctrl[/code] here maps to [code]Command[/code] on macOS): - Ctrl + C: Copy - Ctrl + X: Cut - Ctrl + V or Ctrl + Y: Paste/"yank" @@ -14,6 +15,15 @@ - Ctrl + K: Delete text from the cursor position to the end of the line - Ctrl + A: Select all text - Up/Down arrow: Move the cursor to the beginning/end of the line + On macOS, some extra keyboard shortcuts are available: + - Ctrl + F: Like the right arrow key, move the cursor one character right + - Ctrl + B: Like the left arrow key, move the cursor one character left + - Ctrl + P: Like the up arrow key, move the cursor to the previous line + - Ctrl + N: Like the down arrow key, move the cursor to the next line + - Ctrl + D: Like the Delete key, delete the character on the right side of cursor + - Ctrl + H: Like the Backspace key, delete the character on the left side of the cursor + - Command + Left arrow: Like the Home key, move the cursor to the beginning of the line + - Command + Right arrow: Like the End key, move the cursor to the end of the line </description> <tutorials> </tutorials> @@ -68,9 +78,9 @@ Selects characters inside [LineEdit] between [code]from[/code] and [code]to[/code]. By default, [code]from[/code] is at the beginning and [code]to[/code] at the end. [codeblock] text = "Welcome" - select() # Will select "Welcome" - select(4) # Will select "ome" - select(2, 5) # Will select "lco" + select() # Will select "Welcome". + select(4) # Will select "ome". + select(2, 5) # Will select "lco". [/codeblock] </description> </method> @@ -135,6 +145,7 @@ </member> <member name="text" type="String" setter="set_text" getter="get_text" default=""""> String value of the [LineEdit]. + [b]Note:[/b] Changing text using this property won't emit the [signal text_changed] signal. </member> </members> <signals> @@ -226,7 +237,7 @@ Font color when editing is disabled. </theme_item> <theme_item name="minimum_spaces" type="int" default="12"> - Minimum horizontal space for the text (not counting the clear button and content margins). + Minimum horizontal space for the text (not counting the clear button and content margins). This value is measured in count of space characters (i.e. this amount of space characters can be displayed without scrolling). </theme_item> <theme_item name="normal" type="StyleBox"> Default background for the [LineEdit]. diff --git a/doc/classes/LineShape2D.xml b/doc/classes/LineShape2D.xml index fbab1dbe3c..33352b7d98 100644 --- a/doc/classes/LineShape2D.xml +++ b/doc/classes/LineShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="LineShape2D" inherits="Shape2D" category="Core" version="3.2"> +<class name="LineShape2D" inherits="Shape2D" version="4.0"> <brief_description> Line shape for 2D collisions. </brief_description> diff --git a/doc/classes/LinkButton.xml b/doc/classes/LinkButton.xml index af4c255b92..13d3355da5 100644 --- a/doc/classes/LinkButton.xml +++ b/doc/classes/LinkButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="LinkButton" inherits="BaseButton" category="Core" version="3.2"> +<class name="LinkButton" inherits="BaseButton" version="4.0"> <brief_description> Simple button used to represent a link to some resource. </brief_description> @@ -15,8 +15,10 @@ <member name="focus_mode" type="int" setter="set_focus_mode" getter="get_focus_mode" override="true" enum="Control.FocusMode" default="0" /> <member name="mouse_default_cursor_shape" type="int" setter="set_default_cursor_shape" getter="get_default_cursor_shape" override="true" enum="Control.CursorShape" default="2" /> <member name="text" type="String" setter="set_text" getter="get_text" default=""""> + The button's text that will be displayed inside the button's area. </member> <member name="underline" type="int" setter="set_underline_mode" getter="get_underline_mode" enum="LinkButton.UnderlineMode" default="0"> + Determines when to show the underline. See [enum UnderlineMode] for options. </member> </members> <constants> @@ -32,16 +34,22 @@ </constants> <theme_items> <theme_item name="focus" type="StyleBox"> + [StyleBox] used when the [LinkButton] is focused. It is displayed over the current [StyleBox], so using [StyleBoxEmpty] will just disable the focus visual effect. </theme_item> <theme_item name="font" type="Font"> + [Font] of the [LinkButton]'s text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> + Default text [Color] of the [LinkButton]. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 0.94, 0.94, 0.94, 1 )"> + Text [Color] used when the [LinkButton] is being hovered. </theme_item> <theme_item name="font_color_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + Text [Color] used when the [LinkButton] is being pressed. </theme_item> <theme_item name="underline_spacing" type="int" default="2"> + The vertical space between the baseline of text and the underline. </theme_item> </theme_items> </class> diff --git a/doc/classes/Listener.xml b/doc/classes/Listener.xml index ae8c38198f..72bbfa29d4 100644 --- a/doc/classes/Listener.xml +++ b/doc/classes/Listener.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Listener" inherits="Spatial" category="Core" version="3.2"> +<class name="Listener" inherits="Spatial" version="4.0"> <brief_description> Overrides the location sounds are heard from. </brief_description> diff --git a/doc/classes/MainLoop.xml b/doc/classes/MainLoop.xml index d5ca39e09a..2ae7eacdb6 100644 --- a/doc/classes/MainLoop.xml +++ b/doc/classes/MainLoop.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MainLoop" inherits="Object" category="Core" version="3.2"> +<class name="MainLoop" inherits="Object" version="4.0"> <brief_description> Abstract base class for the game's main loop. </brief_description> @@ -69,6 +69,7 @@ <argument index="1" name="meta" type="Variant"> </argument> <description> + Called when the user performs an action in the system global menu (e.g. the Mac OS menu bar). </description> </method> <method name="_idle" qualifiers="virtual"> diff --git a/doc/classes/MarginContainer.xml b/doc/classes/MarginContainer.xml index 08e8098a75..fb5f437239 100644 --- a/doc/classes/MarginContainer.xml +++ b/doc/classes/MarginContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MarginContainer" inherits="Container" category="Core" version="3.2"> +<class name="MarginContainer" inherits="Container" version="4.0"> <brief_description> Simple margin container. </brief_description> diff --git a/doc/classes/Marshalls.xml b/doc/classes/Marshalls.xml index 083a3163ce..f9ca391f1c 100644 --- a/doc/classes/Marshalls.xml +++ b/doc/classes/Marshalls.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Marshalls" inherits="Reference" category="Core" version="3.2"> +<class name="Marshalls" inherits="Reference" version="4.0"> <brief_description> Data transformation (marshalling) and encoding helpers. </brief_description> diff --git a/doc/classes/Material.xml b/doc/classes/Material.xml index f584c5207a..ba74be330e 100644 --- a/doc/classes/Material.xml +++ b/doc/classes/Material.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Material" inherits="Resource" category="Core" version="3.2"> +<class name="Material" inherits="Resource" version="4.0"> <brief_description> Abstract base [Resource] for coloring and shading geometry. </brief_description> @@ -12,8 +12,12 @@ </methods> <members> <member name="next_pass" type="Material" setter="set_next_pass" getter="get_next_pass"> + Sets the [Material] to be used for the next pass. This renders the object again using a different material. + [b]Note:[/b] only applies to [SpatialMaterial]s and [ShaderMaterial]s with type "Spatial". </member> <member name="render_priority" type="int" setter="set_render_priority" getter="get_render_priority" default="0"> + Sets the render priority for transparent objects in 3D scenes. Higher priority objects will be sorted in front of lower priority objects. + [b]Note:[/b] this only applies to sorting of transparent objects. This will not impact how transparent objects are sorted relative to opaque objects. This is because opaque objects are sorted based on depth, while transparent objects are sorted from back to front (subject to priority). </member> </members> <constants> diff --git a/doc/classes/MenuButton.xml b/doc/classes/MenuButton.xml index 52fb4b9ca1..6ec9d60df4 100644 --- a/doc/classes/MenuButton.xml +++ b/doc/classes/MenuButton.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MenuButton" inherits="Button" category="Core" version="3.2"> +<class name="MenuButton" inherits="Button" version="4.0"> <brief_description> Special button that brings up a [PopupMenu] when clicked. </brief_description> <description> - Special button that brings up a [PopupMenu] when clicked. That's pretty much all it does, as it's just a helper class when building GUIs. + Special button that brings up a [PopupMenu] when clicked. + New items can be created inside this [PopupMenu] using [code]get_popup().add_item("My Item Name")[/code]. You can also create them directly from the editor. To do so, select the [MenuButton] node, then in the toolbar at the top of the 2D editor, click [b]Items[/b] then click [b]Add[/b] in the popup. You will be able to give each items new properties. </description> <tutorials> </tutorials> @@ -22,6 +23,7 @@ <argument index="0" name="disabled" type="bool"> </argument> <description> + If [code]true[/code], shortcuts are disabled and cannot be used to trigger the button. </description> </method> </methods> @@ -31,7 +33,7 @@ <member name="flat" type="bool" setter="set_flat" getter="is_flat" override="true" default="true" /> <member name="focus_mode" type="int" setter="set_focus_mode" getter="get_focus_mode" override="true" enum="Control.FocusMode" default="0" /> <member name="switch_on_hover" type="bool" setter="set_switch_on_hover" getter="is_switch_on_hover" default="false"> - If [code]true[/code], when the cursor hovers above another MenuButton within the same parent which also has [code]switch_on_hover[/code] enabled, it will close the current MenuButton and open the other one. + If [code]true[/code], when the cursor hovers above another [MenuButton] within the same parent which also has [code]switch_on_hover[/code] enabled, it will close the current [MenuButton] and open the other one. </member> <member name="toggle_mode" type="bool" setter="set_toggle_mode" getter="is_toggle_mode" override="true" default="true" /> </members> @@ -46,26 +48,37 @@ </constants> <theme_items> <theme_item name="disabled" type="StyleBox"> + [StyleBox] used when the [MenuButton] is disabled. </theme_item> <theme_item name="focus" type="StyleBox"> + [StyleBox] used when the [MenuButton] is focused. It is displayed over the current [StyleBox], so using [StyleBoxEmpty] will just disable the focus visual effect. </theme_item> <theme_item name="font" type="Font"> + [Font] of the [MenuButton]'s text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> + Default text [Color] of the [MenuButton]. </theme_item> <theme_item name="font_color_disabled" type="Color" default="Color( 1, 1, 1, 0.3 )"> + Text [Color] used when the [MenuButton] is disabled. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 0.94, 0.94, 0.94, 1 )"> + Text [Color] used when the [MenuButton] is being hovered. </theme_item> <theme_item name="font_color_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + Text [Color] used when the [MenuButton] is being pressed. </theme_item> <theme_item name="hover" type="StyleBox"> + [StyleBox] used when the [MenuButton] is being hovered. </theme_item> <theme_item name="hseparation" type="int" default="3"> + The horizontal space between [MenuButton]'s icon and text. </theme_item> <theme_item name="normal" type="StyleBox"> + Default [StyleBox] for the [MenuButton]. </theme_item> <theme_item name="pressed" type="StyleBox"> + [StyleBox] used when the [MenuButton] is being pressed. </theme_item> </theme_items> </class> diff --git a/doc/classes/Mesh.xml b/doc/classes/Mesh.xml index d4804930e1..b2d979239c 100644 --- a/doc/classes/Mesh.xml +++ b/doc/classes/Mesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Mesh" inherits="Resource" category="Core" version="3.2"> +<class name="Mesh" inherits="Resource" version="4.0"> <brief_description> A [Resource] that contains vertex array-based geometry. </brief_description> @@ -103,6 +103,7 @@ </methods> <members> <member name="lightmap_size_hint" type="Vector2" setter="set_lightmap_size_hint" getter="get_lightmap_size_hint" default="Vector2( 0, 0 )"> + Sets a hint to be used for lightmap resolution in [BakedLightmap]. Overrides [member BakedLightmap.bake_default_texels_per_unit]. </member> </members> <constants> @@ -128,52 +129,76 @@ Render array as triangle fans. </constant> <constant name="BLEND_SHAPE_MODE_NORMALIZED" value="0" enum="BlendShapeMode"> + Blend shapes are normalized. </constant> <constant name="BLEND_SHAPE_MODE_RELATIVE" value="1" enum="BlendShapeMode"> + Blend shapes are relative to base weight. </constant> <constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat"> + Mesh array contains vertices. All meshes require a vertex array so this should always be present. </constant> <constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat"> + Mesh array contains normals. </constant> <constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat"> + Mesh array contains tangents. </constant> <constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat"> + Mesh array contains colors. </constant> <constant name="ARRAY_FORMAT_TEX_UV" value="16" enum="ArrayFormat"> + Mesh array contains UVs. </constant> <constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat"> + Mesh array contains second UV. </constant> <constant name="ARRAY_FORMAT_BONES" value="64" enum="ArrayFormat"> + Mesh array contains bones. </constant> <constant name="ARRAY_FORMAT_WEIGHTS" value="128" enum="ArrayFormat"> + Mesh array contains bone weights. </constant> <constant name="ARRAY_FORMAT_INDEX" value="256" enum="ArrayFormat"> + Mesh array uses indices. </constant> <constant name="ARRAY_COMPRESS_BASE" value="9" enum="ArrayFormat"> + Used internally to calculate other [code]ARRAY_COMPRESS_*[/code] enum values. Do not use. </constant> <constant name="ARRAY_COMPRESS_VERTEX" value="512" enum="ArrayFormat"> + Flag used to mark a compressed (half float) vertex array. </constant> <constant name="ARRAY_COMPRESS_NORMAL" value="1024" enum="ArrayFormat"> + Flag used to mark a compressed (half float) normal array. </constant> <constant name="ARRAY_COMPRESS_TANGENT" value="2048" enum="ArrayFormat"> + Flag used to mark a compressed (half float) tangent array. </constant> <constant name="ARRAY_COMPRESS_COLOR" value="4096" enum="ArrayFormat"> + Flag used to mark a compressed (half float) color array. </constant> <constant name="ARRAY_COMPRESS_TEX_UV" value="8192" enum="ArrayFormat"> + Flag used to mark a compressed (half float) UV coordinates array. </constant> <constant name="ARRAY_COMPRESS_TEX_UV2" value="16384" enum="ArrayFormat"> + Flag used to mark a compressed (half float) UV coordinates array for the second UV coordinates. </constant> <constant name="ARRAY_COMPRESS_BONES" value="32768" enum="ArrayFormat"> + Flag used to mark a compressed bone array. </constant> <constant name="ARRAY_COMPRESS_WEIGHTS" value="65536" enum="ArrayFormat"> + Flag used to mark a compressed (half float) weight array. </constant> <constant name="ARRAY_COMPRESS_INDEX" value="131072" enum="ArrayFormat"> + Flag used to mark a compressed index array. </constant> <constant name="ARRAY_FLAG_USE_2D_VERTICES" value="262144" enum="ArrayFormat"> + Flag used to mark that the array contains 2D vertices. </constant> <constant name="ARRAY_FLAG_USE_16_BIT_BONES" value="524288" enum="ArrayFormat"> + Flag used to mark that the array uses 16-bit bones instead of 8-bit. </constant> <constant name="ARRAY_COMPRESS_DEFAULT" value="97280" enum="ArrayFormat"> + Used to set flags [constant ARRAY_COMPRESS_VERTEX], [constant ARRAY_COMPRESS_NORMAL], [constant ARRAY_COMPRESS_TANGENT], [constant ARRAY_COMPRESS_COLOR], [constant ARRAY_COMPRESS_TEX_UV], [constant ARRAY_COMPRESS_TEX_UV2] and [constant ARRAY_COMPRESS_WEIGHTS] quickly. </constant> <constant name="ARRAY_VERTEX" value="0" enum="ArrayType"> Array of vertices. diff --git a/doc/classes/MeshDataTool.xml b/doc/classes/MeshDataTool.xml index 22c31306bf..5c6401521a 100644 --- a/doc/classes/MeshDataTool.xml +++ b/doc/classes/MeshDataTool.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MeshDataTool" inherits="Reference" category="Core" version="3.2"> +<class name="MeshDataTool" inherits="Reference" version="4.0"> <brief_description> Helper tool to access and edit [Mesh] data. </brief_description> diff --git a/doc/classes/MeshInstance.xml b/doc/classes/MeshInstance.xml index a4d2bb4295..6123dfa37a 100644 --- a/doc/classes/MeshInstance.xml +++ b/doc/classes/MeshInstance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MeshInstance" inherits="GeometryInstance" category="Core" version="3.2"> +<class name="MeshInstance" inherits="GeometryInstance" version="4.0"> <brief_description> Node that instances meshes into a scenario. </brief_description> @@ -66,6 +66,7 @@ [NodePath] to the [Skeleton] associated with the instance. </member> <member name="skin" type="Skin" setter="set_skin" getter="get_skin"> + Sets the skin to be used by this instance. </member> </members> <constants> diff --git a/doc/classes/MeshInstance2D.xml b/doc/classes/MeshInstance2D.xml index 4b38b9aa96..a14ad1d4cd 100644 --- a/doc/classes/MeshInstance2D.xml +++ b/doc/classes/MeshInstance2D.xml @@ -1,13 +1,13 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MeshInstance2D" inherits="Node2D" category="Core" version="3.2"> +<class name="MeshInstance2D" inherits="Node2D" version="4.0"> <brief_description> Node used for displaying a [Mesh] in 2D. </brief_description> <description> - Node used for displaying a [Mesh] in 2D. Can be constructed from an existing [Sprite] use tool in Toolbar. Select "Sprite" then "Convert to Mesh2D", select settings in popup and press "Create Mesh2D". + Node used for displaying a [Mesh] in 2D. Can be constructed from an existing [Sprite] via a tool in the editor toolbar. Select "Sprite" then "Convert to Mesh2D", select settings in popup and press "Create Mesh2D". </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/2d/2d_meshes.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/2d/2d_meshes.html</link> </tutorials> <methods> </methods> @@ -25,6 +25,7 @@ <signals> <signal name="texture_changed"> <description> + Emitted when the [member texture] is changed. </description> </signal> </signals> diff --git a/doc/classes/MeshLibrary.xml b/doc/classes/MeshLibrary.xml index 49278be44e..95c046398a 100644 --- a/doc/classes/MeshLibrary.xml +++ b/doc/classes/MeshLibrary.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MeshLibrary" inherits="Resource" category="Core" version="3.2"> +<class name="MeshLibrary" inherits="Resource" version="4.0"> <brief_description> Library of meshes. </brief_description> diff --git a/doc/classes/MeshTexture.xml b/doc/classes/MeshTexture.xml index 2c94014879..6e18517ef1 100644 --- a/doc/classes/MeshTexture.xml +++ b/doc/classes/MeshTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MeshTexture" inherits="Texture" category="Core" version="3.2"> +<class name="MeshTexture" inherits="Texture" version="4.0"> <brief_description> Simple texture that uses a mesh to draw itself. </brief_description> diff --git a/doc/classes/MultiMesh.xml b/doc/classes/MultiMesh.xml index ec65f407cd..270ac08178 100644 --- a/doc/classes/MultiMesh.xml +++ b/doc/classes/MultiMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MultiMesh" inherits="Resource" category="Core" version="3.2"> +<class name="MultiMesh" inherits="Resource" version="4.0"> <brief_description> Provides high-performance mesh instancing. </brief_description> @@ -10,8 +10,8 @@ Since instances may have any behavior, the AABB used for visibility must be provided by the user. </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/3d/vertex_animation/animating_thousands_of_fish.html</link> - <link>http://docs.godotengine.org/en/latest/tutorials/optimization/using_multimesh.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/3d/vertex_animation/animating_thousands_of_fish.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/optimization/using_multimesh.html</link> </tutorials> <methods> <method name="get_aabb" qualifiers="const"> diff --git a/doc/classes/MultiMeshInstance.xml b/doc/classes/MultiMeshInstance.xml index 16f16fdc8b..6cbc0a8e04 100644 --- a/doc/classes/MultiMeshInstance.xml +++ b/doc/classes/MultiMeshInstance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MultiMeshInstance" inherits="GeometryInstance" category="Core" version="3.2"> +<class name="MultiMeshInstance" inherits="GeometryInstance" version="4.0"> <brief_description> Node that instances a [MultiMesh]. </brief_description> @@ -8,8 +8,9 @@ This is useful to optimize the rendering of a high amount of instances of a given mesh (for example trees in a forest or grass strands). </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/3d/vertex_animation/animating_thousands_of_fish.html</link> - <link>http://docs.godotengine.org/en/latest/tutorials/3d/using_multi_mesh_instance.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/3d/vertex_animation/animating_thousands_of_fish.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/3d/using_multi_mesh_instance.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/optimization/using_multimesh.html</link> </tutorials> <methods> </methods> diff --git a/doc/classes/MultiMeshInstance2D.xml b/doc/classes/MultiMeshInstance2D.xml index 8509986c3c..5c0e85d3fe 100644 --- a/doc/classes/MultiMeshInstance2D.xml +++ b/doc/classes/MultiMeshInstance2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MultiMeshInstance2D" inherits="Node2D" category="Core" version="3.2"> +<class name="MultiMeshInstance2D" inherits="Node2D" version="4.0"> <brief_description> Node that instances a [MultiMesh] in 2D. </brief_description> @@ -25,6 +25,7 @@ <signals> <signal name="texture_changed"> <description> + Emitted when the [member texture] is changed. </description> </signal> </signals> diff --git a/doc/classes/MultiplayerAPI.xml b/doc/classes/MultiplayerAPI.xml index 9cd3fe7bb4..f34d3c5da4 100644 --- a/doc/classes/MultiplayerAPI.xml +++ b/doc/classes/MultiplayerAPI.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MultiplayerAPI" inherits="Reference" category="Core" version="3.2"> +<class name="MultiplayerAPI" inherits="Reference" version="4.0"> <brief_description> High-level multiplayer API. </brief_description> diff --git a/doc/classes/Mutex.xml b/doc/classes/Mutex.xml index 8a294425e6..2de1f71867 100644 --- a/doc/classes/Mutex.xml +++ b/doc/classes/Mutex.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Mutex" inherits="Reference" category="Core" version="3.2"> +<class name="Mutex" inherits="Reference" version="4.0"> <brief_description> A synchronization mutex (mutual exclusion). </brief_description> diff --git a/doc/classes/Navigation.xml b/doc/classes/Navigation.xml index 58b7d1255e..615ccf6c36 100644 --- a/doc/classes/Navigation.xml +++ b/doc/classes/Navigation.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Navigation" inherits="Spatial" category="Core" version="3.2"> +<class name="Navigation" inherits="Spatial" version="4.0"> <brief_description> Mesh-based navigation and pathfinding node. </brief_description> diff --git a/doc/classes/Navigation2D.xml b/doc/classes/Navigation2D.xml index ea1b992d79..ba15c59238 100644 --- a/doc/classes/Navigation2D.xml +++ b/doc/classes/Navigation2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Navigation2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Navigation2D" inherits="Node2D" version="4.0"> <brief_description> 2D navigation and pathfinding node. </brief_description> diff --git a/doc/classes/NavigationMesh.xml b/doc/classes/NavigationMesh.xml index 6528704bb5..fb3babf4aa 100644 --- a/doc/classes/NavigationMesh.xml +++ b/doc/classes/NavigationMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NavigationMesh" inherits="Resource" category="Core" version="3.2"> +<class name="NavigationMesh" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/NavigationMeshInstance.xml b/doc/classes/NavigationMeshInstance.xml index 2f9cc58aea..a348740fdc 100644 --- a/doc/classes/NavigationMeshInstance.xml +++ b/doc/classes/NavigationMeshInstance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NavigationMeshInstance" inherits="Spatial" category="Core" version="3.2"> +<class name="NavigationMeshInstance" inherits="Spatial" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/NavigationPolygon.xml b/doc/classes/NavigationPolygon.xml index 555f308660..0157a6f3f7 100644 --- a/doc/classes/NavigationPolygon.xml +++ b/doc/classes/NavigationPolygon.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NavigationPolygon" inherits="Resource" category="Core" version="3.2"> +<class name="NavigationPolygon" inherits="Resource" version="4.0"> <brief_description> A node that has methods to draw outlines or use indices of vertices to create navigation polygons. </brief_description> diff --git a/doc/classes/NavigationPolygonInstance.xml b/doc/classes/NavigationPolygonInstance.xml index 83f3386af6..34c6b09859 100644 --- a/doc/classes/NavigationPolygonInstance.xml +++ b/doc/classes/NavigationPolygonInstance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NavigationPolygonInstance" inherits="Node2D" category="Core" version="3.2"> +<class name="NavigationPolygonInstance" inherits="Node2D" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/NetworkedMultiplayerPeer.xml b/doc/classes/NetworkedMultiplayerPeer.xml index 4f212cf392..ff97ea926d 100644 --- a/doc/classes/NetworkedMultiplayerPeer.xml +++ b/doc/classes/NetworkedMultiplayerPeer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NetworkedMultiplayerPeer" inherits="PacketPeer" category="Core" version="3.2"> +<class name="NetworkedMultiplayerPeer" inherits="PacketPeer" version="4.0"> <brief_description> A high-level network interface to simplify multiplayer interactions. </brief_description> diff --git a/doc/classes/Nil.xml b/doc/classes/Nil.xml deleted file mode 100644 index a5c1ade6ed..0000000000 --- a/doc/classes/Nil.xml +++ /dev/null @@ -1,169 +0,0 @@ -<?xml version="1.0" encoding="UTF-8" ?> -<class name="Nil" category="Built-In Types" version="3.2"> - <brief_description> - </brief_description> - <description> - </description> - <tutorials> - </tutorials> - <methods> - <method name="Nil"> - <argument index="0" name="from" type="PoolColorArray"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="PoolVector3Array"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="PoolVector2Array"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="PoolStringArray"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="PoolRealArray"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="PoolIntArray"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="PoolByteArray"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Array"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Dictionary"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Object"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="RID"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="NodePath"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Color"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Transform"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Basis"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="AABB"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Quat"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Plane"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Transform2D"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Vector3"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Rect2"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="Vector2"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="String"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="float"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="int"> - </argument> - <description> - </description> - </method> - <method name="Nil"> - <argument index="0" name="from" type="bool"> - </argument> - <description> - </description> - </method> - </methods> - <constants> - </constants> -</class> diff --git a/doc/classes/NinePatchRect.xml b/doc/classes/NinePatchRect.xml index 8935ac9d94..68326d7e77 100644 --- a/doc/classes/NinePatchRect.xml +++ b/doc/classes/NinePatchRect.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NinePatchRect" inherits="Control" category="Core" version="3.2"> +<class name="NinePatchRect" inherits="Control" version="4.0"> <brief_description> Scalable texture-based frame that tiles the texture's centers and sides, but keeps the corners' original size. Perfect for panels and dialog boxes. </brief_description> @@ -15,6 +15,7 @@ <argument index="0" name="margin" type="int" enum="Margin"> </argument> <description> + Returns the size of the margin identified by the given [enum Margin] constant. </description> </method> <method name="set_patch_margin"> @@ -25,6 +26,7 @@ <argument index="1" name="value" type="int"> </argument> <description> + Sets the size of the margin identified by the given [enum Margin] constant to [code]value[/code] in pixels. </description> </method> </methods> diff --git a/doc/classes/Node.xml b/doc/classes/Node.xml index e3f1165c55..1847954b67 100644 --- a/doc/classes/Node.xml +++ b/doc/classes/Node.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Node" inherits="Object" category="Core" version="3.2"> +<class name="Node" inherits="Object" version="4.0"> <brief_description> Base class for all [i]scene[/i] objects. </brief_description> @@ -33,7 +33,7 @@ </return> <description> Called when the node is about to leave the [SceneTree] (e.g. upon freeing, scene changing, or after calling [method remove_child] in a script). If the node has children, its [method _exit_tree] callback will be called last, after all its children have left the tree. - Corresponds to the [constant NOTIFICATION_EXIT_TREE] notification in [method Object._notification] and signal [signal tree_exiting]. To get notified when the node has already left the active tree, connect to the [signal tree_exited] + Corresponds to the [constant NOTIFICATION_EXIT_TREE] notification in [method Object._notification] and signal [signal tree_exiting]. To get notified when the node has already left the active tree, connect to the [signal tree_exited]. </description> </method> <method name="_get_configuration_warning" qualifiers="virtual"> diff --git a/doc/classes/Node2D.xml b/doc/classes/Node2D.xml index 67e9597781..9f017e9aed 100644 --- a/doc/classes/Node2D.xml +++ b/doc/classes/Node2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Node2D" inherits="CanvasItem" category="Core" version="3.2"> +<class name="Node2D" inherits="CanvasItem" version="4.0"> <brief_description> A 2D game object, inherited by all 2D-related nodes. Has a position, rotation, scale, and Z index. </brief_description> diff --git a/doc/classes/NodePath.xml b/doc/classes/NodePath.xml index 0310068a90..e8ab3e536e 100644 --- a/doc/classes/NodePath.xml +++ b/doc/classes/NodePath.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NodePath" category="Built-In Types" version="3.2"> +<class name="NodePath" version="4.0"> <brief_description> Pre-parsed scene tree path. </brief_description> diff --git a/doc/classes/OS.xml b/doc/classes/OS.xml index 2236c42094..21c8dcd20a 100644 --- a/doc/classes/OS.xml +++ b/doc/classes/OS.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="OS" inherits="Object" category="Core" version="3.2"> +<class name="OS" inherits="Object" version="4.0"> <brief_description> Operating System functions. </brief_description> @@ -95,7 +95,7 @@ </argument> <argument index="1" name="arguments" type="PoolStringArray"> </argument> - <argument index="2" name="blocking" type="bool"> + <argument index="2" name="blocking" type="bool" default="true"> </argument> <argument index="3" name="output" type="Array" default="[ ]"> </argument> @@ -333,6 +333,7 @@ </argument> <description> Returns the given scancode as a string (e.g. Return values: [code]"Escape"[/code], [code]"Shift+Escape"[/code]). + See also [member InputEventKey.scancode] and [method InputEventKey.get_scancode_with_modifiers]. </description> </method> <method name="get_screen_count" qualifiers="const"> @@ -937,8 +938,9 @@ <member name="vsync_enabled" type="bool" setter="set_use_vsync" getter="is_vsync_enabled" default="true"> If [code]true[/code], vertical synchronization (Vsync) is enabled. </member> - <member name="vsync_via_compositor" type="bool" setter="set_vsync_via_compositor" getter="is_vsync_via_compositor_enabled" default="true"> + <member name="vsync_via_compositor" type="bool" setter="set_vsync_via_compositor" getter="is_vsync_via_compositor_enabled" default="false"> If [code]true[/code] and [code]vsync_enabled[/code] is true, the operating system's window compositor will be used for vsync when the compositor is enabled and the game is in windowed mode. + [b]Note:[/b] This option is experimental and meant to alleviate stutter experienced by some users. However, some users have experienced a Vsync framerate halving (e.g. from 60 FPS to 30 FPS) when using it. [b]Note:[/b] This property is only implemented on Windows. </member> <member name="window_borderless" type="bool" setter="set_borderless_window" getter="get_borderless_window" default="false"> diff --git a/doc/classes/Object.xml b/doc/classes/Object.xml index d063bd81e7..858bf5b635 100644 --- a/doc/classes/Object.xml +++ b/doc/classes/Object.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Object" category="Core" version="3.2"> +<class name="Object" version="4.0"> <brief_description> Base class for all non built-in types. </brief_description> @@ -12,8 +12,8 @@ Property membership can be tested directly in GDScript using [code]in[/code]: [codeblock] var n = Node2D.new() - print("position" in n) # Prints "True". - print("other_property" in n) # Prints "False". + print("position" in n) # Prints "True". + print("other_property" in n) # Prints "False". [/codeblock] Objects also receive notifications. Notifications are a simple way to notify the object about different events, so they can all be handled together. See [method _notification]. </description> diff --git a/doc/classes/OccluderPolygon2D.xml b/doc/classes/OccluderPolygon2D.xml index f4fa6ac688..6cfef42204 100644 --- a/doc/classes/OccluderPolygon2D.xml +++ b/doc/classes/OccluderPolygon2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="OccluderPolygon2D" inherits="Resource" category="Core" version="3.2"> +<class name="OccluderPolygon2D" inherits="Resource" version="4.0"> <brief_description> Defines a 2D polygon for LightOccluder2D. </brief_description> diff --git a/doc/classes/OmniLight.xml b/doc/classes/OmniLight.xml index 7189826385..e836dc1758 100644 --- a/doc/classes/OmniLight.xml +++ b/doc/classes/OmniLight.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="OmniLight" inherits="Light" category="Core" version="3.2"> +<class name="OmniLight" inherits="Light" version="4.0"> <brief_description> Omnidirectional light, such as a light bulb or a candle. </brief_description> @@ -33,8 +33,10 @@ Shadows are rendered to a cubemap. Slower than [constant SHADOW_DUAL_PARABOLOID], but higher-quality. </constant> <constant name="SHADOW_DETAIL_VERTICAL" value="0" enum="ShadowDetail"> + Use more detail vertically when computing the shadow. </constant> <constant name="SHADOW_DETAIL_HORIZONTAL" value="1" enum="ShadowDetail"> + Use more detail horizontally when computing the shadow. </constant> </constants> </class> diff --git a/doc/classes/OptionButton.xml b/doc/classes/OptionButton.xml index 0debb988ce..d488e918b9 100644 --- a/doc/classes/OptionButton.xml +++ b/doc/classes/OptionButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="OptionButton" inherits="Button" category="Core" version="3.2"> +<class name="OptionButton" inherits="Button" version="4.0"> <brief_description> Button control that provides selectable options when pressed. </brief_description> @@ -232,30 +232,43 @@ </constants> <theme_items> <theme_item name="arrow" type="Texture"> + The arrow icon to be drawn on the right end of the button. </theme_item> <theme_item name="arrow_margin" type="int" default="2"> + The horizontal space between the arrow icon and the right edge of the button. </theme_item> <theme_item name="disabled" type="StyleBox"> + [StyleBox] used when the [OptionButton] is disabled. </theme_item> <theme_item name="focus" type="StyleBox"> + [StyleBox] used when the [OptionButton] is focused. It is displayed over the current [StyleBox], so using [StyleBoxEmpty] will just disable the focus visual effect. </theme_item> <theme_item name="font" type="Font"> + [Font] of the [OptionButton]'s text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> + Default text [Color] of the [OptionButton]. </theme_item> <theme_item name="font_color_disabled" type="Color" default="Color( 0.9, 0.9, 0.9, 0.2 )"> + Text [Color] used when the [OptionButton] is disabled. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 0.94, 0.94, 0.94, 1 )"> + Text [Color] used when the [OptionButton] is being hovered. </theme_item> <theme_item name="font_color_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + Text [Color] used when the [OptionButton] is being pressed. </theme_item> <theme_item name="hover" type="StyleBox"> + [StyleBox] used when the [OptionButton] is being hovered. </theme_item> <theme_item name="hseparation" type="int" default="2"> + The horizontal space between [OptionButton]'s icon and text. </theme_item> <theme_item name="normal" type="StyleBox"> + Default [StyleBox] for the [OptionButton]. </theme_item> <theme_item name="pressed" type="StyleBox"> + [StyleBox] used when the [OptionButton] is being pressed. </theme_item> </theme_items> </class> diff --git a/doc/classes/PCKPacker.xml b/doc/classes/PCKPacker.xml index e9ff2c0916..314869be49 100644 --- a/doc/classes/PCKPacker.xml +++ b/doc/classes/PCKPacker.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PCKPacker" inherits="Reference" category="Core" version="3.2"> +<class name="PCKPacker" inherits="Reference" version="4.0"> <brief_description> Creates packages that can be loaded into a running project. </brief_description> diff --git a/doc/classes/PHashTranslation.xml b/doc/classes/PHashTranslation.xml index 7c771b6b04..30194e9495 100644 --- a/doc/classes/PHashTranslation.xml +++ b/doc/classes/PHashTranslation.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PHashTranslation" inherits="Translation" category="Core" version="3.2"> +<class name="PHashTranslation" inherits="Translation" version="4.0"> <brief_description> Optimized translation. </brief_description> diff --git a/doc/classes/PackedDataContainer.xml b/doc/classes/PackedDataContainer.xml index fa6a00d65d..79c9fa8d9c 100644 --- a/doc/classes/PackedDataContainer.xml +++ b/doc/classes/PackedDataContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PackedDataContainer" inherits="Resource" category="Core" version="3.2"> +<class name="PackedDataContainer" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/PackedDataContainerRef.xml b/doc/classes/PackedDataContainerRef.xml index 8623ff7843..9e7ed59054 100644 --- a/doc/classes/PackedDataContainerRef.xml +++ b/doc/classes/PackedDataContainerRef.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PackedDataContainerRef" inherits="Reference" category="Core" version="3.2"> +<class name="PackedDataContainerRef" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/PackedScene.xml b/doc/classes/PackedScene.xml index 0400f2704b..d13195bd5e 100644 --- a/doc/classes/PackedScene.xml +++ b/doc/classes/PackedScene.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PackedScene" inherits="Resource" category="Core" version="3.2"> +<class name="PackedScene" inherits="Resource" version="4.0"> <brief_description> An abstraction of a serialized scene. </brief_description> diff --git a/doc/classes/PacketPeer.xml b/doc/classes/PacketPeer.xml index d52bf4e3bb..39da9d1548 100644 --- a/doc/classes/PacketPeer.xml +++ b/doc/classes/PacketPeer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PacketPeer" inherits="Reference" category="Core" version="3.2"> +<class name="PacketPeer" inherits="Reference" version="4.0"> <brief_description> Abstraction and base class for packet-based protocols. </brief_description> @@ -67,6 +67,10 @@ If [code]true[/code], the PacketPeer will allow encoding and decoding of object via [method get_var] and [method put_var]. [b]Warning:[/b] Deserialized objects can contain code which gets executed. Do not use this option if the serialized object comes from untrusted sources to avoid potential security threats such as remote code execution. </member> + <member name="encode_buffer_max_size" type="int" setter="set_encode_buffer_max_size" getter="get_encode_buffer_max_size" default="8388608"> + Maximum buffer size allowed when encoding [Variant]s. Raise this value to support heavier memory allocations. + The [method put_var] method allocates memory on the stack, and the buffer used will grow automatically to the closest power of two to match the size of the [Variant]. If the [Variant] is bigger than [code]encode_buffer_max_size[/code], the method will error out with [constant ERR_OUT_OF_MEMORY]. + </member> </members> <constants> </constants> diff --git a/doc/classes/PacketPeerStream.xml b/doc/classes/PacketPeerStream.xml index 0376fea592..ec1ee175f7 100644 --- a/doc/classes/PacketPeerStream.xml +++ b/doc/classes/PacketPeerStream.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PacketPeerStream" inherits="PacketPeer" category="Core" version="3.2"> +<class name="PacketPeerStream" inherits="PacketPeer" version="4.0"> <brief_description> Wrapper to use a PacketPeer over a StreamPeer. </brief_description> diff --git a/doc/classes/PacketPeerUDP.xml b/doc/classes/PacketPeerUDP.xml index 3dc83ce8b4..81cd341ef7 100644 --- a/doc/classes/PacketPeerUDP.xml +++ b/doc/classes/PacketPeerUDP.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PacketPeerUDP" inherits="PacketPeer" category="Core" version="3.2"> +<class name="PacketPeerUDP" inherits="PacketPeer" version="4.0"> <brief_description> UDP packet peer. </brief_description> diff --git a/doc/classes/Panel.xml b/doc/classes/Panel.xml index c9c3f80e7b..a96871ba28 100644 --- a/doc/classes/Panel.xml +++ b/doc/classes/Panel.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Panel" inherits="Control" category="Core" version="3.2"> +<class name="Panel" inherits="Control" version="4.0"> <brief_description> Provides an opaque background for [Control] children. </brief_description> diff --git a/doc/classes/PanelContainer.xml b/doc/classes/PanelContainer.xml index 64fae6d95c..5863093662 100644 --- a/doc/classes/PanelContainer.xml +++ b/doc/classes/PanelContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PanelContainer" inherits="Container" category="Core" version="3.2"> +<class name="PanelContainer" inherits="Container" version="4.0"> <brief_description> Panel container type. </brief_description> diff --git a/doc/classes/PanoramaSky.xml b/doc/classes/PanoramaSky.xml index 96aefc0623..c1c048f875 100644 --- a/doc/classes/PanoramaSky.xml +++ b/doc/classes/PanoramaSky.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PanoramaSky" inherits="Sky" category="Core" version="3.2"> +<class name="PanoramaSky" inherits="Sky" version="4.0"> <brief_description> A type of [Sky] used to draw a background texture. </brief_description> diff --git a/doc/classes/ParallaxBackground.xml b/doc/classes/ParallaxBackground.xml index d4f3462016..3b730fc4d4 100644 --- a/doc/classes/ParallaxBackground.xml +++ b/doc/classes/ParallaxBackground.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ParallaxBackground" inherits="CanvasLayer" category="Core" version="3.2"> +<class name="ParallaxBackground" inherits="CanvasLayer" version="4.0"> <brief_description> A node used to create a parallax scrolling background. </brief_description> diff --git a/doc/classes/ParallaxLayer.xml b/doc/classes/ParallaxLayer.xml index 75c69cc4b1..105d105731 100644 --- a/doc/classes/ParallaxLayer.xml +++ b/doc/classes/ParallaxLayer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ParallaxLayer" inherits="Node2D" category="Core" version="3.2"> +<class name="ParallaxLayer" inherits="Node2D" version="4.0"> <brief_description> A parallax scrolling layer to be used with [ParallaxBackground]. </brief_description> diff --git a/doc/classes/Particles.xml b/doc/classes/Particles.xml index 2219be5a26..b146678bfc 100644 --- a/doc/classes/Particles.xml +++ b/doc/classes/Particles.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Particles" inherits="GeometryInstance" category="Core" version="3.2"> +<class name="Particles" inherits="GeometryInstance" version="4.0"> <brief_description> 3D particle emitter. </brief_description> @@ -8,7 +8,7 @@ Use the [code]process_material[/code] property to add a [ParticlesMaterial] to configure particle appearance and behavior. Alternatively, you can add a [ShaderMaterial] which will be applied to all particles. </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/3d/vertex_animation/controlling_thousands_of_fish.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/3d/vertex_animation/controlling_thousands_of_fish.html</link> </tutorials> <methods> <method name="capture_aabb" qualifiers="const"> diff --git a/doc/classes/Particles2D.xml b/doc/classes/Particles2D.xml index 100585768d..2a00ec3113 100644 --- a/doc/classes/Particles2D.xml +++ b/doc/classes/Particles2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Particles2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Particles2D" inherits="Node2D" version="4.0"> <brief_description> 2D particle emitter. </brief_description> diff --git a/doc/classes/ParticlesMaterial.xml b/doc/classes/ParticlesMaterial.xml index 187ad1688d..42f0fe1f00 100644 --- a/doc/classes/ParticlesMaterial.xml +++ b/doc/classes/ParticlesMaterial.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ParticlesMaterial" inherits="Material" category="Core" version="3.2"> +<class name="ParticlesMaterial" inherits="Material" version="4.0"> <brief_description> Particle properties for [Particles] and [Particles2D] nodes. </brief_description> @@ -17,6 +17,7 @@ <argument index="0" name="flag" type="int" enum="ParticlesMaterial.Flags"> </argument> <description> + Returns [code]true[/code] if the specified flag is enabled. </description> </method> <method name="get_param" qualifiers="const"> @@ -25,6 +26,7 @@ <argument index="0" name="param" type="int" enum="ParticlesMaterial.Parameter"> </argument> <description> + Returns the value of the specified parameter. </description> </method> <method name="get_param_randomness" qualifiers="const"> @@ -33,6 +35,7 @@ <argument index="0" name="param" type="int" enum="ParticlesMaterial.Parameter"> </argument> <description> + Returns the randomness ratio associated with the specified parameter. </description> </method> <method name="get_param_texture" qualifiers="const"> @@ -41,6 +44,7 @@ <argument index="0" name="param" type="int" enum="ParticlesMaterial.Parameter"> </argument> <description> + Returns the [Texture] used by the specified parameter. </description> </method> <method name="set_flag"> @@ -51,6 +55,7 @@ <argument index="1" name="enable" type="bool"> </argument> <description> + If [code]true[/code], enables the specified flag. See [enum Flags] for options. </description> </method> <method name="set_param"> @@ -61,6 +66,7 @@ <argument index="1" name="value" type="float"> </argument> <description> + Sets the specified [enum Parameter]. </description> </method> <method name="set_param_randomness"> @@ -71,6 +77,7 @@ <argument index="1" name="randomness" type="float"> </argument> <description> + Sets the randomness ratio for the specified [enum Parameter]. </description> </method> <method name="set_param_texture"> @@ -81,6 +88,7 @@ <argument index="1" name="texture" type="Texture"> </argument> <description> + Sets the [Texture] for the specified [enum Parameter]. </description> </method> </methods> @@ -321,5 +329,8 @@ <constant name="EMISSION_SHAPE_DIRECTED_POINTS" value="4" enum="EmissionShape"> Particles will be emitted at a position determined by sampling a random point on the [member emission_point_texture]. Particle velocity and rotation will be set based on [member emission_normal_texture]. Particle color will be modulated by [member emission_color_texture]. </constant> + <constant name="EMISSION_SHAPE_MAX" value="5" enum="EmissionShape"> + Represents the size of the [enum EmissionShape] enum. + </constant> </constants> </class> diff --git a/doc/classes/Path.xml b/doc/classes/Path.xml index 12ae8fd3d5..801e86ff9e 100644 --- a/doc/classes/Path.xml +++ b/doc/classes/Path.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Path" inherits="Spatial" category="Core" version="3.2"> +<class name="Path" inherits="Spatial" version="4.0"> <brief_description> Contains a [Curve3D] path for [PathFollow] nodes to follow. </brief_description> diff --git a/doc/classes/Path2D.xml b/doc/classes/Path2D.xml index 7b37f8e40d..ab266a2f73 100644 --- a/doc/classes/Path2D.xml +++ b/doc/classes/Path2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Path2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Path2D" inherits="Node2D" version="4.0"> <brief_description> Contains a [Curve2D] path for [PathFollow2D] nodes to follow. </brief_description> diff --git a/doc/classes/PathFollow.xml b/doc/classes/PathFollow.xml index 0b4a781a7e..85ca5b787f 100644 --- a/doc/classes/PathFollow.xml +++ b/doc/classes/PathFollow.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PathFollow" inherits="Spatial" category="Core" version="3.2"> +<class name="PathFollow" inherits="Spatial" version="4.0"> <brief_description> Point sampler for a [Path]. </brief_description> diff --git a/doc/classes/PathFollow2D.xml b/doc/classes/PathFollow2D.xml index 9c4624dfee..bbaeca12da 100644 --- a/doc/classes/PathFollow2D.xml +++ b/doc/classes/PathFollow2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PathFollow2D" inherits="Node2D" category="Core" version="3.2"> +<class name="PathFollow2D" inherits="Node2D" version="4.0"> <brief_description> Point sampler for a [Path2D]. </brief_description> diff --git a/doc/classes/Performance.xml b/doc/classes/Performance.xml index a2b5856624..e992f25836 100644 --- a/doc/classes/Performance.xml +++ b/doc/classes/Performance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Performance" inherits="Object" category="Core" version="3.2"> +<class name="Performance" inherits="Object" version="4.0"> <brief_description> Exposes performance-related data. </brief_description> diff --git a/doc/classes/PhysicalBone.xml b/doc/classes/PhysicalBone.xml index 81446063f2..cef41aac5c 100644 --- a/doc/classes/PhysicalBone.xml +++ b/doc/classes/PhysicalBone.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicalBone" inherits="PhysicsBody" category="Core" version="3.2"> +<class name="PhysicalBone" inherits="PhysicsBody" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/Physics2DDirectBodyState.xml b/doc/classes/Physics2DDirectBodyState.xml index af3bba9b86..d9d402ac9a 100644 --- a/doc/classes/Physics2DDirectBodyState.xml +++ b/doc/classes/Physics2DDirectBodyState.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Physics2DDirectBodyState" inherits="Object" category="Core" version="3.2"> +<class name="Physics2DDirectBodyState" inherits="Object" version="4.0"> <brief_description> Direct access object to a physics body in the [Physics2DServer]. </brief_description> diff --git a/doc/classes/Physics2DDirectBodyStateSW.xml b/doc/classes/Physics2DDirectBodyStateSW.xml index 8aeea560c3..11f1140ca8 100644 --- a/doc/classes/Physics2DDirectBodyStateSW.xml +++ b/doc/classes/Physics2DDirectBodyStateSW.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Physics2DDirectBodyStateSW" inherits="Physics2DDirectBodyState" category="Core" version="3.2"> +<class name="Physics2DDirectBodyStateSW" inherits="Physics2DDirectBodyState" version="4.0"> <brief_description> Software implementation of [Physics2DDirectBodyState]. </brief_description> diff --git a/doc/classes/Physics2DDirectSpaceState.xml b/doc/classes/Physics2DDirectSpaceState.xml index e11e8918cd..662a823d84 100644 --- a/doc/classes/Physics2DDirectSpaceState.xml +++ b/doc/classes/Physics2DDirectSpaceState.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Physics2DDirectSpaceState" inherits="Object" category="Core" version="3.2"> +<class name="Physics2DDirectSpaceState" inherits="Object" version="4.0"> <brief_description> Direct access object to a space in the [Physics2DServer]. </brief_description> diff --git a/doc/classes/Physics2DServer.xml b/doc/classes/Physics2DServer.xml index 02e3ef5efb..4fac27a82b 100644 --- a/doc/classes/Physics2DServer.xml +++ b/doc/classes/Physics2DServer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Physics2DServer" inherits="Object" category="Core" version="3.2"> +<class name="Physics2DServer" inherits="Object" version="4.0"> <brief_description> Server interface for low-level 2D physics access. </brief_description> diff --git a/doc/classes/Physics2DServerSW.xml b/doc/classes/Physics2DServerSW.xml index e478a33e2c..1e4531ed66 100644 --- a/doc/classes/Physics2DServerSW.xml +++ b/doc/classes/Physics2DServerSW.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Physics2DServerSW" inherits="Physics2DServer" category="Core" version="3.2"> +<class name="Physics2DServerSW" inherits="Physics2DServer" version="4.0"> <brief_description> Software implementation of [Physics2DServer]. </brief_description> diff --git a/doc/classes/Physics2DShapeQueryParameters.xml b/doc/classes/Physics2DShapeQueryParameters.xml index 7ea00cbddc..392ccbd10a 100644 --- a/doc/classes/Physics2DShapeQueryParameters.xml +++ b/doc/classes/Physics2DShapeQueryParameters.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Physics2DShapeQueryParameters" inherits="Reference" category="Core" version="3.2"> +<class name="Physics2DShapeQueryParameters" inherits="Reference" version="4.0"> <brief_description> Parameters to be sent to a 2D shape physics query. </brief_description> diff --git a/doc/classes/Physics2DShapeQueryResult.xml b/doc/classes/Physics2DShapeQueryResult.xml index 06f943cb6d..359a716bee 100644 --- a/doc/classes/Physics2DShapeQueryResult.xml +++ b/doc/classes/Physics2DShapeQueryResult.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Physics2DShapeQueryResult" inherits="Reference" category="Core" version="3.2"> +<class name="Physics2DShapeQueryResult" inherits="Reference" version="4.0"> <brief_description> Result of a 2D shape query in [Physics2DServer]. </brief_description> diff --git a/doc/classes/Physics2DTestMotionResult.xml b/doc/classes/Physics2DTestMotionResult.xml index 752b50922d..9e8c03580f 100644 --- a/doc/classes/Physics2DTestMotionResult.xml +++ b/doc/classes/Physics2DTestMotionResult.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Physics2DTestMotionResult" inherits="Reference" category="Core" version="3.2"> +<class name="Physics2DTestMotionResult" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/PhysicsBody.xml b/doc/classes/PhysicsBody.xml index ee50f5a6c3..c0927a5b53 100644 --- a/doc/classes/PhysicsBody.xml +++ b/doc/classes/PhysicsBody.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicsBody" inherits="CollisionObject" category="Core" version="3.2"> +<class name="PhysicsBody" inherits="CollisionObject" version="4.0"> <brief_description> Base class for all objects affected by physics in 3D space. </brief_description> diff --git a/doc/classes/PhysicsBody2D.xml b/doc/classes/PhysicsBody2D.xml index 4fe7c329bd..28d6ce7048 100644 --- a/doc/classes/PhysicsBody2D.xml +++ b/doc/classes/PhysicsBody2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicsBody2D" inherits="CollisionObject2D" category="Core" version="3.2"> +<class name="PhysicsBody2D" inherits="CollisionObject2D" version="4.0"> <brief_description> Base class for all objects affected by physics in 2D space. </brief_description> diff --git a/doc/classes/PhysicsDirectBodyState.xml b/doc/classes/PhysicsDirectBodyState.xml index e68d280cd1..24cf4961be 100644 --- a/doc/classes/PhysicsDirectBodyState.xml +++ b/doc/classes/PhysicsDirectBodyState.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicsDirectBodyState" inherits="Object" category="Core" version="3.2"> +<class name="PhysicsDirectBodyState" inherits="Object" version="4.0"> <brief_description> Direct access object to a physics body in the [PhysicsServer]. </brief_description> diff --git a/doc/classes/PhysicsDirectSpaceState.xml b/doc/classes/PhysicsDirectSpaceState.xml index 1a3324bf0e..a6172805e9 100644 --- a/doc/classes/PhysicsDirectSpaceState.xml +++ b/doc/classes/PhysicsDirectSpaceState.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicsDirectSpaceState" inherits="Object" category="Core" version="3.2"> +<class name="PhysicsDirectSpaceState" inherits="Object" version="4.0"> <brief_description> Direct access object to a space in the [PhysicsServer]. </brief_description> diff --git a/doc/classes/PhysicsMaterial.xml b/doc/classes/PhysicsMaterial.xml index 73f1416172..84e7f2b275 100644 --- a/doc/classes/PhysicsMaterial.xml +++ b/doc/classes/PhysicsMaterial.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicsMaterial" inherits="Resource" category="Core" version="3.2"> +<class name="PhysicsMaterial" inherits="Resource" version="4.0"> <brief_description> A material for physics properties. </brief_description> diff --git a/doc/classes/PhysicsServer.xml b/doc/classes/PhysicsServer.xml index d7eb4c8c4f..d54a907d3d 100644 --- a/doc/classes/PhysicsServer.xml +++ b/doc/classes/PhysicsServer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicsServer" inherits="Object" category="Core" version="3.2"> +<class name="PhysicsServer" inherits="Object" version="4.0"> <brief_description> Server interface for low-level physics access. </brief_description> @@ -1315,7 +1315,7 @@ If [code]true[/code], the Hinge has a maximum and a minimum rotation. </constant> <constant name="HINGE_JOINT_FLAG_ENABLE_MOTOR" value="1" enum="HingeJointFlag"> - If [code]true[/code], a motor turns the Hinge + If [code]true[/code], a motor turns the Hinge. </constant> <constant name="SLIDER_JOINT_LINEAR_LIMIT_UPPER" value="0" enum="SliderJointParam"> The maximum difference between the pivot points on their X axis before damping happens. diff --git a/doc/classes/PhysicsShapeQueryParameters.xml b/doc/classes/PhysicsShapeQueryParameters.xml index d56247fcaf..829a1d1bf0 100644 --- a/doc/classes/PhysicsShapeQueryParameters.xml +++ b/doc/classes/PhysicsShapeQueryParameters.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicsShapeQueryParameters" inherits="Reference" category="Core" version="3.2"> +<class name="PhysicsShapeQueryParameters" inherits="Reference" version="4.0"> <brief_description> Parameters to be sent to a 3D shape physics query. </brief_description> diff --git a/doc/classes/PhysicsShapeQueryResult.xml b/doc/classes/PhysicsShapeQueryResult.xml index 1f151ebb1a..ea6dc2c39e 100644 --- a/doc/classes/PhysicsShapeQueryResult.xml +++ b/doc/classes/PhysicsShapeQueryResult.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PhysicsShapeQueryResult" inherits="Reference" category="Core" version="3.2"> +<class name="PhysicsShapeQueryResult" inherits="Reference" version="4.0"> <brief_description> Result of a 3D shape query in [PhysicsServer]. </brief_description> diff --git a/doc/classes/PinJoint.xml b/doc/classes/PinJoint.xml index 647a59feef..de4cb9d98a 100644 --- a/doc/classes/PinJoint.xml +++ b/doc/classes/PinJoint.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PinJoint" inherits="Joint" category="Core" version="3.2"> +<class name="PinJoint" inherits="Joint" version="4.0"> <brief_description> Pin joint for 3D shapes. </brief_description> diff --git a/doc/classes/PinJoint2D.xml b/doc/classes/PinJoint2D.xml index f65cb86b1c..020babdf40 100644 --- a/doc/classes/PinJoint2D.xml +++ b/doc/classes/PinJoint2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PinJoint2D" inherits="Joint2D" category="Core" version="3.2"> +<class name="PinJoint2D" inherits="Joint2D" version="4.0"> <brief_description> Pin Joint for 2D shapes. </brief_description> diff --git a/doc/classes/Plane.xml b/doc/classes/Plane.xml index 0164943ccc..8f0043fb86 100644 --- a/doc/classes/Plane.xml +++ b/doc/classes/Plane.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Plane" category="Built-In Types" version="3.2"> +<class name="Plane" version="4.0"> <brief_description> Plane in hessian form. </brief_description> @@ -170,10 +170,13 @@ </members> <constants> <constant name="PLANE_YZ" value="Plane( 1, 0, 0, 0 )"> + A plane that extends in the Y and Z axes. </constant> <constant name="PLANE_XZ" value="Plane( 0, 1, 0, 0 )"> + A plane that extends in the X and Z axes. </constant> <constant name="PLANE_XY" value="Plane( 0, 0, 1, 0 )"> + A plane that extends in the X and Y axes. </constant> </constants> </class> diff --git a/doc/classes/PlaneMesh.xml b/doc/classes/PlaneMesh.xml index 01aee93dad..2081442e04 100644 --- a/doc/classes/PlaneMesh.xml +++ b/doc/classes/PlaneMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PlaneMesh" inherits="PrimitiveMesh" category="Core" version="3.2"> +<class name="PlaneMesh" inherits="PrimitiveMesh" version="4.0"> <brief_description> Class representing a planar [PrimitiveMesh]. </brief_description> diff --git a/doc/classes/PlaneShape.xml b/doc/classes/PlaneShape.xml index ee841a3cff..b40e133d00 100644 --- a/doc/classes/PlaneShape.xml +++ b/doc/classes/PlaneShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PlaneShape" inherits="Shape" category="Core" version="3.2"> +<class name="PlaneShape" inherits="Shape" version="4.0"> <brief_description> Infinite plane shape for 3D collisions. </brief_description> diff --git a/doc/classes/PointMesh.xml b/doc/classes/PointMesh.xml index dc7dd065cf..af100d5206 100644 --- a/doc/classes/PointMesh.xml +++ b/doc/classes/PointMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PointMesh" inherits="PrimitiveMesh" category="Core" version="3.2"> +<class name="PointMesh" inherits="PrimitiveMesh" version="4.0"> <brief_description> Mesh with a single Point primitive. </brief_description> diff --git a/doc/classes/Polygon2D.xml b/doc/classes/Polygon2D.xml index 7c2aa468ab..e911ed7664 100644 --- a/doc/classes/Polygon2D.xml +++ b/doc/classes/Polygon2D.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Polygon2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Polygon2D" inherits="Node2D" version="4.0"> <brief_description> A 2D polygon. </brief_description> <description> A Polygon2D is defined by a set of points. Each point is connected to the next, with the final point being connected to the first, resulting in a closed polygon. Polygon2Ds can be filled with color (solid or gradient) or filled with a given texture. + [b]Note:[/b] By default, Godot can only draw up to 4,096 polygon points at a time. To increase this limit, open the Project Settings and increase [member ProjectSettings.rendering/limits/buffers/canvas_polygon_buffer_size_kb] and [member ProjectSettings.rendering/limits/buffers/canvas_polygon_index_buffer_size_kb]. </description> <tutorials> </tutorials> diff --git a/doc/classes/PolygonPathFinder.xml b/doc/classes/PolygonPathFinder.xml index 7286857b51..28a0447f3d 100644 --- a/doc/classes/PolygonPathFinder.xml +++ b/doc/classes/PolygonPathFinder.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PolygonPathFinder" inherits="Resource" category="Core" version="3.2"> +<class name="PolygonPathFinder" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/PoolByteArray.xml b/doc/classes/PoolByteArray.xml index 867f042cd2..63a7037fb1 100644 --- a/doc/classes/PoolByteArray.xml +++ b/doc/classes/PoolByteArray.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PoolByteArray" category="Built-In Types" version="3.2"> +<class name="PoolByteArray" version="4.0"> <brief_description> A pooled [Array] of bytes. </brief_description> @@ -78,6 +78,11 @@ <return type="String"> </return> <description> + Returns a hexadecimal representation of this array as a [String]. + [codeblock] + var array = PoolByteArray([11, 46, 255]) + print(array.hex_encode()) # Prints: 0b2eff + [/codeblock] </description> </method> <method name="insert"> diff --git a/doc/classes/PoolColorArray.xml b/doc/classes/PoolColorArray.xml index 34cfa0ab53..d5599f821c 100644 --- a/doc/classes/PoolColorArray.xml +++ b/doc/classes/PoolColorArray.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PoolColorArray" category="Built-In Types" version="3.2"> +<class name="PoolColorArray" version="4.0"> <brief_description> A pooled [Array] of [Color]. </brief_description> diff --git a/doc/classes/PoolIntArray.xml b/doc/classes/PoolIntArray.xml index 25e1e718f7..54f0f46e11 100644 --- a/doc/classes/PoolIntArray.xml +++ b/doc/classes/PoolIntArray.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PoolIntArray" category="Built-In Types" version="3.2"> +<class name="PoolIntArray" version="4.0"> <brief_description> A pooled [Array] of integers ([int]). </brief_description> diff --git a/doc/classes/PoolRealArray.xml b/doc/classes/PoolRealArray.xml index e8afe46640..6957e7282b 100644 --- a/doc/classes/PoolRealArray.xml +++ b/doc/classes/PoolRealArray.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PoolRealArray" category="Built-In Types" version="3.2"> +<class name="PoolRealArray" version="4.0"> <brief_description> A pooled [Array] of reals ([float]). </brief_description> diff --git a/doc/classes/PoolStringArray.xml b/doc/classes/PoolStringArray.xml index f41a3c7a68..b4fb7b31d4 100644 --- a/doc/classes/PoolStringArray.xml +++ b/doc/classes/PoolStringArray.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PoolStringArray" category="Built-In Types" version="3.2"> +<class name="PoolStringArray" version="4.0"> <brief_description> A pooled [Array] of [String]. </brief_description> diff --git a/doc/classes/PoolVector2Array.xml b/doc/classes/PoolVector2Array.xml index 321846d08b..cb4536be5b 100644 --- a/doc/classes/PoolVector2Array.xml +++ b/doc/classes/PoolVector2Array.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PoolVector2Array" category="Built-In Types" version="3.2"> +<class name="PoolVector2Array" version="4.0"> <brief_description> A pooled [Array] of [Vector2]. </brief_description> diff --git a/doc/classes/PoolVector3Array.xml b/doc/classes/PoolVector3Array.xml index c82bd62a11..6c40de9bd8 100644 --- a/doc/classes/PoolVector3Array.xml +++ b/doc/classes/PoolVector3Array.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PoolVector3Array" category="Built-In Types" version="3.2"> +<class name="PoolVector3Array" version="4.0"> <brief_description> A pooled [Array] of [Vector3]. </brief_description> diff --git a/doc/classes/Popup.xml b/doc/classes/Popup.xml index 6b15b5a1ea..483e262f60 100644 --- a/doc/classes/Popup.xml +++ b/doc/classes/Popup.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Popup" inherits="Control" category="Core" version="3.2"> +<class name="Popup" inherits="Control" version="4.0"> <brief_description> Base container control for popups and dialogs. </brief_description> diff --git a/doc/classes/PopupDialog.xml b/doc/classes/PopupDialog.xml index 939453b977..a8fd9c1b7d 100644 --- a/doc/classes/PopupDialog.xml +++ b/doc/classes/PopupDialog.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PopupDialog" inherits="Popup" category="Core" version="3.2"> +<class name="PopupDialog" inherits="Popup" version="4.0"> <brief_description> Base class for popup dialogs. </brief_description> diff --git a/doc/classes/PopupMenu.xml b/doc/classes/PopupMenu.xml index 89039eebda..31ab27628a 100644 --- a/doc/classes/PopupMenu.xml +++ b/doc/classes/PopupMenu.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PopupMenu" inherits="Popup" category="Core" version="3.2"> +<class name="PopupMenu" inherits="Popup" version="4.0"> <brief_description> PopupMenu displays a list of options. </brief_description> @@ -645,55 +645,58 @@ </constants> <theme_items> <theme_item name="checked" type="Texture"> - Sets a custom [Texture] icon for [code]checked[/code] state of checkbox items. + [Texture] icon for the checked checkbox items. </theme_item> <theme_item name="font" type="Font"> - Sets a custom [Font]. + [Font] used for the menu items. </theme_item> <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> - Sets a custom [Color] for the [Font]. + The default text [Color] for menu items' names. </theme_item> <theme_item name="font_color_accel" type="Color" default="Color( 0.7, 0.7, 0.7, 0.8 )"> + The text [Color] used for shortcuts and accelerators that show next to the menu item name when defined. See [method get_item_accelerator] for more info on accelerators. </theme_item> <theme_item name="font_color_disabled" type="Color" default="Color( 0.4, 0.4, 0.4, 0.8 )"> - Sets a custom [Color] for disabled text. + [Color] used for disabled menu items' text. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> - Sets a custom [Color] for the hovered text. + [Color] used for the hovered text. </theme_item> <theme_item name="hover" type="StyleBox"> - Sets a custom [StyleBox] when the [PopupMenu] is hovered. + [StyleBox] displayed when the [PopupMenu] item is hovered. </theme_item> <theme_item name="hseparation" type="int" default="4"> - Sets the horizontal space separation between each item. + The horizontal space between the item's name and the shortcut text/submenu arrow. </theme_item> <theme_item name="labeled_separator_left" type="StyleBox"> + [StyleBox] for the left side of labeled separator. See [method add_separator]. </theme_item> <theme_item name="labeled_separator_right" type="StyleBox"> + [StyleBox] for the right side of labeled separator. See [method add_separator]. </theme_item> <theme_item name="panel" type="StyleBox"> - Sets a custom [StyleBox] for the panel of the [PopupMenu]. + Default [StyleBox] of the [PopupMenu] items. </theme_item> <theme_item name="panel_disabled" type="StyleBox"> - Sets a custom [StyleBox] for the panel of the [PopupMenu], when the panel is disabled. + [StyleBox] used when the [PopupMenu] item is disabled. </theme_item> <theme_item name="radio_checked" type="Texture"> - Sets a custom [Texture] icon for [code]checked[/code] of radio button items. + [Texture] icon for the checked radio button items. </theme_item> <theme_item name="radio_unchecked" type="Texture"> - Sets a custom [Texture] icon for [code]unchecked[/code] of radio button items. + [Texture] icon for the unchecked radio button items. </theme_item> <theme_item name="separator" type="StyleBox"> - Sets a custom [StyleBox] for separator's. + [StyleBox] used for the separators. See [method add_separator]. </theme_item> <theme_item name="submenu" type="Texture"> - Sets a custom [Texture] for submenu's. + [Texture] icon for the submenu arrow. </theme_item> <theme_item name="unchecked" type="Texture"> - Sets a custom [Texture] icon for [code]unchecked[/code] of checkbox items. + [Texture] icon for the unchecked checkbox items. </theme_item> <theme_item name="vseparation" type="int" default="4"> - Sets the vertical space separation between each item. + The vertical space between each menu item. </theme_item> </theme_items> </class> diff --git a/doc/classes/PopupPanel.xml b/doc/classes/PopupPanel.xml index bed4d97112..a3dd722f81 100644 --- a/doc/classes/PopupPanel.xml +++ b/doc/classes/PopupPanel.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PopupPanel" inherits="Popup" category="Core" version="3.2"> +<class name="PopupPanel" inherits="Popup" version="4.0"> <brief_description> Class for displaying popups with a panel background. </brief_description> diff --git a/doc/classes/Position2D.xml b/doc/classes/Position2D.xml index ccadee6018..9fadb73a15 100644 --- a/doc/classes/Position2D.xml +++ b/doc/classes/Position2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Position2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Position2D" inherits="Node2D" version="4.0"> <brief_description> Generic 2D position hint for editing. </brief_description> diff --git a/doc/classes/Position3D.xml b/doc/classes/Position3D.xml index 4d43a6729d..6dce8a91c6 100644 --- a/doc/classes/Position3D.xml +++ b/doc/classes/Position3D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Position3D" inherits="Spatial" category="Core" version="3.2"> +<class name="Position3D" inherits="Spatial" version="4.0"> <brief_description> Generic 3D position hint for editing. </brief_description> diff --git a/doc/classes/PrimitiveMesh.xml b/doc/classes/PrimitiveMesh.xml index 3f07affdfd..ea84860632 100644 --- a/doc/classes/PrimitiveMesh.xml +++ b/doc/classes/PrimitiveMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PrimitiveMesh" inherits="Mesh" category="Core" version="3.2"> +<class name="PrimitiveMesh" inherits="Mesh" version="4.0"> <brief_description> Base class for all primitive meshes. Handles applying a [Material] to a primitive mesh. </brief_description> diff --git a/doc/classes/PrismMesh.xml b/doc/classes/PrismMesh.xml index 1d4e5ddab7..b2e1fdd3f0 100644 --- a/doc/classes/PrismMesh.xml +++ b/doc/classes/PrismMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PrismMesh" inherits="PrimitiveMesh" category="Core" version="3.2"> +<class name="PrismMesh" inherits="PrimitiveMesh" version="4.0"> <brief_description> Class representing a prism-shaped [PrimitiveMesh]. </brief_description> diff --git a/doc/classes/ProceduralSky.xml b/doc/classes/ProceduralSky.xml index 9ffca20081..25d09a1bc0 100644 --- a/doc/classes/ProceduralSky.xml +++ b/doc/classes/ProceduralSky.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ProceduralSky" inherits="Sky" category="Core" version="3.2"> +<class name="ProceduralSky" inherits="Sky" version="4.0"> <brief_description> Type of [Sky] that is generated procedurally based on user input parameters. </brief_description> @@ -63,14 +63,19 @@ </members> <constants> <constant name="TEXTURE_SIZE_256" value="0" enum="TextureSize"> + Sky texture will be 256x128. </constant> <constant name="TEXTURE_SIZE_512" value="1" enum="TextureSize"> + Sky texture will be 512x256. </constant> <constant name="TEXTURE_SIZE_1024" value="2" enum="TextureSize"> + Sky texture will be 1024x512. This is the default size. </constant> <constant name="TEXTURE_SIZE_2048" value="3" enum="TextureSize"> + Sky texture will be 2048x1024. </constant> <constant name="TEXTURE_SIZE_4096" value="4" enum="TextureSize"> + Sky texture will be 4096x2048. </constant> <constant name="TEXTURE_SIZE_MAX" value="5" enum="TextureSize"> Represents the size of the [enum TextureSize] enum. diff --git a/doc/classes/ProgressBar.xml b/doc/classes/ProgressBar.xml index d489fd8bca..e94299a5b8 100644 --- a/doc/classes/ProgressBar.xml +++ b/doc/classes/ProgressBar.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ProgressBar" inherits="Range" category="Core" version="3.2"> +<class name="ProgressBar" inherits="Range" version="4.0"> <brief_description> General-purpose progress bar. </brief_description> diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml index 1e714d92c2..b4284e06b9 100644 --- a/doc/classes/ProjectSettings.xml +++ b/doc/classes/ProjectSettings.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ProjectSettings" inherits="Object" category="Core" version="3.2"> +<class name="ProjectSettings" inherits="Object" version="4.0"> <brief_description> Contains global variables accessible from everywhere. </brief_description> @@ -205,6 +205,7 @@ Icon used for the project, set when project loads. Exporters will also use this icon when possible. </member> <member name="application/config/macos_native_icon" type="String" setter="" getter="" default=""""> + Icon set in [code].icns[/code] format used on macOS to set the game's icon. This is done automatically on start by calling [method OS.set_native_icon]. </member> <member name="application/config/name" type="String" setter="" getter="" default=""""> The project's name. It is used both by the Project Manager and by exporters. The project name can be translated by translating its value in localization files. @@ -217,6 +218,7 @@ If [code]true[/code], the project will save user data to its own user directory (see [member application/config/custom_user_dir_name]). This setting is only effective on desktop platforms. A name must be set in the [member application/config/custom_user_dir_name] setting for this to take effect. If [code]false[/code], the project will save user data to [code](OS user data directory)/Godot/app_userdata/(project name)[/code]. </member> <member name="application/config/windows_native_icon" type="String" setter="" getter="" default=""""> + Icon set in [code].ico[/code] format used on Windows to set the game's icon. This is done automatically on start by calling [method OS.set_native_icon]. </member> <member name="application/run/disable_stderr" type="bool" setter="" getter="" default="false"> If [code]true[/code], disables printing to standard error in an exported build. @@ -243,6 +245,7 @@ Audio buses will disable automatically when sound goes below a given dB threshold for a given time. This saves CPU as effects assigned to that bus will no longer do any processing. </member> <member name="audio/default_bus_layout" type="String" setter="" getter="" default=""res://default_bus_layout.tres""> + Default [AudioBusLayout] resource file to use in the project, unless overridden by the scene. </member> <member name="audio/driver" type="String" setter="" getter="" default=""PulseAudio""> Specifies the audio driver to use. This setting is platform-dependent as each platform supports different audio drivers. If left empty, the default audio driver will be used. @@ -272,6 +275,7 @@ Enables long-distance matching in Zstandard. </member> <member name="compression/formats/zstd/window_log_size" type="int" setter="" getter="" default="27"> + Largest size limit (in power of 2) allowed when compressing using long-distance matching with Zstandard. </member> <member name="debug/gdscript/completion/autocomplete_setters_and_getters" type="bool" setter="" getter="" default="false"> If [code]true[/code], displays getters and setters in autocompletion results in the script editor. This setting is meant to be used when porting old projects (Godot 2), as using member variables is the preferred style from Godot 3 onwards. @@ -370,6 +374,9 @@ Message to be displayed before the backtrace when the engine crashes. </member> <member name="debug/settings/fps/force_fps" type="int" setter="" getter="" default="0"> + Maximum number of frames per second allowed. The actual number of frames per second may still be below this value if the game is lagging. + If [member display/window/vsync/use_vsync] is enabled, it takes precedence and the forced FPS number cannot exceed the monitor's refresh rate. + This setting is therefore mostly relevant for lowering the maximum FPS below VSync, e.g. to perform non real-time rendering of static frames, or test the project under lag conditions. </member> <member name="debug/settings/gdscript/max_call_stack" type="int" setter="" getter="" default="1024"> Maximum call stack allowed for debugging GDScript. @@ -386,6 +393,21 @@ <member name="debug/settings/visual_script/max_call_stack" type="int" setter="" getter="" default="1024"> Maximum call stack in visual scripting, to avoid infinite recursion. </member> + <member name="debug/shapes/collision/contact_color" type="Color" setter="" getter="" default="Color( 1, 0.2, 0.1, 0.8 )"> + Color of the contact points between collision shapes, visible when "Visible Collision Shapes" is enabled in the Debug menu. + </member> + <member name="debug/shapes/collision/max_contacts_displayed" type="int" setter="" getter="" default="10000"> + Maximum number of contact points between collision shapes to display when "Visible Collision Shapes" is enabled in the Debug menu. + </member> + <member name="debug/shapes/collision/shape_color" type="Color" setter="" getter="" default="Color( 0, 0.6, 0.7, 0.5 )"> + Color of the collision shapes, visible when "Visible Collision Shapes" is enabled in the Debug menu. + </member> + <member name="debug/shapes/navigation/disabled_geometry_color" type="Color" setter="" getter="" default="Color( 1, 0.7, 0.1, 0.4 )"> + Color of the disabled navigation geometry, visible when "Visible Navigation" is enabled in the Debug menu. + </member> + <member name="debug/shapes/navigation/geometry_color" type="Color" setter="" getter="" default="Color( 0.1, 1, 0.7, 0.4 )"> + Color of the navigation geometry, visible when "Visible Navigation" is enabled in the Debug menu. + </member> <member name="display/mouse_cursor/custom_image" type="String" setter="" getter="" default=""""> Custom image for the mouse cursor (limited to 256×256). </member> @@ -440,58 +462,91 @@ <member name="display/window/vsync/use_vsync" type="bool" setter="" getter="" default="true"> If [code]true[/code], enables vertical synchronization. This eliminates tearing that may appear in moving scenes, at the cost of higher input latency and stuttering at lower framerates. If [code]false[/code], vertical synchronization will be disabled, however, many platforms will enforce it regardless (such as mobile platforms and HTML5). </member> - <member name="display/window/vsync/vsync_via_compositor" type="bool" setter="" getter="" default="true"> + <member name="display/window/vsync/vsync_via_compositor" type="bool" setter="" getter="" default="false"> If [code]Use Vsync[/code] is enabled and this setting is [code]true[/code], enables vertical synchronization via the operating system's window compositor when in windowed mode and the compositor is enabled. This will prevent stutter in certain situations. (Windows only.) + [b]Note:[/b] This option is experimental and meant to alleviate stutter experienced by some users. However, some users have experienced a Vsync framerate halving (e.g. from 60 FPS to 30 FPS) when using it. </member> <member name="editor/script_templates_search_path" type="String" setter="" getter="" default=""res://script_templates""> + Search path for project-specific script templates. Script templates will be search both in the editor-specific path and in this project-specific path. </member> <member name="editor/search_in_file_extensions" type="PoolStringArray" setter="" getter="" default="PoolStringArray( "gd", "shader" )"> + Text-based file extensions to include in the script editor's "Find in Files" feature. You can add e.g. [code]tscn[/code] if you wish to also parse your scene files, especially if you use built-in scripts which are serialized in the scene files. </member> <member name="gui/common/default_scroll_deadzone" type="int" setter="" getter="" default="0"> + Default value for [member ScrollContainer.scroll_deadzone], which will be used for all [ScrollContainer]s unless overridden. </member> <member name="gui/common/swap_ok_cancel" type="bool" setter="" getter="" default="false"> If [code]true[/code], swaps OK and Cancel buttons in dialogs on Windows and UWP to follow interface conventions. </member> <member name="gui/theme/custom" type="String" setter="" getter="" default=""""> - Use a custom theme resource, set a path to it here. + Path to a custom [Theme] resource file to use for the project ([code]theme[/code] or generic [code]tres[/code]/[code]res[/code] extension). </member> <member name="gui/theme/custom_font" type="String" setter="" getter="" default=""""> - Use a custom default font resource, set a path to it here. + Path to a custom [Font] resource to use as default for all GUI elements of the project. </member> <member name="gui/theme/use_hidpi" type="bool" setter="" getter="" default="false"> If [code]true[/code], makes sure the theme used works with HiDPI. </member> <member name="gui/timers/incremental_search_max_interval_msec" type="int" setter="" getter="" default="2000"> - Timer setting for incremental search in Tree, IntemList, etc. controls (in milliseconds). + Timer setting for incremental search in [Tree], [ItemList], etc. controls (in milliseconds). </member> <member name="gui/timers/text_edit_idle_detect_sec" type="float" setter="" getter="" default="3"> - Timer for detecting idle in the editor (in seconds). + Timer for detecting idle in [TextEdit] (in seconds). + </member> + <member name="gui/timers/tooltip_delay_sec" type="float" setter="" getter="" default="0.5"> + Default delay for tooltips (in seconds). </member> - <member name="input/ui_accept" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777221,"unicode":0,"echo":false,"script":null), Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777222,"unicode":0,"echo":false,"script":null), Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":32,"unicode":0,"echo":false,"script":null), Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":0,"pressure":0.0,"pressed":false,"script":null) ]}"> + <member name="input/ui_accept" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to confirm a focused button, menu or list item, or validate input. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_cancel" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777217,"unicode":0,"echo":false,"script":null), Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":1,"pressure":0.0,"pressed":false,"script":null) ]}"> + <member name="input/ui_cancel" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to discard a modal or pending input. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_down" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777234,"unicode":0,"echo":false,"script":null), Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":13,"pressure":0.0,"pressed":false,"script":null) ]}"> + <member name="input/ui_down" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to move down in the UI. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_end" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777230,"unicode":0,"echo":false,"script":null) ]}"> + <member name="input/ui_end" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to go to the end position of a [Control] (e.g. last item in an [ItemList] or a [Tree]), matching the behavior of [constant KEY_END] on typical desktop UI systems. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_focus_next" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777218,"unicode":0,"echo":false,"script":null) ]}"> + <member name="input/ui_focus_next" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to focus the next [Control] in the scene. The focus behavior can be configured via [member Control.focus_next]. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_focus_prev" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":true,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777218,"unicode":0,"echo":false,"script":null) ]}"> + <member name="input/ui_focus_prev" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to focus the previous [Control] in the scene. The focus behavior can be configured via [member Control.focus_previous]. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_home" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777229,"unicode":0,"echo":false,"script":null) ]}"> + <member name="input/ui_home" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to go to the start position of a [Control] (e.g. first item in an [ItemList] or a [Tree]), matching the behavior of [constant KEY_HOME] on typical desktop UI systems. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_left" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777231,"unicode":0,"echo":false,"script":null), Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":14,"pressure":0.0,"pressed":false,"script":null) ]}"> + <member name="input/ui_left" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to move left in the UI. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_page_down" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777236,"unicode":0,"echo":false,"script":null) ]}"> + <member name="input/ui_page_down" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to go down a page in a [Control] (e.g. in an [ItemList] or a [Tree]), matching the behavior of [constant KEY_PAGEDOWN] on typical desktop UI systems. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_page_up" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777235,"unicode":0,"echo":false,"script":null) ]}"> + <member name="input/ui_page_up" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to go up a page in a [Control] (e.g. in an [ItemList] or a [Tree]), matching the behavior of [constant KEY_PAGEUP] on typical desktop UI systems. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_right" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777233,"unicode":0,"echo":false,"script":null), Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":15,"pressure":0.0,"pressed":false,"script":null) ]}"> + <member name="input/ui_right" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to move right in the UI. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_select" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":32,"unicode":0,"echo":false,"script":null), Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":3,"pressure":0.0,"pressed":false,"script":null) ]}"> + <member name="input/ui_select" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to select an item in a [Control] (e.g. in an [ItemList] or a [Tree]). + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> - <member name="input/ui_up" type="Dictionary" setter="" getter="" default="{"deadzone": 0.5,"events": [ Object(InputEventKey,"resource_local_to_scene":false,"resource_name":"","device":0,"alt":false,"shift":false,"control":false,"meta":false,"command":false,"pressed":false,"scancode":16777232,"unicode":0,"echo":false,"script":null), Object(InputEventJoypadButton,"resource_local_to_scene":false,"resource_name":"","device":0,"button_index":12,"pressure":0.0,"pressed":false,"script":null) ]}"> + <member name="input/ui_up" type="Dictionary" setter="" getter=""> + Default [InputEventAction] to move up in the UI. + [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. </member> <member name="input_devices/pointing/emulate_mouse_from_touch" type="bool" setter="" getter="" default="true"> If [code]true[/code], sends mouse input events when tapping or swiping on the touchscreen. @@ -500,164 +555,244 @@ If [code]true[/code], sends touch input events when clicking or dragging the mouse. </member> <member name="layer_names/2d_physics/layer_1" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 1. </member> <member name="layer_names/2d_physics/layer_10" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 10. </member> <member name="layer_names/2d_physics/layer_11" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 11. </member> <member name="layer_names/2d_physics/layer_12" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 12. </member> <member name="layer_names/2d_physics/layer_13" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 13. </member> <member name="layer_names/2d_physics/layer_14" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 14. </member> <member name="layer_names/2d_physics/layer_15" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 15. </member> <member name="layer_names/2d_physics/layer_16" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 16. </member> <member name="layer_names/2d_physics/layer_17" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 17. </member> <member name="layer_names/2d_physics/layer_18" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 18. </member> <member name="layer_names/2d_physics/layer_19" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 19. </member> <member name="layer_names/2d_physics/layer_2" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 2. </member> <member name="layer_names/2d_physics/layer_20" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 20. </member> <member name="layer_names/2d_physics/layer_3" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 3. </member> <member name="layer_names/2d_physics/layer_4" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 4. </member> <member name="layer_names/2d_physics/layer_5" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 5. </member> <member name="layer_names/2d_physics/layer_6" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 6. </member> <member name="layer_names/2d_physics/layer_7" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 7. </member> <member name="layer_names/2d_physics/layer_8" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 8. </member> <member name="layer_names/2d_physics/layer_9" type="String" setter="" getter="" default=""""> + Optional name for the 2D physics layer 9. </member> <member name="layer_names/2d_render/layer_1" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 1. </member> <member name="layer_names/2d_render/layer_10" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 10. </member> <member name="layer_names/2d_render/layer_11" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 11. </member> <member name="layer_names/2d_render/layer_12" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 12. </member> <member name="layer_names/2d_render/layer_13" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 13. </member> <member name="layer_names/2d_render/layer_14" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 14. </member> <member name="layer_names/2d_render/layer_15" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 15. </member> <member name="layer_names/2d_render/layer_16" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 16. </member> <member name="layer_names/2d_render/layer_17" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 17. </member> <member name="layer_names/2d_render/layer_18" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 18. </member> <member name="layer_names/2d_render/layer_19" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 19. </member> <member name="layer_names/2d_render/layer_2" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 2. </member> <member name="layer_names/2d_render/layer_20" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 20. </member> <member name="layer_names/2d_render/layer_3" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 3. </member> <member name="layer_names/2d_render/layer_4" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 4. </member> <member name="layer_names/2d_render/layer_5" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 5. </member> <member name="layer_names/2d_render/layer_6" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 6. </member> <member name="layer_names/2d_render/layer_7" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 7. </member> <member name="layer_names/2d_render/layer_8" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 8. </member> <member name="layer_names/2d_render/layer_9" type="String" setter="" getter="" default=""""> + Optional name for the 2D render layer 9. </member> <member name="layer_names/3d_physics/layer_1" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 1. </member> <member name="layer_names/3d_physics/layer_10" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 10. </member> <member name="layer_names/3d_physics/layer_11" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 11. </member> <member name="layer_names/3d_physics/layer_12" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 12. </member> <member name="layer_names/3d_physics/layer_13" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 13. </member> <member name="layer_names/3d_physics/layer_14" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 14. </member> <member name="layer_names/3d_physics/layer_15" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 15. </member> <member name="layer_names/3d_physics/layer_16" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 16. </member> <member name="layer_names/3d_physics/layer_17" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 17. </member> <member name="layer_names/3d_physics/layer_18" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 18. </member> <member name="layer_names/3d_physics/layer_19" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 19. </member> <member name="layer_names/3d_physics/layer_2" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 2. </member> <member name="layer_names/3d_physics/layer_20" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 20. </member> <member name="layer_names/3d_physics/layer_3" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 3. </member> <member name="layer_names/3d_physics/layer_4" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 4. </member> <member name="layer_names/3d_physics/layer_5" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 5. </member> <member name="layer_names/3d_physics/layer_6" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 6. </member> <member name="layer_names/3d_physics/layer_7" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 7. </member> <member name="layer_names/3d_physics/layer_8" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 8. </member> <member name="layer_names/3d_physics/layer_9" type="String" setter="" getter="" default=""""> + Optional name for the 3D physics layer 9. </member> <member name="layer_names/3d_render/layer_1" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 1. </member> <member name="layer_names/3d_render/layer_10" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 10. </member> <member name="layer_names/3d_render/layer_11" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 11. </member> <member name="layer_names/3d_render/layer_12" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 12. </member> <member name="layer_names/3d_render/layer_13" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 13. </member> <member name="layer_names/3d_render/layer_14" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 14 </member> <member name="layer_names/3d_render/layer_15" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 15. </member> <member name="layer_names/3d_render/layer_16" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 16. </member> <member name="layer_names/3d_render/layer_17" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 17. </member> <member name="layer_names/3d_render/layer_18" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 18. </member> <member name="layer_names/3d_render/layer_19" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 19. </member> <member name="layer_names/3d_render/layer_2" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 2. </member> <member name="layer_names/3d_render/layer_20" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 20. </member> <member name="layer_names/3d_render/layer_3" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 3. </member> <member name="layer_names/3d_render/layer_4" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 4. </member> <member name="layer_names/3d_render/layer_5" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 5. </member> <member name="layer_names/3d_render/layer_6" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 6. </member> <member name="layer_names/3d_render/layer_7" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 7. </member> <member name="layer_names/3d_render/layer_8" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 8. </member> <member name="layer_names/3d_render/layer_9" type="String" setter="" getter="" default=""""> + Optional name for the 3D render layer 9. </member> <member name="locale/fallback" type="String" setter="" getter="" default=""en""> The locale to fall back to if a translation isn't available in a given language. If left empty, [code]en[/code] (English) will be used. @@ -696,24 +831,34 @@ Default size of packet peer stream for deserializing Godot data. Over this size, data is dropped. </member> <member name="network/limits/tcp/connect_timeout_seconds" type="int" setter="" getter="" default="30"> + Timeout (in seconds) for connection attempts using TCP. </member> <member name="network/limits/webrtc/max_channel_in_buffer_kb" type="int" setter="" getter="" default="64"> + Maximum size (in kiB) for the [WebRTCDataChannel] input buffer. </member> <member name="network/limits/websocket_client/max_in_buffer_kb" type="int" setter="" getter="" default="64"> + Maximum size (in kiB) for the [WebSocketClient] input buffer. </member> <member name="network/limits/websocket_client/max_in_packets" type="int" setter="" getter="" default="1024"> + Maximum number of concurrent input packets for [WebSocketClient]. </member> <member name="network/limits/websocket_client/max_out_buffer_kb" type="int" setter="" getter="" default="64"> + Maximum size (in kiB) for the [WebSocketClient] output buffer. </member> <member name="network/limits/websocket_client/max_out_packets" type="int" setter="" getter="" default="1024"> + Maximum number of concurrent output packets for [WebSocketClient]. </member> <member name="network/limits/websocket_server/max_in_buffer_kb" type="int" setter="" getter="" default="64"> + Maximum size (in kiB) for the [WebSocketServer] input buffer. </member> <member name="network/limits/websocket_server/max_in_packets" type="int" setter="" getter="" default="1024"> + Maximum number of concurrent input packets for [WebSocketServer]. </member> <member name="network/limits/websocket_server/max_out_buffer_kb" type="int" setter="" getter="" default="64"> + Maximum size (in kiB) for the [WebSocketServer] output buffer. </member> <member name="network/limits/websocket_server/max_out_packets" type="int" setter="" getter="" default="1024"> + Maximum number of concurrent output packets for [WebSocketServer]. </member> <member name="network/remote_fs/page_read_ahead" type="int" setter="" getter="" default="4"> Amount of read ahead used by remote filesystem. Higher values decrease the effects of latency at the cost of higher bandwidth usage. @@ -722,6 +867,7 @@ Page size used by remote filesystem (in bytes). </member> <member name="network/ssl/certificates" type="String" setter="" getter="" default=""""> + CA certificates bundle to use for SSL connections. If not defined, Godot's internal CA certificates are used. </member> <member name="node/name_casing" type="int" setter="" getter="" default="0"> When creating node names automatically, set the type of casing in this project. This is mostly an editor setting. @@ -729,19 +875,85 @@ <member name="node/name_num_separator" type="int" setter="" getter="" default="0"> What to use to separate node name from number. This is mostly an editor setting. </member> + <member name="physics/2d/bp_hash_table_size" type="int" setter="" getter="" default="4096"> + Size of the hash table used for the broad-phase 2D hash grid algorithm. + </member> + <member name="physics/2d/cell_size" type="int" setter="" getter="" default="128"> + Cell size used for the broad-phase 2D hash grid algorithm. + </member> + <member name="physics/2d/default_angular_damp" type="float" setter="" getter="" default="1.0"> + The default angular damp in 2D. + </member> <member name="physics/2d/default_gravity" type="int" setter="" getter="" default="98"> + The default gravity strength in 2D. + [b]Note:[/b] This property is only read when the project starts. To change the default gravity at runtime, use the following code sample: + [codeblock] + # Set the default gravity strength to 98. + Physics2DServer.area_set_param(get_viewport().find_world_2d().get_space(), Physics2DServer.AREA_PARAM_GRAVITY, 98) + [/codeblock] + </member> + <member name="physics/2d/default_gravity_vector" type="Vector2" setter="" getter="" default="Vector2( 0, 1 )"> + The default gravity direction in 2D. + [b]Note:[/b] This property is only read when the project starts. To change the default gravity vector at runtime, use the following code sample: + [codeblock] + # Set the default gravity direction to `Vector2(0, 1)`. + Physics2DServer.area_set_param(get_viewport().find_world_2d().get_space(), Physics2DServer.AREA_PARAM_GRAVITY_VECTOR, Vector2(0, 1)) + [/codeblock] + </member> + <member name="physics/2d/default_linear_damp" type="float" setter="" getter="" default="0.1"> + The default linear damp in 2D. + </member> + <member name="physics/2d/large_object_surface_threshold_in_cells" type="int" setter="" getter="" default="512"> + Threshold defining the surface size that constitutes a large object with regard to cells in the broad-phase 2D hash grid algorithm. </member> <member name="physics/2d/physics_engine" type="String" setter="" getter="" default=""DEFAULT""> + Sets which physics engine to use for 2D physics. + "DEFAULT" and "GodotPhysics" are the same, as there is currently no alternative 2D physics server implemented. + </member> + <member name="physics/2d/sleep_threshold_angular" type="float" setter="" getter="" default="0.139626"> + Threshold angular velocity under which a 2D physics body will be considered inactive. See [constant Physics2DServer.SPACE_PARAM_BODY_ANGULAR_VELOCITY_SLEEP_THRESHOLD]. + </member> + <member name="physics/2d/sleep_threshold_linear" type="float" setter="" getter="" default="2.0"> + Threshold linear velocity under which a 2D physics body will be considered inactive. See [constant Physics2DServer.SPACE_PARAM_BODY_LINEAR_VELOCITY_SLEEP_THRESHOLD]. </member> <member name="physics/2d/thread_model" type="int" setter="" getter="" default="1"> Sets whether physics is run on the main thread or a separate one. Running the server on a thread increases performance, but restricts API access to only physics process. + [b]Warning:[/b] As of Godot 3.2, there are mixed reports about the use of a Multi-Threaded thread model for physics. Be sure to assess whether it does give you extra performance and no regressions when using it. + </member> + <member name="physics/2d/time_before_sleep" type="float" setter="" getter="" default="0.5"> + Time (in seconds) of inactivity before which a 2D physics body will put to sleep. See [constant Physics2DServer.SPACE_PARAM_BODY_TIME_TO_SLEEP]. </member> <member name="physics/3d/active_soft_world" type="bool" setter="" getter="" default="true"> + Sets whether the 3D physics world will be created with support for [SoftBody] physics. Only applies to the Bullet physics engine. + </member> + <member name="physics/3d/default_angular_damp" type="float" setter="" getter="" default="0.1"> + The default angular damp in 3D. </member> <member name="physics/3d/default_gravity" type="float" setter="" getter="" default="9.8"> + The default gravity strength in 3D. + [b]Note:[/b] This property is only read when the project starts. To change the default gravity at runtime, use the following code sample: + [codeblock] + # Set the default gravity strength to 9.8. + PhysicsServer.area_set_param(get_viewport().find_world().get_space(), PhysicsServer.AREA_PARAM_GRAVITY, 9.8) + [/codeblock] + </member> + <member name="physics/3d/default_gravity_vector" type="Vector3" setter="" getter="" default="Vector3( 0, -1, 0 )"> + The default gravity direction in 3D. + [b]Note:[/b] This property is only read when the project starts. To change the default gravity vector at runtime, use the following code sample: + [codeblock] + # Set the default gravity direction to `Vector3(0, -1, 0)`. + PhysicsServer.area_set_param(get_viewport().find_world().get_space(), PhysicsServer.AREA_PARAM_GRAVITY_VECTOR, Vector3(0, -1, 0)) + [/codeblock] + </member> + <member name="physics/3d/default_linear_damp" type="float" setter="" getter="" default="0.1"> + The default linear damp in 3D. </member> <member name="physics/3d/physics_engine" type="String" setter="" getter="" default=""DEFAULT""> - Sets which physics engine to use. + Sets which physics engine to use for 3D physics. + "DEFAULT" is currently the [url=https://bulletphysics.org]Bullet[/url] physics engine. The "GodotPhysics" engine is still supported as an alternative. + </member> + <member name="physics/common/enable_object_picking" type="bool" setter="" getter="" default="true"> + Enables [member Viewport.physics_object_picking] on the root viewport. </member> <member name="physics/common/physics_fps" type="int" setter="" getter="" default="60"> Frames per second used in the physics. Physics always needs a fixed amount of frames per second. @@ -752,6 +964,9 @@ <member name="rendering/environment/default_clear_color" type="Color" setter="" getter="" default="Color( 0.3, 0.3, 0.3, 1 )"> Default background clear color. Overridable per [Viewport] using its [Environment]. See [member Environment.background_mode] and [member Environment.background_color] in particular. To change this default color programmatically, use [method VisualServer.set_default_clear_color]. </member> + <member name="rendering/environment/default_environment" type="String" setter="" getter="" default=""""> + [Environment] that will be used as a fallback environment in case a scene does not specify its own environment. The default environment is loaded in at scene load time regardless of whether you have set an environment or not. If you do not rely on the fallback environment, it is best to delete [code]default_env.tres[/code], or to specify a different default environment here. + </member> <member name="rendering/limits/buffers/blend_shape_max_buffer_size_kb" type="int" setter="" getter="" default="4096"> Max buffer size for blend shapes. Any blend shape bigger than this will not work. </member> @@ -783,6 +998,13 @@ <member name="rendering/quality/2d/use_pixel_snap" type="bool" setter="" getter="" default="false"> If [code]true[/code], forces snapping of polygons to pixels in 2D rendering. May help in some pixel art styles. </member> + <member name="rendering/quality/depth/hdr" type="bool" setter="" getter="" default="true"> + If [code]true[/code], allocates the main framebuffer with high dynamic range. High dynamic range allows the use of [Color] values greater than 1. + [b]Note:[/b] Only available on the GLES3 backend. + </member> + <member name="rendering/quality/depth/hdr.mobile" type="bool" setter="" getter="" default="false"> + Lower-end override for [member rendering/quality/depth/hdr] on mobile devices, due to performance concerns or driver support. + </member> <member name="rendering/quality/depth_prepass/disable_for_vendors" type="String" setter="" getter="" default=""PowerVR,Mali,Adreno,Apple""> Disables depth pre-pass for some GPU vendors (usually mobile), as their architecture already does this. </member> @@ -793,6 +1015,7 @@ The directional shadow's size in pixels. Higher values will result in sharper shadows, at the cost of performance. The value will be rounded up to the nearest power of 2. </member> <member name="rendering/quality/directional_shadow/size.mobile" type="int" setter="" getter="" default="2048"> + Lower-end override for [member rendering/quality/directional_shadow/size] on mobile devices, due to performance concerns or driver support. </member> <member name="rendering/quality/driver/driver_name" type="String" setter="" getter="" default=""GLES3""> The video driver to use ("GLES2" or "GLES3"). @@ -805,38 +1028,58 @@ <member name="rendering/quality/filters/anisotropic_filter_level" type="int" setter="" getter="" default="4"> Maximum anisotropic filter level used for textures with anisotropy enabled. Higher values will result in sharper textures when viewed from oblique angles, at the cost of performance. Only power-of-two values are valid (2, 4, 8, 16). </member> + <member name="rendering/quality/filters/msaa" type="int" setter="" getter="" default="0"> + Sets the number of MSAA samples to use. MSAA is used to reduce aliasing around the edges of polygons. A higher MSAA value results in smoother edges but can be significantly slower on some hardware. + [b]Note:[/b] MSAA is not available on HTML5 export using the GLES2 backend. + </member> <member name="rendering/quality/filters/use_nearest_mipmap_filter" type="bool" setter="" getter="" default="false"> If [code]true[/code], uses nearest-neighbor mipmap filtering when using mipmaps (also called "bilinear filtering"), which will result in visible seams appearing between mipmap stages. This may increase performance in mobile as less memory bandwidth is used. If [code]false[/code], linear mipmap filtering (also called "trilinear filtering") is used. </member> <member name="rendering/quality/intended_usage/framebuffer_allocation" type="int" setter="" getter="" default="2"> - Strategy used for framebuffer allocation. The simpler it is, the less resources it uses (but the less features it supports). + Strategy used for framebuffer allocation. The simpler it is, the less resources it uses (but the less features it supports). If set to "2D Without Sampling" or "3D Without Effects", sample buffers will not be allocated. This means [code]SCREEN_TEXTURE[/code] and [code]DEPTH_TEXTURE[/code] will not be available in shaders and post-processing effects will not be available in the [Environment]. </member> <member name="rendering/quality/intended_usage/framebuffer_allocation.mobile" type="int" setter="" getter="" default="3"> + Lower-end override for [member rendering/quality/intended_usage/framebuffer_allocation] on mobile devices, due to performance concerns or driver support. + </member> + <member name="rendering/quality/reflections/atlas_size" type="int" setter="" getter="" default="2048"> + Size of the atlas used by reflection probes. A larger size can result in higher visual quality, while a smaller size will be faster and take up less memory. + </member> + <member name="rendering/quality/reflections/atlas_subdiv" type="int" setter="" getter="" default="8"> + Number of subdivisions to use for the reflection atlas. A higher number lowers the quality of each atlas, but allows you to use more. </member> <member name="rendering/quality/reflections/high_quality_ggx" type="bool" setter="" getter="" default="true"> If [code]true[/code], uses a high amount of samples to create blurred variants of reflection probes and panorama backgrounds (sky). Those blurred variants are used by rough materials. </member> <member name="rendering/quality/reflections/high_quality_ggx.mobile" type="bool" setter="" getter="" default="false"> + Lower-end override for [member rendering/quality/reflections/high_quality_ggx] on mobile devices, due to performance concerns or driver support. + </member> + <member name="rendering/quality/reflections/irradiance_max_size" type="int" setter="" getter="" default="128"> + Limits the size of the irradiance map which is normally determined by [member Sky.radiance_size]. A higher size results in a higher quality irradiance map similarly to [member rendering/quality/reflections/high_quality_ggx]. Use a higher value when using high-frequency HDRI maps, otherwise keep this as low as possible. + [b]Note:[/b] Low and mid range hardware do not support complex irradiance maps well and may crash if this is set too high. </member> <member name="rendering/quality/reflections/texture_array_reflections" type="bool" setter="" getter="" default="true"> If [code]true[/code], uses texture arrays instead of mipmaps for reflection probes and panorama backgrounds (sky). This reduces jitter noise on reflections, but costs more performance and memory. </member> <member name="rendering/quality/reflections/texture_array_reflections.mobile" type="bool" setter="" getter="" default="false"> + Lower-end override for [member rendering/quality/reflections/texture_array_reflections] on mobile devices, due to performance concerns or driver support. </member> <member name="rendering/quality/shading/force_blinn_over_ggx" type="bool" setter="" getter="" default="false"> If [code]true[/code], uses faster but lower-quality Blinn model to generate blurred reflections instead of the GGX model. </member> <member name="rendering/quality/shading/force_blinn_over_ggx.mobile" type="bool" setter="" getter="" default="true"> + Lower-end override for [member rendering/quality/shading/force_blinn_over_ggx] on mobile devices, due to performance concerns or driver support. </member> <member name="rendering/quality/shading/force_lambert_over_burley" type="bool" setter="" getter="" default="false"> If [code]true[/code], uses faster but lower-quality Lambert material lighting model instead of Burley. </member> <member name="rendering/quality/shading/force_lambert_over_burley.mobile" type="bool" setter="" getter="" default="true"> + Lower-end override for [member rendering/quality/shading/force_lambert_over_burley] on mobile devices, due to performance concerns or driver support. </member> <member name="rendering/quality/shading/force_vertex_shading" type="bool" setter="" getter="" default="false"> If [code]true[/code], forces vertex shading for all rendering. This can increase performance a lot, but also reduces quality immensely. Can be used to optimize performance on low-end mobile devices. </member> <member name="rendering/quality/shading/force_vertex_shading.mobile" type="bool" setter="" getter="" default="true"> + Lower-end override for [member rendering/quality/shading/force_vertex_shading] on mobile devices, due to performance concerns or driver support. </member> <member name="rendering/quality/shadow_atlas/quadrant_0_subdiv" type="int" setter="" getter="" default="1"> Subdivision quadrant size for shadow mapping. See shadow mapping documentation. @@ -854,19 +1097,22 @@ Size for shadow atlas (used for OmniLights and SpotLights). See documentation. </member> <member name="rendering/quality/shadow_atlas/size.mobile" type="int" setter="" getter="" default="2048"> + Lower-end override for [member rendering/quality/shadow_atlas/size] on mobile devices, due to performance concerns or driver support. </member> <member name="rendering/quality/shadows/filter_mode" type="int" setter="" getter="" default="1"> Shadow filter mode. Higher-quality settings result in smoother shadows that flicker less when moving. "Disabled" is the fastest option, but also has the lowest quality. "PCF5" is smoother but is also slower. "PCF13" is the smoothest option, but is also the slowest. </member> <member name="rendering/quality/shadows/filter_mode.mobile" type="int" setter="" getter="" default="0"> + Lower-end override for [member rendering/quality/shadows/filter_mode] on mobile devices, due to performance concerns or driver support. </member> <member name="rendering/quality/subsurface_scattering/follow_surface" type="bool" setter="" getter="" default="false"> Improves quality of subsurface scattering, but cost significantly increases. </member> <member name="rendering/quality/subsurface_scattering/quality" type="int" setter="" getter="" default="1"> - Quality setting for subsurface scaterring (samples taken). + Quality setting for subsurface scattering (samples taken). </member> <member name="rendering/quality/subsurface_scattering/scale" type="int" setter="" getter="" default="1.0"> + Max radius used for subsurface scattering samples. </member> <member name="rendering/quality/subsurface_scattering/weight_samples" type="bool" setter="" getter="" default="true"> Weight subsurface scattering samples. Helps to avoid reading samples from unrelated parts of the screen. @@ -892,8 +1138,6 @@ <member name="rendering/vram_compression/import_s3tc" type="bool" setter="" getter="" default="true"> If [code]true[/code], the texture importer will import VRAM-compressed textures using the S3 Texture Compression algorithm. This algorithm is only supported on desktop platforms and consoles. </member> - <member name="script" type="Script" setter="" getter=""> - </member> </members> <constants> </constants> diff --git a/doc/classes/ProximityGroup.xml b/doc/classes/ProximityGroup.xml index 3c081bf91f..dee1a3daf0 100644 --- a/doc/classes/ProximityGroup.xml +++ b/doc/classes/ProximityGroup.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ProximityGroup" inherits="Spatial" category="Core" version="3.2"> +<class name="ProximityGroup" inherits="Spatial" version="4.0"> <brief_description> General-purpose proximity detection node. </brief_description> diff --git a/doc/classes/ProxyTexture.xml b/doc/classes/ProxyTexture.xml index 36c65f1096..fdff8908d5 100644 --- a/doc/classes/ProxyTexture.xml +++ b/doc/classes/ProxyTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ProxyTexture" inherits="Texture" category="Core" version="3.2"> +<class name="ProxyTexture" inherits="Texture" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/QuadMesh.xml b/doc/classes/QuadMesh.xml index 209e91eef2..422add08d1 100644 --- a/doc/classes/QuadMesh.xml +++ b/doc/classes/QuadMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="QuadMesh" inherits="PrimitiveMesh" category="Core" version="3.2"> +<class name="QuadMesh" inherits="PrimitiveMesh" version="4.0"> <brief_description> Class representing a square mesh. </brief_description> diff --git a/doc/classes/Quat.xml b/doc/classes/Quat.xml index eeb633f480..f11f20f1f9 100644 --- a/doc/classes/Quat.xml +++ b/doc/classes/Quat.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Quat" category="Built-In Types" version="3.2"> +<class name="Quat" version="4.0"> <brief_description> Quaternion. </brief_description> @@ -195,6 +195,7 @@ </members> <constants> <constant name="IDENTITY" value="Quat( 0, 0, 0, 1 )"> + The identity rotation. Equivalent to an identity matrix. If a vector is transformed by an identity quaternion, it will not change. </constant> </constants> </class> diff --git a/doc/classes/RID.xml b/doc/classes/RID.xml index 5edef100c5..77c608fccb 100644 --- a/doc/classes/RID.xml +++ b/doc/classes/RID.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RID" category="Built-In Types" version="3.2"> +<class name="RID" version="4.0"> <brief_description> Handle for a [Resource]'s unique ID. </brief_description> diff --git a/doc/classes/RandomNumberGenerator.xml b/doc/classes/RandomNumberGenerator.xml index 9054e2fa88..ec0f1a96b2 100644 --- a/doc/classes/RandomNumberGenerator.xml +++ b/doc/classes/RandomNumberGenerator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RandomNumberGenerator" inherits="Reference" category="Core" version="3.2"> +<class name="RandomNumberGenerator" inherits="Reference" version="4.0"> <brief_description> A class for generating pseudo-random numbers. </brief_description> diff --git a/doc/classes/Range.xml b/doc/classes/Range.xml index 82fffd0cb8..8690f6d7e7 100644 --- a/doc/classes/Range.xml +++ b/doc/classes/Range.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Range" inherits="Control" category="Core" version="3.2"> +<class name="Range" inherits="Control" version="4.0"> <brief_description> Abstract base class for range-based controls. </brief_description> diff --git a/doc/classes/RayCast.xml b/doc/classes/RayCast.xml index 5e17d6e7d7..65f632ba74 100644 --- a/doc/classes/RayCast.xml +++ b/doc/classes/RayCast.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RayCast" inherits="Spatial" category="Core" version="3.2"> +<class name="RayCast" inherits="Spatial" version="4.0"> <brief_description> Query the closest object intersecting a ray. </brief_description> diff --git a/doc/classes/RayCast2D.xml b/doc/classes/RayCast2D.xml index c5ba5da24e..51f3f0334d 100644 --- a/doc/classes/RayCast2D.xml +++ b/doc/classes/RayCast2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RayCast2D" inherits="Node2D" category="Core" version="3.2"> +<class name="RayCast2D" inherits="Node2D" version="4.0"> <brief_description> Query the closest object intersecting a ray. </brief_description> diff --git a/doc/classes/RayShape.xml b/doc/classes/RayShape.xml index 3f5859714e..87a642f779 100644 --- a/doc/classes/RayShape.xml +++ b/doc/classes/RayShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RayShape" inherits="Shape" category="Core" version="3.2"> +<class name="RayShape" inherits="Shape" version="4.0"> <brief_description> Ray shape for 3D collisions. </brief_description> diff --git a/doc/classes/RayShape2D.xml b/doc/classes/RayShape2D.xml index 377a19e8da..432c650074 100644 --- a/doc/classes/RayShape2D.xml +++ b/doc/classes/RayShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RayShape2D" inherits="Shape2D" category="Core" version="3.2"> +<class name="RayShape2D" inherits="Shape2D" version="4.0"> <brief_description> Ray shape for 2D collisions. </brief_description> diff --git a/doc/classes/Rect2.xml b/doc/classes/Rect2.xml index 90dd996691..e32b19ff00 100644 --- a/doc/classes/Rect2.xml +++ b/doc/classes/Rect2.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Rect2" category="Built-In Types" version="3.2"> +<class name="Rect2" version="4.0"> <brief_description> 2D axis-aligned bounding box. </brief_description> diff --git a/doc/classes/RectangleShape2D.xml b/doc/classes/RectangleShape2D.xml index d55324c98f..b42cc48d43 100644 --- a/doc/classes/RectangleShape2D.xml +++ b/doc/classes/RectangleShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RectangleShape2D" inherits="Shape2D" category="Core" version="3.2"> +<class name="RectangleShape2D" inherits="Shape2D" version="4.0"> <brief_description> Rectangle shape for 2D collisions. </brief_description> diff --git a/doc/classes/Reference.xml b/doc/classes/Reference.xml index 70d41b665a..860a47798c 100644 --- a/doc/classes/Reference.xml +++ b/doc/classes/Reference.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Reference" inherits="Object" category="Core" version="3.2"> +<class name="Reference" inherits="Object" version="4.0"> <brief_description> Base class for reference-counted objects. </brief_description> diff --git a/doc/classes/ReferenceRect.xml b/doc/classes/ReferenceRect.xml index 393a72cf60..4f8f71b3db 100644 --- a/doc/classes/ReferenceRect.xml +++ b/doc/classes/ReferenceRect.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ReferenceRect" inherits="Control" category="Core" version="3.2"> +<class name="ReferenceRect" inherits="Control" version="4.0"> <brief_description> Reference frame for GUI. </brief_description> diff --git a/doc/classes/ReflectionProbe.xml b/doc/classes/ReflectionProbe.xml index 0a1cf962c8..9c7a645fec 100644 --- a/doc/classes/ReflectionProbe.xml +++ b/doc/classes/ReflectionProbe.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ReflectionProbe" inherits="VisualInstance" category="Core" version="3.2"> +<class name="ReflectionProbe" inherits="VisualInstance" version="4.0"> <brief_description> Captures its surroundings to create reflections. </brief_description> <description> Capture its surroundings as a dual parabolid image, and stores versions of it with increasing levels of blur to simulate different material roughnesses. + The [ReflectionProbe] is used to create high-quality reflections at the cost of performance. It can be combined with [GIProbe]s and Screen Space Reflections to achieve high quality reflections. [ReflectionProbe]s render all objects within their [member cull_mask], so updating them can be quite expensive. It is best to update them once with the important static objects and then leave them. </description> <tutorials> <link>https://docs.godotengine.org/en/latest/tutorials/3d/reflection_probes.html</link> @@ -16,34 +17,45 @@ If [code]true[/code], enables box projection. This makes reflections look more correct in rectangle-shaped rooms by offsetting the reflection center depending on the camera's location. </member> <member name="cull_mask" type="int" setter="set_cull_mask" getter="get_cull_mask" default="1048575"> + Sets the cull mask which determines what objects are drawn by this probe. Every [VisualInstance] with a layer included in this cull mask will be rendered by the probe. It is best to only include large objects which are likely to take up a lot of space in the reflection in order to save on rendering cost. </member> <member name="enable_shadows" type="bool" setter="set_enable_shadows" getter="are_shadows_enabled" default="false"> If [code]true[/code], computes shadows in the reflection probe. This makes the reflection probe slower to render; you may want to disable this if using the [constant UPDATE_ALWAYS] [member update_mode]. </member> <member name="extents" type="Vector3" setter="set_extents" getter="get_extents" default="Vector3( 1, 1, 1 )"> + The size of the reflection probe. The larger the extents the more space covered by the probe which will lower the perceived resolution. It is best to keep the extents only as large as you need them. </member> <member name="intensity" type="float" setter="set_intensity" getter="get_intensity" default="1.0"> - Defines the reflection intensity. + Defines the reflection intensity. Intensity modulates the strength of the reflection. </member> <member name="interior_ambient_color" type="Color" setter="set_interior_ambient" getter="get_interior_ambient" default="Color( 0, 0, 0, 1 )"> + Sets the ambient light color to be used when this probe is set to [member interior_enable]. </member> <member name="interior_ambient_contrib" type="float" setter="set_interior_ambient_probe_contribution" getter="get_interior_ambient_probe_contribution" default="0.0"> + Sets the contribution value for how much the reflection affects the ambient light for this reflection probe when set to [member interior_enable]. Useful so that ambient light matches the color of the room. </member> <member name="interior_ambient_energy" type="float" setter="set_interior_ambient_energy" getter="get_interior_ambient_energy" default="1.0"> + Sets the energy multiplier for this reflection probe's ambient light contribution when set to [member interior_enable]. </member> <member name="interior_enable" type="bool" setter="set_as_interior" getter="is_set_as_interior" default="false"> + If [code]true[/code], reflections will ignore sky contribution. Ambient lighting is then controlled by the [code]interior_ambient_*[/code] properties. </member> <member name="max_distance" type="float" setter="set_max_distance" getter="get_max_distance" default="0.0"> + Sets the max distance away from the probe an object can be before it is culled. </member> <member name="origin_offset" type="Vector3" setter="set_origin_offset" getter="get_origin_offset" default="Vector3( 0, 0, 0 )"> + Sets the origin offset to be used when this reflection probe is in box project mode. </member> <member name="update_mode" type="int" setter="set_update_mode" getter="get_update_mode" enum="ReflectionProbe.UpdateMode" default="0"> + Sets how frequently the probe is updated. Can be [constant UPDATE_ONCE] or [constant UPDATE_ALWAYS]. </member> </members> <constants> <constant name="UPDATE_ONCE" value="0" enum="UpdateMode"> + Update the probe once on the next frame. </constant> <constant name="UPDATE_ALWAYS" value="1" enum="UpdateMode"> + Update the probe every frame. This is needed when you want to capture dynamic objects. However, it results in an increased render time. Use [constant UPDATE_ONCE] whenever possible. </constant> </constants> </class> diff --git a/doc/classes/RemoteTransform.xml b/doc/classes/RemoteTransform.xml index 377f9cc34b..feb6ac1841 100644 --- a/doc/classes/RemoteTransform.xml +++ b/doc/classes/RemoteTransform.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RemoteTransform" inherits="Spatial" category="Core" version="3.2"> +<class name="RemoteTransform" inherits="Spatial" version="4.0"> <brief_description> RemoteTransform pushes its own [Transform] to another [Spatial] derived Node in the scene. </brief_description> diff --git a/doc/classes/RemoteTransform2D.xml b/doc/classes/RemoteTransform2D.xml index f5d509782f..84ec673920 100644 --- a/doc/classes/RemoteTransform2D.xml +++ b/doc/classes/RemoteTransform2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RemoteTransform2D" inherits="Node2D" category="Core" version="3.2"> +<class name="RemoteTransform2D" inherits="Node2D" version="4.0"> <brief_description> RemoteTransform2D pushes its own [Transform2D] to another [CanvasItem] derived Node in the scene. </brief_description> diff --git a/doc/classes/Resource.xml b/doc/classes/Resource.xml index a50f5c97d1..496b1c4f3c 100644 --- a/doc/classes/Resource.xml +++ b/doc/classes/Resource.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Resource" inherits="Reference" category="Core" version="3.2"> +<class name="Resource" inherits="Reference" version="4.0"> <brief_description> Base class for all resources. </brief_description> diff --git a/doc/classes/ResourceFormatLoader.xml b/doc/classes/ResourceFormatLoader.xml index ce37691e0a..fc36f922e1 100644 --- a/doc/classes/ResourceFormatLoader.xml +++ b/doc/classes/ResourceFormatLoader.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourceFormatLoader" inherits="Reference" category="Core" version="3.2"> +<class name="ResourceFormatLoader" inherits="Reference" version="4.0"> <brief_description> Loads a specific resource type from a file. </brief_description> diff --git a/doc/classes/ResourceFormatLoaderCrypto.xml b/doc/classes/ResourceFormatLoaderCrypto.xml index 8bc7d50c75..fda529fdbd 100644 --- a/doc/classes/ResourceFormatLoaderCrypto.xml +++ b/doc/classes/ResourceFormatLoaderCrypto.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourceFormatLoaderCrypto" inherits="ResourceFormatLoader" category="Core" version="3.2"> +<class name="ResourceFormatLoaderCrypto" inherits="ResourceFormatLoader" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/ResourceFormatSaver.xml b/doc/classes/ResourceFormatSaver.xml index 5ad5ab49b1..369c158ce4 100644 --- a/doc/classes/ResourceFormatSaver.xml +++ b/doc/classes/ResourceFormatSaver.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourceFormatSaver" inherits="Reference" category="Core" version="3.2"> +<class name="ResourceFormatSaver" inherits="Reference" version="4.0"> <brief_description> Saves a specific resource type to a file. </brief_description> diff --git a/doc/classes/ResourceFormatSaverCrypto.xml b/doc/classes/ResourceFormatSaverCrypto.xml index 2f7d224dab..31db8ff4f5 100644 --- a/doc/classes/ResourceFormatSaverCrypto.xml +++ b/doc/classes/ResourceFormatSaverCrypto.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourceFormatSaverCrypto" inherits="ResourceFormatSaver" category="Core" version="3.2"> +<class name="ResourceFormatSaverCrypto" inherits="ResourceFormatSaver" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/ResourceImporter.xml b/doc/classes/ResourceImporter.xml index e0c0aa9a47..0475d2c94d 100644 --- a/doc/classes/ResourceImporter.xml +++ b/doc/classes/ResourceImporter.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourceImporter" inherits="Reference" category="Core" version="3.2"> +<class name="ResourceImporter" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/ResourceInteractiveLoader.xml b/doc/classes/ResourceInteractiveLoader.xml index df552d3656..64e94c4f2d 100644 --- a/doc/classes/ResourceInteractiveLoader.xml +++ b/doc/classes/ResourceInteractiveLoader.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourceInteractiveLoader" inherits="Reference" category="Core" version="3.2"> +<class name="ResourceInteractiveLoader" inherits="Reference" version="4.0"> <brief_description> Interactive [Resource] loader. </brief_description> diff --git a/doc/classes/ResourceLoader.xml b/doc/classes/ResourceLoader.xml index 31bba18171..661043b083 100644 --- a/doc/classes/ResourceLoader.xml +++ b/doc/classes/ResourceLoader.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourceLoader" inherits="Object" category="Core" version="3.2"> +<class name="ResourceLoader" inherits="Object" version="4.0"> <brief_description> Singleton used to load resource files. </brief_description> diff --git a/doc/classes/ResourcePreloader.xml b/doc/classes/ResourcePreloader.xml index 2b00c038e1..1e0dcaaea8 100644 --- a/doc/classes/ResourcePreloader.xml +++ b/doc/classes/ResourcePreloader.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourcePreloader" inherits="Node" category="Core" version="3.2"> +<class name="ResourcePreloader" inherits="Node" version="4.0"> <brief_description> Resource Preloader Node. </brief_description> diff --git a/doc/classes/ResourceSaver.xml b/doc/classes/ResourceSaver.xml index f12d26d4b9..8c27b951f5 100644 --- a/doc/classes/ResourceSaver.xml +++ b/doc/classes/ResourceSaver.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ResourceSaver" inherits="Object" category="Core" version="3.2"> +<class name="ResourceSaver" inherits="Object" version="4.0"> <brief_description> Singleton for saving Godot-specific resource types. </brief_description> diff --git a/doc/classes/RichTextEffect.xml b/doc/classes/RichTextEffect.xml index 0e043b1d50..34431c5153 100644 --- a/doc/classes/RichTextEffect.xml +++ b/doc/classes/RichTextEffect.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RichTextEffect" inherits="Resource" category="Core" version="3.2"> +<class name="RichTextEffect" inherits="Resource" version="4.0"> <brief_description> A custom effect for use with [RichTextLabel]. </brief_description> @@ -13,7 +13,7 @@ [b]Note:[/b] As soon as a [RichTextLabel] contains at least one [RichTextEffect], it will continuously process the effect unless the project is paused. This may impact battery life negatively. </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/gui/bbcode_in_richtextlabel.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/gui/bbcode_in_richtextlabel.html</link> <link>https://github.com/Eoin-ONeill-Yokai/Godot-Rich-Text-Effect-Test-Project</link> </tutorials> <methods> diff --git a/doc/classes/RichTextLabel.xml b/doc/classes/RichTextLabel.xml index c3fb226b6a..bad3625abc 100644 --- a/doc/classes/RichTextLabel.xml +++ b/doc/classes/RichTextLabel.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RichTextLabel" inherits="Control" category="Core" version="3.2"> +<class name="RichTextLabel" inherits="Control" version="4.0"> <brief_description> Label that displays rich text. </brief_description> @@ -325,21 +325,21 @@ </members> <signals> <signal name="meta_clicked"> - <argument index="0" name="meta" type="Nil"> + <argument index="0" name="meta" type="Variant"> </argument> <description> Triggered when the user clicks on content between meta tags. If the meta is defined in text, e.g. [code][url={"data"="hi"}]hi[/url][/code], then the parameter for this signal will be a [String] type. If a particular type or an object is desired, the [method push_meta] method must be used to manually insert the data into the tag stack. </description> </signal> <signal name="meta_hover_ended"> - <argument index="0" name="meta" type="Nil"> + <argument index="0" name="meta" type="Variant"> </argument> <description> Triggers when the mouse exits a meta tag. </description> </signal> <signal name="meta_hover_started"> - <argument index="0" name="meta" type="Nil"> + <argument index="0" name="meta" type="Variant"> </argument> <description> Triggers when the mouse enters a meta tag. diff --git a/doc/classes/RigidBody.xml b/doc/classes/RigidBody.xml index 624b576f4d..19c0363963 100644 --- a/doc/classes/RigidBody.xml +++ b/doc/classes/RigidBody.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RigidBody" inherits="PhysicsBody" category="Core" version="3.2"> +<class name="RigidBody" inherits="PhysicsBody" version="4.0"> <brief_description> Physics Body whose position is determined through physics simulation in 3D space. </brief_description> diff --git a/doc/classes/RigidBody2D.xml b/doc/classes/RigidBody2D.xml index c960ef5aee..958c6f0504 100644 --- a/doc/classes/RigidBody2D.xml +++ b/doc/classes/RigidBody2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RigidBody2D" inherits="PhysicsBody2D" category="Core" version="3.2"> +<class name="RigidBody2D" inherits="PhysicsBody2D" version="4.0"> <brief_description> A body that is controlled by the 2D physics engine. </brief_description> diff --git a/doc/classes/RootMotionView.xml b/doc/classes/RootMotionView.xml index bb939e82f3..654e42a3c6 100644 --- a/doc/classes/RootMotionView.xml +++ b/doc/classes/RootMotionView.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RootMotionView" inherits="VisualInstance" category="Core" version="3.2"> +<class name="RootMotionView" inherits="VisualInstance" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/SceneState.xml b/doc/classes/SceneState.xml index 3bd958bfd4..7304e03bf6 100644 --- a/doc/classes/SceneState.xml +++ b/doc/classes/SceneState.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SceneState" inherits="Reference" category="Core" version="3.2"> +<class name="SceneState" inherits="Reference" version="4.0"> <brief_description> A script interface to a scene file's data. </brief_description> diff --git a/doc/classes/SceneTree.xml b/doc/classes/SceneTree.xml index 6a4105ca2f..1499173d6b 100644 --- a/doc/classes/SceneTree.xml +++ b/doc/classes/SceneTree.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SceneTree" inherits="MainLoop" category="Core" version="3.2"> +<class name="SceneTree" inherits="MainLoop" version="4.0"> <brief_description> Manages the game loop via a hierarchy of nodes. </brief_description> @@ -329,9 +329,9 @@ </description> </signal> <signal name="global_menu_action"> - <argument index="0" name="id" type="Nil"> + <argument index="0" name="id" type="Variant"> </argument> - <argument index="1" name="meta" type="Nil"> + <argument index="1" name="meta" type="Variant"> </argument> <description> Emitted whenever global menu item is clicked. diff --git a/doc/classes/SceneTreeTimer.xml b/doc/classes/SceneTreeTimer.xml index 5678833752..a4a83fa65b 100644 --- a/doc/classes/SceneTreeTimer.xml +++ b/doc/classes/SceneTreeTimer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SceneTreeTimer" inherits="Reference" category="Core" version="3.2"> +<class name="SceneTreeTimer" inherits="Reference" version="4.0"> <brief_description> One-shot timer. </brief_description> diff --git a/doc/classes/Script.xml b/doc/classes/Script.xml index 91014580d3..0f07cb83f3 100644 --- a/doc/classes/Script.xml +++ b/doc/classes/Script.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Script" inherits="Resource" category="Core" version="3.2"> +<class name="Script" inherits="Resource" version="4.0"> <brief_description> A class stored as a resource. </brief_description> diff --git a/doc/classes/ScriptCreateDialog.xml b/doc/classes/ScriptCreateDialog.xml index 2991d76bec..9f16a6ed46 100644 --- a/doc/classes/ScriptCreateDialog.xml +++ b/doc/classes/ScriptCreateDialog.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ScriptCreateDialog" inherits="ConfirmationDialog" category="Core" version="3.2"> +<class name="ScriptCreateDialog" inherits="ConfirmationDialog" version="4.0"> <brief_description> The Editor's popup dialog for creating new [Script] files. </brief_description> diff --git a/doc/classes/ScriptEditor.xml b/doc/classes/ScriptEditor.xml index 28e1f75ac1..ed401d6853 100644 --- a/doc/classes/ScriptEditor.xml +++ b/doc/classes/ScriptEditor.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ScriptEditor" inherits="PanelContainer" category="Core" version="3.2"> +<class name="ScriptEditor" inherits="PanelContainer" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/ScrollBar.xml b/doc/classes/ScrollBar.xml index e4ace8e8ae..b1eb9c012b 100644 --- a/doc/classes/ScrollBar.xml +++ b/doc/classes/ScrollBar.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ScrollBar" inherits="Range" category="Core" version="3.2"> +<class name="ScrollBar" inherits="Range" version="4.0"> <brief_description> Base class for scroll bars. </brief_description> diff --git a/doc/classes/ScrollContainer.xml b/doc/classes/ScrollContainer.xml index 94920d57e5..0b113bebe5 100644 --- a/doc/classes/ScrollContainer.xml +++ b/doc/classes/ScrollContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ScrollContainer" inherits="Container" category="Core" version="3.2"> +<class name="ScrollContainer" inherits="Container" version="4.0"> <brief_description> A helper node for displaying scrollable elements such as lists. </brief_description> @@ -13,12 +13,14 @@ <return type="HScrollBar"> </return> <description> + Returns the horizontal scrollbar [HScrollBar] of this [ScrollContainer]. </description> </method> <method name="get_v_scrollbar"> <return type="VScrollBar"> </return> <description> + Returns the vertical scrollbar [VScrollBar] of this [ScrollContainer]. </description> </method> </methods> @@ -58,6 +60,7 @@ </constants> <theme_items> <theme_item name="bg" type="StyleBox"> + The background [StyleBox] of the [ScrollContainer]. </theme_item> </theme_items> </class> diff --git a/doc/classes/SegmentShape2D.xml b/doc/classes/SegmentShape2D.xml index e9e9d01a42..31c0f7f1f3 100644 --- a/doc/classes/SegmentShape2D.xml +++ b/doc/classes/SegmentShape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SegmentShape2D" inherits="Shape2D" category="Core" version="3.2"> +<class name="SegmentShape2D" inherits="Shape2D" version="4.0"> <brief_description> Segment shape for 2D collisions. </brief_description> diff --git a/doc/classes/Semaphore.xml b/doc/classes/Semaphore.xml index 74970be8b4..eca98fb10e 100644 --- a/doc/classes/Semaphore.xml +++ b/doc/classes/Semaphore.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Semaphore" inherits="Reference" category="Core" version="3.2"> +<class name="Semaphore" inherits="Reference" version="4.0"> <brief_description> A synchronization semaphore. </brief_description> diff --git a/doc/classes/Separator.xml b/doc/classes/Separator.xml index 11f6f1b22f..ef79851aab 100644 --- a/doc/classes/Separator.xml +++ b/doc/classes/Separator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Separator" inherits="Control" category="Core" version="3.2"> +<class name="Separator" inherits="Control" version="4.0"> <brief_description> Base class for separators. </brief_description> diff --git a/doc/classes/Shader.xml b/doc/classes/Shader.xml index be9509fda5..cab906ee25 100644 --- a/doc/classes/Shader.xml +++ b/doc/classes/Shader.xml @@ -1,13 +1,14 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Shader" inherits="Resource" category="Core" version="3.2"> +<class name="Shader" inherits="Resource" version="4.0"> <brief_description> A custom shader program. </brief_description> <description> - This class allows you to define a custom shader program that can be used for various materials to render objects. + This class allows you to define a custom shader program that can be used by a [ShaderMaterial]. Shaders allow you to write your own custom behavior for rendering objects or updating particle information. For a detailed explanation and usage, please see the tutorials linked below. </description> <tutorials> <link>https://docs.godotengine.org/en/latest/tutorials/shading/index.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/shading/your_first_shader/what_are_shaders.html</link> </tutorials> <methods> <method name="get_default_texture_param" qualifiers="const"> @@ -16,13 +17,15 @@ <argument index="0" name="param" type="String"> </argument> <description> + Returns the texture that is set as default for the specified parameter. + [b]Note:[/b] [code]param[/code] must match the name of the uniform in the code exactly. </description> </method> <method name="get_mode" qualifiers="const"> <return type="int" enum="Shader.Mode"> </return> <description> - Returns the shader mode for the shader, either [constant MODE_CANVAS_ITEM], [constant MODE_SPATIAL] or [constant MODE_PARTICLES] + Returns the shader mode for the shader, either [constant MODE_CANVAS_ITEM], [constant MODE_SPATIAL] or [constant MODE_PARTICLES]. </description> </method> <method name="has_param" qualifiers="const"> @@ -31,6 +34,8 @@ <argument index="0" name="name" type="String"> </argument> <description> + Returns [code]true[/code] if the shader has this param defined as a uniform in its code. + [b]Note:[/b] [code]param[/code] must match the name of the uniform in the code exactly. </description> </method> <method name="set_default_texture_param"> @@ -41,19 +46,25 @@ <argument index="1" name="texture" type="Texture"> </argument> <description> + Sets the default texture to be used with a texture uniform. The default is used if a texture is not set in the [ShaderMaterial]. + [b]Note:[/b] [code]param[/code] must match the name of the uniform in the code exactly. </description> </method> </methods> <members> <member name="code" type="String" setter="set_code" getter="get_code" default=""""> + Returns the shader's code as the user has written it, not the full generated code used internally. </member> </members> <constants> <constant name="MODE_SPATIAL" value="0" enum="Mode"> + Mode used to draw all 3D objects. </constant> <constant name="MODE_CANVAS_ITEM" value="1" enum="Mode"> + Mode used to draw all 2D objects. </constant> <constant name="MODE_PARTICLES" value="2" enum="Mode"> + Mode used to calculate particle information on a per-particle basis. Not used for drawing. </constant> </constants> </class> diff --git a/doc/classes/ShaderMaterial.xml b/doc/classes/ShaderMaterial.xml index ef355c4417..adb30c14d1 100644 --- a/doc/classes/ShaderMaterial.xml +++ b/doc/classes/ShaderMaterial.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ShaderMaterial" inherits="Material" category="Core" version="3.2"> +<class name="ShaderMaterial" inherits="Material" version="4.0"> <brief_description> A material that uses a custom [Shader] program. </brief_description> @@ -7,7 +7,7 @@ A material that uses a custom [Shader] program to render either items to screen or process particles. You can create multiple materials for the same shader but configure different values for the uniforms defined in the shader. </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/shading/index.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/shading/index.html</link> </tutorials> <methods> <method name="get_shader_param" qualifiers="const"> @@ -25,6 +25,7 @@ <argument index="0" name="name" type="String"> </argument> <description> + Returns [code]true[/code] if the property identified by [code]name[/code] can be reverted to a default value. </description> </method> <method name="property_get_revert"> @@ -33,6 +34,7 @@ <argument index="0" name="name" type="String"> </argument> <description> + Returns the default value of the material property with given [code]name[/code]. </description> </method> <method name="set_shader_param"> @@ -43,7 +45,7 @@ <argument index="1" name="value" type="Variant"> </argument> <description> - Changes the value set for this material of a uniform in the shader. + Changes the value set for this material of a uniform in the shader. [b]Note:[/b] [code]param[/code] must match the name of the uniform in the code exactly. </description> </method> </methods> diff --git a/doc/classes/Shape.xml b/doc/classes/Shape.xml index 123353b59a..d70d2c09b3 100644 --- a/doc/classes/Shape.xml +++ b/doc/classes/Shape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Shape" inherits="Resource" category="Core" version="3.2"> +<class name="Shape" inherits="Resource" version="4.0"> <brief_description> Base class for all 3D shape resources. </brief_description> diff --git a/doc/classes/Shape2D.xml b/doc/classes/Shape2D.xml index 70d55344ca..9e913cb44d 100644 --- a/doc/classes/Shape2D.xml +++ b/doc/classes/Shape2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Shape2D" inherits="Resource" category="Core" version="3.2"> +<class name="Shape2D" inherits="Resource" version="4.0"> <brief_description> Base class for all 2D shapes. </brief_description> diff --git a/doc/classes/ShortCut.xml b/doc/classes/ShortCut.xml index 4c5dc0e77b..9a2a761969 100644 --- a/doc/classes/ShortCut.xml +++ b/doc/classes/ShortCut.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ShortCut" inherits="Resource" category="Core" version="3.2"> +<class name="ShortCut" inherits="Resource" version="4.0"> <brief_description> A shortcut for binding input. </brief_description> diff --git a/doc/classes/Skeleton.xml b/doc/classes/Skeleton.xml index 7cd95390e6..1fc8b2eb35 100644 --- a/doc/classes/Skeleton.xml +++ b/doc/classes/Skeleton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Skeleton" inherits="Spatial" category="Core" version="3.2"> +<class name="Skeleton" inherits="Spatial" version="4.0"> <brief_description> Skeleton for characters and animated objects. </brief_description> diff --git a/doc/classes/Skeleton2D.xml b/doc/classes/Skeleton2D.xml index 886e8244a2..ccae59d72c 100644 --- a/doc/classes/Skeleton2D.xml +++ b/doc/classes/Skeleton2D.xml @@ -1,12 +1,12 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Skeleton2D" inherits="Node2D" category="Core" version="3.2"> +<class name="Skeleton2D" inherits="Node2D" version="4.0"> <brief_description> Skeleton for 2D characters and animated objects. </brief_description> <description> </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/animation/2d_skeletons.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/animation/2d_skeletons.html</link> </tutorials> <methods> <method name="get_bone"> diff --git a/doc/classes/SkeletonIK.xml b/doc/classes/SkeletonIK.xml index 2f35826cc7..0f07031708 100644 --- a/doc/classes/SkeletonIK.xml +++ b/doc/classes/SkeletonIK.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SkeletonIK" inherits="Node" category="Core" version="3.2"> +<class name="SkeletonIK" inherits="Node" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/Skin.xml b/doc/classes/Skin.xml index 174febc883..b65d9d8f98 100644 --- a/doc/classes/Skin.xml +++ b/doc/classes/Skin.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Skin" inherits="Resource" category="Core" version="3.2"> +<class name="Skin" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/SkinReference.xml b/doc/classes/SkinReference.xml index c12957654f..8fc163f88d 100644 --- a/doc/classes/SkinReference.xml +++ b/doc/classes/SkinReference.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SkinReference" inherits="Reference" category="Core" version="3.2"> +<class name="SkinReference" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/Sky.xml b/doc/classes/Sky.xml index 398a988d9e..11cea6dbc3 100644 --- a/doc/classes/Sky.xml +++ b/doc/classes/Sky.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Sky" inherits="Resource" category="Core" version="3.2"> +<class name="Sky" inherits="Resource" version="4.0"> <brief_description> The base class for [PanoramaSky] and [ProceduralSky]. </brief_description> @@ -14,6 +14,7 @@ <member name="radiance_size" type="int" setter="set_radiance_size" getter="get_radiance_size" enum="Sky.RadianceSize" default="2"> The [Sky]'s radiance map size. The higher the radiance map size, the more detailed the lighting from the [Sky] will be. See [enum RadianceSize] constants for values. + [b]Note:[/b] Some hardware will have trouble with higher radiance sizes, especially [constant RADIANCE_SIZE_512] and above. Only use such high values on high-end hardware. </member> </members> <constants> diff --git a/doc/classes/Slider.xml b/doc/classes/Slider.xml index 14176da44f..68776df603 100644 --- a/doc/classes/Slider.xml +++ b/doc/classes/Slider.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Slider" inherits="Range" category="Core" version="3.2"> +<class name="Slider" inherits="Range" version="4.0"> <brief_description> Base class for GUI sliders. </brief_description> diff --git a/doc/classes/SliderJoint.xml b/doc/classes/SliderJoint.xml index 3f22b5a37c..dc0cf96eb4 100644 --- a/doc/classes/SliderJoint.xml +++ b/doc/classes/SliderJoint.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SliderJoint" inherits="Joint" category="Core" version="3.2"> +<class name="SliderJoint" inherits="Joint" version="4.0"> <brief_description> Piston kind of slider between two bodies in 3D. </brief_description> diff --git a/doc/classes/SoftBody.xml b/doc/classes/SoftBody.xml index a51907b1bf..46a00fbd67 100644 --- a/doc/classes/SoftBody.xml +++ b/doc/classes/SoftBody.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SoftBody" inherits="MeshInstance" category="Core" version="3.2"> +<class name="SoftBody" inherits="MeshInstance" version="4.0"> <brief_description> A soft mesh physics body. </brief_description> diff --git a/doc/classes/Spatial.xml b/doc/classes/Spatial.xml index 0309e73eec..d057db8519 100644 --- a/doc/classes/Spatial.xml +++ b/doc/classes/Spatial.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Spatial" inherits="Node" category="Core" version="3.2"> +<class name="Spatial" inherits="Node" version="4.0"> <brief_description> Most basic 3D game object, parent of all 3D-related nodes. </brief_description> @@ -277,7 +277,7 @@ <argument index="0" name="offset" type="Vector3"> </argument> <description> - Changes the node's position by given offset [Vector3]. + Changes the node's position by the given offset [Vector3]. Note that the translation [code]offset[/code] is affected by the node's scale, so if scaled by e.g. [code](10, 1, 1)[/code], a translation by an offset of [code](2, 0, 0)[/code] would actually add 20 ([code]2 * 10[/code]) to the X coordinate. </description> </method> @@ -287,6 +287,7 @@ <argument index="0" name="offset" type="Vector3"> </argument> <description> + Changes the node's position by the given offset [Vector3] in local space. </description> </method> <method name="update_gizmo"> diff --git a/doc/classes/SpatialGizmo.xml b/doc/classes/SpatialGizmo.xml index 5cca1883b3..5260eaa8a3 100644 --- a/doc/classes/SpatialGizmo.xml +++ b/doc/classes/SpatialGizmo.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SpatialGizmo" inherits="Reference" category="Core" version="3.2"> +<class name="SpatialGizmo" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/SpatialMaterial.xml b/doc/classes/SpatialMaterial.xml index df315d7430..c6780511b9 100644 --- a/doc/classes/SpatialMaterial.xml +++ b/doc/classes/SpatialMaterial.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SpatialMaterial" inherits="Material" category="Core" version="3.2"> +<class name="SpatialMaterial" inherits="Material" version="4.0"> <brief_description> Default 3D rendering material. </brief_description> @@ -16,6 +16,7 @@ <argument index="0" name="feature" type="int" enum="SpatialMaterial.Feature"> </argument> <description> + Returns [code]true[/code], if the specified [enum Feature] is enabled. </description> </method> <method name="get_flag" qualifiers="const"> @@ -24,6 +25,7 @@ <argument index="0" name="flag" type="int" enum="SpatialMaterial.Flags"> </argument> <description> + Returns [code]true[/code], if the specified flag is enabled. See [enum Flags] enumerator for options. </description> </method> <method name="get_texture" qualifiers="const"> @@ -32,6 +34,7 @@ <argument index="0" name="param" type="int" enum="SpatialMaterial.TextureParam"> </argument> <description> + Returns the [Texture] associated with the specified [enum TextureParam]. </description> </method> <method name="set_feature"> @@ -42,6 +45,7 @@ <argument index="1" name="enable" type="bool"> </argument> <description> + If [code]true[/code], enables the specified [enum Feature]. Many features that are available in [SpatialMaterial]s need to be enabled before use. This way the cost for using the feature is only incurred when specified. Features can also be enabled by setting the corresponding member to [code]true[/code]. </description> </method> <method name="set_flag"> @@ -52,6 +56,7 @@ <argument index="1" name="enable" type="bool"> </argument> <description> + If [code]true[/code], enables the specified flag. Flags are optional behaviour that can be turned on and off. Only one flag can be enabled at a time with this function, the flag enumerators cannot be bit-masked together to enable or disable multiple flags at once. Flags can also be enabled by setting the corresponding member to [code]true[/code]. See [enum Flags] enumerator for options. </description> </method> <method name="set_texture"> @@ -62,6 +67,7 @@ <argument index="1" name="texture" type="Texture"> </argument> <description> + Sets the [Texture] to be used by the specified [enum TextureParam]. This function is called when setting members ending in [code]*_texture[/code]. </description> </method> </methods> @@ -70,86 +76,115 @@ The material's base color. </member> <member name="albedo_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture to multiply by [member albedo_color]. Used for basic texturing of objects. </member> <member name="anisotropy" type="float" setter="set_anisotropy" getter="get_anisotropy"> The strength of the anisotropy effect. </member> <member name="anisotropy_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> - If [code]true[/code], anisotropy is enabled. Changes the shape of the specular blob and aligns it to tangent space. + If [code]true[/code], anisotropy is enabled. Changes the shape of the specular blob and aligns it to tangent space. Mesh tangents are needed for this to work. If the mesh does not contain tangents the anisotropy effect will appear broken. </member> <member name="anisotropy_flowmap" type="Texture" setter="set_texture" getter="get_texture"> + Texture that offsets the tangent map for anisotropy calculations. </member> <member name="ao_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> - If [code]true[/code], ambient occlusion is enabled. + If [code]true[/code], ambient occlusion is enabled. Ambient occlusion darkens areas based on the [member ao_texture]. </member> <member name="ao_light_affect" type="float" setter="set_ao_light_affect" getter="get_ao_light_affect"> + Amount that ambient occlusion affects lighting from lights. If [code]0[/code], ambient occlusion only affects ambient light. If [code]1[/code], ambient occlusion affects lights just as much as it affects ambient light. This can be used to impact the strength of the ambient occlusion effect, but typically looks unrealistic. </member> <member name="ao_on_uv2" type="bool" setter="set_flag" getter="get_flag"> + If [code]true[/code], use [code]UV2[/code] coordinates to look up from the [member ao_texture]. </member> <member name="ao_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture that defines the amount of ambient occlusion for a given point on the object. </member> <member name="ao_texture_channel" type="int" setter="set_ao_texture_channel" getter="get_ao_texture_channel" enum="SpatialMaterial.TextureChannel"> + Specifies the channel of the [member ao_texture] in which the ambient occlusion information is stored. This is useful when you store the information for multiple effects in a single texture. For example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in the green you could reduce the number of textures you use. </member> <member name="clearcoat" type="float" setter="set_clearcoat" getter="get_clearcoat"> + Sets the strength of the clearcoat effect. Setting to [code]0[/code] looks the same as disabling the clearcoat effect. </member> <member name="clearcoat_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> - If [code]true[/code], clearcoat rendering is enabled. Adds a secondary transparent pass to the material. + If [code]true[/code], clearcoat rendering is enabled. Adds a secondary transparent pass to the lighting calculation resulting in an added specular blob. This makes materials appear as if they have a clear layer on them that can be either glossy or rough. </member> <member name="clearcoat_gloss" type="float" setter="set_clearcoat_gloss" getter="get_clearcoat_gloss"> + Sets the roughness of the clearcoat pass. A higher value results in a smoother clearcoat while a lower value results in a rougher clearcoat. </member> <member name="clearcoat_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture that defines the strength of the clearcoat effect and the glossiness of the clearcoat. Strength is specified in the red channel while glossiness is specified in the green channel. </member> <member name="depth_deep_parallax" type="bool" setter="set_depth_deep_parallax" getter="is_depth_deep_parallax_enabled"> + If [code]true[/code], the shader will read depth texture at multiple points along the view ray to determine occlusion and parrallax. This can be very performance demanding, but results in more realistic looking depth mapping. </member> <member name="depth_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> If [code]true[/code], depth mapping is enabled (also called "parallax mapping" or "height mapping"). See also [member normal_enabled]. </member> <member name="depth_flip_binormal" type="bool" setter="set_depth_deep_parallax_flip_binormal" getter="get_depth_deep_parallax_flip_binormal"> + If [code]true[/code], direction of the binormal is flipped before using in the depth effect. This may be necessary if you have encoded your binormals in a way that is conflicting with the depth effect. </member> <member name="depth_flip_tangent" type="bool" setter="set_depth_deep_parallax_flip_tangent" getter="get_depth_deep_parallax_flip_tangent"> + If [code]true[/code], direction of the tangent is flipped before using in the depth effect. This may be necessary if you have encoded your tangents in a way that is conflicting with the depth effect. </member> <member name="depth_max_layers" type="int" setter="set_depth_deep_parallax_max_layers" getter="get_depth_deep_parallax_max_layers"> + Number of layers to use when using [member depth_deep_parallax] and the view direction is perpendicular to the surface of the object. A higher number will be more performance demanding while a lower number may not look as crisp. </member> <member name="depth_min_layers" type="int" setter="set_depth_deep_parallax_min_layers" getter="get_depth_deep_parallax_min_layers"> + Number of layers to use when using [member depth_deep_parallax] and the view direction is parallel to the surface of the object. A higher number will be more performance demanding while a lower number may not look as crisp. </member> <member name="depth_scale" type="float" setter="set_depth_scale" getter="get_depth_scale"> + Scales the depth offset effect. A higher number will create a larger depth. </member> <member name="depth_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture used to determine depth at a given pixel. Depth is always stored in the red channel. </member> <member name="detail_albedo" type="Texture" setter="set_texture" getter="get_texture"> + Texture that specifies the color of the detail overlay. </member> <member name="detail_blend_mode" type="int" setter="set_detail_blend_mode" getter="get_detail_blend_mode" enum="SpatialMaterial.BlendMode"> + Specifies how the [member detail_albedo] should blend with the current [code]ALBEDO[/code]. See [enum BlendMode] for options. </member> <member name="detail_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> + If [code]true[/code], enables the detail overlay. Detail is a second texture that gets mixed over the surface of the object based on [member detail_mask]. This can be used to add variation to objects, or to blend between two different albedo/normal textures. </member> <member name="detail_mask" type="Texture" setter="set_texture" getter="get_texture"> + Texture used to specify how the detail textures get blended with the base textures. </member> <member name="detail_normal" type="Texture" setter="set_texture" getter="get_texture"> + Texture that specifies the per-pixel normal of the detail overlay. </member> <member name="detail_uv_layer" type="int" setter="set_detail_uv" getter="get_detail_uv" enum="SpatialMaterial.DetailUV"> + Specifies whether to use [code]UV[/code] or [code]UV2[/code] for the detail layer. See [enum DetailUV] for options. </member> <member name="distance_fade_max_distance" type="float" setter="set_distance_fade_max_distance" getter="get_distance_fade_max_distance"> + Distance at which the object fades fully and is no longer visible. </member> <member name="distance_fade_min_distance" type="float" setter="set_distance_fade_min_distance" getter="get_distance_fade_min_distance"> + Distance at which the object starts to fade. If the object is less than this distance away it will appear normal. </member> <member name="distance_fade_mode" type="int" setter="set_distance_fade" getter="get_distance_fade" enum="SpatialMaterial.DistanceFadeMode" default="0"> + Specifies which type of fade to use. Can be any of the [enum DistanceFadeMode]s. </member> <member name="emission" type="Color" setter="set_emission" getter="get_emission"> The emitted light's color. See [member emission_enabled]. </member> <member name="emission_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> - If [code]true[/code], the body emits light. + If [code]true[/code], the body emits light. Emitting light makes the object appear brighter. The object can also cast light on other objects if a [GIProbe] or [BakedLightmap] is used and this object is used in baked lighting. </member> <member name="emission_energy" type="float" setter="set_emission_energy" getter="get_emission_energy"> The emitted light's strength. See [member emission_enabled]. </member> <member name="emission_on_uv2" type="bool" setter="set_flag" getter="get_flag"> + Use [code]UV2[/code] to read from the [member emission_texture]. </member> <member name="emission_operator" type="int" setter="set_emission_operator" getter="get_emission_operator" enum="SpatialMaterial.EmissionOperator"> + Sets how [member emission] interacts with [member emission_texture]. Can either add or multiply. See [enum EmissionOperator] for options. </member> <member name="emission_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture that specifies how much surface emits light at a given point. </member> <member name="flags_albedo_tex_force_srgb" type="bool" setter="set_flag" getter="get_flag" default="false"> + Forces a conversion of the [member albedo_texture] from sRGB space to linear space. </member> <member name="flags_disable_ambient_light" type="bool" setter="set_flag" getter="get_flag" default="false"> If [code]true[/code], the object receives no ambient light. @@ -158,6 +193,7 @@ If [code]true[/code], the object receives no shadow that would otherwise be cast onto it. </member> <member name="flags_ensure_correct_normals" type="bool" setter="set_flag" getter="get_flag" default="false"> + If [code]true[/code], the shader will compute extra operations to make sure the normal stays correct when using a non-uniform scale. Only enable if using non-uniform scaling. </member> <member name="flags_fixed_size" type="bool" setter="set_flag" getter="get_flag" default="false"> If [code]true[/code], the object is rendered at the same size regardless of distance. @@ -176,6 +212,7 @@ [b]Note:[/b] this is only effective for objects whose geometry is point-based rather than triangle-based. See also [member params_point_size]. </member> <member name="flags_use_shadow_to_opacity" type="bool" setter="set_flag" getter="get_flag" default="false"> + If [code]true[/code], enables the "shadow to opacity" render mode where lighting modifies the alpha so shadowed areas are opaque and non-shadowed areas are transparent. Useful for overlaying shadows onto a camera feed in AR. </member> <member name="flags_vertex_lighting" type="bool" setter="set_flag" getter="get_flag" default="false"> If [code]true[/code], lighting is calculated per vertex rather than per pixel. This may increase performance on low-end devices. @@ -187,12 +224,14 @@ The reflectivity of the object's surface. The higher the value, the more light is reflected. </member> <member name="metallic_specular" type="float" setter="set_specular" getter="get_specular" default="0.5"> - General reflectivity amount. + Sets the size of the specular lobe. The specular lobe is the bright spot that is reflected from light sources. [b]Note:[/b] unlike [member metallic], this is not energy-conserving, so it should be left at [code]0.5[/code] in most cases. See also [member roughness]. </member> <member name="metallic_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture used to specify metallic for an object. This is multiplied by [member metallic]. </member> <member name="metallic_texture_channel" type="int" setter="set_metallic_texture_channel" getter="get_metallic_texture_channel" enum="SpatialMaterial.TextureChannel" default="0"> + Specifies the channel of the [member metallic_texture] in which the metallic information is stored. This is useful when you store the information for multiple effects in a single texture. For example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in the green you could reduce the number of textures you use. </member> <member name="normal_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> If [code]true[/code], normal mapping is enabled. @@ -201,10 +240,13 @@ The strength of the normal map's effect. </member> <member name="normal_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture used to specify the normal at a given pixel. The [code]normal_texture[/code] only uses the red and green channels. The normal read from [code]normal_texture[/code] is oriented around the surface normal provided by the [Mesh]. </member> <member name="params_alpha_scissor_threshold" type="float" setter="set_alpha_scissor_threshold" getter="get_alpha_scissor_threshold"> + Threshold at which the alpha scissor will discard values. </member> <member name="params_billboard_keep_scale" type="bool" setter="set_flag" getter="get_flag" default="false"> + If [code]true[/code], the shader will keep the scale set for the mesh. Otherwise the scale is lost when billboarding. Only applies when [member params_billboard_mode] is [constant BILLBOARD_ENABLED]. </member> <member name="params_billboard_mode" type="int" setter="set_billboard_mode" getter="get_billboard_mode" enum="SpatialMaterial.BillboardMode" default="0"> Controls how the object faces the camera. See [enum BillboardMode]. @@ -229,6 +271,7 @@ Grows object vertices in the direction of their normals. </member> <member name="params_line_width" type="float" setter="set_line_width" getter="get_line_width" default="1.0"> + Currently unimplemented in Godot. </member> <member name="params_point_size" type="float" setter="set_point_size" getter="get_point_size" default="1.0"> The point size in pixels. See [member flags_use_point_size]. @@ -237,6 +280,7 @@ The method for rendering the specular blob. See [enum SpecularMode]. </member> <member name="params_use_alpha_scissor" type="bool" setter="set_flag" getter="get_flag" default="false"> + If [code]true[/code], the shader will discard all pixels that have an alpha value less than [member params_alpha_scissor_threshold]. </member> <member name="particles_anim_h_frames" type="int" setter="set_particles_anim_h_frames" getter="get_particles_anim_h_frames"> The number of horizontal frames in the particle sprite sheet. Only enabled when using [constant BILLBOARD_PARTICLES]. See [member params_billboard_mode]. @@ -248,9 +292,10 @@ The number of vertical frames in the particle sprite sheet. Only enabled when using [constant BILLBOARD_PARTICLES]. See [member params_billboard_mode]. </member> <member name="proximity_fade_distance" type="float" setter="set_proximity_fade_distance" getter="get_proximity_fade_distance"> + Distance over which the fade effect takes place. The larger the distance the longer it takes for an object to fade. </member> <member name="proximity_fade_enable" type="bool" setter="set_proximity_fade" getter="is_proximity_fade_enabled" default="false"> - If [code]true[/code], the proximity and distance fade effect is enabled. + If [code]true[/code], the proximity fade effect is enabled. The proximity fade effect fades out each pixel based on its distance to another object. </member> <member name="refraction_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> If [code]true[/code], the refraction effect is enabled. Distorts transparency based on light from behind the object. @@ -259,15 +304,19 @@ The strength of the refraction effect. </member> <member name="refraction_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture that controls the strength of the refraction per-pixel. Multiplied by [member refraction_scale]. </member> <member name="refraction_texture_channel" type="int" setter="set_refraction_texture_channel" getter="get_refraction_texture_channel" enum="SpatialMaterial.TextureChannel"> + Specifies the channel of the [member ao_texture] in which the ambient occlusion information is stored. This is useful when you store the information for multiple effects in a single texture. For example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in the green you could reduce the number of textures you use. </member> <member name="rim" type="float" setter="set_rim" getter="get_rim"> + Sets the strength of the rim lighting effect. </member> <member name="rim_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> - If [code]true[/code], rim effect is enabled. + If [code]true[/code], rim effect is enabled. Rim lighting increases the brightness at glancing angles on an object. </member> <member name="rim_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture used to set the strength of the rim lighting effect per-pixel. Multiplied by [member rim]. </member> <member name="rim_tint" type="float" setter="set_rim_tint" getter="get_rim_tint"> The amount of to blend light and albedo color when rendering rim effect. If [code]0[/code] the light color is used, while [code]1[/code] means albedo color is used. An intermediate value generally works best. @@ -276,8 +325,10 @@ Surface reflection. A value of [code]0[/code] represents a perfect mirror while a value of [code]1[/code] completely blurs the reflection. See also [member metallic]. </member> <member name="roughness_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture used to control the roughness per-pixel. Multiplied by [member roughness]. </member> <member name="roughness_texture_channel" type="int" setter="set_roughness_texture_channel" getter="get_roughness_texture_channel" enum="SpatialMaterial.TextureChannel" default="0"> + Specifies the channel of the [member ao_texture] in which the ambient occlusion information is stored. This is useful when you store the information for multiple effects in a single texture. For example if you stored metallic in the red channel, roughness in the blue, and ambient occlusion in the green you could reduce the number of textures you use. </member> <member name="subsurf_scatter_enabled" type="bool" setter="set_feature" getter="get_feature" default="false"> If [code]true[/code], subsurface scattering is enabled. Emulates light that penetrates an object's surface, is scattered, and then emerges. @@ -286,6 +337,7 @@ The strength of the subsurface scattering effect. </member> <member name="subsurf_scatter_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture used to control the subsurface scattering strength. Stored in the red texture channel. Multiplied by [member subsurf_scatter_strength]. </member> <member name="transmission" type="Color" setter="set_transmission" getter="get_transmission"> The color used by the transmission effect. Represents the light passing through an object. @@ -294,22 +346,31 @@ If [code]true[/code], the transmission effect is enabled. </member> <member name="transmission_texture" type="Texture" setter="set_texture" getter="get_texture"> + Texture used to control the transmission effect per-pixel. Added to [member transmission]. </member> <member name="uv1_offset" type="Vector3" setter="set_uv1_offset" getter="get_uv1_offset" default="Vector3( 0, 0, 0 )"> + How much to offset the [code]UV[/code] coordinates. This amount will be added to [code]UV[/code] in the vertex function. This can be used to offset a texture. </member> <member name="uv1_scale" type="Vector3" setter="set_uv1_scale" getter="get_uv1_scale" default="Vector3( 1, 1, 1 )"> + How much to scale the [code]UV[/code] coordinates. This is multiplied by [code]UV[/code] in the vertex function. </member> <member name="uv1_triplanar" type="bool" setter="set_flag" getter="get_flag" default="false"> + If [code]true[/code], instead of using [code]UV[/code] textures will use a triplanar texture lookup to determine how to apply textures. Triplanar uses the orientation of the object's surface to blend between texture coordinates. It reads from the source texture 3 times, once for each axis and then blends between the results based on how closely the pixel aligns with each axis. This is often used for natural features to get a realistic blend of materials. Because triplanar texturing requires many more texture reads per-pixel it is much slower than normal UV texturing. Additionally, because it is blending the texture between the three axes, it is unsuitable when you are trying to achieve crisp texturing. </member> <member name="uv1_triplanar_sharpness" type="float" setter="set_uv1_triplanar_blend_sharpness" getter="get_uv1_triplanar_blend_sharpness" default="1.0"> + A lower number blends the texture more softly while a higher number blends the texture more sharply. </member> <member name="uv2_offset" type="Vector3" setter="set_uv2_offset" getter="get_uv2_offset" default="Vector3( 0, 0, 0 )"> + How much to offset the [code]UV2[/code] coordinates. This amount will be added to [code]UV2[/code] in the vertex function. This can be used to offset a texture. </member> <member name="uv2_scale" type="Vector3" setter="set_uv2_scale" getter="get_uv2_scale" default="Vector3( 1, 1, 1 )"> + How much to scale the [code]UV2[/code] coordinates. This is multiplied by [code]UV2[/code] in the vertex function. </member> <member name="uv2_triplanar" type="bool" setter="set_flag" getter="get_flag" default="false"> + If [code]true[/code], instead of using [code]UV2[/code] textures will use a triplanar texture lookup to determine how to apply textures. Triplanar uses the orientation of the object's surface to blend between texture coordinates. It reads from the source texture 3 times, once for each axis and then blends between the results based on how closely the pixel aligns with each axis. This is often used for natural features to get a realistic blend of materials. Because triplanar texturing requires many more texture reads per-pixel it is much slower than normal UV texturing. Additionally, because it is blending the texture between the three axes, it is unsuitable when you are trying to achieve crisp texturing. </member> <member name="uv2_triplanar_sharpness" type="float" setter="set_uv2_triplanar_blend_sharpness" getter="get_uv2_triplanar_blend_sharpness" default="1.0"> + A lower number blends the texture more softly while a higher number blends the texture more sharply. </member> <member name="vertex_color_is_srgb" type="bool" setter="set_flag" getter="get_flag" default="false"> If [code]true[/code], the model's vertex colors are processed as sRGB mode. @@ -320,79 +381,112 @@ </members> <constants> <constant name="TEXTURE_ALBEDO" value="0" enum="TextureParam"> + Texture specifying per-pixel color. </constant> <constant name="TEXTURE_METALLIC" value="1" enum="TextureParam"> + Texture specifying per-pixel metallic value. </constant> <constant name="TEXTURE_ROUGHNESS" value="2" enum="TextureParam"> + Texture specifying per-pixel roughness value. </constant> <constant name="TEXTURE_EMISSION" value="3" enum="TextureParam"> + Texture specifying per-pixel emission color. </constant> <constant name="TEXTURE_NORMAL" value="4" enum="TextureParam"> + Texture specifying per-pixel normal vector. </constant> <constant name="TEXTURE_RIM" value="5" enum="TextureParam"> + Texture specifying per-pixel rim value. </constant> <constant name="TEXTURE_CLEARCOAT" value="6" enum="TextureParam"> + Texture specifying per-pixel clearcoat value. </constant> <constant name="TEXTURE_FLOWMAP" value="7" enum="TextureParam"> + Texture specifying per-pixel flowmap direction for use with [member anisotropy]. </constant> <constant name="TEXTURE_AMBIENT_OCCLUSION" value="8" enum="TextureParam"> + Texture specifying per-pixel ambient occlusion value. </constant> <constant name="TEXTURE_DEPTH" value="9" enum="TextureParam"> + Texture specifying per-pixel depth. </constant> <constant name="TEXTURE_SUBSURFACE_SCATTERING" value="10" enum="TextureParam"> + Texture specifying per-pixel subsurface scattering. </constant> <constant name="TEXTURE_TRANSMISSION" value="11" enum="TextureParam"> + Texture specifying per-pixel transmission color. </constant> <constant name="TEXTURE_REFRACTION" value="12" enum="TextureParam"> + Texture specifying per-pixel refraction strength. </constant> <constant name="TEXTURE_DETAIL_MASK" value="13" enum="TextureParam"> + Texture specifying per-pixel detail mask blending value. </constant> <constant name="TEXTURE_DETAIL_ALBEDO" value="14" enum="TextureParam"> + Texture specifying per-pixel detail color. </constant> <constant name="TEXTURE_DETAIL_NORMAL" value="15" enum="TextureParam"> + Texture specifying per-pixel detail normal. </constant> <constant name="TEXTURE_MAX" value="16" enum="TextureParam"> Represents the size of the [enum TextureParam] enum. </constant> <constant name="DETAIL_UV_1" value="0" enum="DetailUV"> + Use [code]UV[/code] with the detail texture. </constant> <constant name="DETAIL_UV_2" value="1" enum="DetailUV"> + Use [code]UV2[/code] with the detail texture. </constant> <constant name="FEATURE_TRANSPARENT" value="0" enum="Feature"> + Constant for setting [member flags_transparent]. </constant> <constant name="FEATURE_EMISSION" value="1" enum="Feature"> + Constant for setting [member emission_enabled]. </constant> <constant name="FEATURE_NORMAL_MAPPING" value="2" enum="Feature"> + Constant for setting [member normal_enabled]. </constant> <constant name="FEATURE_RIM" value="3" enum="Feature"> + Constant for setting [member rim_enabled]. </constant> <constant name="FEATURE_CLEARCOAT" value="4" enum="Feature"> + Constant for setting [member clearcoat_enabled]. </constant> <constant name="FEATURE_ANISOTROPY" value="5" enum="Feature"> + Constant for setting [member anisotropy_enabled]. </constant> <constant name="FEATURE_AMBIENT_OCCLUSION" value="6" enum="Feature"> + Constant for setting [member ao_enabled]. </constant> <constant name="FEATURE_DEPTH_MAPPING" value="7" enum="Feature"> + Constant for setting [member depth_enabled]. </constant> <constant name="FEATURE_SUBSURACE_SCATTERING" value="8" enum="Feature"> + Constant for setting [member subsurf_scatter_enabled]. </constant> <constant name="FEATURE_TRANSMISSION" value="9" enum="Feature"> + Constant for setting [member transmission_enabled]. </constant> <constant name="FEATURE_REFRACTION" value="10" enum="Feature"> + Constant for setting [member refraction_enabled]. </constant> <constant name="FEATURE_DETAIL" value="11" enum="Feature"> + Constant for setting [member detail_enabled]. </constant> <constant name="FEATURE_MAX" value="12" enum="Feature"> Represents the size of the [enum Feature] enum. </constant> <constant name="BLEND_MODE_MIX" value="0" enum="BlendMode"> - Default blend mode. + Default blend mode. The color of the object is blended over the background based on the object's alpha value. </constant> <constant name="BLEND_MODE_ADD" value="1" enum="BlendMode"> + The color of the object is added to the background. </constant> <constant name="BLEND_MODE_SUB" value="2" enum="BlendMode"> + The color of the object is subtracted from the background. </constant> <constant name="BLEND_MODE_MUL" value="3" enum="BlendMode"> + The color of the object is multiplied by the background. </constant> <constant name="DEPTH_DRAW_OPAQUE_ONLY" value="0" enum="DepthDrawMode"> Default depth draw mode. Depth is drawn only for opaque objects. @@ -416,42 +510,61 @@ No culling is performed. </constant> <constant name="FLAG_UNSHADED" value="0" enum="Flags"> + No lighting is used on the object. Color comes directly from [code]ALBEDO[/code]. </constant> <constant name="FLAG_USE_VERTEX_LIGHTING" value="1" enum="Flags"> + Lighting is calculated per-vertex rather than per-pixel. This can be used to increase the speed of the shader at the cost of quality. </constant> <constant name="FLAG_DISABLE_DEPTH_TEST" value="2" enum="Flags"> + Disables the depth test, so this object is drawn on top of all others. However, objects drawn after it in the draw order may cover it. </constant> <constant name="FLAG_ALBEDO_FROM_VERTEX_COLOR" value="3" enum="Flags"> + Set [code]ALBEDO[/code] to the per-vertex color specified in the mesh. </constant> <constant name="FLAG_SRGB_VERTEX_COLOR" value="4" enum="Flags"> + Vertex color is in sRGB space and needs to be converted to linear. Only applies in the GLES3 renderer. </constant> <constant name="FLAG_USE_POINT_SIZE" value="5" enum="Flags"> + Uses point size to alter the size of primitive points. Also changes the albedo texture lookup to use [code]POINT_COORD[/code] instead of [code]UV[/code]. </constant> <constant name="FLAG_FIXED_SIZE" value="6" enum="Flags"> + Object is scaled by depth so that it always appears the same size on screen. </constant> <constant name="FLAG_BILLBOARD_KEEP_SCALE" value="7" enum="Flags"> + Shader will keep the scale set for the mesh. Otherwise the scale is lost when billboarding. Only applies when [member params_billboard_mode] is [constant BILLBOARD_ENABLED]. </constant> <constant name="FLAG_UV1_USE_TRIPLANAR" value="8" enum="Flags"> + Use triplanar texture lookup for all texture lookups that would normally use [code]UV[/code]. </constant> <constant name="FLAG_UV2_USE_TRIPLANAR" value="9" enum="Flags"> + Use triplanar texture lookup for all texture lookups that would normally use [code]UV2[/code]. </constant> <constant name="FLAG_AO_ON_UV2" value="11" enum="Flags"> + Use [code]UV2[/code] coordinates to look up from the [member ao_texture]. </constant> <constant name="FLAG_EMISSION_ON_UV2" value="12" enum="Flags"> + Use [code]UV2[/code] coordinates to look up from the [member emission_texture]. </constant> <constant name="FLAG_USE_ALPHA_SCISSOR" value="13" enum="Flags"> + Use alpha scissor. Set by [member params_use_alpha_scissor]. </constant> <constant name="FLAG_TRIPLANAR_USE_WORLD" value="10" enum="Flags"> + Use world coordinates in the triplanar texture lookup instead of local coordinates. </constant> <constant name="FLAG_ALBEDO_TEXTURE_FORCE_SRGB" value="14" enum="Flags"> + Forces the shader to convert albedo from sRGB space to linear space. </constant> <constant name="FLAG_DONT_RECEIVE_SHADOWS" value="15" enum="Flags"> + Disables receiving shadows from other objects. </constant> <constant name="FLAG_DISABLE_AMBIENT_LIGHT" value="17" enum="Flags"> + Disables receiving ambient light. </constant> <constant name="FLAG_ENSURE_CORRECT_NORMALS" value="16" enum="Flags"> + Ensures that normals appear correct, even with non-uniform scaling. </constant> <constant name="FLAG_USE_SHADOW_TO_OPACITY" value="18" enum="Flags"> + Enables the shadow to opacity feature. </constant> <constant name="FLAG_MAX" value="19" enum="Flags"> Represents the size of the [enum Flags] enum. @@ -496,29 +609,41 @@ The object's X axis will always face the camera. </constant> <constant name="BILLBOARD_PARTICLES" value="3" enum="BillboardMode"> - Used for particle systems. Enables particle animation options. + Used for particle systems when assigned to [Particles] and [CPUParticles] nodes. Enables [code]particles_anim_*[/code] properties. + The [member ParticlesMaterial.anim_speed] or [member CPUParticles.anim_speed] should also be set to a positive value for the animation to play. </constant> <constant name="TEXTURE_CHANNEL_RED" value="0" enum="TextureChannel"> + Used to read from the red channel of a texture. </constant> <constant name="TEXTURE_CHANNEL_GREEN" value="1" enum="TextureChannel"> + Used to read from the green channel of a texture. </constant> <constant name="TEXTURE_CHANNEL_BLUE" value="2" enum="TextureChannel"> + Used to read from the blue channel of a texture. </constant> <constant name="TEXTURE_CHANNEL_ALPHA" value="3" enum="TextureChannel"> + Used to read from the alpha channel of a texture. </constant> <constant name="TEXTURE_CHANNEL_GRAYSCALE" value="4" enum="TextureChannel"> + Currently unused. </constant> <constant name="EMISSION_OP_ADD" value="0" enum="EmissionOperator"> + Adds the emission color to the color from the emission texture. </constant> <constant name="EMISSION_OP_MULTIPLY" value="1" enum="EmissionOperator"> + Multiplies the emission color by the color from the emission texture. </constant> <constant name="DISTANCE_FADE_DISABLED" value="0" enum="DistanceFadeMode"> + Do not use distance fade. </constant> <constant name="DISTANCE_FADE_PIXEL_ALPHA" value="1" enum="DistanceFadeMode"> + Smoothly fades the object out based on each pixel's distance from the camera using the alpha channel. </constant> <constant name="DISTANCE_FADE_PIXEL_DITHER" value="2" enum="DistanceFadeMode"> + Smoothly fades the object out based on each pixel's distance from the camera using a dither approach. Dithering discards pixels based on a set pattern to smoothly fade without enabling transparency. On certain hardware this can be faster than [constant DISTANCE_FADE_PIXEL_ALPHA]. </constant> <constant name="DISTANCE_FADE_OBJECT_DITHER" value="3" enum="DistanceFadeMode"> + Smoothly fades the object out based on the object's distance from the camera using a dither approach. Dithering discards pixels based on a set pattern to smoothly fade without enabling transparency. On certain hardware this can be faster than [constant DISTANCE_FADE_PIXEL_ALPHA]. </constant> </constants> </class> diff --git a/doc/classes/SpatialVelocityTracker.xml b/doc/classes/SpatialVelocityTracker.xml index 0dcd174a67..7a4e0c054a 100644 --- a/doc/classes/SpatialVelocityTracker.xml +++ b/doc/classes/SpatialVelocityTracker.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SpatialVelocityTracker" inherits="Reference" category="Core" version="3.2"> +<class name="SpatialVelocityTracker" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/SphereMesh.xml b/doc/classes/SphereMesh.xml index 43f19f9f4e..439fe11861 100644 --- a/doc/classes/SphereMesh.xml +++ b/doc/classes/SphereMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SphereMesh" inherits="PrimitiveMesh" category="Core" version="3.2"> +<class name="SphereMesh" inherits="PrimitiveMesh" version="4.0"> <brief_description> Class representing a spherical [PrimitiveMesh]. </brief_description> diff --git a/doc/classes/SphereShape.xml b/doc/classes/SphereShape.xml index 616c3b3894..75dab58c38 100644 --- a/doc/classes/SphereShape.xml +++ b/doc/classes/SphereShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SphereShape" inherits="Shape" category="Core" version="3.2"> +<class name="SphereShape" inherits="Shape" version="4.0"> <brief_description> Sphere shape for 3D collisions. </brief_description> diff --git a/doc/classes/SpinBox.xml b/doc/classes/SpinBox.xml index dfa14fc512..3b8bb7fb4b 100644 --- a/doc/classes/SpinBox.xml +++ b/doc/classes/SpinBox.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SpinBox" inherits="Range" category="Core" version="3.2"> +<class name="SpinBox" inherits="Range" version="4.0"> <brief_description> Numerical input text field. </brief_description> diff --git a/doc/classes/SplitContainer.xml b/doc/classes/SplitContainer.xml index 25d4546c3a..b3f85ce7e1 100644 --- a/doc/classes/SplitContainer.xml +++ b/doc/classes/SplitContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SplitContainer" inherits="Container" category="Core" version="3.2"> +<class name="SplitContainer" inherits="Container" version="4.0"> <brief_description> Container for splitting and adjusting. </brief_description> diff --git a/doc/classes/SpotLight.xml b/doc/classes/SpotLight.xml index 93aee55b99..351d4f8aff 100644 --- a/doc/classes/SpotLight.xml +++ b/doc/classes/SpotLight.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SpotLight" inherits="Light" category="Core" version="3.2"> +<class name="SpotLight" inherits="Light" version="4.0"> <brief_description> A spotlight, such as a reflector spotlight or a lantern. </brief_description> diff --git a/doc/classes/SpringArm.xml b/doc/classes/SpringArm.xml index 133ff68859..f426cfc352 100644 --- a/doc/classes/SpringArm.xml +++ b/doc/classes/SpringArm.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SpringArm" inherits="Spatial" category="Core" version="3.2"> +<class name="SpringArm" inherits="Spatial" version="4.0"> <brief_description> A helper node, mostly used in 3rd person cameras. </brief_description> diff --git a/doc/classes/Sprite.xml b/doc/classes/Sprite.xml index b77db1ce9a..5f82f76911 100644 --- a/doc/classes/Sprite.xml +++ b/doc/classes/Sprite.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Sprite" inherits="Node2D" category="Core" version="3.2"> +<class name="Sprite" inherits="Node2D" version="4.0"> <brief_description> General-purpose sprite node. </brief_description> diff --git a/doc/classes/Sprite3D.xml b/doc/classes/Sprite3D.xml index e458d4301e..a082a297f8 100644 --- a/doc/classes/Sprite3D.xml +++ b/doc/classes/Sprite3D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Sprite3D" inherits="SpriteBase3D" category="Core" version="3.2"> +<class name="Sprite3D" inherits="SpriteBase3D" version="4.0"> <brief_description> 2D sprite node in a 3D world. </brief_description> diff --git a/doc/classes/SpriteBase3D.xml b/doc/classes/SpriteBase3D.xml index 15d5d7beb4..8a923b4521 100644 --- a/doc/classes/SpriteBase3D.xml +++ b/doc/classes/SpriteBase3D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SpriteBase3D" inherits="GeometryInstance" category="Core" version="3.2"> +<class name="SpriteBase3D" inherits="GeometryInstance" version="4.0"> <brief_description> 2D sprite node in 3D environment. </brief_description> diff --git a/doc/classes/SpriteFrames.xml b/doc/classes/SpriteFrames.xml index f28192519e..30690392e9 100644 --- a/doc/classes/SpriteFrames.xml +++ b/doc/classes/SpriteFrames.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SpriteFrames" inherits="Resource" category="Core" version="3.2"> +<class name="SpriteFrames" inherits="Resource" version="4.0"> <brief_description> Sprite frame library for AnimatedSprite. </brief_description> @@ -170,6 +170,7 @@ </methods> <members> <member name="frames" type="Array" setter="_set_frames" getter="_get_frames"> + Compatibility property, always equals to an empty array. </member> </members> <constants> diff --git a/doc/classes/StaticBody.xml b/doc/classes/StaticBody.xml index f8840ddc14..ce7584ecda 100644 --- a/doc/classes/StaticBody.xml +++ b/doc/classes/StaticBody.xml @@ -1,12 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StaticBody" inherits="PhysicsBody" category="Core" version="3.2"> +<class name="StaticBody" inherits="PhysicsBody" version="4.0"> <brief_description> Static body for 3D physics. </brief_description> <description> Static body for 3D physics. A static body is a simple body that is not intended to move. In contrast to [RigidBody], they don't consume any CPU resources as long as they don't move. - A static body can also be animated by using simulated motion mode. This is useful for implementing functionalities such as moving platforms. When this mode is active, the body can be animated and automatically computes linear and angular velocity to apply in that frame and to influence other bodies. - Alternatively, a constant linear or angular velocity can be set for the static body, so even if it doesn't move, it affects other bodies as if it was moving (this is useful for simulating conveyor belts or conveyor wheels). + Additionally, a constant linear or angular velocity can be set for the static body, so even if it doesn't move, it affects other bodies as if it was moving (this is useful for simulating conveyor belts or conveyor wheels). </description> <tutorials> </tutorials> diff --git a/doc/classes/StaticBody2D.xml b/doc/classes/StaticBody2D.xml index 34276ec535..daa160b8a9 100644 --- a/doc/classes/StaticBody2D.xml +++ b/doc/classes/StaticBody2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StaticBody2D" inherits="PhysicsBody2D" category="Core" version="3.2"> +<class name="StaticBody2D" inherits="PhysicsBody2D" version="4.0"> <brief_description> Static body for 2D physics. </brief_description> diff --git a/doc/classes/StreamPeer.xml b/doc/classes/StreamPeer.xml index 2a1919071a..31742199dd 100644 --- a/doc/classes/StreamPeer.xml +++ b/doc/classes/StreamPeer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StreamPeer" inherits="Reference" category="Core" version="3.2"> +<class name="StreamPeer" inherits="Reference" version="4.0"> <brief_description> Abstraction and base class for stream-based protocols. </brief_description> diff --git a/doc/classes/StreamPeerBuffer.xml b/doc/classes/StreamPeerBuffer.xml index 30a220863d..23e3890fdb 100644 --- a/doc/classes/StreamPeerBuffer.xml +++ b/doc/classes/StreamPeerBuffer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StreamPeerBuffer" inherits="StreamPeer" category="Core" version="3.2"> +<class name="StreamPeerBuffer" inherits="StreamPeer" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/StreamPeerSSL.xml b/doc/classes/StreamPeerSSL.xml index b34d8d1b25..738d623d02 100644 --- a/doc/classes/StreamPeerSSL.xml +++ b/doc/classes/StreamPeerSSL.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StreamPeerSSL" inherits="StreamPeer" category="Core" version="3.2"> +<class name="StreamPeerSSL" inherits="StreamPeer" version="4.0"> <brief_description> SSL stream peer. </brief_description> @@ -38,6 +38,7 @@ </argument> <description> Connects to a peer using an underlying [StreamPeer] [code]stream[/code]. If [code]validate_certs[/code] is [code]true[/code], [StreamPeerSSL] will validate that the certificate presented by the peer matches the [code]for_hostname[/code]. + [b]Note:[/b] Specifying a custom [code]valid_certificate[/code] is not supported in HTML5 exports due to browsers restrictions. </description> </method> <method name="disconnect_from_stream"> diff --git a/doc/classes/StreamPeerTCP.xml b/doc/classes/StreamPeerTCP.xml index bee026c851..dbd53f8ba0 100644 --- a/doc/classes/StreamPeerTCP.xml +++ b/doc/classes/StreamPeerTCP.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StreamPeerTCP" inherits="StreamPeer" category="Core" version="3.2"> +<class name="StreamPeerTCP" inherits="StreamPeer" version="4.0"> <brief_description> TCP stream peer. </brief_description> diff --git a/doc/classes/StreamTexture.xml b/doc/classes/StreamTexture.xml index 9cc3511b68..75e2661db0 100644 --- a/doc/classes/StreamTexture.xml +++ b/doc/classes/StreamTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StreamTexture" inherits="Texture" category="Core" version="3.2"> +<class name="StreamTexture" inherits="Texture" version="4.0"> <brief_description> A [code].stex[/code] texture. </brief_description> diff --git a/doc/classes/String.xml b/doc/classes/String.xml index f5597d89e5..cb80d04f24 100644 --- a/doc/classes/String.xml +++ b/doc/classes/String.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="String" category="Built-In Types" version="3.2"> +<class name="String" version="4.0"> <brief_description> Built-in string class. </brief_description> diff --git a/doc/classes/StyleBox.xml b/doc/classes/StyleBox.xml index 1d873ef0b1..0e848a1bf6 100644 --- a/doc/classes/StyleBox.xml +++ b/doc/classes/StyleBox.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StyleBox" inherits="Resource" category="Core" version="3.2"> +<class name="StyleBox" inherits="Resource" version="4.0"> <brief_description> Base class for drawing stylized boxes for the UI. </brief_description> @@ -17,18 +17,22 @@ <argument index="1" name="rect" type="Rect2"> </argument> <description> + Draws this stylebox using a [CanvasItem] with given [RID]. + You can get a [RID] value using [method Object.get_instance_id] on a [CanvasItem]-derived node. </description> </method> <method name="get_center_size" qualifiers="const"> <return type="Vector2"> </return> <description> + Returns the size of this [StyleBox] without the margins. </description> </method> <method name="get_current_item_drawn" qualifiers="const"> <return type="CanvasItem"> </return> <description> + Returns the [CanvasItem] that handles its [constant CanvasItem.NOTIFICATION_DRAW] or [method CanvasItem._draw] callback at this moment. </description> </method> <method name="get_default_margin" qualifiers="const"> @@ -37,6 +41,7 @@ <argument index="0" name="margin" type="int" enum="Margin"> </argument> <description> + Returns the default value of the specified [enum Margin]. </description> </method> <method name="get_margin" qualifiers="const"> @@ -45,7 +50,7 @@ <argument index="0" name="margin" type="int" enum="Margin"> </argument> <description> - Returns the content margin offset for the specified margin. + Returns the content margin offset for the specified [enum Margin]. Positive values reduce size inwards, unlike [Control]'s margin values. </description> </method> @@ -71,6 +76,7 @@ <argument index="1" name="offset" type="float"> </argument> <description> + Sets the default value of the specified [enum Margin] to given [code]offset[/code] in pixels. </description> </method> <method name="test_mask" qualifiers="const"> diff --git a/doc/classes/StyleBoxEmpty.xml b/doc/classes/StyleBoxEmpty.xml index 9dc8569b75..8781cdcde3 100644 --- a/doc/classes/StyleBoxEmpty.xml +++ b/doc/classes/StyleBoxEmpty.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StyleBoxEmpty" inherits="StyleBox" category="Core" version="3.2"> +<class name="StyleBoxEmpty" inherits="StyleBox" version="4.0"> <brief_description> Empty stylebox (does not display anything). </brief_description> diff --git a/doc/classes/StyleBoxFlat.xml b/doc/classes/StyleBoxFlat.xml index 46b11ac010..d6e737b076 100644 --- a/doc/classes/StyleBoxFlat.xml +++ b/doc/classes/StyleBoxFlat.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StyleBoxFlat" inherits="StyleBox" category="Core" version="3.2"> +<class name="StyleBoxFlat" inherits="StyleBox" version="4.0"> <brief_description> Customizable [StyleBox] with a given set of parameters (no texture required). </brief_description> @@ -179,7 +179,8 @@ </member> <member name="corner_detail" type="int" setter="set_corner_detail" getter="get_corner_detail" default="8"> This sets the amount of vertices used for each corner. Higher values result in rounder corners but take more processing power to compute. When choosing a value, you should take the corner radius ([method set_corner_radius_all]) into account. - For corner radii smaller than 10, 4-5 should be enough. For corner radii smaller than 30, 8-12 should be enough. + For corner radii smaller than 10, [code]4[/code] or [code]5[/code] should be enough. For corner radii smaller than 30, values between [code]8[/code] and [code]12[/code] should be enough. + A corner detail of [code]1[/code] will result in chamfered corners instead of rounded corners, which is useful for some artistic effects. </member> <member name="corner_radius_bottom_left" type="int" setter="set_corner_radius" getter="get_corner_radius" default="0"> The bottom-left corner's radius. If [code]0[/code], the corner is not rounded. diff --git a/doc/classes/StyleBoxLine.xml b/doc/classes/StyleBoxLine.xml index b5da81de79..4a2dbf60e4 100644 --- a/doc/classes/StyleBoxLine.xml +++ b/doc/classes/StyleBoxLine.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StyleBoxLine" inherits="StyleBox" category="Core" version="3.2"> +<class name="StyleBoxLine" inherits="StyleBox" version="4.0"> <brief_description> [StyleBox] that displays a single line. </brief_description> diff --git a/doc/classes/StyleBoxTexture.xml b/doc/classes/StyleBoxTexture.xml index af4186dcb6..0e9add964d 100644 --- a/doc/classes/StyleBoxTexture.xml +++ b/doc/classes/StyleBoxTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StyleBoxTexture" inherits="StyleBox" category="Core" version="3.2"> +<class name="StyleBoxTexture" inherits="StyleBox" version="4.0"> <brief_description> Texture-based nine-patch [StyleBox]. </brief_description> diff --git a/doc/classes/SurfaceTool.xml b/doc/classes/SurfaceTool.xml index 0c9ac9fbff..ef9666b5ec 100644 --- a/doc/classes/SurfaceTool.xml +++ b/doc/classes/SurfaceTool.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="SurfaceTool" inherits="Reference" category="Core" version="3.2"> +<class name="SurfaceTool" inherits="Reference" version="4.0"> <brief_description> Helper tool to create geometry. </brief_description> @@ -174,6 +174,7 @@ <return type="Array"> </return> <description> + Commits the data to the same format used by [method ArrayMesh.add_surface_from_arrays]. This way you can further process the mesh data using the [ArrayMesh] API. </description> </method> <method name="create_from"> @@ -197,6 +198,7 @@ <argument index="2" name="blend_shape" type="String"> </argument> <description> + Creates a vertex array from the specified blend shape of an existing [Mesh]. This can be used to extract a specific pose from a blend shape. </description> </method> <method name="deindex"> diff --git a/doc/classes/TCP_Server.xml b/doc/classes/TCP_Server.xml index cac3a0b082..72e9ca923d 100644 --- a/doc/classes/TCP_Server.xml +++ b/doc/classes/TCP_Server.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TCP_Server" inherits="Reference" category="Core" version="3.2"> +<class name="TCP_Server" inherits="Reference" version="4.0"> <brief_description> A TCP server. </brief_description> diff --git a/doc/classes/TabContainer.xml b/doc/classes/TabContainer.xml index e5f126c344..ee26be472c 100644 --- a/doc/classes/TabContainer.xml +++ b/doc/classes/TabContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TabContainer" inherits="Container" category="Core" version="3.2"> +<class name="TabContainer" inherits="Container" version="4.0"> <brief_description> Tabbed container. </brief_description> diff --git a/doc/classes/Tabs.xml b/doc/classes/Tabs.xml index 04119b7cdb..ae455f8043 100644 --- a/doc/classes/Tabs.xml +++ b/doc/classes/Tabs.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Tabs" inherits="Control" category="Core" version="3.2"> +<class name="Tabs" inherits="Control" version="4.0"> <brief_description> Tabs control. </brief_description> diff --git a/doc/classes/TextEdit.xml b/doc/classes/TextEdit.xml index 3deed63ae7..eb3b72f627 100644 --- a/doc/classes/TextEdit.xml +++ b/doc/classes/TextEdit.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TextEdit" inherits="Control" category="Core" version="3.2"> +<class name="TextEdit" inherits="Control" version="4.0"> <brief_description> Multiline text editing control. </brief_description> @@ -315,7 +315,7 @@ [codeblock] var result = search(key, flags, line, column) if result.size() > 0: - # result found + # Result found. var res_line = result[TextEdit.SEARCH_RESULT_LINE] var res_column = result[TextEdit.SEARCH_RESULT_COLUMN] [/codeblock] diff --git a/doc/classes/TextFile.xml b/doc/classes/TextFile.xml index 163900a482..1c2c2ff25c 100644 --- a/doc/classes/TextFile.xml +++ b/doc/classes/TextFile.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TextFile" inherits="Resource" category="Core" version="3.2"> +<class name="TextFile" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/Texture.xml b/doc/classes/Texture.xml index 238d6929ba..592f822ecc 100644 --- a/doc/classes/Texture.xml +++ b/doc/classes/Texture.xml @@ -1,11 +1,12 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Texture" inherits="Resource" category="Core" version="3.2"> +<class name="Texture" inherits="Resource" version="4.0"> <brief_description> Texture for 2D and 3D. </brief_description> <description> A texture works by registering an image in the video hardware, which then can be used in 3D models or 2D [Sprite] or GUI [Control]. Textures are often created by loading them from a file. See [method @GDScript.load]. + [Texture] is a base for other resources. It cannot be used directly. </description> <tutorials> </tutorials> @@ -24,6 +25,7 @@ <argument index="4" name="normal_map" type="Texture" default="null"> </argument> <description> + Draws the texture using a [CanvasItem] with the [VisualServer] API at the specified [code]position[/code]. Equivalent to [method VisualServer.canvas_item_add_texture_rect] with a rect at [code]position[/code] and the size of this [Texture]. </description> </method> <method name="draw_rect" qualifiers="const"> @@ -42,6 +44,7 @@ <argument index="5" name="normal_map" type="Texture" default="null"> </argument> <description> + Draws the texture using a [CanvasItem] with the [VisualServer] API. Equivalent to [method VisualServer.canvas_item_add_texture_rect]. </description> </method> <method name="draw_rect_region" qualifiers="const"> @@ -62,12 +65,14 @@ <argument index="6" name="clip_uv" type="bool" default="true"> </argument> <description> + Draws a part of the texture using a [CanvasItem] with the [VisualServer] API. Equivalent to [method VisualServer.canvas_item_add_texture_rect_region]. </description> </method> <method name="get_data" qualifiers="const"> <return type="Image"> </return> <description> + Returns an [Image] with the data from this [Texture]. [Image]s can be accessed and manipulated directly. </description> </method> <method name="get_height" qualifiers="const"> @@ -95,12 +100,13 @@ <return type="bool"> </return> <description> + Returns [code]true[/code] if this [Texture] has an alpha channel. </description> </method> </methods> <members> <member name="flags" type="int" setter="set_flags" getter="get_flags" default="4"> - The texture's flags. + The texture's [enum Flags]. [enum Flags] are used to set various properties of the [Texture]. </member> </members> <constants> diff --git a/doc/classes/Texture3D.xml b/doc/classes/Texture3D.xml index c11a48137f..bc16cd015f 100644 --- a/doc/classes/Texture3D.xml +++ b/doc/classes/Texture3D.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Texture3D" inherits="TextureLayered" category="Core" version="3.2"> +<class name="Texture3D" inherits="TextureLayered" version="4.0"> <brief_description> + Texture with 3 dimensions. </brief_description> <description> + Texture3D is a 3-dimensional texture that has a width, height, and depth. </description> <tutorials> </tutorials> diff --git a/doc/classes/TextureArray.xml b/doc/classes/TextureArray.xml index 0a9ac1fb2e..b652a1c6bc 100644 --- a/doc/classes/TextureArray.xml +++ b/doc/classes/TextureArray.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TextureArray" inherits="TextureLayered" category="Core" version="3.2"> +<class name="TextureArray" inherits="TextureLayered" version="4.0"> <brief_description> + Array of textures stored in a single primitive. </brief_description> <description> + [TextureArray]s store an array of images in a single [Texture] primitive. Each layer of the texture array has its own mipmap chain. This makes it is a good alternative to texture atlases. </description> <tutorials> </tutorials> diff --git a/doc/classes/TextureButton.xml b/doc/classes/TextureButton.xml index 201f8ddb8e..be717e9817 100644 --- a/doc/classes/TextureButton.xml +++ b/doc/classes/TextureButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TextureButton" inherits="BaseButton" category="Core" version="3.2"> +<class name="TextureButton" inherits="BaseButton" version="4.0"> <brief_description> Texture-based button. Supports Pressed, Hover, Disabled and Focused states. </brief_description> diff --git a/doc/classes/TextureLayered.xml b/doc/classes/TextureLayered.xml index 232df8f59b..f20f46b6c4 100644 --- a/doc/classes/TextureLayered.xml +++ b/doc/classes/TextureLayered.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TextureLayered" inherits="Resource" category="Core" version="3.2"> +<class name="TextureLayered" inherits="Resource" version="4.0"> <brief_description> + Base class for 3D texture types. </brief_description> <description> + Base class for [Texture3D] and [TextureArray]. Cannot be used directly, but contains all the functions necessary for accessing and using [Texture3D] and [TextureArray]. Data is set on a per-layer basis. For [Texture3D]s, the layer sepcifies the depth or Z-index, they can be treated as a bunch of 2D slices. Similarly, for [TextureArray]s, the layer specifies the array layer. </description> <tutorials> </tutorials> @@ -21,24 +23,28 @@ <argument index="4" name="flags" type="int" default="4"> </argument> <description> + Creates the [Texture3D] or [TextureArray] with specified [code]width[/code], [code]height[/code], and [code]depth[/code]. See [enum Image.Format] for [code]format[/code] options. See [enum Flags] enumerator for [code]flags[/code] options. </description> </method> <method name="get_depth" qualifiers="const"> <return type="int"> </return> <description> + Returns the depth of the texture. Depth is the 3rd dimension (typically Z-axis). </description> </method> <method name="get_format" qualifiers="const"> <return type="int" enum="Image.Format"> </return> <description> + Returns the current format being used by this texture. See [enum Image.Format] for details. </description> </method> <method name="get_height" qualifiers="const"> <return type="int"> </return> <description> + Returns the height of the texture. Height is typically represented by the Y-axis. </description> </method> <method name="get_layer_data" qualifiers="const"> @@ -47,12 +53,14 @@ <argument index="0" name="layer" type="int"> </argument> <description> + Returns an [Image] resource with the data from specified [code]layer[/code]. </description> </method> <method name="get_width" qualifiers="const"> <return type="int"> </return> <description> + Returns the width of the texture. Width is typically represented by the X-axis. </description> </method> <method name="set_data_partial"> @@ -69,6 +77,7 @@ <argument index="4" name="mipmap" type="int" default="0"> </argument> <description> + Partially sets the data for a specified [code]layer[/code] by overwriting using the data of the specified [code]image[/code]. [code]x_offset[/code] and [code]y_offset[/code] determine where the [Image] is "stamped" over the texture. The [code]image[/code] must fit within the texture. </description> </method> <method name="set_layer_data"> @@ -79,23 +88,30 @@ <argument index="1" name="layer" type="int"> </argument> <description> + Sets the data for the specified layer. Data takes the form of a 2-dimensional [Image] resource. </description> </method> </methods> <members> <member name="data" type="Dictionary" setter="_set_data" getter="_get_data" default="{"depth": 0,"flags": 4,"format": 37,"height": 0,"layers": [ ],"width": 0}"> + Returns a dictionary with all the data used by this texture. </member> <member name="flags" type="int" setter="set_flags" getter="get_flags" default="4"> + Specifies which [enum Flags] apply to this texture. </member> </members> <constants> <constant name="FLAG_MIPMAPS" value="1" enum="Flags"> + Texture will generate mipmaps on creation. </constant> <constant name="FLAG_REPEAT" value="2" enum="Flags"> + Texture will repeat when UV used is outside the 0-1 range. </constant> <constant name="FLAG_FILTER" value="4" enum="Flags"> + Use filtering when reading from texture. Filtering smooths out pixels. Turning filtering off is slightly faster and more appropriate when you need access to individual pixels. </constant> <constant name="FLAGS_DEFAULT" value="4" enum="Flags"> + Equivalent to [constant FLAG_FILTER]. </constant> </constants> </class> diff --git a/doc/classes/TextureProgress.xml b/doc/classes/TextureProgress.xml index c16d6f58bc..7f91206c2c 100644 --- a/doc/classes/TextureProgress.xml +++ b/doc/classes/TextureProgress.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TextureProgress" inherits="Range" category="Core" version="3.2"> +<class name="TextureProgress" inherits="Range" version="4.0"> <brief_description> Texture-based progress bar. Useful for loading screens and life or stamina bars. </brief_description> diff --git a/doc/classes/TextureRect.xml b/doc/classes/TextureRect.xml index 997a686e82..17c413c9f2 100644 --- a/doc/classes/TextureRect.xml +++ b/doc/classes/TextureRect.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TextureRect" inherits="Control" category="Core" version="3.2"> +<class name="TextureRect" inherits="Control" version="4.0"> <brief_description> Control for drawing textures. </brief_description> diff --git a/doc/classes/Theme.xml b/doc/classes/Theme.xml index b9aa74ebb7..f9beb5566d 100644 --- a/doc/classes/Theme.xml +++ b/doc/classes/Theme.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Theme" inherits="Resource" category="Core" version="3.2"> +<class name="Theme" inherits="Resource" version="4.0"> <brief_description> Theme for controls. </brief_description> diff --git a/doc/classes/Thread.xml b/doc/classes/Thread.xml index 25e40d4c1f..f616a9d9b1 100644 --- a/doc/classes/Thread.xml +++ b/doc/classes/Thread.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Thread" inherits="Reference" category="Core" version="3.2"> +<class name="Thread" inherits="Reference" version="4.0"> <brief_description> A unit of execution in a process. </brief_description> @@ -50,10 +50,13 @@ </methods> <constants> <constant name="PRIORITY_LOW" value="0" enum="Priority"> + A thread running with lower priority than normally. </constant> <constant name="PRIORITY_NORMAL" value="1" enum="Priority"> + A thread with a standard priority. </constant> <constant name="PRIORITY_HIGH" value="2" enum="Priority"> + A thread running with higher priority than normally. </constant> </constants> </class> diff --git a/doc/classes/TileMap.xml b/doc/classes/TileMap.xml index 7376f624cb..1db1142aa0 100644 --- a/doc/classes/TileMap.xml +++ b/doc/classes/TileMap.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TileMap" inherits="Node2D" category="Core" version="3.2"> +<class name="TileMap" inherits="Node2D" version="4.0"> <brief_description> Node for 2D tile-based maps. </brief_description> diff --git a/doc/classes/TileSet.xml b/doc/classes/TileSet.xml index 8ad62f0fcb..7bf5d8a0fe 100644 --- a/doc/classes/TileSet.xml +++ b/doc/classes/TileSet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TileSet" inherits="Resource" category="Core" version="3.2"> +<class name="TileSet" inherits="Resource" version="4.0"> <brief_description> Tile library for tilemaps. </brief_description> @@ -749,6 +749,8 @@ </constant> <constant name="BIND_LEFT" value="8" enum="AutotileBindings"> </constant> + <constant name="BIND_CENTER" value="16" enum="AutotileBindings"> + </constant> <constant name="BIND_RIGHT" value="32" enum="AutotileBindings"> </constant> <constant name="BIND_BOTTOMLEFT" value="64" enum="AutotileBindings"> diff --git a/doc/classes/Timer.xml b/doc/classes/Timer.xml index 3e4b68d91d..c1e5987a06 100644 --- a/doc/classes/Timer.xml +++ b/doc/classes/Timer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Timer" inherits="Node" category="Core" version="3.2"> +<class name="Timer" inherits="Node" version="4.0"> <brief_description> A countdown timer. </brief_description> @@ -37,6 +37,7 @@ <members> <member name="autostart" type="bool" setter="set_autostart" getter="has_autostart" default="false"> If [code]true[/code], the timer will automatically start when entering the scene tree. + [b]Note:[/b] This property is automatically set to [code]false[/code] after the timer enters the scene tree and starts. </member> <member name="one_shot" type="bool" setter="set_one_shot" getter="is_one_shot" default="false"> If [code]true[/code], the timer will stop when reaching 0. If [code]false[/code], it will restart. diff --git a/doc/classes/ToolButton.xml b/doc/classes/ToolButton.xml index d5edbe3972..f78627b163 100644 --- a/doc/classes/ToolButton.xml +++ b/doc/classes/ToolButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ToolButton" inherits="Button" category="Core" version="3.2"> +<class name="ToolButton" inherits="Button" version="4.0"> <brief_description> Flat button helper class. </brief_description> @@ -21,26 +21,37 @@ </constants> <theme_items> <theme_item name="disabled" type="StyleBox"> + [StyleBox] used when the [ToolButton] is disabled. </theme_item> <theme_item name="focus" type="StyleBox"> + [StyleBox] used when the [ToolButton] is focused. It is displayed over the current [StyleBox], so using [StyleBoxEmpty] will just disable the focus visual effect. </theme_item> <theme_item name="font" type="Font"> + [Font] of the [ToolButton]'s text. </theme_item> <theme_item name="font_color" type="Color" default="Color( 0.88, 0.88, 0.88, 1 )"> + Default text [Color] of the [ToolButton]. </theme_item> <theme_item name="font_color_disabled" type="Color" default="Color( 0.9, 0.95, 1, 0.3 )"> + Text [Color] used when the [ToolButton] is disabled. </theme_item> <theme_item name="font_color_hover" type="Color" default="Color( 0.94, 0.94, 0.94, 1 )"> + Text [Color] used when the [ToolButton] is being hovered. </theme_item> <theme_item name="font_color_pressed" type="Color" default="Color( 1, 1, 1, 1 )"> + Text [Color] used when the [ToolButton] is being pressed. </theme_item> <theme_item name="hover" type="StyleBox"> + [StyleBox] used when the [ToolButton] is being hovered. </theme_item> <theme_item name="hseparation" type="int" default="3"> + The horizontal space between [ToolButton]'s icon and text. </theme_item> <theme_item name="normal" type="StyleBox"> + Default [StyleBox] for the [ToolButton]. </theme_item> <theme_item name="pressed" type="StyleBox"> + [StyleBox] used when the [ToolButton] is being pressed. </theme_item> </theme_items> </class> diff --git a/doc/classes/TouchScreenButton.xml b/doc/classes/TouchScreenButton.xml index 3d18534a68..52025a1b04 100644 --- a/doc/classes/TouchScreenButton.xml +++ b/doc/classes/TouchScreenButton.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TouchScreenButton" inherits="Node2D" category="Core" version="3.2"> +<class name="TouchScreenButton" inherits="Node2D" version="4.0"> <brief_description> Button for touch screen devices. </brief_description> diff --git a/doc/classes/Transform.xml b/doc/classes/Transform.xml index 2e447ca1ba..e9d7208f66 100644 --- a/doc/classes/Transform.xml +++ b/doc/classes/Transform.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Transform" category="Built-In Types" version="3.2"> +<class name="Transform" version="4.0"> <brief_description> 3D transformation (3×4 matrix). </brief_description> diff --git a/doc/classes/Transform2D.xml b/doc/classes/Transform2D.xml index afc8b04dc7..9719326f59 100644 --- a/doc/classes/Transform2D.xml +++ b/doc/classes/Transform2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Transform2D" category="Built-In Types" version="3.2"> +<class name="Transform2D" version="4.0"> <brief_description> 2D transformation (3×2 matrix). </brief_description> diff --git a/doc/classes/Translation.xml b/doc/classes/Translation.xml index e2599b9695..f80e59f6f9 100644 --- a/doc/classes/Translation.xml +++ b/doc/classes/Translation.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Translation" inherits="Resource" category="Core" version="3.2"> +<class name="Translation" inherits="Resource" version="4.0"> <brief_description> Language Translation. </brief_description> diff --git a/doc/classes/TranslationServer.xml b/doc/classes/TranslationServer.xml index f43d3bb24e..8a2a8b9768 100644 --- a/doc/classes/TranslationServer.xml +++ b/doc/classes/TranslationServer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TranslationServer" inherits="Object" category="Core" version="3.2"> +<class name="TranslationServer" inherits="Object" version="4.0"> <brief_description> Server that manages all translations. </brief_description> diff --git a/doc/classes/Tree.xml b/doc/classes/Tree.xml index aa1f8638d2..a28dcec92b 100644 --- a/doc/classes/Tree.xml +++ b/doc/classes/Tree.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Tree" inherits="Control" category="Core" version="3.2"> +<class name="Tree" inherits="Control" version="4.0"> <brief_description> Control to show a tree of items. </brief_description> diff --git a/doc/classes/TreeItem.xml b/doc/classes/TreeItem.xml index f32c5527fd..bd9f8d36b5 100644 --- a/doc/classes/TreeItem.xml +++ b/doc/classes/TreeItem.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TreeItem" inherits="Object" category="Core" version="3.2"> +<class name="TreeItem" inherits="Object" version="4.0"> <brief_description> Control for a single item inside a [Tree]. </brief_description> diff --git a/doc/classes/TriangleMesh.xml b/doc/classes/TriangleMesh.xml index 2125aa5e17..39bee0c2b3 100644 --- a/doc/classes/TriangleMesh.xml +++ b/doc/classes/TriangleMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="TriangleMesh" inherits="Reference" category="Core" version="3.2"> +<class name="TriangleMesh" inherits="Reference" version="4.0"> <brief_description> Internal mesh type. </brief_description> diff --git a/doc/classes/Tween.xml b/doc/classes/Tween.xml index cf75e71358..e60dc07e99 100644 --- a/doc/classes/Tween.xml +++ b/doc/classes/Tween.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Tween" inherits="Node" category="Core" version="3.2"> +<class name="Tween" inherits="Node" version="4.0"> <brief_description> Smoothly animates a node's properties over time. </brief_description> <description> Tweens are useful for animations requiring a numerical property to be interpolated over a range of values. The name [i]tween[/i] comes from [i]in-betweening[/i], an animation technique where you specify [i]keyframes[/i] and the computer interpolates the frames that appear between them. + [Tween] is more suited than [AnimationPlayer] for animations where you don't know the final values in advance. For example, interpolating a dynamically-chosen camera zoom value is best done with a [Tween] node; it would be difficult to do the same thing with an [AnimationPlayer] node. Here is a brief usage example that causes a 2D node to move smoothly between two positions: [codeblock] var tween = get_node("Tween") diff --git a/doc/classes/UndoRedo.xml b/doc/classes/UndoRedo.xml index 52ff7ef38b..06fcb1ca03 100644 --- a/doc/classes/UndoRedo.xml +++ b/doc/classes/UndoRedo.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="UndoRedo" inherits="Object" category="Core" version="3.2"> +<class name="UndoRedo" inherits="Object" version="4.0"> <brief_description> Helper to manage undo/redo operations in the editor or custom tools. </brief_description> diff --git a/doc/classes/VBoxContainer.xml b/doc/classes/VBoxContainer.xml index 4709772615..6b32a08f93 100644 --- a/doc/classes/VBoxContainer.xml +++ b/doc/classes/VBoxContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VBoxContainer" inherits="BoxContainer" category="Core" version="3.2"> +<class name="VBoxContainer" inherits="BoxContainer" version="4.0"> <brief_description> Vertical box container. </brief_description> @@ -14,6 +14,7 @@ </constants> <theme_items> <theme_item name="separation" type="int" default="4"> + The vertical space between the [VBoxContainer]'s elements. </theme_item> </theme_items> </class> diff --git a/doc/classes/VScrollBar.xml b/doc/classes/VScrollBar.xml index add695ef2c..dddbbb219b 100644 --- a/doc/classes/VScrollBar.xml +++ b/doc/classes/VScrollBar.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VScrollBar" inherits="ScrollBar" category="Core" version="3.2"> +<class name="VScrollBar" inherits="ScrollBar" version="4.0"> <brief_description> Vertical scroll bar. </brief_description> diff --git a/doc/classes/VSeparator.xml b/doc/classes/VSeparator.xml index e618c2b84b..19e995b9bc 100644 --- a/doc/classes/VSeparator.xml +++ b/doc/classes/VSeparator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VSeparator" inherits="Separator" category="Core" version="3.2"> +<class name="VSeparator" inherits="Separator" version="4.0"> <brief_description> Vertical version of [Separator]. </brief_description> diff --git a/doc/classes/VSlider.xml b/doc/classes/VSlider.xml index 8590c7bc3b..9e0b2e0453 100644 --- a/doc/classes/VSlider.xml +++ b/doc/classes/VSlider.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VSlider" inherits="Slider" category="Core" version="3.2"> +<class name="VSlider" inherits="Slider" version="4.0"> <brief_description> Vertical slider. </brief_description> diff --git a/doc/classes/VSplitContainer.xml b/doc/classes/VSplitContainer.xml index da2a54dca0..2dba120a4f 100644 --- a/doc/classes/VSplitContainer.xml +++ b/doc/classes/VSplitContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VSplitContainer" inherits="SplitContainer" category="Core" version="3.2"> +<class name="VSplitContainer" inherits="SplitContainer" version="4.0"> <brief_description> Vertical split container. </brief_description> diff --git a/doc/classes/Variant.xml b/doc/classes/Variant.xml index 1976e812ba..042c8d8e67 100644 --- a/doc/classes/Variant.xml +++ b/doc/classes/Variant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Variant" category="Core" version="3.2"> +<class name="Variant" version="4.0"> <brief_description> The most important data type in Godot. </brief_description> diff --git a/doc/classes/Vector2.xml b/doc/classes/Vector2.xml index b23c69de60..4eef103d1f 100644 --- a/doc/classes/Vector2.xml +++ b/doc/classes/Vector2.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Vector2" category="Built-In Types" version="3.2"> +<class name="Vector2" version="4.0"> <brief_description> Vector used for 2D math. </brief_description> diff --git a/doc/classes/Vector3.xml b/doc/classes/Vector3.xml index d838e6d2f7..7ae89cc450 100644 --- a/doc/classes/Vector3.xml +++ b/doc/classes/Vector3.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Vector3" category="Built-In Types" version="3.2"> +<class name="Vector3" version="4.0"> <brief_description> Vector used for 3D math. </brief_description> diff --git a/doc/classes/VehicleBody.xml b/doc/classes/VehicleBody.xml index 1803d4e197..74879419a1 100644 --- a/doc/classes/VehicleBody.xml +++ b/doc/classes/VehicleBody.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VehicleBody" inherits="RigidBody" category="Core" version="3.2"> +<class name="VehicleBody" inherits="RigidBody" version="4.0"> <brief_description> Physics body that simulates the behavior of a car. </brief_description> diff --git a/doc/classes/VehicleWheel.xml b/doc/classes/VehicleWheel.xml index ba33f66e77..1a6a226fd1 100644 --- a/doc/classes/VehicleWheel.xml +++ b/doc/classes/VehicleWheel.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VehicleWheel" inherits="Spatial" category="Core" version="3.2"> +<class name="VehicleWheel" inherits="Spatial" version="4.0"> <brief_description> Physics object that simulates the behavior of a wheel. </brief_description> diff --git a/doc/classes/VideoPlayer.xml b/doc/classes/VideoPlayer.xml index 804489f7f1..73c5a1d232 100644 --- a/doc/classes/VideoPlayer.xml +++ b/doc/classes/VideoPlayer.xml @@ -1,10 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VideoPlayer" inherits="Control" category="Core" version="3.2"> +<class name="VideoPlayer" inherits="Control" version="4.0"> <brief_description> Control for playing video streams. </brief_description> <description> - Control node for playing video streams. Supported formats are [url=https://www.webmproject.org/]WebM[/url] and [url=https://www.theora.org/]Ogg Theora[/url]. + Control node for playing video streams using [VideoStream] resources. + Supported video formats are [url=https://www.webmproject.org/]WebM[/url] ([VideoStreamWebm]), [url=https://www.theora.org/]Ogg Theora[/url] ([VideoStreamTheora]), and any format exposed via a GDNative plugin using [VideoStreamGDNative]. </description> <tutorials> </tutorials> @@ -13,7 +14,7 @@ <return type="String"> </return> <description> - Returns the video stream's name. + Returns the video stream's name, or [code]"<No Stream>"[/code] if no video stream is assigned. </description> </method> <method name="get_video_texture" qualifiers="const"> @@ -28,20 +29,22 @@ </return> <description> Returns [code]true[/code] if the video is playing. + [b]Note:[/b] The video is still considered playing if paused during playback. </description> </method> <method name="play"> <return type="void"> </return> <description> - Starts the video playback. + Starts the video playback from the beginning. If the video is paused, this will not unpause the video. </description> </method> <method name="stop"> <return type="void"> </return> <description> - Stops the video playback. + Stops the video playback and sets the stream position to 0. + [b]Note:[/b] Although the stream position will be set to 0, the first frame of the video stream won't become the current frame. </description> </method> </methods> @@ -59,7 +62,7 @@ Audio bus to use for sound playback. </member> <member name="expand" type="bool" setter="set_expand" getter="has_expand" default="true"> - If [code]true[/code], the video scales to the control size. + If [code]true[/code], the video scales to the control size. Otherwise, the control minimum size will be automatically adjusted to match the video stream's dimensions. </member> <member name="paused" type="bool" setter="set_paused" getter="is_paused" default="false"> If [code]true[/code], the video is paused. diff --git a/doc/classes/VideoStream.xml b/doc/classes/VideoStream.xml index 7772c61e85..7f522bfdf0 100644 --- a/doc/classes/VideoStream.xml +++ b/doc/classes/VideoStream.xml @@ -1,9 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VideoStream" inherits="Resource" category="Core" version="3.2"> +<class name="VideoStream" inherits="Resource" version="4.0"> <brief_description> Base resource for video streams. </brief_description> <description> + Base resource type for all video streams. Classes that derive from [VideoStream] can all be used as resource types to play back videos in [VideoPlayer]. </description> <tutorials> </tutorials> diff --git a/doc/classes/Viewport.xml b/doc/classes/Viewport.xml index 58dd36daa5..3c6ff1939e 100644 --- a/doc/classes/Viewport.xml +++ b/doc/classes/Viewport.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="Viewport" inherits="Node" category="Core" version="3.2"> +<class name="Viewport" inherits="Node" version="4.0"> <brief_description> Creates a sub-view into the screen. </brief_description> @@ -73,6 +73,7 @@ <argument index="0" name="quadrant" type="int"> </argument> <description> + Returns the [enum ShadowAtlasQuadrantSubdiv] of the specified quadrant. </description> </method> <method name="get_size_override" qualifiers="const"> @@ -156,12 +157,14 @@ <argument index="0" name="rect" type="Rect2"> </argument> <description> + Attaches this [Viewport] to the root [Viewport] with the specified rectangle. This bypasses the need for another node to display this [Viewport] but makes you responsible for updating the position of this [Viewport] manually. </description> </method> <method name="set_input_as_handled"> <return type="void"> </return> <description> + Stops the input from propagating further down the [SceneTree]. </description> </method> <method name="set_shadow_atlas_quadrant_subdiv"> @@ -172,6 +175,7 @@ <argument index="1" name="subdiv" type="int" enum="Viewport.ShadowAtlasQuadrantSubdiv"> </argument> <description> + Sets the number of subdivisions to use in the specified quadrant. A higher number of subdivisions allows you to have more shadows in the scene at once, but reduces the quality of the shadows. A good practice is to have quadrants with a varying number of subdivisions and to have as few subdivisions as possible. </description> </method> <method name="set_size_override"> @@ -243,13 +247,13 @@ <member name="handle_input_locally" type="bool" setter="set_handle_input_locally" getter="is_handling_input_locally" default="true"> </member> <member name="hdr" type="bool" setter="set_hdr" getter="get_hdr" default="true"> - If [code]true[/code], the viewport rendering will receive benefits from High Dynamic Range algorithm. + If [code]true[/code], the viewport rendering will receive benefits from High Dynamic Range algorithm. High Dynamic Range allows the viewport to receive values that are outside the 0-1 range. In Godot HDR uses 16 bits, meaning it does not store the full range of a floating point number. </member> <member name="keep_3d_linear" type="bool" setter="set_keep_3d_linear" getter="get_keep_3d_linear" default="false"> If [code]true[/code], the result after 3D rendering will not have a linear to sRGB color conversion applied. This is important when the viewport is used as a render target where the result is used as a texture on a 3D object rendered in another viewport. It is also important if the viewport is used to create data that is not color based (noise, heightmaps, pickmaps, etc.). Do not enable this when the viewport is used as a texture on a 2D object or if the viewport is your final output. </member> <member name="msaa" type="int" setter="set_msaa" getter="get_msaa" enum="Viewport.MSAA" default="0"> - The multisample anti-aliasing mode. + The multisample anti-aliasing mode. A higher number results in smoother edges at the cost of significantly worse performance. A value of 4 is best unless targeting very high-end systems. </member> <member name="own_world" type="bool" setter="set_use_own_world" getter="is_using_own_world" default="false"> If [code]true[/code], the viewport will use [World] defined in [code]world[/code] property. @@ -270,16 +274,16 @@ If [code]true[/code], the result of rendering will be flipped vertically. </member> <member name="shadow_atlas_quad_0" type="int" setter="set_shadow_atlas_quadrant_subdiv" getter="get_shadow_atlas_quadrant_subdiv" enum="Viewport.ShadowAtlasQuadrantSubdiv" default="2"> - The subdivision amount of first quadrant on shadow atlas. + The subdivision amount of the first quadrant on the shadow atlas. </member> <member name="shadow_atlas_quad_1" type="int" setter="set_shadow_atlas_quadrant_subdiv" getter="get_shadow_atlas_quadrant_subdiv" enum="Viewport.ShadowAtlasQuadrantSubdiv" default="2"> - The subdivision amount of second quadrant on shadow atlas. + The subdivision amount of the second quadrant on the shadow atlas. </member> <member name="shadow_atlas_quad_2" type="int" setter="set_shadow_atlas_quadrant_subdiv" getter="get_shadow_atlas_quadrant_subdiv" enum="Viewport.ShadowAtlasQuadrantSubdiv" default="3"> - The subdivision amount of third quadrant on shadow atlas. + The subdivision amount of the third quadrant on the shadow atlas. </member> <member name="shadow_atlas_quad_3" type="int" setter="set_shadow_atlas_quadrant_subdiv" getter="get_shadow_atlas_quadrant_subdiv" enum="Viewport.ShadowAtlasQuadrantSubdiv" default="4"> - The subdivision amount of fourth quadrant on shadow atlas. + The subdivision amount of the fourth quadrant on the shadow atlas. </member> <member name="shadow_atlas_size" type="int" setter="set_shadow_atlas_size" getter="get_shadow_atlas_size" default="0"> The shadow atlas' resolution (used for omni and spot lights). The value will be rounded up to the nearest power of 2. @@ -332,18 +336,25 @@ Always update the render target. </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_DISABLED" value="0" enum="ShadowAtlasQuadrantSubdiv"> + This quadrant will not be used. </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_1" value="1" enum="ShadowAtlasQuadrantSubdiv"> + This quadrant will only be used by one shadow map. </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_4" value="2" enum="ShadowAtlasQuadrantSubdiv"> + This quadrant will be split in 4 and used by up to 4 shadow maps. </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_16" value="3" enum="ShadowAtlasQuadrantSubdiv"> + This quadrant will be split 16 ways and used by up to 16 shadow maps. </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_64" value="4" enum="ShadowAtlasQuadrantSubdiv"> + This quadrant will be split 64 ways and used by up to 64 shadow maps. </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_256" value="5" enum="ShadowAtlasQuadrantSubdiv"> + This quadrant will be split 256 ways and used by up to 256 shadow maps. Unless the [member shadow_atlas_size] is very high, the shadows in this quadrant will be very low resolution. </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_1024" value="6" enum="ShadowAtlasQuadrantSubdiv"> + This quadrant will be split 1024 ways and used by up to 1024 shadow maps. Unless the [member shadow_atlas_size] is very high, the shadows in this quadrant will be very low resolution. </constant> <constant name="SHADOW_ATLAS_QUADRANT_SUBDIV_MAX" value="7" enum="ShadowAtlasQuadrantSubdiv"> Represents the size of the [enum ShadowAtlasQuadrantSubdiv] enum. @@ -385,20 +396,28 @@ Multisample anti-aliasing mode disabled. This is the default value. </constant> <constant name="MSAA_2X" value="1" enum="MSAA"> + Use 2x Multisample Antialiasing. </constant> <constant name="MSAA_4X" value="2" enum="MSAA"> + Use 4x Multisample Antialiasing. </constant> <constant name="MSAA_8X" value="3" enum="MSAA"> + Use 8x Multisample Antialiasing. Likely unsupported on low-end and older hardware. </constant> <constant name="MSAA_16X" value="4" enum="MSAA"> + Use 16x Multisample Antialiasing. Likely unsupported on medium and low-end hardware. </constant> <constant name="USAGE_2D" value="0" enum="Usage"> + Allocates all buffers needed for drawing 2D scenes. This takes less VRAM than the 3D usage modes. </constant> <constant name="USAGE_2D_NO_SAMPLING" value="1" enum="Usage"> + Allocates buffers needed for 2D scenes without allocating a buffer for screen copy. Accordingly, you cannot read from the screen. Of the [enum Usage] types, this requires the least VRAM. </constant> <constant name="USAGE_3D" value="2" enum="Usage"> + Allocates full buffers for drawing 3D scenes and all 3D effects including buffers needed for 2D scenes and effects. </constant> <constant name="USAGE_3D_NO_EFFECTS" value="3" enum="Usage"> + Allocates buffers needed for drawing 3D scenes. But does not allocate buffers needed for reading from the screen and post-processing effects. Saves some VRAM. </constant> <constant name="CLEAR_MODE_ALWAYS" value="0" enum="ClearMode"> Always clear the render target before drawing. diff --git a/doc/classes/ViewportContainer.xml b/doc/classes/ViewportContainer.xml index 2f1bc5d799..d2fbb85305 100644 --- a/doc/classes/ViewportContainer.xml +++ b/doc/classes/ViewportContainer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ViewportContainer" inherits="Container" category="Core" version="3.2"> +<class name="ViewportContainer" inherits="Container" version="4.0"> <brief_description> Control for holding [Viewport]s. </brief_description> diff --git a/doc/classes/ViewportTexture.xml b/doc/classes/ViewportTexture.xml index f4994699a3..e65d44f0f4 100644 --- a/doc/classes/ViewportTexture.xml +++ b/doc/classes/ViewportTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ViewportTexture" inherits="Texture" category="Core" version="3.2"> +<class name="ViewportTexture" inherits="Texture" version="4.0"> <brief_description> Texture which displays the content of a [Viewport]. </brief_description> diff --git a/doc/classes/VisibilityEnabler.xml b/doc/classes/VisibilityEnabler.xml index 8636d9c8d2..82b952fda6 100644 --- a/doc/classes/VisibilityEnabler.xml +++ b/doc/classes/VisibilityEnabler.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisibilityEnabler" inherits="VisibilityNotifier" category="Core" version="3.2"> +<class name="VisibilityEnabler" inherits="VisibilityNotifier" version="4.0"> <brief_description> Enables certain nodes only when visible. </brief_description> diff --git a/doc/classes/VisibilityEnabler2D.xml b/doc/classes/VisibilityEnabler2D.xml index 095a377ccb..98c3e5d78d 100644 --- a/doc/classes/VisibilityEnabler2D.xml +++ b/doc/classes/VisibilityEnabler2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisibilityEnabler2D" inherits="VisibilityNotifier2D" category="Core" version="3.2"> +<class name="VisibilityEnabler2D" inherits="VisibilityNotifier2D" version="4.0"> <brief_description> Enables certain nodes only when visible. </brief_description> diff --git a/doc/classes/VisibilityNotifier.xml b/doc/classes/VisibilityNotifier.xml index 4cbfa7ba76..6161017884 100644 --- a/doc/classes/VisibilityNotifier.xml +++ b/doc/classes/VisibilityNotifier.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisibilityNotifier" inherits="Spatial" category="Core" version="3.2"> +<class name="VisibilityNotifier" inherits="Spatial" version="4.0"> <brief_description> Detects when the node is visible on screen. </brief_description> diff --git a/doc/classes/VisibilityNotifier2D.xml b/doc/classes/VisibilityNotifier2D.xml index 7e1d933c44..f2a4a59d77 100644 --- a/doc/classes/VisibilityNotifier2D.xml +++ b/doc/classes/VisibilityNotifier2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisibilityNotifier2D" inherits="Node2D" category="Core" version="3.2"> +<class name="VisibilityNotifier2D" inherits="Node2D" version="4.0"> <brief_description> Detects when the node is visible on screen. </brief_description> diff --git a/doc/classes/VisualInstance.xml b/doc/classes/VisualInstance.xml index 7576bf7ad8..1bbd5cb64d 100644 --- a/doc/classes/VisualInstance.xml +++ b/doc/classes/VisualInstance.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualInstance" inherits="Spatial" category="Core" version="3.2"> +<class name="VisualInstance" inherits="Spatial" version="4.0"> <brief_description> + Parent of all visual 3D nodes. </brief_description> <description> + The [VisualInstance] is used to connect a resource to a visual representation. All visual 3D nodes inherit from the [VisualInstance]. In general, you should not access the [VisualInstance] properties directly as they are accessed and managed by the nodes that inherit from [VisualInstance]. [VisualInstance] is the node representation of the [VisualServer] instance. </description> <tutorials> </tutorials> @@ -11,19 +13,21 @@ <return type="AABB"> </return> <description> - Returns the [AABB] (also known as the bounding box) for this VisualInstance. + Returns the [AABB] (also known as the bounding box) for this [VisualInstance]. </description> </method> <method name="get_base" qualifiers="const"> <return type="RID"> </return> <description> + Returns the RID of the resource associated with this [VisualInstance]. For example, if the Node is a [MeshInstance], this will return the RID of the associated [Mesh]. </description> </method> <method name="get_instance" qualifiers="const"> <return type="RID"> </return> <description> + Returns the RID of this instance. This RID is the same as the RID returned by [method VisualServer.instance_create]. This RID is needed if you want to call [VisualServer] functions directly on this [VisualInstance]. </description> </method> <method name="get_layer_mask_bit" qualifiers="const"> @@ -32,14 +36,15 @@ <argument index="0" name="layer" type="int"> </argument> <description> + Returns [code]true[/code] when the specified layer is enabled in [member layers] and [code]false[/code] otherwise. </description> </method> <method name="get_transformed_aabb" qualifiers="const"> <return type="AABB"> </return> <description> - Returns the transformed [AABB] (also known as the bounding box) for this VisualInstance. - Transformed in this case means the [AABB] plus the position, rotation, and scale of the [Spatial]s [Transform] + Returns the transformed [AABB] (also known as the bounding box) for this [VisualInstance]. + Transformed in this case means the [AABB] plus the position, rotation, and scale of the [Spatial]'s [Transform]. </description> </method> <method name="set_base"> @@ -48,8 +53,7 @@ <argument index="0" name="base" type="RID"> </argument> <description> - Sets the base of the VisualInstance, which changes how the engine handles the VisualInstance under the hood. - It is recommended to only use [method set_base] if you know what you're doing. + Sets the resource that is instantiated by this [VisualInstance], which changes how the engine handles the [VisualInstance] under the hood. Equivalent to [method VisualServer.instance_set_base]. </description> </method> <method name="set_layer_mask_bit"> @@ -60,13 +64,14 @@ <argument index="1" name="enabled" type="bool"> </argument> <description> + Enables a particular layer in [member layers]. </description> </method> </methods> <members> <member name="layers" type="int" setter="set_layer_mask" getter="get_layer_mask" default="1"> - The render layer(s) this VisualInstance is drawn on. - This object will only be visible for [Camera]s whose cull mask includes the render object this VisualInstance is set to. + The render layer(s) this [VisualInstance] is drawn on. + This object will only be visible for [Camera]s whose cull mask includes the render object this [VisualInstance] is set to. </member> </members> <constants> diff --git a/doc/classes/VisualServer.xml b/doc/classes/VisualServer.xml index c00710ade9..2a830abcb2 100644 --- a/doc/classes/VisualServer.xml +++ b/doc/classes/VisualServer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualServer" inherits="Object" category="Core" version="3.2"> +<class name="VisualServer" inherits="Object" version="4.0"> <brief_description> Server for anything visible. </brief_description> @@ -15,7 +15,7 @@ In 2D, all visible objects are some form of canvas item. In order to be visible, a canvas item needs to be the child of a canvas attached to a viewport, or it needs to be the child of another canvas item that is eventually attached to the canvas. </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/optimization/using_servers.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/optimization/using_servers.html</link> </tutorials> <methods> <method name="black_bars_set_images"> @@ -64,7 +64,7 @@ <argument index="1" name="layers" type="int"> </argument> <description> - Sets the cull mask associated with this camera. The cull mask describes which 3d layers are rendered by this camera. Equivalent to [member Camera.cull_mask]. + Sets the cull mask associated with this camera. The cull mask describes which 3D layers are rendered by this camera. Equivalent to [member Camera.cull_mask]. </description> </method> <method name="camera_set_environment"> @@ -1679,7 +1679,7 @@ <argument index="0" name="feature" type="String"> </argument> <description> - Returns [code]true[/code] if the OS supports a certain feature. Features might be s3tc, etc, etc2 and pvrtc, + Returns [code]true[/code] if the OS supports a certain feature. Features might be [code]s3tc[/code], [code]etc[/code], [code]etc2[/code] and [code]pvrtc[/code]. </description> </method> <method name="immediate_begin"> @@ -3018,7 +3018,7 @@ <argument index="0" name="particles" type="RID"> </argument> <description> - Reset the particles on the next update. Equivalent to [method Particles.restart] + Reset the particles on the next update. Equivalent to [method Particles.restart]. </description> </method> <method name="particles_set_amount"> @@ -3897,7 +3897,7 @@ <argument index="2" name="screen" type="int" default="0"> </argument> <description> - Copies viewport to a region of the screen specified by [code]rect[/code]. If Viewport.[member Viewport.render_direct_to_screen] is [code]true[/code], then viewport does not use a framebuffer and the contents of the viewport are rendered directly to screen. However, note that the root viewport is drawn last, therefore it will draw over the screen. Accordingly, you must set the root viewport to an area that does not cover the area that you have attached this viewport to. + Copies viewport to a region of the screen specified by [code]rect[/code]. If [member Viewport.render_direct_to_screen] is [code]true[/code], then viewport does not use a framebuffer and the contents of the viewport are rendered directly to screen. However, note that the root viewport is drawn last, therefore it will draw over the screen. Accordingly, you must set the root viewport to an area that does not cover the area that you have attached this viewport to. For example, you can set the root viewport to not render at all with the following code: [codeblock] func _ready(): diff --git a/doc/classes/VisualShader.xml b/doc/classes/VisualShader.xml index 15216948e4..44e843f8a5 100644 --- a/doc/classes/VisualShader.xml +++ b/doc/classes/VisualShader.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShader" inherits="Shader" category="Core" version="3.2"> +<class name="VisualShader" inherits="Shader" version="4.0"> <brief_description> A custom shader program with a visual editor. </brief_description> diff --git a/doc/classes/VisualShaderNode.xml b/doc/classes/VisualShaderNode.xml index 9b0c6b2604..bed97565ff 100644 --- a/doc/classes/VisualShaderNode.xml +++ b/doc/classes/VisualShaderNode.xml @@ -1,18 +1,36 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNode" inherits="Resource" category="Core" version="3.2"> +<class name="VisualShaderNode" inherits="Resource" version="4.0"> <brief_description> </brief_description> <description> </description> <tutorials> + <link>https://docs.godotengine.org/en/latest/tutorials/shading/visual_shaders.html</link> </tutorials> <methods> + <method name="get_default_input_values" qualifiers="const"> + <return type="Array"> + </return> + <description> + Returns an [Array] containing default values for all of the input ports of the node in the form [code][index0, value0, index1, value1, ...][/code]. + </description> + </method> <method name="get_input_port_default_value" qualifiers="const"> <return type="Variant"> </return> <argument index="0" name="port" type="int"> </argument> <description> + Returns the default value of the input [code]port[/code]. + </description> + </method> + <method name="set_default_input_values"> + <return type="void"> + </return> + <argument index="0" name="values" type="Array"> + </argument> + <description> + Sets the default input ports values using an [Array] of the form [code][index0, value0, index1, value1, ...][/code]. For example: [code][0, Vector3(0, 0, 0), 1, Vector3(0, 0, 0)][/code]. </description> </method> <method name="set_input_port_default_value"> @@ -23,18 +41,19 @@ <argument index="1" name="value" type="Variant"> </argument> <description> + Sets the default value for the selected input [code]port[/code]. </description> </method> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" default="[ 0, Vector3( 0, 0, 0 ) ]"> - </member> <member name="output_port_for_preview" type="int" setter="set_output_port_for_preview" getter="get_output_port_for_preview" default="-1"> + Sets the output port index which will be showed for preview. If set to [code]-1[/code] no port will be open for preview. </member> </members> <signals> <signal name="editor_refresh_request"> <description> + Emitted when the node requests an editor refresh. Currently called only in setter of [member VisualShaderNodeTexture.source], [VisualShaderNodeTexture], and [VisualShaderNodeCubeMap] (and their derivatives). </description> </signal> </signals> diff --git a/doc/classes/VisualShaderNodeBooleanConstant.xml b/doc/classes/VisualShaderNodeBooleanConstant.xml index 2490dbbcc0..cccb64e874 100644 --- a/doc/classes/VisualShaderNodeBooleanConstant.xml +++ b/doc/classes/VisualShaderNodeBooleanConstant.xml @@ -1,8 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeBooleanConstant" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeBooleanConstant" inherits="VisualShaderNode" version="4.0"> <brief_description> + A boolean constant to be used within the visual shader graph. </brief_description> <description> + Has only one output port and no inputs. + Translated to [code]bool[/code] in the shader language. </description> <tutorials> </tutorials> @@ -10,8 +13,8 @@ </methods> <members> <member name="constant" type="bool" setter="set_constant" getter="get_constant" default="false"> + A boolean constant which represents a state of this node. </member> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> </members> <constants> </constants> diff --git a/doc/classes/VisualShaderNodeBooleanUniform.xml b/doc/classes/VisualShaderNodeBooleanUniform.xml index 518c7ba3b8..8313a8256e 100644 --- a/doc/classes/VisualShaderNodeBooleanUniform.xml +++ b/doc/classes/VisualShaderNodeBooleanUniform.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeBooleanUniform" inherits="VisualShaderNodeUniform" category="Core" version="3.2"> +<class name="VisualShaderNodeBooleanUniform" inherits="VisualShaderNodeUniform" version="4.0"> <brief_description> + A boolean uniform to be used within the visual shader graph. </brief_description> <description> + Translated to [code]uniform bool[/code] in the shader language. </description> <tutorials> </tutorials> diff --git a/doc/classes/VisualShaderNodeColorConstant.xml b/doc/classes/VisualShaderNodeColorConstant.xml index f58d1d8e76..9b122ca8e1 100644 --- a/doc/classes/VisualShaderNodeColorConstant.xml +++ b/doc/classes/VisualShaderNodeColorConstant.xml @@ -1,8 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeColorConstant" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeColorConstant" inherits="VisualShaderNode" version="4.0"> <brief_description> + A [Color] constant to be used within the visual shader graph. </brief_description> <description> + Has two output ports representing RGB and alpha channels of [Color]. + Translated to [code]vec3 rgb[/code] and [code]float alpha[/code] in the shader language. </description> <tutorials> </tutorials> @@ -10,8 +13,8 @@ </methods> <members> <member name="constant" type="Color" setter="set_constant" getter="get_constant" default="Color( 1, 1, 1, 1 )"> + A [Color] constant which represents a state of this node. </member> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> </members> <constants> </constants> diff --git a/doc/classes/VisualShaderNodeColorFunc.xml b/doc/classes/VisualShaderNodeColorFunc.xml index b37a669ee9..b9abf85802 100644 --- a/doc/classes/VisualShaderNodeColorFunc.xml +++ b/doc/classes/VisualShaderNodeColorFunc.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeColorFunc" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeColorFunc" inherits="VisualShaderNode" version="4.0"> <brief_description> + A [Color] function to be used within the visual shader graph. </brief_description> <description> + Accept a [Color] to the input port and transform it according to [member function]. </description> <tutorials> </tutorials> @@ -10,12 +12,29 @@ </methods> <members> <member name="function" type="int" setter="set_function" getter="get_function" enum="VisualShaderNodeColorFunc.Function" default="0"> + A function to be applied to the input color. See [enum Function] for options. </member> </members> <constants> <constant name="FUNC_GRAYSCALE" value="0" enum="Function"> + Converts the color to grayscale using the following formula: + [codeblock] + vec3 c = input; + float max1 = max(c.r, c.g); + float max2 = max(max1, c.b); + float max3 = max(max1, max2); + return vec3(max3, max3, max3); + [/codeblock] </constant> <constant name="FUNC_SEPIA" value="1" enum="Function"> + Applies sepia tone effect using the following formula: + [codeblock] + vec3 c = input; + float r = (c.r * 0.393) + (c.g * 0.769) + (c.b * 0.189); + float g = (c.r * 0.349) + (c.g * 0.686) + (c.b * 0.168); + float b = (c.r * 0.272) + (c.g * 0.534) + (c.b * 0.131); + return vec3(r, g, b); + [/codeblock] </constant> </constants> </class> diff --git a/doc/classes/VisualShaderNodeColorOp.xml b/doc/classes/VisualShaderNodeColorOp.xml index 9997e9c83c..629e84d47b 100644 --- a/doc/classes/VisualShaderNodeColorOp.xml +++ b/doc/classes/VisualShaderNodeColorOp.xml @@ -1,36 +1,98 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeColorOp" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeColorOp" inherits="VisualShaderNode" version="4.0"> <brief_description> + A [Color] operator to be used within the visual shader graph. </brief_description> <description> + Applies [member operator] to two color inputs. </description> <tutorials> </tutorials> <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ) ]" /> <member name="operator" type="int" setter="set_operator" getter="get_operator" enum="VisualShaderNodeColorOp.Operator" default="0"> + An operator to be applied to the inputs. See [enum Operator] for options. </member> </members> <constants> <constant name="OP_SCREEN" value="0" enum="Operator"> + Produce a screen effect with the following formula: + [codeblock] + result = vec3(1.0) - (vec3(1.0) - a) * (vec3(1.0) - b); + [/codeblock] </constant> <constant name="OP_DIFFERENCE" value="1" enum="Operator"> + Produce a difference effect with the following formula: + [codeblock] + result = abs(a - b); + [/codeblock] </constant> <constant name="OP_DARKEN" value="2" enum="Operator"> + Produce a darken effect with the following formula: + [codeblock] + result = min(a, b); + [/codeblock] </constant> <constant name="OP_LIGHTEN" value="3" enum="Operator"> + Produce a lighten effect with the following formula: + [codeblock] + result = max(a, b); + [/codeblock] </constant> <constant name="OP_OVERLAY" value="4" enum="Operator"> + Produce an overlay effect with the following formula: + [codeblock] + for (int i = 0; i < 3; i++) { + float base = a[i]; + float blend = b[i]; + if (base < 0.5) { + result[i] = 2.0 * base * blend; + } else { + result[i] = 1.0 - 2.0 * (1.0 - blend) * (1.0 - base); + } + } + [/codeblock] </constant> <constant name="OP_DODGE" value="5" enum="Operator"> + Produce a dodge effect with the following formula: + [codeblock] + result = a / (vec3(1.0) - b); + [/codeblock] </constant> <constant name="OP_BURN" value="6" enum="Operator"> + Produce a burn effect with the following formula: + [codeblock] + result = vec3(1.0) - (vec3(1.0) - a) / b; + [/codeblock] </constant> <constant name="OP_SOFT_LIGHT" value="7" enum="Operator"> + Produce a soft light effect with the following formula: + [codeblock] + for (int i = 0; i < 3; i++) { + float base = a[i]; + float blend = b[i]; + if (base < 0.5) { + result[i] = base * (blend + 0.5); + } else { + result[i] = 1.0 - (1.0 - base) * (1.0 - (blend - 0.5)); + } + } + [/codeblock] </constant> <constant name="OP_HARD_LIGHT" value="8" enum="Operator"> + Produce a hard light effect with the following formula: + [codeblock] + for (int i = 0; i < 3; i++) { + float base = a[i]; + float blend = b[i]; + if (base < 0.5) { + result[i] = base * (2.0 * blend); + } else { + result[i] = 1.0 - (1.0 - base) * (1.0 - 2.0 * (blend - 0.5)); + } + } + [/codeblock] </constant> </constants> </class> diff --git a/doc/classes/VisualShaderNodeColorUniform.xml b/doc/classes/VisualShaderNodeColorUniform.xml index ec61729782..6972ccefd9 100644 --- a/doc/classes/VisualShaderNodeColorUniform.xml +++ b/doc/classes/VisualShaderNodeColorUniform.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeColorUniform" inherits="VisualShaderNodeUniform" category="Core" version="3.2"> +<class name="VisualShaderNodeColorUniform" inherits="VisualShaderNodeUniform" version="4.0"> <brief_description> + A [Color] uniform to be used within the visual shader graph. </brief_description> <description> + Translated to [code]uniform vec4[/code] in the shader language. </description> <tutorials> </tutorials> diff --git a/doc/classes/VisualShaderNodeCompare.xml b/doc/classes/VisualShaderNodeCompare.xml index b1106998e9..f207cba0a5 100644 --- a/doc/classes/VisualShaderNodeCompare.xml +++ b/doc/classes/VisualShaderNodeCompare.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeCompare" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeCompare" inherits="VisualShaderNode" version="4.0"> <brief_description> + A comparison function for common types within the visual shader graph. </brief_description> <description> + Compares [code]a[/code] and [code]b[/code] of [member type] by [member function]. Returns a boolean scalar. Translates to [code]if[/code] instruction in shader code. </description> <tutorials> </tutorials> @@ -10,37 +12,51 @@ </methods> <members> <member name="condition" type="int" setter="set_condition" getter="get_condition" enum="VisualShaderNodeCompare.Condition" default="0"> + Extra condition which is applied if [member type] is set to [constant CTYPE_VECTOR]. </member> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, 0.0, 2, 1e-05 ]" /> <member name="function" type="int" setter="set_function" getter="get_function" enum="VisualShaderNodeCompare.Function" default="0"> + A comparison function. See [enum Function] for options. </member> - <member name="type" type="int" setter="set_comparsion_type" getter="get_comparsion_type" enum="VisualShaderNodeCompare.ComparsionType" default="0"> + <member name="type" type="int" setter="set_comparison_type" getter="get_comparison_type" enum="VisualShaderNodeCompare.ComparisonType" default="0"> + The type to be used in the comparison. See [enum ComparisonType] for options. </member> </members> <constants> - <constant name="CTYPE_SCALAR" value="0" enum="ComparsionType"> + <constant name="CTYPE_SCALAR" value="0" enum="ComparisonType"> + A floating-point scalar. </constant> - <constant name="CTYPE_VECTOR" value="1" enum="ComparsionType"> + <constant name="CTYPE_VECTOR" value="1" enum="ComparisonType"> + A 3D vector type. </constant> - <constant name="CTYPE_BOOLEAN" value="2" enum="ComparsionType"> + <constant name="CTYPE_BOOLEAN" value="2" enum="ComparisonType"> + A boolean type. </constant> - <constant name="CTYPE_TRANSFORM" value="3" enum="ComparsionType"> + <constant name="CTYPE_TRANSFORM" value="3" enum="ComparisonType"> + A transform ([code]mat4[/code]) type. </constant> <constant name="FUNC_EQUAL" value="0" enum="Function"> + Comparison for equality ([code]a == b[/code]). </constant> <constant name="FUNC_NOT_EQUAL" value="1" enum="Function"> + Comparison for inequality ([code]a != b[/code]). </constant> <constant name="FUNC_GREATER_THAN" value="2" enum="Function"> + Comparison for greater than ([code]a > b[/code]). Cannot be used if [member type] set to [constant CTYPE_BOOLEAN] or [constant CTYPE_TRANSFORM]. </constant> <constant name="FUNC_GREATER_THAN_EQUAL" value="3" enum="Function"> + Comparison for greater than or equal ([code]a >= b[/code]). Cannot be used if [member type] set to [constant CTYPE_BOOLEAN] or [constant CTYPE_TRANSFORM]. </constant> <constant name="FUNC_LESS_THAN" value="4" enum="Function"> + Comparison for less than ([code]a < b[/code]). Cannot be used if [member type] set to [constant CTYPE_BOOLEAN] or [constant CTYPE_TRANSFORM]. </constant> <constant name="FUNC_LESS_THAN_EQUAL" value="5" enum="Function"> + Comparison for less than or equal ([code]a < b[/code]). Cannot be used if [member type] set to [constant CTYPE_BOOLEAN] or [constant CTYPE_TRANSFORM]. </constant> <constant name="COND_ALL" value="0" enum="Condition"> + The result will be true if all of component in vector satisfy the comparison condition. </constant> <constant name="COND_ANY" value="1" enum="Condition"> + The result will be true if any of component in vector satisfy the comparison condition. </constant> </constants> </class> diff --git a/doc/classes/VisualShaderNodeCubeMap.xml b/doc/classes/VisualShaderNodeCubeMap.xml index 29ebe95086..8b9cec968c 100644 --- a/doc/classes/VisualShaderNodeCubeMap.xml +++ b/doc/classes/VisualShaderNodeCubeMap.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeCubeMap" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeCubeMap" inherits="VisualShaderNode" version="4.0"> <brief_description> + A [CubeMap] sampling node to be used within the visual shader graph. </brief_description> <description> + Translated to [code]texture(cubemap, vec3)[/code] in the shader language. Returns a color vector and alpha channel as scalar. </description> <tutorials> </tutorials> @@ -10,23 +12,30 @@ </methods> <members> <member name="cube_map" type="CubeMap" setter="set_cube_map" getter="get_cube_map"> + The [CubeMap] texture to sample when using [constant SOURCE_TEXTURE] as [member source]. </member> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> <member name="source" type="int" setter="set_source" getter="get_source" enum="VisualShaderNodeCubeMap.Source" default="0"> + Defines which source should be used for the sampling. See [enum Source] for options. </member> <member name="texture_type" type="int" setter="set_texture_type" getter="get_texture_type" enum="VisualShaderNodeCubeMap.TextureType" default="0"> + Defines the type of data provided by the source texture. See [enum TextureType] for options. </member> </members> <constants> <constant name="SOURCE_TEXTURE" value="0" enum="Source"> + Use the [CubeMap] set via [member cube_map]. If this is set to [member source], the [code]samplerCube[/code] port is ignored. </constant> <constant name="SOURCE_PORT" value="1" enum="Source"> + Use the [CubeMap] sampler reference passed via the [code]samplerCube[/code] port. If this is set to [member source], the [member cube_map] texture is ignored. </constant> <constant name="TYPE_DATA" value="0" enum="TextureType"> + No hints are added to the uniform declaration. </constant> <constant name="TYPE_COLOR" value="1" enum="TextureType"> + Adds [code]hint_albedo[/code] as hint to the uniform declaration for proper sRGB to linear conversion. </constant> <constant name="TYPE_NORMALMAP" value="2" enum="TextureType"> + Adds [code]hint_normal[/code] as hint to the uniform declaration, which internally converts the texture for proper usage as normal map. </constant> </constants> </class> diff --git a/doc/classes/VisualShaderNodeCubeMapUniform.xml b/doc/classes/VisualShaderNodeCubeMapUniform.xml index c6b3db5a9d..c5cb6ed938 100644 --- a/doc/classes/VisualShaderNodeCubeMapUniform.xml +++ b/doc/classes/VisualShaderNodeCubeMapUniform.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeCubeMapUniform" inherits="VisualShaderNodeTextureUniform" category="Core" version="3.2"> +<class name="VisualShaderNodeCubeMapUniform" inherits="VisualShaderNodeTextureUniform" version="4.0"> <brief_description> + A [CubeMap] uniform node to be used within the visual shader graph. </brief_description> <description> + Translated to [code]uniform samplerCube[/code] in the shader language. The output value can be used as port for [VisualShaderNodeCubeMap]. </description> <tutorials> </tutorials> diff --git a/doc/classes/VisualShaderNodeCustom.xml b/doc/classes/VisualShaderNodeCustom.xml index 5219dcb77b..9ccdf0d3c4 100644 --- a/doc/classes/VisualShaderNodeCustom.xml +++ b/doc/classes/VisualShaderNodeCustom.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeCustom" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeCustom" inherits="VisualShaderNode" version="4.0"> <brief_description> Virtual class to define custom [VisualShaderNode]s for use in the Visual Shader Editor. </brief_description> @@ -13,7 +13,7 @@ [/codeblock] </description> <tutorials> - <link>http://docs.godotengine.org/en/latest/tutorials/plugins/editor/visual_shader_plugins.html</link> + <link>https://docs.godotengine.org/en/latest/tutorials/plugins/editor/visual_shader_plugins.html</link> </tutorials> <methods> <method name="_get_category" qualifiers="virtual"> @@ -144,9 +144,6 @@ </description> </method> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeDeterminant.xml b/doc/classes/VisualShaderNodeDeterminant.xml index 4ea7e5ed6e..72be31872d 100644 --- a/doc/classes/VisualShaderNodeDeterminant.xml +++ b/doc/classes/VisualShaderNodeDeterminant.xml @@ -1,16 +1,15 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeDeterminant" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeDeterminant" inherits="VisualShaderNode" version="4.0"> <brief_description> + Calculates the determinant of a [Transform] within the visual shader graph. </brief_description> <description> + Translates to [code]deteminant(x)[/code] in the shader language. </description> <tutorials> </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeDotProduct.xml b/doc/classes/VisualShaderNodeDotProduct.xml index 4c2bae39a1..51166ab58f 100644 --- a/doc/classes/VisualShaderNodeDotProduct.xml +++ b/doc/classes/VisualShaderNodeDotProduct.xml @@ -1,16 +1,15 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeDotProduct" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeDotProduct" inherits="VisualShaderNode" version="4.0"> <brief_description> + Calculates a dot product of two vectors within the visual shader graph. </brief_description> <description> + Translates to [code]dot(a, b)[/code] in the shader language. </description> <tutorials> </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeExpression.xml b/doc/classes/VisualShaderNodeExpression.xml index 9727b8698b..f571edaab3 100644 --- a/doc/classes/VisualShaderNodeExpression.xml +++ b/doc/classes/VisualShaderNodeExpression.xml @@ -1,22 +1,19 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeExpression" inherits="VisualShaderNodeGroupBase" category="Core" version="3.2"> +<class name="VisualShaderNodeExpression" inherits="VisualShaderNodeGroupBase" version="4.0"> <brief_description> + A custom visual shader graph expression written in Godot Shading Language. </brief_description> <description> + Custom Godot Shading Language expression, with a custom amount of input and output ports. + The provided code is directly injected into the graph's matching shader function ([code]vertex[/code], [code]fragment[/code], or [code]light[/code]), so it cannot be used to to declare functions, varyings, uniforms, or global constants. See [VisualShaderNodeGlobalExpression] for such global definitions. </description> <tutorials> </tutorials> <methods> - <method name="build"> - <return type="void"> - </return> - <description> - </description> - </method> </methods> <members> - <member name="editable" type="bool" setter="set_editable" getter="is_editable" override="true" default="true" /> <member name="expression" type="String" setter="set_expression" getter="get_expression" default=""""> + An expression in Godot Shading Language, which will be injected at the start of the graph's matching shader function ([code]vertex[/code], [code]fragment[/code], or [code]light[/code]), and thus cannot be used to declare functions, varyings, uniforms, or global constants. </member> </members> <constants> diff --git a/doc/classes/VisualShaderNodeFaceForward.xml b/doc/classes/VisualShaderNodeFaceForward.xml index 9c755cc6de..5ef08ea8c2 100644 --- a/doc/classes/VisualShaderNodeFaceForward.xml +++ b/doc/classes/VisualShaderNodeFaceForward.xml @@ -1,16 +1,15 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeFaceForward" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeFaceForward" inherits="VisualShaderNode" version="4.0"> <brief_description> + Returns the vector that points in the same direction as a reference vector within the visual shader graph. </brief_description> <description> + Translates to [code]faceforward(N, I, Nref)[/code] in the shader language. The function has three vector parameters: [code]N[/code], the vector to orient, [code]I[/code], the incident vector, and [code]Nref[/code], the reference vector. If the dot product of [code]I[/code] and [code]Nref[/code] is smaller than zero the return value is [code]N[/code]. Otherwise [code]-N[/code] is returned. </description> <tutorials> </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ), 2, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeFresnel.xml b/doc/classes/VisualShaderNodeFresnel.xml index b71f5c6f37..c396b4574c 100644 --- a/doc/classes/VisualShaderNodeFresnel.xml +++ b/doc/classes/VisualShaderNodeFresnel.xml @@ -1,16 +1,15 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeFresnel" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeFresnel" inherits="VisualShaderNode" version="4.0"> <brief_description> + A Fresnel effect to be used within the visual shader graph. </brief_description> <description> + Returns falloff based on the dot product of surface normal and view direction of camera (pass associated inputs to it). </description> <tutorials> </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 2, false, 3, 1.0 ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeGlobalExpression.xml b/doc/classes/VisualShaderNodeGlobalExpression.xml index f008c639cf..8023ba1890 100644 --- a/doc/classes/VisualShaderNodeGlobalExpression.xml +++ b/doc/classes/VisualShaderNodeGlobalExpression.xml @@ -1,16 +1,15 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeGlobalExpression" inherits="VisualShaderNodeExpression" category="Core" version="3.2"> +<class name="VisualShaderNodeGlobalExpression" inherits="VisualShaderNodeExpression" version="4.0"> <brief_description> + A custom global visual shader graph expression written in Godot Shading Language. </brief_description> <description> + Custom Godot Shader Language expression, which is placed on top of the generated shader. You can place various function definitions inside to call later in [VisualShaderNodeExpression]s (which are injected in the main shader functions). You can also declare varyings, uniforms and global constants. </description> <tutorials> </tutorials> <methods> </methods> - <members> - <member name="editable" type="bool" setter="set_editable" getter="is_editable" override="true" default="false" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeGroupBase.xml b/doc/classes/VisualShaderNodeGroupBase.xml index 511a56b7a6..13018d52f3 100644 --- a/doc/classes/VisualShaderNodeGroupBase.xml +++ b/doc/classes/VisualShaderNodeGroupBase.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeGroupBase" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeGroupBase" inherits="VisualShaderNode" version="4.0"> <brief_description> + Base class for a family of nodes with variable amount of input and output ports within the visual shader graph. </brief_description> <description> + Currently, has no direct usage, use the derived classes instead. </description> <tutorials> </tutorials> @@ -17,6 +19,7 @@ <argument index="2" name="name" type="String"> </argument> <description> + Adds an input port with the specified [code]type[/code] (see [enum VisualShaderNode.PortType]) and [code]name[/code]. </description> </method> <method name="add_output_port"> @@ -29,68 +32,63 @@ <argument index="2" name="name" type="String"> </argument> <description> + Adds an output port with the specified [code]type[/code] (see [enum VisualShaderNode.PortType]) and [code]name[/code]. </description> </method> <method name="clear_input_ports"> <return type="void"> </return> <description> + Removes all previously specified input ports. </description> </method> <method name="clear_output_ports"> <return type="void"> </return> <description> - </description> - </method> - <method name="get_control"> - <return type="Control"> - </return> - <argument index="0" name="index" type="int"> - </argument> - <description> + Removes all previously specified output ports. </description> </method> <method name="get_free_input_port_id" qualifiers="const"> <return type="int"> </return> <description> + Returns a free input port ID which can be used in [method add_input_port]. </description> </method> <method name="get_free_output_port_id" qualifiers="const"> <return type="int"> </return> <description> + Returns a free output port ID which can be used in [method add_output_port]. </description> </method> <method name="get_input_port_count" qualifiers="const"> <return type="int"> </return> <description> + Returns the number of input ports in use. Alternative for [method get_free_input_port_id]. </description> </method> <method name="get_inputs" qualifiers="const"> <return type="String"> </return> <description> + Returns a [String] description of the input ports as as colon-separated list using the format [code]id,type,name;[/code] (see [method add_input_port]). </description> </method> <method name="get_output_port_count" qualifiers="const"> <return type="int"> </return> <description> + Returns the number of output ports in use. Alternative for [method get_free_output_port_id]. </description> </method> <method name="get_outputs" qualifiers="const"> <return type="String"> </return> <description> - </description> - </method> - <method name="get_size" qualifiers="const"> - <return type="Vector2"> - </return> - <description> + Returns a [String] description of the output ports as as colon-separated list using the format [code]id,type,name;[/code] (see [method add_output_port]). </description> </method> <method name="has_input_port" qualifiers="const"> @@ -99,6 +97,7 @@ <argument index="0" name="id" type="int"> </argument> <description> + Returns [code]true[/code] if the specified input port exists. </description> </method> <method name="has_output_port" qualifiers="const"> @@ -107,6 +106,7 @@ <argument index="0" name="id" type="int"> </argument> <description> + Returns [code]true[/code] if the specified output port exists. </description> </method> <method name="is_valid_port_name" qualifiers="const"> @@ -115,6 +115,7 @@ <argument index="0" name="name" type="String"> </argument> <description> + Returns [code]true[/code] if the specified port name does not override an existed port name and is valid within the shader. </description> </method> <method name="remove_input_port"> @@ -123,6 +124,7 @@ <argument index="0" name="id" type="int"> </argument> <description> + Removes the specified input port. </description> </method> <method name="remove_output_port"> @@ -131,16 +133,7 @@ <argument index="0" name="id" type="int"> </argument> <description> - </description> - </method> - <method name="set_control"> - <return type="void"> - </return> - <argument index="0" name="control" type="Control"> - </argument> - <argument index="1" name="index" type="int"> - </argument> - <description> + Removes the specified output port. </description> </method> <method name="set_input_port_name"> @@ -151,6 +144,7 @@ <argument index="1" name="name" type="String"> </argument> <description> + Renames the specified input port. </description> </method> <method name="set_input_port_type"> @@ -161,6 +155,7 @@ <argument index="1" name="type" type="int"> </argument> <description> + Sets the specified input port's type (see [enum VisualShaderNode.PortType]). </description> </method> <method name="set_inputs"> @@ -169,6 +164,7 @@ <argument index="0" name="inputs" type="String"> </argument> <description> + Defines all input ports using a [String] formatted as a colon-separated list: [code]id,type,name;[/code] (see [method add_input_port]). </description> </method> <method name="set_output_port_name"> @@ -179,6 +175,7 @@ <argument index="1" name="name" type="String"> </argument> <description> + Renames the specified output port. </description> </method> <method name="set_output_port_type"> @@ -189,6 +186,7 @@ <argument index="1" name="type" type="int"> </argument> <description> + Sets the specified output port's type (see [enum VisualShaderNode.PortType]). </description> </method> <method name="set_outputs"> @@ -197,20 +195,13 @@ <argument index="0" name="outputs" type="String"> </argument> <description> - </description> - </method> - <method name="set_size"> - <return type="void"> - </return> - <argument index="0" name="size" type="Vector2"> - </argument> - <description> + Defines all output ports using a [String] formatted as a colon-separated list: [code]id,type,name;[/code] (see [method add_output_port]). </description> </method> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> - <member name="editable" type="bool" setter="set_editable" getter="is_editable" default="false"> + <member name="size" type="Vector2" setter="set_size" getter="get_size" default="Vector2( 0, 0 )"> + The size of the node in the visual shader graph. </member> </members> <constants> diff --git a/doc/classes/VisualShaderNodeIf.xml b/doc/classes/VisualShaderNodeIf.xml index 6900cdf81b..0a8fdcfd4d 100644 --- a/doc/classes/VisualShaderNodeIf.xml +++ b/doc/classes/VisualShaderNodeIf.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeIf" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeIf" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, 0.0, 2, 1e-05, 3, Vector3( 0, 0, 0 ), 4, Vector3( 0, 0, 0 ), 5, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeInput.xml b/doc/classes/VisualShaderNodeInput.xml index bfcd4c734c..1c8d8d84c4 100644 --- a/doc/classes/VisualShaderNodeInput.xml +++ b/doc/classes/VisualShaderNodeInput.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeInput" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeInput" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -15,7 +15,6 @@ </method> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> <member name="input_name" type="String" setter="set_input_name" getter="get_input_name" default=""[None]""> </member> </members> diff --git a/doc/classes/VisualShaderNodeIs.xml b/doc/classes/VisualShaderNodeIs.xml index c221e60b75..184c9e099f 100644 --- a/doc/classes/VisualShaderNodeIs.xml +++ b/doc/classes/VisualShaderNodeIs.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeIs" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeIs" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0 ]" /> <member name="function" type="int" setter="set_function" getter="get_function" enum="VisualShaderNodeIs.Function" default="0"> </member> </members> diff --git a/doc/classes/VisualShaderNodeOuterProduct.xml b/doc/classes/VisualShaderNodeOuterProduct.xml index 6111084b44..b8d4fd687f 100644 --- a/doc/classes/VisualShaderNodeOuterProduct.xml +++ b/doc/classes/VisualShaderNodeOuterProduct.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeOuterProduct" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeOuterProduct" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeOutput.xml b/doc/classes/VisualShaderNodeOutput.xml index ff109a949e..c63e307bad 100644 --- a/doc/classes/VisualShaderNodeOutput.xml +++ b/doc/classes/VisualShaderNodeOutput.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeOutput" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeOutput" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeScalarClamp.xml b/doc/classes/VisualShaderNodeScalarClamp.xml index 927aeb01ce..fd963dcb5d 100644 --- a/doc/classes/VisualShaderNodeScalarClamp.xml +++ b/doc/classes/VisualShaderNodeScalarClamp.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarClamp" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarClamp" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, 0.0, 2, 1.0 ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeScalarConstant.xml b/doc/classes/VisualShaderNodeScalarConstant.xml index c4ac65aa48..f7b94d9e39 100644 --- a/doc/classes/VisualShaderNodeScalarConstant.xml +++ b/doc/classes/VisualShaderNodeScalarConstant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarConstant" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarConstant" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -11,7 +11,6 @@ <members> <member name="constant" type="float" setter="set_constant" getter="get_constant" default="0.0"> </member> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> </members> <constants> </constants> diff --git a/doc/classes/VisualShaderNodeScalarDerivativeFunc.xml b/doc/classes/VisualShaderNodeScalarDerivativeFunc.xml index 795054637e..fa9aa07761 100644 --- a/doc/classes/VisualShaderNodeScalarDerivativeFunc.xml +++ b/doc/classes/VisualShaderNodeScalarDerivativeFunc.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarDerivativeFunc" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarDerivativeFunc" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0 ]" /> <member name="function" type="int" setter="set_function" getter="get_function" enum="VisualShaderNodeScalarDerivativeFunc.Function" default="0"> </member> </members> diff --git a/doc/classes/VisualShaderNodeScalarFunc.xml b/doc/classes/VisualShaderNodeScalarFunc.xml index 81ccf8aeb6..b306d198f6 100644 --- a/doc/classes/VisualShaderNodeScalarFunc.xml +++ b/doc/classes/VisualShaderNodeScalarFunc.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarFunc" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarFunc" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0 ]" /> <member name="function" type="int" setter="set_function" getter="get_function" enum="VisualShaderNodeScalarFunc.Function" default="13"> </member> </members> diff --git a/doc/classes/VisualShaderNodeScalarInterp.xml b/doc/classes/VisualShaderNodeScalarInterp.xml index 7e40304b04..a25ab750cc 100644 --- a/doc/classes/VisualShaderNodeScalarInterp.xml +++ b/doc/classes/VisualShaderNodeScalarInterp.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarInterp" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarInterp" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, 1.0, 2, 0.5 ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeScalarOp.xml b/doc/classes/VisualShaderNodeScalarOp.xml index 3ff56bffaa..f13f16cdd2 100644 --- a/doc/classes/VisualShaderNodeScalarOp.xml +++ b/doc/classes/VisualShaderNodeScalarOp.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarOp" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarOp" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, 0.0 ]" /> <member name="operator" type="int" setter="set_operator" getter="get_operator" enum="VisualShaderNodeScalarOp.Operator" default="0"> </member> </members> diff --git a/doc/classes/VisualShaderNodeScalarSmoothStep.xml b/doc/classes/VisualShaderNodeScalarSmoothStep.xml index e71bb16f6f..1ac16e451f 100644 --- a/doc/classes/VisualShaderNodeScalarSmoothStep.xml +++ b/doc/classes/VisualShaderNodeScalarSmoothStep.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarSmoothStep" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarSmoothStep" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, 0.0, 2, 0.0 ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeScalarSwitch.xml b/doc/classes/VisualShaderNodeScalarSwitch.xml index 2828f42b47..789c8972bb 100644 --- a/doc/classes/VisualShaderNodeScalarSwitch.xml +++ b/doc/classes/VisualShaderNodeScalarSwitch.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarSwitch" inherits="VisualShaderNodeSwitch" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarSwitch" inherits="VisualShaderNodeSwitch" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, false, 1, 1.0, 2, 0.0 ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeScalarUniform.xml b/doc/classes/VisualShaderNodeScalarUniform.xml index bdbb02561b..d1a4742555 100644 --- a/doc/classes/VisualShaderNodeScalarUniform.xml +++ b/doc/classes/VisualShaderNodeScalarUniform.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeScalarUniform" inherits="VisualShaderNodeUniform" category="Core" version="3.2"> +<class name="VisualShaderNodeScalarUniform" inherits="VisualShaderNodeUniform" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeSwitch.xml b/doc/classes/VisualShaderNodeSwitch.xml index 704ac08adb..5bbb9168a0 100644 --- a/doc/classes/VisualShaderNodeSwitch.xml +++ b/doc/classes/VisualShaderNodeSwitch.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeSwitch" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeSwitch" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, false, 1, Vector3( 1, 1, 1 ), 2, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeTexture.xml b/doc/classes/VisualShaderNodeTexture.xml index 4150b36c9c..e1c12c69b6 100644 --- a/doc/classes/VisualShaderNodeTexture.xml +++ b/doc/classes/VisualShaderNodeTexture.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTexture" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeTexture" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> <member name="source" type="int" setter="set_source" getter="get_source" enum="VisualShaderNodeTexture.Source" default="0"> </member> <member name="texture" type="Texture" setter="set_texture" getter="get_texture"> diff --git a/doc/classes/VisualShaderNodeTextureUniform.xml b/doc/classes/VisualShaderNodeTextureUniform.xml index 3d58ec88c5..4e2c39a297 100644 --- a/doc/classes/VisualShaderNodeTextureUniform.xml +++ b/doc/classes/VisualShaderNodeTextureUniform.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTextureUniform" inherits="VisualShaderNodeUniform" category="Core" version="3.2"> +<class name="VisualShaderNodeTextureUniform" inherits="VisualShaderNodeUniform" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeTextureUniformTriplanar.xml b/doc/classes/VisualShaderNodeTextureUniformTriplanar.xml index d4e142651e..3d69575444 100644 --- a/doc/classes/VisualShaderNodeTextureUniformTriplanar.xml +++ b/doc/classes/VisualShaderNodeTextureUniformTriplanar.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTextureUniformTriplanar" inherits="VisualShaderNodeTextureUniform" category="Core" version="3.2"> +<class name="VisualShaderNodeTextureUniformTriplanar" inherits="VisualShaderNodeTextureUniform" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeTransformCompose.xml b/doc/classes/VisualShaderNodeTransformCompose.xml index 0c44e6b3c5..6d9cab7ab0 100644 --- a/doc/classes/VisualShaderNodeTransformCompose.xml +++ b/doc/classes/VisualShaderNodeTransformCompose.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTransformCompose" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeTransformCompose" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ), 2, Vector3( 0, 0, 0 ), 3, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeTransformConstant.xml b/doc/classes/VisualShaderNodeTransformConstant.xml index 737961f8ec..15422e1728 100644 --- a/doc/classes/VisualShaderNodeTransformConstant.xml +++ b/doc/classes/VisualShaderNodeTransformConstant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTransformConstant" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeTransformConstant" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -11,7 +11,6 @@ <members> <member name="constant" type="Transform" setter="set_constant" getter="get_constant" default="Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 )"> </member> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> </members> <constants> </constants> diff --git a/doc/classes/VisualShaderNodeTransformDecompose.xml b/doc/classes/VisualShaderNodeTransformDecompose.xml index 911d2e953a..4d3c464781 100644 --- a/doc/classes/VisualShaderNodeTransformDecompose.xml +++ b/doc/classes/VisualShaderNodeTransformDecompose.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTransformDecompose" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeTransformDecompose" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeTransformFunc.xml b/doc/classes/VisualShaderNodeTransformFunc.xml index 53b7c9f1ab..d2b6fcef2b 100644 --- a/doc/classes/VisualShaderNodeTransformFunc.xml +++ b/doc/classes/VisualShaderNodeTransformFunc.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTransformFunc" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeTransformFunc" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 ) ]" /> <member name="function" type="int" setter="set_function" getter="get_function" enum="VisualShaderNodeTransformFunc.Function" default="0"> </member> </members> diff --git a/doc/classes/VisualShaderNodeTransformMult.xml b/doc/classes/VisualShaderNodeTransformMult.xml index f5368b3b1c..5893d1413b 100644 --- a/doc/classes/VisualShaderNodeTransformMult.xml +++ b/doc/classes/VisualShaderNodeTransformMult.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTransformMult" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeTransformMult" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 ), 1, Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 ) ]" /> <member name="operator" type="int" setter="set_operator" getter="get_operator" enum="VisualShaderNodeTransformMult.Operator" default="0"> </member> </members> diff --git a/doc/classes/VisualShaderNodeTransformUniform.xml b/doc/classes/VisualShaderNodeTransformUniform.xml index 0a28e0c1f6..7605ef96d5 100644 --- a/doc/classes/VisualShaderNodeTransformUniform.xml +++ b/doc/classes/VisualShaderNodeTransformUniform.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTransformUniform" inherits="VisualShaderNodeUniform" category="Core" version="3.2"> +<class name="VisualShaderNodeTransformUniform" inherits="VisualShaderNodeUniform" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeTransformVecMult.xml b/doc/classes/VisualShaderNodeTransformVecMult.xml index 9ab9c08562..d53c3c5ae5 100644 --- a/doc/classes/VisualShaderNodeTransformVecMult.xml +++ b/doc/classes/VisualShaderNodeTransformVecMult.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeTransformVecMult" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeTransformVecMult" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Transform( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 ), 1, Vector3( 0, 0, 0 ) ]" /> <member name="operator" type="int" setter="set_operator" getter="get_operator" enum="VisualShaderNodeTransformVecMult.Operator" default="0"> </member> </members> diff --git a/doc/classes/VisualShaderNodeUniform.xml b/doc/classes/VisualShaderNodeUniform.xml index 05539294a0..c4362f6f2a 100644 --- a/doc/classes/VisualShaderNodeUniform.xml +++ b/doc/classes/VisualShaderNodeUniform.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeUniform" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeUniform" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> <member name="uniform_name" type="String" setter="set_uniform_name" getter="get_uniform_name" default=""""> </member> </members> diff --git a/doc/classes/VisualShaderNodeVec3Constant.xml b/doc/classes/VisualShaderNodeVec3Constant.xml index 06e033cd9d..8532c5476f 100644 --- a/doc/classes/VisualShaderNodeVec3Constant.xml +++ b/doc/classes/VisualShaderNodeVec3Constant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVec3Constant" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVec3Constant" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -11,7 +11,6 @@ <members> <member name="constant" type="Vector3" setter="set_constant" getter="get_constant" default="Vector3( 0, 0, 0 )"> </member> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ ]" /> </members> <constants> </constants> diff --git a/doc/classes/VisualShaderNodeVec3Uniform.xml b/doc/classes/VisualShaderNodeVec3Uniform.xml index a1c9b14566..f2b4c4778b 100644 --- a/doc/classes/VisualShaderNodeVec3Uniform.xml +++ b/doc/classes/VisualShaderNodeVec3Uniform.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVec3Uniform" inherits="VisualShaderNodeUniform" category="Core" version="3.2"> +<class name="VisualShaderNodeVec3Uniform" inherits="VisualShaderNodeUniform" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeVectorClamp.xml b/doc/classes/VisualShaderNodeVectorClamp.xml index 8b9a0cacff..85c093f84c 100644 --- a/doc/classes/VisualShaderNodeVectorClamp.xml +++ b/doc/classes/VisualShaderNodeVectorClamp.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorClamp" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorClamp" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ), 2, Vector3( 1, 1, 1 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeVectorCompose.xml b/doc/classes/VisualShaderNodeVectorCompose.xml index 11eb4d2778..e5e4924a9e 100644 --- a/doc/classes/VisualShaderNodeVectorCompose.xml +++ b/doc/classes/VisualShaderNodeVectorCompose.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorCompose" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorCompose" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, 0.0, 2, 0.0 ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeVectorDecompose.xml b/doc/classes/VisualShaderNodeVectorDecompose.xml index 30727379e6..5378f38b6d 100644 --- a/doc/classes/VisualShaderNodeVectorDecompose.xml +++ b/doc/classes/VisualShaderNodeVectorDecompose.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorDecompose" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorDecompose" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeVectorDerivativeFunc.xml b/doc/classes/VisualShaderNodeVectorDerivativeFunc.xml index 56f89ffc38..d62512d68b 100644 --- a/doc/classes/VisualShaderNodeVectorDerivativeFunc.xml +++ b/doc/classes/VisualShaderNodeVectorDerivativeFunc.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorDerivativeFunc" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorDerivativeFunc" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeVectorDistance.xml b/doc/classes/VisualShaderNodeVectorDistance.xml index 3b7f743864..2e681156a5 100644 --- a/doc/classes/VisualShaderNodeVectorDistance.xml +++ b/doc/classes/VisualShaderNodeVectorDistance.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorDistance" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorDistance" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeVectorFunc.xml b/doc/classes/VisualShaderNodeVectorFunc.xml index 3725a43395..0b3f317b8b 100644 --- a/doc/classes/VisualShaderNodeVectorFunc.xml +++ b/doc/classes/VisualShaderNodeVectorFunc.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorFunc" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorFunc" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeVectorInterp.xml b/doc/classes/VisualShaderNodeVectorInterp.xml index 7aa525cd0e..4d6d3ac577 100644 --- a/doc/classes/VisualShaderNodeVectorInterp.xml +++ b/doc/classes/VisualShaderNodeVectorInterp.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorInterp" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorInterp" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 1, 1, 1 ), 2, Vector3( 0.5, 0.5, 0.5 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeVectorLen.xml b/doc/classes/VisualShaderNodeVectorLen.xml index f6fdc0aff3..ade575310c 100644 --- a/doc/classes/VisualShaderNodeVectorLen.xml +++ b/doc/classes/VisualShaderNodeVectorLen.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorLen" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorLen" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/doc/classes/VisualShaderNodeVectorOp.xml b/doc/classes/VisualShaderNodeVectorOp.xml index d237ee56b0..8c391d09a2 100644 --- a/doc/classes/VisualShaderNodeVectorOp.xml +++ b/doc/classes/VisualShaderNodeVectorOp.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorOp" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorOp" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -9,7 +9,6 @@ <methods> </methods> <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ) ]" /> <member name="operator" type="int" setter="set_operator" getter="get_operator" enum="VisualShaderNodeVectorOp.Operator" default="0"> </member> </members> diff --git a/doc/classes/VisualShaderNodeVectorRefract.xml b/doc/classes/VisualShaderNodeVectorRefract.xml index 453c2bf02f..c5962e7e10 100644 --- a/doc/classes/VisualShaderNodeVectorRefract.xml +++ b/doc/classes/VisualShaderNodeVectorRefract.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorRefract" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorRefract" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ), 2, 0.0 ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeVectorScalarMix.xml b/doc/classes/VisualShaderNodeVectorScalarMix.xml index 4ab396a14b..c425bfe45e 100644 --- a/doc/classes/VisualShaderNodeVectorScalarMix.xml +++ b/doc/classes/VisualShaderNodeVectorScalarMix.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorScalarMix" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorScalarMix" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 1, 1, 1 ), 2, 0.5 ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeVectorScalarSmoothStep.xml b/doc/classes/VisualShaderNodeVectorScalarSmoothStep.xml index 2aeb8c1b53..2f341d71e0 100644 --- a/doc/classes/VisualShaderNodeVectorScalarSmoothStep.xml +++ b/doc/classes/VisualShaderNodeVectorScalarSmoothStep.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorScalarSmoothStep" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorScalarSmoothStep" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, 0.0, 2, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeVectorScalarStep.xml b/doc/classes/VisualShaderNodeVectorScalarStep.xml index c448404b7f..11da106001 100644 --- a/doc/classes/VisualShaderNodeVectorScalarStep.xml +++ b/doc/classes/VisualShaderNodeVectorScalarStep.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorScalarStep" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorScalarStep" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, 0.0, 1, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/VisualShaderNodeVectorSmoothStep.xml b/doc/classes/VisualShaderNodeVectorSmoothStep.xml index bb80832c3c..54e9f1bd7d 100644 --- a/doc/classes/VisualShaderNodeVectorSmoothStep.xml +++ b/doc/classes/VisualShaderNodeVectorSmoothStep.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualShaderNodeVectorSmoothStep" inherits="VisualShaderNode" category="Core" version="3.2"> +<class name="VisualShaderNodeVectorSmoothStep" inherits="VisualShaderNode" version="4.0"> <brief_description> </brief_description> <description> @@ -8,9 +8,6 @@ </tutorials> <methods> </methods> - <members> - <member name="default_input_values" type="Array" setter="_set_default_input_values" getter="_get_default_input_values" override="true" default="[ 0, Vector3( 0, 0, 0 ), 1, Vector3( 0, 0, 0 ), 2, Vector3( 0, 0, 0 ) ]" /> - </members> <constants> </constants> </class> diff --git a/doc/classes/WeakRef.xml b/doc/classes/WeakRef.xml index 6845c81a13..07d82289a3 100644 --- a/doc/classes/WeakRef.xml +++ b/doc/classes/WeakRef.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WeakRef" inherits="Reference" category="Core" version="3.2"> +<class name="WeakRef" inherits="Reference" version="4.0"> <brief_description> Holds an [Object], but does not contribute to the reference count if the object is a reference. </brief_description> diff --git a/doc/classes/WindowDialog.xml b/doc/classes/WindowDialog.xml index 595aaeecee..befa820f9b 100644 --- a/doc/classes/WindowDialog.xml +++ b/doc/classes/WindowDialog.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WindowDialog" inherits="Popup" category="Core" version="3.2"> +<class name="WindowDialog" inherits="Popup" version="4.0"> <brief_description> Base class for window dialogs. </brief_description> diff --git a/doc/classes/World.xml b/doc/classes/World.xml index c8e6944b83..361ec9b764 100644 --- a/doc/classes/World.xml +++ b/doc/classes/World.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="World" inherits="Resource" category="Core" version="3.2"> +<class name="World" inherits="Resource" version="4.0"> <brief_description> Class that has everything pertaining to a world. </brief_description> diff --git a/doc/classes/World2D.xml b/doc/classes/World2D.xml index 66ef18f8f4..9e2d4cfde3 100644 --- a/doc/classes/World2D.xml +++ b/doc/classes/World2D.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="World2D" inherits="Resource" category="Core" version="3.2"> +<class name="World2D" inherits="Resource" version="4.0"> <brief_description> Class that has everything pertaining to a 2D world. </brief_description> diff --git a/doc/classes/WorldEnvironment.xml b/doc/classes/WorldEnvironment.xml index b4524bfea0..9c062ecfd0 100644 --- a/doc/classes/WorldEnvironment.xml +++ b/doc/classes/WorldEnvironment.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WorldEnvironment" inherits="Node" category="Core" version="3.2"> +<class name="WorldEnvironment" inherits="Node" version="4.0"> <brief_description> Default environment properties for the entire scene (post-processing effects, lighting and background settings). </brief_description> diff --git a/doc/classes/X509Certificate.xml b/doc/classes/X509Certificate.xml index 50e9e4e0d4..d2b7b20cd6 100644 --- a/doc/classes/X509Certificate.xml +++ b/doc/classes/X509Certificate.xml @@ -1,11 +1,12 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="X509Certificate" inherits="Resource" category="Core" version="3.2"> +<class name="X509Certificate" inherits="Resource" version="4.0"> <brief_description> An X509 certificate (e.g. for SSL). </brief_description> <description> The X509Certificate class represents an X509 certificate. Certificates can be loaded and saved like any other [Resource]. They can be used as the server certificate in [method StreamPeerSSL.accept_stream] (along with the proper [CryptoKey]), and to specify the only certificate that should be accepted when connecting to an SSL server via [method StreamPeerSSL.connect_to_stream]. + [b]Note:[/b] Not available in HTML5 exports. </description> <tutorials> </tutorials> diff --git a/doc/classes/XMLParser.xml b/doc/classes/XMLParser.xml index 4375b2eb62..8140fde62d 100644 --- a/doc/classes/XMLParser.xml +++ b/doc/classes/XMLParser.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="XMLParser" inherits="Reference" category="Core" version="3.2"> +<class name="XMLParser" inherits="Reference" version="4.0"> <brief_description> Low-level class for creating parsers for [url=https://en.wikipedia.org/wiki/XML]XML[/url] files. </brief_description> @@ -147,25 +147,25 @@ </methods> <constants> <constant name="NODE_NONE" value="0" enum="NodeType"> - There's no node (no file or buffer opened) + There's no node (no file or buffer opened). </constant> <constant name="NODE_ELEMENT" value="1" enum="NodeType"> - Element (tag) + Element (tag). </constant> <constant name="NODE_ELEMENT_END" value="2" enum="NodeType"> - End of element + End of element. </constant> <constant name="NODE_TEXT" value="3" enum="NodeType"> - Text node + Text node. </constant> <constant name="NODE_COMMENT" value="4" enum="NodeType"> - Comment node + Comment node. </constant> <constant name="NODE_CDATA" value="5" enum="NodeType"> - CDATA content + CDATA content. </constant> <constant name="NODE_UNKNOWN" value="6" enum="NodeType"> - Unknown node + Unknown node. </constant> </constants> </class> diff --git a/doc/classes/YSort.xml b/doc/classes/YSort.xml index 6045a5713c..4ef6a4b4ec 100644 --- a/doc/classes/YSort.xml +++ b/doc/classes/YSort.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="YSort" inherits="Node2D" category="Core" version="3.2"> +<class name="YSort" inherits="Node2D" version="4.0"> <brief_description> Sort all child nodes based on their Y positions. </brief_description> diff --git a/doc/classes/bool.xml b/doc/classes/bool.xml index 533963b460..4482a280b2 100644 --- a/doc/classes/bool.xml +++ b/doc/classes/bool.xml @@ -1,10 +1,41 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="bool" category="Built-In Types" version="3.2"> +<class name="bool" version="4.0"> <brief_description> Boolean built-in type. </brief_description> <description> - Boolean built-in type. + Boolean is a built-in type. It can represent any data type that is either a true or false value. You can think of it as an switch with on or off (1 or 0) setting. It's often used as part of programming logic in condition statements like [code]if[/code] statements. + [b]Note:[/b] In a code below [code]if can_shoot[/code] is equivalent of [code]if can_shoot == true[/code]. It is good practice to follow the natural spoken language structure when possible. Use [code]if can_shoot[/code] rather than [code]if can_shoot == true[/code] and use [code]if not can_shoot[/code] rather than [code]if can_shoot == false[/code]. + [codeblock] + var can_shoot = true + + func shoot(): + if can_shoot: + # Perform shooting actions here. + [/codeblock] + The following code will only create a bullet if both conditions are met: action "shoot" is pressed and if [code]can_shoot[/code] is [code]true[/code]. + [b]Note:[/b] [code]Input.is_action_pressed("shoot")[/code] is also a boolean that is [code]true[/code] when "shoot" is pressed and [code]false[/code] when "shoot" isn't pressed. + [codeblock] + var can_shoot = true + + func shoot(): + if can_shoot and Input.is_action_pressed("shoot"): + create_bullet() + [/codeblock] + The following code will set [code]can_shoot[/code] to [code]false[/code] and start a timer. This will prevent player from shooting until the timer runs out. Next [code]can_shoot[/code] will be set to [code]true[/code] again allowing player to shoot once again. + [codeblock] + var can_shoot = true + onready var cool_down = $CoolDownTimer + + func shoot(): + if can_shoot and Input.is_action_pressed("shoot"): + create_bullet() + can_shoot = false + cool_down.start() + + func _on_CoolDownTimer_timeout(): + can_shoot = true + [/codeblock] </description> <tutorials> </tutorials> diff --git a/doc/classes/float.xml b/doc/classes/float.xml index 1571bae847..16a696f959 100644 --- a/doc/classes/float.xml +++ b/doc/classes/float.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="float" category="Built-In Types" version="3.2"> +<class name="float" version="4.0"> <brief_description> Float built-in type. </brief_description> diff --git a/doc/classes/int.xml b/doc/classes/int.xml index dad0f0d8c0..2c9f0ad371 100644 --- a/doc/classes/int.xml +++ b/doc/classes/int.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="int" category="Built-In Types" version="3.2"> +<class name="int" version="4.0"> <brief_description> Integer built-in type. </brief_description> @@ -8,16 +8,16 @@ It can take values in the interval [code][-2^63, 2^63 - 1][/code], i.e. [code][-9223372036854775808, 9223372036854775807][/code]. Exceeding those bounds will wrap around. [int] is a [Variant] type, and will thus be used when assigning an integer value to a [Variant]. It can also be enforced with the [code]: int[/code] type hint. [codeblock] - var my_variant = 0 # int, value 0 - my_variant += 4.2 # float, value 4.2 - var my_int: int = 1 # int, value 1 - my_int = 4.2 # int, value 4, the right value is implicitly cast to int - my_int = int("6.7") # int, value 6, the String is explicitly cast with [method int] + var my_variant = 0 # int, value 0. + my_variant += 4.2 # float, value 4.2. + var my_int: int = 1 # int, value 1. + my_int = 4.2 # int, value 4, the right value is implicitly cast to int. + my_int = int("6.7") # int, value 6, the String is explicitly cast with int. var max_int = 9223372036854775807 - print(max_int) # 9223372036854775807, OK + print(max_int) # 9223372036854775807, OK. max_int += 1 - print(max_int) # -9223372036854775808, we overflowed and wrapped around + print(max_int) # -9223372036854775808, we overflowed and wrapped around. [/codeblock] </description> <tutorials> diff --git a/doc/tools/doc_status.py b/doc/tools/doc_status.py index 6e34cffc05..e6e6d5f606 100755 --- a/doc/tools/doc_status.py +++ b/doc/tools/doc_status.py @@ -69,8 +69,8 @@ long_flags = { 'empty': 'e', } -table_columns = ['name', 'brief_description', 'description', 'methods', 'constants', 'members', 'signals'] -table_column_names = ['Name', 'Brief Desc.', 'Desc.', 'Methods', 'Constants', 'Members', 'Signals'] +table_columns = ['name', 'brief_description', 'description', 'methods', 'constants', 'members', 'signals', 'theme_items'] +table_column_names = ['Name', 'Brief Desc.', 'Desc.', 'Methods', 'Constants', 'Members', 'Signals', 'Theme Items'] colors = { 'name': [36], # cyan 'part_big_problem': [4, 31], # underline, red @@ -81,6 +81,7 @@ colors = { 'section': [1, 4], # bold, underline 'state_off': [36], # cyan 'state_on': [1, 35], # bold, magenta/plum + 'bold': [1], # bold } overall_progress_description_weigth = 10 @@ -176,6 +177,7 @@ class ClassStatus: 'methods': ClassStatusProgress(), 'constants': ClassStatusProgress(), 'members': ClassStatusProgress(), + 'theme_items': ClassStatusProgress(), 'signals': ClassStatusProgress() } @@ -220,13 +222,13 @@ class ClassStatus: ) items_progress = ClassStatusProgress() - for k in ['methods', 'constants', 'members', 'signals']: + for k in ['methods', 'constants', 'members', 'signals', 'theme_items']: items_progress += self.progresses[k] output[k] = self.progresses[k].to_configured_colored_string() output['items'] = items_progress.to_configured_colored_string() - output['overall'] = (description_progress + items_progress).to_colored_string('{percent}%', '{pad_percent}{s}') + output['overall'] = (description_progress + items_progress).to_colored_string(color('bold', '{percent}%'), '{pad_percent}{s}') if self.name.startswith('Total'): output['url'] = color('url', 'https://docs.godotengine.org/en/latest/classes/') @@ -257,7 +259,7 @@ class ClassStatus: for sub_tag in list(tag): descr = sub_tag.find('description') status.progresses[tag.tag].increment(len(descr.text.strip()) > 0) - elif tag.tag in ['constants', 'members']: + elif tag.tag in ['constants', 'members', 'theme_items']: for sub_tag in list(tag): if not sub_tag.text is None: status.progresses[tag.tag].increment(len(sub_tag.text.strip()) > 0) @@ -300,7 +302,7 @@ for arg in sys.argv[1:]: sys.exit(1) if flags['i']: - for r in ['methods', 'constants', 'members', 'signals']: + for r in ['methods', 'constants', 'members', 'signals', 'theme_items']: index = table_columns.index(r) del table_column_names[index] del table_columns[index] @@ -308,7 +310,7 @@ if flags['i']: table_columns.append('items') if flags['o'] == (not flags['i']): - table_column_names.append('Overall') + table_column_names.append(color('bold', 'Overall')) table_columns.append('overall') if flags['u']: @@ -434,6 +436,11 @@ if len(table) > 2 or not flags['a']: row.append('') table.append(row) +if flags['a']: + # Duplicate the headers at the bottom of the table so they can be viewed + # without having to scroll back to the top. + table.append(table_column_names) + table_column_sizes = [] for row in table: for cell_i, cell in enumerate(row): @@ -459,7 +466,10 @@ for row_i, row in enumerate(table): print(row_string) - if row_i == 0 or row_i == len(table) - 2: + # Account for the possible double header (if the `a` flag is enabled). + # No need to have a condition for the flag, as this will behave correctly + # if the flag is disabled. + if row_i == 0 or row_i == len(table) - 3 or row_i == len(table) - 2: print(divider_string) print(divider_string) diff --git a/doc/tools/makerst.py b/doc/tools/makerst.py index 91240e9550..9012de03b3 100755 --- a/doc/tools/makerst.py +++ b/doc/tools/makerst.py @@ -98,7 +98,6 @@ class ClassDef: self.methods = OrderedDict() # type: OrderedDict[str, List[MethodDef]] self.signals = OrderedDict() # type: OrderedDict[str, SignalDef] self.inherits = None # type: Optional[str] - self.category = None # type: Optional[str] self.brief_description = None # type: Optional[str] self.description = None # type: Optional[str] self.theme_items = None # type: Optional[OrderedDict[str, List[ThemeItemDef]]] @@ -122,10 +121,6 @@ class State: if inherits is not None: class_def.inherits = inherits - category = class_root.get("category") - if category is not None: - class_def.category = category - brief_desc = class_root.find("brief_description") if brief_desc is not None and brief_desc.text: class_def.brief_description = brief_desc.text @@ -149,7 +144,7 @@ class State: getter = property.get("getter") or None default_value = property.get("default") or None if default_value is not None: - default_value = escape_rst(default_value) + default_value = '``{}``'.format(default_value) overridden = property.get("override") or False property_def = PropertyDef(property_name, type_name, setter, getter, property.text, default_value, overridden) @@ -393,15 +388,22 @@ def make_rst_class(class_def, state, dry_run, output_dir): # type: (ClassDef, S f.write(make_type(child, state)) f.write("\n\n") - # Category - if class_def.category is not None: - f.write('**Category:** ' + class_def.category.strip() + "\n\n") - # Brief description - f.write(make_heading('Brief Description', '-')) if class_def.brief_description is not None: f.write(rstize_text(class_def.brief_description.strip(), state) + "\n\n") + # Class description + if class_def.description is not None and class_def.description.strip() != '': + f.write(make_heading('Description', '-')) + f.write(rstize_text(class_def.description.strip(), state) + "\n\n") + + # Online tutorials + if len(class_def.tutorials) > 0: + f.write(make_heading('Tutorials', '-')) + for t in class_def.tutorials: + link = t.strip() + f.write("- " + make_url(link) + "\n\n") + # Properties overview if len(class_def.properties) > 0: f.write(make_heading('Properties', '-')) @@ -494,18 +496,6 @@ def make_rst_class(class_def, state, dry_run, output_dir): # type: (ClassDef, S f.write('\n\n') - # Class description - if class_def.description is not None and class_def.description.strip() != '': - f.write(make_heading('Description', '-')) - f.write(rstize_text(class_def.description.strip(), state) + "\n\n") - - # Online tutorials - if len(class_def.tutorials) > 0: - f.write(make_heading('Tutorials', '-')) - for t in class_def.tutorials: - link = t.strip() - f.write("- " + make_url(link) + "\n\n") - # Property descriptions if any(not p.overridden for p in class_def.properties.values()) > 0: f.write(make_heading('Property Descriptions', '-')) @@ -886,6 +876,7 @@ def rstize_text(text, state): # type: (str, State) -> str inside_code = True elif cmd.startswith('enum '): tag_text = make_enum(cmd[5:], state) + escape_post = True else: tag_text = make_type(tag_text, state) escape_post = True diff --git a/drivers/alsa/audio_driver_alsa.cpp b/drivers/alsa/audio_driver_alsa.cpp index 425f12ae91..fe6cd091b7 100644 --- a/drivers/alsa/audio_driver_alsa.cpp +++ b/drivers/alsa/audio_driver_alsa.cpp @@ -204,7 +204,7 @@ void AudioDriverALSA::thread_func(void *p_udata) { } else { wrote = snd_pcm_recover(ad->pcm_handle, wrote, 0); if (wrote < 0) { - ERR_PRINTS("ALSA: Failed and can't recover: " + String(snd_strerror(wrote))); + ERR_PRINT("ALSA: Failed and can't recover: " + String(snd_strerror(wrote))); ad->active = false; ad->exit_thread = true; } diff --git a/drivers/alsamidi/midi_driver_alsamidi.cpp b/drivers/alsamidi/midi_driver_alsamidi.cpp index ff9d866aee..6121a44b36 100644 --- a/drivers/alsamidi/midi_driver_alsamidi.cpp +++ b/drivers/alsamidi/midi_driver_alsamidi.cpp @@ -43,12 +43,30 @@ static int get_message_size(uint8_t message) { case 0x90: // note on case 0xA0: // aftertouch case 0xB0: // continuous controller + case 0xE0: // pitch bend + case 0xF2: // song position pointer return 3; case 0xC0: // patch change case 0xD0: // channel pressure - case 0xE0: // pitch bend + case 0xF1: // time code quarter frame + case 0xF3: // song select return 2; + + case 0xF0: // SysEx start + case 0xF4: // reserved + case 0xF5: // reserved + case 0xF6: // tune request + case 0xF7: // SysEx end + case 0xF8: // timing clock + case 0xF9: // reserved + case 0xFA: // start + case 0xFB: // continue + case 0xFC: // stop + case 0xFD: // reserved + case 0xFE: // active sensing + case 0xFF: // reset + return 1; } return 256; @@ -73,7 +91,7 @@ void MIDIDriverALSAMidi::thread_func(void *p_udata) { ret = snd_rawmidi_read(midi_in, &byte, 1); if (ret < 0) { if (ret != -EAGAIN) { - ERR_PRINTS("snd_rawmidi_read error: " + String(snd_strerror(ret))); + ERR_PRINT("snd_rawmidi_read error: " + String(snd_strerror(ret))); } } else { if (byte & 0x80) { @@ -83,6 +101,9 @@ void MIDIDriverALSAMidi::thread_func(void *p_udata) { bytes = 0; } expected_size = get_message_size(byte); + // After a SysEx start, all bytes are data until a SysEx end, so + // we're going to end the command at the SES, and let the common + // driver ignore the following data bytes. } if (bytes < 256) { @@ -128,6 +149,7 @@ Error MIDIDriverALSAMidi::open() { snd_device_name_free_hint(hints); mutex = Mutex::create(); + exit_thread = false; thread = Thread::create(MIDIDriverALSAMidi::thread_func, this); return OK; diff --git a/drivers/coreaudio/audio_driver_coreaudio.cpp b/drivers/coreaudio/audio_driver_coreaudio.cpp index 1e97100a32..d8229f7bf2 100644 --- a/drivers/coreaudio/audio_driver_coreaudio.cpp +++ b/drivers/coreaudio/audio_driver_coreaudio.cpp @@ -233,15 +233,15 @@ OSStatus AudioDriverCoreAudio::input_callback(void *inRefCon, if (result == noErr) { for (unsigned int i = 0; i < inNumberFrames * ad->capture_channels; i++) { int32_t sample = ad->input_buf[i] << 16; - ad->capture_buffer_write(sample); + ad->input_buffer_write(sample); if (ad->capture_channels == 1) { - // In case capture device is single channel convert it to Stereo - ad->capture_buffer_write(sample); + // In case input device is single channel convert it to Stereo + ad->input_buffer_write(sample); } } } else { - ERR_PRINTS("AudioUnitRender failed, code: " + itos(result)); + ERR_PRINT("AudioUnitRender failed, code: " + itos(result)); } ad->unlock(); @@ -253,7 +253,7 @@ void AudioDriverCoreAudio::start() { if (!active) { OSStatus result = AudioOutputUnitStart(audio_unit); if (result != noErr) { - ERR_PRINTS("AudioOutputUnitStart failed, code: " + itos(result)); + ERR_PRINT("AudioOutputUnitStart failed, code: " + itos(result)); } else { active = true; } @@ -264,7 +264,7 @@ void AudioDriverCoreAudio::stop() { if (active) { OSStatus result = AudioOutputUnitStop(audio_unit); if (result != noErr) { - ERR_PRINTS("AudioOutputUnitStop failed, code: " + itos(result)); + ERR_PRINT("AudioOutputUnitStop failed, code: " + itos(result)); } else { active = false; } @@ -487,11 +487,11 @@ void AudioDriverCoreAudio::capture_finish() { Error AudioDriverCoreAudio::capture_start() { - capture_buffer_init(buffer_frames); + input_buffer_init(buffer_frames); OSStatus result = AudioOutputUnitStart(input_unit); if (result != noErr) { - ERR_PRINTS("AudioOutputUnitStart failed, code: " + itos(result)); + ERR_PRINT("AudioOutputUnitStart failed, code: " + itos(result)); } return OK; @@ -502,7 +502,7 @@ Error AudioDriverCoreAudio::capture_stop() { if (input_unit) { OSStatus result = AudioOutputUnitStop(input_unit); if (result != noErr) { - ERR_PRINTS("AudioOutputUnitStop failed, code: " + itos(result)); + ERR_PRINT("AudioOutputUnitStop failed, code: " + itos(result)); } } @@ -642,9 +642,9 @@ void AudioDriverCoreAudio::_set_device(const String &device, bool capture) { ERR_FAIL_COND(result != noErr); if (capture) { - // Reset audio capture to keep synchronisation. - capture_position = 0; - capture_size = 0; + // Reset audio input to keep synchronisation. + input_position = 0; + input_size = 0; } } } diff --git a/drivers/coremidi/midi_driver_coremidi.cpp b/drivers/coremidi/midi_driver_coremidi.cpp index 06082a9140..99628c7fe3 100644 --- a/drivers/coremidi/midi_driver_coremidi.cpp +++ b/drivers/coremidi/midi_driver_coremidi.cpp @@ -51,13 +51,13 @@ Error MIDIDriverCoreMidi::open() { OSStatus result = MIDIClientCreate(name, NULL, NULL, &client); CFRelease(name); if (result != noErr) { - ERR_PRINTS("MIDIClientCreate failed, code: " + itos(result)); + ERR_PRINT("MIDIClientCreate failed, code: " + itos(result)); return ERR_CANT_OPEN; } result = MIDIInputPortCreate(client, CFSTR("Godot Input"), MIDIDriverCoreMidi::read, (void *)this, &port_in); if (result != noErr) { - ERR_PRINTS("MIDIInputPortCreate failed, code: " + itos(result)); + ERR_PRINT("MIDIInputPortCreate failed, code: " + itos(result)); return ERR_CANT_OPEN; } diff --git a/drivers/gles2/rasterizer_gles2.cpp b/drivers/gles2/rasterizer_gles2.cpp index c4e9541a36..140617246c 100644 --- a/drivers/gles2/rasterizer_gles2.cpp +++ b/drivers/gles2/rasterizer_gles2.cpp @@ -130,7 +130,7 @@ static void GLAPIENTRY _gl_debug_print(GLenum source, GLenum type, GLuint id, GL String output = String() + "GL ERROR: Source: " + debSource + "\tType: " + debType + "\tID: " + itos(id) + "\tSeverity: " + debSev + "\tMessage: " + message; - ERR_PRINTS(output); + ERR_PRINT(output); } #endif // CAN_DEBUG diff --git a/drivers/gles2/rasterizer_scene_gles2.cpp b/drivers/gles2/rasterizer_scene_gles2.cpp index 5c52d88cc7..c0ba93db6a 100644 --- a/drivers/gles2/rasterizer_scene_gles2.cpp +++ b/drivers/gles2/rasterizer_scene_gles2.cpp @@ -557,15 +557,16 @@ bool RasterizerSceneGLES2::reflection_probe_instance_begin_render(RID p_instance glGenTextures(1, &rpi->cubemap); glBindTexture(GL_TEXTURE_CUBE_MAP, rpi->cubemap); -#if 1 - //Mobile hardware (PowerVR specially) prefers this approach, the other one kills the game + + // Mobile hardware (PowerVR specially) prefers this approach, + // the previous approach with manual lod levels kills the game. for (int i = 0; i < 6; i++) { glTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, internal_format, size, size, 0, format, type, NULL); } glGenerateMipmap(GL_TEXTURE_CUBE_MAP); - //Generate framebuffers for rendering + // Generate framebuffers for rendering for (int i = 0; i < 6; i++) { glBindFramebuffer(GL_FRAMEBUFFER, rpi->fbo[i]); glBindTexture(GL_TEXTURE_2D, rpi->color[i]); @@ -576,34 +577,6 @@ bool RasterizerSceneGLES2::reflection_probe_instance_begin_render(RID p_instance ERR_CONTINUE(status != GL_FRAMEBUFFER_COMPLETE); } -#else - int lod = 0; - - //the approach below is fatal for powervr - - // Set the initial (empty) mipmaps, all need to be set for this to work in GLES2, even if they won't be used later. - while (size >= 1) { - - for (int i = 0; i < 6; i++) { - glTexImage2D(_cube_side_enum[i], lod, internal_format, size, size, 0, format, type, NULL); - if (size == rpi->current_resolution) { - //adjust framebuffer - glBindFramebuffer(GL_FRAMEBUFFER, rpi->fbo[i]); - glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, _cube_side_enum[i], rpi->cubemap, 0); - glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_RENDERBUFFER, rpi->depth); - -#ifdef DEBUG_ENABLED - GLenum status = glCheckFramebufferStatus(GL_FRAMEBUFFER); - ERR_CONTINUE(status != GL_FRAMEBUFFER_COMPLETE); -#endif - } - } - - lod++; - - size >>= 1; - } -#endif glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR); glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAG_FILTER, GL_LINEAR); glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); @@ -1169,7 +1142,7 @@ void RasterizerSceneGLES2::_add_geometry_with_material(RasterizerStorageGLES2::G LightInstance *li = light_instance_owner.getornull(e->instance->light_instances[i]); - if (li->light_index >= render_light_instance_count || render_light_instances[li->light_index] != li) { + if (!li || li->light_index >= render_light_instance_count || render_light_instances[li->light_index] != li) { continue; // too many or light_index did not correspond to the light instances to be rendered } @@ -2685,14 +2658,14 @@ void RasterizerSceneGLES2::_draw_sky(RasterizerStorageGLES2::Sky *p_sky, const C }; if (!asymmetrical) { - float vw, vh, zn; - camera.get_viewport_size(vw, vh); + Vector2 vp_he = camera.get_viewport_half_extents(); + float zn; zn = p_projection.get_z_near(); for (int i = 0; i < 4; i++) { Vector3 uv = vertices[i * 2 + 1]; - uv.x = (uv.x * 2.0 - 1.0) * vw; - uv.y = -(uv.y * 2.0 - 1.0) * vh; + uv.x = (uv.x * 2.0 - 1.0) * vp_he.x; + uv.y = -(uv.y * 2.0 - 1.0) * vp_he.y; uv.z = -zn; vertices[i * 2 + 1] = p_transform.basis.xform(uv).normalized(); vertices[i * 2 + 1].z = -vertices[i * 2 + 1].z; @@ -3325,6 +3298,7 @@ void RasterizerSceneGLES2::render_scene(const Transform &p_cam_transform, const glDepthMask(GL_TRUE); glClearDepth(1.0f); glEnable(GL_DEPTH_TEST); + glClear(GL_DEPTH_BUFFER_BIT); // clear color @@ -3351,13 +3325,12 @@ void RasterizerSceneGLES2::render_scene(const Transform &p_cam_transform, const if (!env || env->bg_mode != VS::ENV_BG_KEEP) { glClearColor(clear_color.r, clear_color.g, clear_color.b, clear_color.a); + glClear(GL_COLOR_BUFFER_BIT); } state.default_ambient = Color(clear_color.r, clear_color.g, clear_color.b, 1.0); state.default_bg = Color(clear_color.r, clear_color.g, clear_color.b, 1.0); - glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); - if (storage->frame.current_rt && storage->frame.current_rt->flags[RasterizerStorage::RENDER_TARGET_DIRECT_TO_SCREEN]) { glDisable(GL_SCISSOR_TEST); } diff --git a/drivers/gles2/rasterizer_storage_gles2.cpp b/drivers/gles2/rasterizer_storage_gles2.cpp index b0b14ed413..828f6907e3 100644 --- a/drivers/gles2/rasterizer_storage_gles2.cpp +++ b/drivers/gles2/rasterizer_storage_gles2.cpp @@ -109,6 +109,7 @@ PFNGLFRAMEBUFFERTEXTURE2DMULTISAMPLEEXTPROC glFramebufferTexture2DMultisampleEXT #define glFramebufferTexture2DMultisample glFramebufferTexture2DMultisampleANGLE #endif +#define GL_TEXTURE_3D 0x806F #define GL_MAX_SAMPLES 0x8D57 #endif //!GLES_OVER_GL @@ -565,11 +566,11 @@ void RasterizerStorageGLES2::texture_allocate(RID p_texture, int p_width, int p_ texture->target = GL_TEXTURE_CUBE_MAP; texture->images.resize(6); } break; - case VS::TEXTURE_TYPE_2D_ARRAY: { - texture->images.resize(p_depth_3d); - } break; + case VS::TEXTURE_TYPE_2D_ARRAY: case VS::TEXTURE_TYPE_3D: { - texture->images.resize(p_depth_3d); + texture->target = GL_TEXTURE_3D; + ERR_PRINT("3D textures and Texture Arrays are not supported in GLES2. Please switch to the GLES3 backend."); + return; } break; default: { ERR_PRINT("Unknown texture type!"); @@ -590,7 +591,7 @@ void RasterizerStorageGLES2::texture_allocate(RID p_texture, int p_width, int p_ if (p_flags & VS::TEXTURE_FLAG_USED_FOR_STREAMING) { //not supported - ERR_PRINTS("Streaming texture for non power of 2 or has mipmaps on this hardware: " + texture->path + "'. Mipmaps and repeat disabled."); + ERR_PRINT("Streaming texture for non power of 2 or has mipmaps on this hardware: " + texture->path + "'. Mipmaps and repeat disabled."); texture->flags &= ~(VS::TEXTURE_FLAG_REPEAT | VS::TEXTURE_FLAG_MIPMAPS); } else { texture->alloc_height = po2_height; @@ -626,6 +627,10 @@ void RasterizerStorageGLES2::texture_set_data(RID p_texture, const Ref<Image> &p Texture *texture = texture_owner.getornull(p_texture); ERR_FAIL_COND(!texture); + if (texture->target == GL_TEXTURE_3D) { + // Target is set to a 3D texture or array texture, exit early to avoid spamming errors + return; + } ERR_FAIL_COND(!texture->active); ERR_FAIL_COND(texture->render_target); ERR_FAIL_COND(texture->format != p_image->get_format()); @@ -645,7 +650,7 @@ void RasterizerStorageGLES2::texture_set_data(RID p_texture, const Ref<Image> &p if (texture->resize_to_po2) { if (p_image->is_compressed()) { - ERR_PRINTS("Texture '" + texture->path + "' is required to be a power of 2 because it uses either mipmaps or repeat, so it was decompressed. This will hurt performance and memory usage."); + ERR_PRINT("Texture '" + texture->path + "' is required to be a power of 2 because it uses either mipmaps or repeat, so it was decompressed. This will hurt performance and memory usage."); } if (img == p_image) { @@ -1201,32 +1206,21 @@ void RasterizerStorageGLES2::sky_set_texture(RID p_sky, RID p_panorama, int p_ra GLenum type = GL_UNSIGNED_BYTE; // Set the initial (empty) mipmaps -#if 1 - //Mobile hardware (PowerVR specially) prefers this approach, the other one kills the game + // Mobile hardware (PowerVR specially) prefers this approach, + // the previous approach with manual lod levels kills the game. for (int i = 0; i < 6; i++) { glTexImage2D(GL_TEXTURE_CUBE_MAP_POSITIVE_X + i, 0, internal_format, size, size, 0, format, type, NULL); } glGenerateMipmap(GL_TEXTURE_CUBE_MAP); - //no filters for now + + // No filters for now glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MIN_FILTER, GL_LINEAR); glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_MAG_FILTER, GL_LINEAR); glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); glTexParameterf(GL_TEXTURE_CUBE_MAP, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); -#else - while (size >= 1) { - - for (int i = 0; i < 6; i++) { - glTexImage2D(_cube_side_enum[i], lod, internal_format, size, size, 0, format, type, NULL); - } - - lod++; - - size >>= 1; - } -#endif - //framebuffer + // Framebuffer glBindFramebuffer(GL_FRAMEBUFFER, resources.mipmap_blur_fbo); @@ -2698,6 +2692,7 @@ void RasterizerStorageGLES2::mesh_set_custom_aabb(RID p_mesh, const AABB &p_aabb ERR_FAIL_COND(!mesh); mesh->custom_aabb = p_aabb; + mesh->instance_change_notify(true, false); } AABB RasterizerStorageGLES2::mesh_get_custom_aabb(RID p_mesh) const { @@ -3051,7 +3046,7 @@ void RasterizerStorageGLES2::multimesh_instance_set_color(RID p_multimesh, int p ERR_FAIL_COND(!multimesh); ERR_FAIL_INDEX(p_index, multimesh->size); ERR_FAIL_COND(multimesh->color_format == VS::MULTIMESH_COLOR_NONE); - ERR_FAIL_INDEX(multimesh->color_format, VS::MULTIMESH_COLOR_FLOAT); + ERR_FAIL_INDEX(multimesh->color_format, VS::MULTIMESH_COLOR_MAX); int stride = multimesh->color_floats + multimesh->xform_floats + multimesh->custom_data_floats; float *dataptr = &multimesh->data.write[stride * p_index + multimesh->xform_floats]; @@ -3084,7 +3079,7 @@ void RasterizerStorageGLES2::multimesh_instance_set_custom_data(RID p_multimesh, ERR_FAIL_COND(!multimesh); ERR_FAIL_INDEX(p_index, multimesh->size); ERR_FAIL_COND(multimesh->custom_data_format == VS::MULTIMESH_CUSTOM_DATA_NONE); - ERR_FAIL_INDEX(multimesh->custom_data_format, VS::MULTIMESH_CUSTOM_DATA_FLOAT); + ERR_FAIL_INDEX(multimesh->custom_data_format, VS::MULTIMESH_CUSTOM_DATA_MAX); int stride = multimesh->color_floats + multimesh->xform_floats + multimesh->custom_data_floats; float *dataptr = &multimesh->data.write[stride * p_index + multimesh->xform_floats + multimesh->color_floats]; @@ -3172,7 +3167,7 @@ Color RasterizerStorageGLES2::multimesh_instance_get_color(RID p_multimesh, int ERR_FAIL_COND_V(!multimesh, Color()); ERR_FAIL_INDEX_V(p_index, multimesh->size, Color()); ERR_FAIL_COND_V(multimesh->color_format == VS::MULTIMESH_COLOR_NONE, Color()); - ERR_FAIL_INDEX_V(multimesh->color_format, VS::MULTIMESH_COLOR_FLOAT, Color()); + ERR_FAIL_INDEX_V(multimesh->color_format, VS::MULTIMESH_COLOR_MAX, Color()); int stride = multimesh->color_floats + multimesh->xform_floats + multimesh->custom_data_floats; float *dataptr = &multimesh->data.write[stride * p_index + multimesh->xform_floats]; @@ -3205,7 +3200,7 @@ Color RasterizerStorageGLES2::multimesh_instance_get_custom_data(RID p_multimesh ERR_FAIL_COND_V(!multimesh, Color()); ERR_FAIL_INDEX_V(p_index, multimesh->size, Color()); ERR_FAIL_COND_V(multimesh->custom_data_format == VS::MULTIMESH_CUSTOM_DATA_NONE, Color()); - ERR_FAIL_INDEX_V(multimesh->custom_data_format, VS::MULTIMESH_CUSTOM_DATA_FLOAT, Color()); + ERR_FAIL_INDEX_V(multimesh->custom_data_format, VS::MULTIMESH_CUSTOM_DATA_MAX, Color()); int stride = multimesh->color_floats + multimesh->xform_floats + multimesh->custom_data_floats; float *dataptr = &multimesh->data.write[stride * p_index + multimesh->xform_floats + multimesh->color_floats]; @@ -4714,7 +4709,7 @@ void RasterizerStorageGLES2::_render_target_allocate(RenderTarget *rt) { int max_samples = 0; glGetIntegerv(GL_MAX_SAMPLES, &max_samples); if (msaa > max_samples) { - WARN_PRINTS("MSAA must be <= GL_MAX_SAMPLES, falling-back to GL_MAX_SAMPLES = " + itos(max_samples)); + WARN_PRINT("MSAA must be <= GL_MAX_SAMPLES, falling-back to GL_MAX_SAMPLES = " + itos(max_samples)); msaa = max_samples; } diff --git a/drivers/gles2/shader_compiler_gles2.cpp b/drivers/gles2/shader_compiler_gles2.cpp index fc59486090..5dec6f2fee 100644 --- a/drivers/gles2/shader_compiler_gles2.cpp +++ b/drivers/gles2/shader_compiler_gles2.cpp @@ -80,7 +80,7 @@ static String _opstr(SL::Operator p_op) { static String _mkid(const String &p_id) { - String id = "m_" + p_id; + String id = "m_" + p_id.replace("__", "_dus_"); return id.replace("__", "_dus_"); //doubleunderscore is reserved in glsl } @@ -522,9 +522,6 @@ String ShaderCompilerGLES2::_dump_node_code(SL::Node *p_node, int p_level, Gener SL::ArrayDeclarationNode *arr_dec_node = (SL::ArrayDeclarationNode *)p_node; StringBuffer<> declaration; - if (arr_dec_node->is_const) { - declaration += "const "; - } declaration += _prestr(arr_dec_node->precision); declaration += _typestr(arr_dec_node->datatype); @@ -540,22 +537,6 @@ String ShaderCompilerGLES2::_dump_node_code(SL::Node *p_node, int p_level, Gener declaration += "["; declaration += itos(arr_dec_node->declarations[i].size); declaration += "]"; - int sz = arr_dec_node->declarations[i].initializer.size(); - if (sz > 0) { - declaration += "="; - declaration += _typestr(arr_dec_node->datatype); - declaration += "["; - declaration += itos(sz); - declaration += "]"; - declaration += "("; - for (int j = 0; j < sz; j++) { - declaration += _dump_node_code(arr_dec_node->declarations[i].initializer[j], p_level, r_gen_code, p_actions, p_default_actions, p_assigning); - if (j != sz - 1) { - declaration += ", "; - } - } - declaration += ")"; - } } code += declaration.as_string(); diff --git a/drivers/gles2/shader_gles2.cpp b/drivers/gles2/shader_gles2.cpp index 8bb1ef7f0f..f03f1ffa4f 100644 --- a/drivers/gles2/shader_gles2.cpp +++ b/drivers/gles2/shader_gles2.cpp @@ -126,7 +126,7 @@ static void _display_error_with_code(const String &p_error, const Vector<const c line++; } - ERR_PRINTS(p_error); + ERR_PRINT(p_error); } static String _mkid(const String &p_id) { diff --git a/drivers/gles2/shaders/scene.glsl b/drivers/gles2/shaders/scene.glsl index 63eee4eb87..ac7a8796a3 100644 --- a/drivers/gles2/shaders/scene.glsl +++ b/drivers/gles2/shaders/scene.glsl @@ -1666,19 +1666,19 @@ FRAGMENT_SHADER_CODE #ifdef USE_LIGHTMAP_CAPTURE { - vec3 cone_dirs[12] = vec3[]( - vec3(0.0, 0.0, 1.0), - vec3(0.866025, 0.0, 0.5), - vec3(0.267617, 0.823639, 0.5), - vec3(-0.700629, 0.509037, 0.5), - vec3(-0.700629, -0.509037, 0.5), - vec3(0.267617, -0.823639, 0.5), - vec3(0.0, 0.0, -1.0), - vec3(0.866025, 0.0, -0.5), - vec3(0.267617, 0.823639, -0.5), - vec3(-0.700629, 0.509037, -0.5), - vec3(-0.700629, -0.509037, -0.5), - vec3(0.267617, -0.823639, -0.5)); + vec3 cone_dirs[12]; + cone_dirs[0] = vec3(0.0, 0.0, 1.0); + cone_dirs[1] = vec3(0.866025, 0.0, 0.5); + cone_dirs[2] = vec3(0.267617, 0.823639, 0.5); + cone_dirs[3] = vec3(-0.700629, 0.509037, 0.5); + cone_dirs[4] = vec3(-0.700629, -0.509037, 0.5); + cone_dirs[5] = vec3(0.267617, -0.823639, 0.5); + cone_dirs[6] = vec3(0.0, 0.0, -1.0); + cone_dirs[7] = vec3(0.866025, 0.0, -0.5); + cone_dirs[8] = vec3(0.267617, 0.823639, -0.5); + cone_dirs[9] = vec3(-0.700629, 0.509037, -0.5); + cone_dirs[10] = vec3(-0.700629, -0.509037, -0.5); + cone_dirs[11] = vec3(0.267617, -0.823639, -0.5); vec3 local_normal = normalize(camera_matrix * vec4(normal, 0.0)).xyz; vec4 captured = vec4(0.0); diff --git a/drivers/gles3/rasterizer_canvas_gles3.cpp b/drivers/gles3/rasterizer_canvas_gles3.cpp index df11da44f7..b7b31c66aa 100644 --- a/drivers/gles3/rasterizer_canvas_gles3.cpp +++ b/drivers/gles3/rasterizer_canvas_gles3.cpp @@ -1012,6 +1012,7 @@ void RasterizerCanvasGLES3::_canvas_item_render_commands(Item *p_item, Item *cur switch (multi_mesh->color_format) { + case VS::MULTIMESH_COLOR_MAX: case VS::MULTIMESH_COLOR_NONE: { glDisableVertexAttribArray(11); glVertexAttrib4f(11, 1, 1, 1, 1); @@ -1033,6 +1034,7 @@ void RasterizerCanvasGLES3::_canvas_item_render_commands(Item *p_item, Item *cur switch (multi_mesh->custom_data_format) { + case VS::MULTIMESH_CUSTOM_DATA_MAX: case VS::MULTIMESH_CUSTOM_DATA_NONE: { glDisableVertexAttribArray(12); glVertexAttrib4f(12, 1, 1, 1, 1); diff --git a/drivers/gles3/rasterizer_gles3.cpp b/drivers/gles3/rasterizer_gles3.cpp index ef2c318807..e06cc55423 100644 --- a/drivers/gles3/rasterizer_gles3.cpp +++ b/drivers/gles3/rasterizer_gles3.cpp @@ -120,7 +120,7 @@ static void GLAPIENTRY _gl_debug_print(GLenum source, GLenum type, GLuint id, GL String output = String() + "GL ERROR: Source: " + debSource + "\tType: " + debType + "\tID: " + itos(id) + "\tSeverity: " + debSev + "\tMessage: " + message; - ERR_PRINTS(output); + ERR_PRINT(output); } #endif // GLAD_ENABLED @@ -339,8 +339,6 @@ void RasterizerGLES3::blit_render_target_to_screen(RID p_render_target, const Re RasterizerStorageGLES3::RenderTarget *rt = storage->render_target_owner.getornull(p_render_target); ERR_FAIL_COND(!rt); -#if 1 - Size2 win_size = OS::get_singleton()->get_window_size(); if (rt->external.fbo != 0) { glBindFramebuffer(GL_READ_FRAMEBUFFER, rt->external.fbo); @@ -350,21 +348,6 @@ void RasterizerGLES3::blit_render_target_to_screen(RID p_render_target, const Re glReadBuffer(GL_COLOR_ATTACHMENT0); glBindFramebuffer(GL_DRAW_FRAMEBUFFER, RasterizerStorageGLES3::system_fbo); glBlitFramebuffer(0, 0, rt->width, rt->height, p_screen_rect.position.x, win_size.height - p_screen_rect.position.y - p_screen_rect.size.height, p_screen_rect.position.x + p_screen_rect.size.width, win_size.height - p_screen_rect.position.y, GL_COLOR_BUFFER_BIT, GL_NEAREST); - -#else - canvas->canvas_begin(); - glDisable(GL_BLEND); - glBindFramebuffer(GL_FRAMEBUFFER, RasterizerStorageGLES3::system_fbo); - glActiveTexture(GL_TEXTURE0); - glBindTexture(GL_TEXTURE_2D, rt->color); - //glBindTexture(GL_TEXTURE_2D, rt->effects.mip_maps[0].color); - glActiveTexture(GL_TEXTURE1); - glBindTexture(GL_TEXTURE_2D, storage->resources.normal_tex); - - canvas->draw_generic_textured_rect(p_screen_rect, Rect2(0, 0, 1, -1)); - glBindTexture(GL_TEXTURE_2D, 0); - canvas->canvas_end(); -#endif } void RasterizerGLES3::output_lens_distorted_to_screen(RID p_render_target, const Rect2 &p_screen_rect, float p_k1, float p_k2, const Vector2 &p_eye_center, float p_oversample) { diff --git a/drivers/gles3/rasterizer_scene_gles3.cpp b/drivers/gles3/rasterizer_scene_gles3.cpp index 1be0c46668..27173d317b 100644 --- a/drivers/gles3/rasterizer_scene_gles3.cpp +++ b/drivers/gles3/rasterizer_scene_gles3.cpp @@ -1146,47 +1146,6 @@ bool RasterizerSceneGLES3::_setup_material(RasterizerStorageGLES3::Material *p_m state.current_depth_draw = p_material->shader->spatial.depth_draw_mode; } -#if 0 - //blend mode - if (state.current_blend_mode!=p_material->shader->spatial.blend_mode) { - - switch(p_material->shader->spatial.blend_mode) { - - case RasterizerStorageGLES3::Shader::Spatial::BLEND_MODE_MIX: { - glBlendEquation(GL_FUNC_ADD); - if (storage->frame.current_rt->flags[RasterizerStorage::RENDER_TARGET_TRANSPARENT]) { - glBlendFuncSeparate(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA, GL_ONE, GL_ONE_MINUS_SRC_ALPHA); - } else { - glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); - } - - } break; - case RasterizerStorageGLES3::Shader::Spatial::BLEND_MODE_ADD: { - - glBlendEquation(GL_FUNC_ADD); - glBlendFunc(p_alpha_pass?GL_SRC_ALPHA:GL_ONE,GL_ONE); - - } break; - case RasterizerStorageGLES3::Shader::Spatial::BLEND_MODE_SUB: { - - glBlendEquation(GL_FUNC_REVERSE_SUBTRACT); - glBlendFunc(GL_SRC_ALPHA,GL_ONE); - } break; - case RasterizerStorageGLES3::Shader::Spatial::BLEND_MODE_MUL: { - glBlendEquation(GL_FUNC_ADD); - if (storage->frame.current_rt->flags[RasterizerStorage::RENDER_TARGET_TRANSPARENT]) { - glBlendFuncSeparate(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA, GL_ONE, GL_ONE_MINUS_SRC_ALPHA); - } else { - glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); - } - - } break; - } - - state.current_blend_mode=p_material->shader->spatial.blend_mode; - - } -#endif //material parameters state.scene_shader.set_custom_shader(p_material->shader->custom_code_id); @@ -1416,6 +1375,7 @@ void RasterizerSceneGLES3::_setup_geometry(RenderList::Element *e, const Transfo switch (multi_mesh->color_format) { + case VS::MULTIMESH_COLOR_MAX: case VS::MULTIMESH_COLOR_NONE: { glDisableVertexAttribArray(11); glVertexAttrib4f(11, 1, 1, 1, 1); @@ -1437,6 +1397,7 @@ void RasterizerSceneGLES3::_setup_geometry(RenderList::Element *e, const Transfo switch (multi_mesh->custom_data_format) { + case VS::MULTIMESH_CUSTOM_DATA_MAX: case VS::MULTIMESH_CUSTOM_DATA_NONE: { glDisableVertexAttribArray(12); glVertexAttrib4f(12, 1, 1, 1, 1); @@ -1887,8 +1848,8 @@ void RasterizerSceneGLES3::_setup_light(RenderList::Element *e, const Transform const RID *lights = e->instance->light_instances.ptr(); for (int i = 0; i < lc; i++) { - LightInstance *li = light_instance_owner.getptr(lights[i]); - if (li->last_pass != render_pass) //not visible + LightInstance *li = light_instance_owner.getornull(lights[i]); + if (!li || li->last_pass != render_pass) //not visible continue; if (li && li->light_ptr->type == VS::LIGHT_OMNI) { @@ -2536,14 +2497,14 @@ void RasterizerSceneGLES3::_draw_sky(RasterizerStorageGLES3::Sky *p_sky, const C }; if (!asymmetrical) { - float vw, vh, zn; - camera.get_viewport_size(vw, vh); + Vector2 vp_he = camera.get_viewport_half_extents(); + float zn; zn = p_projection.get_z_near(); for (int i = 0; i < 4; i++) { Vector3 uv = vertices[i * 2 + 1]; - uv.x = (uv.x * 2.0 - 1.0) * vw; - uv.y = -(uv.y * 2.0 - 1.0) * vh; + uv.x = (uv.x * 2.0 - 1.0) * vp_he.x; + uv.y = -(uv.y * 2.0 - 1.0) * vp_he.y; uv.z = -zn; vertices[i * 2 + 1] = p_transform.basis.xform(uv).normalized(); vertices[i * 2 + 1].z = -vertices[i * 2 + 1].z; @@ -3005,16 +2966,6 @@ void RasterizerSceneGLES3::_setup_lights(RID *p_light_cull_result, int p_light_c li->light_index = state.spot_light_count; copymem(&state.spot_array_tmp[li->light_index * state.ubo_light_size], &ubo_data, state.ubo_light_size); state.spot_light_count++; - -#if 0 - if (li->light_ptr->shadow_enabled) { - CameraMatrix bias; - bias.set_light_bias(); - Transform modelview=Transform(camera_transform_inverse * li->transform).inverse(); - li->shadow_projection[0] = bias * li->projection * modelview; - lights_use_shadow=true; - } -#endif } break; } @@ -4179,11 +4130,15 @@ void RasterizerSceneGLES3::render_scene(const Transform &p_cam_transform, const state.ubo_data.shadow_dual_paraboloid_render_zfar = 0; state.ubo_data.opaque_prepass_threshold = 0.99; - p_cam_projection.get_viewport_size(state.ubo_data.viewport_size[0], state.ubo_data.viewport_size[1]); - if (storage->frame.current_rt) { - state.ubo_data.screen_pixel_size[0] = 1.0 / storage->frame.current_rt->width; - state.ubo_data.screen_pixel_size[1] = 1.0 / storage->frame.current_rt->height; + int viewport_width_pixels = storage->frame.current_rt->width; + int viewport_height_pixels = storage->frame.current_rt->height; + + state.ubo_data.viewport_size[0] = viewport_width_pixels; + state.ubo_data.viewport_size[1] = viewport_height_pixels; + + state.ubo_data.screen_pixel_size[0] = 1.0 / viewport_width_pixels; + state.ubo_data.screen_pixel_size[1] = 1.0 / viewport_height_pixels; } _setup_environment(env, p_cam_projection, p_cam_transform, p_reflection_probe.is_valid()); diff --git a/drivers/gles3/rasterizer_storage_gles3.cpp b/drivers/gles3/rasterizer_storage_gles3.cpp index 335931efd1..e5a7fcce07 100644 --- a/drivers/gles3/rasterizer_storage_gles3.cpp +++ b/drivers/gles3/rasterizer_storage_gles3.cpp @@ -1834,7 +1834,7 @@ void RasterizerStorageGLES3::sky_set_texture(RID p_sky, RID p_panorama, int p_ra glGenFramebuffers(1, &tmp_fb); glBindFramebuffer(GL_FRAMEBUFFER, tmp_fb); - int size = 64; + int size = 32; bool use_float = config.framebuffer_half_float_supported; @@ -1854,6 +1854,27 @@ void RasterizerStorageGLES3::sky_set_texture(RID p_sky, RID p_panorama, int p_ra glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, sky->irradiance, 0); + int irradiance_size = GLOBAL_GET("rendering/quality/reflections/irradiance_max_size"); + int upscale_size = MIN(int(previous_power_of_2(irradiance_size)), p_radiance_size); + + GLuint tmp_fb2; + GLuint tmp_tex; + { + //generate another one for rendering, as can't read and write from a single texarray it seems + glGenFramebuffers(1, &tmp_fb2); + glBindFramebuffer(GL_FRAMEBUFFER, tmp_fb2); + glGenTextures(1, &tmp_tex); + glBindTexture(GL_TEXTURE_2D, tmp_tex); + glTexImage2D(GL_TEXTURE_2D, 0, internal_format, upscale_size, 2.0 * upscale_size, 0, format, type, NULL); + glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, tmp_tex, 0); + glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR); + glTexParameterf(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); +#ifdef DEBUG_ENABLED + GLenum status = glCheckFramebufferStatus(GL_FRAMEBUFFER); + ERR_FAIL_COND(status != GL_FRAMEBUFFER_COMPLETE); +#endif + } + shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES3::USE_DUAL_PARABOLOID, true); shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES3::USE_SOURCE_PANORAMA, true); shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES3::COMPUTE_IRRADIANCE, true); @@ -1863,8 +1884,9 @@ void RasterizerStorageGLES3::sky_set_texture(RID p_sky, RID p_panorama, int p_ra // level that corresponds to a panorama of 1024x512 shaders.cubemap_filter.set_uniform(CubemapFilterShaderGLES3::SOURCE_MIP_LEVEL, MAX(Math::floor(Math::log(float(texture->width)) / Math::log(2.0f)) - 10.0f, 0.0f)); + // Compute Irradiance for a large texture, specified by radiance size and then pull out a low mipmap corresponding to 32x32 for (int i = 0; i < 2; i++) { - glViewport(0, i * size, size, size); + glViewport(0, i * upscale_size, upscale_size, upscale_size); glBindVertexArray(resources.quadie_array); shaders.cubemap_filter.set_uniform(CubemapFilterShaderGLES3::Z_FLIP, i > 0); @@ -1872,13 +1894,32 @@ void RasterizerStorageGLES3::sky_set_texture(RID p_sky, RID p_panorama, int p_ra glDrawArrays(GL_TRIANGLE_FAN, 0, 4); glBindVertexArray(0); } + glGenerateMipmap(GL_TEXTURE_2D); + glActiveTexture(GL_TEXTURE0); + glBindTexture(GL_TEXTURE_2D, tmp_tex); + glBindFramebuffer(GL_FRAMEBUFFER, tmp_fb); shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES3::USE_DUAL_PARABOLOID, false); shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES3::USE_SOURCE_PANORAMA, false); shaders.cubemap_filter.set_conditional(CubemapFilterShaderGLES3::COMPUTE_IRRADIANCE, false); + shaders.copy.set_conditional(CopyShaderGLES3::USE_LOD, true); + shaders.copy.bind(); + shaders.copy.set_uniform(CopyShaderGLES3::MIP_LEVEL, MAX(Math::floor(Math::log(float(upscale_size)) / Math::log(2.0f)) - 5.0f, 0.0f)); // Mip level that corresponds to a 32x32 texture + + glViewport(0, 0, size, size * 2.0); + glBindVertexArray(resources.quadie_array); + glDrawArrays(GL_TRIANGLE_FAN, 0, 4); + glBindVertexArray(0); + + shaders.copy.set_conditional(CopyShaderGLES3::USE_LOD, false); + glBindFramebuffer(GL_FRAMEBUFFER, RasterizerStorageGLES3::system_fbo); + glActiveTexture(GL_TEXTURE0); + glBindTexture(texture->target, texture->tex_id); glDeleteFramebuffers(1, &tmp_fb); + glDeleteFramebuffers(1, &tmp_fb2); + glDeleteTextures(1, &tmp_tex); } // Now compute radiance @@ -1955,7 +1996,6 @@ void RasterizerStorageGLES3::sky_set_texture(RID p_sky, RID p_panorama, int p_ra glActiveTexture(GL_TEXTURE0); glBindTexture(GL_TEXTURE_2D_ARRAY, sky->radiance); shaders.cubemap_filter.set_uniform(CubemapFilterShaderGLES3::SOURCE_ARRAY_INDEX, j - 1); //read from previous to ensure better blur - shaders.cubemap_filter.set_uniform(CubemapFilterShaderGLES3::SOURCE_RESOLUTION, float(size / 2)); } for (int i = 0; i < 2; i++) { @@ -2085,7 +2125,6 @@ void RasterizerStorageGLES3::sky_set_texture(RID p_sky, RID p_panorama, int p_ra glActiveTexture(GL_TEXTURE0); glBindTexture(GL_TEXTURE_2D, sky->radiance); shaders.cubemap_filter.set_uniform(CubemapFilterShaderGLES3::SOURCE_MIP_LEVEL, float(lod - 1)); //read from previous to ensure better blur - shaders.cubemap_filter.set_uniform(CubemapFilterShaderGLES3::SOURCE_RESOLUTION, float(size)); } for (int i = 0; i < 2; i++) { @@ -4679,7 +4718,7 @@ void RasterizerStorageGLES3::multimesh_instance_set_color(RID p_multimesh, int p ERR_FAIL_COND(!multimesh); ERR_FAIL_INDEX(p_index, multimesh->size); ERR_FAIL_COND(multimesh->color_format == VS::MULTIMESH_COLOR_NONE); - ERR_FAIL_INDEX(multimesh->color_format, VS::MULTIMESH_COLOR_FLOAT); + ERR_FAIL_INDEX(multimesh->color_format, VS::MULTIMESH_COLOR_MAX); int stride = multimesh->color_floats + multimesh->xform_floats + multimesh->custom_data_floats; float *dataptr = &multimesh->data.write[stride * p_index + multimesh->xform_floats]; @@ -4713,7 +4752,7 @@ void RasterizerStorageGLES3::multimesh_instance_set_custom_data(RID p_multimesh, ERR_FAIL_COND(!multimesh); ERR_FAIL_INDEX(p_index, multimesh->size); ERR_FAIL_COND(multimesh->custom_data_format == VS::MULTIMESH_CUSTOM_DATA_NONE); - ERR_FAIL_INDEX(multimesh->custom_data_format, VS::MULTIMESH_CUSTOM_DATA_FLOAT); + ERR_FAIL_INDEX(multimesh->custom_data_format, VS::MULTIMESH_CUSTOM_DATA_MAX); int stride = multimesh->color_floats + multimesh->xform_floats + multimesh->custom_data_floats; float *dataptr = &multimesh->data.write[stride * p_index + multimesh->xform_floats + multimesh->color_floats]; @@ -4802,7 +4841,7 @@ Color RasterizerStorageGLES3::multimesh_instance_get_color(RID p_multimesh, int ERR_FAIL_COND_V(!multimesh, Color()); ERR_FAIL_INDEX_V(p_index, multimesh->size, Color()); ERR_FAIL_COND_V(multimesh->color_format == VS::MULTIMESH_COLOR_NONE, Color()); - ERR_FAIL_INDEX_V(multimesh->color_format, VS::MULTIMESH_COLOR_FLOAT, Color()); + ERR_FAIL_INDEX_V(multimesh->color_format, VS::MULTIMESH_COLOR_MAX, Color()); int stride = multimesh->color_floats + multimesh->xform_floats + multimesh->custom_data_floats; float *dataptr = &multimesh->data.write[stride * p_index + multimesh->xform_floats]; @@ -4836,7 +4875,7 @@ Color RasterizerStorageGLES3::multimesh_instance_get_custom_data(RID p_multimesh ERR_FAIL_COND_V(!multimesh, Color()); ERR_FAIL_INDEX_V(p_index, multimesh->size, Color()); ERR_FAIL_COND_V(multimesh->custom_data_format == VS::MULTIMESH_CUSTOM_DATA_NONE, Color()); - ERR_FAIL_INDEX_V(multimesh->custom_data_format, VS::MULTIMESH_CUSTOM_DATA_FLOAT, Color()); + ERR_FAIL_INDEX_V(multimesh->custom_data_format, VS::MULTIMESH_CUSTOM_DATA_MAX, Color()); int stride = multimesh->color_floats + multimesh->xform_floats + multimesh->custom_data_floats; float *dataptr = &multimesh->data.write[stride * p_index + multimesh->xform_floats + multimesh->color_floats]; @@ -7105,7 +7144,7 @@ void RasterizerStorageGLES3::_render_target_allocate(RenderTarget *rt) { int max_samples = 0; glGetIntegerv(GL_MAX_SAMPLES, &max_samples); if (msaa > max_samples) { - WARN_PRINTS("MSAA must be <= GL_MAX_SAMPLES, falling-back to GL_MAX_SAMPLES = " + itos(max_samples)); + WARN_PRINT("MSAA must be <= GL_MAX_SAMPLES, falling-back to GL_MAX_SAMPLES = " + itos(max_samples)); msaa = max_samples; } diff --git a/drivers/gles3/shader_compiler_gles3.cpp b/drivers/gles3/shader_compiler_gles3.cpp index 121a7f60f4..4e4d896bd7 100644 --- a/drivers/gles3/shader_compiler_gles3.cpp +++ b/drivers/gles3/shader_compiler_gles3.cpp @@ -166,7 +166,7 @@ static String _opstr(SL::Operator p_op) { static String _mkid(const String &p_id) { - String id = "m_" + p_id; + String id = "m_" + p_id.replace("__", "_dus_"); return id.replace("__", "_dus_"); //doubleunderscore is reserved in glsl } @@ -400,7 +400,7 @@ String ShaderCompilerGLES3::_dump_node_code(SL::Node *p_node, int p_level, Gener for (int i = 0; i < max_uniforms; i++) { r_gen_code.uniforms += uniform_defines[i]; } -#if 1 + // add up int offset = 0; for (int i = 0; i < uniform_sizes.size(); i++) { @@ -420,45 +420,6 @@ String ShaderCompilerGLES3::_dump_node_code(SL::Node *p_node, int p_level, Gener if (r_gen_code.uniform_total_size % 16 != 0) { //UBO sizes must be multiples of 16 r_gen_code.uniform_total_size += r_gen_code.uniform_total_size % 16; } -#else - // add up - for (int i = 0; i < uniform_sizes.size(); i++) { - - if (i > 0) { - - int align = uniform_sizes[i - 1] % uniform_alignments[i]; - if (align != 0) { - uniform_sizes[i - 1] += uniform_alignments[i] - align; - } - - uniform_sizes[i] = uniform_sizes[i] + uniform_sizes[i - 1]; - } - } - //offset - r_gen_code.uniform_offsets.resize(uniform_sizes.size()); - for (int i = 0; i < uniform_sizes.size(); i++) { - - if (i > 0) - r_gen_code.uniform_offsets[i] = uniform_sizes[i - 1]; - else - r_gen_code.uniform_offsets[i] = 0; - } - /* - for(Map<StringName,SL::ShaderNode::Uniform>::Element *E=pnode->uniforms.front();E;E=E->next()) { - - if (SL::is_sampler_type(E->get().type)) { - continue; - } - - } - -*/ - if (uniform_sizes.size()) { - r_gen_code.uniform_total_size = uniform_sizes[uniform_sizes.size() - 1]; - } else { - r_gen_code.uniform_total_size = 0; - } -#endif for (Map<StringName, SL::ShaderNode::Varying>::Element *E = pnode->varyings.front(); E; E = E->next()) { diff --git a/drivers/gles3/shader_gles3.cpp b/drivers/gles3/shader_gles3.cpp index 5d269e22f0..69f42c4d6d 100644 --- a/drivers/gles3/shader_gles3.cpp +++ b/drivers/gles3/shader_gles3.cpp @@ -161,7 +161,7 @@ static void _display_error_with_code(const String &p_error, const Vector<const c line++; } - ERR_PRINTS(p_error); + ERR_PRINT(p_error); } ShaderGLES3::Version *ShaderGLES3::get_current_version() { diff --git a/drivers/gles3/shaders/copy.glsl b/drivers/gles3/shaders/copy.glsl index 1952e201aa..a3cdb3a543 100644 --- a/drivers/gles3/shaders/copy.glsl +++ b/drivers/gles3/shaders/copy.glsl @@ -104,6 +104,10 @@ uniform sampler2D CbCr; //texunit:1 /* clang-format on */ +#ifdef USE_LOD +uniform float mip_level; +#endif + #if defined(USE_TEXTURE3D) || defined(USE_TEXTURE2DARRAY) uniform float layer; #endif @@ -190,8 +194,12 @@ void main() { color.gb = textureLod(CbCr, uv_interp, 0.0).rg - vec2(0.5, 0.5); color.a = 1.0; #else +#ifdef USE_LOD + vec4 color = textureLod(source, uv_interp, mip_level); +#else vec4 color = textureLod(source, uv_interp, 0.0); #endif +#endif #ifdef LINEAR_TO_SRGB // regular Linear -> SRGB conversion diff --git a/drivers/gles3/shaders/cubemap_filter.glsl b/drivers/gles3/shaders/cubemap_filter.glsl index 3f3313c3a7..e1872eb433 100644 --- a/drivers/gles3/shaders/cubemap_filter.glsl +++ b/drivers/gles3/shaders/cubemap_filter.glsl @@ -23,6 +23,7 @@ precision highp int; #ifdef USE_SOURCE_PANORAMA uniform sampler2D source_panorama; //texunit:0 +uniform float source_resolution; #endif #ifdef USE_SOURCE_DUAL_PARABOLOID_ARRAY @@ -44,7 +45,6 @@ uniform samplerCube source_cube; //texunit:0 uniform int face_id; uniform float roughness; -uniform float source_resolution; in highp vec2 uv_interp; @@ -183,12 +183,12 @@ vec2 Hammersley(uint i, uint N) { #ifdef LOW_QUALITY #define SAMPLE_COUNT 64u -#define SAMPLE_DELTA 0.05 +#define SAMPLE_DELTA 0.1 #else #define SAMPLE_COUNT 512u -#define SAMPLE_DELTA 0.01 +#define SAMPLE_DELTA 0.03 #endif @@ -332,6 +332,7 @@ void main() { if (ndotl > 0.0) { +#ifdef USE_SOURCE_PANORAMA float D = DistributionGGX(N, H, roughness); float ndoth = max(dot(N, H), 0.0); float hdotv = max(dot(H, V), 0.0); @@ -342,17 +343,14 @@ void main() { float mipLevel = roughness == 0.0 ? 0.0 : 0.5 * log2(saSample / saTexel); -#ifdef USE_SOURCE_PANORAMA sum.rgb += texturePanorama(L, source_panorama, mipLevel).rgb * ndotl; #endif #ifdef USE_SOURCE_DUAL_PARABOLOID_ARRAY - sum.rgb += textureDualParaboloidArray(L).rgb * ndotl; #endif #ifdef USE_SOURCE_DUAL_PARABOLOID - sum.rgb += textureDualParaboloid(L).rgb * ndotl; #endif diff --git a/drivers/gles3/shaders/scene.glsl b/drivers/gles3/shaders/scene.glsl index a330dbef77..a45ac2eb8a 100644 --- a/drivers/gles3/shaders/scene.glsl +++ b/drivers/gles3/shaders/scene.glsl @@ -1224,35 +1224,6 @@ in highp float dp_clip; #endif -#if 0 -// need to save texture depth for this -vec3 light_transmittance(float translucency,vec3 light_vec, vec3 normal, vec3 pos, float distance) { - - float scale = 8.25 * (1.0 - translucency) / subsurface_scatter_width; - float d = scale * distance; - - /** - * Armed with the thickness, we can now calculate the color by means of the - * precalculated transmittance profile. - * (It can be precomputed into a texture, for maximum performance): - */ - float dd = -d * d; - vec3 profile = - vec3(0.233, 0.455, 0.649) * exp(dd / 0.0064) + - vec3(0.1, 0.336, 0.344) * exp(dd / 0.0484) + - vec3(0.118, 0.198, 0.0) * exp(dd / 0.187) + - vec3(0.113, 0.007, 0.007) * exp(dd / 0.567) + - vec3(0.358, 0.004, 0.0) * exp(dd / 1.99) + - vec3(0.078, 0.0, 0.0) * exp(dd / 7.41); - - /** - * Using the profile, we finally approximate the transmitted lighting from - * the back of the object: - */ - return profile * clamp(0.3 + dot(light_vec, normal),0.0,1.0); -} -#endif - void light_process_omni(int idx, vec3 vertex, vec3 eye_vec, vec3 normal, vec3 binormal, vec3 tangent, vec3 albedo, vec3 transmission, float roughness, float metallic, float specular, float rim, float rim_tint, float clearcoat, float clearcoat_gloss, float anisotropy, float p_blob_intensity, inout vec3 diffuse_light, inout vec3 specular_light, inout float alpha) { vec3 light_rel_vec = omni_lights[idx].light_pos_inv_radius.xyz - vertex; diff --git a/drivers/pulseaudio/audio_driver_pulseaudio.cpp b/drivers/pulseaudio/audio_driver_pulseaudio.cpp index 68487c7805..df9303fbec 100644 --- a/drivers/pulseaudio/audio_driver_pulseaudio.cpp +++ b/drivers/pulseaudio/audio_driver_pulseaudio.cpp @@ -176,7 +176,7 @@ Error AudioDriverPulseAudio::init_device() { break; default: - WARN_PRINTS("PulseAudio: Unsupported number of channels: " + itos(pa_map.channels)); + WARN_PRINT("PulseAudio: Unsupported number of channels: " + itos(pa_map.channels)); pa_channel_map_init_stereo(&pa_map); channels = 2; break; @@ -204,7 +204,7 @@ Error AudioDriverPulseAudio::init_device() { pa_str = pa_stream_new(pa_ctx, "Sound", &spec, &pa_map); if (pa_str == NULL) { - ERR_PRINTS("PulseAudio: pa_stream_new error: " + String(pa_strerror(pa_context_errno(pa_ctx)))); + ERR_PRINT("PulseAudio: pa_stream_new error: " + String(pa_strerror(pa_context_errno(pa_ctx)))); ERR_FAIL_V(ERR_CANT_OPEN); } @@ -229,8 +229,8 @@ Error AudioDriverPulseAudio::init_device() { samples_out.resize(pa_buffer_size); // Reset audio input to keep synchronisation. - capture_position = 0; - capture_size = 0; + input_position = 0; + input_size = 0; return OK; } @@ -388,7 +388,7 @@ void AudioDriverPulseAudio::thread_func(void *p_udata) { const void *ptr = ad->samples_out.ptr(); ret = pa_stream_write(ad->pa_str, (char *)ptr + write_ofs, bytes_to_write, NULL, 0LL, PA_SEEK_RELATIVE); if (ret != 0) { - ERR_PRINTS("PulseAudio: pa_stream_write error: " + String(pa_strerror(ret))); + ERR_PRINT("PulseAudio: pa_stream_write error: " + String(pa_strerror(ret))); } else { avail_bytes -= bytes_to_write; write_ofs += bytes_to_write; @@ -465,7 +465,7 @@ void AudioDriverPulseAudio::thread_func(void *p_udata) { size_t bytes = pa_stream_readable_size(ad->pa_rec_str); if (bytes > 0) { const void *ptr = NULL; - size_t maxbytes = ad->capture_buffer.size() * sizeof(int16_t); + size_t maxbytes = ad->input_buffer.size() * sizeof(int16_t); bytes = MIN(bytes, maxbytes); ret = pa_stream_peek(ad->pa_rec_str, &ptr, &bytes); @@ -475,11 +475,11 @@ void AudioDriverPulseAudio::thread_func(void *p_udata) { int16_t *srcptr = (int16_t *)ptr; for (size_t i = bytes >> 1; i > 0; i--) { int32_t sample = int32_t(*srcptr++) << 16; - ad->capture_buffer_write(sample); + ad->input_buffer_write(sample); if (ad->pa_rec_map.channels == 1) { - // In case capture device is single channel convert it to Stereo - ad->capture_buffer_write(sample); + // In case input device is single channel convert it to Stereo + ad->input_buffer_write(sample); } } @@ -666,7 +666,7 @@ Error AudioDriverPulseAudio::capture_init_device() { break; default: - WARN_PRINTS("PulseAudio: Unsupported number of capture channels: " + itos(pa_rec_map.channels)); + WARN_PRINT("PulseAudio: Unsupported number of input channels: " + itos(pa_rec_map.channels)); pa_channel_map_init_stereo(&pa_rec_map); break; } @@ -686,7 +686,7 @@ Error AudioDriverPulseAudio::capture_init_device() { pa_rec_str = pa_stream_new(pa_ctx, "Record", &spec, &pa_rec_map); if (pa_rec_str == NULL) { - ERR_PRINTS("PulseAudio: pa_stream_new error: " + String(pa_strerror(pa_context_errno(pa_ctx)))); + ERR_PRINT("PulseAudio: pa_stream_new error: " + String(pa_strerror(pa_context_errno(pa_ctx)))); ERR_FAIL_V(ERR_CANT_OPEN); } @@ -694,14 +694,14 @@ Error AudioDriverPulseAudio::capture_init_device() { pa_stream_flags flags = pa_stream_flags(PA_STREAM_INTERPOLATE_TIMING | PA_STREAM_ADJUST_LATENCY | PA_STREAM_AUTO_TIMING_UPDATE); int error_code = pa_stream_connect_record(pa_rec_str, dev, &attr, flags); if (error_code < 0) { - ERR_PRINTS("PulseAudio: pa_stream_connect_record error: " + String(pa_strerror(error_code))); + ERR_PRINT("PulseAudio: pa_stream_connect_record error: " + String(pa_strerror(error_code))); ERR_FAIL_V(ERR_CANT_OPEN); } - capture_buffer_init(input_buffer_frames); + input_buffer_init(input_buffer_frames); - print_verbose("PulseAudio: detected " + itos(pa_rec_map.channels) + " capture channels"); - print_verbose("PulseAudio: capture buffer frames: " + itos(input_buffer_frames) + " calculated latency: " + itos(input_buffer_frames * 1000 / mix_rate) + "ms"); + print_verbose("PulseAudio: detected " + itos(pa_rec_map.channels) + " input channels"); + print_verbose("PulseAudio: input buffer frames: " + itos(input_buffer_frames) + " calculated latency: " + itos(input_buffer_frames * 1000 / mix_rate) + "ms"); return OK; } @@ -711,7 +711,7 @@ void AudioDriverPulseAudio::capture_finish_device() { if (pa_rec_str) { int ret = pa_stream_disconnect(pa_rec_str); if (ret != 0) { - ERR_PRINTS("PulseAudio: pa_stream_disconnect error: " + String(pa_strerror(ret))); + ERR_PRINT("PulseAudio: pa_stream_disconnect error: " + String(pa_strerror(ret))); } pa_stream_unref(pa_rec_str); pa_rec_str = NULL; diff --git a/drivers/unix/os_unix.h b/drivers/unix/os_unix.h index 8ce0eca8c6..c381890834 100644 --- a/drivers/unix/os_unix.h +++ b/drivers/unix/os_unix.h @@ -85,7 +85,7 @@ public: virtual void delay_usec(uint32_t p_usec) const; virtual uint64_t get_ticks_usec() const; - virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL); + virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking = true, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL); virtual Error kill(const ProcessID &p_pid); virtual int get_process_id() const; diff --git a/drivers/wasapi/audio_driver_wasapi.cpp b/drivers/wasapi/audio_driver_wasapi.cpp index 8b342fb416..8aa6fb96c9 100644 --- a/drivers/wasapi/audio_driver_wasapi.cpp +++ b/drivers/wasapi/audio_driver_wasapi.cpp @@ -327,7 +327,7 @@ Error AudioDriverWASAPI::init_render_device(bool reinit) { break; default: - WARN_PRINTS("WASAPI: Unsupported number of channels: " + itos(audio_output.channels)); + WARN_PRINT("WASAPI: Unsupported number of channels: " + itos(audio_output.channels)); channels = 2; break; } @@ -342,8 +342,8 @@ Error AudioDriverWASAPI::init_render_device(bool reinit) { // Sample rate is independent of channels (ref: https://stackoverflow.com/questions/11048825/audio-sample-frequency-rely-on-channels) samples_in.resize(buffer_frames * channels); - capture_position = 0; - capture_size = 0; + input_position = 0; + input_size = 0; print_verbose("WASAPI: detected " + itos(channels) + " channels"); print_verbose("WASAPI: audio buffer frames: " + itos(buffer_frames) + " calculated latency: " + itos(buffer_frames * 1000 / mix_rate) + "ms"); @@ -362,7 +362,7 @@ Error AudioDriverWASAPI::init_capture_device(bool reinit) { HRESULT hr = audio_input.audio_client->GetBufferSize(&max_frames); ERR_FAIL_COND_V(hr != S_OK, ERR_CANT_OPEN); - capture_buffer_init(max_frames); + input_buffer_init(max_frames); return OK; } @@ -715,8 +715,8 @@ void AudioDriverWASAPI::thread_func(void *p_udata) { } } - ad->capture_buffer_write(l); - ad->capture_buffer_write(r); + ad->input_buffer_write(l); + ad->input_buffer_write(r); } read_frames += num_frames_available; diff --git a/drivers/windows/file_access_windows.cpp b/drivers/windows/file_access_windows.cpp index 1b8760fdc7..01d2b8716f 100644 --- a/drivers/windows/file_access_windows.cpp +++ b/drivers/windows/file_access_windows.cpp @@ -102,7 +102,7 @@ Error FileAccessWindows::_open(const String &p_path, int p_mode_flags) { String base_file = path.get_file(); if (base_file != fname && base_file.findn(fname) == 0) { - WARN_PRINTS("Case mismatch opening requested file '" + base_file + "', stored as '" + fname + "' in the filesystem. This file will not open when exported to other case-sensitive platforms."); + WARN_PRINT("Case mismatch opening requested file '" + base_file + "', stored as '" + fname + "' in the filesystem. This file will not open when exported to other case-sensitive platforms."); } } FindClose(f); diff --git a/drivers/winmidi/midi_driver_winmidi.cpp b/drivers/winmidi/midi_driver_winmidi.cpp index e79216efaf..01c194b7d8 100644 --- a/drivers/winmidi/midi_driver_winmidi.cpp +++ b/drivers/winmidi/midi_driver_winmidi.cpp @@ -53,12 +53,12 @@ Error MIDIDriverWinMidi::open() { } else { char err[256]; midiInGetErrorText(res, err, 256); - ERR_PRINTS("midiInOpen error: " + String(err)); + ERR_PRINT("midiInOpen error: " + String(err)); MIDIINCAPS caps; res = midiInGetDevCaps(i, &caps, sizeof(MIDIINCAPS)); if (res == MMSYSERR_NOERROR) { - ERR_PRINTS("Can't open MIDI device \"" + String(caps.szPname) + "\", is it being used by another application?"); + ERR_PRINT("Can't open MIDI device \"" + String(caps.szPname) + "\", is it being used by another application?"); } } } diff --git a/editor/animation_bezier_editor.cpp b/editor/animation_bezier_editor.cpp index 2514663b4c..af2760e82b 100644 --- a/editor/animation_bezier_editor.cpp +++ b/editor/animation_bezier_editor.cpp @@ -491,26 +491,6 @@ void AnimationBezierTrackEdit::_notification(int p_what) { } draw_rect(Rect2(bs_from, bs_to - bs_from), bs); } - -#if 0 - // KEYFAMES // - - { - - float scale = timeline->get_zoom_scale(); - int limit_end = get_size().width - timeline->get_buttons_width(); - - for (int i = 0; i < animation->track_get_key_count(track); i++) { - - float offset = animation->track_get_key_time(track, i) - timeline->get_value(); - if (editor->is_key_selected(track, i) && editor->is_moving_selection()) { - offset += editor->get_moving_selection_offset(); - } - offset = offset * scale + limit; - draw_key(i, scale, int(offset), editor->is_key_selected(track, i), limit, limit_end); - } - } -#endif } } diff --git a/editor/animation_track_editor.cpp b/editor/animation_track_editor.cpp index f6d5312fc7..e9719f8618 100644 --- a/editor/animation_track_editor.cpp +++ b/editor/animation_track_editor.cpp @@ -4838,40 +4838,23 @@ struct _AnimMoveRestore { void AnimationTrackEditor::_clear_key_edit() { if (key_edit) { - -#if 0 - // going back seems like the most comfortable thing to do, but it results - // in weird behaviors and crashes, because going back to animation editor - // triggers the editor setting up again itself - - bool go_back = false; + //if key edit is the object being inspected, remove it first if (EditorNode::get_singleton()->get_inspector()->get_edited_object() == key_edit) { EditorNode::get_singleton()->push_item(NULL); - go_back = true; } + //then actually delete it memdelete(key_edit); key_edit = NULL; + } - if (go_back) { - EditorNode::get_singleton()->get_inspector_dock()->go_back(); - } -#else - //if key edit is the object being inspected, remove it first - if (EditorNode::get_singleton()->get_inspector()->get_edited_object() == key_edit || - EditorNode::get_singleton()->get_inspector()->get_edited_object() == multi_key_edit) { + if (multi_key_edit) { + if (EditorNode::get_singleton()->get_inspector()->get_edited_object() == multi_key_edit) { EditorNode::get_singleton()->push_item(NULL); } - //then actually delete it - if (key_edit) { - memdelete(key_edit); - key_edit = NULL; - } else if (multi_key_edit) { - memdelete(multi_key_edit); - multi_key_edit = NULL; - } -#endif + memdelete(multi_key_edit); + multi_key_edit = NULL; } } @@ -4927,7 +4910,7 @@ void AnimationTrackEditor::_update_key_edit() { if (!key_ofs_map.has(track)) { key_ofs_map[track] = List<float>(); - base_map[track] = *memnew(NodePath); + base_map[track] = NodePath(); } key_ofs_map[track].push_back(animation->track_get_key_time(track, E->key().key)); @@ -5994,6 +5977,7 @@ AnimationTrackEditor::AnimationTrackEditor() { keying = false; moving_selection = 0; key_edit = NULL; + multi_key_edit = NULL; box_selection = memnew(Control); add_child(box_selection); @@ -6105,4 +6089,7 @@ AnimationTrackEditor::~AnimationTrackEditor() { if (key_edit) { memdelete(key_edit); } + if (multi_key_edit) { + memdelete(multi_key_edit); + } } diff --git a/editor/code_editor.cpp b/editor/code_editor.cpp index fa713349d4..e05ace53da 100644 --- a/editor/code_editor.cpp +++ b/editor/code_editor.cpp @@ -277,7 +277,8 @@ void FindReplaceBar::_replace_all() { } text_edit->set_v_scroll(vsval); - set_error(vformat(TTR("Replaced %d occurrence(s)."), rc)); + matches_label->add_color_override("font_color", rc > 0 ? get_color("font_color", "Label") : get_color("error_color", "Editor")); + matches_label->set_text(vformat(TTR("%d replaced."), rc)); text_edit->call_deferred("connect", "text_changed", this, "_editor_text_changed"); results_count = -1; @@ -1184,7 +1185,7 @@ void CodeTextEditor::move_lines_down() { void CodeTextEditor::_delete_line(int p_line) { // this is currently intended to be called within delete_lines() - // so `begin_complex_operation` is ommitted here + // so `begin_complex_operation` is omitted here text_editor->set_line(p_line, ""); if (p_line == 0 && text_editor->get_line_count() > 1) { text_editor->cursor_set_line(1); diff --git a/editor/connections_dialog.cpp b/editor/connections_dialog.cpp index 60058f2f43..1853133bc7 100644 --- a/editor/connections_dialog.cpp +++ b/editor/connections_dialog.cpp @@ -127,6 +127,7 @@ void ConnectDialog::ok_pressed() { } } emit_signal("connected"); + hide(); } void ConnectDialog::_cancel_pressed() { @@ -145,7 +146,17 @@ void ConnectDialog::_tree_node_selected() { return; dst_path = source->get_path_to(current); - get_ok()->set_disabled(false); + _update_ok_enabled(); +} + +/* + * Called each time a target node is activated within the target node tree. + */ +void ConnectDialog::_tree_item_activated() { + + if (!get_ok()->is_disabled()) { + get_ok()->emit_signal("pressed"); + } } /* @@ -199,6 +210,27 @@ void ConnectDialog::_remove_bind() { cdbinds->notify_changed(); } +/* + * Enables or disables the connect button. The connect button is enabled if a + * node is selected and valid in the selected mode. + */ +void ConnectDialog::_update_ok_enabled() { + + Node *target = tree->get_selected(); + + if (target == nullptr) { + get_ok()->set_disabled(true); + return; + } + + if (!advanced->is_pressed() && target->get_script().is_null()) { + get_ok()->set_disabled(true); + return; + } + + get_ok()->set_disabled(false); +} + void ConnectDialog::_notification(int p_what) { if (p_what == NOTIFICATION_ENTER_TREE) { @@ -211,8 +243,10 @@ void ConnectDialog::_bind_methods() { ClassDB::bind_method("_advanced_pressed", &ConnectDialog::_advanced_pressed); ClassDB::bind_method("_cancel", &ConnectDialog::_cancel_pressed); ClassDB::bind_method("_tree_node_selected", &ConnectDialog::_tree_node_selected); + ClassDB::bind_method("_tree_item_activated", &ConnectDialog::_tree_item_activated); ClassDB::bind_method("_add_bind", &ConnectDialog::_add_bind); ClassDB::bind_method("_remove_bind", &ConnectDialog::_remove_bind); + ClassDB::bind_method("_update_ok_enabled", &ConnectDialog::_update_ok_enabled); ADD_SIGNAL(MethodInfo("connected")); } @@ -280,6 +314,8 @@ bool ConnectDialog::is_editing() const { */ void ConnectDialog::init(Connection c, bool bEdit) { + set_hide_on_ok(false); + source = static_cast<Node *>(c.source); signal = c.signal; @@ -287,13 +323,12 @@ void ConnectDialog::init(Connection c, bool bEdit) { tree->set_marked(source, true); if (c.target) { - get_ok()->set_disabled(false); set_dst_node(static_cast<Node *>(c.target)); set_dst_method(c.method); - } else { - get_ok()->set_disabled(true); } + _update_ok_enabled(); + bool bDeferred = (c.flags & CONNECT_DEFERRED) == CONNECT_DEFERRED; bool bOneshot = (c.flags & CONNECT_ONESHOT) == CONNECT_ONESHOT; @@ -336,6 +371,8 @@ void ConnectDialog::_advanced_pressed() { error_label->set_visible(!_find_first_script(get_tree()->get_edited_scene_root(), get_tree()->get_edited_scene_root())); } + _update_ok_enabled(); + set_position((get_viewport_rect().size - get_custom_minimum_size()) / 2); } @@ -360,7 +397,7 @@ ConnectDialog::ConnectDialog() { tree = memnew(SceneTreeEditor(false)); tree->set_connecting_signal(true); - tree->get_scene_tree()->connect("item_activated", this, "_ok"); + tree->get_scene_tree()->connect("item_activated", this, "_tree_item_activated"); tree->connect("node_selected", this, "_tree_node_selected"); tree->set_connect_to_script_mode(true); diff --git a/editor/connections_dialog.h b/editor/connections_dialog.h index 8ef4eddea1..c30413953a 100644 --- a/editor/connections_dialog.h +++ b/editor/connections_dialog.h @@ -76,9 +76,11 @@ class ConnectDialog : public ConfirmationDialog { void ok_pressed(); void _cancel_pressed(); void _tree_node_selected(); + void _tree_item_activated(); void _add_bind(); void _remove_bind(); void _advanced_pressed(); + void _update_ok_enabled(); protected: void _notification(int p_what); diff --git a/editor/doc/doc_data.cpp b/editor/doc/doc_data.cpp index ea9bf508f1..adfffe27ba 100644 --- a/editor/doc/doc_data.cpp +++ b/editor/doc/doc_data.cpp @@ -233,6 +233,8 @@ void DocData::generate(bool p_basic_types) { List<StringName> classes; ClassDB::get_class_list(&classes); classes.sort_custom<StringName::AlphCompare>(); + // Move ProjectSettings, so that other classes can register properties there. + classes.move_to_back(classes.find("ProjectSettings")); bool skip_setter_getter_methods = true; @@ -249,7 +251,6 @@ void DocData::generate(bool p_basic_types) { ClassDoc &c = class_list[cname]; c.name = cname; c.inherits = ClassDB::get_parent_class(name); - c.category = ClassDB::get_category(name); List<PropertyInfo> properties; List<PropertyInfo> own_properties; @@ -280,13 +281,27 @@ void DocData::generate(bool p_basic_types) { prop.overridden = inherited; bool default_value_valid = false; - Variant default_value = get_documentation_default_value(name, E->get().name, default_value_valid); + Variant default_value; - if (inherited) { - bool base_default_value_valid = false; - Variant base_default_value = get_documentation_default_value(ClassDB::get_parent_class(name), E->get().name, base_default_value_valid); - if (!default_value_valid || !base_default_value_valid || default_value == base_default_value) + if (name == "ProjectSettings") { + // Special case for project settings, so that settings are not taken from the current project's settings + if (E->get().name == "script" || + ProjectSettings::get_singleton()->get_order(E->get().name) >= ProjectSettings::NO_BUILTIN_ORDER_BASE) { continue; + } + if (E->get().usage & PROPERTY_USAGE_EDITOR) { + default_value = ProjectSettings::get_singleton()->property_get_revert(E->get().name); + default_value_valid = true; + } + } else { + default_value = get_documentation_default_value(name, E->get().name, default_value_valid); + + if (inherited) { + bool base_default_value_valid = false; + Variant base_default_value = get_documentation_default_value(ClassDB::get_parent_class(name), E->get().name, base_default_value_valid); + if (!default_value_valid || !base_default_value_valid || default_value == base_default_value) + continue; + } } if (default_value_valid && default_value.get_type() != Variant::OBJECT) { @@ -387,13 +402,10 @@ void DocData::generate(bool p_basic_types) { } else { const PropertyInfo &arginfo = E->get().arguments[i]; - ArgumentDoc argument; - argument_doc_from_arginfo(argument, arginfo); int darg_idx = i - (E->get().arguments.size() - E->get().default_arguments.size()); - if (darg_idx >= 0) { Variant default_arg = E->get().default_arguments[darg_idx]; argument.default_value = default_arg.get_construct_string(); @@ -417,14 +429,10 @@ void DocData::generate(bool p_basic_types) { signal.name = EV->get().name; for (int i = 0; i < EV->get().arguments.size(); i++) { - PropertyInfo arginfo = EV->get().arguments[i]; + const PropertyInfo &arginfo = EV->get().arguments[i]; ArgumentDoc argument; - argument.name = arginfo.name; - if (arginfo.type == Variant::OBJECT && arginfo.class_name != StringName()) { - argument.type = arginfo.class_name.operator String(); - } else { - argument.type = Variant::get_type_name(arginfo.type); - } + argument_doc_from_arginfo(argument, arginfo); + signal.arguments.push_back(argument); } @@ -502,7 +510,7 @@ void DocData::generate(bool p_basic_types) { } { - //so it can be documented that it does not exist + // So we can document the concept of Variant even if it's not a usable class per se. class_list["Variant"] = ClassDoc(); class_list["Variant"].name = "Variant"; } @@ -510,17 +518,18 @@ void DocData::generate(bool p_basic_types) { if (!p_basic_types) return; + // Add Variant types. for (int i = 0; i < Variant::VARIANT_MAX; i++) { - + if (i == Variant::NIL) + continue; // Not exposed outside of 'null', should not be in class list. if (i == Variant::OBJECT) - continue; //use the core type instead + continue; // Use the core type instead. String cname = Variant::get_type_name(Variant::Type(i)); class_list[cname] = ClassDoc(); ClassDoc &c = class_list[cname]; c.name = cname; - c.category = "Built-In Types"; Variant::CallError cerror; Variant v = Variant::construct(Variant::Type(i), NULL, 0, cerror); @@ -540,15 +549,10 @@ void DocData::generate(bool p_basic_types) { for (int j = 0; j < mi.arguments.size(); j++) { PropertyInfo arginfo = mi.arguments[j]; - ArgumentDoc ad; + argument_doc_from_arginfo(ad, mi.arguments[j]); ad.name = arginfo.name; - if (arginfo.type == Variant::NIL) - ad.type = "Variant"; - else - ad.type = Variant::get_type_name(arginfo.type); - int defarg = mi.default_arguments.size() - mi.arguments.size() + j; if (defarg >= 0) ad.default_value = mi.default_arguments[defarg]; @@ -837,8 +841,6 @@ Error DocData::_load(Ref<XMLParser> parser) { c.name = name; if (parser->has_attribute("inherits")) c.inherits = parser->get_attribute_value("inherits"); - if (parser->has_attribute("category")) - c.category = parser->get_attribute_value("category"); while (parser->read() == OK) { @@ -1028,25 +1030,24 @@ Error DocData::save_classes(const String &p_default_path, const Map<String, Stri String header = "<class name=\"" + c.name + "\""; if (c.inherits != "") header += " inherits=\"" + c.inherits + "\""; - - String category = c.category; - if (c.category == "") - category = "Core"; - header += " category=\"" + category + "\""; header += String(" version=\"") + VERSION_NUMBER + "\""; header += ">"; _write_string(f, 0, header); + _write_string(f, 1, "<brief_description>"); _write_string(f, 2, c.brief_description.strip_edges().xml_escape()); _write_string(f, 1, "</brief_description>"); + _write_string(f, 1, "<description>"); _write_string(f, 2, c.description.strip_edges().xml_escape()); _write_string(f, 1, "</description>"); + _write_string(f, 1, "<tutorials>"); for (int i = 0; i < c.tutorials.size(); i++) { _write_string(f, 2, "<link>" + c.tutorials.get(i).xml_escape() + "</link>"); } _write_string(f, 1, "</tutorials>"); + _write_string(f, 1, "<methods>"); c.methods.sort(); diff --git a/editor/doc/doc_dump.cpp b/editor/doc/doc_dump.cpp index edb1a536c3..d7e1d257f2 100644 --- a/editor/doc/doc_dump.cpp +++ b/editor/doc/doc_dump.cpp @@ -93,16 +93,14 @@ void DocDump::dump(const String &p_file) { String inherits = ClassDB::get_parent_class(name); if (inherits != "") header += " inherits=\"" + inherits + "\""; - String category = ClassDB::get_category(name); - if (category == "") - category = "Core"; - header += " category=\"" + category + "\""; - header += ">"; _write_string(f, 0, header); + _write_string(f, 1, "<brief_description>"); _write_string(f, 1, "</brief_description>"); + _write_string(f, 1, "<description>"); _write_string(f, 1, "</description>"); + _write_string(f, 1, "<methods>"); List<MethodInfo> method_list; diff --git a/editor/editor_audio_buses.cpp b/editor/editor_audio_buses.cpp index e4b2a2748a..0a60aabd2d 100644 --- a/editor/editor_audio_buses.cpp +++ b/editor/editor_audio_buses.cpp @@ -1248,7 +1248,7 @@ void EditorAudioBuses::_load_default_layout() { String layout_path = ProjectSettings::get_singleton()->get("audio/default_bus_layout"); - Ref<AudioBusLayout> state = ResourceLoader::load(layout_path); + Ref<AudioBusLayout> state = ResourceLoader::load(layout_path, "", true); if (state.is_null()) { EditorNode::get_singleton()->show_warning(vformat(TTR("There is no '%s' file."), layout_path)); return; @@ -1265,7 +1265,7 @@ void EditorAudioBuses::_load_default_layout() { void EditorAudioBuses::_file_dialog_callback(const String &p_string) { if (file_dialog->get_mode() == EditorFileDialog::MODE_OPEN_FILE) { - Ref<AudioBusLayout> state = ResourceLoader::load(p_string); + Ref<AudioBusLayout> state = ResourceLoader::load(p_string, "", true); if (state.is_null()) { EditorNode::get_singleton()->show_warning(TTR("Invalid file, not an audio bus layout.")); return; @@ -1403,7 +1403,7 @@ void EditorAudioBuses::open_layout(const String &p_path) { EditorNode::get_singleton()->make_bottom_panel_item_visible(this); - Ref<AudioBusLayout> state = ResourceLoader::load(p_path); + Ref<AudioBusLayout> state = ResourceLoader::load(p_path, "", true); if (state.is_null()) { EditorNode::get_singleton()->show_warning(TTR("Invalid file, not an audio bus layout.")); return; diff --git a/editor/editor_autoload_settings.cpp b/editor/editor_autoload_settings.cpp index 46a54969e0..dba8c2ec8c 100644 --- a/editor/editor_autoload_settings.cpp +++ b/editor/editor_autoload_settings.cpp @@ -120,6 +120,7 @@ void EditorAutoloadSettings::_autoload_add() { autoload_add_path->get_line_edit()->set_text(""); autoload_add_name->set_text(""); + add_autoload->set_disabled(true); } void EditorAutoloadSettings::_autoload_selected() { @@ -312,7 +313,34 @@ void EditorAutoloadSettings::_autoload_open(const String &fpath) { void EditorAutoloadSettings::_autoload_file_callback(const String &p_path) { - autoload_add_name->set_text(p_path.get_file().get_basename()); + // Convert the file name to PascalCase, which is the convention for classes in GDScript. + const String class_name = p_path.get_file().get_basename().capitalize().replace(" ", ""); + + // If the name collides with a built-in class, prefix the name to make it possible to add without having to edit the name. + // The prefix is subjective, but it provides better UX than leaving the Add button disabled :) + const String prefix = ClassDB::class_exists(class_name) ? "Global" : ""; + + autoload_add_name->set_text(prefix + class_name); + add_autoload->set_disabled(false); +} + +void EditorAutoloadSettings::_autoload_text_entered(const String p_name) { + + if (autoload_add_path->get_line_edit()->get_text() != "" && _autoload_name_is_valid(p_name, NULL)) { + _autoload_add(); + } +} + +void EditorAutoloadSettings::_autoload_path_text_changed(const String p_path) { + + add_autoload->set_disabled( + p_path == "" || !_autoload_name_is_valid(autoload_add_name->get_text(), NULL)); +} + +void EditorAutoloadSettings::_autoload_text_changed(const String p_name) { + + add_autoload->set_disabled( + autoload_add_path->get_line_edit()->get_text() == "" || !_autoload_name_is_valid(p_name, NULL)); } Node *EditorAutoloadSettings::_create_autoload(const String &p_path) { @@ -424,7 +452,7 @@ void EditorAutoloadSettings::update_autoload() { item->set_editable(2, true); item->set_text(2, TTR("Enable")); item->set_checked(2, info.is_singleton); - item->add_button(3, get_icon("FileList", "EditorIcons"), BUTTON_OPEN); + item->add_button(3, get_icon("Load", "EditorIcons"), BUTTON_OPEN); item->add_button(3, get_icon("MoveUp", "EditorIcons"), BUTTON_MOVE_UP); item->add_button(3, get_icon("MoveDown", "EditorIcons"), BUTTON_MOVE_DOWN); item->add_button(3, get_icon("Remove", "EditorIcons"), BUTTON_DELETE); @@ -713,7 +741,9 @@ void EditorAutoloadSettings::_bind_methods() { ClassDB::bind_method("_autoload_edited", &EditorAutoloadSettings::_autoload_edited); ClassDB::bind_method("_autoload_button_pressed", &EditorAutoloadSettings::_autoload_button_pressed); ClassDB::bind_method("_autoload_activated", &EditorAutoloadSettings::_autoload_activated); + ClassDB::bind_method("_autoload_path_text_changed", &EditorAutoloadSettings::_autoload_path_text_changed); ClassDB::bind_method("_autoload_text_entered", &EditorAutoloadSettings::_autoload_text_entered); + ClassDB::bind_method("_autoload_text_changed", &EditorAutoloadSettings::_autoload_text_changed); ClassDB::bind_method("_autoload_open", &EditorAutoloadSettings::_autoload_open); ClassDB::bind_method("_autoload_file_callback", &EditorAutoloadSettings::_autoload_file_callback); @@ -806,6 +836,8 @@ EditorAutoloadSettings::EditorAutoloadSettings() { autoload_add_path->set_h_size_flags(SIZE_EXPAND_FILL); autoload_add_path->get_file_dialog()->set_mode(EditorFileDialog::MODE_OPEN_FILE); autoload_add_path->get_file_dialog()->connect("file_selected", this, "_autoload_file_callback"); + autoload_add_path->get_line_edit()->connect("text_changed", this, "_autoload_path_text_changed"); + hbc->add_child(autoload_add_path); l = memnew(Label); @@ -815,11 +847,14 @@ EditorAutoloadSettings::EditorAutoloadSettings() { autoload_add_name = memnew(LineEdit); autoload_add_name->set_h_size_flags(SIZE_EXPAND_FILL); autoload_add_name->connect("text_entered", this, "_autoload_text_entered"); + autoload_add_name->connect("text_changed", this, "_autoload_text_changed"); hbc->add_child(autoload_add_name); - Button *add_autoload = memnew(Button); + add_autoload = memnew(Button); add_autoload->set_text(TTR("Add")); add_autoload->connect("pressed", this, "_autoload_add"); + // The button will be enabled once a valid name is entered (either automatically or manually). + add_autoload->set_disabled(true); hbc->add_child(add_autoload); tree = memnew(Tree); diff --git a/editor/editor_autoload_settings.h b/editor/editor_autoload_settings.h index e1a04644aa..653a1b0a78 100644 --- a/editor/editor_autoload_settings.h +++ b/editor/editor_autoload_settings.h @@ -76,6 +76,7 @@ class EditorAutoloadSettings : public VBoxContainer { Tree *tree; EditorLineEditFileChooser *autoload_add_path; LineEdit *autoload_add_name; + Button *add_autoload; bool _autoload_name_is_valid(const String &p_name, String *r_error = NULL); @@ -84,7 +85,9 @@ class EditorAutoloadSettings : public VBoxContainer { void _autoload_edited(); void _autoload_button_pressed(Object *p_item, int p_column, int p_button); void _autoload_activated(); - void _autoload_text_entered(String) { _autoload_add(); } + void _autoload_path_text_changed(const String p_path); + void _autoload_text_entered(const String p_name); + void _autoload_text_changed(const String p_name); void _autoload_open(const String &fpath); void _autoload_file_callback(const String &p_path); Node *_create_autoload(const String &p_path); diff --git a/editor/editor_export.cpp b/editor/editor_export.cpp index d66b386f93..3d8ea0b040 100644 --- a/editor/editor_export.cpp +++ b/editor/editor_export.cpp @@ -748,7 +748,7 @@ Error EditorExportPlatform::export_project_files(const Ref<EditorExportPreset> & config.instance(); Error err = config->load(path + ".import"); if (err != OK) { - ERR_PRINTS("Could not parse: '" + path + "', not exported."); + ERR_PRINT("Could not parse: '" + path + "', not exported."); continue; } diff --git a/editor/editor_feature_profile.cpp b/editor/editor_feature_profile.cpp index a4a7a0cd45..559a0ef0ea 100644 --- a/editor/editor_feature_profile.cpp +++ b/editor/editor_feature_profile.cpp @@ -192,14 +192,14 @@ Error EditorFeatureProfile::load_from_file(const String &p_path) { Variant v; err = JSON::parse(text, v, err_str, err_line); if (err != OK) { - ERR_PRINTS("Error parsing '" + p_path + "' on line " + itos(err_line) + ": " + err_str); + ERR_PRINT("Error parsing '" + p_path + "' on line " + itos(err_line) + ": " + err_str); return ERR_PARSE_ERROR; } Dictionary json = v; if (!json.has("type") || String(json["type"]) != "feature_profile") { - ERR_PRINTS("Error parsing '" + p_path + "', it's not a feature profile."); + ERR_PRINT("Error parsing '" + p_path + "', it's not a feature profile."); return ERR_PARSE_ERROR; } @@ -298,7 +298,7 @@ void EditorFeatureProfileManager::_notification(int p_what) { current.instance(); Error err = current->load_from_file(EditorSettings::get_singleton()->get_feature_profiles_dir().plus_file(current_profile + ".profile")); if (err != OK) { - ERR_PRINTS("Error loading default feature profile: " + current_profile); + ERR_PRINT("Error loading default feature profile: " + current_profile); current_profile = String(); current.unref(); } diff --git a/editor/editor_file_system.cpp b/editor/editor_file_system.cpp index 5abb3c4ec2..04fe6e5ce6 100644 --- a/editor/editor_file_system.cpp +++ b/editor/editor_file_system.cpp @@ -387,7 +387,7 @@ bool EditorFileSystem::_test_for_reimport(const String &p_path, bool p_only_impo if (err == ERR_FILE_EOF) { break; } else if (err != OK) { - ERR_PRINTS("ResourceFormatImporter::load - '" + p_path + ".import:" + itos(lines) + "' error '" + error_text + "'."); + ERR_PRINT("ResourceFormatImporter::load - '" + p_path + ".import:" + itos(lines) + "' error '" + error_text + "'."); memdelete(f); return false; //parse error, try reimport manually (Avoid reimport loop on broken file) } @@ -435,7 +435,7 @@ bool EditorFileSystem::_test_for_reimport(const String &p_path, bool p_only_impo if (err == ERR_FILE_EOF) { break; } else if (err != OK) { - ERR_PRINTS("ResourceFormatImporter::load - '" + p_path + ".import.md5:" + itos(lines) + "' error '" + error_text + "'."); + ERR_PRINT("ResourceFormatImporter::load - '" + p_path + ".import.md5:" + itos(lines) + "' error '" + error_text + "'."); memdelete(md5s); return false; // parse error } @@ -734,7 +734,7 @@ void EditorFileSystem::_scan_new_dir(EditorFileSystemDirectory *p_dir, DirAccess da->change_dir(".."); } } else { - ERR_PRINTS("Cannot go into subdir '" + E->get() + "'."); + ERR_PRINT("Cannot go into subdir '" + E->get() + "'."); } p_progress.update(idx, total); @@ -1114,7 +1114,7 @@ void EditorFileSystem::_notification(int p_what) { Thread::wait_to_finish(thread); memdelete(thread); thread = NULL; - WARN_PRINTS("Scan thread aborted..."); + WARN_PRINT("Scan thread aborted..."); set_process(false); } @@ -1780,7 +1780,7 @@ void EditorFileSystem::_reimport_file(const String &p_file) { Error err = importer->import(p_file, base_path, params, &import_variants, &gen_files, &metadata); if (err != OK) { - ERR_PRINTS("Error importing '" + p_file + "'."); + ERR_PRINT("Error importing '" + p_file + "'."); } //as import is complete, save the .import file diff --git a/editor/editor_help.cpp b/editor/editor_help.cpp index a0c106441a..556dbcbfc4 100644 --- a/editor/editor_help.cpp +++ b/editor/editor_help.cpp @@ -418,10 +418,10 @@ void EditorHelp::_update_doc() { } } - if (found) + if (found) { class_desc->pop(); - - class_desc->add_newline(); + class_desc->add_newline(); + } } class_desc->add_newline(); @@ -430,9 +430,26 @@ void EditorHelp::_update_doc() { // Brief description if (cd.brief_description != "") { + class_desc->push_color(text_color); + class_desc->push_font(doc_bold_font); + class_desc->push_indent(1); + _add_text(cd.brief_description); + class_desc->pop(); + class_desc->pop(); + class_desc->pop(); + class_desc->add_newline(); + class_desc->add_newline(); + class_desc->add_newline(); + } + + // Class description + if (cd.description != "") { + + section_line.push_back(Pair<String, int>(TTR("Description"), class_desc->get_line_count() - 2)); + description_line = class_desc->get_line_count() - 2; class_desc->push_color(title_color); class_desc->push_font(doc_title_font); - class_desc->add_text(TTR("Brief Description")); + class_desc->add_text(TTR("Description")); class_desc->pop(); class_desc->pop(); @@ -441,11 +458,43 @@ void EditorHelp::_update_doc() { class_desc->push_color(text_color); class_desc->push_font(doc_font); class_desc->push_indent(1); - _add_text(cd.brief_description); + _add_text(cd.description); + class_desc->pop(); class_desc->pop(); class_desc->pop(); + class_desc->add_newline(); + class_desc->add_newline(); + class_desc->add_newline(); + } + + // Online tutorials + if (cd.tutorials.size()) { + class_desc->push_color(title_color); + class_desc->push_font(doc_title_font); + class_desc->add_text(TTR("Online Tutorials")); + class_desc->pop(); class_desc->pop(); + + class_desc->push_indent(1); + class_desc->push_font(doc_code_font); class_desc->add_newline(); + + for (int i = 0; i < cd.tutorials.size(); i++) { + const String link = cd.tutorials[i]; + String linktxt = link; + const int seppos = linktxt.find("//"); + if (seppos != -1) { + linktxt = link.right(seppos + 2); + } + + class_desc->push_color(symbol_color); + class_desc->append_bbcode("[url=" + link + "]" + linktxt + "[/url]"); + class_desc->pop(); + class_desc->add_newline(); + } + + class_desc->pop(); + class_desc->pop(); class_desc->add_newline(); class_desc->add_newline(); } @@ -516,7 +565,7 @@ void EditorHelp::_update_doc() { if (cd.properties[i].default_value != "") { class_desc->push_color(symbol_color); - class_desc->add_text(cd.properties[i].overridden ? " [override: " : " [default: "); + class_desc->add_text(cd.properties[i].overridden ? " [" + TTR("override:") + " " : " [" + TTR("default:") + " "); class_desc->pop(); class_desc->push_color(value_color); _add_text(_fix_constant(cd.properties[i].default_value)); @@ -546,8 +595,11 @@ void EditorHelp::_update_doc() { Vector<DocData::MethodDoc> methods; for (int i = 0; i < cd.methods.size(); i++) { - if (skip_methods.has(cd.methods[i].name)) - continue; + if (skip_methods.has(cd.methods[i].name)) { + if (cd.methods[i].arguments.size() == 0 /* getter */ || (cd.methods[i].arguments.size() == 1 && cd.methods[i].return_type == "void" /* setter */)) { + continue; + } + } methods.push_back(cd.methods[i]); } @@ -658,7 +710,7 @@ void EditorHelp::_update_doc() { if (cd.theme_properties[i].default_value != "") { class_desc->push_color(symbol_color); - class_desc->add_text(" [default: "); + class_desc->add_text(" [" + TTR("default:") + " "); class_desc->pop(); class_desc->push_color(value_color); _add_text(_fix_constant(cd.theme_properties[i].default_value)); @@ -795,7 +847,7 @@ void EditorHelp::_update_doc() { enum_line[E->key()] = class_desc->get_line_count() - 2; class_desc->push_color(title_color); - class_desc->add_text(TTR("enum ")); + class_desc->add_text("enum "); class_desc->pop(); class_desc->push_font(doc_code_font); String e = E->key(); @@ -922,71 +974,6 @@ void EditorHelp::_update_doc() { } } - // Class description - if (cd.description != "") { - - section_line.push_back(Pair<String, int>(TTR("Class Description"), class_desc->get_line_count() - 2)); - description_line = class_desc->get_line_count() - 2; - class_desc->push_color(title_color); - class_desc->push_font(doc_title_font); - class_desc->add_text(TTR("Class Description")); - class_desc->pop(); - class_desc->pop(); - - class_desc->add_newline(); - class_desc->add_newline(); - class_desc->push_color(text_color); - class_desc->push_font(doc_font); - class_desc->push_indent(1); - _add_text(cd.description); - class_desc->pop(); - class_desc->pop(); - class_desc->pop(); - class_desc->add_newline(); - class_desc->add_newline(); - class_desc->add_newline(); - } - - // Online tutorials - { - class_desc->push_color(title_color); - class_desc->push_font(doc_title_font); - class_desc->add_text(TTR("Online Tutorials")); - class_desc->pop(); - class_desc->pop(); - class_desc->push_indent(1); - - class_desc->push_font(doc_code_font); - - class_desc->add_newline(); - // class_desc->add_newline(); - - if (cd.tutorials.size() != 0) { - - for (int i = 0; i < cd.tutorials.size(); i++) { - String link = cd.tutorials[i]; - String linktxt = link; - int seppos = linktxt.find("//"); - if (seppos != -1) { - linktxt = link.right(seppos + 2); - } - - class_desc->push_color(symbol_color); - class_desc->append_bbcode("[url=" + link + "]" + linktxt + "[/url]"); - class_desc->pop(); - class_desc->add_newline(); - } - } else { - class_desc->push_color(comment_color); - class_desc->append_bbcode(TTR("There are currently no tutorials for this class, you can [color=$color][url=$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/url][/color].").replace("$url2", REQUEST_URL).replace("$url", CONTRIBUTE2_URL).replace("$color", link_color_text)); - class_desc->pop(); - } - class_desc->pop(); - class_desc->pop(); - class_desc->add_newline(); - class_desc->add_newline(); - } - // Property descriptions if (property_descr) { @@ -1025,7 +1012,7 @@ void EditorHelp::_update_doc() { if (cd.properties[i].default_value != "") { class_desc->push_color(symbol_color); - class_desc->add_text(" [default: "); + class_desc->add_text(" [" + TTR("default:") + " "); class_desc->pop(); // color class_desc->push_color(value_color); @@ -1048,7 +1035,7 @@ void EditorHelp::_update_doc() { class_desc->push_cell(); class_desc->push_font(doc_code_font); class_desc->push_color(text_color); - class_desc->add_text(cd.properties[i].setter + "(value)"); + class_desc->add_text(cd.properties[i].setter + TTR("(value)")); class_desc->pop(); // color class_desc->push_color(comment_color); class_desc->add_text(" setter"); diff --git a/editor/editor_help_search.cpp b/editor/editor_help_search.cpp index 700d9b692b..80981e8fa1 100644 --- a/editor/editor_help_search.cpp +++ b/editor/editor_help_search.cpp @@ -307,7 +307,7 @@ bool EditorHelpSearch::Runner::_slice() { case PHASE_MAX: return true; default: - WARN_PRINTS("Invalid or unhandled phase in EditorHelpSearch::Runner, aborting search."); + WARN_PRINT("Invalid or unhandled phase in EditorHelpSearch::Runner, aborting search."); return true; }; diff --git a/editor/editor_inspector.cpp b/editor/editor_inspector.cpp index 56da7d93fa..7c1e58862e 100644 --- a/editor/editor_inspector.cpp +++ b/editor/editor_inspector.cpp @@ -1596,7 +1596,7 @@ void EditorInspector::update_tree() { if (capitalize_paths) cat = cat.capitalize(); - if (!filter.is_subsequence_ofi(cat) && !filter.is_subsequence_ofi(name)) + if (!filter.is_subsequence_ofi(cat) && !filter.is_subsequence_ofi(name) && property_prefix.to_lower().find(filter.to_lower()) == -1) continue; } diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 0ea8e04471..7d0601e8db 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -369,6 +369,19 @@ void EditorNode::_notification(int p_what) { case NOTIFICATION_READY: { + { + _initializing_addons = true; + Vector<String> addons; + if (ProjectSettings::get_singleton()->has_setting("editor_plugins/enabled")) { + addons = ProjectSettings::get_singleton()->get("editor_plugins/enabled"); + } + + for (int i = 0; i < addons.size(); i++) { + set_addon_plugin_enabled(addons[i], true); + } + _initializing_addons = false; + } + VisualServer::get_singleton()->viewport_set_hide_scenario(get_scene_root()->get_viewport_rid(), true); VisualServer::get_singleton()->viewport_set_hide_canvas(get_scene_root()->get_viewport_rid(), true); VisualServer::get_singleton()->viewport_set_disable_environment(get_viewport()->get_viewport_rid(), true); @@ -660,12 +673,14 @@ void EditorNode::_sources_changed(bool p_exist) { if (waiting_for_first_scan) { waiting_for_first_scan = false; - EditorResourcePreview::get_singleton()->start(); //start previes now that it's safe + // Start preview thread now that it's safe. + if (!singleton->cmdline_export_mode) { + EditorResourcePreview::get_singleton()->start(); + } _load_docks(); if (defer_load_scene != "") { - load_scene(defer_load_scene); defer_load_scene = ""; } @@ -1155,7 +1170,10 @@ void EditorNode::_save_scene_with_preview(String p_file, int p_idx) { save.step(TTR("Saving Scene"), 4); _save_scene(p_file, p_idx); - EditorResourcePreview::get_singleton()->check_for_invalidation(p_file); + + if (!singleton->cmdline_export_mode) { + EditorResourcePreview::get_singleton()->check_for_invalidation(p_file); + } } bool EditorNode::_validate_scene_recursive(const String &p_filename, Node *p_node) { @@ -1747,6 +1765,8 @@ void EditorNode::_edit_current() { return; } + Object *prev_inspected_object = get_inspector()->get_edited_object(); + bool capitalize = bool(EDITOR_GET("interface/inspector/capitalize_properties")); bool disable_folding = bool(EDITOR_GET("interface/inspector/disable_folding")); bool is_resource = current_obj->is_class("Resource"); @@ -1838,6 +1858,11 @@ void EditorNode::_edit_current() { inspector_dock->update(NULL); } + if (current_obj == prev_inspected_object) { + // Make sure inspected properties are restored. + get_inspector()->update_tree(); + } + inspector_dock->set_warning(editable_warning); if (get_inspector()->is_capitalize_paths_enabled() != capitalize) { @@ -2707,7 +2732,7 @@ void EditorNode::_tool_menu_option(int p_idx) { handler->call(callback, (const Variant **)&ud, 1, ce); if (ce.error != Variant::CallError::CALL_OK) { String err = Variant::get_call_error_text(handler, callback, (const Variant **)&ud, 1, ce); - ERR_PRINTS("Error calling function from tool menu: " + err); + ERR_PRINT("Error calling function from tool menu: " + err); } } // else it's a submenu so don't do anything. } break; @@ -3017,7 +3042,7 @@ void EditorNode::set_addon_plugin_enabled(const String &p_addon, bool p_enabled, } ps->set("editor_plugins/enabled", enabled_plugins); ps->save(); - WARN_PRINTS("Addon '" + p_addon + "' failed to load. No directory found. Removing from enabled plugins."); + WARN_PRINT("Addon '" + p_addon + "' failed to load. No directory found. Removing from enabled plugins."); return; } Error err = cf->load(addon_path); @@ -3839,7 +3864,7 @@ Ref<Texture> EditorNode::get_class_icon(const String &p_class, const String &p_f void EditorNode::progress_add_task(const String &p_task, const String &p_label, int p_steps, bool p_can_cancel) { - if (singleton->disable_progress_dialog) { + if (singleton->cmdline_export_mode) { print_line(p_task + ": begin: " + p_label + " steps: " + itos(p_steps)); } else { singleton->progress_dialog->add_task(p_task, p_label, p_steps, p_can_cancel); @@ -3848,7 +3873,7 @@ void EditorNode::progress_add_task(const String &p_task, const String &p_label, bool EditorNode::progress_task_step(const String &p_task, const String &p_state, int p_step, bool p_force_refresh) { - if (singleton->disable_progress_dialog) { + if (singleton->cmdline_export_mode) { print_line("\t" + p_task + ": step " + itos(p_step) + ": " + p_state); return false; } else { @@ -3859,7 +3884,7 @@ bool EditorNode::progress_task_step(const String &p_task, const String &p_state, void EditorNode::progress_end_task(const String &p_task) { - if (singleton->disable_progress_dialog) { + if (singleton->cmdline_export_mode) { print_line(p_task + ": end"); } else { singleton->progress_dialog->end_task(p_task); @@ -3945,7 +3970,7 @@ Error EditorNode::export_preset(const String &p_preset, const String &p_path, bo export_defer.path = p_path; export_defer.debug = p_debug; export_defer.pack_only = p_pack_only; - disable_progress_dialog = true; + cmdline_export_mode = true; return OK; } @@ -3963,7 +3988,7 @@ void EditorNode::show_warning(const String &p_text, const String &p_title) { warning->set_title(p_title); warning->popup_centered_minsize(); } else { - WARN_PRINTS(p_title + " " + p_text); + WARN_PRINT(p_title + " " + p_text); } } @@ -5587,7 +5612,7 @@ EditorNode::EditorNode() { _initializing_addons = false; docks_visible = true; restoring_scenes = false; - disable_progress_dialog = false; + cmdline_export_mode = false; scene_distraction = false; script_distraction = false; @@ -6776,19 +6801,6 @@ EditorNode::EditorNode() { import_dock->initialize_import_options(); - { - _initializing_addons = true; - Vector<String> addons; - if (ProjectSettings::get_singleton()->has_setting("editor_plugins/enabled")) { - addons = ProjectSettings::get_singleton()->get("editor_plugins/enabled"); - } - - for (int i = 0; i < addons.size(); i++) { - set_addon_plugin_enabled(addons[i], true); - } - _initializing_addons = false; - } - FileAccess::set_file_close_fail_notify_callback(_file_access_close_error_notify); waiting_for_first_scan = true; diff --git a/editor/editor_node.h b/editor/editor_node.h index 7f53f77c76..a5c04d3531 100644 --- a/editor/editor_node.h +++ b/editor/editor_node.h @@ -561,7 +561,7 @@ private: bool pack_only; } export_defer; - bool disable_progress_dialog; + bool cmdline_export_mode; static EditorNode *singleton; diff --git a/editor/editor_path.cpp b/editor/editor_path.cpp index d538c7c23d..f0d69f98fb 100644 --- a/editor/editor_path.cpp +++ b/editor/editor_path.cpp @@ -150,6 +150,7 @@ void EditorPath::_bind_methods() { EditorPath::EditorPath(EditorHistory *p_history) { history = p_history; + set_clip_text(true); set_text_align(ALIGN_LEFT); get_popup()->connect("about_to_show", this, "_about_to_show"); get_popup()->connect("id_pressed", this, "_id_pressed"); diff --git a/editor/editor_plugin_settings.cpp b/editor/editor_plugin_settings.cpp index b81a996956..16decf5c04 100644 --- a/editor/editor_plugin_settings.cpp +++ b/editor/editor_plugin_settings.cpp @@ -96,28 +96,28 @@ void EditorPluginSettings::update_plugins() { Error err2 = cf->load(path); if (err2 != OK) { - WARN_PRINTS("Can't load plugin config: " + path); + WARN_PRINT("Can't load plugin config: " + path); } else { bool key_missing = false; if (!cf->has_section_key("plugin", "name")) { - WARN_PRINTS("Plugin config misses \"plugin/name\" key: " + path); + WARN_PRINT("Plugin config misses \"plugin/name\" key: " + path); key_missing = true; } if (!cf->has_section_key("plugin", "author")) { - WARN_PRINTS("Plugin config misses \"plugin/author\" key: " + path); + WARN_PRINT("Plugin config misses \"plugin/author\" key: " + path); key_missing = true; } if (!cf->has_section_key("plugin", "version")) { - WARN_PRINTS("Plugin config misses \"plugin/version\" key: " + path); + WARN_PRINT("Plugin config misses \"plugin/version\" key: " + path); key_missing = true; } if (!cf->has_section_key("plugin", "description")) { - WARN_PRINTS("Plugin config misses \"plugin/description\" key: " + path); + WARN_PRINT("Plugin config misses \"plugin/description\" key: " + path); key_missing = true; } if (!cf->has_section_key("plugin", "script")) { - WARN_PRINTS("Plugin config misses \"plugin/script\" key: " + path); + WARN_PRINT("Plugin config misses \"plugin/script\" key: " + path); key_missing = true; } diff --git a/editor/editor_profiler.cpp b/editor/editor_profiler.cpp index 4807f8839c..e5a9c4d699 100644 --- a/editor/editor_profiler.cpp +++ b/editor/editor_profiler.cpp @@ -102,26 +102,28 @@ void EditorProfiler::clear() { } static String _get_percent_txt(float p_value, float p_total) { - if (p_total == 0) + if (p_total == 0) { p_total = 0.00001; + } + return String::num((p_value / p_total) * 100, 1) + "%"; } String EditorProfiler::_get_time_as_text(const Metric &m, float p_time, int p_calls) { - int dmode = display_mode->get_selected(); + const int dmode = display_mode->get_selected(); if (dmode == DISPLAY_FRAME_TIME) { - return rtos(p_time); + return rtos(p_time * 1000).pad_decimals(2) + " ms"; } else if (dmode == DISPLAY_AVERAGE_TIME) { - if (p_calls == 0) - return "0"; - else - return rtos(p_time / p_calls); + if (p_calls == 0) { + return "0.00 ms"; + } else { + return rtos((p_time / p_calls) * 1000).pad_decimals(2) + " ms"; + } } else if (dmode == DISPLAY_FRAME_PERCENT) { return _get_percent_txt(p_time, m.frame_time); } else if (dmode == DISPLAY_PHYSICS_FRAME_PERCENT) { - return _get_percent_txt(p_time, m.physics_frame_time); } @@ -163,12 +165,10 @@ void EditorProfiler::_item_edited() { void EditorProfiler::_update_plot() { - int w = graph->get_size().width; - int h = graph->get_size().height; - + const int w = graph->get_size().width; + const int h = graph->get_size().height; bool reset_texture = false; - - int desired_len = w * h * 4; + const int desired_len = w * h * 4; if (graph_image.size() != desired_len) { reset_texture = true; @@ -176,18 +176,19 @@ void EditorProfiler::_update_plot() { } PoolVector<uint8_t>::Write wr = graph_image.write(); + const Color background_color = get_color("dark_color_2", "Editor"); - //clear + // Clear the previous frame and set the background color. for (int i = 0; i < desired_len; i += 4) { - wr[i + 0] = 0; - wr[i + 1] = 0; - wr[i + 2] = 0; + wr[i + 0] = Math::fast_ftoi(background_color.r * 255); + wr[i + 1] = Math::fast_ftoi(background_color.g * 255); + wr[i + 2] = Math::fast_ftoi(background_color.b * 255); wr[i + 3] = 255; } //find highest value - bool use_self = display_time->get_selected() == DISPLAY_SELF_TIME; + const bool use_self = display_time->get_selected() == DISPLAY_SELF_TIME; float highest = 0; for (int i = 0; i < frame_metrics.size(); i++) { @@ -319,21 +320,23 @@ void EditorProfiler::_update_plot() { for (int j = 0; j < h * 4; j += 4) { - int a = column[j + 3]; + const int a = column[j + 3]; if (a > 0) { column[j + 0] /= a; column[j + 1] /= a; column[j + 2] /= a; } - uint8_t r = uint8_t(column[j + 0]); - uint8_t g = uint8_t(column[j + 1]); - uint8_t b = uint8_t(column[j + 2]); + const uint8_t red = uint8_t(column[j + 0]); + const uint8_t green = uint8_t(column[j + 1]); + const uint8_t blue = uint8_t(column[j + 2]); + const bool is_filled = red >= 1 || green >= 1 || blue >= 1; + const int widx = ((j >> 2) * w + i) * 4; - int widx = ((j >> 2) * w + i) * 4; - wr[widx + 0] = r; - wr[widx + 1] = g; - wr[widx + 2] = b; + // If the pixel isn't filled by any profiler line, apply the background color instead. + wr[widx + 0] = is_filled ? red : Math::fast_ftoi(background_color.r * 255); + wr[widx + 1] = is_filled ? green : Math::fast_ftoi(background_color.g * 255); + wr[widx + 2] = is_filled ? blue : Math::fast_ftoi(background_color.b * 255); wr[widx + 3] = 255; } } @@ -729,7 +732,7 @@ EditorProfiler::EditorProfiler() { h_split->set_v_size_flags(SIZE_EXPAND_FILL); variables = memnew(Tree); - variables->set_custom_minimum_size(Size2(300, 0) * EDSCALE); + variables->set_custom_minimum_size(Size2(320, 0) * EDSCALE); variables->set_hide_folding(true); h_split->add_child(variables); variables->set_hide_root(true); @@ -737,10 +740,10 @@ EditorProfiler::EditorProfiler() { variables->set_column_titles_visible(true); variables->set_column_title(0, TTR("Name")); variables->set_column_expand(0, true); - variables->set_column_min_width(0, 60); + variables->set_column_min_width(0, 60 * EDSCALE); variables->set_column_title(1, TTR("Time")); variables->set_column_expand(1, false); - variables->set_column_min_width(1, 60 * EDSCALE); + variables->set_column_min_width(1, 100 * EDSCALE); variables->set_column_title(2, TTR("Calls")); variables->set_column_expand(2, false); variables->set_column_min_width(2, 60 * EDSCALE); @@ -749,7 +752,6 @@ EditorProfiler::EditorProfiler() { graph = memnew(TextureRect); graph->set_expand(true); graph->set_mouse_filter(MOUSE_FILTER_STOP); - //graph->set_ignore_mouse(false); graph->connect("draw", this, "_graph_tex_draw"); graph->connect("gui_input", this, "_graph_tex_input"); graph->connect("mouse_exited", this, "_graph_tex_mouse_exit"); @@ -760,13 +762,10 @@ EditorProfiler::EditorProfiler() { int metric_size = CLAMP(int(EDITOR_DEF("debugger/profiler_frame_history_size", 600)), 60, 1024); frame_metrics.resize(metric_size); last_metric = -1; - //cursor_metric=-1; hover_metric = -1; EDITOR_DEF("debugger/profiler_frame_max_functions", 64); - //display_mode=DISPLAY_FRAME_TIME; - frame_delay = memnew(Timer); frame_delay->set_wait_time(0.1); frame_delay->set_one_shot(true); @@ -784,6 +783,4 @@ EditorProfiler::EditorProfiler() { seeking = false; graph_height = 1; - - //activate->set_disabled(true); } diff --git a/editor/editor_properties.cpp b/editor/editor_properties.cpp index c049096c35..c134786b89 100644 --- a/editor/editor_properties.cpp +++ b/editor/editor_properties.cpp @@ -805,10 +805,10 @@ EditorPropertyLayers::EditorPropertyLayers() { ///////////////////// INT ///////////////////////// -void EditorPropertyInteger::_value_changed(double val) { +void EditorPropertyInteger::_value_changed(int64_t val) { if (setting) return; - emit_changed(get_edited_property(), (int64_t)val); + emit_changed(get_edited_property(), val); } void EditorPropertyInteger::update_property() { @@ -816,14 +816,19 @@ void EditorPropertyInteger::update_property() { setting = true; spin->set_value(val); setting = false; +#ifdef DEBUG_ENABLED + // If spin (currently EditorSplinSlider : Range) is changed so that it can use int64_t, then the below warning wouldn't be a problem. + if (val != (int64_t)(double)(val)) { + WARN_PRINT("Cannot reliably represent '" + itos(val) + "' in the inspector, value is too large."); + } +#endif } void EditorPropertyInteger::_bind_methods() { - ClassDB::bind_method(D_METHOD("_value_changed"), &EditorPropertyInteger::_value_changed); } -void EditorPropertyInteger::setup(int p_min, int p_max, int p_step, bool p_allow_greater, bool p_allow_lesser) { +void EditorPropertyInteger::setup(int64_t p_min, int64_t p_max, int64_t p_step, bool p_allow_greater, bool p_allow_lesser) { spin->set_min(p_min); spin->set_max(p_max); spin->set_step(p_step); diff --git a/editor/editor_properties.h b/editor/editor_properties.h index 4c7358597e..1853a6b6e1 100644 --- a/editor/editor_properties.h +++ b/editor/editor_properties.h @@ -263,14 +263,14 @@ class EditorPropertyInteger : public EditorProperty { GDCLASS(EditorPropertyInteger, EditorProperty); EditorSpinSlider *spin; bool setting; - void _value_changed(double p_val); + void _value_changed(int64_t p_val); protected: static void _bind_methods(); public: virtual void update_property(); - void setup(int p_min, int p_max, int p_step, bool p_allow_greater, bool p_allow_lesser); + void setup(int64_t p_min, int64_t p_max, int64_t p_step, bool p_allow_greater, bool p_allow_lesser); EditorPropertyInteger(); }; diff --git a/editor/editor_resource_preview.cpp b/editor/editor_resource_preview.cpp index 9d31e26086..1f2a02c9a0 100644 --- a/editor/editor_resource_preview.cpp +++ b/editor/editor_resource_preview.cpp @@ -215,7 +215,6 @@ void EditorResourcePreview::_generate_preview(Ref<ImageTexture> &r_texture, Ref< void EditorResourcePreview::_thread() { -#ifndef SERVER_ENABLED exited = false; while (!exit) { @@ -298,7 +297,7 @@ void EditorResourcePreview::_thread() { if (!f) { // Not returning as this would leave the thread hanging and would require // some proper cleanup/disabling of resource preview generation. - ERR_PRINTS("Cannot create file '" + file + "'. Check user write permissions."); + ERR_PRINT("Cannot create file '" + file + "'. Check user write permissions."); } else { f->store_line(itos(thumbnail_size)); f->store_line(itos(has_small_texture)); @@ -349,7 +348,6 @@ void EditorResourcePreview::_thread() { preview_mutex->unlock(); } } -#endif exited = true; } diff --git a/editor/editor_sectioned_inspector.cpp b/editor/editor_sectioned_inspector.cpp index 28825b45e1..2090c12c91 100644 --- a/editor/editor_sectioned_inspector.cpp +++ b/editor/editor_sectioned_inspector.cpp @@ -245,6 +245,9 @@ void SectionedInspector::update_category_list() { if (pi.name.find(":") != -1 || pi.name == "script" || pi.name == "resource_name" || pi.name == "resource_path" || pi.name == "resource_local_to_scene" || pi.name.begins_with("_global_script")) continue; + if (!filter.empty() && !filter.is_subsequence_ofi(pi.name) && !filter.is_subsequence_ofi(pi.name.replace("/", " ").capitalize())) + continue; + int sp = pi.name.find("/"); if (sp == -1) pi.name = "global/" + pi.name; @@ -252,9 +255,6 @@ void SectionedInspector::update_category_list() { Vector<String> sectionarr = pi.name.split("/"); String metasection; - if (!filter.empty() && !filter.is_subsequence_ofi(sectionarr[sectionarr.size() - 1].capitalize())) - continue; - int sc = MIN(2, sectionarr.size() - 1); for (int i = 0; i < sc; i++) { diff --git a/editor/editor_settings.cpp b/editor/editor_settings.cpp index 92e3f61ca5..715ce6bea7 100644 --- a/editor/editor_settings.cpp +++ b/editor/editor_settings.cpp @@ -148,7 +148,7 @@ bool EditorSettings::_get(const StringName &p_name, Variant &r_ret) const { const VariantContainer *v = props.getptr(p_name); if (!v) { - WARN_PRINTS("EditorSettings::_get - Property not found: " + String(p_name)); + WARN_PRINT("EditorSettings::_get - Property not found: " + String(p_name)); return false; } r_ret = v->variant; @@ -794,13 +794,13 @@ void EditorSettings::create() { self_contained = true; Error err = extra_config->load(exe_path + "/._sc_"); if (err != OK) { - ERR_PRINTS("Can't load config from path '" + exe_path + "/._sc_'."); + ERR_PRINT("Can't load config from path '" + exe_path + "/._sc_'."); } } else if (d->file_exists(exe_path + "/_sc_")) { self_contained = true; Error err = extra_config->load(exe_path + "/_sc_"); if (err != OK) { - ERR_PRINTS("Can't load config from path '" + exe_path + "/_sc_'."); + ERR_PRINT("Can't load config from path '" + exe_path + "/_sc_'."); } } memdelete(d); @@ -1056,7 +1056,7 @@ void EditorSettings::save() { Error err = ResourceSaver::save(singleton->config_file_path, singleton); if (err != OK) { - ERR_PRINTS("Error saving editor settings to " + singleton->config_file_path); + ERR_PRINT("Error saving editor settings to " + singleton->config_file_path); } else { print_verbose("EditorSettings: Save OK!"); } diff --git a/editor/editor_themes.cpp b/editor/editor_themes.cpp index 2cacc767c8..8037045e77 100644 --- a/editor/editor_themes.cpp +++ b/editor/editor_themes.cpp @@ -89,7 +89,11 @@ Ref<ImageTexture> editor_generate_icon(int p_index, bool p_convert_color, float // dumb gizmo check bool is_gizmo = String(editor_icons_names[p_index]).begins_with("Gizmo"); - ImageLoaderSVG::create_image_from_string(img, editor_icons_sources[p_index], p_scale, true, p_convert_color); + // Upsample icon generation only if the editor scale isn't an integer multiplier. + // Generating upsampled icons is slower, and the benefit is hardly visible + // with integer editor scales. + const bool upsample = !Math::is_equal_approx(Math::round(p_scale), p_scale); + ImageLoaderSVG::create_image_from_string(img, editor_icons_sources[p_index], p_scale, upsample, p_convert_color); if ((p_scale - (float)((int)p_scale)) > 0.0 || is_gizmo || p_force_filter) icon->create_from_image(img); // in this case filter really helps @@ -106,7 +110,15 @@ Ref<ImageTexture> editor_generate_icon(int p_index, bool p_convert_color, float void editor_register_and_generate_icons(Ref<Theme> p_theme, bool p_dark_theme = true, int p_thumb_size = 32, bool p_only_thumbs = false) { #ifdef SVG_ENABLED + // The default icon theme is designed to be used for a dark theme. + // This dictionary stores color codes to convert to other colors + // for better readability on a light theme. Dictionary dark_icon_color_dictionary; + + // The names of the icons to never convert, even if one of their colors + // are contained in the dictionary above. + Set<StringName> exceptions; + if (!p_dark_theme) { // convert color: FROM TO ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#e0e0e0", "#5a5a5a"); // common icon color @@ -172,9 +184,31 @@ void editor_register_and_generate_icons(Ref<Theme> p_theme, bool p_dark_theme = ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#69ec9a", "#2ce573"); // VS rid ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#79f3e8", "#12d5c3"); // VS object ADD_CONVERT_COLOR(dark_icon_color_dictionary, "#77edb1", "#57e99f"); // VS dict + + exceptions.insert("EditorPivot"); + exceptions.insert("EditorHandle"); + exceptions.insert("Editor3DHandle"); + exceptions.insert("Godot"); + exceptions.insert("PanoramaSky"); + exceptions.insert("ProceduralSky"); + exceptions.insert("EditorControlAnchor"); + exceptions.insert("DefaultProjectIcon"); + exceptions.insert("GuiCloseCustomizable"); + exceptions.insert("GuiGraphNodePort"); + exceptions.insert("GuiResizer"); + exceptions.insert("ZoomMore"); + exceptions.insert("ZoomLess"); + exceptions.insert("ZoomReset"); + exceptions.insert("LockViewport"); + exceptions.insert("GroupViewport"); + exceptions.insert("StatusError"); + exceptions.insert("StatusSuccess"); + exceptions.insert("StatusWarning"); + exceptions.insert("NodeWarning"); + exceptions.insert("OverbrightIndicator"); } - // these ones should be converted even if we are using a dark theme + // These ones should be converted even if we are using a dark theme. const Color error_color = p_theme->get_color("error_color", "Editor"); const Color success_color = p_theme->get_color("success_color", "Editor"); const Color warning_color = p_theme->get_color("warning_color", "Editor"); @@ -182,65 +216,44 @@ void editor_register_and_generate_icons(Ref<Theme> p_theme, bool p_dark_theme = dark_icon_color_dictionary[Color::html("#45ff8b")] = success_color; dark_icon_color_dictionary[Color::html("#dbab09")] = warning_color; - List<String> exceptions; - exceptions.push_back("EditorPivot"); - exceptions.push_back("EditorHandle"); - exceptions.push_back("Editor3DHandle"); - exceptions.push_back("Godot"); - exceptions.push_back("PanoramaSky"); - exceptions.push_back("ProceduralSky"); - exceptions.push_back("EditorControlAnchor"); - exceptions.push_back("DefaultProjectIcon"); - exceptions.push_back("GuiCloseCustomizable"); - exceptions.push_back("GuiGraphNodePort"); - exceptions.push_back("GuiResizer"); - exceptions.push_back("ZoomMore"); - exceptions.push_back("ZoomLess"); - exceptions.push_back("ZoomReset"); - exceptions.push_back("LockViewport"); - exceptions.push_back("GroupViewport"); - exceptions.push_back("StatusError"); - exceptions.push_back("StatusSuccess"); - exceptions.push_back("StatusWarning"); - exceptions.push_back("NodeWarning"); - exceptions.push_back("OverbrightIndicator"); - ImageLoaderSVG::set_convert_colors(&dark_icon_color_dictionary); - // generate icons - if (!p_only_thumbs) + // Generate icons. + if (!p_only_thumbs) { for (int i = 0; i < editor_icons_count; i++) { - List<String>::Element *is_exception = exceptions.find(editor_icons_names[i]); - if (is_exception) exceptions.erase(is_exception); - Ref<ImageTexture> icon = editor_generate_icon(i, !is_exception); + const int is_exception = exceptions.has(editor_icons_names[i]); + const Ref<ImageTexture> icon = editor_generate_icon(i, !is_exception); + p_theme->set_icon(editor_icons_names[i], "EditorIcons", icon); } + } - // generate thumb files with the given thumb size - bool force_filter = p_thumb_size != 64 && p_thumb_size != 32; // we don't need filter with original resolution + // Generate thumbnail icons with the given thumbnail size. + // We don't need filtering when generating at one of the default resolutions. + const bool force_filter = p_thumb_size != 64 && p_thumb_size != 32; if (p_thumb_size >= 64) { - float scale = (float)p_thumb_size / 64.0 * EDSCALE; + const float scale = (float)p_thumb_size / 64.0 * EDSCALE; for (int i = 0; i < editor_bg_thumbs_count; i++) { - int index = editor_bg_thumbs_indices[i]; - List<String>::Element *is_exception = exceptions.find(editor_icons_names[index]); - if (is_exception) exceptions.erase(is_exception); - Ref<ImageTexture> icon = editor_generate_icon(index, !p_dark_theme && !is_exception, scale, force_filter); + const int index = editor_bg_thumbs_indices[i]; + const int is_exception = exceptions.has(editor_icons_names[index]); + const Ref<ImageTexture> icon = editor_generate_icon(index, !p_dark_theme && !is_exception, scale, force_filter); + p_theme->set_icon(editor_icons_names[index], "EditorIcons", icon); } } else { - float scale = (float)p_thumb_size / 32.0 * EDSCALE; + const float scale = (float)p_thumb_size / 32.0 * EDSCALE; for (int i = 0; i < editor_md_thumbs_count; i++) { - int index = editor_md_thumbs_indices[i]; - List<String>::Element *is_exception = exceptions.find(editor_icons_names[index]); - if (is_exception) exceptions.erase(is_exception); - Ref<ImageTexture> icon = editor_generate_icon(index, !p_dark_theme && !is_exception, scale, force_filter); + const int index = editor_md_thumbs_indices[i]; + const bool is_exception = exceptions.has(editor_icons_names[index]); + const Ref<ImageTexture> icon = editor_generate_icon(index, !p_dark_theme && !is_exception, scale, force_filter); + p_theme->set_icon(editor_icons_names[index], "EditorIcons", icon); } } ImageLoaderSVG::set_convert_colors(NULL); #else - print_line("SVG support disabled, editor icons won't be rendered."); + WARN_PRINT("SVG support disabled, editor icons won't be rendered."); #endif } @@ -1218,7 +1231,7 @@ Ref<Theme> create_editor_theme(const Ref<Theme> p_theme) { Ref<Theme> create_custom_theme(const Ref<Theme> p_theme) { Ref<Theme> theme; - String custom_theme = EditorSettings::get_singleton()->get("interface/theme/custom_theme"); + const String custom_theme = EditorSettings::get_singleton()->get("interface/theme/custom_theme"); if (custom_theme != "") { theme = ResourceLoader::load(custom_theme); } diff --git a/editor/editor_vcs_interface.cpp b/editor/editor_vcs_interface.cpp index 0562c3ba43..c420cf44e7 100644 --- a/editor/editor_vcs_interface.cpp +++ b/editor/editor_vcs_interface.cpp @@ -63,7 +63,7 @@ void EditorVCSInterface::_bind_methods() { bool EditorVCSInterface::_initialize(String p_project_root_path) { - WARN_PRINT("Selected VCS addon does not implement an initialization function. This warning will be suppressed.") + WARN_PRINT("Selected VCS addon does not implement an initialization function. This warning will be suppressed."); return true; } diff --git a/editor/export_template_manager.cpp b/editor/export_template_manager.cpp index cb636f8cdc..7ed6688154 100644 --- a/editor/export_template_manager.cpp +++ b/editor/export_template_manager.cpp @@ -638,7 +638,7 @@ Error ExportTemplateManager::install_android_template() { FileAccess::set_unix_permissions(to_write, (info.external_fa >> 16) & 0x01FF); #endif } else { - ERR_PRINTS("Can't uncompress file: " + to_write); + ERR_PRINT("Can't uncompress file: " + to_write); } } diff --git a/editor/filesystem_dock.cpp b/editor/filesystem_dock.cpp index 93e9cc58fb..5041441ac3 100644 --- a/editor/filesystem_dock.cpp +++ b/editor/filesystem_dock.cpp @@ -140,6 +140,7 @@ bool FileSystemDock::_create_tree(TreeItem *p_parent, EditorFileSystemDirectory subdirectory_item->set_collapsed(false); } else if (dname != "res://") { subdirectory_item->get_parent()->remove_child(subdirectory_item); + memdelete(subdirectory_item); } } @@ -1412,17 +1413,13 @@ void FileSystemDock::_move_operation_confirm(const String &p_to_path, bool overw if (!can_move) { // Ask to do something. overwrite_dialog->popup_centered_minsize(); - overwrite_dialog->grab_focus(); return; } } // Check groups. for (int i = 0; i < to_move.size(); i++) { - - print_line("is group: " + to_move[i].path + ": " + itos(EditorFileSystem::get_singleton()->is_group_file(to_move[i].path))); if (to_move[i].is_file && EditorFileSystem::get_singleton()->is_group_file(to_move[i].path)) { - print_line("move to: " + p_to_path.plus_file(to_move[i].path.get_file())); EditorFileSystem::get_singleton()->move_group_file(to_move[i].path, p_to_path.plus_file(to_move[i].path.get_file())); } } @@ -1441,7 +1438,7 @@ void FileSystemDock::_move_operation_confirm(const String &p_to_path, bool overw if (is_moved) { int current_tab = editor->get_current_tab(); - _save_scenes_after_move(file_renames); //save scenes before updating + _save_scenes_after_move(file_renames); // Save scenes before updating. _update_dependencies_after_move(file_renames); _update_resource_paths_after_move(file_renames); _update_project_settings_after_move(file_renames); @@ -1947,7 +1944,7 @@ bool FileSystemDock::can_drop_data_fw(const Point2 &p_point, const Variant &p_da return false; // Attempting to move a folder into itself will fail later, - // rather than bring up a message don't try to do it in the first place + // rather than bring up a message don't try to do it in the first place. to_dir = to_dir.ends_with("/") ? to_dir : (to_dir + "/"); Vector<String> fnames = drag_data["files"]; for (int i = 0; i < fnames.size(); ++i) { @@ -2049,11 +2046,15 @@ void FileSystemDock::drop_data_fw(const Point2 &p_point, const Variant &p_data, Vector<String> fnames = drag_data["files"]; to_move.clear(); for (int i = 0; i < fnames.size(); i++) { - to_move.push_back(FileOrFolder(fnames[i], !fnames[i].ends_with("/"))); + if (fnames[i].get_base_dir() != to_dir) { + to_move.push_back(FileOrFolder(fnames[i], !fnames[i].ends_with("/"))); + } + } + if (!to_move.empty()) { + _move_operation_confirm(to_dir); } - _move_operation_confirm(to_dir); } else if (favorite) { - // Add the files from favorites + // Add the files from favorites. Vector<String> fnames = drag_data["files"]; Vector<String> favorites = EditorSettings::get_singleton()->get_favorites(); for (int i = 0; i < fnames.size(); i++) { @@ -2102,6 +2103,10 @@ void FileSystemDock::_get_drag_target_folder(String &target, bool &target_favori // We drop on a folder. target = fpath; return; + } else { + // We drop on the folder that the target file is in. + target = fpath.get_base_dir(); + return; } } else { if (ti->get_parent() != tree->get_root()->get_children()) { diff --git a/editor/find_in_files.cpp b/editor/find_in_files.cpp index 86a4a9ef47..4ab90ad3e4 100644 --- a/editor/find_in_files.cpp +++ b/editor/find_in_files.cpp @@ -828,8 +828,8 @@ void FindInFilesPanel::apply_replaces_in_file(String fpath, const Vector<Result> // If there are unsaved changes, the user will be asked on focus, // however that means either losing changes or losing replaces. - FileAccess *f = FileAccess::open(fpath, FileAccess::READ); - ERR_FAIL_COND_MSG(f == NULL, "Cannot open file from path '" + fpath + "'."); + FileAccessRef f = FileAccess::open(fpath, FileAccess::READ); + ERR_FAIL_COND_MSG(!f, "Cannot open file from path '" + fpath + "'."); String buffer; int current_line = 1; diff --git a/editor/icons/icon_audio_stream_o_g_g_vorbis.svg b/editor/icons/icon_audio_stream_o_g_g_vorbis.svg new file mode 100644 index 0000000000..a8d6fb6bf1 --- /dev/null +++ b/editor/icons/icon_audio_stream_o_g_g_vorbis.svg @@ -0,0 +1 @@ +<svg height="16" viewBox="0 0 16 16" width="16" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><linearGradient id="a" gradientUnits="userSpaceOnUse" x1="8" x2="8" y1="1" y2="15"><stop offset="0" stop-color="#ff7a7a"/><stop offset=".5" stop-color="#e1dc7a"/><stop offset="1" stop-color="#66ff9e"/></linearGradient><path d="m11.971 1.002c-.08326.00207-.16593.014541-.24609.037109l-7 2c-.42881.12287-.7244.51487-.72461.96094v5.5508c-.16454-.033679-.33205-.050692-.5-.050781-1.3807 0-2.5 1.1193-2.5 2.5-.00000475 1.3807 1.1193 2.5 2.5 2.5 1.3456-.0013 2.4488-1.0674 2.4961-2.4121.0025906-.029226.003894-.058551.0039062-.087891v-7.2441l5-1.4277v3.1719l2-1v-3.5c-.000916-.56314-.4664-1.0145-1.0293-.99805zm-1.4707 6.998c-.277 0-.5.223-.5.5v5c0 .277.223.5.5.5s.5-.223.5-.5v-5c0-.277-.223-.5-.5-.5zm2 1c-.277 0-.5.223-.5.5v3c0 .277.223.5.5.5s.5-.223.5-.5v-3c0-.277-.223-.5-.5-.5zm-4 1c-.277 0-.5.223-.5.5v1c0 .277.223.5.5.5s.5-.223.5-.5v-1c0-.277-.223-.5-.5-.5zm6 0c-.277 0-.5.223-.5.5v1c0 .277.223.5.5.5s.5-.223.5-.5v-1c0-.277-.223-.5-.5-.5z" fill="url(#a)"/></svg>
\ No newline at end of file diff --git a/editor/icons/icon_crosshair.svg b/editor/icons/icon_crosshair.svg new file mode 100644 index 0000000000..b6fa5ec654 --- /dev/null +++ b/editor/icons/icon_crosshair.svg @@ -0,0 +1 @@ +<svg height="16" viewBox="0 0 16 16" width="16" xmlns="http://www.w3.org/2000/svg"><path d="m6 1v5h-5v1 3h5v5h4v-5h5v-4h-5v-5z" fill-opacity=".627451"/><path d="m2 7v2l5.0000803.0000197-.0000803 4.9999803h2l-.0000803-4.9999803 5.0000803-.0000197v-2l-5.0000803.0001803.0000803-5.0001803h-2l.0000803 5.0001803z" fill="#fefefe" fill-opacity=".862745"/></svg>
\ No newline at end of file diff --git a/editor/import/editor_import_collada.cpp b/editor/import/editor_import_collada.cpp index b3f97714ae..e2d8dc8962 100644 --- a/editor/import/editor_import_collada.cpp +++ b/editor/import/editor_import_collada.cpp @@ -892,7 +892,7 @@ Error ColladaImport::_create_mesh_surfaces(bool p_optimize, Ref<ArrayMesh> &p_me material = material_cache[target]; } else if (p.material != "") { - WARN_PRINTS("Collada: Unreferenced material in geometry instance: " + p.material); + WARN_PRINT("Collada: Unreferenced material in geometry instance: " + p.material); } } @@ -1210,7 +1210,7 @@ Error ColladaImport::_create_resources(Collada::Node *p_node, bool p_use_compres mesh_cache[meshid] = mesh; } else { - WARN_PRINTS("Collada: Will not import geometry: " + meshid); + WARN_PRINT("Collada: Will not import geometry: " + meshid); } } @@ -1237,7 +1237,7 @@ Error ColladaImport::_create_resources(Collada::Node *p_node, bool p_use_compres mi->set_surface_material(i, material); } else if (matname != "") { - WARN_PRINTS("Collada: Unreferenced material in geometry instance: " + matname); + WARN_PRINT("Collada: Unreferenced material in geometry instance: " + matname); } } } @@ -1408,7 +1408,7 @@ void ColladaImport::create_animations(bool p_make_tracks_in_all_bones, bool p_im node = node_name_map[at.target]; } else { - WARN_PRINTS("Collada: Couldn't find node: " + at.target); + WARN_PRINT("Collada: Couldn't find node: " + at.target); continue; } } else { @@ -1588,7 +1588,7 @@ void ColladaImport::create_animation(int p_clip, bool p_make_tracks_in_all_bones } if (xform_idx == -1) { - WARN_PRINTS("Collada: Couldn't find matching node " + at.target + " xform for track " + at.param + "."); + WARN_PRINT("Collada: Couldn't find matching node " + at.target + " xform for track " + at.param + "."); continue; } @@ -1666,7 +1666,7 @@ void ColladaImport::create_animation(int p_clip, bool p_make_tracks_in_all_bones Collada::Node *cn = collada.state.scene_map[E->key()]; if (cn->ignore_anim) { - WARN_PRINTS("Collada: Ignoring animation on node: " + path); + WARN_PRINT("Collada: Ignoring animation on node: " + path); continue; } @@ -1735,7 +1735,7 @@ void ColladaImport::create_animation(int p_clip, bool p_make_tracks_in_all_bones //matrix WARN_PRINT("Collada: Value keys for matrices not supported."); } else { - WARN_PRINTS("Collada: Unexpected amount of value keys: " + itos(data.size())); + WARN_PRINT("Collada: Unexpected amount of value keys: " + itos(data.size())); } animation->track_insert_key(track, time, value); diff --git a/editor/import/editor_scene_importer_gltf.cpp b/editor/import/editor_scene_importer_gltf.cpp index 7de6db7add..fc9c877ac7 100644 --- a/editor/import/editor_scene_importer_gltf.cpp +++ b/editor/import/editor_scene_importer_gltf.cpp @@ -233,7 +233,7 @@ Error EditorSceneImporterGLTF::_parse_scenes(GLTFState &state) { if (state.json.has("scene")) { loaded_scene = state.json["scene"]; } else { - WARN_PRINT("The load-time scene is not defined in the glTF2 file. Picking the first scene.") + WARN_PRINT("The load-time scene is not defined in the glTF2 file. Picking the first scene."); } if (scenes.size()) { @@ -1302,6 +1302,8 @@ Error EditorSceneImporterGLTF::_parse_images(GLTFState &state, const String &p_b if (mimetype.findn("png") != -1) { //is a png + ERR_FAIL_COND_V(Image::_png_mem_loader_func == NULL, ERR_UNAVAILABLE); + const Ref<Image> img = Image::_png_mem_loader_func(data_ptr, data_size); ERR_FAIL_COND_V(img.is_null(), ERR_FILE_CORRUPT); @@ -1316,6 +1318,8 @@ Error EditorSceneImporterGLTF::_parse_images(GLTFState &state, const String &p_b if (mimetype.findn("jpeg") != -1) { //is a jpg + ERR_FAIL_COND_V(Image::_jpg_mem_loader_func == NULL, ERR_UNAVAILABLE); + const Ref<Image> img = Image::_jpg_mem_loader_func(data_ptr, data_size); ERR_FAIL_COND_V(img.is_null(), ERR_FILE_CORRUPT); @@ -2434,7 +2438,7 @@ Error EditorSceneImporterGLTF::_parse_animations(GLTFState &state) { track->weight_tracks.write[k] = cf; } } else { - WARN_PRINTS("Invalid path '" + path + "'."); + WARN_PRINT("Invalid path '" + path + "'."); } } @@ -2630,22 +2634,22 @@ template <> struct EditorSceneImporterGLTFInterpolate<Quat> { Quat lerp(const Quat &a, const Quat &b, const float c) const { - ERR_FAIL_COND_V(!a.is_normalized(), Quat()); - ERR_FAIL_COND_V(!b.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!a.is_normalized(), Quat(), "The quaternion \"a\" must be normalized."); + ERR_FAIL_COND_V_MSG(!b.is_normalized(), Quat(), "The quaternion \"b\" must be normalized."); return a.slerp(b, c).normalized(); } Quat catmull_rom(const Quat &p0, const Quat &p1, const Quat &p2, const Quat &p3, const float c) { - ERR_FAIL_COND_V(!p1.is_normalized(), Quat()); - ERR_FAIL_COND_V(!p2.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!p1.is_normalized(), Quat(), "The quaternion \"p1\" must be normalized."); + ERR_FAIL_COND_V_MSG(!p2.is_normalized(), Quat(), "The quaternion \"p2\" must be normalized."); return p1.slerp(p2, c).normalized(); } Quat bezier(const Quat start, const Quat control_1, const Quat control_2, const Quat end, const float t) { - ERR_FAIL_COND_V(!start.is_normalized(), Quat()); - ERR_FAIL_COND_V(!end.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!start.is_normalized(), Quat(), "The start quaternion must be normalized."); + ERR_FAIL_COND_V_MSG(!end.is_normalized(), Quat(), "The end quaternion must be normalized."); return start.slerp(end, t).normalized(); } diff --git a/editor/import/resource_importer_obj.cpp b/editor/import/resource_importer_obj.cpp index b1ed59a2db..bdd6a197f8 100644 --- a/editor/import/resource_importer_obj.cpp +++ b/editor/import/resource_importer_obj.cpp @@ -63,7 +63,7 @@ static Error _parse_material_library(const String &p_path, Map<String, Ref<Spati material_map[current_name] = current; } else if (l.begins_with("Ka ")) { //uv - WARN_PRINTS("OBJ: Ambient light for material '" + current_name + "' is ignored in PBR"); + WARN_PRINT("OBJ: Ambient light for material '" + current_name + "' is ignored in PBR"); } else if (l.begins_with("Kd ")) { //normal @@ -119,7 +119,7 @@ static Error _parse_material_library(const String &p_path, Map<String, Ref<Spati } else if (l.begins_with("map_Ka ")) { //uv - WARN_PRINTS("OBJ: Ambient light texture for material '" + current_name + "' is ignored in PBR"); + WARN_PRINT("OBJ: Ambient light texture for material '" + current_name + "' is ignored in PBR"); } else if (l.begins_with("map_Kd ")) { //normal diff --git a/editor/import/resource_importer_scene.cpp b/editor/import/resource_importer_scene.cpp index cab317990e..0774d0b5dc 100644 --- a/editor/import/resource_importer_scene.cpp +++ b/editor/import/resource_importer_scene.cpp @@ -32,18 +32,15 @@ #include "core/io/resource_saver.h" #include "editor/editor_node.h" -#include "scene/resources/packed_scene.h" - #include "scene/3d/collision_shape.h" #include "scene/3d/mesh_instance.h" #include "scene/3d/navigation.h" #include "scene/3d/physics_body.h" -#include "scene/3d/portal.h" -#include "scene/3d/room_instance.h" #include "scene/3d/vehicle_body.h" #include "scene/animation/animation_player.h" #include "scene/resources/animation.h" #include "scene/resources/box_shape.h" +#include "scene/resources/packed_scene.h" #include "scene/resources/plane_shape.h" #include "scene/resources/ray_shape.h" #include "scene/resources/resource_format_text.h" diff --git a/editor/inspector_dock.cpp b/editor/inspector_dock.cpp index 2be3464d30..b65482cc6b 100644 --- a/editor/inspector_dock.cpp +++ b/editor/inspector_dock.cpp @@ -584,6 +584,7 @@ InspectorDock::InspectorDock(EditorNode *p_editor, EditorData &p_editor_data) { add_child(warning); warning->set_text(TTR("Changes may be lost!")); warning->set_icon(get_icon("NodeWarning", "EditorIcons")); + warning->set_clip_text(true); warning->hide(); warning->connect("pressed", this, "_warning_pressed"); diff --git a/editor/node_dock.cpp b/editor/node_dock.cpp index 20b8b3f5cb..c53c5f330b 100644 --- a/editor/node_dock.cpp +++ b/editor/node_dock.cpp @@ -105,6 +105,7 @@ NodeDock::NodeDock() { connections_button->set_toggle_mode(true); connections_button->set_pressed(true); connections_button->set_h_size_flags(SIZE_EXPAND_FILL); + connections_button->set_clip_text(true); mode_hb->add_child(connections_button); connections_button->connect("pressed", this, "show_connections"); @@ -113,6 +114,7 @@ NodeDock::NodeDock() { groups_button->set_toggle_mode(true); groups_button->set_pressed(false); groups_button->set_h_size_flags(SIZE_EXPAND_FILL); + groups_button->set_clip_text(true); mode_hb->add_child(groups_button); groups_button->connect("pressed", this, "show_groups"); diff --git a/editor/plugin_config_dialog.cpp b/editor/plugin_config_dialog.cpp index 28667abe77..07b87633a9 100644 --- a/editor/plugin_config_dialog.cpp +++ b/editor/plugin_config_dialog.cpp @@ -77,16 +77,19 @@ void PluginConfigDialog::_on_confirmed() { if (lang_name == GDScriptLanguage::get_singleton()->get_name()) { // Hard-coded GDScript template to keep usability until we use script templates. - Ref<GDScript> gdscript = memnew(GDScript); + Ref<Script> gdscript = memnew(GDScript); gdscript->set_source_code( "tool\n" "extends EditorPlugin\n" "\n" - "func _enter_tree():\n" - "\tpass\n" "\n" - "func _exit_tree():\n" - "\tpass\n"); + "func _enter_tree()%VOID_RETURN%:\n" + "%TS%pass\n" + "\n" + "\n" + "func _exit_tree()%VOID_RETURN%:\n" + "%TS%pass\n"); + GDScriptLanguage::get_singleton()->make_template("", "", gdscript); String script_path = path.plus_file(script_edit->get_text()); gdscript->set_path(script_path); ResourceSaver::save(script_path, gdscript); diff --git a/editor/plugins/animation_blend_tree_editor_plugin.cpp b/editor/plugins/animation_blend_tree_editor_plugin.cpp index def3f4bfec..2de224c043 100644 --- a/editor/plugins/animation_blend_tree_editor_plugin.cpp +++ b/editor/plugins/animation_blend_tree_editor_plugin.cpp @@ -147,7 +147,7 @@ void AnimationNodeBlendTreeEditor::_update_graph() { node->add_child(name); node->set_slot(0, false, 0, Color(), true, 0, get_color("font_color", "Label")); name->connect("text_entered", this, "_node_renamed", varray(agnode)); - name->connect("focus_exited", this, "_node_renamed_focus_out", varray(name, agnode)); + name->connect("focus_exited", this, "_node_renamed_focus_out", varray(name, agnode), CONNECT_DEFERRED); base = 1; node->set_show_close_button(true); node->connect("close_request", this, "_delete_request", varray(E->get()), CONNECT_DEFERRED); diff --git a/editor/plugins/animation_player_editor_plugin.cpp b/editor/plugins/animation_player_editor_plugin.cpp index 5b41da6e8e..5e69ce4e69 100644 --- a/editor/plugins/animation_player_editor_plugin.cpp +++ b/editor/plugins/animation_player_editor_plugin.cpp @@ -997,9 +997,9 @@ void AnimationPlayerEditor::_animation_duplicate() { String new_name = current; while (player->has_animation(new_name)) { - new_name = new_name + " (copy)"; } + new_anim->set_name(new_name); undo_redo->create_action(TTR("Duplicate Animation")); undo_redo->add_do_method(player, "add_animation", new_name, new_anim); diff --git a/editor/plugins/animation_tree_player_editor_plugin.cpp b/editor/plugins/animation_tree_player_editor_plugin.cpp index a85def5c6d..2b365feec5 100644 --- a/editor/plugins/animation_tree_player_editor_plugin.cpp +++ b/editor/plugins/animation_tree_player_editor_plugin.cpp @@ -34,6 +34,7 @@ #include "core/os/input.h" #include "core/os/keyboard.h" #include "core/project_settings.h" +#include "editor/editor_scale.h" #include "scene/gui/menu_button.h" #include "scene/gui/panel.h" #include "scene/main/viewport.h" @@ -923,17 +924,18 @@ void AnimationTreePlayerEditor::_notification(int p_what) { _draw_cos_line(source, dest, col); } + const Ref<Font> f = get_font("font", "Label"); + const Point2 status_offset = Point2(5, 25) * EDSCALE + Point2(0, f->get_ascent()); + switch (anim_tree->get_last_error()) { case AnimationTreePlayer::CONNECT_OK: { - Ref<Font> f = get_font("font", "Label"); - f->draw(get_canvas_item(), Point2(5, 25 + f->get_ascent()), TTR("Animation tree is valid."), Color(0, 1, 0.6, 0.8)); + f->draw(get_canvas_item(), status_offset, TTR("Animation tree is valid."), Color(0, 1, 0.6, 0.8)); } break; default: { - Ref<Font> f = get_font("font", "Label"); - f->draw(get_canvas_item(), Point2(5, 25 + f->get_ascent()), TTR("Animation tree is invalid."), Color(1, 0.6, 0.0, 0.8)); + f->draw(get_canvas_item(), status_offset, TTR("Animation tree is invalid."), Color(1, 0.6, 0.0, 0.8)); } break; } @@ -1300,7 +1302,7 @@ AnimationTreePlayerEditor::AnimationTreePlayerEditor() { p->connect("id_pressed", this, "_add_menu_item"); play_button = memnew(Button); - play_button->set_position(Point2(25, 0)); + play_button->set_position(Point2(25, 0) * EDSCALE); play_button->set_size(Point2(25, 15)); add_child(play_button); play_button->set_toggle_mode(true); @@ -1439,7 +1441,7 @@ AnimationTreePlayerEditorPlugin::AnimationTreePlayerEditorPlugin(EditorNode *p_n editor = p_node; anim_tree_editor = memnew(AnimationTreePlayerEditor); - anim_tree_editor->set_custom_minimum_size(Size2(0, 300)); + anim_tree_editor->set_custom_minimum_size(Size2(0, 300) * EDSCALE); button = editor->add_bottom_panel_item(TTR("AnimationTree"), anim_tree_editor); button->hide(); diff --git a/editor/plugins/asset_library_editor_plugin.cpp b/editor/plugins/asset_library_editor_plugin.cpp index 09cfa3c564..2428bf82d4 100644 --- a/editor/plugins/asset_library_editor_plugin.cpp +++ b/editor/plugins/asset_library_editor_plugin.cpp @@ -160,7 +160,7 @@ void EditorAssetLibraryItemDescription::set_image(int p_type, int p_index, const Ref<Image> overlay = get_icon("PlayOverlay", "EditorIcons")->get_data(); Ref<Image> thumbnail = p_image->get_data(); thumbnail = thumbnail->duplicate(); - Point2 overlay_pos = Point2((thumbnail->get_width() - overlay->get_width() / 2) / 2, (thumbnail->get_height() - overlay->get_height() / 2) / 2); + Point2 overlay_pos = Point2((thumbnail->get_width() - overlay->get_width()) / 2, (thumbnail->get_height() - overlay->get_height()) / 2); // Overlay and thumbnail need the same format for `blend_rect` to work. thumbnail->convert(Image::FORMAT_RGBA8); @@ -433,7 +433,10 @@ void EditorAssetLibraryItemDownload::_notification(int p_what) { String::humanize_size(download->get_body_size()))); } else { // Total file size is unknown, so it cannot be displayed. - status->set_text(TTR("Downloading...")); + progress->set_modulate(Color(0, 0, 0, 0)); + status->set_text(vformat( + TTR("Downloading...") + " (%s)", + String::humanize_size(download->get_downloaded_bytes()))); } } @@ -724,9 +727,9 @@ void EditorAssetLibrary::_image_update(bool use_cache, bool final, const PoolByt uint8_t jpg_signature[3] = { 255, 216, 255 }; if (r.ptr()) { - if (memcmp(&r[0], &png_signature[0], 8) == 0) { + if ((memcmp(&r[0], &png_signature[0], 8) == 0) && Image::_png_mem_loader_func) { image->copy_internals_from(Image::_png_mem_loader_func(r.ptr(), len)); - } else if (memcmp(&r[0], &jpg_signature[0], 3) == 0) { + } else if ((memcmp(&r[0], &jpg_signature[0], 3) == 0) && Image::_jpg_mem_loader_func) { image->copy_internals_from(Image::_jpg_mem_loader_func(r.ptr(), len)); } } @@ -807,7 +810,7 @@ void EditorAssetLibrary::_image_request_completed(int p_status, int p_code, cons _image_update(p_code == HTTPClient::RESPONSE_NOT_MODIFIED, true, p_data, p_queue_id); } else { - WARN_PRINTS("Error getting image file from URL: " + image_queue[p_queue_id].image_url); + WARN_PRINT("Error getting image file from URL: " + image_queue[p_queue_id].image_url); Object *obj = ObjectDB::get_instance(image_queue[p_queue_id].target); if (obj) { obj->call("set_image", image_queue[p_queue_id].image_type, image_queue[p_queue_id].image_index, get_icon("FileBrokenBigThumb", "EditorIcons")); diff --git a/editor/plugins/canvas_item_editor_plugin.cpp b/editor/plugins/canvas_item_editor_plugin.cpp index 89e25ffcff..1d8f3a2bbd 100644 --- a/editor/plugins/canvas_item_editor_plugin.cpp +++ b/editor/plugins/canvas_item_editor_plugin.cpp @@ -1492,7 +1492,9 @@ bool CanvasItemEditor::_gui_input_rotate(const Ref<InputEvent> &p_event) { for (List<CanvasItem *>::Element *E = drag_selection.front(); E; E = E->next()) { CanvasItem *canvas_item = E->get(); drag_to = transform.affine_inverse().xform(m->get_position()); - canvas_item->_edit_set_rotation(snap_angle(canvas_item->_edit_get_rotation() + (drag_from - drag_rotation_center).angle_to(drag_to - drag_rotation_center), canvas_item->_edit_get_rotation())); + //Rotate the opposite way if the canvas item's compounded scale has an uneven number of negative elements + bool opposite = (canvas_item->get_global_transform().get_scale().sign().dot(canvas_item->get_transform().get_scale().sign()) == 0); + canvas_item->_edit_set_rotation(snap_angle(canvas_item->_edit_get_rotation() + (opposite ? -1 : 1) * (drag_from - drag_rotation_center).angle_to(drag_to - drag_rotation_center), canvas_item->_edit_get_rotation())); viewport->update(); } return true; @@ -1748,8 +1750,18 @@ bool CanvasItemEditor::_gui_input_resize(const Ref<InputEvent> &p_event) { Transform2D xform = canvas_item->get_global_transform_with_canvas().affine_inverse(); - Point2 drag_to_snapped_begin = snap_point(xform.affine_inverse().xform(current_begin) + (drag_to - drag_from), SNAP_NODE_ANCHORS | SNAP_NODE_PARENT | SNAP_OTHER_NODES | SNAP_GRID | SNAP_PIXEL, 0, canvas_item); - Point2 drag_to_snapped_end = snap_point(xform.affine_inverse().xform(current_end) + (drag_to - drag_from), SNAP_NODE_ANCHORS | SNAP_NODE_PARENT | SNAP_OTHER_NODES | SNAP_GRID | SNAP_PIXEL, 0, canvas_item); + Point2 drag_to_snapped_begin; + Point2 drag_to_snapped_end; + + // last call decides which snapping lines are drawn + if (drag_type == DRAG_LEFT || drag_type == DRAG_TOP || drag_type == DRAG_TOP_LEFT) { + drag_to_snapped_end = snap_point(xform.affine_inverse().xform(current_end) + (drag_to - drag_from), SNAP_NODE_ANCHORS | SNAP_NODE_PARENT | SNAP_OTHER_NODES | SNAP_GRID | SNAP_PIXEL, 0, canvas_item); + drag_to_snapped_begin = snap_point(xform.affine_inverse().xform(current_begin) + (drag_to - drag_from), SNAP_NODE_ANCHORS | SNAP_NODE_PARENT | SNAP_OTHER_NODES | SNAP_GRID | SNAP_PIXEL, 0, canvas_item); + } else { + drag_to_snapped_begin = snap_point(xform.affine_inverse().xform(current_begin) + (drag_to - drag_from), SNAP_NODE_ANCHORS | SNAP_NODE_PARENT | SNAP_OTHER_NODES | SNAP_GRID | SNAP_PIXEL, 0, canvas_item); + drag_to_snapped_end = snap_point(xform.affine_inverse().xform(current_end) + (drag_to - drag_from), SNAP_NODE_ANCHORS | SNAP_NODE_PARENT | SNAP_OTHER_NODES | SNAP_GRID | SNAP_PIXEL, 0, canvas_item); + } + Point2 drag_begin = xform.xform(drag_to_snapped_begin); Point2 drag_end = xform.xform(drag_to_snapped_end); @@ -2587,14 +2599,14 @@ void CanvasItemEditor::_draw_guides() { Color text_color = get_color("font_color", "Editor"); text_color.a = 0.5; if (drag_type == DRAG_DOUBLE_GUIDE || drag_type == DRAG_V_GUIDE) { - String str = vformat("%d px", xform.affine_inverse().xform(dragged_guide_pos).x); + String str = vformat("%d px", Math::round(xform.affine_inverse().xform(dragged_guide_pos).x)); Ref<Font> font = get_font("font", "Label"); Size2 text_size = font->get_string_size(str); viewport->draw_string(font, Point2(dragged_guide_pos.x + 10, RULER_WIDTH + text_size.y / 2 + 10), str, text_color); viewport->draw_line(Point2(dragged_guide_pos.x, 0), Point2(dragged_guide_pos.x, viewport->get_size().y), guide_color, Math::round(EDSCALE)); } if (drag_type == DRAG_DOUBLE_GUIDE || drag_type == DRAG_H_GUIDE) { - String str = vformat("%d px", xform.affine_inverse().xform(dragged_guide_pos).y); + String str = vformat("%d px", Math::round(xform.affine_inverse().xform(dragged_guide_pos).y)); Ref<Font> font = get_font("font", "Label"); Size2 text_size = font->get_string_size(str); viewport->draw_string(font, Point2(RULER_WIDTH + 10, dragged_guide_pos.y + text_size.y / 2 + 10), str, text_color); @@ -3838,6 +3850,7 @@ void CanvasItemEditor::_notification(int p_what) { key_scale_button->set_icon(get_icon("KeyScale", "EditorIcons")); key_insert_button->set_icon(get_icon("Key", "EditorIcons")); key_auto_insert_button->set_icon(get_icon("AutoKey", "EditorIcons")); + animation_menu->set_icon(get_icon("GuiTabMenu", "EditorIcons")); zoom_minus->set_icon(get_icon("ZoomLess", "EditorIcons")); zoom_plus->set_icon(get_icon("ZoomMore", "EditorIcons")); @@ -3987,29 +4000,21 @@ void CanvasItemEditor::_update_scrollbars() { updating_scroll = true; - // Move the zoom buttons + // Move the zoom buttons. Point2 controls_vb_begin = Point2(5, 5); controls_vb_begin += (show_rulers) ? Point2(RULER_WIDTH, RULER_WIDTH) : Point2(); controls_vb->set_begin(controls_vb_begin); - // Move and resize the scrollbars - Size2 size = viewport->get_size(); Size2 hmin = h_scroll->get_minimum_size(); Size2 vmin = v_scroll->get_minimum_size(); - v_scroll->set_begin(Point2(size.width - vmin.width, (show_rulers) ? RULER_WIDTH : 0)); - v_scroll->set_end(Point2(size.width, size.height)); - - h_scroll->set_begin(Point2((show_rulers) ? RULER_WIDTH : 0, size.height - hmin.height)); - h_scroll->set_end(Point2(size.width - vmin.width, size.height)); - - // Get the visible frame + // Get the visible frame. Size2 screen_rect = Size2(ProjectSettings::get_singleton()->get("display/window/size/width"), ProjectSettings::get_singleton()->get("display/window/size/height")); Rect2 local_rect = Rect2(Point2(), viewport->get_size() - Size2(vmin.width, hmin.height)); _queue_update_bone_list(); - // Calculate scrollable area + // Calculate scrollable area. Rect2 canvas_item_rect = Rect2(Point2(), screen_rect); if (editor->get_edited_scene()) { Rect2 content_rect = _get_encompassing_rect(editor->get_edited_scene()); @@ -4019,7 +4024,8 @@ void CanvasItemEditor::_update_scrollbars() { canvas_item_rect.size += screen_rect * 2; canvas_item_rect.position -= screen_rect; - // Constraints the view offset and updates the scrollbars + // Constraints the view offset and updates the scrollbars. + Size2 size = viewport->get_size(); Point2 begin = canvas_item_rect.position; Point2 end = canvas_item_rect.position + canvas_item_rect.size - local_rect.size / zoom; bool constrain_editor_view = bool(EditorSettings::get_singleton()->get("editors/2d/constrain_editor_view")); @@ -4066,7 +4072,13 @@ void CanvasItemEditor::_update_scrollbars() { h_scroll->set_page(screen_rect.x); } - // Calculate scrollable area + // Move and resize the scrollbars, avoiding overlap. + v_scroll->set_begin(Point2(size.width - vmin.width, (show_rulers) ? RULER_WIDTH : 0)); + v_scroll->set_end(Point2(size.width, size.height - (h_scroll->is_visible() ? hmin.height : 0))); + h_scroll->set_begin(Point2((show_rulers) ? RULER_WIDTH : 0, size.height - hmin.height)); + h_scroll->set_end(Point2(size.width - (v_scroll->is_visible() ? vmin.width : 0), size.height)); + + // Calculate scrollable area. v_scroll->set_value(view_offset.y); h_scroll->set_value(view_offset.x); @@ -4217,12 +4229,14 @@ void CanvasItemEditor::_zoom_on_position(float p_zoom, Point2 p_position) { void CanvasItemEditor::_update_zoom_label() { String zoom_text; // The zoom level displayed is relative to the editor scale - // (like in most image editors). + // (like in most image editors). Its lower bound is clamped to 1 as some people + // lower the editor scale to increase the available real estate, + // even if their display doesn't have a particularly low DPI. if (zoom >= 10) { // Don't show a decimal when the zoom level is higher than 1000 %. - zoom_text = rtos(Math::round((zoom / EDSCALE) * 100)) + " %"; + zoom_text = rtos(Math::round((zoom / MAX(1, EDSCALE)) * 100)) + " %"; } else { - zoom_text = rtos(Math::stepify((zoom / EDSCALE) * 100, 0.1)) + " %"; + zoom_text = rtos(Math::stepify((zoom / MAX(1, EDSCALE)) * 100, 0.1)) + " %"; } zoom_reset->set_text(zoom_text); @@ -4233,7 +4247,7 @@ void CanvasItemEditor::_button_zoom_minus() { } void CanvasItemEditor::_button_zoom_reset() { - _zoom_on_position(1.0 * EDSCALE, viewport_scrollable->get_size() / 2.0); + _zoom_on_position(1.0 * MAX(1, EDSCALE), viewport_scrollable->get_size() / 2.0); } void CanvasItemEditor::_button_zoom_plus() { @@ -4996,7 +5010,7 @@ Dictionary CanvasItemEditor::get_state() const { Dictionary state; // Take the editor scale into account. - state["zoom"] = zoom / EDSCALE; + state["zoom"] = zoom / MAX(1, EDSCALE); state["ofs"] = view_offset; state["grid_offset"] = grid_offset; state["grid_step"] = grid_step; @@ -5035,7 +5049,7 @@ void CanvasItemEditor::set_state(const Dictionary &p_state) { if (state.has("zoom")) { // Compensate the editor scale, so that the editor scale can be changed // and the zoom level will still be the same (relative to the editor scale). - zoom = float(p_state["zoom"]) * EDSCALE; + zoom = float(p_state["zoom"]) * MAX(1, EDSCALE); _update_zoom_label(); } @@ -5251,7 +5265,7 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) { show_rulers = true; show_guides = true; show_edit_locks = true; - zoom = 1.0 / EDSCALE; + zoom = 1.0 / MAX(1, EDSCALE); view_offset = Point2(-150 - RULER_WIDTH, -95 - RULER_WIDTH); previous_update_view_offset = view_offset; // Moves the view a little bit to the left so that (0,0) is visible. The values a relative to a 16/10 screen grid_offset = Point2(); @@ -5654,7 +5668,7 @@ CanvasItemEditor::CanvasItemEditor(EditorNode *p_editor) { animation_hb->add_child(key_auto_insert_button); animation_menu = memnew(MenuButton); - animation_menu->set_text(TTR("Animation")); + animation_menu->set_tooltip(TTR("Animation Key and Pose Options")); animation_hb->add_child(animation_menu); animation_menu->get_popup()->connect("id_pressed", this, "_popup_callback"); animation_menu->set_switch_on_hover(true); diff --git a/editor/plugins/polygon_2d_editor_plugin.cpp b/editor/plugins/polygon_2d_editor_plugin.cpp index de23193df0..35c0142d4b 100644 --- a/editor/plugins/polygon_2d_editor_plugin.cpp +++ b/editor/plugins/polygon_2d_editor_plugin.cpp @@ -92,6 +92,9 @@ void Polygon2DEditor::_notification(int p_what) { b_snap_grid->set_icon(get_icon("Grid", "EditorIcons")); b_snap_enable->set_icon(get_icon("SnapGrid", "EditorIcons")); uv_icon_zoom->set_texture(get_icon("Zoom", "EditorIcons")); + + uv_vscroll->set_anchors_and_margins_preset(PRESET_RIGHT_WIDE); + uv_hscroll->set_anchors_and_margins_preset(PRESET_BOTTOM_WIDE); } break; case NOTIFICATION_VISIBILITY_CHANGED: { @@ -1196,7 +1199,9 @@ void Polygon2DEditor::_uv_draw() { rect.position -= uv_edit_draw->get_size(); rect.size += uv_edit_draw->get_size() * 2.0; + updating_uv_scroll = true; + uv_hscroll->set_min(rect.position.x); uv_hscroll->set_max(rect.position.x + rect.size.x); if (ABS(rect.position.x - (rect.position.x + rect.size.x)) <= uv_edit_draw->get_size().x) { @@ -1216,6 +1221,14 @@ void Polygon2DEditor::_uv_draw() { uv_vscroll->set_page(uv_edit_draw->get_size().y); uv_vscroll->set_value(uv_draw_ofs.y); } + + Size2 hmin = uv_hscroll->get_combined_minimum_size(); + Size2 vmin = uv_vscroll->get_combined_minimum_size(); + + // Avoid scrollbar overlapping. + uv_hscroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, uv_vscroll->is_visible() ? -vmin.width : 0); + uv_vscroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, uv_hscroll->is_visible() ? -hmin.height : 0); + updating_uv_scroll = false; } @@ -1461,13 +1474,10 @@ Polygon2DEditor::Polygon2DEditor(EditorNode *p_editor) : uv_vscroll = memnew(VScrollBar); uv_vscroll->set_step(0.001); uv_edit_draw->add_child(uv_vscroll); - uv_vscroll->set_anchors_and_margins_preset(PRESET_RIGHT_WIDE); uv_vscroll->connect("value_changed", this, "_uv_scroll_changed"); uv_hscroll = memnew(HScrollBar); uv_hscroll->set_step(0.001); uv_edit_draw->add_child(uv_hscroll); - uv_hscroll->set_anchors_and_margins_preset(PRESET_BOTTOM_WIDE); - uv_hscroll->set_margin(MARGIN_RIGHT, -uv_vscroll->get_size().x * EDSCALE); uv_hscroll->connect("value_changed", this, "_uv_scroll_changed"); bone_scroll_main_vb = memnew(VBoxContainer); diff --git a/editor/plugins/script_editor_plugin.cpp b/editor/plugins/script_editor_plugin.cpp index f13abd47a9..1da47196f8 100644 --- a/editor/plugins/script_editor_plugin.cpp +++ b/editor/plugins/script_editor_plugin.cpp @@ -3209,7 +3209,7 @@ ScriptEditor::ScriptEditor(EditorNode *p_editor) { script_list = memnew(ItemList); scripts_vbox->add_child(script_list); - script_list->set_custom_minimum_size(Size2(150, 90) * EDSCALE); //need to give a bit of limit to avoid it from disappearing + script_list->set_custom_minimum_size(Size2(150, 60) * EDSCALE); //need to give a bit of limit to avoid it from disappearing script_list->set_v_size_flags(SIZE_EXPAND_FILL); script_split->set_split_offset(140); _sort_list_on_update = true; @@ -3254,14 +3254,14 @@ ScriptEditor::ScriptEditor(EditorNode *p_editor) { overview_vbox->add_child(members_overview); members_overview->set_allow_reselect(true); - members_overview->set_custom_minimum_size(Size2(0, 90) * EDSCALE); //need to give a bit of limit to avoid it from disappearing + members_overview->set_custom_minimum_size(Size2(0, 60) * EDSCALE); //need to give a bit of limit to avoid it from disappearing members_overview->set_v_size_flags(SIZE_EXPAND_FILL); members_overview->set_allow_rmb_select(true); help_overview = memnew(ItemList); overview_vbox->add_child(help_overview); help_overview->set_allow_reselect(true); - help_overview->set_custom_minimum_size(Size2(0, 90) * EDSCALE); //need to give a bit of limit to avoid it from disappearing + help_overview->set_custom_minimum_size(Size2(0, 60) * EDSCALE); //need to give a bit of limit to avoid it from disappearing help_overview->set_v_size_flags(SIZE_EXPAND_FILL); tab_container = memnew(TabContainer); diff --git a/editor/plugins/script_text_editor.cpp b/editor/plugins/script_text_editor.cpp index f0e4a4bfdc..1432c3fc63 100644 --- a/editor/plugins/script_text_editor.cpp +++ b/editor/plugins/script_text_editor.cpp @@ -691,13 +691,16 @@ void ScriptTextEditor::_update_bookmark_list() { bookmarks_menu->add_separator(); for (int i = 0; i < bookmark_list.size(); i++) { - String line = code_editor->get_text_edit()->get_line(bookmark_list[i]).strip_edges(); + // Strip edges to remove spaces or tabs. + // Also replace any tabs by spaces, since we can't print tabs in the menu. + String line = code_editor->get_text_edit()->get_line(bookmark_list[i]).replace("\t", " ").strip_edges(); + // Limit the size of the line if too big. if (line.length() > 50) { line = line.substr(0, 50); } - bookmarks_menu->add_item(String::num((int)bookmark_list[i] + 1) + " - \"" + line + "\""); + bookmarks_menu->add_item(String::num((int)bookmark_list[i] + 1) + " - `" + line + "`"); bookmarks_menu->set_item_metadata(bookmarks_menu->get_item_count() - 1, bookmark_list[i]); } } @@ -841,13 +844,16 @@ void ScriptTextEditor::_update_breakpoint_list() { breakpoints_menu->add_separator(); for (int i = 0; i < breakpoint_list.size(); i++) { - String line = code_editor->get_text_edit()->get_line(breakpoint_list[i]).strip_edges(); + // Strip edges to remove spaces or tabs. + // Also replace any tabs by spaces, since we can't print tabs in the menu. + String line = code_editor->get_text_edit()->get_line(breakpoint_list[i]).replace("\t", " ").strip_edges(); + // Limit the size of the line if too big. if (line.length() > 50) { line = line.substr(0, 50); } - breakpoints_menu->add_item(String::num((int)breakpoint_list[i] + 1) + " - \"" + line + "\""); + breakpoints_menu->add_item(String::num((int)breakpoint_list[i] + 1) + " - `" + line + "`"); breakpoints_menu->set_item_metadata(breakpoints_menu->get_item_count() - 1, breakpoint_list[i]); } } diff --git a/editor/plugins/shader_editor_plugin.cpp b/editor/plugins/shader_editor_plugin.cpp index c0b5053f9d..c24a666c55 100644 --- a/editor/plugins/shader_editor_plugin.cpp +++ b/editor/plugins/shader_editor_plugin.cpp @@ -379,6 +379,8 @@ void ShaderEditor::_editor_settings_changed() { shader_editor->get_text_edit()->cursor_set_block_mode(EditorSettings::get_singleton()->get("text_editor/cursor/block_caret")); shader_editor->get_text_edit()->set_smooth_scroll_enabled(EditorSettings::get_singleton()->get("text_editor/navigation/smooth_scrolling")); shader_editor->get_text_edit()->set_v_scroll_speed(EditorSettings::get_singleton()->get("text_editor/navigation/v_scroll_speed")); + shader_editor->get_text_edit()->set_draw_minimap(EditorSettings::get_singleton()->get("text_editor/navigation/show_minimap")); + shader_editor->get_text_edit()->set_minimap_width((int)EditorSettings::get_singleton()->get("text_editor/navigation/minimap_width") * EDSCALE); } void ShaderEditor::_bind_methods() { diff --git a/editor/plugins/spatial_editor_plugin.cpp b/editor/plugins/spatial_editor_plugin.cpp index 252f067eb1..31e6b65640 100644 --- a/editor/plugins/spatial_editor_plugin.cpp +++ b/editor/plugins/spatial_editor_plugin.cpp @@ -428,8 +428,7 @@ Vector3 SpatialEditorViewport::_get_screen_to_space(const Vector3 &p_vector3) { } else { cm.set_perspective(get_fov(), get_size().aspect(), get_znear() + p_vector3.z, get_zfar()); } - float screen_w, screen_h; - cm.get_viewport_size(screen_w, screen_h); + Vector2 screen_he = cm.get_viewport_half_extents(); Transform camera_transform; camera_transform.translate(cursor.pos); @@ -437,7 +436,7 @@ Vector3 SpatialEditorViewport::_get_screen_to_space(const Vector3 &p_vector3) { camera_transform.basis.rotate(Vector3(0, 1, 0), -cursor.y_rot); camera_transform.translate(0, 0, cursor.distance); - return camera_transform.xform(Vector3(((p_vector3.x / get_size().width) * 2.0 - 1.0) * screen_w, ((1.0 - (p_vector3.y / get_size().height)) * 2.0 - 1.0) * screen_h, -(get_znear() + p_vector3.z))); + return camera_transform.xform(Vector3(((p_vector3.x / get_size().width) * 2.0 - 1.0) * screen_he.x, ((1.0 - (p_vector3.y / get_size().height)) * 2.0 - 1.0) * screen_he.y, -(get_znear() + p_vector3.z))); } void SpatialEditorViewport::_select_region() { @@ -2135,6 +2134,13 @@ void SpatialEditorViewport::_notification(int p_what) { call_deferred("update_transform_gizmo_view"); } + if (p_what == NOTIFICATION_READY) { + // The crosshair icon doesn't depend on the editor theme. + crosshair->set_texture(get_icon("Crosshair", "EditorIcons")); + // Set the anchors and margins after changing the icon to ensure it's centered correctly. + crosshair->set_anchors_and_margins_preset(PRESET_CENTER); + } + if (p_what == NOTIFICATION_PROCESS) { real_t delta = get_process_delta_time(); @@ -2255,6 +2261,10 @@ void SpatialEditorViewport::_notification(int p_what) { current_camera = camera; } + // Display the crosshair only while freelooking. Hide it otherwise, + // as the crosshair can be distracting. + crosshair->set_visible(freelook_active); + if (show_info) { String text; text += "X: " + rtos(current_camera->get_translation().x).pad_decimals(1) + "\n"; @@ -3546,6 +3556,10 @@ SpatialEditorViewport::SpatialEditorViewport(SpatialEditor *p_spatial_editor, Ed camera->make_current(); surface->set_focus_mode(FOCUS_ALL); + crosshair = memnew(TextureRect); + crosshair->set_mouse_filter(MOUSE_FILTER_IGNORE); + surface->add_child(crosshair); + VBoxContainer *vbox = memnew(VBoxContainer); surface->add_child(vbox); vbox->set_position(Point2(10, 10) * EDSCALE); @@ -3598,6 +3612,24 @@ SpatialEditorViewport::SpatialEditorViewport(SpatialEditor *p_spatial_editor, Ed view_menu->set_disable_shortcuts(true); + if (OS::get_singleton()->get_current_video_driver() == OS::VIDEO_DRIVER_GLES2) { + // Alternate display modes only work when using the GLES3 renderer; make this explicit. + const int normal_idx = view_menu->get_popup()->get_item_index(VIEW_DISPLAY_NORMAL); + const int wireframe_idx = view_menu->get_popup()->get_item_index(VIEW_DISPLAY_WIREFRAME); + const int overdraw_idx = view_menu->get_popup()->get_item_index(VIEW_DISPLAY_OVERDRAW); + const int shadeless_idx = view_menu->get_popup()->get_item_index(VIEW_DISPLAY_SHADELESS); + const String unsupported_tooltip = TTR("Not available when using the GLES2 renderer."); + + view_menu->get_popup()->set_item_disabled(normal_idx, true); + view_menu->get_popup()->set_item_tooltip(normal_idx, unsupported_tooltip); + view_menu->get_popup()->set_item_disabled(wireframe_idx, true); + view_menu->get_popup()->set_item_tooltip(wireframe_idx, unsupported_tooltip); + view_menu->get_popup()->set_item_disabled(overdraw_idx, true); + view_menu->get_popup()->set_item_tooltip(overdraw_idx, unsupported_tooltip); + view_menu->get_popup()->set_item_disabled(shadeless_idx, true); + view_menu->get_popup()->set_item_tooltip(shadeless_idx, unsupported_tooltip); + } + ED_SHORTCUT("spatial_editor/freelook_left", TTR("Freelook Left"), KEY_A); ED_SHORTCUT("spatial_editor/freelook_right", TTR("Freelook Right"), KEY_D); ED_SHORTCUT("spatial_editor/freelook_forward", TTR("Freelook Forward"), KEY_W); diff --git a/editor/plugins/spatial_editor_plugin.h b/editor/plugins/spatial_editor_plugin.h index 356646221e..5cc2b24cbb 100644 --- a/editor/plugins/spatial_editor_plugin.h +++ b/editor/plugins/spatial_editor_plugin.h @@ -217,6 +217,7 @@ private: bool freelook_active; real_t freelook_speed; + TextureRect *crosshair; Label *info_label; Label *fps_label; Label *cinema_label; diff --git a/editor/plugins/sprite_editor_plugin.cpp b/editor/plugins/sprite_editor_plugin.cpp index f5ea88eeae..6757b180a3 100644 --- a/editor/plugins/sprite_editor_plugin.cpp +++ b/editor/plugins/sprite_editor_plugin.cpp @@ -474,69 +474,6 @@ void SpriteEditor::_add_as_sibling_or_child(Node *p_own_node, Node *p_new_node) p_new_node->set_owner(this->get_tree()->get_edited_scene_root()); } -#if 0 -void SpriteEditor::_create_uv_lines() { - - Ref<Mesh> sprite = node->get_sprite(); - ERR_FAIL_COND(!sprite.is_valid()); - - Set<SpriteEditorEdgeSort> edges; - uv_lines.clear(); - for (int i = 0; i < sprite->get_surface_count(); i++) { - if (sprite->surface_get_primitive_type(i) != Mesh::PRIMITIVE_TRIANGLES) - continue; - Array a = sprite->surface_get_arrays(i); - - PoolVector<Vector2> uv = a[p_layer == 0 ? Mesh::ARRAY_TEX_UV : Mesh::ARRAY_TEX_UV2]; - if (uv.size() == 0) { - err_dialog->set_text(TTR("Model has no UV in this layer")); - err_dialog->popup_centered_minsize(); - return; - } - - PoolVector<Vector2>::Read r = uv.read(); - - PoolVector<int> indices = a[Mesh::ARRAY_INDEX]; - PoolVector<int>::Read ri; - - int ic; - bool use_indices; - - if (indices.size()) { - ic = indices.size(); - ri = indices.read(); - use_indices = true; - } else { - ic = uv.size(); - use_indices = false; - } - - for (int j = 0; j < ic; j += 3) { - - for (int k = 0; k < 3; k++) { - - SpriteEditorEdgeSort edge; - if (use_indices) { - edge.a = r[ri[j + k]]; - edge.b = r[ri[j + ((k + 1) % 3)]]; - } else { - edge.a = r[j + k]; - edge.b = r[j + ((k + 1) % 3)]; - } - - if (edges.has(edge)) - continue; - - uv_lines.push_back(edge.a); - uv_lines.push_back(edge.b); - edges.insert(edge); - } - } - } - - debug_uv_dialog->popup_centered_minsize(); -} -#endif void SpriteEditor::_debug_uv_draw() { Ref<Texture> tex = node->get_texture(); diff --git a/editor/plugins/texture_region_editor_plugin.cpp b/editor/plugins/texture_region_editor_plugin.cpp index 13faeb0edb..94aef60f1f 100644 --- a/editor/plugins/texture_region_editor_plugin.cpp +++ b/editor/plugins/texture_region_editor_plugin.cpp @@ -178,6 +178,7 @@ void TextureRegionEditor::_region_draw() { scroll_rect.size += scroll_margin * 2; updating_scroll = true; + hscroll->set_min(scroll_rect.position.x); hscroll->set_max(scroll_rect.position.x + scroll_rect.size.x); if (ABS(scroll_rect.position.x - (scroll_rect.position.x + scroll_rect.size.x)) <= scroll_margin.x) { @@ -198,6 +199,14 @@ void TextureRegionEditor::_region_draw() { vscroll->set_page(scroll_margin.y); vscroll->set_value(draw_ofs.y); } + + Size2 hmin = hscroll->get_combined_minimum_size(); + Size2 vmin = vscroll->get_combined_minimum_size(); + + // Avoid scrollbar overlapping. + hscroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, vscroll->is_visible() ? -vmin.width : 0); + vscroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, hscroll->is_visible() ? -hmin.height : 0); + updating_scroll = false; if (node_ninepatch || obj_styleBox.is_valid()) { @@ -537,6 +546,17 @@ void TextureRegionEditor::_region_input(const Ref<InputEvent> &p_input) { edit_draw->update(); } } + + Ref<InputEventMagnifyGesture> magnify_gesture = p_input; + if (magnify_gesture.is_valid()) { + _zoom_on_position(draw_zoom * magnify_gesture->get_factor(), magnify_gesture->get_position()); + } + + Ref<InputEventPanGesture> pan_gesture = p_input; + if (pan_gesture.is_valid()) { + hscroll->set_value(hscroll->get_value() + hscroll->get_page() * pan_gesture->get_delta().x / 8); + vscroll->set_value(vscroll->get_value() + vscroll->get_page() * pan_gesture->get_delta().y / 8); + } } void TextureRegionEditor::_scroll_changed(float) { @@ -727,6 +747,9 @@ void TextureRegionEditor::_notification(int p_what) { zoom_out->set_icon(get_icon("ZoomLess", "EditorIcons")); zoom_reset->set_icon(get_icon("ZoomReset", "EditorIcons")); zoom_in->set_icon(get_icon("ZoomMore", "EditorIcons")); + + vscroll->set_anchors_and_margins_preset(PRESET_RIGHT_WIDE); + hscroll->set_anchors_and_margins_preset(PRESET_BOTTOM_WIDE); } break; case NOTIFICATION_VISIBILITY_CHANGED: { if (snap_mode == SNAP_AUTOSLICE && is_visible() && autoslice_is_dirty) { @@ -1001,25 +1024,22 @@ TextureRegionEditor::TextureRegionEditor(EditorNode *p_editor) { zoom_hb->add_child(zoom_out); zoom_reset = memnew(ToolButton); - zoom_out->set_tooltip(TTR("Zoom Reset")); + zoom_reset->set_tooltip(TTR("Zoom Reset")); zoom_reset->connect("pressed", this, "_zoom_reset"); zoom_hb->add_child(zoom_reset); zoom_in = memnew(ToolButton); - zoom_out->set_tooltip(TTR("Zoom In")); + zoom_in->set_tooltip(TTR("Zoom In")); zoom_in->connect("pressed", this, "_zoom_in"); zoom_hb->add_child(zoom_in); vscroll = memnew(VScrollBar); vscroll->set_step(0.001); edit_draw->add_child(vscroll); - vscroll->set_anchors_and_margins_preset(PRESET_RIGHT_WIDE); vscroll->connect("value_changed", this, "_scroll_changed"); hscroll = memnew(HScrollBar); hscroll->set_step(0.001); edit_draw->add_child(hscroll); - hscroll->set_anchors_and_margins_preset(PRESET_BOTTOM_WIDE); - hscroll->set_margin(MARGIN_RIGHT, -vscroll->get_size().x * EDSCALE); hscroll->connect("value_changed", this, "_scroll_changed"); updating_scroll = false; diff --git a/editor/plugins/tile_map_editor_plugin.cpp b/editor/plugins/tile_map_editor_plugin.cpp index a107cb020d..f889228f87 100644 --- a/editor/plugins/tile_map_editor_plugin.cpp +++ b/editor/plugins/tile_map_editor_plugin.cpp @@ -627,13 +627,14 @@ PoolVector<Vector2> TileMapEditor::_bucket_fill(const Point2i &p_start, bool era if (r != bucket_cache_rect) _clear_bucket_cache(); // Cache grid is not initialized - if (bucket_cache_visited == 0) { + if (bucket_cache_visited == NULL) { bucket_cache_visited = new bool[area]; invalidate_cache = true; } // Tile ID changed or position wasn't visited by the previous fill - int loc = (p_start.x - r.position.x) + (p_start.y - r.position.y) * r.get_size().x; - if (prev_id != bucket_cache_tile || !bucket_cache_visited[loc]) { + const int loc = (p_start.x - r.position.x) + (p_start.y - r.position.y) * r.get_size().x; + const bool in_range = 0 <= loc && loc < area; + if (prev_id != bucket_cache_tile || (in_range && !bucket_cache_visited[loc])) { invalidate_cache = true; } if (invalidate_cache) { @@ -893,7 +894,7 @@ void TileMapEditor::_draw_fill_preview(Control *p_viewport, int p_cell, const Po void TileMapEditor::_clear_bucket_cache() { if (bucket_cache_visited) { delete[] bucket_cache_visited; - bucket_cache_visited = 0; + bucket_cache_visited = NULL; } } @@ -1924,7 +1925,7 @@ TileMapEditor::TileMapEditor(EditorNode *p_editor) { transpose = false; bucket_cache_tile = -1; - bucket_cache_visited = 0; + bucket_cache_visited = NULL; invalid_cell.resize(1); invalid_cell.write[0] = TileMap::INVALID_CELL; diff --git a/editor/plugins/version_control_editor_plugin.cpp b/editor/plugins/version_control_editor_plugin.cpp index c53fc7e6c5..3622ca8d61 100644 --- a/editor/plugins/version_control_editor_plugin.cpp +++ b/editor/plugins/version_control_editor_plugin.cpp @@ -203,7 +203,7 @@ void VersionControlEditorPlugin::_refresh_stage_area() { } } else { - WARN_PRINT("No VCS addon is initialized. Select a Version Control Addon from Project menu.") + WARN_PRINT("No VCS addon is initialized. Select a Version Control Addon from Project menu."); } } diff --git a/editor/project_export.cpp b/editor/project_export.cpp index 8245264e0d..3c8fef6233 100644 --- a/editor/project_export.cpp +++ b/editor/project_export.cpp @@ -974,7 +974,7 @@ void ProjectExportDialog::_export_project_to_path(const String &p_path) { error_dialog->set_text(vformat(TTR("Failed to export the project for platform '%s'.\nThis might be due to a configuration issue in the export preset or your export settings."), platform->get_name())); } - ERR_PRINTS(vformat("Failed to export the project for platform '%s'.", platform->get_name())); + ERR_PRINT(vformat("Failed to export the project for platform '%s'.", platform->get_name())); error_dialog->show(); error_dialog->popup_centered_minsize(Size2(300, 80)); } diff --git a/editor/project_manager.cpp b/editor/project_manager.cpp index ca3431d3ec..ee434aaac2 100644 --- a/editor/project_manager.cpp +++ b/editor/project_manager.cpp @@ -163,7 +163,7 @@ private: } if (valid_path == "") { - set_message(TTR("The path does not exist."), MESSAGE_ERROR); + set_message(TTR("The path specified doesn't exist."), MESSAGE_ERROR); memdelete(d); get_ok()->set_disabled(true); return ""; @@ -177,7 +177,7 @@ private: } if (valid_install_path == "") { - set_message(TTR("The path does not exist."), MESSAGE_ERROR, INSTALL_PATH); + set_message(TTR("The path specified doesn't exist."), MESSAGE_ERROR, INSTALL_PATH); memdelete(d); get_ok()->set_disabled(true); return ""; @@ -195,7 +195,7 @@ private: unzFile pkg = unzOpen2(valid_path.utf8().get_data(), &io); if (!pkg) { - set_message(TTR("Error opening package file, not in ZIP format."), MESSAGE_ERROR); + set_message(TTR("Error opening package file (it's not in ZIP format)."), MESSAGE_ERROR); memdelete(d); get_ok()->set_disabled(true); unzClose(pkg); @@ -216,7 +216,7 @@ private: } if (ret == UNZ_END_OF_LIST_OF_FILE) { - set_message(TTR("Invalid '.zip' project file, does not contain a 'project.godot' file."), MESSAGE_ERROR); + set_message(TTR("Invalid \".zip\" project file; it doesn't contain a \"project.godot\" file."), MESSAGE_ERROR); memdelete(d); get_ok()->set_disabled(true); unzClose(pkg); @@ -230,7 +230,11 @@ private: bool is_empty = true; String n = d->get_next(); while (n != String()) { - if (n != "." && n != "..") { + if (!n.begins_with(".")) { + // Allow `.`, `..` (reserved current/parent folder names) + // and hidden files/folders to be present. + // For instance, this lets users initialize a Git repository + // and still be able to create a project in the directory afterwards. is_empty = false; break; } @@ -247,7 +251,7 @@ private: } } else { - set_message(TTR("Please choose a 'project.godot' or '.zip' file."), MESSAGE_ERROR); + set_message(TTR("Please choose a \"project.godot\" or \".zip\" file."), MESSAGE_ERROR); memdelete(d); install_path_container->hide(); get_ok()->set_disabled(true); @@ -256,7 +260,7 @@ private: } else if (valid_path.ends_with("zip")) { - set_message(TTR("Directory already contains a Godot project."), MESSAGE_ERROR, INSTALL_PATH); + set_message(TTR("This directory already contains a Godot project."), MESSAGE_ERROR, INSTALL_PATH); memdelete(d); get_ok()->set_disabled(true); return ""; @@ -269,7 +273,11 @@ private: bool is_empty = true; String n = d->get_next(); while (n != String()) { - if (n != "." && n != "..") { // i don't know if this is enough to guarantee an empty dir + if (!n.begins_with(".")) { + // Allow `.`, `..` (reserved current/parent folder names) + // and hidden files/folders to be present. + // For instance, this lets users initialize a Git repository + // and still be able to create a project in the directory afterwards. is_empty = false; break; } @@ -332,7 +340,7 @@ private: install_path_container->show(); get_ok()->set_disabled(false); } else { - set_message(TTR("Please choose a 'project.godot' or '.zip' file."), MESSAGE_ERROR); + set_message(TTR("Please choose a \"project.godot\" or \".zip\" file."), MESSAGE_ERROR); get_ok()->set_disabled(true); return; } @@ -1313,7 +1321,10 @@ void ProjectList::create_project_item_control(int p_index) { hb->set_is_favorite(item.favorite); TextureRect *tf = memnew(TextureRect); - tf->set_texture(get_icon("DefaultProjectIcon", "EditorIcons")); + // The project icon may not be loaded by the time the control is displayed, + // so use a loading placeholder. + tf->set_texture(get_icon("ProjectIconLoading", "EditorIcons")); + tf->set_v_size_flags(SIZE_SHRINK_CENTER); if (item.missing) { tf->set_modulate(Color(1, 1, 1, 0.5)); } @@ -2419,12 +2430,11 @@ ProjectManager::ProjectManager() { FileDialog::set_default_show_hidden_files(EditorSettings::get_singleton()->get("filesystem/file_dialog/show_hidden_files")); set_anchors_and_margins_preset(Control::PRESET_WIDE); - set_theme(create_editor_theme()); + set_theme(create_custom_theme()); gui_base = memnew(Control); add_child(gui_base); gui_base->set_anchors_and_margins_preset(Control::PRESET_WIDE); - gui_base->set_theme(create_custom_theme()); Panel *panel = memnew(Panel); gui_base->add_child(panel); diff --git a/editor/rename_dialog.cpp b/editor/rename_dialog.cpp index ce37b9e7f6..317be309a3 100644 --- a/editor/rename_dialog.cpp +++ b/editor/rename_dialog.cpp @@ -109,15 +109,13 @@ RenameDialog::RenameDialog(SceneTreeEditor *p_scene_tree_editor, UndoRedo *p_und const int feature_min_height = 160 * EDSCALE; - Ref<Theme> collapse_theme = create_editor_theme(); - collapse_theme->set_icon("checked", "CheckBox", collapse_theme->get_icon("GuiTreeArrowDown", "EditorIcons")); - collapse_theme->set_icon("unchecked", "CheckBox", collapse_theme->get_icon("GuiTreeArrowRight", "EditorIcons")); + cbut_regex = memnew(CheckButton); + cbut_regex->set_text(TTR("Use Regular Expressions")); + vbc->add_child(cbut_regex); - CheckBox *chk_collapse_features = memnew(CheckBox); - chk_collapse_features->set_text(TTR("Advanced Options")); - chk_collapse_features->set_theme(collapse_theme); - chk_collapse_features->set_focus_mode(FOCUS_NONE); - vbc->add_child(chk_collapse_features); + CheckButton *cbut_collapse_features = memnew(CheckButton); + cbut_collapse_features->set_text(TTR("Advanced Options")); + vbc->add_child(cbut_collapse_features); tabc_features = memnew(TabContainer); tabc_features->set_tab_align(TabContainer::ALIGN_LEFT); @@ -201,7 +199,7 @@ RenameDialog::RenameDialog(SceneTreeEditor *p_scene_tree_editor, UndoRedo *p_und grd_substitute->add_child(but_insert_count); chk_per_level_counter = memnew(CheckBox); - chk_per_level_counter->set_text(TTR("Per Level counter")); + chk_per_level_counter->set_text(TTR("Per-level Counter")); chk_per_level_counter->set_tooltip(TTR("If set the counter restarts for each group of child nodes")); vbc_substitute->add_child(chk_per_level_counter); @@ -239,18 +237,6 @@ RenameDialog::RenameDialog(SceneTreeEditor *p_scene_tree_editor, UndoRedo *p_und spn_count_padding->set_step(1); hbc_count_options->add_child(spn_count_padding); - // ---- Tab RegEx - - VBoxContainer *vbc_regex = memnew(VBoxContainer); - vbc_regex->set_h_size_flags(SIZE_EXPAND_FILL); - vbc_regex->set_name(TTR("Regular Expressions")); - vbc_regex->set_custom_minimum_size(Size2(0, feature_min_height)); - tabc_features->add_child(vbc_regex); - - cbut_regex = memnew(CheckBox); - cbut_regex->set_text(TTR("Regular Expressions")); - vbc_regex->add_child(cbut_regex); - // ---- Tab Process VBoxContainer *vbc_process = memnew(VBoxContainer); @@ -274,8 +260,8 @@ RenameDialog::RenameDialog(SceneTreeEditor *p_scene_tree_editor, UndoRedo *p_und opt_style = memnew(OptionButton); opt_style->add_item(TTR("Keep")); - opt_style->add_item(TTR("CamelCase to under_scored")); - opt_style->add_item(TTR("under_scored to CamelCase")); + opt_style->add_item(TTR("PascalCase to snake_case")); + opt_style->add_item(TTR("snake_case to PascalCase")); hbc_style->add_child(opt_style); // ------ Case @@ -305,7 +291,7 @@ RenameDialog::RenameDialog(SceneTreeEditor *p_scene_tree_editor, UndoRedo *p_und lbl_preview = memnew(Label); lbl_preview->set_text(""); - lbl_preview->add_color_override("font_color", Color(1, 0.5f, 0, 1)); + lbl_preview->add_color_override("font_color", EditorNode::get_singleton()->get_gui_base()->get_color("error_color", "Editor")); vbc->add_child(lbl_preview); // ---- Dialog related @@ -320,7 +306,7 @@ RenameDialog::RenameDialog(SceneTreeEditor *p_scene_tree_editor, UndoRedo *p_und // ---- Connections - chk_collapse_features->connect("toggled", this, "_features_toggled"); + cbut_collapse_features->connect("toggled", this, "_features_toggled"); // Substitite Buttons @@ -420,9 +406,12 @@ void RenameDialog::_update_preview(String new_text) { lbl_preview->set_text(new_name); if (new_name == preview_node->get_name()) { - lbl_preview->add_color_override("font_color", Color(0, 0.5f, 0.25f, 1)); + // New name is identical to the old one. Don't color it as much to avoid distracting the user. + const Color accent_color = EditorNode::get_singleton()->get_gui_base()->get_color("accent_color", "Editor"); + const Color text_color = EditorNode::get_singleton()->get_gui_base()->get_color("default_color", "RichTextLabel"); + lbl_preview->add_color_override("font_color", accent_color.linear_interpolate(text_color, 0.5)); } else { - lbl_preview->add_color_override("font_color", Color(0, 1, 0.5f, 1)); + lbl_preview->add_color_override("font_color", EditorNode::get_singleton()->get_gui_base()->get_color("success_color", "Editor")); } } @@ -507,9 +496,9 @@ void RenameDialog::_error_handler(void *p_self, const char *p_func, const char * } self->has_errors = true; - self->lbl_preview_title->set_text(TTR("Error")); - self->lbl_preview->add_color_override("font_color", Color(1, 0.25f, 0, 1)); - self->lbl_preview->set_text(err_str); + self->lbl_preview_title->set_text(TTR("Regular Expression Error")); + self->lbl_preview->add_color_override("font_color", EditorNode::get_singleton()->get_gui_base()->get_color("error_color", "Editor")); + self->lbl_preview->set_text(vformat(TTR("At character %s"), err_str)); } String RenameDialog::_regex(const String &pattern, const String &subject, const String &replacement) { @@ -526,18 +515,18 @@ String RenameDialog::_postprocess(const String &subject) { String result = subject; if (style_id == 1) { + // PascalCase to snake_case - // CamelCase to Under_Line result = result.camelcase_to_underscore(true); result = _regex("_+", result, "_"); } else if (style_id == 2) { + // snake_case to PascalCase - // Under_Line to CamelCase RegEx pattern("_+(.?)"); Array matches = pattern.search_all(result); - // _ name would become empty. Ignore + // The name `_` would become empty; ignore it. if (matches.size() && result != "_") { String buffer; int start = 0; @@ -623,7 +612,7 @@ void RenameDialog::rename() { const String &new_name = to_rename[i].second; if (!n) { - ERR_PRINTS("Skipping missing node: " + to_rename[i].first.get_concatenated_subnames()); + ERR_PRINT("Skipping missing node: " + to_rename[i].first.get_concatenated_subnames()); continue; } diff --git a/editor/rename_dialog.h b/editor/rename_dialog.h index 692e56f1a4..2825cb2cd2 100644 --- a/editor/rename_dialog.h +++ b/editor/rename_dialog.h @@ -75,7 +75,7 @@ class RenameDialog : public ConfirmationDialog { TabContainer *tabc_features; CheckBox *cbut_substitute; - CheckBox *cbut_regex; + CheckButton *cbut_regex; CheckBox *cbut_process; CheckBox *chk_per_level_counter; diff --git a/editor/scene_tree_dock.cpp b/editor/scene_tree_dock.cpp index dca6087f8b..7410a998ad 100644 --- a/editor/scene_tree_dock.cpp +++ b/editor/scene_tree_dock.cpp @@ -981,7 +981,7 @@ void SceneTreeDock::_tool_selected(int p_tool, bool p_confirm_override) { if (!new_node) { new_node = memnew(Node); - ERR_PRINTS("Creating root from favorite '" + selected_favorite_root + "' failed. Creating 'Node' instead."); + ERR_PRINT("Creating root from favorite '" + selected_favorite_root + "' failed. Creating 'Node' instead."); } } else { switch (p_tool) { diff --git a/editor/script_create_dialog.cpp b/editor/script_create_dialog.cpp index 35d5fe5f70..c4627e6627 100644 --- a/editor/script_create_dialog.cpp +++ b/editor/script_create_dialog.cpp @@ -84,7 +84,9 @@ void ScriptCreateDialog::_path_hbox_sorted() { int filename_start_pos = initial_bp.find_last("/") + 1; int filename_end_pos = initial_bp.length(); - file_path->select(filename_start_pos, filename_end_pos); + if (!is_built_in) { + file_path->select(filename_start_pos, filename_end_pos); + } // First set cursor to the end of line to scroll LineEdit view // to the right and then set the actual cursor position. @@ -575,6 +577,10 @@ void ScriptCreateDialog::_browse_class_in_tree() { void ScriptCreateDialog::_path_changed(const String &p_path) { + if (is_built_in) { + return; + } + is_path_valid = false; is_new_script_created = true; @@ -644,7 +650,7 @@ void ScriptCreateDialog::_update_dialog() { } if (script_ok) { - _msg_script_valid(true, TTR("Script is valid.")); + _msg_script_valid(true, TTR("Script path/name is valid.")); } // Does script have named classes? diff --git a/editor/script_editor_debugger.cpp b/editor/script_editor_debugger.cpp index 71a946b256..34547717fd 100644 --- a/editor/script_editor_debugger.cpp +++ b/editor/script_editor_debugger.cpp @@ -338,7 +338,7 @@ void ScriptEditorDebugger::_file_selected(const String &p_file) { FileAccessRef file = FileAccess::open(p_file, FileAccess::WRITE, &err); if (err != OK) { - ERR_PRINTS("Failed to open " + p_file); + ERR_PRINT("Failed to open " + p_file); return; } Vector<String> line; @@ -484,8 +484,10 @@ int ScriptEditorDebugger::_update_scene_tree(TreeItem *parent, const Array &node void ScriptEditorDebugger::_video_mem_request() { - ERR_FAIL_COND(connection.is_null()); - ERR_FAIL_COND(!connection->is_connected_to_host()); + if (connection.is_null() || !connection->is_connected_to_host()) { + // Video RAM usage is only available while a project is being debugged. + return; + } Array msg; msg.push_back("request_video_mem"); @@ -806,25 +808,25 @@ void ScriptEditorDebugger::_parse_message(const String &p_msg, const Array &p_da p.write[i] = arr[i]; if (i < perf_items.size()) { - float v = p[i]; - String vs = rtos(v); - String tt = vs; + const float value = p[i]; + String label = rtos(value); + String tooltip = label; switch (Performance::MonitorType((int)perf_items[i]->get_metadata(1))) { case Performance::MONITOR_TYPE_MEMORY: { - vs = String::humanize_size(v); - tt = vs; + label = String::humanize_size(value); + tooltip = label; } break; case Performance::MONITOR_TYPE_TIME: { - tt += " seconds"; - vs += " s"; + label = rtos(value * 1000).pad_decimals(2) + " ms"; + tooltip = label; } break; default: { - tt += " " + perf_items[i]->get_text(0); + tooltip += " " + perf_items[i]->get_text(0); } break; } - perf_items[i]->set_text(1, vs); - perf_items[i]->set_tooltip(1, tt); + perf_items[i]->set_text(1, label); + perf_items[i]->set_tooltip(1, tooltip); if (p[i] > perf_max[i]) perf_max.write[i] = p[i]; } @@ -1323,6 +1325,7 @@ void ScriptEditorDebugger::_notification(int p_what) { inspect_scene_tree->clear(); le_set->set_disabled(true); le_clear->set_disabled(false); + vmem_refresh->set_disabled(false); error_tree->clear(); error_count = 0; warning_count = 0; @@ -1523,6 +1526,7 @@ void ScriptEditorDebugger::stop() { le_clear->set_disabled(false); le_set->set_disabled(true); profiler->set_enabled(true); + vmem_refresh->set_disabled(true); inspect_scene_tree->clear(); inspector->edit(NULL); @@ -1622,6 +1626,7 @@ void ScriptEditorDebugger::_output_clear() { void ScriptEditorDebugger::_export_csv() { file_dialog->set_mode(EditorFileDialog::MODE_SAVE_FILE); + file_dialog->set_access(EditorFileDialog::ACCESS_FILESYSTEM); file_dialog_mode = SAVE_CSV; file_dialog->popup_centered_ratio(); } @@ -2187,6 +2192,13 @@ void ScriptEditorDebugger::_item_menu_id_pressed(int p_option) { } } +void ScriptEditorDebugger::_tab_changed(int p_tab) { + if (tabs->get_tab_title(p_tab) == TTR("Video RAM")) { + // "Video RAM" tab was clicked, refresh the data it's dislaying when entering the tab. + _video_mem_request(); + } +} + void ScriptEditorDebugger::_bind_methods() { ClassDB::bind_method(D_METHOD("_stack_dump_frame_selected"), &ScriptEditorDebugger::_stack_dump_frame_selected); @@ -2218,6 +2230,7 @@ void ScriptEditorDebugger::_bind_methods() { ClassDB::bind_method(D_METHOD("_error_tree_item_rmb_selected"), &ScriptEditorDebugger::_error_tree_item_rmb_selected); ClassDB::bind_method(D_METHOD("_item_menu_id_pressed"), &ScriptEditorDebugger::_item_menu_id_pressed); + ClassDB::bind_method(D_METHOD("_tab_changed"), &ScriptEditorDebugger::_tab_changed); ClassDB::bind_method(D_METHOD("_paused"), &ScriptEditorDebugger::_paused); @@ -2258,13 +2271,13 @@ ScriptEditorDebugger::ScriptEditorDebugger(EditorNode *p_editor) { tabs->add_style_override("panel", editor->get_gui_base()->get_stylebox("DebuggerPanel", "EditorStyles")); tabs->add_style_override("tab_fg", editor->get_gui_base()->get_stylebox("DebuggerTabFG", "EditorStyles")); tabs->add_style_override("tab_bg", editor->get_gui_base()->get_stylebox("DebuggerTabBG", "EditorStyles")); + tabs->connect("tab_changed", this, "_tab_changed"); add_child(tabs); { //debugger VBoxContainer *vbc = memnew(VBoxContainer); vbc->set_name(TTR("Debugger")); - //tabs->add_child(vbc); Control *dbg = vbc; HBoxContainer *hbc = memnew(HBoxContainer); @@ -2522,6 +2535,7 @@ ScriptEditorDebugger::ScriptEditorDebugger(EditorNode *p_editor) { vmem_total->set_custom_minimum_size(Size2(100, 0) * EDSCALE); vmem_hb->add_child(vmem_total); vmem_refresh = memnew(ToolButton); + vmem_refresh->set_disabled(true); vmem_hb->add_child(vmem_refresh); vmem_vb->add_child(vmem_hb); vmem_refresh->connect("pressed", this, "_video_mem_request"); @@ -2534,20 +2548,20 @@ ScriptEditorDebugger::ScriptEditorDebugger(EditorNode *p_editor) { vmmc->set_v_size_flags(SIZE_EXPAND_FILL); vmem_vb->add_child(vmmc); - vmem_vb->set_name(TTR("Video Mem")); + vmem_vb->set_name(TTR("Video RAM")); vmem_tree->set_columns(4); vmem_tree->set_column_titles_visible(true); vmem_tree->set_column_title(0, TTR("Resource Path")); vmem_tree->set_column_expand(0, true); vmem_tree->set_column_expand(1, false); vmem_tree->set_column_title(1, TTR("Type")); - vmem_tree->set_column_min_width(1, 100); + vmem_tree->set_column_min_width(1, 100 * EDSCALE); vmem_tree->set_column_expand(2, false); vmem_tree->set_column_title(2, TTR("Format")); - vmem_tree->set_column_min_width(2, 150); + vmem_tree->set_column_min_width(2, 150 * EDSCALE); vmem_tree->set_column_expand(3, false); vmem_tree->set_column_title(3, TTR("Usage")); - vmem_tree->set_column_min_width(3, 80); + vmem_tree->set_column_min_width(3, 80 * EDSCALE); vmem_tree->set_hide_root(true); tabs->add_child(vmem_vb); diff --git a/editor/script_editor_debugger.h b/editor/script_editor_debugger.h index 7d91e247b6..589a011bff 100644 --- a/editor/script_editor_debugger.h +++ b/editor/script_editor_debugger.h @@ -226,6 +226,7 @@ private: void _error_tree_item_rmb_selected(const Vector2 &p_pos); void _item_menu_id_pressed(int p_option); + void _tab_changed(int p_tab); void _export_csv(); diff --git a/editor/spatial_editor_gizmos.cpp b/editor/spatial_editor_gizmos.cpp index 89713c2579..c94b0eeab0 100644 --- a/editor/spatial_editor_gizmos.cpp +++ b/editor/spatial_editor_gizmos.cpp @@ -44,11 +44,9 @@ #include "scene/3d/navigation_mesh.h" #include "scene/3d/particles.h" #include "scene/3d/physics_joint.h" -#include "scene/3d/portal.h" #include "scene/3d/position_3d.h" #include "scene/3d/ray_cast.h" #include "scene/3d/reflection_probe.h" -#include "scene/3d/room_instance.h" #include "scene/3d/soft_body.h" #include "scene/3d/spring_arm.h" #include "scene/3d/sprite_3d.h" @@ -885,7 +883,7 @@ void LightSpatialGizmoPlugin::set_handle(EditorSpatialGizmo *p_gizmo, int p_idx, d = Math::stepify(d, SpatialEditor::get_singleton()->get_translate_snap()); } - if (d < 0) + if (d <= 0) // Equal is here for negative zero. d = 0; light->set_param(Light::PARAM_RANGE, d); @@ -1951,112 +1949,6 @@ void PhysicalBoneSpatialGizmoPlugin::redraw(EditorSpatialGizmo *p_gizmo) { p_gizmo->add_lines(points, material); } -// FIXME: Kept as reference for reimplementation in 3.1+ -#if 0 - -void RoomSpatialGizmo::redraw() { - - clear(); - Ref<RoomBounds> roomie = room->get_room(); - if (roomie.is_null()) - return; - PoolVector<Face3> faces = roomie->get_geometry_hint(); - - Vector<Vector3> lines; - int fc = faces.size(); - PoolVector<Face3>::Read r = faces.read(); - - Map<_EdgeKey, Vector3> edge_map; - - for (int i = 0; i < fc; i++) { - - Vector3 fn = r[i].get_plane().normal; - - for (int j = 0; j < 3; j++) { - - _EdgeKey ek; - ek.from = r[i].vertex[j].snapped(Vector3(CMP_EPSILON, CMP_EPSILON, CMP_EPSILON)); - ek.to = r[i].vertex[(j + 1) % 3].snapped(Vector3(CMP_EPSILON, CMP_EPSILON, CMP_EPSILON)); - if (ek.from < ek.to) - SWAP(ek.from, ek.to); - - Map<_EdgeKey, Vector3>::Element *E = edge_map.find(ek); - - if (E) { - - if (E->get().dot(fn) > 0.9) { - - E->get() = Vector3(); - } - - } else { - - edge_map[ek] = fn; - } - } - } - - for (Map<_EdgeKey, Vector3>::Element *E = edge_map.front(); E; E = E->next()) { - - if (E->get() != Vector3()) { - lines.push_back(E->key().from); - lines.push_back(E->key().to); - } - } - - add_lines(lines, EditorSpatialGizmos::singleton->room_material); - add_collision_segments(lines); -} - -RoomSpatialGizmo::RoomSpatialGizmo(Room *p_room) { - - set_spatial_node(p_room); - room = p_room; -} - -///// - -void PortalSpatialGizmo::redraw() { - - clear(); - - Vector<Point2> points = portal->get_shape(); - if (points.size() == 0) { - return; - } - - Vector<Vector3> lines; - - Vector3 center; - for (int i = 0; i < points.size(); i++) { - - Vector3 f; - f.x = points[i].x; - f.y = points[i].y; - Vector3 fn; - fn.x = points[(i + 1) % points.size()].x; - fn.y = points[(i + 1) % points.size()].y; - center += f; - - lines.push_back(f); - lines.push_back(fn); - } - - center /= points.size(); - lines.push_back(center); - lines.push_back(center + Vector3(0, 0, 1)); - - add_lines(lines, EditorSpatialGizmos::singleton->portal_material); - add_collision_segments(lines); -} - -PortalSpatialGizmo::PortalSpatialGizmo(Portal *p_portal) { - - set_spatial_node(p_portal); - portal = p_portal; -} - -#endif ///// RayCastSpatialGizmoPlugin::RayCastSpatialGizmoPlugin() { diff --git a/editor/spatial_editor_gizmos.h b/editor/spatial_editor_gizmos.h index 1d6801a136..81b62981ac 100644 --- a/editor/spatial_editor_gizmos.h +++ b/editor/spatial_editor_gizmos.h @@ -160,19 +160,6 @@ public: PhysicalBoneSpatialGizmoPlugin(); }; -#if 0 -class PortalSpatialGizmo : public EditorSpatialGizmo { - - GDCLASS(PortalSpatialGizmo, EditorSpatialGizmo); - - Portal *portal; - -public: - void redraw(); - PortalSpatialGizmo(Portal *p_portal = NULL); -}; -#endif - class RayCastSpatialGizmoPlugin : public EditorSpatialGizmoPlugin { GDCLASS(RayCastSpatialGizmoPlugin, EditorSpatialGizmoPlugin); diff --git a/editor/translations/af.po b/editor/translations/af.po index 5dfc860107..23917c09e6 100644 --- a/editor/translations/af.po +++ b/editor/translations/af.po @@ -2014,14 +2014,27 @@ msgstr "Geërf deur:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Kort Beskrywing:" +msgid "Description" +msgstr "Beskrywing:" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "" #: editor/editor_help.cpp msgid "Properties" msgstr "Eienskappe" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Laai Verstek" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metodes" @@ -2035,36 +2048,17 @@ msgid "Enumerations" msgstr "Opnoemings" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstantes" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "Beskrywing" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "" +msgid "Property Descriptions" +msgstr "Eienskap Beskrywing:" #: editor/editor_help.cpp -#, fuzzy -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "(value)" msgstr "" -"Daar is tans geen beskrywing vir hierdie metode nie. Help ons asseblief deur " -"[color=$color][url=$url]een by te dra[/url][/color]!" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Property Descriptions" -msgstr "Eienskap Beskrywing:" #: editor/editor_help.cpp msgid "" @@ -4599,7 +4593,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5684,6 +5677,11 @@ msgid "Auto Insert Key" msgstr "Anim Voeg Sleutel by" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animasie lengte (in sekondes)." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5973,7 +5971,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7390,6 +7387,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12540,6 +12541,26 @@ msgid "Constants cannot be modified." msgstr "" #, fuzzy +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Daar is tans geen beskrywing vir hierdie metode nie. Help ons asseblief " +#~ "deur [color=$color][url=$url]een by te dra[/url][/color]!" + +#~ msgid "enum " +#~ msgstr "enum " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Kort Beskrywing:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "Beskrywing" + +#, fuzzy #~ msgid "Methods:" #~ msgstr "Metodes" diff --git a/editor/translations/ar.po b/editor/translations/ar.po index f488274efc..6a3dba2b43 100644 --- a/editor/translations/ar.po +++ b/editor/translations/ar.po @@ -32,12 +32,13 @@ # Rachid Graphicos <graphicos1d@gmail.com>, 2019. # traveller010 <manar.bushnaq.001@gmail.com>, 2019. # Ahmed Shahwan <dev.ahmed.shahwan@gmail.com>, 2019. +# hshw <shw@tutanota.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2019-12-26 00:02+0000\n" -"Last-Translator: Ahmed Shahwan <dev.ahmed.shahwan@gmail.com>\n" +"PO-Revision-Date: 2020-01-16 22:23+0000\n" +"Last-Translator: hshw <shw@tutanota.com>\n" "Language-Team: Arabic <https://hosted.weblate.org/projects/godot-engine/" "godot/ar/>\n" "Language: ar\n" @@ -46,7 +47,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 " "&& n%100<=10 ? 3 : n%100>=11 ? 4 : 5;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.10.2-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -55,7 +56,7 @@ msgstr "نوع معامل خاطئ للدالة convert()ØŒ إستخدم Ø«ÙˆØ§Ø #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp msgid "Expected a string of length 1 (a character)." -msgstr "" +msgstr "كان يتوقع سلسلة من الطول 1 (ØرÙ)." #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/mono/glue/gd_glue.cpp @@ -1220,7 +1221,7 @@ msgstr "ÙŠÙكك الضغط عن الأصول" #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "The following files failed extraction from package:" -msgstr "" +msgstr "Ùشل استخراج الملÙات التالية من الØزمة:" #: editor/editor_asset_installer.cpp #, fuzzy @@ -1699,7 +1700,7 @@ msgstr "خصائص:" #: editor/editor_feature_profile.cpp msgid "Enabled Features:" -msgstr "" +msgstr "الميزات المÙعلة:" #: editor/editor_feature_profile.cpp #, fuzzy @@ -1739,7 +1740,7 @@ msgstr "الØالي:" #: editor/plugins/animation_player_editor_plugin.cpp #: editor/plugins/version_control_editor_plugin.cpp msgid "New" -msgstr "" +msgstr "جديد" #: editor/editor_feature_profile.cpp editor/editor_node.cpp #: editor/project_manager.cpp @@ -1989,14 +1990,28 @@ msgstr "مورث بواسطة:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "وص٠مختصر:" +msgid "Description" +msgstr "الوصÙ:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "الدورس علي الإنترنت:" #: editor/editor_help.cpp msgid "Properties" msgstr "خصائص" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "الإÙتراضي" + +#: editor/editor_help.cpp msgid "Methods" msgstr "قائمة الطرق" @@ -2009,36 +2024,18 @@ msgid "Enumerations" msgstr "التعدادات" #: editor/editor_help.cpp -msgid "enum " -msgstr "التعداد " - -#: editor/editor_help.cpp msgid "Constants" msgstr "الثوابت" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "وص٠الصÙ" - -#: editor/editor_help.cpp #, fuzzy -msgid "Online Tutorials" -msgstr "الدورس علي الإنترنت:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"ليس هناك دروس تعليمية ÙÙŠ هذا الÙصل، يمكنك [color=$color][url=$url] المساهمة " -"ÙÙŠ Ø¥Øداها [/url][/color] أو [color=$color][url=$url2]أطلب Ø£Øداها [/url][/" -"color]." +msgid "Property Descriptions" +msgstr "وص٠الملكية:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "وص٠الملكية:" +msgid "(value)" +msgstr "القيمة:" #: editor/editor_help.cpp msgid "" @@ -2193,7 +2190,7 @@ msgstr "تنزيل" #: editor/editor_network_profiler.cpp msgid "Up" -msgstr "" +msgstr "Ùوق" #: editor/editor_network_profiler.cpp editor/editor_node.cpp msgid "Node" @@ -2217,7 +2214,7 @@ msgstr "" #: editor/editor_node.cpp editor/project_manager.cpp msgid "New Window" -msgstr "" +msgstr "ناÙذة جديدة" #: editor/editor_node.cpp msgid "Imported resources can't be saved." @@ -2662,7 +2659,7 @@ msgstr "اغلاق" #: editor/editor_node.cpp editor/plugins/script_editor_plugin.cpp msgid "Close Other Tabs" -msgstr "" +msgstr "أغلق الألسنة الاخرى" #: editor/editor_node.cpp msgid "Close Tabs to the Right" @@ -4677,7 +4674,6 @@ msgid "Animation Tools" msgstr "أدوات الØركة" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "صورة متØركة" @@ -5804,6 +5800,11 @@ msgid "Auto Insert Key" msgstr "أض٠مÙØªØ§Ø Ø§Ù„Øركة" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "مدة الØركة (seconds)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "أدخل Ù…ÙØªØ§Ø (مسارات موجودة بالÙعل)" @@ -6102,7 +6103,6 @@ msgid "No mesh to debug." msgstr "لا ميش لتصØÙŠØØ©." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "النموذج ليس لديه UV ÙÙŠ هذا الطابق" @@ -7547,6 +7547,10 @@ msgid "Cinematic Preview" msgstr "ÙŠÙنشئ مستعرضات الميش" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12800,7 +12804,26 @@ msgstr "يمكن تعيين المتغيرات Ùقط ÙÙŠ الذروة ." #: servers/visual/shader_language.cpp msgid "Constants cannot be modified." -msgstr "" +msgstr "لا يمكن تعديل الثوابت." + +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "ليس هناك دروس تعليمية ÙÙŠ هذا الÙصل، يمكنك [color=$color][url=$url] " +#~ "المساهمة ÙÙŠ Ø¥Øداها [/url][/color] أو [color=$color][url=$url2]أطلب Ø£Øداها " +#~ "[/url][/color]." + +#~ msgid "enum " +#~ msgstr "التعداد " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "وص٠مختصر:" + +#~ msgid "Class Description" +#~ msgstr "وص٠الصÙ" #~ msgid "Project export failed with error code %d." #~ msgstr "تصدير المشروع Ùشل, رمز الخطأ %d." diff --git a/editor/translations/bg.po b/editor/translations/bg.po index 8b3fe3d00d..a42e873790 100644 --- a/editor/translations/bg.po +++ b/editor/translations/bg.po @@ -1978,14 +1978,26 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Кратко ОпиÑание:" +msgid "Description" +msgstr "ОпиÑание:" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "" #: editor/editor_help.cpp msgid "Properties" msgstr "" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Методи" @@ -1999,33 +2011,18 @@ msgid "Enumerations" msgstr "Изброени типове" #: editor/editor_help.cpp -msgid "enum " -msgstr "" - -#: editor/editor_help.cpp msgid "Constants" msgstr "КонÑтанти" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "ОпиÑание" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" +msgid "Property Descriptions" +msgstr "Кратко ОпиÑание:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "Кратко ОпиÑание:" +msgid "(value)" +msgstr "СтойноÑÑ‚" #: editor/editor_help.cpp msgid "" @@ -4611,7 +4608,6 @@ msgid "Animation Tools" msgstr "Ðнимационни ИнÑтрументи" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5724,6 +5720,11 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Промени Името на ÐнимациÑта:" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -6013,7 +6014,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7440,6 +7440,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Свободен Изглед ОтлÑво" @@ -12721,6 +12725,14 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Кратко ОпиÑание:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "ОпиÑание" + #~ msgid "Password:" #~ msgstr "Парола:" diff --git a/editor/translations/bn.po b/editor/translations/bn.po index 86ffa156e6..3cfcc98809 100644 --- a/editor/translations/bn.po +++ b/editor/translations/bn.po @@ -2066,8 +2066,13 @@ msgstr "গৃহীত হয়েছে:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "সংকà§à¦·à¦¿à¦ªà§à¦¤ বরà§à¦£à¦¨à¦¾:" +msgid "Description" +msgstr "বরà§à¦£à¦¨à¦¾:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "টিউটোরিয়ালসমূহ" #: editor/editor_help.cpp #, fuzzy @@ -2076,6 +2081,16 @@ msgstr "পà§à¦°à§‹à¦ªà¦¾à¦°à§à¦Ÿà¦¿-সমূহ:" #: editor/editor_help.cpp #, fuzzy +msgid "override:" +msgstr "ওà¦à¦¾à¦°à¦°à¦¾à¦‡à¦¡..." + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "সাধারণ/ডিফলà§à¦Ÿ" + +#: editor/editor_help.cpp +#, fuzzy msgid "Methods" msgstr "মেথডের তালিকা:" @@ -2090,39 +2105,19 @@ msgid "Enumerations" msgstr "অà§à¦¯à¦¾à¦¨à¦¿à¦®à§‡à¦¶à¦¨à¦¸à¦®à§‚হ" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp #, fuzzy msgid "Constants" msgstr "ধà§à¦°à§à¦¬à¦•à¦¸à¦®à§‚হ:" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "বরà§à¦£à¦¨à¦¾:" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "টিউটোরিয়ালসমূহ" - -#: editor/editor_help.cpp -#, fuzzy -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"à¦à¦‡ মেথড সমà§à¦ªà¦°à§à¦•à§‡ বিসà§à¦¤à¦¾à¦°à¦¿à¦¤ তথà§à¦¯ লিপিবদà§à¦§ করা হয়নি। অনà§à¦—à§à¦°à¦¹ করে তথà§à¦¯ পà§à¦°à¦¦à¦¾à¦¨à§‡à¦° মাধà§à¦¯à¦®à§‡ " -"সহায়তা করà§à¦¨à¥¤ তথà§à¦¯ পà§à¦°à¦¦à¦¾à¦¨à§‡à¦° জনà§à¦¯ [color=$color][url=$url], [/url][/color] ফরমà§à¦¯à¦¾à¦Ÿ " -"বà§à¦¯à¦¾à¦¬à¦¹à¦¾à¦° করà§à¦¨ !" +msgid "Property Descriptions" +msgstr "মান/পà§à¦°à§‹à¦ªà¦¾à¦°à§à¦Ÿà¦¿à¦° বরà§à¦£à¦¨à¦¾:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "মান/পà§à¦°à§‹à¦ªà¦¾à¦°à§à¦Ÿà¦¿à¦° বরà§à¦£à¦¨à¦¾:" +msgid "(value)" +msgstr "মান" #: editor/editor_help.cpp msgid "" @@ -4882,7 +4877,6 @@ msgid "Animation Tools" msgstr "অà§à¦¯à¦¾à¦¨à¦¿à¦®à§‡à¦¶à¦¨à§‡à¦° সরঞà§à¦œà¦¾à¦®à¦¸à¦®à§‚হ" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "অà§à¦¯à¦¾à¦¨à¦¿à¦®à§‡à¦¶à¦¨" @@ -6036,6 +6030,11 @@ msgid "Auto Insert Key" msgstr "অà§à¦¯à¦¾à¦¨à¦¿à¦®à§‡à¦¶à¦¨à§‡ (Anim) চাবি যোগ করà§à¦¨" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "অà§à¦¯à¦¾à¦¨à¦¿à¦®à§‡à¦¶à¦¨à§‡à¦° চাবি সনà§à¦¨à¦¿à¦¬à§‡à¦¶à¦¿à¦¤ হয়েছে।" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "চাবি সনà§à¦¨à¦¿à¦¬à§‡à¦¶ করà§à¦¨ (বিদà§à¦¯à¦®à¦¾à¦¨ টà§à¦°à§à¦¯à¦¾à¦•/পথসমূহ)" @@ -6345,7 +6344,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7839,6 +7837,10 @@ msgid "Cinematic Preview" msgstr "মেস লাইবà§à¦°à§‡à¦°à¦¿ তৈরি হচà§à¦›à§‡" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "বাম দিকে ফà§à¦°à¦¿à¦²à§à¦• করà§à¦¨" @@ -13382,6 +13384,27 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "à¦à¦‡ মেথড সমà§à¦ªà¦°à§à¦•à§‡ বিসà§à¦¤à¦¾à¦°à¦¿à¦¤ তথà§à¦¯ লিপিবদà§à¦§ করা হয়নি। অনà§à¦—à§à¦°à¦¹ করে তথà§à¦¯ পà§à¦°à¦¦à¦¾à¦¨à§‡à¦° " +#~ "মাধà§à¦¯à¦®à§‡ সহায়তা করà§à¦¨à¥¤ তথà§à¦¯ পà§à¦°à¦¦à¦¾à¦¨à§‡à¦° জনà§à¦¯ [color=$color][url=$url], [/url][/" +#~ "color] ফরমà§à¦¯à¦¾à¦Ÿ বà§à¦¯à¦¾à¦¬à¦¹à¦¾à¦° করà§à¦¨ !" + +#~ msgid "enum " +#~ msgstr "enum " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "সংকà§à¦·à¦¿à¦ªà§à¦¤ বরà§à¦£à¦¨à¦¾:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "বরà§à¦£à¦¨à¦¾:" + #~ msgid "Password:" #~ msgstr "পাসওয়ারà§à¦¡:" diff --git a/editor/translations/ca.po b/editor/translations/ca.po index 441fa30e91..dc618c880f 100644 --- a/editor/translations/ca.po +++ b/editor/translations/ca.po @@ -9,12 +9,13 @@ # roger <616steam@gmail.com>, 2019. # Roger BR <drai_kin@hotmail.com>, 2019. # Adolfo Jayme Barrientos <fitojb@ubuntu.com>, 2020. +# Xavier Gomez <hiulit@gmail.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" -"Last-Translator: Adolfo Jayme Barrientos <fitojb@ubuntu.com>\n" +"PO-Revision-Date: 2020-01-27 07:09+0000\n" +"Last-Translator: Xavier Gomez <hiulit@gmail.com>\n" "Language-Team: Catalan <https://hosted.weblate.org/projects/godot-engine/" "godot/ca/>\n" "Language: ca\n" @@ -22,7 +23,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -431,7 +432,7 @@ msgstr "No es pot afegir una nova pista sense cap arrel" #: editor/animation_track_editor.cpp msgid "Invalid track for Bezier (no suitable sub-properties)" -msgstr "" +msgstr "La pista no és và lida per a Bezier (no hi ha subpropietats adequades)" #: editor/animation_track_editor.cpp msgid "Add Bezier Track" @@ -500,16 +501,23 @@ msgid "" "Alternatively, use an import preset that imports animations to separate " "files." msgstr "" +"Aquesta animació pertany a una escena importada, de manera que no es desaran " +"els canvis a les pistes importades.\n" +"\n" +"Per habilitar la possibilitat d’afegir pistes personalitzades, navegueu a la " +"configuració d’importació de l’escena i establiu\n" +"\"Animation > Storage\" a \"Files\", activeu \"Animation > Keep Custom Tracks" +"\", i, després, reimporteu.\n" +"També podeu fer servir una configuració preestablerta que importi animacions " +"a fitxers separats." #: editor/animation_track_editor.cpp msgid "Warning: Editing imported animation" msgstr "Advertiment: Edició d'animació importada" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Select an AnimationPlayer node to create and edit animations." -msgstr "" -"Selecciona un AnimationPlayer a l'Arbre de l'Escena per editar-ne l'animació." +msgstr "Seleccioneu un node AnimationPlayer per a crear i editar animacions." #: editor/animation_track_editor.cpp msgid "Only show tracks from nodes selected in tree." @@ -811,9 +819,8 @@ msgid "Extra Call Arguments:" msgstr "Arguments de Crida addicionals:" #: editor/connections_dialog.cpp -#, fuzzy msgid "Receiver Method:" -msgstr "Selecciona un Mètode" +msgstr "Mètode Receptor:" #: editor/connections_dialog.cpp msgid "Advanced" @@ -1166,22 +1173,21 @@ msgid "License" msgstr "Llicència" #: editor/editor_about.cpp -#, fuzzy msgid "Third-party Licenses" msgstr "Llicències de Tercers" #: editor/editor_about.cpp -#, fuzzy msgid "" "Godot Engine relies on a number of third-party free and open source " "libraries, all compatible with the terms of its MIT license. The following " "is an exhaustive list of all such third-party components with their " "respective copyright statements and license terms." msgstr "" -"El motor Godot es recolza en una sèrie de biblioteques lliures i de codi " -"obert, totes elles compatibles amb els termes de la llicència MIT. Tot " -"seguit podeu trobar la llista exhaustiva de tots aquests components externs " -"amb llurs respectius drets d'autor i termes de llicenciament." +"Godot Engine compta amb diverses biblioteques gratuïtes i de codi obert de " +"tercers, totes compatibles amb els termes de la seva llicència MIT. A " +"continuació, es mostra una llista exhaustiva de tots aquests components de " +"tercers amb les seves respectives declaracions de copyright i termes de " +"llicència." #: editor/editor_about.cpp msgid "All Components" @@ -1196,14 +1202,13 @@ msgid "Licenses" msgstr "Llicències" #: editor/editor_asset_installer.cpp editor/project_manager.cpp -#, fuzzy msgid "Error opening package file, not in ZIP format." -msgstr "Error en obrir el arxiu comprimit, el fitxer no té el format ZIP." +msgstr "" +"S'ha produit un error en obrir el fitxer comprimit, no té el format ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Ja existeix" +msgstr "%s (Ja existeix)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1214,9 +1219,8 @@ msgid "The following files failed extraction from package:" msgstr "Ha fracassat l'extracció del paquet dels següents fitxers:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d fitxer(s) més" +msgstr "I %d fitxer(s) més." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1228,9 +1232,8 @@ msgid "Success!" msgstr "Èxit!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Continguts:" +msgstr "Contingut del Paquet:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1285,9 +1288,8 @@ msgid "Delete Bus Effect" msgstr "Elimina l'Efecte de Bus" #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Drag & drop to rearrange." -msgstr "Arrossegueu i deixeu anar per reordenar." +msgstr "Arrossegueu i deixeu anar per a reorganitzar." #: editor/editor_audio_buses.cpp msgid "Solo" @@ -1371,9 +1373,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Fitxer incorrecte. No és un disseny de bus d'à udio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Error en desar el fitxer!" +msgstr "S'ha produit un error al desar el fitxer! %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1422,28 +1423,20 @@ msgid "Valid characters:" msgstr "Carà cters và lids:" #: editor/editor_autoload_settings.cpp -#, fuzzy msgid "Must not collide with an existing engine class name." -msgstr "No pot coincidir amb noms de classe del motor ja existents." +msgstr "No ha de coincidir amb un nom de classe de motor existent." #: editor/editor_autoload_settings.cpp -#, fuzzy msgid "Must not collide with an existing built-in type name." -msgstr "" -"El Nom no és và lid. No pot coincidir amb noms de tipus integrats ja " -"existents." +msgstr "No ha de coincidir amb un nom de tipus incorporat existent." #: editor/editor_autoload_settings.cpp -#, fuzzy msgid "Must not collide with an existing global constant name." -msgstr "" -"El Nom no és và lid. No pot coincidir amb noms de constants globals ja " -"existents." +msgstr "No ha de coincidir amb una constant global existent." #: editor/editor_autoload_settings.cpp -#, fuzzy msgid "Keyword cannot be used as an autoload name." -msgstr "Una paraula clau no es pot utilitzar com a nom de cà rrega automà tica." +msgstr "La paraula clau no es pot utilitzar com a nom d'autocà rrega." #: editor/editor_autoload_settings.cpp msgid "Autoload '%s' already exists!" @@ -1595,6 +1588,10 @@ msgid "" "Enable 'Import Etc' in Project Settings, or disable 'Driver Fallback " "Enabled'." msgstr "" +"La plataforma de destinació requereix una compressió de textura 'ETC' per a " +"utilitzar GLES2 com a controlador alternatiu.\n" +"Activeu \"Import Etc\" a Configuració del Projecte o desactiveu la opció " +"'Driver Fallback Enabled''." #: editor/editor_export.cpp platform/android/export/export.cpp #: platform/iphone/export/export.cpp platform/javascript/export/export.cpp @@ -1613,11 +1610,9 @@ msgid "Template file not found:" msgstr "No s'ha trobat la Plantilla:" #: editor/editor_export.cpp -#, fuzzy msgid "On 32-bit exports the embedded PCK cannot be bigger than 4 GiB." msgstr "" -"En les exportacions de 32 bits, el PCK incrustat no pot ser més gran que 4 " -"GiB." +"En les exportacions de 32 bits, el PCK incrustat no pot ser superior a 4 GiB." #: editor/editor_feature_profile.cpp msgid "3D Editor" @@ -1961,14 +1956,29 @@ msgstr "Heretat per:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Descripció breu:" +msgid "Description" +msgstr "Descripció:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "Tutorials en lÃnia:" #: editor/editor_help.cpp msgid "Properties" msgstr "Propietats" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "Sobreescriu" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Predeterminat" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Mètodes" @@ -1981,35 +1991,17 @@ msgid "Enumerations" msgstr "Enumeracions" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Constants" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Descripció de la classe" +msgid "Property Descriptions" +msgstr "Descripcions de la Propietat" #: editor/editor_help.cpp #, fuzzy -msgid "Online Tutorials" -msgstr "Tutorials en lÃnia:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Aquesta classe no disposa encara de cap Tutorial. Podeu contribuir [color=" -"$color][url=$url] tot aportant-ne un[/url][/color] o [color=$color][url=" -"$url2]sol·licitant-lo[/url][/color]." - -#: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "Descripcions de la Propietat" +msgid "(value)" +msgstr "Valor" #: editor/editor_help.cpp msgid "" @@ -4594,7 +4586,6 @@ msgid "Animation Tools" msgstr "Eines d'Animació" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animació" @@ -5717,6 +5708,11 @@ msgid "Auto Insert Key" msgstr "Inserir Clau Automà ticament" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "S'ha insertit una Clau d'Animació." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Insereix una Clau (Pistes existents)" @@ -6010,7 +6006,6 @@ msgid "No mesh to debug." msgstr "Cap malla per depurar." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "El model no té UVs en aquesta capa" @@ -7426,6 +7421,10 @@ msgid "Cinematic Preview" msgstr "Previsualització Cinemà tica" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Vista Lliure Esquerra" @@ -12977,6 +12976,25 @@ msgstr "" msgid "Constants cannot be modified." msgstr "Les constants no es poden modificar." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Aquesta classe no disposa encara de cap Tutorial. Podeu contribuir " +#~ "[color=$color][url=$url] tot aportant-ne un[/url][/color] o [color=" +#~ "$color][url=$url2]sol·licitant-lo[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Descripció breu:" + +#~ msgid "Class Description" +#~ msgstr "Descripció de la classe" + #~ msgid "Project export failed with error code %d." #~ msgstr "L'exportació del projecte ha fallat amb el codi d'error %d." diff --git a/editor/translations/cs.po b/editor/translations/cs.po index b1c4a67f51..b060c0c234 100644 --- a/editor/translations/cs.po +++ b/editor/translations/cs.po @@ -1954,14 +1954,29 @@ msgid "Inherited by:" msgstr "DÄ›dÄ›ná z:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "StruÄný popis" +#, fuzzy +msgid "Description" +msgstr "Popis:" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Online návody" #: editor/editor_help.cpp msgid "Properties" msgstr "Vlastnosti" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "PÅ™epsat" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "VýchozÃ" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metody" @@ -1974,36 +1989,19 @@ msgid "Enumerations" msgstr "VýÄty" #: editor/editor_help.cpp -msgid "enum " -msgstr "výÄet " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstanty" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Popis tÅ™Ãdy" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Online návody" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"V souÄasné dobÄ› pro tuto tÅ™Ãdu neexistujà žádné návody, můžete nÄ›jaký [color=" -"$color][url=$url]vytvoÅ™it[/url][/color] nebo o nÄ›j [color=$color][url=" -"$url2]zažádat[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Popis vlastnosti" #: editor/editor_help.cpp +#, fuzzy +msgid "(value)" +msgstr "Hodnota" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4572,7 +4570,6 @@ msgid "Animation Tools" msgstr "Nástroje pro animaci" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animace" @@ -5655,6 +5652,11 @@ msgid "Auto Insert Key" msgstr "Animace: vložit klÃÄ" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "AnimaÄnà klÃÄ vložen." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Vložit klÃÄ (existujÃcà stopy)" @@ -5949,7 +5951,6 @@ msgid "No mesh to debug." msgstr "Žádná mesh pro debugovánÃ." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Model nemá UV v této vrstvÄ›" @@ -7363,6 +7364,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Volný pohled doleva" @@ -12726,6 +12731,24 @@ msgstr "" msgid "Constants cannot be modified." msgstr "Konstanty nenà možné upravovat." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "V souÄasné dobÄ› pro tuto tÅ™Ãdu neexistujà žádné návody, můžete nÄ›jaký " +#~ "[color=$color][url=$url]vytvoÅ™it[/url][/color] nebo o nÄ›j [color=$color]" +#~ "[url=$url2]zažádat[/url][/color]." + +#~ msgid "enum " +#~ msgstr "výÄet " + +#~ msgid "Brief Description" +#~ msgstr "StruÄný popis" + +#~ msgid "Class Description" +#~ msgstr "Popis tÅ™Ãdy" + #~ msgid "Project export failed with error code %d." #~ msgstr "Export projektu selhal s chybovým kódem %d." diff --git a/editor/translations/da.po b/editor/translations/da.po index 4c2976812c..aed35d2dc6 100644 --- a/editor/translations/da.po +++ b/editor/translations/da.po @@ -14,12 +14,13 @@ # Rémi Verschelde <akien@godotengine.org>, 2019. # Mads K. Bredager <mbredager@gmail.com>, 2019. # Kristoffer Andersen <kjaa@google.com>, 2019. +# Joe Osborne <reachjoe.o@gmail.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2019-10-04 09:55+0000\n" -"Last-Translator: Kristoffer Andersen <kjaa@google.com>\n" +"PO-Revision-Date: 2020-01-16 22:23+0000\n" +"Last-Translator: Joe Osborne <reachjoe.o@gmail.com>\n" "Language-Team: Danish <https://hosted.weblate.org/projects/godot-engine/" "godot/da/>\n" "Language: da\n" @@ -27,7 +28,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.9-dev\n" +"X-Generator: Weblate 3.10.2-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -755,7 +756,7 @@ msgstr "Kun Valgte" #: editor/code_editor.cpp editor/plugins/script_text_editor.cpp #: editor/plugins/text_editor.cpp msgid "Standard" -msgstr "" +msgstr "Standard" #: editor/code_editor.cpp editor/plugins/script_editor_plugin.cpp msgid "Toggle Scripts Panel" @@ -812,7 +813,7 @@ msgstr "Kan ikke forbinde til host:" #: editor/connections_dialog.cpp #, fuzzy msgid "From Signal:" -msgstr "Signaler:" +msgstr "Fra signal:" #: editor/connections_dialog.cpp msgid "Scene does not contain any script." @@ -2023,14 +2024,28 @@ msgstr "Arvet af:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Kort Beskrivelse:" +msgid "Description" +msgstr "Beskrivelse:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "Online Undervisning:" #: editor/editor_help.cpp msgid "Properties" msgstr "Egenskaber" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Standard" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metoder" @@ -2043,35 +2058,17 @@ msgid "Enumerations" msgstr "Tællinger" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstanter" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Klasse beskrivelse" +msgid "Property Descriptions" +msgstr "Egenskab beskrivelser" #: editor/editor_help.cpp #, fuzzy -msgid "Online Tutorials" -msgstr "Online Undervisning:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Der er i øjeblikket ingen vejledninger for denne klasse, du kan [color=" -"$color][url=$url]bidrage med en[/url][/color] eller [color=$color][url=" -"$url2]anmode en[/url][/color]." - -#: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "Egenskab beskrivelser" +msgid "(value)" +msgstr "Værdi:" #: editor/editor_help.cpp msgid "" @@ -4707,7 +4704,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5812,6 +5808,11 @@ msgid "Auto Insert Key" msgstr "Anim Indsæt Nøgle" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animations længde (i sekunder)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -6102,7 +6103,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7542,6 +7542,10 @@ msgid "Cinematic Preview" msgstr "Opretter Maske ForhÃ¥ndsvisninger" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12864,6 +12868,25 @@ msgstr "" msgid "Constants cannot be modified." msgstr "Konstanter kan ikke ændres." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Der er i øjeblikket ingen vejledninger for denne klasse, du kan [color=" +#~ "$color][url=$url]bidrage med en[/url][/color] eller [color=$color][url=" +#~ "$url2]anmode en[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Kort Beskrivelse:" + +#~ msgid "Class Description" +#~ msgstr "Klasse beskrivelse" + #~ msgid "Project export failed with error code %d." #~ msgstr "Projekt eksport fejlede med fejlkode %d." diff --git a/editor/translations/de.po b/editor/translations/de.po index d15b7a5b04..1b1ada4825 100644 --- a/editor/translations/de.po +++ b/editor/translations/de.po @@ -52,7 +52,7 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" +"PO-Revision-Date: 2020-01-20 11:39+0000\n" "Last-Translator: So Wieso <sowieso@dukun.de>\n" "Language-Team: German <https://hosted.weblate.org/projects/godot-engine/" "godot/de/>\n" @@ -61,7 +61,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1242,9 +1242,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Fehler beim Öffnen der Paketdatei, kein ZIP-Format." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Existiert bereits" +msgstr "%s (existiert bereits)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1255,9 +1254,8 @@ msgid "The following files failed extraction from package:" msgstr "Die folgenden Dateien ließen sich nicht aus dem Paket extrahieren:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d weitere Datei(en)" +msgstr "Und %s weitere Dateien." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1269,9 +1267,8 @@ msgid "Success!" msgstr "Geschafft!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Inhalt:" +msgstr "Paketinhalte:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1411,9 +1408,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Ungültige Datei, kein Audiobus-Layout." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Fehler beim Speichern der Datei!" +msgstr "Fehler beim Speichern von Datei: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1989,14 +1985,26 @@ msgid "Inherited by:" msgstr "Vererbt an:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Kurze Beschreibung" +msgid "Description" +msgstr "Beschreibung" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Anleitungen im Netz" #: editor/editor_help.cpp msgid "Properties" msgstr "Eigenschaften" #: editor/editor_help.cpp +msgid "override:" +msgstr "Ãœberschreibungen:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "Standard:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Methoden" @@ -2009,36 +2017,18 @@ msgid "Enumerations" msgstr "Aufzählungen" #: editor/editor_help.cpp -msgid "enum " -msgstr "Enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstanten" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Klassenbeschreibung" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Anleitungen im Netz" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Es gibt zurzeit keine Tutorials zu dieser Klasse. Mitwirkungen durch [color=" -"$color][url=$url]eigene Beiträge[/url][/color] oder [color=$color][url=" -"$url2]Meldung von Problemen[/url][/color] sind sehr erwünscht." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Eigenschaften-Beschreibung" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(Wert)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4601,7 +4591,6 @@ msgid "Animation Tools" msgstr "Animationswerkzeuge" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animation" @@ -5678,6 +5667,11 @@ msgid "Auto Insert Key" msgstr "Schlüsselbild automatisch einfügen" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animationsschlüsselbild eingefügt." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Schlüsselbild einfügen (in existierende Spuren)" @@ -5786,20 +5780,18 @@ msgstr "Emissionsmaske" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Schrumpfen (Pixel): " +msgstr "Festkörper-Pixel" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Rand-Pixel" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Verzeichnisse & Dateien:" +msgstr "Gerichtete Rand-Pixel" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5963,7 +5955,6 @@ msgid "No mesh to debug." msgstr "Kein Mesh zu debuggen." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Modell besitzt kein UV in dieser Schicht" @@ -7359,6 +7350,10 @@ msgid "Cinematic Preview" msgstr "Cinematische Vorschau" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Nicht verfügbar wenn der GLES2–Renderer genutzt wird." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Freisicht Links" @@ -10907,9 +10902,8 @@ msgid "Will load an existing script file." msgstr "Dies wird eine bestehende Skriptdatei laden." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "Teilung existiert bereits." +msgstr "Skriptdatei existiert bereits." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12611,11 +12605,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Farbe: #%s\n" +"LMT: Farbe festlegen\n" +"RMT: Voreinstellung entfernen" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Wählt eine Farbe vom Bildschirm aus." +msgstr "Eine Farbe innerhalb des Editorfensters auswählen." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12741,6 +12737,24 @@ msgstr "Varyings können nur in Vertex-Funktion zugewiesen werden." msgid "Constants cannot be modified." msgstr "Konstanten können nicht verändert werden." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Es gibt zurzeit keine Tutorials zu dieser Klasse. Mitwirkungen durch " +#~ "[color=$color][url=$url]eigene Beiträge[/url][/color] oder [color=$color]" +#~ "[url=$url2]Meldung von Problemen[/url][/color] sind sehr erwünscht." + +#~ msgid "enum " +#~ msgstr "Enum " + +#~ msgid "Brief Description" +#~ msgstr "Kurze Beschreibung" + +#~ msgid "Class Description" +#~ msgstr "Klassenbeschreibung" + #~ msgid "Project export failed with error code %d." #~ msgstr "Projekt-Export ist fehlgeschlagen mit Fehlercode %d." diff --git a/editor/translations/de_CH.po b/editor/translations/de_CH.po index 093718f019..fc524de9ad 100644 --- a/editor/translations/de_CH.po +++ b/editor/translations/de_CH.po @@ -2,23 +2,22 @@ # Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. # Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). # This file is distributed under the same license as the Godot source code. -# # Christian Fisch <christian.fiesel@gmail.com>, 2016. -# +# Nils <nfa106008@iet-gibb.ch>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2018-12-13 14:38+0100\n" -"Last-Translator: Christian Fisch <christian.fiesel@gmail.com>\n" -"Language-Team: Swiss High German <https://hosted.weblate.org/projects/godot-" -"engine/godot/de_CH/>\n" +"PO-Revision-Date: 2020-01-20 11:39+0000\n" +"Last-Translator: Nils <nfa106008@iet-gibb.ch>\n" +"Language-Team: German (Swiss High) <https://hosted.weblate.org/projects/" +"godot-engine/godot/de_CH/>\n" "Language: de_CH\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Poedit 2.2\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -41,108 +40,103 @@ msgstr "" #: core/math/expression.cpp msgid "self can't be used because instance is null (not passed)" -msgstr "" +msgstr "self cha nid brucht wärde wöu d Instanz null isch (nid düre cho)" #: core/math/expression.cpp msgid "Invalid operands to operator %s, %s and %s." -msgstr "" +msgstr "Invalidi Operande füre Operator %s, %s und %s." #: core/math/expression.cpp msgid "Invalid index of type %s for base type %s" -msgstr "" +msgstr "Invalide index vom Typ %s füre Basis Typ %s" #: core/math/expression.cpp msgid "Invalid named index '%s' for base type %s" -msgstr "" +msgstr "Invalid benamslete index '%s' füre Basis Typ %s" #: core/math/expression.cpp msgid "Invalid arguments to construct '%s'" -msgstr "" +msgstr "Invalidi argumänt für s '%s' z konstruiere" #: core/math/expression.cpp msgid "On call to '%s':" -msgstr "" +msgstr "Ufem ufruef für '%s':" #: core/ustring.cpp msgid "B" -msgstr "" +msgstr "B" #: core/ustring.cpp msgid "KiB" -msgstr "" +msgstr "KiB" #: core/ustring.cpp msgid "MiB" -msgstr "" +msgstr "MiB" #: core/ustring.cpp msgid "GiB" -msgstr "" +msgstr "GiB" #: core/ustring.cpp msgid "TiB" -msgstr "" +msgstr "TiB" #: core/ustring.cpp msgid "PiB" -msgstr "" +msgstr "PiB" #: core/ustring.cpp msgid "EiB" -msgstr "" +msgstr "EiB" #: editor/animation_bezier_editor.cpp msgid "Free" -msgstr "" +msgstr "Gratis" #: editor/animation_bezier_editor.cpp msgid "Balanced" -msgstr "" +msgstr "Usgliche" #: editor/animation_bezier_editor.cpp msgid "Mirror" -msgstr "" +msgstr "Spiegu" #: editor/animation_bezier_editor.cpp editor/editor_profiler.cpp msgid "Time:" -msgstr "" +msgstr "Zit:" #: editor/animation_bezier_editor.cpp msgid "Value:" -msgstr "" +msgstr "Wärt:" #: editor/animation_bezier_editor.cpp -#, fuzzy msgid "Insert Key Here" -msgstr "Bild einfügen" +msgstr "Schlüssu hie ifüege" #: editor/animation_bezier_editor.cpp -#, fuzzy msgid "Duplicate Selected Key(s)" -msgstr "Node(s) duplizieren" +msgstr "Usgwäuti Schlüssle dupliziere" #: editor/animation_bezier_editor.cpp -#, fuzzy msgid "Delete Selected Key(s)" -msgstr "Node(s) löschen" +msgstr "Usgwäuti Schlüssle lösche" #: editor/animation_bezier_editor.cpp -#, fuzzy msgid "Add Bezier Point" -msgstr "Script hinzufügen" +msgstr "Dr Bezier Punkt hinzuefüege" #: editor/animation_bezier_editor.cpp -#, fuzzy msgid "Move Bezier Points" -msgstr "Ungültige Bilder löschen" +msgstr "Dr Bezier Punkt bewege" #: editor/animation_bezier_editor.cpp editor/animation_track_editor.cpp msgid "Anim Duplicate Keys" -msgstr "Anim Bilder duplizieren" +msgstr "Anim Schlüssle Dupliziere" #: editor/animation_bezier_editor.cpp editor/animation_track_editor.cpp msgid "Anim Delete Keys" -msgstr "Anim Bilder löschen" +msgstr "Anim Schlüssle lösche" #: editor/animation_track_editor.cpp msgid "Anim Change Keyframe Time" @@ -232,37 +226,36 @@ msgstr "Animations-Node" #: editor/animation_track_editor.cpp msgid "Add Track" -msgstr "" +msgstr "Spur hinzuefüege" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Animation Looping" -msgstr "Animations-Node" +msgstr "Animationswiderholig" #: editor/animation_track_editor.cpp #: modules/visual_script/visual_script_editor.cpp msgid "Functions:" -msgstr "" +msgstr "Funktione:" #: editor/animation_track_editor.cpp msgid "Audio Clips:" -msgstr "" +msgstr "Audioclips:" #: editor/animation_track_editor.cpp msgid "Anim Clips:" -msgstr "" +msgstr "Animationsclips:" #: editor/animation_track_editor.cpp msgid "Change Track Path" -msgstr "" +msgstr "D Spur wächsle" #: editor/animation_track_editor.cpp msgid "Toggle this track on/off." -msgstr "" +msgstr "Die Spur ah-/abschaute" #: editor/animation_track_editor.cpp msgid "Update Mode (How this property is set)" -msgstr "" +msgstr "Update Modus (Wie die Eigeschaft gsetzt isch)" #: editor/animation_track_editor.cpp #, fuzzy @@ -1965,48 +1958,40 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "Script hinzufügen" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -#, fuzzy -msgid "Theme Properties" -msgstr "Node erstellen" - -#: editor/editor_help.cpp -msgid "Enumerations" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Methods" msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "Script hinzufügen" +msgid "Theme Properties" +msgstr "Node erstellen" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Constants" msgstr "" #: editor/editor_help.cpp @@ -2015,6 +2000,10 @@ msgid "Property Descriptions" msgstr "Script hinzufügen" #: editor/editor_help.cpp +msgid "(value)" +msgstr "" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4566,7 +4555,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5663,6 +5651,11 @@ msgid "Auto Insert Key" msgstr "Anim Bild einfügen" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animationsbild eingefügt." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Bild in bestehende Ebene einfügen" @@ -5954,7 +5947,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7381,6 +7373,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12622,6 +12618,10 @@ msgid "Constants cannot be modified." msgstr "" #, fuzzy +#~ msgid "Class Description" +#~ msgstr "Script hinzufügen" + +#, fuzzy #~ msgid "Base Type:" #~ msgstr "Typ ändern" diff --git a/editor/translations/editor.pot b/editor/translations/editor.pot index bae7df17e2..c1b2932a6f 100644 --- a/editor/translations/editor.pot +++ b/editor/translations/editor.pot @@ -1880,50 +1880,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4351,7 +4348,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5394,6 +5390,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5674,7 +5674,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7044,6 +7043,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/el.po b/editor/translations/el.po index 8c152332a2..99e7a49f85 100644 --- a/editor/translations/el.po +++ b/editor/translations/el.po @@ -2,7 +2,7 @@ # Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. # Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). # This file is distributed under the same license as the Godot source code. -# George Tsiamasiotis <gtsiam@windowslive.com>, 2017-2018, 2019. +# George Tsiamasiotis <gtsiam@windowslive.com>, 2017-2018, 2019, 2020. # Georgios Katsanakis <geo.elgeo@gmail.com>, 2019. # Overloaded <manoschool@yahoo.gr>, 2019. # Eternal Death <eternaldeath0001@gmail.com>, 2019. @@ -11,9 +11,8 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" -"Last-Translator: Overloaded @ Orama Interactive http://orama-interactive." -"com/ <manoschool@yahoo.gr>\n" +"PO-Revision-Date: 2020-01-27 07:09+0000\n" +"Last-Translator: George Tsiamasiotis <gtsiam@windowslive.com>\n" "Language-Team: Greek <https://hosted.weblate.org/projects/godot-engine/godot/" "el/>\n" "Language: el\n" @@ -21,7 +20,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -426,7 +425,7 @@ msgstr "ΑδÏνατη η Ï€Ïοσθήκη ÎºÎ¿Î¼Î¼Î±Ï„Î¹Î¿Ï Ï‡Ï‰Ïίς ÏίζΠ#: editor/animation_track_editor.cpp msgid "Invalid track for Bezier (no suitable sub-properties)" -msgstr "" +msgstr "ΆκυÏο κομμάτι καμπÏλης Bezier (χωÏίς κατάλληλες υπό-ιδιότητες)" #: editor/animation_track_editor.cpp msgid "Add Bezier Track" @@ -1200,9 +1199,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Σφάλμα ανοίγματος αÏχείου πακÎτου, δεν είναι σε μοÏφή ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "ΥπάÏχει ήδη" +msgstr "%s (ΥπάÏχει ήδη)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1213,9 +1211,8 @@ msgid "The following files failed extraction from package:" msgstr "Η εξαγωγή των ακόλουθων αÏχείων από το πακÎτο απÎτυχε:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d πεÏισσότεÏα αÏχεία" +msgstr "Και %s αÏχεία ακόμα." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1227,9 +1224,8 @@ msgid "Success!" msgstr "Επιτυχία!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "ΠεÏιεχόμενα:" +msgstr "ΠεÏιεχόμενα ΠακÎτου:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1369,9 +1365,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "ΆκυÏο αÏχείο, δεν είναι διάταξη διαÏλων ήχου." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Σφάλμα αποθήκευσης αÏχείου!" +msgstr "Σφάλμα αποθήκευσης αÏχείου: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1947,14 +1942,26 @@ msgid "Inherited by:" msgstr "ΚληÏονομείται από:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "ΣÏντομη ΠεÏιγÏαφή" +msgid "Description" +msgstr "ΠεÏιγÏαφή" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Διαδικτυακή Εκμάθηση" #: editor/editor_help.cpp msgid "Properties" msgstr "Ιδιότητες" #: editor/editor_help.cpp +msgid "override:" +msgstr "παÏάκαμψη:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "Ï€Ïοεπιλογή:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "ΣυναÏτήσεις" @@ -1967,36 +1974,18 @@ msgid "Enumerations" msgstr "ΑπαÏιθμήσεις" #: editor/editor_help.cpp -msgid "enum " -msgstr "απαÏίθμηση " - -#: editor/editor_help.cpp msgid "Constants" msgstr "ΣταθεÏÎÏ‚" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "ΠεÏιγÏαφή κλάσης" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Διαδικτυακή Εκμάθηση" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Δεν υπάÏχει ακόμα βοήθεια για αυτήν την κλάση, μποÏείτε να την [color=$color]" -"[url=$url]γÏάψετε[/url][/color] ή να την [color=$color][url=$url2]ζητήσετε[/" -"url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "ΠεÏιγÏαφÎÏ‚ ιδιοτήτων" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(τιμή)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -2026,9 +2015,8 @@ msgid "Case Sensitive" msgstr "ΔιάκÏιση πεζών-κεφαλαίων" #: editor/editor_help_search.cpp -#, fuzzy msgid "Show Hierarchy" -msgstr "Εμφάνιση Βοηθών" +msgstr "Εμφάνιση ΙεÏαÏχίας" #: editor/editor_help_search.cpp msgid "Display All" @@ -2067,9 +2055,8 @@ msgid "Class" msgstr "Κλάση" #: editor/editor_help_search.cpp -#, fuzzy msgid "Method" -msgstr "ΣυναÏτήσεις" +msgstr "ÎœÎθοδος" #: editor/editor_help_search.cpp editor/plugins/script_text_editor.cpp msgid "Signal" @@ -2080,14 +2067,12 @@ msgid "Constant" msgstr "ΣταθεÏή" #: editor/editor_help_search.cpp -#, fuzzy msgid "Property" -msgstr "Ιδιότητα:" +msgstr "Ιδιότητα" #: editor/editor_help_search.cpp -#, fuzzy msgid "Theme Property" -msgstr "Ιδιότητες θÎματος" +msgstr "Ιδιότητα ΘÎματος" #: editor/editor_inspector.cpp editor/project_settings_editor.cpp msgid "Property:" @@ -2868,10 +2853,10 @@ msgid "" "When used remotely on a device, this is more efficient with network " "filesystem." msgstr "" -"Όταν αυτή η επιλογή είναι ενεÏγοποιημÎνη, ÏŒ,τι αλλαγÎÏ‚ γίνουν στη σκηνή θα " -"αναπαÏαχθοÏν και στο παιχνίδι.\n" -"Όταν χÏησιμοποιηθεί απομακÏυσμÎνα σε μία συσκευή, αυτό είναι ποιο " -"αποτελεσματικό με δικτυωμÎνο σÏστημα αÏχείων." +"Η ενεÏγοποίηση της επιλογής αυτής θα συγχÏονίσει αλλαγÎÏ‚ της σκηνής εντός " +"του επεξεÏγαστή με το παιχνίδι που εκτελείται.\n" +"Σε απομακÏυσμÎνες συσκευÎÏ‚, η επιλογή είναι ποιο αποδοτική με δικτυωμÎνο " +"σÏστημα αÏχείων." #: editor/editor_node.cpp msgid "Sync Script Changes" @@ -2884,10 +2869,10 @@ msgid "" "When used remotely on a device, this is more efficient with network " "filesystem." msgstr "" -"Όταν αυτή η επιλογή είναι ενεÏγοποιημÎνη, όποια δÎσμη ενεÏγειών αποθηκευτεί " -"θα επαναφοÏτωθεί στο παιχνίδι.\n" -"Όταν χÏησιμοποιηθεί απομακÏυσμÎνα σε μία συσκευή, αυτό είναι ποιο " -"αποτελεσματικό με δικτυωμÎνο σÏστημα αÏχείων." +"Η ενεÏγοποίηση της επιλογής αυτής θα συγχÏονίσει κάθε δÎσμη ενεÏγειών που " +"αποθηκεÏεται με το παιχνίδι που εκτελείται.\n" +"Σε απομακÏυσμÎνες συσκευÎÏ‚, η επιλογή είναι ποιο αποδοτική με δικτυωμÎνο " +"σÏστημα αÏχείων." #: editor/editor_node.cpp editor/script_create_dialog.cpp msgid "Editor" @@ -3474,13 +3459,14 @@ msgid "Importing:" msgstr "Εισαγωγή:" #: editor/export_template_manager.cpp -#, fuzzy msgid "Error getting the list of mirrors." -msgstr "Σφάλμα κατά τη δημιουÏγία της υπογÏαφής του αντικειμÎνου." +msgstr "Σφάλμα απόκτησης λίστας κατοπτÏισμοÏ." #: editor/export_template_manager.cpp msgid "Error parsing JSON of mirror list. Please report this issue!" msgstr "" +"Σφάλμα ανάλυσης JSON της λίστας κατοπτÏισμοÏ. ΠαÏακαλοÏμε να αναφÎÏετε αυτό " +"το Ï€Ïόβλημα!" #: editor/export_template_manager.cpp msgid "" @@ -4567,7 +4553,6 @@ msgid "Animation Tools" msgstr "ΕÏγαλεία κινήσεων" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Κίνηση" @@ -4671,9 +4656,8 @@ msgid "Move Node" msgstr "Μετακίνηση Κόμβου" #: editor/plugins/animation_state_machine_editor.cpp -#, fuzzy msgid "Transition exists!" -msgstr "Μετάβαση: " +msgstr "ΥπαÏκτή μετάφÏαση!" #: editor/plugins/animation_state_machine_editor.cpp msgid "Add Transition" @@ -5648,6 +5632,10 @@ msgid "Auto Insert Key" msgstr "Αυτόματη Εισαγωγή ΚλειδιοÏ" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "ΕπιλογÎÏ‚ ÎšÎ»ÎµÎ¹Î´Î¹Î¿Ï ÎºÎ±Î¹ Πόζας Κίνησης" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Εισαγωγή ÎšÎ»ÎµÎ¹Î´Î¹Î¿Ï (ΥπαÏκτά κομμάτια)" @@ -5756,20 +5744,18 @@ msgstr "Μάσκα εκπομπής" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "ΣμίκÏυνση (Εικονοστοιχεία): " +msgstr "Αμιγή Εικονοστοιχεία" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Εικονοστοιχεία ΠεÏιγÏάμματος" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Φάκελοι & ΑÏχεία:" +msgstr "Εικονοστοιχεία Î ÏοσανατολισμÎνου ΠεÏιγÏάμματος" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5932,7 +5918,6 @@ msgid "No mesh to debug." msgstr "ΚανÎνα πλÎγμα για αποσφαλμάτωση." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Το μοντÎλο δεν Îχει UV σε αυτό το στÏώμα" @@ -5998,18 +5983,19 @@ msgstr "ÎœÎγεθος πεÏιγÏάμματος:" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "UV Channel Debug" -msgstr "" +msgstr "Αποσφαλμάτωση ÎšÎ±Î½Î±Î»Î¹Î¿Ï UV" #: editor/plugins/mesh_library_editor_plugin.cpp msgid "Remove item %d?" msgstr "ΑφαίÏεση του στοιχείου %d?" #: editor/plugins/mesh_library_editor_plugin.cpp -#, fuzzy msgid "" "Update from existing scene?:\n" "%s" -msgstr "ΑναπÏοσαÏμογή από την σκηνή" +msgstr "" +"ΑνανÎωση από υπαÏκτό δÎντÏο; :\n" +"%s" #: editor/plugins/mesh_library_editor_plugin.cpp msgid "Mesh Library" @@ -6924,6 +6910,8 @@ msgstr "Μόνο οι πόÏοι από το σÏστημα αÏχείων μπΠ#: modules/visual_script/visual_script_editor.cpp msgid "Can't drop nodes because script '%s' is not used in this scene." msgstr "" +"Σφάλμα τοποθÎτησης κόμβων, καθώς η δÎσμη ενεÏγειών «%s» δεν χÏησιμοποιείται " +"σε αυτήν την σκηνή." #: editor/plugins/script_text_editor.cpp msgid "Lookup Symbol" @@ -7330,6 +7318,10 @@ msgid "Cinematic Preview" msgstr "ΚινηματογÏαφική Î Ïοεπισκόπηση" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Δεν είναι διαθÎσιμο στην απόδοση GLES2." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "ΕλεÏθεÏο κοίταγμα αÏιστεÏά" @@ -7572,9 +7564,8 @@ msgid "Create Mesh2D" msgstr "ΔημιουÏγία Mesh2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "Mesh2D Preview" -msgstr "ΔημιουÏγία Ï€Ïοεπισκοπήσεων πλεγμάτων" +msgstr "Î Ïοεπισκόπηση Mesh2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create Polygon2D" @@ -7582,25 +7573,23 @@ msgstr "ΔημιουÏγία Polygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Polygon2D Preview" -msgstr "" +msgstr "Î Ïοεπισκόπηση Polygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create CollisionPolygon2D" msgstr "ΔημιουÏγία CollisionPolygon2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "CollisionPolygon2D Preview" -msgstr "ΔημιουÏγία CollisionPolygon2D" +msgstr "Î Ïοεπισκόπηση CollisionPolygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create LightOccluder2D" msgstr "ΔημιουÏγία LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "LightOccluder2D Preview" -msgstr "ΔημιουÏγία LightOccluder2D" +msgstr "Î Ïοεπισκόπηση LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Sprite is empty!" @@ -7679,9 +7668,8 @@ msgid "Add Frame" msgstr "Î Ïοσθήκη καÏÎ" #: editor/plugins/sprite_frames_editor_plugin.cpp -#, fuzzy msgid "Unable to load images" -msgstr "Δεν ήταν δυνατή η φόÏτωση της εικόνας:" +msgstr "Αδυναμία φόÏτωσης εικόνων" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "ERROR: Couldn't load frame resource!" @@ -8372,14 +8360,12 @@ msgid "Edit Tile Z Index" msgstr "Αλλαγή Δείκτη Z Πλακιδίου" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Make Convex" -msgstr "ΜετατÏοπή Πολυγώνου σε ΚυÏÏ„ÏŒ" +msgstr "ΜετατÏοπή σε ΚυÏÏ„ÏŒ" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Make Concave" -msgstr "ΜετατÏοπή Πολυγώνου σε Κοίλο" +msgstr "ΜετατÏοπή σε Κοίλο" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Create Collision Polygon" @@ -10528,13 +10514,13 @@ msgstr "" "του κόμβου στις Ï€ÏοεπιλογÎÏ‚ τους." #: editor/scene_tree_dock.cpp -#, fuzzy msgid "" "Enabling \"Load As Placeholder\" will disable \"Editable Children\" and " "cause all properties of the node to be reverted to their default." msgstr "" -"Η απενεÏγοποίηση του «editable_instance» θα επαναφÎÏει όλες τις ιδιότητες " -"του κόμβου στις Ï€ÏοεπιλογÎÏ‚ τους." +"Η ενεÏγοποίηση του «ΦόÏτωση ως μÎσο κÏάτησης» θα απενεÏγοποιήσει το " +"«ΕπεξεÏγάσιμα παιδιά» και θα επαναφÎÏει όλες τις ιδιότητες του κόμβου στις " +"Ï€ÏοεπιλογÎÏ‚ τους." #: editor/scene_tree_dock.cpp msgid "Make Local" @@ -10583,9 +10569,8 @@ msgid "Remove Node(s)" msgstr "ΑφαίÏεση κόμβων" #: editor/scene_tree_dock.cpp -#, fuzzy msgid "Change type of node(s)" -msgstr "Αλλαγή ονόματος θÏÏας εξόδου" +msgstr "Αλλαγή Ï„Ïπου κόμβων" #: editor/scene_tree_dock.cpp msgid "" @@ -10617,7 +10602,7 @@ msgstr "ΕπεξεÏγάσιμα παιδιά" #: editor/scene_tree_dock.cpp msgid "Load As Placeholder" -msgstr "ΦόÏτωση ως μÎσο κÏάτησης θÎσης" +msgstr "ΦόÏτωση ως μÎσο κÏάτησης" #: editor/scene_tree_dock.cpp msgid "Open Documentation" @@ -10712,31 +10697,28 @@ msgid "Node configuration warning:" msgstr "Î Ïοειδοποίηση διαμόÏφωσης κόμβου:" #: editor/scene_tree_editor.cpp -#, fuzzy msgid "" "Node has %s connection(s) and %s group(s).\n" "Click to show signals dock." msgstr "" -"Ο κόμβος Îχει συνδÎσεις και ομάδες.\n" -"Πατήστε για να δείξετε την πλατφόÏμα σημάτων." +"Ο κόμβος Îχει %s σÏνδεση/-εις και %s ομάδα/-ες.\n" +"Πατήστε για εμφάνιση της πλατφόÏμας σημάτων." #: editor/scene_tree_editor.cpp -#, fuzzy msgid "" "Node has %s connection(s).\n" "Click to show signals dock." msgstr "" -"Ο κόμβος Îχει συνδÎσεις\n" -"Πατήστε για να δείξετε την πλατφόÏμα σημάτων." +"Ο κόμβος Îχει %s σÏνδεση/-εις.\n" +"Πατήστε για εμφάνιση της πλατφόÏμας σημάτων." #: editor/scene_tree_editor.cpp -#, fuzzy msgid "" "Node is in %s group(s).\n" "Click to show groups dock." msgstr "" -"Ο κόμβος Îχει και ομάδες\n" -"Πατήστε για να δείξετε την πλατφόÏμα σημάτων." +"Ο κόμβος είναι σε %s ομάδα/-ες\n" +"Πατήστε για εμφάνιση της πλατφόÏμας ομάδων." #: editor/scene_tree_editor.cpp msgid "Open Script:" @@ -10831,9 +10813,8 @@ msgid "Error loading script from %s" msgstr "Σφάλμα κατά την φόÏτωση δÎσμής ενεÏγειών από %s" #: editor/script_create_dialog.cpp -#, fuzzy msgid "Overrides" -msgstr "Αντικατάσταση" +msgstr "ΠαÏακάμπτει" #: editor/script_create_dialog.cpp msgid "N/A" @@ -10880,24 +10861,20 @@ msgid "Will load an existing script file." msgstr "Θα φοÏτώσει υπαÏκτό αÏχείο δÎσμης ενεÏγειών." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "Η ενÎÏγεια '%s' υπάÏχει ήδη!" +msgstr "ΥπαÏκτό αÏχείο δÎσμης ενεÏγειών." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Class Name:" -msgstr "Όνομα κλάσης" +msgstr "Όνομα Κλάσης:" #: editor/script_create_dialog.cpp -#, fuzzy msgid "Template:" -msgstr "Î Ïότυπο" +msgstr "Î Ïότυπο:" #: editor/script_create_dialog.cpp -#, fuzzy msgid "Built-in Script:" -msgstr "Ενσωμάτωση" +msgstr "Ενσωμάτωση:" #: editor/script_create_dialog.cpp msgid "Attach Node Script" @@ -10912,38 +10889,32 @@ msgid "Bytes:" msgstr "ΨηφιολÎξεις:" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "Warning:" -msgstr "Î Ïοειδοποιήσεις:" +msgstr "Î Ïοειδοποίηση:" #: editor/script_editor_debugger.cpp msgid "Error:" msgstr "Σφάλμα:" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "C++ Error" -msgstr "ΑντιγÏαφή σφάλματος" +msgstr "Σφάλμα C++" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "C++ Error:" -msgstr "Σφάλμα:" +msgstr "Σφάλμα C++:" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "C++ Source" -msgstr "Πηγή" +msgstr "Πηγή C++" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "Source:" -msgstr "Πηγή" +msgstr "Πηγή:" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "C++ Source:" -msgstr "Πηγή" +msgstr "Πηγή C++:" #: editor/script_editor_debugger.cpp msgid "Stack Trace" @@ -10954,18 +10925,16 @@ msgid "Errors" msgstr "Σφάλματα" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "Child process connected." -msgstr "Η παιδική διαδικασία συνδÎθηκε" +msgstr "Η παιδική διεÏγασία συνδÎθηκε." #: editor/script_editor_debugger.cpp msgid "Copy Error" msgstr "ΑντιγÏαφή σφάλματος" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "Skip Breakpoints" -msgstr "Σημεία Διακοπής" +msgstr "ΠαÏάλειψη Σημείων Διακοπής" #: editor/script_editor_debugger.cpp msgid "Inspect Previous Instance" @@ -11058,19 +11027,16 @@ msgid "Export measures as CSV" msgstr "Εξαγωγή μετÏικών ως CSV" #: editor/settings_config_dialog.cpp -#, fuzzy msgid "Erase Shortcut" -msgstr "Ομαλά Îξω" +msgstr "ΔιαγÏαφή Συνόμευσης" #: editor/settings_config_dialog.cpp -#, fuzzy msgid "Restore Shortcut" -msgstr "ΣυντομεÏσεις" +msgstr "ΕπαναφοÏά Συντόμευσης" #: editor/settings_config_dialog.cpp -#, fuzzy msgid "Change Shortcut" -msgstr "Αλλαγή αγκυÏών" +msgstr "Αλλαγή Συντόμευσης" #: editor/settings_config_dialog.cpp msgid "Editor Settings" @@ -11101,9 +11067,8 @@ msgid "Change Camera Size" msgstr "Αλλαγή μεγÎθους κάμεÏας" #: editor/spatial_editor_gizmos.cpp -#, fuzzy msgid "Change Notifier AABB" -msgstr "Αλλαγή διαστάσεων ειδοποιητή" +msgstr "Ειδοποιητής Αλλαγής AABB" #: editor/spatial_editor_gizmos.cpp msgid "Change Particles AABB" @@ -11130,38 +11095,32 @@ msgid "Change Capsule Shape Height" msgstr "Αλλαγή Ïψους κάψουλας" #: editor/spatial_editor_gizmos.cpp -#, fuzzy msgid "Change Cylinder Shape Radius" -msgstr "Αλλαγή ακτίνας κάψουλας" +msgstr "Αλλαγή Ακτίνας Σχήματος ΚυλίνδÏου" #: editor/spatial_editor_gizmos.cpp -#, fuzzy msgid "Change Cylinder Shape Height" -msgstr "Αλλαγή Ïψους κάψουλας" +msgstr "Αλλαγή Ύψους Σχήματος ΚυλίνδÏου" #: editor/spatial_editor_gizmos.cpp msgid "Change Ray Shape Length" msgstr "Αλλαγή μήκους ακτίνας" #: modules/csg/csg_gizmos.cpp -#, fuzzy msgid "Change Cylinder Radius" -msgstr "Αλλαγή διαμÎÏ„Ïου φωτός" +msgstr "Αλλαγή Ακτίνας ΚυλίνδÏου" #: modules/csg/csg_gizmos.cpp -#, fuzzy msgid "Change Cylinder Height" -msgstr "Αλλαγή Ïψους κάψουλας" +msgstr "Αλλαγή Ύψους ΚυλίνδÏου" #: modules/csg/csg_gizmos.cpp -#, fuzzy msgid "Change Torus Inner Radius" -msgstr "Αλλαγή ακτίνας σφαιÏÎ¹ÎºÎ¿Ï ÏƒÏ‡Î®Î¼Î±Ï„Î¿Ï‚" +msgstr "Αλλαγή ΕσωτεÏική Ακτίνας ΤόÏου" #: modules/csg/csg_gizmos.cpp -#, fuzzy msgid "Change Torus Outer Radius" -msgstr "Αλλαγή διαμÎÏ„Ïου φωτός" +msgstr "Αλλαγή ΕξωτεÏικής Ακτίνας ΤόÏου" #: modules/gdnative/gdnative_library_editor_plugin.cpp msgid "Select the dynamic library for this entry" @@ -11201,12 +11160,11 @@ msgstr "Βιβλιοθήκη GDNative" #: modules/gdnative/gdnative_library_singleton_editor.cpp msgid "Enabled GDNative Singleton" -msgstr "" +msgstr "ΕνεÏγοποίηση Μονοσυνόλου GDNative" #: modules/gdnative/gdnative_library_singleton_editor.cpp -#, fuzzy msgid "Disabled GDNative Singleton" -msgstr "ΑπενεÏγοποίηση δείκτη ενημÎÏωσης" +msgstr "ΑπενεÏγοποίηση Μονοσυνόλου GDNative" #: modules/gdnative/gdnative_library_singleton_editor.cpp msgid "Library" @@ -11221,9 +11179,8 @@ msgid "GDNative" msgstr "GDNative" #: modules/gdscript/gdscript_functions.cpp -#, fuzzy msgid "Step argument is zero!" -msgstr "Η παÏάμετÏος step είναι μηδÎν!" +msgstr "Μηδενική παÏάμετÏος step!" #: modules/gdscript/gdscript_functions.cpp msgid "Not a script with an instance" @@ -11288,14 +11245,12 @@ msgid "GridMap Delete Selection" msgstr "GridMap ΔιαγÏαφή επιλογής" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "GridMap Fill Selection" -msgstr "GridMap ΔιαγÏαφή επιλογής" +msgstr "GridMap ΓÎμισμα Επιλογής" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "GridMap Paste Selection" -msgstr "GridMap ΔιαγÏαφή επιλογής" +msgstr "GridMap Επικόλληση Επιλογής" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "GridMap Paint" @@ -11362,9 +11317,8 @@ msgid "Cursor Clear Rotation" msgstr "ΕκκαθάÏιση πεÏιστÏοφής δÏομÎα" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "Paste Selects" -msgstr "ΔιαγÏαφή επιλογής" +msgstr "Επιλογή Επικόλλησης" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "Clear Selection" @@ -11383,13 +11337,12 @@ msgid "Pick Distance:" msgstr "Επιλογή απόστασης:" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "Filter meshes" -msgstr "ΦιλτÏάÏισμα μεθόδων" +msgstr "ΦιλτÏάÏισμα πλεγμάτων" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "Give a MeshLibrary resource to this GridMap to use its meshes." -msgstr "" +msgstr "ΟÏίστε Îναν πόÏο MeshLibrary στο GridMap για χÏήση των πλεγμάτων του." #: modules/mono/csharp_script.cpp msgid "Class name can't be a reserved keyword" @@ -11400,9 +11353,8 @@ msgid "End of inner exception stack trace" msgstr "ΤÎλος ιχνηλάτησης στοίβας εσωτεÏικής εξαίÏεσης" #: modules/recast/navigation_mesh_editor_plugin.cpp -#, fuzzy msgid "Bake NavMesh" -msgstr "Ψήσιμο NavMesh (πλÎγματος πλοήγησης)" +msgstr "Ψήσιμο NavMesh" #: modules/recast/navigation_mesh_editor_plugin.cpp msgid "Clear the navigation mesh." @@ -11519,42 +11471,36 @@ msgid "Set Variable Type" msgstr "ΟÏισμός Ï„Ïπου μεταβλητής" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Add Input Port" -msgstr "Î Ïοσθήκη θÏÏας εισόδου" +msgstr "Î Ïοσθήκη ΘÏÏας Εισόδου" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Add Output Port" -msgstr "Î Ïοσθήκη θÏÏας εξόδου" +msgstr "Î Ïοσθήκη ΘÏÏας Εξόδου" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Override an existing built-in function." -msgstr "Δεν μποÏεί να συγχÎεται με υπαÏκτό ενσωματωμÎνο όνομα Ï„Ïπου." +msgstr "ΠαÏάκαμψη υπαÏκτής ενσωματωμÎνης συνάÏτησης." #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Create a new function." -msgstr "ΔημιουÏγία νÎου οÏθογωνίου." +msgstr "ΔημιουÏγία νÎας συνάÏτησης." #: modules/visual_script/visual_script_editor.cpp msgid "Variables:" msgstr "ΜεταβλητÎÏ‚:" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Create a new variable." -msgstr "ΔημιουÏγία νÎου οÏθογωνίου." +msgstr "ΔημιουÏγία νÎας μεταβλητής." #: modules/visual_script/visual_script_editor.cpp msgid "Signals:" msgstr "Σήματα:" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Create a new signal." -msgstr "ΔημιουÏγία νÎου πολυγώνου." +msgstr "ΔημιουÏγία νÎου σήματος." #: modules/visual_script/visual_script_editor.cpp msgid "Name is not a valid identifier:" @@ -11581,9 +11527,8 @@ msgid "Add Function" msgstr "Î Ïοσθήκη συνάÏτησης" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Delete input port" -msgstr "ΑφαίÏεση θÏÏας εισόδου" +msgstr "ΔιαγÏαφή θÏÏας εισόδου" #: modules/visual_script/visual_script_editor.cpp msgid "Add Variable" @@ -11594,14 +11539,12 @@ msgid "Add Signal" msgstr "Î Ïοσθήκη σήματος" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Remove Input Port" -msgstr "ΑφαίÏεση θÏÏας εισόδου" +msgstr "ΑφαίÏεση ΘÏÏας Εισόδου" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Remove Output Port" -msgstr "ΑφαίÏεση θÏÏας εξόδου" +msgstr "ΑφαίÏεση ΘÏÏας Εξόδου" #: modules/visual_script/visual_script_editor.cpp msgid "Change Expression" @@ -11658,6 +11601,10 @@ msgid "" "Can't drop properties because script '%s' is not used in this scene.\n" "Drop holding 'Shift' to just copy the signature." msgstr "" +"Σφάλμα τοποθÎτησης ιδιοτήτων, καθώς η δÎσμη ενεÏγειών «%s» δεν " +"χÏησιμοποιείται σε αυτήν την σκηνή.\n" +"Τοποθετήστε τες κÏατώντας παÏατεταμÎνα στο «Shift» για απλή αντιγÏαφή της " +"υπογÏαφής." #: modules/visual_script/visual_script_editor.cpp msgid "Add Getter Property" @@ -11684,19 +11631,16 @@ msgid "Connect Nodes" msgstr "ΣÏνδεση κόμβων" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Disconnect Nodes" -msgstr "ΑποσÏνδεση κόμβων γÏαφήματος" +msgstr "ΑποσÏνδεση Κόμβων" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Connect Node Data" -msgstr "ΣÏνδεση κόμβων" +msgstr "ΣÏνδεση ΔεδομÎνων Κόμβων" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Connect Node Sequence" -msgstr "ΣÏνδεση κόμβων" +msgstr "ΣÏνδεση ΕκτÎλεσης Κόμβων" #: modules/visual_script/visual_script_editor.cpp msgid "Script already has function '%s'" @@ -11707,9 +11651,8 @@ msgid "Change Input Value" msgstr "Αλλαγή τιμής εισόδου" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Resize Comment" -msgstr "Αλλαγή μεγÎθους CanvasItem" +msgstr "Αλλαγή ΜεγÎθους Σχολίου" #: modules/visual_script/visual_script_editor.cpp msgid "Can't copy the function node." @@ -11724,26 +11667,24 @@ msgid "Paste VisualScript Nodes" msgstr "Επικόλληση κόμβων VisualScript" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Can't create function with a function node." -msgstr "ΑδÏνατη η αντιγÏαφή του κόμβου συνάÏτησης." +msgstr "Αδυναμία δημιουÏγίας συνάÏτησης με κόμβου συνάÏτησης." #: modules/visual_script/visual_script_editor.cpp msgid "Can't create function of nodes from nodes of multiple functions." -msgstr "" +msgstr "Αδυναμία δημιουÏγίας συνάÏτησης κόμβων από κόμβους συναÏτήσεων." #: modules/visual_script/visual_script_editor.cpp msgid "Select at least one node with sequence port." -msgstr "" +msgstr "ΕπιλÎξτε τουλάχιστον Îναν κόμβο με θÏÏα εκτÎλεσης." #: modules/visual_script/visual_script_editor.cpp msgid "Try to only have one sequence input in selection." -msgstr "" +msgstr "Î Ïοσπαθήστε να Îχετε μόνο μία είσοδο εκτÎλεσης στην επιλογή." #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Create Function" -msgstr "Μετονομασία συνάÏτησης" +msgstr "ΔημιουÏγία ΣυνάÏτησης" #: modules/visual_script/visual_script_editor.cpp msgid "Remove Function" @@ -11766,38 +11707,33 @@ msgid "Editing Signal:" msgstr "ΕπεξεÏγασία σήματος:" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Make Tool:" -msgstr "Κάνε τοπικό" +msgstr "Κάνε ΕÏγαλείο (tool):" #: modules/visual_script/visual_script_editor.cpp msgid "Members:" msgstr "ÎœÎλη:" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Change Base Type:" -msgstr "Αλλαγή Î²Î±ÏƒÎ¹ÎºÎ¿Ï Ï„Ïπου" +msgstr "Αλλαγή Î’Î±ÏƒÎ¹ÎºÎ¿Ï Î¤Ïπου:" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Add Nodes..." -msgstr "Î Ïοσθήκη Κόμβου..." +msgstr "Î Ïοσθήκη Κόμβων..." #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Add Function..." -msgstr "Î Ïοσθήκη συνάÏτησης" +msgstr "Î Ïοσθήκη ΣυνάÏτησης..." #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "function_name" -msgstr "ΣυνάÏτηση:" +msgstr "όνομα_συνάÏτησης" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Select or create a function to edit its graph." -msgstr "ΕπιλÎξτε ή δημιουÏγήστε μία συνάÏτηση για να επεξεÏγαστείτε το γÏάφημα" +msgstr "" +"ΕπιλÎξτε ή δημιουÏγήστε μία συνάÏτηση για να επεξεÏγαστείτε το γÏάφημα της." #: modules/visual_script/visual_script_editor.cpp msgid "Delete Selected" @@ -11816,19 +11752,16 @@ msgid "Cut Nodes" msgstr "Αποκοπή κόμβων" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Make Function" -msgstr "Μετονομασία συνάÏτησης" +msgstr "Κάνε ΣυνάÏτηση" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Refresh Graph" -msgstr "Αναναίωση" +msgstr "ΑνανÎωση ΓÏαφήματος" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Edit Member" -msgstr "ÎœÎλη" +msgstr "ΕπεξεÏγασία ÎœÎλους" #: modules/visual_script/visual_script_flow_control.cpp msgid "Input type not iterable: " @@ -11888,17 +11821,16 @@ msgstr "" "ή ακολουθία χαÏακτήÏων (error)." #: modules/visual_script/visual_script_property_selector.cpp -#, fuzzy msgid "Search VisualScript" -msgstr "ΑφαίÏεση κόμβου VisualScript" +msgstr "Αναζήτηση VisualScript" #: modules/visual_script/visual_script_property_selector.cpp msgid "Get %s" -msgstr "" +msgstr "Διάβασε %s" #: modules/visual_script/visual_script_property_selector.cpp msgid "Set %s" -msgstr "" +msgstr "ΘÎσε %s" #: platform/android/export/export.cpp msgid "Package name is missing." @@ -11909,10 +11841,9 @@ msgid "Package segments must be of non-zero length." msgstr "Τα τμήματα του πακÎτου Ï€ÏÎπει να Îχουν μη μηδενικό μήκος." #: platform/android/export/export.cpp -#, fuzzy msgid "The character '%s' is not allowed in Android application package names." msgstr "" -"Ο χαÏακτήÏας '%s' δεν επιτÏÎπεται στα ονόματα των πακÎτων εφαÏμογών Android." +"Ο χαÏακτήÏας «%s» απαγοÏεÏεται στο όνομα πακÎτου των εφαÏμογών Android." #: platform/android/export/export.cpp msgid "A digit cannot be the first character in a package segment." @@ -11943,11 +11874,10 @@ msgid "OpenJDK jarsigner not configured in the Editor Settings." msgstr "Το OpenJDK jarsigner δεν Îχει Ïυθμιστεί στις Ρυθμίσεις ΕπεξεÏγαστή." #: platform/android/export/export.cpp -#, fuzzy msgid "Debug keystore not configured in the Editor Settings nor in the preset." msgstr "" -"Το Debug keystore δεν Îχει Ïυθμιστεί στις Ρυθμίσεις ΕπεξεÏγαστή ή στην " -"Ï€ÏοεπιλεγμÎνη ÏÏθμιση." +"Το «debug keystore» δεν Îχει καθοÏιστεί στις Ρυθμίσεις ΕπεξεÏγαστή ή την " +"διαμόÏφωση." #: platform/android/export/export.cpp msgid "Custom build requires a valid Android SDK path in Editor Settings." @@ -11974,9 +11904,8 @@ msgid "Invalid public key for APK expansion." msgstr "Μη ÎγκυÏο δημόσιο κλειδί (public key) για επÎκταση APK." #: platform/android/export/export.cpp -#, fuzzy msgid "Invalid package name:" -msgstr "Μη ÎγκυÏο όνομα κλάσης" +msgstr "ΆκυÏο όνομα πακÎτου:" #: platform/android/export/export.cpp msgid "" @@ -12021,30 +11950,26 @@ msgid "Identifier is missing." msgstr "Το αναγνωÏιστικό λείπει." #: platform/iphone/export/export.cpp -#, fuzzy msgid "The character '%s' is not allowed in Identifier." -msgstr "Το όνομα δεν είναι ÎγκυÏο αναγνωÏιστικό:" +msgstr "Ο χαÏακτήÏας «%s» είναι άκυÏος σε αναγνωÏιστικό." #: platform/iphone/export/export.cpp -#, fuzzy msgid "App Store Team ID not specified - cannot configure the project." msgstr "" -"Το ομαδικό αναγνωÏιστικό (Team ID) App Store δεν Îχει καθοÏιστεί - δεν " -"είναι δυνατή η διαμόÏφωση του ÎÏγου." +"Δεν Îχει καθοÏιστεί αναγνωÏιστικό ομάδας (Team ID) του App Store - αδυναμία " +"διαμόÏφωσης ÎÏγου." #: platform/iphone/export/export.cpp -#, fuzzy msgid "Invalid Identifier:" -msgstr "Το όνομα δεν είναι ÎγκυÏο αναγνωÏιστικό:" +msgstr "ΆκυÏο ΑναγνωÏιστικό:" #: platform/iphone/export/export.cpp -#, fuzzy msgid "Required icon is not specified in the preset." -msgstr "Το απαιτοÏμενο εικονίδιο δεν Îχει καθοÏιστεί στην Ï€Ïοεπιλογή." +msgstr "Το απαιτοÏμενο εικονίδιο δεν Îχει καθοÏιστεί στην διαμόÏφωση." #: platform/javascript/export/export.cpp msgid "Stop HTTP Server" -msgstr "" +msgstr "ΤεÏματισμός Διακομιστή HTTP" #: platform/javascript/export/export.cpp msgid "Run in Browser" @@ -12079,19 +12004,16 @@ msgid "Using default boot splash image." msgstr "ΧÏήση Ï€ÏοεπιλεγμÎνης εικόνας εκκίνησης." #: platform/uwp/export/export.cpp -#, fuzzy msgid "Invalid package short name." -msgstr "Μη ÎγκυÏο όνομα κλάσης" +msgstr "ΆκυÏο σÏντομο όνομα πακÎτου." #: platform/uwp/export/export.cpp -#, fuzzy msgid "Invalid package unique name." -msgstr "ΆκυÏο μοναδικό όνομα." +msgstr "ΆκυÏο μοναδικό όνομα πακÎτου." #: platform/uwp/export/export.cpp -#, fuzzy msgid "Invalid package publisher display name." -msgstr "ΆκυÏο μοναδικό όνομα." +msgstr "ΆκυÏο όνομα εμφάνισης εκδότη πακÎτου." #: platform/uwp/export/export.cpp msgid "Invalid product GUID." @@ -12202,6 +12124,8 @@ msgid "" "CPUParticles2D animation requires the usage of a CanvasItemMaterial with " "\"Particles Animation\" enabled." msgstr "" +"Η κίνηση CPUParticles2D απαιτεί την χÏήση CanvasItemMaterial με το " +"«Particles Animation» ενεÏγό." #: scene/2d/light_2d.cpp #, fuzzy @@ -12253,6 +12177,9 @@ msgid "" "Use the CPUParticles2D node instead. You can use the \"Convert to " "CPUParticles\" option for this purpose." msgstr "" +"Τα σωματίδια GPU δεν υποστηÏίζονται από τον οδηγό βίντεο GLES2.\n" +"ΧÏησιμοποιήστε τον κόμβο CPUParticles2D. ΜποÏείτε να χÏησιμοποιήσετε την " +"επιλογή «Convert to CPUParticles» για αυτόν τον σκοπό." #: scene/2d/particles_2d.cpp scene/3d/particles.cpp msgid "" @@ -12267,6 +12194,8 @@ msgid "" "Particles2D animation requires the usage of a CanvasItemMaterial with " "\"Particles Animation\" enabled." msgstr "" +"Η κίνηση Particles2D απαιτεί την χÏήση ενός CanvasItemMaterial με το " +"«Particles Animation» ενεÏγό." #: scene/2d/path_2d.cpp msgid "PathFollow2D only works when set as a child of a Path2D node." @@ -12290,16 +12219,20 @@ msgstr "" #: scene/2d/skeleton_2d.cpp msgid "This Bone2D chain should end at a Skeleton2D node." -msgstr "" +msgstr "Αυτή η αλυσίδα Bone2D Ï€ÏÎπει να τελειώνει σε Îναν κόμβο Skeleton2D." #: scene/2d/skeleton_2d.cpp msgid "A Bone2D only works with a Skeleton2D or another Bone2D as parent node." msgstr "" +"Ένα Bone2D δουλεÏει μόνο με Îνα Skeleton2D ή άλλο Bone2D σαν τον γονικό του " +"κόμβο." #: scene/2d/skeleton_2d.cpp msgid "" "This bone lacks a proper REST pose. Go to the Skeleton2D node and set one." msgstr "" +"Αυτό το κόκαλο δεν Îχει θÎση REST. Πηγαίνετε στον κόμβο Skeleton2D και " +"οÏίστε την." #: scene/2d/tile_map.cpp #, fuzzy @@ -12450,6 +12383,8 @@ msgid "" "CPUParticles animation requires the usage of a SpatialMaterial whose " "Billboard Mode is set to \"Particle Billboard\"." msgstr "" +"Η κίνηση CPUParticles απαιτεί την χÏήση ενός SpatialMaterial με το Billboard " +"Mode ίσο με «Particle Billboard»." #: scene/3d/gi_probe.cpp msgid "Plotting Meshes" @@ -12491,6 +12426,9 @@ msgid "" "Use the CPUParticles node instead. You can use the \"Convert to CPUParticles" "\" option for this purpose." msgstr "" +"Τα σωματίδια GPU δεν υποστηÏίζονται από τον οδηγό βίντεο GLES2.\n" +"ΧÏησιμοποιήστε τον κόμβο CPUParticles. ΜποÏείτε να χÏησιμοποιήσετε την " +"επιλογή «Convert to CPUParticles» για αυτόν τον σκοπό." #: scene/3d/particles.cpp msgid "" @@ -12503,6 +12441,8 @@ msgid "" "Particles animation requires the usage of a SpatialMaterial whose Billboard " "Mode is set to \"Particle Billboard\"." msgstr "" +"Η κίνηση Particles απαιτεί την χÏήση ενός SpatialMaterial με το Billboard " +"Mode ίσο με «Particle Billboard»." #: scene/3d/path.cpp #, fuzzy @@ -12514,6 +12454,8 @@ msgid "" "PathFollow's ROTATION_ORIENTED requires \"Up Vector\" to be enabled in its " "parent Path's Curve resource." msgstr "" +"Το ROTATION_ORIENTED του PathFollow απαιτεί το «Up Vector» να είναι ενεÏγό " +"στον πόÏο Curve του Î³Î¿Î½Î¹ÎºÎ¿Ï Path." #: scene/3d/physics_body.cpp msgid "" @@ -12571,6 +12513,8 @@ msgid "" "WorldEnvironment requires its \"Environment\" property to contain an " "Environment to have a visible effect." msgstr "" +"Το WorldEnvironment απαιτεί τον οÏισμό της ιδιότητας «Environment» για να " +"Îχει οÏατό αποτÎλεσμα." #: scene/3d/world_environment.cpp msgid "" @@ -12589,7 +12533,7 @@ msgstr "" #: scene/animation/animation_blend_tree.cpp msgid "On BlendTree node '%s', animation not found: '%s'" -msgstr "" +msgstr "Στον κόμβο BlendTree «%s», δεν βÏÎθηκε η κίνηση: «%s»" #: scene/animation/animation_blend_tree.cpp #, fuzzy @@ -12613,7 +12557,7 @@ msgstr "ΑποσÏνδεση του '%s' απο το '%s'" #: scene/animation/animation_tree.cpp msgid "No root AnimationNode for the graph is set." -msgstr "" +msgstr "Δεν Îχει οÏιστεί Ïιζικό AnimationNode για το γÏάφημα." #: scene/animation/animation_tree.cpp #, fuzzy @@ -12625,6 +12569,7 @@ msgstr "" #: scene/animation/animation_tree.cpp msgid "Path set for AnimationPlayer does not lead to an AnimationPlayer node." msgstr "" +"Το ÏŒÏισμα διαδÏομής AnimationPlayer δεν οδηγεί σε κόμβο AnimationPlayer." #: scene/animation/animation_tree.cpp #, fuzzy @@ -12642,6 +12587,9 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"ΧÏώμα: #%s\n" +"LMB: ΟÏισμός χÏώματος\n" +"RMB: ΚατάÏγηση διαμόÏφωσης" #: scene/gui/color_picker.cpp #, fuzzy @@ -12659,7 +12607,7 @@ msgstr "ΠαÏÎκκλιση" #: scene/gui/color_picker.cpp msgid "Switch between hexadecimal and code values." -msgstr "" +msgstr "Εναλλαγή δεκαεξαδικών και κωδικοποιημÎνων τιμών." #: scene/gui/color_picker.cpp msgid "Add current color as a preset." @@ -12682,6 +12630,9 @@ msgid "" "The Hint Tooltip won't be displayed as the control's Mouse Filter is set to " "\"Ignore\". To solve this, set the Mouse Filter to \"Stop\" or \"Pass\"." msgstr "" +"Το Hint Tooltip δεν θα εμφανιστεί, καθώς το Mouse Filter του Control είναι " +"«Ignore». Για επίλυση του Ï€Ïοβλήματος, θÎστε το Mouse Filter σε «Stop» ή " +"«Pass»." #: scene/gui/dialogs.cpp msgid "Alert!" @@ -12705,6 +12656,8 @@ msgstr "" #: scene/gui/range.cpp msgid "If \"Exp Edit\" is enabled, \"Min Value\" must be greater than 0." msgstr "" +"Εάν το «Exp Edit» είναι ενεÏγό, το «Min Value» Ï€ÏÎπει να είναι μεγαλÏτεÏο " +"του 0." #: scene/gui/scroll_container.cpp #, fuzzy @@ -12759,20 +12712,38 @@ msgstr "Μη ÎγκυÏη πηγή!" #: servers/visual/shader_language.cpp msgid "Assignment to function." -msgstr "" +msgstr "Ανάθεση σε συνάÏτηση." #: servers/visual/shader_language.cpp msgid "Assignment to uniform." -msgstr "" +msgstr "Ανάθεση σε ενιαία μεταβλητή." #: servers/visual/shader_language.cpp msgid "Varyings can only be assigned in vertex function." -msgstr "" +msgstr "Τα «varying» μποÏοÏν να ανατεθοÏν μόνο στην σκίαση κοÏυφής." #: servers/visual/shader_language.cpp msgid "Constants cannot be modified." msgstr "Οι σταθεÏÎÏ‚ δεν μποÏοÏν να Ï„ÏοποποιηθοÏν." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Δεν υπάÏχει ακόμα βοήθεια για αυτήν την κλάση, μποÏείτε να την [color=" +#~ "$color][url=$url]γÏάψετε[/url][/color] ή να την [color=$color][url=" +#~ "$url2]ζητήσετε[/url][/color]." + +#~ msgid "enum " +#~ msgstr "απαÏίθμηση " + +#~ msgid "Brief Description" +#~ msgstr "ΣÏντομη ΠεÏιγÏαφή" + +#~ msgid "Class Description" +#~ msgstr "ΠεÏιγÏαφή κλάσης" + #~ msgid "Project export failed with error code %d." #~ msgstr "Η εξαγωγή του ÎÏγου απÎτυχε με κωδικό %d." diff --git a/editor/translations/eo.po b/editor/translations/eo.po index 152834ff55..f8818961c6 100644 --- a/editor/translations/eo.po +++ b/editor/translations/eo.po @@ -1927,51 +1927,49 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "Priskribo:" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "" +#, fuzzy +msgid "(value)" +msgstr "Valoro:" #: editor/editor_help.cpp #, fuzzy @@ -4456,7 +4454,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5504,6 +5501,11 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animado loneco (sekundoj)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5785,7 +5787,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7161,6 +7162,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12187,6 +12192,10 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Priskribo:" + #~ msgid "Input" #~ msgstr "Enigo" diff --git a/editor/translations/es.po b/editor/translations/es.po index 400178ff7c..7ae1e60572 100644 --- a/editor/translations/es.po +++ b/editor/translations/es.po @@ -46,7 +46,7 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-11 03:05+0000\n" +"PO-Revision-Date: 2020-01-27 07:09+0000\n" "Last-Translator: Javier Ocampos <xavier.ocampos@gmail.com>\n" "Language-Team: Spanish <https://hosted.weblate.org/projects/godot-engine/" "godot/es/>\n" @@ -55,7 +55,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10.1\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1236,9 +1236,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Error al abrir el archivo comprimido, no está en formato ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Ya existe" +msgstr "%s (Ya existe)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1249,9 +1248,8 @@ msgid "The following files failed extraction from package:" msgstr "Los siguientes archivos no se pudieron extraer del paquete:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d más archivos" +msgstr "Y %d archivos más." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1263,9 +1261,8 @@ msgid "Success!" msgstr "¡Éxito!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Contenido:" +msgstr "Contenido del Paquete:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1405,9 +1402,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Archivo inválido. No es un layout de bus de audio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "¡Error guardando archivo!" +msgstr "Error guardando el archivo: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1986,14 +1982,26 @@ msgid "Inherited by:" msgstr "Heredada por:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Descripción Breve" +msgid "Description" +msgstr "Descripción" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Tutoriales en lÃnea" #: editor/editor_help.cpp msgid "Properties" msgstr "Propiedades" #: editor/editor_help.cpp +msgid "override:" +msgstr "anulación:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "predeterminado:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Métodos" @@ -2006,36 +2014,18 @@ msgid "Enumerations" msgstr "Enumeraciones" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Constantes" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Descripción de la Clase" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Tutoriales en lÃnea" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Actualmente no existen tutoriales para esta clase, puedes [color=$color][url=" -"$url]contribuir uno[/url][/color] o [color=$color][url=$url2]solicitar uno[/" -"url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Descripción de Propiedades" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(valor)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -2761,7 +2751,7 @@ msgstr "Convertir a..." #: editor/editor_node.cpp msgid "MeshLibrary..." -msgstr "LibrerÃa de mallas..." +msgstr "MeshLibrary..." #: editor/editor_node.cpp msgid "TileSet..." @@ -4602,7 +4592,6 @@ msgid "Animation Tools" msgstr "Herramientas de Animación" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animación" @@ -5364,7 +5353,7 @@ msgid "" "Overrides game camera with editor viewport camera." msgstr "" "Reemplazar Cámara del Juego\n" -"Reemplaza la cámara del juego con la cámara del viewport del editor." +"Reemplaza la cámara del juego por la cámara del viewport del editor." #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp @@ -5373,7 +5362,7 @@ msgid "" "No game instance running." msgstr "" "Reemplazar Cámara del Juego\n" -"No hay ninguna instancia de juego ejecutándose." +"No hay ninguna instancia del juego en ejecución." #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp @@ -5677,6 +5666,10 @@ msgid "Auto Insert Key" msgstr "Auto Insertar Clave" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Clave de animación y Opciones de Pose" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Insertar clave (pistas existentes)" @@ -5785,20 +5778,18 @@ msgstr "Máscara de Emisión" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Encoger (PÃxeles): " +msgstr "Pixeles Sólidos" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "PÃxeles del Borde" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Directorios y Archivos:" +msgstr "PÃxeles del Borde Directos" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5961,7 +5952,6 @@ msgid "No mesh to debug." msgstr "No hay meshes para depurar." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "El modelo no tiene UV en esta capa" @@ -7352,6 +7342,10 @@ msgid "Cinematic Preview" msgstr "Vista Previa Cinemática" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "No disponible al utilizar el renderizador GLES2." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Vista Libre Izquierda" @@ -8286,9 +8280,9 @@ msgid "" "Shift+LMB: Set wildcard bit.\n" "Click on another Tile to edit it." msgstr "" -"Clic Izquierdo: Activar bit.\n" -"Clic Derecho: Desactivar bit.\n" -"Shift + Clic Izquierdo: Establecer valor de bit comodÃn.\n" +"Clic izq: Activar bit.\n" +"Clic der: Desactivar bit.\n" +"Shift + Clic izq: Establecer valor de bit comodÃn.\n" "Haz clic en otro Tile para editarlo." #: editor/plugins/tile_set_editor_plugin.cpp @@ -10098,7 +10092,7 @@ msgstr "Evento de Acción de Entrada Movido" #: editor/project_settings_editor.cpp msgid "Override for Feature" -msgstr "Sobrescribir la CaracterÃstica" +msgstr "Anulación de la CaracterÃstica" #: editor/project_settings_editor.cpp msgid "Add Translation" @@ -10146,7 +10140,7 @@ msgstr "General" #: editor/project_settings_editor.cpp msgid "Override For..." -msgstr "Sustituir por..." +msgstr "Anulación de..." #: editor/project_settings_editor.cpp editor/settings_config_dialog.cpp msgid "The editor must be restarted for changes to take effect." @@ -10842,7 +10836,7 @@ msgstr "Error al cargar script desde %s" #: editor/script_create_dialog.cpp msgid "Overrides" -msgstr "Sobreescritura" +msgstr "Anulaciones" #: editor/script_create_dialog.cpp msgid "N/A" @@ -10889,9 +10883,8 @@ msgid "Will load an existing script file." msgstr "Se cargará un archivo de script existente." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "La división ya existe." +msgstr "El archivo de script ya existe." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -11509,7 +11502,7 @@ msgstr "Añadir Puerto de Salida" #: modules/visual_script/visual_script_editor.cpp msgid "Override an existing built-in function." -msgstr "Sobrescribir una función incorporada existente." +msgstr "Anular una función integrada existente." #: modules/visual_script/visual_script_editor.cpp msgid "Create a new function." @@ -12594,11 +12587,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Color: #%s\n" +"Clic izq: Configurar color\n" +"Clic der: Borrar configuración predeterminada" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Selecciona un color de la pantalla." +msgstr "Selecciona un color de la ventana del editor." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12721,6 +12716,24 @@ msgstr "Solo se pueden asignar variaciones en funciones de vértice." msgid "Constants cannot be modified." msgstr "Las constantes no pueden modificarse." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Actualmente no existen tutoriales para esta clase, puedes [color=$color]" +#~ "[url=$url]contribuir uno[/url][/color] o [color=$color][url=" +#~ "$url2]solicitar uno[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Descripción Breve" + +#~ msgid "Class Description" +#~ msgstr "Descripción de la Clase" + #~ msgid "Project export failed with error code %d." #~ msgstr "La exportación del proyecto falló con el código de error %d." diff --git a/editor/translations/es_AR.po b/editor/translations/es_AR.po index 2109b2bfdb..c367f694c1 100644 --- a/editor/translations/es_AR.po +++ b/editor/translations/es_AR.po @@ -13,11 +13,12 @@ # Florencia Menéndez <mariaflormz2@gmail.com>, 2019. # roger <616steam@gmail.com>, 2019. # Francisco José Carllinni <panchopepe@protonmail.com>, 2019. +# Nicolas Zirulnik <nicolaszirulnik@gmail.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-11 03:05+0000\n" +"PO-Revision-Date: 2020-01-27 07:09+0000\n" "Last-Translator: Javier Ocampos <xavier.ocampos@gmail.com>\n" "Language-Team: Spanish (Argentina) <https://hosted.weblate.org/projects/" "godot-engine/godot/es_AR/>\n" @@ -26,7 +27,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10.1\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1205,9 +1206,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Error al abrir el archivo comprimido, no está en formato ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Ya existe" +msgstr "%s (Ya existe)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1218,9 +1218,8 @@ msgid "The following files failed extraction from package:" msgstr "Los siguientes archivos no se pudieron extraer del paquete:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d más archivos" +msgstr "Y %d archivos más." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1232,9 +1231,8 @@ msgid "Success!" msgstr "¡Éxito!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Contenido:" +msgstr "Contenido del Paquete:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1374,9 +1372,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Archivo inválido. No es un layout de bus de audio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Error guardando archivo!" +msgstr "Error guardando el archivo: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1954,14 +1951,26 @@ msgid "Inherited by:" msgstr "Heredada por:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Descripción Breve" +msgid "Description" +msgstr "Descripción" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Tutoriales en lÃnea" #: editor/editor_help.cpp msgid "Properties" msgstr "Propiedades" #: editor/editor_help.cpp +msgid "override:" +msgstr "reemplazar(override):" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "predeterminado:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Métodos" @@ -1974,36 +1983,18 @@ msgid "Enumerations" msgstr "Enumeraciones" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Constantes" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Descripción de Clase" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Tutoriales en lÃnea" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Actualmente no existen tutoriales para esta clase, podés [color=$color][url=" -"$url]contribuir uno[/url][/color] o [color=$color][url=$url2]solicitar uno[/" -"url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Descripción de Propiedades" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(valor)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4568,7 +4559,6 @@ msgid "Animation Tools" msgstr "Herramientas de Animación" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animación" @@ -5642,6 +5632,10 @@ msgid "Auto Insert Key" msgstr "Auto Insertar Clave" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Clave de animación y Opciones de Pose" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Insetar Clave (Tracks Existentes)" @@ -5750,20 +5744,18 @@ msgstr "Máscara de Emisión" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Achicar (Pixeles): " +msgstr "Pixeles Sólidos" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "PÃxeles del Borde" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Directorios y Archivos:" +msgstr "PÃxeles del Borde Directos" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5926,7 +5918,6 @@ msgid "No mesh to debug." msgstr "No hay meshes para depurar." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "El modelo no tiene UV en esta capa" @@ -7317,6 +7308,10 @@ msgid "Cinematic Preview" msgstr "Vista Previa Cinemática" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "No disponible usando el renderizador GLES2." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Vista Libre A La Izquierda" @@ -10855,9 +10850,8 @@ msgid "Will load an existing script file." msgstr "Se cargará un archivo de script existente." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "La división ya existe." +msgstr "El archivo de script ya existe." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12553,11 +12547,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Color: #%s\n" +"LMB: Configurar color\n" +"RMB: Borrar configuración predeterminada" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Elegir un color de la pantalla." +msgstr "Elegir un color de la ventana del editor." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12679,6 +12675,24 @@ msgstr "Solo se pueden asignar variaciones en funciones de vértice." msgid "Constants cannot be modified." msgstr "Las constantes no pueden modificarse." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Actualmente no existen tutoriales para esta clase, podés [color=$color]" +#~ "[url=$url]contribuir uno[/url][/color] o [color=$color][url=" +#~ "$url2]solicitar uno[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Descripción Breve" + +#~ msgid "Class Description" +#~ msgstr "Descripción de Clase" + #~ msgid "Project export failed with error code %d." #~ msgstr "La exportación del proyecto falló con el código de error %d." diff --git a/editor/translations/et.po b/editor/translations/et.po index 656b354e9b..1db95acc83 100644 --- a/editor/translations/et.po +++ b/editor/translations/et.po @@ -1890,51 +1890,49 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "" +#, fuzzy +msgid "(value)" +msgstr "Väärtus:" #: editor/editor_help.cpp msgid "" @@ -4366,7 +4364,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5412,6 +5409,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5692,7 +5693,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7063,6 +7063,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/eu.po b/editor/translations/eu.po index 4fe720ec38..b9a682553e 100644 --- a/editor/translations/eu.po +++ b/editor/translations/eu.po @@ -1885,50 +1885,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4356,7 +4353,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5399,6 +5395,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5679,7 +5679,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7049,6 +7048,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/fa.po b/editor/translations/fa.po index b1effff53c..5d071126c6 100644 --- a/editor/translations/fa.po +++ b/editor/translations/fa.po @@ -2012,14 +2012,27 @@ msgstr "به ارث رسیده به وسیله:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "خلاصه توضیØات:" +msgid "Description" +msgstr "توضیØ:" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "" #: editor/editor_help.cpp msgid "Properties" msgstr "" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "پیشÙرض" + +#: editor/editor_help.cpp msgid "Methods" msgstr "روش ها" @@ -2033,33 +2046,18 @@ msgid "Enumerations" msgstr "شمارش ها" #: editor/editor_help.cpp -msgid "enum " -msgstr "" - -#: editor/editor_help.cpp msgid "Constants" msgstr "ثابت ها" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "توضیØات" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" +msgid "Property Descriptions" +msgstr "توضیØات مشخصه:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "توضیØات مشخصه:" +msgid "(value)" +msgstr "ارزش:" #: editor/editor_help.cpp msgid "" @@ -4635,7 +4633,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5741,6 +5738,11 @@ msgid "Auto Insert Key" msgstr "کلید را در انیمیشن درج Ú©Ù†" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "طول انیمیشن (seconds)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -6031,7 +6033,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7478,6 +7479,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12845,6 +12850,14 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "خلاصه توضیØات:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "توضیØات" + #~ msgid "Password:" #~ msgstr "گذرواژه:" diff --git a/editor/translations/fi.po b/editor/translations/fi.po index 34eb8bac9b..bac46bbf8b 100644 --- a/editor/translations/fi.po +++ b/editor/translations/fi.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" +"PO-Revision-Date: 2020-01-27 07:10+0000\n" "Last-Translator: Tapani Niemi <tapani.niemi@kapsi.fi>\n" "Language-Team: Finnish <https://hosted.weblate.org/projects/godot-engine/" "godot/fi/>\n" @@ -23,7 +23,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1190,9 +1190,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Virhe avattaessa pakettitiedostoa, ei ZIP-muodossa." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "On jo olemassa" +msgstr "%s (on jo olemassa)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1203,9 +1202,8 @@ msgid "The following files failed extraction from package:" msgstr "Seuraavien tiedostojen purku paketista epäonnistui:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "Vielä %d tiedostoa" +msgstr "Ja vielä %s tiedostoa." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1217,9 +1215,8 @@ msgid "Success!" msgstr "Onnistui!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Sisällöt:" +msgstr "Paketin sisältö:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1359,9 +1356,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Virheellinen tiedosto. Tämä ei ole ääniväylän asettelu ensinkään." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Virhe tallennettaessa tiedostoa!" +msgstr "Virhe tallennettaessa tiedostoa: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1940,14 +1936,26 @@ msgid "Inherited by:" msgstr "Perivät:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Lyhyt kuvaus" +msgid "Description" +msgstr "Kuvaus" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Online-oppaat" #: editor/editor_help.cpp msgid "Properties" msgstr "Ominaisuudet" #: editor/editor_help.cpp +msgid "override:" +msgstr "ylikirjoita:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "oletus:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metodit" @@ -1960,36 +1968,18 @@ msgid "Enumerations" msgstr "Enumeraatiot" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Vakiot" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Luokan kuvaus" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Online-oppaat" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Tälle luokalle ei vielä löydy kuvausta. Voit [color=$color][url=$url]auttaa " -"luomalla sellaisen[/url][/color] tai [color=$color][url=$url2]pyytää " -"sellaisen[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Ominaisuuksien kuvaukset" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(arvo)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4525,7 +4515,6 @@ msgid "Animation Tools" msgstr "Animaatiotyökalut" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animaatio" @@ -5600,6 +5589,10 @@ msgid "Auto Insert Key" msgstr "Lisää avainruutuja automaattisesti" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Animaatioavaimen ja asennon valinnat" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Lisää avainruutu (olemassa olevat raidat)" @@ -5708,20 +5701,18 @@ msgstr "Emissiomaski" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Kutista (pikseleissä): " +msgstr "Kiinteät pikselit" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Reunapikselit" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Hakemistot ja tiedostot:" +msgstr "Suunnatut reunapikselit" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5884,7 +5875,6 @@ msgid "No mesh to debug." msgstr "Ei meshiä debugattavaksi." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Mallilla ei ole UV-kanavaa tällä kerroksella" @@ -7274,6 +7264,10 @@ msgid "Cinematic Preview" msgstr "Elokuvallinen esikatselu" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Ei käytettävissä GLES2-renderöijää käytettäessä." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Liiku vasemmalle" @@ -10804,9 +10798,8 @@ msgid "Will load an existing script file." msgstr "Lataa olemassaolevan skriptitiedoston." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "Jako on jo olemassa." +msgstr "Skriptitiedosto on jo olemassa." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12482,11 +12475,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Väri: #%s\n" +"Vasen hiirenkorva: Aseta väri\n" +"Oikea hiirenkorva: Poista esiasetus" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Valitse väri ruudulta." +msgstr "Valitse väri editori-ikkunasta." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12608,6 +12603,24 @@ msgstr "Varying tyypin voi sijoittaa vain vertex-funktiossa." msgid "Constants cannot be modified." msgstr "Vakioita ei voi muokata." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Tälle luokalle ei vielä löydy kuvausta. Voit [color=$color][url=" +#~ "$url]auttaa luomalla sellaisen[/url][/color] tai [color=$color][url=" +#~ "$url2]pyytää sellaisen[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Lyhyt kuvaus" + +#~ msgid "Class Description" +#~ msgstr "Luokan kuvaus" + #~ msgid "Project export failed with error code %d." #~ msgstr "Projektin vienti epäonnistui virhekoodilla %d." diff --git a/editor/translations/fil.po b/editor/translations/fil.po index b77c4714dd..c8a2a20684 100644 --- a/editor/translations/fil.po +++ b/editor/translations/fil.po @@ -1892,51 +1892,49 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "" +#, fuzzy +msgid "(value)" +msgstr "Halaga:" #: editor/editor_help.cpp msgid "" @@ -4365,7 +4363,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5410,6 +5407,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5692,7 +5693,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7063,6 +7063,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/fr.po b/editor/translations/fr.po index 3b761bb777..c92a8d3bb0 100644 --- a/editor/translations/fr.po +++ b/editor/translations/fr.po @@ -73,7 +73,7 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" +"PO-Revision-Date: 2020-01-16 22:32+0000\n" "Last-Translator: Rémi Verschelde <akien@godotengine.org>\n" "Language-Team: French <https://hosted.weblate.org/projects/godot-engine/" "godot/fr/>\n" @@ -82,7 +82,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n > 1;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.10.2-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1264,9 +1264,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Erreur d'ouverture de paquetage, pas au format ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Existe déjà " +msgstr "%s (existe déjà )" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1277,9 +1276,8 @@ msgid "The following files failed extraction from package:" msgstr "L'extraction des fichiers suivants depuis le paquetage a échoué :" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d fichiers supplémentaires" +msgstr "Et %s fichiers supplémentaires." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1291,9 +1289,8 @@ msgid "Success!" msgstr "Ça marche !" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Contenu :" +msgstr "Contenu du paquetage :" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1433,9 +1430,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Fichier invalide, pas une disposition de bus audio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Erreur lors de l'enregistrement du fichier !" +msgstr "Erreur lors de l'enregistrement du fichier : %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -2013,14 +2009,26 @@ msgid "Inherited by:" msgstr "Héritée par :" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Brève description" +msgid "Description" +msgstr "Description" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Tutoriels en ligne" #: editor/editor_help.cpp msgid "Properties" msgstr "Propriétés" #: editor/editor_help.cpp +msgid "override:" +msgstr "redéfinition :" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "par défaut :" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Méthodes" @@ -2033,36 +2041,18 @@ msgid "Enumerations" msgstr "Énumérations" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum_ " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Constantes" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Description de la classe" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Tutoriels en ligne" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Il n'y a pas de tutoriels disponibles pour cette classe, vous pouvez [color=" -"$color][url=$url]en créer un[/url][/color] ou [color=$color][url=$url2]en " -"demander un[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Description des propriétés" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(valeur)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4639,7 +4629,6 @@ msgid "Animation Tools" msgstr "Outils d'animation" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animation" @@ -5716,6 +5705,10 @@ msgid "Auto Insert Key" msgstr "Auto insertion de clé" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Options pour les clés et poses d'animations" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Insérer clé (pistes existantes)" @@ -5824,20 +5817,18 @@ msgstr "Masque d'émission" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Rétrécir (Pixels) : " +msgstr "Pixels pleins" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Pixels de bordure" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Répertoires et fichiers :" +msgstr "Pixels de bordure orientés" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -6002,7 +5993,6 @@ msgid "No mesh to debug." msgstr "Aucun maillage à déboguer." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Le modèle n'a pas d'UV dans cette couche" @@ -7401,6 +7391,10 @@ msgid "Cinematic Preview" msgstr "Aperçu cinématographique" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Non disponible quand le moteur de rendu GLES2 est utilisé." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Vue libre gauche" @@ -10948,9 +10942,8 @@ msgid "Will load an existing script file." msgstr "Va charger un fichier de script existant." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "Le fractionnement existe déjà ." +msgstr "Le fichier de script existe déjà ." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12663,11 +12656,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Couleur : #%s\n" +"Clic gauche : Définir la couleur\n" +"Clic droit : Supprimer le pré-réglage" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Échantillonner une couleur depuis l'écran." +msgstr "Échantillonner une couleur depuis la fenêtre de l'éditeur." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12791,6 +12786,24 @@ msgstr "Les variations ne peuvent être affectées que dans la fonction vertex." msgid "Constants cannot be modified." msgstr "Les constantes ne peuvent être modifiées." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Il n'y a pas de tutoriels disponibles pour cette classe, vous pouvez " +#~ "[color=$color][url=$url]en créer un[/url][/color] ou [color=$color][url=" +#~ "$url2]en demander un[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum_ " + +#~ msgid "Brief Description" +#~ msgstr "Brève description" + +#~ msgid "Class Description" +#~ msgstr "Description de la classe" + #~ msgid "Project export failed with error code %d." #~ msgstr "L'export du projet a échoué avec le code erreur %d." diff --git a/editor/translations/ga.po b/editor/translations/ga.po index b0876790ee..f1db3d5a78 100644 --- a/editor/translations/ga.po +++ b/editor/translations/ga.po @@ -1888,50 +1888,47 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "Cuntas:" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4362,7 +4359,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5407,6 +5403,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5687,7 +5687,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7057,6 +7056,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12046,3 +12049,7 @@ msgstr "" #: servers/visual/shader_language.cpp msgid "Constants cannot be modified." msgstr "Nà féidir tairisigh a athrú." + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Cuntas:" diff --git a/editor/translations/he.po b/editor/translations/he.po index 18a22b51be..6a153b6f11 100644 --- a/editor/translations/he.po +++ b/editor/translations/he.po @@ -2005,14 +2005,28 @@ msgstr "מוריש ×ל:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "תי×ור קצר:" +msgid "Description" +msgstr "תי×ור:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "×ž×¡×ž×›×™× ×ž×§×•×•× ×™×" #: editor/editor_help.cpp msgid "Properties" msgstr "מ××¤×™×™× ×™×" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "×˜×¢×™× ×ª בררת המחדל" + +#: editor/editor_help.cpp msgid "Methods" msgstr "שיטות" @@ -2026,34 +2040,18 @@ msgid "Enumerations" msgstr "×ž×•× ×™×" #: editor/editor_help.cpp -msgid "enum " -msgstr "×ž×•× ×” " - -#: editor/editor_help.cpp msgid "Constants" msgstr "קבועי×" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "תי×ור" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "×ž×¡×ž×›×™× ×ž×§×•×•× ×™×" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" +msgid "Property Descriptions" +msgstr "תי×ור המ×פיין:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "תי×ור המ×פיין:" +msgid "(value)" +msgstr "ערך:" #: editor/editor_help.cpp msgid "" @@ -4630,7 +4628,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5741,6 +5738,11 @@ msgid "Auto Insert Key" msgstr "×”×›× ×¡ מפתח" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "משך ×”×”× ×¤×©×” (×©× ×™×•×ª)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -6033,7 +6035,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7471,6 +7472,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12702,6 +12707,17 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#~ msgid "enum " +#~ msgstr "×ž×•× ×” " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "תי×ור קצר:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "תי×ור" + #~ msgid "Password:" #~ msgstr "ססמה:" diff --git a/editor/translations/hi.po b/editor/translations/hi.po index b46c89c8eb..424a9a6bc1 100644 --- a/editor/translations/hi.po +++ b/editor/translations/hi.po @@ -1980,47 +1980,39 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "विवरण:" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -#, fuzzy -msgid "Class Description" -msgstr "विवरण:" - -#: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Constants" msgstr "" #: editor/editor_help.cpp @@ -2029,6 +2021,11 @@ msgid "Property Descriptions" msgstr "विवरण:" #: editor/editor_help.cpp +#, fuzzy +msgid "(value)" +msgstr "मूलà¥à¤¯ :" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4511,7 +4508,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5579,6 +5575,11 @@ msgid "Auto Insert Key" msgstr "चाबी यहां डालें" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "à¤à¤¨à¤¿à¤®à¥‡à¤¶à¤¨ लंबाई समय (सेकंडà¥à¤¸)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5863,7 +5864,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7256,6 +7256,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12358,6 +12362,14 @@ msgid "Constants cannot be modified." msgstr "" #, fuzzy +#~ msgid "Brief Description" +#~ msgstr "विवरण:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "विवरण:" + +#, fuzzy #~ msgid "Class Description:" #~ msgstr "विवरण:" diff --git a/editor/translations/hr.po b/editor/translations/hr.po index f1a7f46b69..bc5abb76fc 100644 --- a/editor/translations/hr.po +++ b/editor/translations/hr.po @@ -1902,51 +1902,49 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "Opis:" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "" +#, fuzzy +msgid "(value)" +msgstr "Vrijednost:" #: editor/editor_help.cpp msgid "" @@ -4381,7 +4379,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5431,6 +5428,11 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Trajanje animacije (u sekundama)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5716,7 +5718,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7087,6 +7088,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12102,3 +12107,7 @@ msgstr "" #: servers/visual/shader_language.cpp msgid "Constants cannot be modified." msgstr "" + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Opis:" diff --git a/editor/translations/hu.po b/editor/translations/hu.po index 6571cdfcc6..af13990fdc 100644 --- a/editor/translations/hu.po +++ b/editor/translations/hu.po @@ -2024,14 +2024,28 @@ msgstr "Åt örökli:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Rövid LeÃrás:" +msgid "Description" +msgstr "LeÃrás:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "Online Oktatóanyagok:" #: editor/editor_help.cpp msgid "Properties" msgstr "Tulajdonságok" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Alapértelmezett" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metódusok" @@ -2045,37 +2059,18 @@ msgid "Enumerations" msgstr "Felsorolások" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstansok" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "LeÃrás" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "Online Oktatóanyagok:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Jelenleg nincsenek oktatóanyagok ehhez az osztályhoz. [color=$color][url=" -"$url]Hozzájárulhat eggyel[/url][/color], vagy [color=$color][url=" -"$url2]kérvényezhet egyet[/url][/color]." +msgid "Property Descriptions" +msgstr "Tulajdonság LeÃrása:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "Tulajdonság LeÃrása:" +msgid "(value)" +msgstr "Érték:" #: editor/editor_help.cpp msgid "" @@ -4746,7 +4741,6 @@ msgid "Animation Tools" msgstr "Animációs Eszközök" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animáció" @@ -5888,6 +5882,11 @@ msgid "Auto Insert Key" msgstr "Animáció kulcs beillesztés" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animáció hossza (másodpercben)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Kulcs Beszúrása (MeglévÅ‘ Nyomvonalakra)" @@ -6186,7 +6185,6 @@ msgid "No mesh to debug." msgstr "Nincs mesh a hibakereséshez." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "A modellnek nincs UV-je ezen a rétegen" @@ -7641,6 +7639,10 @@ msgid "Cinematic Preview" msgstr "Háló ElÅ‘nézetek Létrehozása" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12901,6 +12903,26 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Jelenleg nincsenek oktatóanyagok ehhez az osztályhoz. [color=$color][url=" +#~ "$url]Hozzájárulhat eggyel[/url][/color], vagy [color=$color][url=" +#~ "$url2]kérvényezhet egyet[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Rövid LeÃrás:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "LeÃrás" + #~ msgid "Project export failed with error code %d." #~ msgstr "Projekt export nem sikerült, hibakód %d." diff --git a/editor/translations/id.po b/editor/translations/id.po index 73e51a5cab..4208edb582 100644 --- a/editor/translations/id.po +++ b/editor/translations/id.po @@ -1956,14 +1956,29 @@ msgid "Inherited by:" msgstr "Diturunkan oleh:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Deskripsi Singkat" +#, fuzzy +msgid "Description" +msgstr "Deskripsi:" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Tutorial Daring" #: editor/editor_help.cpp msgid "Properties" msgstr "Properti Objek" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "Menimpa" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Bawaan" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Fungsi" @@ -1976,36 +1991,19 @@ msgid "Enumerations" msgstr "Enumerasi" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstanta" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Deskripsi Kelas" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Tutorial Daring" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Untuk saat ini tidak ada tutorial dalam kelas ini, anda bisa [color=$color]" -"[url=$url]ikut berkontribusi[/url][/color] atau [color=$color][url=" -"$url2]memberikan usulan[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Deskripsi Properti" #: editor/editor_help.cpp +#, fuzzy +msgid "(value)" +msgstr "Nilai:" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4556,7 +4554,6 @@ msgid "Animation Tools" msgstr "Perkakas Animasi" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animasi" @@ -5648,6 +5645,11 @@ msgid "Auto Insert Key" msgstr "Otomatis Sisipkan Kunci" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Kunci Animasi Dimasukkan." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Sisip Key (ke Trek yang Ada)" @@ -5933,7 +5935,6 @@ msgid "No mesh to debug." msgstr "Tidak ada mesh untuk diawakutu." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Model tidak memiliki UV dalam lapisan ini" @@ -7321,6 +7322,10 @@ msgid "Cinematic Preview" msgstr "Pratinjau Sinematik" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "TampilanBebas Kiri" @@ -12678,6 +12683,24 @@ msgstr "Variasi hanya bisa ditetapkan dalam fungsi vertex." msgid "Constants cannot be modified." msgstr "Konstanta tidak dapat dimodifikasi." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Untuk saat ini tidak ada tutorial dalam kelas ini, anda bisa [color=" +#~ "$color][url=$url]ikut berkontribusi[/url][/color] atau [color=$color][url=" +#~ "$url2]memberikan usulan[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Deskripsi Singkat" + +#~ msgid "Class Description" +#~ msgstr "Deskripsi Kelas" + #~ msgid "Project export failed with error code %d." #~ msgstr "Ekspor proyek gagal dengan kode kesalahan %d." diff --git a/editor/translations/is.po b/editor/translations/is.po index 5d3445d1c5..7a2250c0b2 100644 --- a/editor/translations/is.po +++ b/editor/translations/is.po @@ -1923,50 +1923,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4411,7 +4408,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5468,6 +5464,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5750,7 +5750,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7126,6 +7125,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/it.po b/editor/translations/it.po index deb6a489ef..a549df218c 100644 --- a/editor/translations/it.po +++ b/editor/translations/it.po @@ -36,17 +36,18 @@ # Davide Giuliano <davidegiuliano00@gmail.com>, 2019. # Stefano Merazzi <asso99@hotmail.com>, 2019. # Sinapse X <sinapsex13@gmail.com>, 2019. -# Micila Micillotto <micillotto@gmail.com>, 2019. +# Micila Micillotto <micillotto@gmail.com>, 2019, 2020. # Mirko Soppelsa <miknsop@gmail.com>, 2019. # No <kingofwizards.kw7@gmail.com>, 2019. # StarFang208 <polaritymanx@yahoo.it>, 2019. # Katia Piazza <gydey@ridiculousglitch.com>, 2019. # nickfla1 <lanterniniflavio@gmail.com>, 2019. +# Fabio Iotti <fabiogiopla@gmail.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2019-12-30 17:25+0000\n" +"PO-Revision-Date: 2020-01-27 07:09+0000\n" "Last-Translator: Micila Micillotto <micillotto@gmail.com>\n" "Language-Team: Italian <https://hosted.weblate.org/projects/godot-engine/" "godot/it/>\n" @@ -55,7 +56,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -456,7 +457,7 @@ msgstr "Non è possibile aggiungere una nuova traccia senza un nodo root" #: editor/animation_track_editor.cpp msgid "Invalid track for Bezier (no suitable sub-properties)" -msgstr "" +msgstr "Traccia non valida per la curva Bézier (nessuna sottoproprietà adatta)" #: editor/animation_track_editor.cpp msgid "Add Bezier Track" @@ -1229,9 +1230,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Errore nell'apertura del file package: non è in formato ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Già esistente" +msgstr "%s (già esistente)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1242,9 +1242,8 @@ msgid "The following files failed extraction from package:" msgstr "Impossibile estrarre i file seguenti dal pacchetto:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d altri file" +msgstr "E %s altri file." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1256,9 +1255,8 @@ msgid "Success!" msgstr "Successo!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Contenuti:" +msgstr "Contenuti del pacchetto:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1398,9 +1396,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "File non valido, non è una disposizione di un bus audio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Errore nel salvataggio file!" +msgstr "Errore nel salvataggio file: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1978,14 +1975,26 @@ msgid "Inherited by:" msgstr "Ereditato da:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Breve descrizione" +msgid "Description" +msgstr "Descrizione" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Tutorial Online" #: editor/editor_help.cpp msgid "Properties" msgstr "Proprietà " #: editor/editor_help.cpp +msgid "override:" +msgstr "sovrascrivi:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "predefinito:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metodi" @@ -1998,36 +2007,18 @@ msgid "Enumerations" msgstr "Enumerazioni" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Costanti" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Descrizione della classe" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Tutorial Online" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Al momento non esiste alcuna descrizione per questa classe. Aiutaci [color=" -"$color][url=$url]aggiungendone una[/url][/color] oppure [color=$color][url=" -"$url2]richiedendone una[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Descrizioni delle proprietà " #: editor/editor_help.cpp +msgid "(value)" +msgstr "(valore)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -2054,12 +2045,11 @@ msgstr "Cerca aiuto" #: editor/editor_help_search.cpp msgid "Case Sensitive" -msgstr "Case Sensitive" +msgstr "Distinzione maiuscole/minuscole" #: editor/editor_help_search.cpp -#, fuzzy msgid "Show Hierarchy" -msgstr "Mostra Guide" +msgstr "Mostra dipendenze" #: editor/editor_help_search.cpp msgid "Display All" @@ -2098,9 +2088,8 @@ msgid "Class" msgstr "Classe" #: editor/editor_help_search.cpp -#, fuzzy msgid "Method" -msgstr "Metodi" +msgstr "Metodo" #: editor/editor_help_search.cpp editor/plugins/script_text_editor.cpp msgid "Signal" @@ -2111,12 +2100,10 @@ msgid "Constant" msgstr "Costante" #: editor/editor_help_search.cpp -#, fuzzy msgid "Property" -msgstr "Proprietà :" +msgstr "Proprietà " #: editor/editor_help_search.cpp -#, fuzzy msgid "Theme Property" msgstr "Proprietà del tema" @@ -3505,13 +3492,14 @@ msgid "Importing:" msgstr "Importo:" #: editor/export_template_manager.cpp -#, fuzzy msgid "Error getting the list of mirrors." -msgstr "Errore in creazione del signature object." +msgstr "Errore nella ricezione della lista dei mirror." #: editor/export_template_manager.cpp msgid "Error parsing JSON of mirror list. Please report this issue!" msgstr "" +"Errore elaborazione JSON della lista dei mirror. Si prega di segnalare " +"questo problema!" #: editor/export_template_manager.cpp msgid "" @@ -3524,7 +3512,7 @@ msgstr "" #: editor/export_template_manager.cpp #: editor/plugins/asset_library_editor_plugin.cpp msgid "Can't resolve." -msgstr "Impossibile risolvete." +msgstr "Impossibile risolvere." #: editor/export_template_manager.cpp #: editor/plugins/asset_library_editor_plugin.cpp @@ -4597,7 +4585,6 @@ msgid "Animation Tools" msgstr "Strumenti di Animazione" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animazione" @@ -4701,9 +4688,8 @@ msgid "Move Node" msgstr "Sposta Nodo" #: editor/plugins/animation_state_machine_editor.cpp -#, fuzzy msgid "Transition exists!" -msgstr "Transizioni" +msgstr "La transizione esiste!" #: editor/plugins/animation_state_machine_editor.cpp msgid "Add Transition" @@ -5673,6 +5659,10 @@ msgid "Auto Insert Key" msgstr "Inserimento Automatico Chiave" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Chiavi d'Animazione e Opzioni Posa" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Inserisci Key (Tracce Esistenti)" @@ -5781,20 +5771,18 @@ msgstr "Maschera Emissione" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Rimpicciolisci (Pixels): " +msgstr "Pixel Solidi" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Pixel del Bordo" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "File e cartelle:" +msgstr "Pixel dei Bordi Diretti" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5958,7 +5946,6 @@ msgid "No mesh to debug." msgstr "Nessuna mesh da debuggare." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Il modello non ha UV su questo layer" @@ -6024,18 +6011,19 @@ msgstr "Dimensione Outline:" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "UV Channel Debug" -msgstr "" +msgstr "Debug del Canale UV" #: editor/plugins/mesh_library_editor_plugin.cpp msgid "Remove item %d?" msgstr "Rimuovi elemento %d?" #: editor/plugins/mesh_library_editor_plugin.cpp -#, fuzzy msgid "" "Update from existing scene?:\n" "%s" -msgstr "Aggiorna da Scena" +msgstr "" +"Aggiornare da scena esistente?:\n" +"%s" #: editor/plugins/mesh_library_editor_plugin.cpp msgid "Mesh Library" @@ -7349,6 +7337,10 @@ msgid "Cinematic Preview" msgstr "Anteprima Cinematografica" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Non disponibile quando il renderer GLES2 è in uso." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Vista Libera Sinistra" @@ -7590,35 +7582,32 @@ msgid "Create Mesh2D" msgstr "Crea Mesh2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "Mesh2D Preview" -msgstr "Creazione Anteprime Mesh" +msgstr "Anteprima Mesh2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create Polygon2D" -msgstr "Crea Poligono 2D" +msgstr "Crea Polygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Polygon2D Preview" -msgstr "" +msgstr "Anteprima Polygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create CollisionPolygon2D" -msgstr "Crea Poligono di Collisione 2D" +msgstr "Crea CollisionPolygon2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "CollisionPolygon2D Preview" -msgstr "Crea Poligono di Collisione 2D" +msgstr "Anteprima CollisionPolygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create LightOccluder2D" -msgstr "Crea Occlusore di Luce 2D" +msgstr "Crea LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "LightOccluder2D Preview" -msgstr "Crea Occlusore di Luce 2D" +msgstr "Crea LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Sprite is empty!" @@ -7644,7 +7633,7 @@ msgstr "Geometria non valida, impossibile creare il poligono." #: editor/plugins/sprite_editor_plugin.cpp msgid "Convert to Polygon2D" -msgstr "Converti in Poligono 2D" +msgstr "Converti in Polygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Invalid geometry, can't create collision polygon." @@ -7652,7 +7641,7 @@ msgstr "Geometria non valida, impossibile creare un poligono di collisione." #: editor/plugins/sprite_editor_plugin.cpp msgid "Create CollisionPolygon2D Sibling" -msgstr "Crea fratello del Poligono di Collisione 2D" +msgstr "Crea fratello del CollisionPolygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Invalid geometry, can't create light occluder." @@ -7660,7 +7649,7 @@ msgstr "Geometria non valida, impossibile creare un occlusore di luce." #: editor/plugins/sprite_editor_plugin.cpp msgid "Create LightOccluder2D Sibling" -msgstr "Crea fratello di Occlusore di Luce 2D" +msgstr "Crea fratello del LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Sprite" @@ -7699,9 +7688,8 @@ msgid "Add Frame" msgstr "Aggiungi frame" #: editor/plugins/sprite_frames_editor_plugin.cpp -#, fuzzy msgid "Unable to load images" -msgstr "Impossibile caricare immagine:" +msgstr "Impossibile caricare le immagini" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "ERROR: Couldn't load frame resource!" @@ -8393,14 +8381,12 @@ msgid "Edit Tile Z Index" msgstr "Modifica Indice Z della Tile" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Make Convex" -msgstr "Rendi il Poligono Convesso" +msgstr "Rendi Convesso" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Make Concave" -msgstr "Rendi il Poligono Concavo" +msgstr "Rendi Concavo" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Create Collision Polygon" @@ -10895,9 +10881,8 @@ msgid "Will load an existing script file." msgstr "Caricherà un file di script esistente." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "L'Azione '%s' esiste già !" +msgstr "Il file di script esiste già ." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -11349,9 +11334,8 @@ msgid "Cursor Clear Rotation" msgstr "Cursore Cancella Rotazione" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "Paste Selects" -msgstr "Cancella Selezione" +msgstr "Incolla Selezioni" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "Clear Selection" @@ -12597,11 +12581,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Colore: #%s\n" +"LMB: Imposta colore\n" +"RMB: Rimuovi preset" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Scegliere un colore dallo schermo." +msgstr "Scegli un colore dalla finestra dell'editor." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12721,6 +12707,24 @@ msgstr "Varyings può essere assegnato soltanto nella funzione del vertice." msgid "Constants cannot be modified." msgstr "Le constanti non possono essere modificate." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Al momento non esiste alcuna descrizione per questa classe. Aiutaci " +#~ "[color=$color][url=$url]aggiungendone una[/url][/color] oppure [color=" +#~ "$color][url=$url2]richiedendone una[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Breve descrizione" + +#~ msgid "Class Description" +#~ msgstr "Descrizione della classe" + #~ msgid "Project export failed with error code %d." #~ msgstr "Esportazione progetto fallita con codice di errore %d." diff --git a/editor/translations/ja.po b/editor/translations/ja.po index 88a9cefed7..af2cca2ca6 100644 --- a/editor/translations/ja.po +++ b/editor/translations/ja.po @@ -35,8 +35,8 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-12 13:25+0000\n" -"Last-Translator: sporeball <sporeballdev@gmail.com>\n" +"PO-Revision-Date: 2020-01-27 07:09+0000\n" +"Last-Translator: Wataru Onuki <bettawat@yahoo.co.jp>\n" "Language-Team: Japanese <https://hosted.weblate.org/projects/godot-engine/" "godot/ja/>\n" "Language: ja\n" @@ -44,7 +44,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Weblate 3.10.1\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -681,7 +681,7 @@ msgstr "コピー" #: editor/animation_track_editor.cpp msgid "Select All/None" -msgstr "å…¨ã¦ã‚’é¸æŠž/解除" +msgstr "ã™ã¹ã¦ã‚’é¸æŠž/解除" #: editor/animation_track_editor_plugins.cpp msgid "Add Audio Track Clip" @@ -928,7 +928,7 @@ msgstr "ã“ã®ã‚·ã‚°ãƒŠãƒ«ã‹ã‚‰å…¨ã¦ã®æŽ¥ç¶šã‚’除去ã—ã¦ã‚‚よã‚ã—ã„㧠#: editor/connections_dialog.cpp msgid "Disconnect All" -msgstr "å…¨ã¦åˆ‡æ–" +msgstr "ã™ã¹ã¦åˆ‡æ–" #: editor/connections_dialog.cpp msgid "Edit..." @@ -1202,7 +1202,7 @@ msgstr "" #: editor/editor_about.cpp msgid "All Components" -msgstr "å…¨ã¦ã®ã‚³ãƒ³ãƒãƒ¼ãƒãƒ³ãƒˆ" +msgstr "ã™ã¹ã¦ã®ã‚³ãƒ³ãƒãƒ¼ãƒãƒ³ãƒˆ" #: editor/editor_about.cpp msgid "Components" @@ -1217,9 +1217,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "パッケージファイルを開ã‘ã¾ã›ã‚“ã§ã—ãŸã€zip å½¢å¼ã§ã¯ã‚ã‚Šã¾ã›ã‚“。" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "æ—¢ã«å˜åœ¨ã—ã¾ã™" +msgstr "%s (ã™ã§ã«å˜åœ¨ã—ã¾ã™)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1230,9 +1229,8 @@ msgid "The following files failed extraction from package:" msgstr "次ã®ãƒ•ã‚¡ã‚¤ãƒ«ã‚’パッケージã‹ã‚‰æŠ½å‡ºã§ãã¾ã›ã‚“ã§ã—ãŸ:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d 以上ã®ãƒ•ã‚¡ã‚¤ãƒ«" +msgstr "ãŠã‚ˆã³ %s 個ã®ãƒ•ã‚¡ã‚¤ãƒ«ã€‚" #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1244,9 +1242,8 @@ msgid "Success!" msgstr "æˆåŠŸï¼" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "コンテンツ:" +msgstr "パッケージã®å†…容:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1386,9 +1383,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "無効ãªãƒ•ã‚¡ã‚¤ãƒ«ã§ã™ã€‚オーディオãƒã‚¹ã®ãƒ¬ã‚¤ã‚¢ã‚¦ãƒˆã§ã¯ã‚ã‚Šã¾ã›ã‚“。" #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "ファイルã®ä¿å˜ã‚¨ãƒ©ãƒ¼!" +msgstr "ファイルã®ä¿å˜ã‚¨ãƒ©ãƒ¼: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1964,14 +1960,26 @@ msgid "Inherited by:" msgstr "継承先:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "è¦ç´„" +msgid "Description" +msgstr "説明" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "オンラインãƒãƒ¥ãƒ¼ãƒˆãƒªã‚¢ãƒ«" #: editor/editor_help.cpp msgid "Properties" msgstr "プãƒãƒ‘ティ" #: editor/editor_help.cpp +msgid "override:" +msgstr "上書ã:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "デフォルト:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "メソッド" @@ -1984,36 +1992,18 @@ msgid "Enumerations" msgstr "列挙型" #: editor/editor_help.cpp -msgid "enum " -msgstr "列挙型 " - -#: editor/editor_help.cpp msgid "Constants" msgstr "定数" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "クラスã®èª¬æ˜Ž" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "オンラインãƒãƒ¥ãƒ¼ãƒˆãƒªã‚¢ãƒ«" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"ç¾åœ¨ã€ã“ã®ã‚¯ãƒ©ã‚¹ã®ãƒãƒ¥ãƒ¼ãƒˆãƒªã‚¢ãƒ«ã¯ã‚ã‚Šã¾ã›ã‚“ãŒã€[color=$color][url=$url]貢献" -"[/url][/color]ã€ã¾ãŸã¯[color=$color][url=$url2]リクエスト[/url][/color]ã¯å¯èƒ½" -"ã§ã™ã€‚" - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "プãƒãƒ‘ティã®èª¬æ˜Ž" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(値)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -2043,9 +2033,8 @@ msgid "Case Sensitive" msgstr "大文å—å°æ–‡å—を区別" #: editor/editor_help_search.cpp -#, fuzzy msgid "Show Hierarchy" -msgstr "ヘルパーを表示" +msgstr "階層表示" #: editor/editor_help_search.cpp msgid "Display All" @@ -2084,7 +2073,6 @@ msgid "Class" msgstr "クラス" #: editor/editor_help_search.cpp -#, fuzzy msgid "Method" msgstr "メソッド" @@ -2632,7 +2620,7 @@ msgstr "ä»–ã®ã‚¿ãƒ–ã‚’é–‰ã˜ã‚‹" #: editor/editor_node.cpp msgid "Close Tabs to the Right" -msgstr "タブをå³ã«é–‰ã˜ã‚‹" +msgstr "å³å´ã®ã‚¿ãƒ–ã‚’é–‰ã˜ã‚‹" #: editor/editor_node.cpp msgid "Close All Tabs" @@ -2720,7 +2708,7 @@ msgstr "シーンをä¿å˜" #: editor/editor_node.cpp msgid "Save All Scenes" -msgstr "å…¨ã¦ã®ã‚·ãƒ¼ãƒ³ã‚’ä¿å˜" +msgstr "ã™ã¹ã¦ã®ã‚·ãƒ¼ãƒ³ã‚’ä¿å˜" #: editor/editor_node.cpp msgid "Convert To..." @@ -3468,9 +3456,8 @@ msgid "Importing:" msgstr "インãƒãƒ¼ãƒˆä¸:" #: editor/export_template_manager.cpp -#, fuzzy msgid "Error getting the list of mirrors." -msgstr "ç½²åオブジェクトã®ç”Ÿæˆã‚¨ãƒ©ãƒ¼" +msgstr "ミラーリストã®å–得エラー。" #: editor/export_template_manager.cpp msgid "Error parsing JSON of mirror list. Please report this issue!" @@ -4550,7 +4537,6 @@ msgid "Animation Tools" msgstr "アニメーションツール" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "アニメーション" @@ -4654,9 +4640,8 @@ msgid "Move Node" msgstr "ノードを移動" #: editor/plugins/animation_state_machine_editor.cpp -#, fuzzy msgid "Transition exists!" -msgstr "トランジション: " +msgstr "トランジションãŒå˜åœ¨ã—ã¦ã„ã¾ã™ï¼" #: editor/plugins/animation_state_machine_editor.cpp msgid "Add Transition" @@ -4750,7 +4735,7 @@ msgstr "プレイモード:" #: editor/plugins/animation_tree_editor_plugin.cpp #: editor/plugins/animation_tree_player_editor_plugin.cpp msgid "AnimationTree" -msgstr "アニメーションツリー" +msgstr "AnimationTree(アニメーションツリー)" #: editor/plugins/animation_tree_player_editor_plugin.cpp msgid "New name:" @@ -5137,7 +5122,7 @@ msgstr "グリッドã®ã‚¹ãƒ†ãƒƒãƒ—:" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Primary Line Every:" -msgstr "" +msgstr "基本ラインã®é–“éš”:" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "steps" @@ -5312,6 +5297,8 @@ msgid "" "Game Camera Override\n" "Overrides game camera with editor viewport camera." msgstr "" +"ゲームカメラã®ç½®ãæ›ãˆ\n" +"エディタã®ãƒ“ューãƒãƒ¼ãƒˆã‚«ãƒ¡ãƒ©ã§ã‚²ãƒ¼ãƒ カメラを置ãæ›ãˆã‚‹ã€‚" #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp @@ -5319,6 +5306,8 @@ msgid "" "Game Camera Override\n" "No game instance running." msgstr "" +"ゲームカメラã®ç½®ãæ›ãˆ\n" +"実行ä¸ã®ã‚²ãƒ¼ãƒ インスタンス無ã—。" #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp @@ -5618,6 +5607,11 @@ msgid "Auto Insert Key" msgstr "自動ã‚ー挿入" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "アニメーションã‚ーãŒæŒ¿å…¥ã•ã‚Œã¾ã—ãŸã€‚" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "(æ—¢å˜ã®ãƒˆãƒ©ãƒƒã‚¯ã«)ã‚ーを挿入" @@ -5722,24 +5716,22 @@ msgstr "生æˆã—ãŸãƒã‚¤ãƒ³ãƒˆã®æ•°:" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Emission Mask" -msgstr "放出マスク" +msgstr "\\ Emission Mask" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "ç¸®å° (ピクセル): " +msgstr "å‡é›†ãƒ”クセル" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "境界ピクセル" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "ディレクトリã¨ãƒ•ã‚¡ã‚¤ãƒ«:" +msgstr "æ–¹å‘ã‚り境界ピクセル" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5749,7 +5741,7 @@ msgstr "ピクセルã‹ã‚‰ã‚ャプãƒãƒ£" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Emission Colors" -msgstr "放出時ã®è‰²" +msgstr "発光(Emission)色" #: editor/plugins/cpu_particles_editor_plugin.cpp msgid "CPUParticles" @@ -5863,7 +5855,7 @@ msgstr "メッシュãŒã‚ã‚Šã¾ã›ã‚“!" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "Create Static Trimesh Body" -msgstr "é™çš„三角形メッシュ ボディを作æˆ" +msgstr "三角形メッシュé™çš„ボディを作æˆ" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "Create Static Convex Body" @@ -5875,7 +5867,7 @@ msgstr "シーンã®ãƒ«ãƒ¼ãƒˆã§ã¯ç„¡åŠ¹ã§ã™!" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "Create Trimesh Static Shape" -msgstr "é™çš„三角形メッシュ シェイプを生æˆ" +msgstr "三角形メッシュé™çš„シェイプを生æˆ" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "Failed creating shapes!" @@ -5902,7 +5894,6 @@ msgid "No mesh to debug." msgstr "デãƒãƒƒã‚°ã™ã‚‹ãƒ¡ãƒƒã‚·ãƒ¥ãŒã‚ã‚Šã¾ã›ã‚“。" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "モデルã«ã¯ã“ã®ãƒ¬ã‚¤ãƒ¤ãƒ¼ã«UVãŒã‚ã‚Šã¾ã›ã‚“" @@ -5932,7 +5923,7 @@ msgstr "メッシュ" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "Create Trimesh Static Body" -msgstr "é™çš„三角形メッシュボディを作æˆ" +msgstr "三角形メッシュé™çš„ボディを作æˆ" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "Create Trimesh Collision Sibling" @@ -5968,18 +5959,19 @@ msgstr "アウトラインã®ã‚µã‚¤ã‚º:" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "UV Channel Debug" -msgstr "" +msgstr "UVãƒãƒ£ãƒ³ãƒãƒ« デãƒãƒƒã‚°" #: editor/plugins/mesh_library_editor_plugin.cpp msgid "Remove item %d?" msgstr "アイテム%dã‚’å–り除ãã¾ã™ã‹ï¼Ÿ" #: editor/plugins/mesh_library_editor_plugin.cpp -#, fuzzy msgid "" "Update from existing scene?:\n" "%s" -msgstr "シーンã‹ã‚‰ã‚¢ãƒƒãƒ—デート" +msgstr "" +"æ—¢å˜ã‚·ãƒ¼ãƒ³ã‹ã‚‰ã‚¢ãƒƒãƒ—デートã—ã¾ã™ã‹ï¼Ÿ:\n" +"%s" #: editor/plugins/mesh_library_editor_plugin.cpp msgid "Mesh Library" @@ -7295,6 +7287,10 @@ msgid "Cinematic Preview" msgstr "ã‚·ãƒãƒžãƒ†ã‚£ãƒƒã‚¯ãƒ—レビュー" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "GLES2レンダラーã®å ´åˆã¯åˆ©ç”¨ã§ãã¾ã›ã‚“。" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "フリールック左" @@ -7336,9 +7332,8 @@ msgstr "" "ゲーム内ã®ãƒ‘フォーマンスを確実ã«ç¤ºã™ã‚‚ã®ã¨ã—ã¦ä½¿ç”¨ã™ã‚‹ã“ã¨ã¯ã§ãã¾ã›ã‚“。" #: editor/plugins/spatial_editor_plugin.cpp -#, fuzzy msgid "View Rotation Locked" -msgstr "æƒ…å ±ã‚’è¡¨ç¤º" +msgstr "ビューã®å›žè»¢ã‚’固定ä¸" #: editor/plugins/spatial_editor_plugin.cpp msgid "XForm Dialog" @@ -7418,7 +7413,7 @@ msgstr "フリールックã®åˆ‡ã‚Šæ›¿ãˆ" #: editor/plugins/spatial_editor_plugin.cpp #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Transform" -msgstr "変形" +msgstr "幾何å¦å¤‰æ›(変形)" #: editor/plugins/spatial_editor_plugin.cpp msgid "Snap Object to Floor" @@ -7535,12 +7530,11 @@ msgstr "ç„¡åã®ã‚®ã‚ºãƒ¢" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create Mesh2D" -msgstr "メッシュ2Dを作æˆ" +msgstr "Mesh2Dを作æˆã™ã‚‹" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "Mesh2D Preview" -msgstr "メッシュプレビューを作æˆ" +msgstr "Mesh2D プレビュー" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create Polygon2D" @@ -7548,25 +7542,23 @@ msgstr "Polygon2Dを作æˆ" #: editor/plugins/sprite_editor_plugin.cpp msgid "Polygon2D Preview" -msgstr "" +msgstr "Polygon2D プレビュー" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create CollisionPolygon2D" msgstr "CollisionPolygon2Dを作æˆ" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "CollisionPolygon2D Preview" -msgstr "CollisionPolygon2Dを作æˆ" +msgstr "CollisionPolygon2D プレビュー" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create LightOccluder2D" msgstr "LightOccluder2Dを作æˆ" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "LightOccluder2D Preview" -msgstr "LightOccluder2Dを作æˆ" +msgstr "LightOccluder2D プレビュー" #: editor/plugins/sprite_editor_plugin.cpp msgid "Sprite is empty!" @@ -7582,7 +7574,7 @@ msgstr "ジオメトリãŒç„¡åŠ¹ã§ã™ã€‚メッシュã«ç½®ãæ›ãˆã‚‹ã“ã¨ã¯ #: editor/plugins/sprite_editor_plugin.cpp msgid "Convert to Mesh2D" -msgstr "メッシュ2Dã«å¤‰æ›" +msgstr "Mesh2Dã«å¤‰æ›ã™ã‚‹" #: editor/plugins/sprite_editor_plugin.cpp msgid "Invalid geometry, can't create polygon." @@ -7645,9 +7637,8 @@ msgid "Add Frame" msgstr "ãƒ•ãƒ¬ãƒ¼ãƒ ã‚’è¿½åŠ " #: editor/plugins/sprite_frames_editor_plugin.cpp -#, fuzzy msgid "Unable to load images" -msgstr "イメージをèªã¿è¾¼ã‚ã¾ã›ã‚“ã§ã—ãŸ:" +msgstr "ç”»åƒã‚’èªã¿è¾¼ã‚ã¾ã›ã‚“ã§ã—ãŸ:" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "ERROR: Couldn't load frame resource!" @@ -7940,7 +7931,7 @@ msgstr "フォント" #: editor/plugins/theme_editor_plugin.cpp msgid "Color" -msgstr "色" +msgstr "\\ Color" #: editor/plugins/theme_editor_plugin.cpp msgid "Theme File" @@ -9155,18 +9146,17 @@ msgid "1.0 / vector" msgstr "1.0 / ベクトル" #: editor/plugins/visual_shader_editor_plugin.cpp -#, fuzzy msgid "" "Returns the vector that points in the direction of reflection ( a : incident " "vector, b : normal vector )." -msgstr "åå°„ã®æ–¹å‘(a:入射ベクトルã€b:法線ベクトル)を指ã™ãƒ™ã‚¯ãƒˆãƒ«ã‚’è¿”ã—ã¾ã™ã€‚" +msgstr "" +"åå°„ã®æ–¹å‘ (a: 入射ベクトルã€b: 法線ベクトル) を指ã™ãƒ™ã‚¯ãƒˆãƒ«ã‚’è¿”ã—ã¾ã™ã€‚" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Returns the vector that points in the direction of refraction." msgstr "屈折ã®æ–¹å‘を指ã™ãƒ™ã‚¯ãƒˆãƒ«ã‚’è¿”ã—ã¾ã™ã€‚" #: editor/plugins/visual_shader_editor_plugin.cpp -#, fuzzy msgid "" "SmoothStep function( vector(edge0), vector(edge1), vector(x) ).\n" "\n" @@ -9174,14 +9164,13 @@ msgid "" "'edge1'. Otherwise the return value is interpolated between 0.0 and 1.0 " "using Hermite polynomials." msgstr "" -"SmoothStep関数(vector(エッジ0)ã€vector(エッジ1)ã€vector (x))。\n" +"SmoothStep関数( vector(edge0), vector(edge1), vector (x) )。\n" "\n" -"'x' ㌠'edge0' よりå°ã•ã„å ´åˆã¯0.0ã‚’è¿”ã—ã€x㌠'edge1' より大ãã„å ´åˆã¯1.0ã‚’è¿”" -"ã—ã¾ã™ã€‚ãれ以外ã®å ´åˆã€æˆ»ã‚Šå€¤ã¯ã‚¨ãƒ«ãƒŸãƒ¼ãƒˆå¤šé …å¼ã‚’使用ã—ã¦0.0ã¨1.0ã®é–“ã§è£œé–“" -"ã•ã‚Œã¾ã™ã€‚" +"'x' ㌠'edge0' よりå°ã•ã„å ´åˆã¯0.0ã‚’è¿”ã—ã€'x' ㌠'edge1' より大ãã„å ´åˆã¯1.0" +"ã‚’è¿”ã—ã¾ã™ã€‚ãれ以外ã®å ´åˆã€æˆ»ã‚Šå€¤ã¯ã‚¨ãƒ«ãƒŸãƒ¼ãƒˆå¤šé …å¼ã‚’使用ã—ã¦0.0ã¨1.0ã®é–“ã§" +"補間ã•ã‚Œã¾ã™ã€‚" #: editor/plugins/visual_shader_editor_plugin.cpp -#, fuzzy msgid "" "SmoothStep function( scalar(edge0), scalar(edge1), vector(x) ).\n" "\n" @@ -9189,31 +9178,29 @@ msgid "" "'edge1'. Otherwise the return value is interpolated between 0.0 and 1.0 " "using Hermite polynomials." msgstr "" -"SmoothStep関数(scalar(エッジ0)ã€scalar(エッジ1)ã€vector (x))。\n" +"SmoothStep関数( scalar(edge0), scalar(edge1), vector(x) )。\n" "\n" "'x' ㌠'edge0' よりå°ã•ã„å ´åˆã¯0.0ã‚’è¿”ã—ã€x㌠'edge1' より大ãã„å ´åˆã¯1.0ã‚’è¿”" "ã—ã¾ã™ã€‚ãれ以外ã®å ´åˆã€æˆ»ã‚Šå€¤ã¯ã‚¨ãƒ«ãƒŸãƒ¼ãƒˆå¤šé …å¼ã‚’使用ã—ã¦0.0ã¨1.0ã®é–“ã§è£œé–“" "ã•ã‚Œã¾ã™ã€‚" #: editor/plugins/visual_shader_editor_plugin.cpp -#, fuzzy msgid "" "Step function( vector(edge), vector(x) ).\n" "\n" "Returns 0.0 if 'x' is smaller than 'edge' and otherwise 1.0." msgstr "" -"Step関数( vector(edge)ã€vector(x))。\n" +"Step関数( vector(edge), vector(x) )。\n" "\n" "'x' ㌠'edge' よりå°ã•ã„å ´åˆã¯0.0ã‚’è¿”ã—ã€ãれ以外ã®å ´åˆã¯1.0ã‚’è¿”ã—ã¾ã™ã€‚" #: editor/plugins/visual_shader_editor_plugin.cpp -#, fuzzy msgid "" "Step function( scalar(edge), vector(x) ).\n" "\n" "Returns 0.0 if 'x' is smaller than 'edge' and otherwise 1.0." msgstr "" -"Step関数( scalar(edge)ã€vector(x))。\n" +"Step関数( scalar(edge), vector(x) )。\n" "\n" "'x' ㌠'edge' よりå°ã•ã„å ´åˆã¯0.0ã‚’è¿”ã—ã€ãれ以外ã®å ´åˆã¯1.0ã‚’è¿”ã—ã¾ã™ã€‚" @@ -9336,7 +9323,7 @@ msgstr "ビジュアルシェーダー" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Edit Visual Property" -msgstr "ビジュアルプãƒãƒ‘ティã®ç·¨é›†" +msgstr "ビジュアルプãƒãƒ‘ティを編集" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Visual Shader Mode Changed" @@ -9347,13 +9334,12 @@ msgid "Runnable" msgstr "実行å¯èƒ½" #: editor/project_export.cpp -#, fuzzy msgid "Add initial export..." -msgstr "入力ãƒãƒ¼ãƒˆã®è¿½åŠ " +msgstr "åˆå›žã‚¨ã‚¯ã‚¹ãƒãƒ¼ãƒˆã‚’è¿½åŠ â€¦" #: editor/project_export.cpp msgid "Add previous patches..." -msgstr "" +msgstr "å‰å›žã®ãƒ‘ッãƒã‚’è¿½åŠ â€¦" #: editor/project_export.cpp msgid "Delete patch '%s' from list?" @@ -9382,9 +9368,8 @@ msgstr "" "ã™ã€‚" #: editor/project_export.cpp -#, fuzzy msgid "Release" -msgstr "離ã—ãŸ" +msgstr "リリース" #: editor/project_export.cpp msgid "Exporting All" @@ -10416,8 +10401,8 @@ msgid "" "Cannot instance the scene '%s' because the current scene exists within one " "of its nodes." msgstr "" -"ã“ã®ã‚·ãƒ¼ãƒ³ã¯è‡ªèº«ã®ãƒŽãƒ¼ãƒ‰ã®ã†ã¡ã®ä¸€ã¤ã®å†…ã«ã‚ã‚‹ãŸã‚〠'%s'シーンをインスタンス" -"化ã§ãã¾ã›ã‚“。" +"シーン '%s' ã®ãƒŽãƒ¼ãƒ‰ã®ä¸€ã¤ã«ç¾åœ¨ã®ã‚·ãƒ¼ãƒ³ãŒã‚ã‚‹ãŸã‚ã€ã‚¤ãƒ³ã‚¹ã‚¿ãƒ³ã‚¹åŒ–ã§ãã¾ã›" +"ん。" #: editor/scene_tree_dock.cpp msgid "Instance Scene(s)" @@ -10610,9 +10595,8 @@ msgid "Change Type" msgstr "型を変更" #: editor/scene_tree_dock.cpp -#, fuzzy msgid "Reparent to New Node" -msgstr "親ノードを変更" +msgstr "親ノードを新è¦ãƒŽãƒ¼ãƒ‰ã«å¤‰æ›´" #: editor/scene_tree_dock.cpp msgid "Make Scene Root" @@ -10840,7 +10824,7 @@ msgstr "使用å¯èƒ½: a-z, A-Z, 0-9 㨠." #: editor/script_create_dialog.cpp msgid "Built-in script (into scene file)." -msgstr "組ã¿è¾¼ã¿ã‚¹ã‚¯ãƒªãƒ—ト(シーンファイルã¸ã®)。" +msgstr "組ã¿è¾¼ã¿ã‚¹ã‚¯ãƒªãƒ—ト (シーンファイル内)。" #: editor/script_create_dialog.cpp msgid "Will create a new script file." @@ -10851,9 +10835,8 @@ msgid "Will load an existing script file." msgstr "æ—¢å˜ã®ã‚¹ã‚¯ãƒªãƒ—トファイルをèªã¿è¾¼ã‚€ã€‚" #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "アクション'%s'ã¯æ—¢ã«ã‚ã‚Šã¾ã™!" +msgstr "スクリプトファイルãŒæ—¢ã«ã‚ã‚Šã¾ã™ã€‚" #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -10981,7 +10964,7 @@ msgstr "リソースã®ãƒ‘ス(ResourcePath)" #: editor/script_editor_debugger.cpp msgid "Type" -msgstr "タイプ(型)" +msgstr "タイプ(åž‹)" #: editor/script_editor_debugger.cpp msgid "Format" @@ -10989,7 +10972,7 @@ msgstr "フォーマット" #: editor/script_editor_debugger.cpp msgid "Usage" -msgstr "使用" +msgstr "使用法" #: editor/script_editor_debugger.cpp msgid "Misc" @@ -11229,24 +11212,20 @@ msgid "Floor:" msgstr "床é¢:" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "GridMap Delete Selection" -msgstr "é¸æŠžç¯„囲を消去" +msgstr "GridMap é¸æŠžç¯„囲を削除" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "GridMap Fill Selection" -msgstr "é¸æŠžç¯„囲を消去" +msgstr "GridMap é¸æŠžç¯„囲を埋ã‚ã‚‹" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "GridMap Paste Selection" -msgstr "é¸æŠžç¯„囲を消去" +msgstr "GridMap é¸æŠžç¯„囲を貼り付ã‘" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "GridMap Paint" -msgstr "グリッドマップã®è¨å®š" +msgstr "GridMap ペイント" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "Grid Map" @@ -11537,14 +11516,12 @@ msgid "Add Signal" msgstr "ã‚·ã‚°ãƒŠãƒ«ã‚’è¿½åŠ " #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Remove Input Port" -msgstr "入力ãƒãƒ¼ãƒˆã®å‰Šé™¤" +msgstr "入力ãƒãƒ¼ãƒˆã®é™¤åŽ»" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Remove Output Port" -msgstr "出力ãƒãƒ¼ãƒˆã®å‰Šé™¤" +msgstr "出力ãƒãƒ¼ãƒˆã®é™¤åŽ»" #: modules/visual_script/visual_script_editor.cpp msgid "Change Expression" @@ -11559,10 +11536,10 @@ msgid "Duplicate VisualScript Nodes" msgstr "VisualScriptノードを複製" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Hold %s to drop a Getter. Hold Shift to drop a generic signature." msgstr "" -"メタã‚ーをä¿æŒã—ã¦getterã‚’è½ã¨ã™.Shiftã‚ーをä¿æŒã—ã¦ã‚¸ã‚§ãƒãƒªãƒƒã‚¯ã‚’指示ã™ã‚‹." +"%sを押ã—ãŸã¾ã¾Getterを(ドラッグ&)ドãƒãƒƒãƒ—ã™ã‚‹ã€‚Shiftを押ã—ãŸã¾ã¾æ±Žç”¨ç½²åã‚’" +"(ドラッグ&)ドãƒãƒƒãƒ—ã™ã‚‹ã€‚" #: modules/visual_script/visual_script_editor.cpp msgid "Hold Ctrl to drop a Getter. Hold Shift to drop a generic signature." @@ -11571,9 +11548,10 @@ msgstr "" "ãƒãƒãƒ£ã‚’(ドラッグ&)ドãƒãƒƒãƒ—ã™ã‚‹." #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Hold %s to drop a simple reference to the node." -msgstr "メタã‚ーをä¿æŒã—ã¦å˜ç´”å‚照(simple reference)ã‚’è½ã¨ã™." +msgstr "" +"%sを押ã—ãŸã¾ã¾ãƒŽãƒ¼ãƒ‰ã¸å˜ç´”å‚照(simple reference)を(ドラッグ&)ドãƒãƒƒãƒ—ã™" +"る。" #: modules/visual_script/visual_script_editor.cpp msgid "Hold Ctrl to drop a simple reference to the node." @@ -11582,9 +11560,8 @@ msgstr "" "る。" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Hold %s to drop a Variable Setter." -msgstr "メタã‚ーをä¿æŒã—ã¦å¤‰æ•°ã®setterã‚’è½ã¨ã™" +msgstr "%sを押ã—ãŸã¾ã¾å¤‰æ•°ã®Setterを(ドラッグ&)ドãƒãƒƒãƒ—ã™ã‚‹ã€‚" #: modules/visual_script/visual_script_editor.cpp msgid "Hold Ctrl to drop a Variable Setter." @@ -11634,9 +11611,8 @@ msgid "Connect Nodes" msgstr "ノードã«æŽ¥ç¶š" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Disconnect Nodes" -msgstr "グラフノードを切æ–" +msgstr "ノードを切æ–" #: modules/visual_script/visual_script_editor.cpp msgid "Connect Node Data" @@ -11689,9 +11665,8 @@ msgid "Try to only have one sequence input in selection." msgstr "セクションã§ã¯å”¯ä¸€ã¤ã®ã‚·ãƒ¼ã‚±ãƒ³ã‚¹å…¥åŠ›ã‚’æŒã¤ã‚ˆã†ã«ã—ã¦ãã ã•ã„。" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Create Function" -msgstr "関数åを変更" +msgstr "関数を作æˆ" #: modules/visual_script/visual_script_editor.cpp msgid "Remove Function" @@ -11714,9 +11689,8 @@ msgid "Editing Signal:" msgstr "シグナルを接続:" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Make Tool:" -msgstr "ãƒãƒ¼ã‚«ãƒ«ã«ã™ã‚‹" +msgstr "ツールã«ã™ã‚‹:" #: modules/visual_script/visual_script_editor.cpp msgid "Members:" @@ -11727,14 +11701,12 @@ msgid "Change Base Type:" msgstr "基底型を変更:" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Add Nodes..." msgstr "ãƒŽãƒ¼ãƒ‰ã‚’è¿½åŠ ..." #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Add Function..." -msgstr "é–¢æ•°ã‚’è¿½åŠ " +msgstr "é–¢æ•°ã‚’è¿½åŠ â€¦" #: modules/visual_script/visual_script_editor.cpp #, fuzzy @@ -12549,6 +12521,9 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"色: #%s\n" +"左マウスボタン: 色をセット\n" +"å³ãƒžã‚¦ã‚¹ãƒœã‚¿ãƒ³: プリセットã®é™¤åŽ»" #: scene/gui/color_picker.cpp #, fuzzy @@ -12678,6 +12653,24 @@ msgstr "Varyingã¯é ‚点関数ã«ã®ã¿å‰²ã‚Šå½“ã¦ã‚‹ã“ã¨ãŒã§ãã¾ã™ã€‚" msgid "Constants cannot be modified." msgstr "定数ã¯å¤‰æ›´ã§ãã¾ã›ã‚“。" +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "ç¾åœ¨ã€ã“ã®ã‚¯ãƒ©ã‚¹ã®ãƒãƒ¥ãƒ¼ãƒˆãƒªã‚¢ãƒ«ã¯ã‚ã‚Šã¾ã›ã‚“ãŒã€[color=$color][url=$url]è²¢" +#~ "献[/url][/color]ã€ã¾ãŸã¯[color=$color][url=$url2]リクエスト[/url][/color]" +#~ "ã¯å¯èƒ½ã§ã™ã€‚" + +#~ msgid "enum " +#~ msgstr "列挙型 " + +#~ msgid "Brief Description" +#~ msgstr "è¦ç´„" + +#~ msgid "Class Description" +#~ msgstr "クラスã®èª¬æ˜Ž" + #~ msgid "Project export failed with error code %d." #~ msgstr "プãƒã‚¸ã‚§ã‚¯ãƒˆã®ã‚¨ã‚¯ã‚¹ãƒãƒ¼ãƒˆãŒã‚¨ãƒ©ãƒ¼ã‚³ãƒ¼ãƒ‰ %d ã§å¤±æ•—ã—ã¾ã—ãŸã€‚" diff --git a/editor/translations/ka.po b/editor/translations/ka.po index e937cd3daa..4808e9177b 100644 --- a/editor/translations/ka.po +++ b/editor/translations/ka.po @@ -1989,47 +1989,39 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "áƒáƒ¦áƒ¬áƒ”რáƒ:" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -#, fuzzy -msgid "Class Description" -msgstr "áƒáƒ¦áƒ¬áƒ”რáƒ:" - -#: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Constants" msgstr "" #: editor/editor_help.cpp @@ -2038,6 +2030,10 @@ msgid "Property Descriptions" msgstr "áƒáƒ¦áƒ¬áƒ”რáƒ:" #: editor/editor_help.cpp +msgid "(value)" +msgstr "" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4524,7 +4520,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5600,6 +5595,11 @@ msgid "Auto Insert Key" msgstr "áƒáƒœáƒ˜áƒ› გáƒáƒ¡áƒáƒ¦áƒ”ბის ჩáƒáƒ§áƒ”ნებáƒ" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "áƒáƒœáƒ˜áƒ›áƒáƒªáƒ˜áƒ˜áƒ¡ ხáƒáƒœáƒ’რძლივáƒáƒ‘რ(წáƒáƒ›áƒ”ბში)." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5887,7 +5887,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7286,6 +7285,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12406,6 +12409,14 @@ msgid "Constants cannot be modified." msgstr "" #, fuzzy +#~ msgid "Brief Description" +#~ msgstr "áƒáƒ¦áƒ¬áƒ”რáƒ:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "áƒáƒ¦áƒ¬áƒ”რáƒ:" + +#, fuzzy #~ msgid "Class Description:" #~ msgstr "áƒáƒ¦áƒ¬áƒ”რáƒ:" diff --git a/editor/translations/ko.po b/editor/translations/ko.po index f16f432e28..ae7e1edf52 100644 --- a/editor/translations/ko.po +++ b/editor/translations/ko.po @@ -19,7 +19,7 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-06 14:21+0000\n" +"PO-Revision-Date: 2020-01-27 07:09+0000\n" "Last-Translator: ì†¡íƒœì„ <xotjq237@gmail.com>\n" "Language-Team: Korean <https://hosted.weblate.org/projects/godot-engine/" "godot/ko/>\n" @@ -28,12 +28,12 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp msgid "Invalid type argument to convert(), use TYPE_* constants." -msgstr "convert() ë©”ì„œë“œì˜ ì¸ìˆ˜ ìœ í˜•ì´ ìž˜ëª»ë˜ì—ˆì–´ìš”. TYPE_* ìƒìˆ˜ë¥¼ 사용하세요." +msgstr "convert() ë©”ì„œë“œì˜ ì¸ìˆ˜ ìœ í˜•ì´ ìž˜ëª»ëì–´ìš”. TYPE_* ìƒìˆ˜ë¥¼ 사용하세요." #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp msgid "Expected a string of length 1 (a character)." @@ -47,7 +47,7 @@ msgstr "ë””ì½”ë”©í• ë°”ì´íŠ¸ê°€ 모ìžë¼ê±°ë‚˜ ìž˜ëª»ëœ í˜•ì‹ì´ì—ìš”." #: core/math/expression.cpp msgid "Invalid input %i (not passed) in expression" -msgstr "표현ì‹ì—ì„œ ìž…ë ¥ %iì´(ê°€) 잘못ë˜ì—ˆì–´ìš” (ì „ë‹¬ë˜ì§€ ì•ŠìŒ)" +msgstr "표현ì‹ì—ì„œ ìž…ë ¥ %iì´(ê°€) 잘못ëì–´ìš” (ì „ë‹¬ë˜ì§€ ì•ŠìŒ)" #: core/math/expression.cpp msgid "self can't be used because instance is null (not passed)" @@ -55,15 +55,15 @@ msgstr "ì¸ìŠ¤í„´ìŠ¤ê°€ 비어있어서 Self를 ì‚¬ìš©í• ìˆ˜ 없어요 (ì „ë‹¬ë #: core/math/expression.cpp msgid "Invalid operands to operator %s, %s and %s." -msgstr "ì—°ì‚°ìž %s와(ê³¼) %s, %sì˜ ì—°ì‚° 대ìƒì´ 잘못ë˜ì—ˆì–´ìš”." +msgstr "ì—°ì‚°ìž %s와(ê³¼) %s, %sì˜ ì—°ì‚° 대ìƒì´ 잘못ëì–´ìš”." #: core/math/expression.cpp msgid "Invalid index of type %s for base type %s" -msgstr "기본 ìœ í˜•ì´ %sì¸ %s ìœ í˜•ì˜ ì¸ë±ìŠ¤ê°€ 잘못ë˜ì—ˆì–´ìš”" +msgstr "기본 ìœ í˜•ì´ %sì¸ %s ìœ í˜•ì˜ ì¸ë±ìŠ¤ê°€ 잘못ëì–´ìš”" #: core/math/expression.cpp msgid "Invalid named index '%s' for base type %s" -msgstr "기본 ìœ í˜•ì´ %sì¸ '%s' ì¸ë±ìŠ¤ì˜ ì´ë¦„ì´ ìž˜ëª»ë˜ì—ˆì–´ìš”" +msgstr "기본 ìœ í˜•ì´ %sì¸ '%s' ì¸ë±ìŠ¤ì˜ ì´ë¦„ì´ ìž˜ëª»ëì–´ìš”" #: core/math/expression.cpp msgid "Invalid arguments to construct '%s'" @@ -381,7 +381,7 @@ msgstr "" #: editor/animation_track_editor.cpp msgid "Anim Create & Insert" -msgstr "ì• ë‹ˆë©”ì´ì…˜ ìƒì„±í•˜ê¸° & 삽입하기" +msgstr "ì• ë‹ˆë©”ì´ì…˜ 만들기 & 삽입하기" #: editor/animation_track_editor.cpp msgid "Anim Insert Track & Key" @@ -439,7 +439,7 @@ msgstr "ë² ì§€ì–´ 트랙 추가하기" #: editor/animation_track_editor.cpp msgid "Track path is invalid, so can't add a key." -msgstr "트랙 경로가 잘못ë˜ì—ˆì–´ìš”. 키를 ì¶”ê°€í• ìˆ˜ 없어요." +msgstr "트랙 경로가 잘못ëì–´ìš”. 키를 ì¶”ê°€í• ìˆ˜ 없어요." #: editor/animation_track_editor.cpp msgid "Track is not of type Spatial, can't insert key" @@ -1195,9 +1195,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "패키지 파ì¼ì„ 여는 중 오류. ZIP 형ì‹ì´ 아니ì—ìš”." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "ì´ë¯¸ 존재함" +msgstr "%s (ì´ë¯¸ 존재함)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1208,9 +1207,8 @@ msgid "The following files failed extraction from package:" msgstr "ë‹¤ìŒ íŒŒì¼ì„ 패키지ì—ì„œ ì¶”ì¶œí•˜ëŠ”ë° ì‹¤íŒ¨í•¨:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "외 %dê°œì˜ íŒŒì¼" +msgstr "외 %d ê°œì˜ íŒŒì¼." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1222,9 +1220,8 @@ msgid "Success!" msgstr "성공!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "ë‚´ìš©:" +msgstr "패키지 ë‚´ìš©:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1364,9 +1361,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "ìž˜ëª»ëœ íŒŒì¼. 오디오 버스 ë ˆì´ì•„ì›ƒì´ ì•„ë‹ˆì—ìš”." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "íŒŒì¼ ì €ìž¥ 중 오류!" +msgstr "íŒŒì¼ ì €ìž¥ 중 오류: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1678,7 +1674,7 @@ msgstr "켜진 í´ëž˜ìŠ¤:" #: editor/editor_feature_profile.cpp msgid "File '%s' format is invalid, import aborted." -msgstr "íŒŒì¼ '%s' 형ì‹ì´ 잘못ë˜ì—ˆì–´ìš”. ê°€ì ¸ì˜¬ 수 없어요." +msgstr "íŒŒì¼ '%s' 형ì‹ì´ 잘못ëì–´ìš”. ê°€ì ¸ì˜¬ 수 없어요." #: editor/editor_feature_profile.cpp msgid "" @@ -1938,14 +1934,26 @@ msgid "Inherited by:" msgstr "ìƒì†í•œ í´ëž˜ìŠ¤:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "간단한 설명" +msgid "Description" +msgstr "설명" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "온ë¼ì¸ íŠœí† ë¦¬ì–¼" #: editor/editor_help.cpp msgid "Properties" msgstr "ì†ì„±" #: editor/editor_help.cpp +msgid "override:" +msgstr "다시 ì •ì˜í•˜ê¸°:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "기본:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "메서드" @@ -1958,36 +1966,18 @@ msgid "Enumerations" msgstr "ì—´ê±°" #: editor/editor_help.cpp -msgid "enum " -msgstr "ì´ë„˜ " - -#: editor/editor_help.cpp msgid "Constants" -msgstr "ìƒìˆ˜" - -#: editor/editor_help.cpp -msgid "Class Description" -msgstr "í´ëž˜ìŠ¤ 설명" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "온ë¼ì¸ íŠœí† ë¦¬ì–¼" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"현재 ì´ í´ëž˜ìŠ¤ì— 대한 íŠœí† ë¦¬ì–¼ì´ ì—†ì–´ìš”. [color=$color][url=$url]íŠœí† ë¦¬ì–¼ì— " -"기여하거나[/url][/color] [color=$color][url=$url2]íŠœí† ë¦¬ì–¼ì„ ìš”ì²í• 수[/url]" -"[/color] 있어요." +msgstr "ìƒìˆ˜(Constant)" #: editor/editor_help.cpp msgid "Property Descriptions" msgstr "ì†ì„± 설명" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(ê°’)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -2271,7 +2261,7 @@ msgstr "ë ˆì´ì•„웃 ì €ìž¥ 중 오류!" #: editor/editor_node.cpp msgid "Default editor layout overridden." -msgstr "편집기 기본 ë ˆì´ì•„ì›ƒì´ ìƒˆë¡œ ì •ì˜ë˜ì—ˆì–´ìš”." +msgstr "편집기 기본 ë ˆì´ì•„ì›ƒì´ ìƒˆë¡œ ì •ì˜ëì–´ìš”." #: editor/editor_node.cpp msgid "Layout name not found!" @@ -2370,7 +2360,7 @@ msgstr "닫기 ì „ì— '%s'ì— ë³€ê²½ 사í•ì„ ì €ìž¥í• ê¹Œìš”?" #: editor/editor_node.cpp msgid "Saved %s modified resource(s)." -msgstr "ìˆ˜ì •ëœ ë¦¬ì†ŒìŠ¤ %sì´(ê°€) ì €ìž¥ë˜ì—ˆì–´ìš”." +msgstr "ìˆ˜ì •ëœ ë¦¬ì†ŒìŠ¤ %sì´(ê°€) ì €ìž¥ëì–´ìš”." #: editor/editor_node.cpp msgid "A root node is required to save the scene." @@ -2851,7 +2841,7 @@ msgstr "" #: editor/editor_node.cpp editor/script_create_dialog.cpp msgid "Editor" -msgstr "편집기" +msgstr "편집기(Editor)" #: editor/editor_node.cpp msgid "Editor Settings..." @@ -3412,7 +3402,7 @@ msgstr "í…œí”Œë¦¿ì— version.txt를 ì°¾ì„ ìˆ˜ 없어요." #: editor/export_template_manager.cpp msgid "Error creating path for templates:" -msgstr "í…œí”Œë¦¿ì˜ ê²½ë¡œ ìƒì„± 중 오류:" +msgstr "í…œí”Œë¦¿ì˜ ê²½ë¡œë¥¼ 만드는 중 오류:" #: editor/export_template_manager.cpp msgid "Extracting Export Templates" @@ -4375,7 +4365,7 @@ msgstr "오디오 í´ë¦½" #: editor/plugins/animation_blend_tree_editor_plugin.cpp msgid "Functions" -msgstr "함수" +msgstr "함수(Function)" #: editor/plugins/animation_blend_tree_editor_plugin.cpp #: editor/plugins/animation_state_machine_editor.cpp @@ -4504,7 +4494,6 @@ msgid "Animation Tools" msgstr "ì• ë‹ˆë©”ì´ì…˜ ë„구" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "ì• ë‹ˆë©”ì´ì…˜(Animation)" @@ -5565,6 +5554,10 @@ msgid "Auto Insert Key" msgstr "ìžë™ìœ¼ë¡œ 키 삽입하기" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "ì• ë‹ˆë©”ì´ì…˜ 키와 í¬ì¦ˆ ì„¤ì •" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "키 삽입하기 (기존 트랙)" @@ -5673,20 +5666,18 @@ msgstr "방출 마스í¬" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "수축 (픽셀): " +msgstr "ì „ë©´ 픽셀" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "í…Œë‘리 픽셀" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "ë””ë ‰í† ë¦¬ & 파ì¼:" +msgstr "ë°©í–¥ì„±ì´ ìžˆëŠ” í…Œë‘리 픽셀" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5849,7 +5840,6 @@ msgid "No mesh to debug." msgstr "ë””ë²„ê·¸í• ë©”ì‹œê°€ 없어요." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "ì´ ë ˆì´ì–´ì—ì„œ 모ë¸ì€ UVê°€ 없어요" @@ -7235,6 +7225,10 @@ msgid "Cinematic Preview" msgstr "시네마틱 미리 보기" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "GLES2 ë Œë”러ì—ì„œ ì‚¬ìš©í• ìˆ˜ 없어요." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "ìžìœ ì‹œì 왼쪽으로 가기" @@ -9494,7 +9488,7 @@ msgstr "프로ì 트 경로ì—ì„œ project.godot 파ì¼ì„ íŽ¸ì§‘í• ìˆ˜ ì—†ì–´ìš #: editor/project_manager.cpp msgid "Couldn't create project.godot in project path." -msgstr "프로ì 트 경로ì—ì„œ project.godot 파ì¼ì„ ìƒì„±í• 수 없어요." +msgstr "프로ì 트 경로ì—ì„œ project.godot 파ì¼ì„ 만들 수 없어요." #: editor/project_manager.cpp msgid "Rename Project" @@ -9586,7 +9580,7 @@ msgstr "누ë½ëœ 프로ì 트" #: editor/project_manager.cpp msgid "Error: Project is missing on the filesystem." -msgstr "오류: 프로ì 트가 íŒŒì¼ ì‹œìŠ¤í…œì—ì„œ 누ë½ë˜ì—ˆì–´ìš”." +msgstr "오류: 프로ì 트가 íŒŒì¼ ì‹œìŠ¤í…œì—ì„œ 누ë½ëì–´ìš”." #: editor/project_manager.cpp msgid "Can't open project at '%s'." @@ -10718,9 +10712,8 @@ msgid "Will load an existing script file." msgstr "기존 스í¬ë¦½íŠ¸ 파ì¼ì„ 불러와요." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "ì´ë¯¸ ë¶„í• ë˜ì—ˆìŠµë‹ˆë‹¤." +msgstr "스í¬ë¦½íŠ¸ 파ì¼ì´ ì´ë¯¸ 있어요." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -11279,7 +11272,7 @@ msgid "" "Node yielded, but did not return a function state in the first working " "memory." msgstr "" -"노드가 Yieldë˜ì—ˆì§€ë§Œ, 첫번째 ìž‘ì—… ë©”ëª¨ë¦¬ì˜ í•¨ìˆ˜ ìƒíƒœë¥¼ 반환하지 않았어요." +"노드가 Yieldë지만, 첫번째 ìž‘ì—… ë©”ëª¨ë¦¬ì˜ í•¨ìˆ˜ ìƒíƒœë¥¼ 반환하지 않았어요." #: modules/visual_script/visual_script.cpp msgid "" @@ -12361,11 +12354,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"색ìƒ: #%s\n" +"좌í´ë¦: ìƒ‰ìƒ ì„¤ì •í•˜ê¸°\n" +"ìš°í´ë¦: 프리셋 ì œê±°í•˜ê¸°" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "화면ì—ì„œ 색ìƒì„ ì„ íƒí•˜ì„¸ìš”." +msgstr "편집기 ì°½ì—ì„œ 색ìƒì„ ê³ ë¥´ì„¸ìš”." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12483,6 +12478,24 @@ msgstr "Varyingì€ ê¼ì§“ì 함수ì—만 ì§€ì •í• ìˆ˜ 있어요." msgid "Constants cannot be modified." msgstr "ìƒìˆ˜ëŠ” ìˆ˜ì •í• ìˆ˜ 없어요." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "현재 ì´ í´ëž˜ìŠ¤ì— 대한 íŠœí† ë¦¬ì–¼ì´ ì—†ì–´ìš”. [color=$color][url=$url]íŠœí† ë¦¬ì–¼" +#~ "ì— ê¸°ì—¬í•˜ê±°ë‚˜[/url][/color] [color=$color][url=$url2]íŠœí† ë¦¬ì–¼ì„ ìš”ì²í• 수" +#~ "[/url][/color] 있어요." + +#~ msgid "enum " +#~ msgstr "ì´ë„˜ " + +#~ msgid "Brief Description" +#~ msgstr "간단한 설명" + +#~ msgid "Class Description" +#~ msgstr "í´ëž˜ìŠ¤ 설명" + #~ msgid "Project export failed with error code %d." #~ msgstr "프로ì 트 ë‚´ë³´ë‚´ê¸°ì— ì‹¤íŒ¨í–ˆì–´ìš”. 오류 코드%d." diff --git a/editor/translations/lt.po b/editor/translations/lt.po index c9de0179b1..f3118b9942 100644 --- a/editor/translations/lt.po +++ b/editor/translations/lt.po @@ -1956,47 +1956,39 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "ApraÅ¡ymas:" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -#, fuzzy -msgid "Class Description" -msgstr "ApraÅ¡ymas:" - -#: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Constants" msgstr "" #: editor/editor_help.cpp @@ -2005,6 +1997,11 @@ msgid "Property Descriptions" msgstr "ApraÅ¡ymas:" #: editor/editor_help.cpp +#, fuzzy +msgid "(value)" +msgstr "Naujas pavadinimas:" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4498,7 +4495,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animacija" @@ -5576,6 +5572,11 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animacijos Nodas" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5861,7 +5862,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7261,6 +7261,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12393,6 +12397,14 @@ msgid "Constants cannot be modified." msgstr "" #, fuzzy +#~ msgid "Brief Description" +#~ msgstr "ApraÅ¡ymas:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "ApraÅ¡ymas:" + +#, fuzzy #~ msgid "Class Description:" #~ msgstr "ApraÅ¡ymas:" diff --git a/editor/translations/lv.po b/editor/translations/lv.po index 63da6e5725..b6066df271 100644 --- a/editor/translations/lv.po +++ b/editor/translations/lv.po @@ -1959,47 +1959,40 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "Apraksts:" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" -msgstr "" +#, fuzzy +msgid "default:" +msgstr "IelÄdÄ“t NoklusÄ“jumu" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -#, fuzzy -msgid "Class Description" -msgstr "Apraksts:" - -#: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Constants" msgstr "" #: editor/editor_help.cpp @@ -2008,6 +2001,10 @@ msgid "Property Descriptions" msgstr "Apraksts:" #: editor/editor_help.cpp +msgid "(value)" +msgstr "" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4488,7 +4485,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5558,6 +5554,11 @@ msgid "Auto Insert Key" msgstr "Anim ievietot atslÄ“gievietni" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "AnimÄcijas Garums (sekundes)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5846,7 +5847,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7243,6 +7243,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12358,6 +12362,14 @@ msgid "Constants cannot be modified." msgstr "" #, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Apraksts:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "Apraksts:" + +#, fuzzy #~ msgid "Class Description:" #~ msgstr "Apraksts:" diff --git a/editor/translations/mi.po b/editor/translations/mi.po index 77c0a220e3..24d1f213e2 100644 --- a/editor/translations/mi.po +++ b/editor/translations/mi.po @@ -1878,50 +1878,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4349,7 +4346,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5392,6 +5388,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5672,7 +5672,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7042,6 +7041,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/ml.po b/editor/translations/ml.po index 765164a24b..dbf8e76d3f 100644 --- a/editor/translations/ml.po +++ b/editor/translations/ml.po @@ -1888,51 +1888,49 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "" +#, fuzzy +msgid "(value)" +msgstr "വില:" #: editor/editor_help.cpp msgid "" @@ -4363,7 +4361,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5406,6 +5403,11 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "ചലന നേരം (ഞൊടികൾ)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5686,7 +5688,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7056,6 +7057,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/mr.po b/editor/translations/mr.po index 972c843a62..43f7620d28 100644 --- a/editor/translations/mr.po +++ b/editor/translations/mr.po @@ -1884,51 +1884,49 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "" +#, fuzzy +msgid "(value)" +msgstr "मूलà¥à¤¯:" #: editor/editor_help.cpp msgid "" @@ -4355,7 +4353,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5398,6 +5395,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5678,7 +5679,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7048,6 +7048,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/ms.po b/editor/translations/ms.po index 8e5602be96..0207d83de5 100644 --- a/editor/translations/ms.po +++ b/editor/translations/ms.po @@ -6,12 +6,14 @@ # Shaqir Rafiq <moshamoradev@gmail.com>, 2018. # Syaz Amirin <amirin123z@gmail.com>, 2018. # Nafis Ibrahim <thepreciousnafis@gmail.com>, 2018. +# Muhammad Hazim bin Hafizalshah <muhammadhazimhafizalshah@gmail.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2018-12-13 14:41+0100\n" -"Last-Translator: Nafis Ibrahim <thepreciousnafis@gmail.com>\n" +"PO-Revision-Date: 2020-01-27 07:10+0000\n" +"Last-Translator: Muhammad Hazim bin Hafizalshah " +"<muhammadhazimhafizalshah@gmail.com>\n" "Language-Team: Malay <https://hosted.weblate.org/projects/godot-engine/godot/" "ms/>\n" "Language: ms\n" @@ -19,7 +21,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Poedit 2.2\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1907,50 +1909,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4257,9 +4256,8 @@ msgid "Audio Clips" msgstr "Anim Tambah Trek" #: editor/plugins/animation_blend_tree_editor_plugin.cpp -#, fuzzy msgid "Functions" -msgstr "Semua Pilihan" +msgstr "Fungsi" #: editor/plugins/animation_blend_tree_editor_plugin.cpp #: editor/plugins/animation_state_machine_editor.cpp @@ -4388,7 +4386,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -4587,7 +4584,7 @@ msgstr "" #: editor/plugins/animation_tree_editor_plugin.cpp #: editor/plugins/animation_tree_player_editor_plugin.cpp msgid "AnimationTree" -msgstr "" +msgstr "AnimationTree" #: editor/plugins/animation_tree_player_editor_plugin.cpp msgid "New name:" @@ -5443,6 +5440,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5725,7 +5726,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7096,6 +7096,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -9755,9 +9759,8 @@ msgid "Action:" msgstr "" #: editor/project_settings_editor.cpp -#, fuzzy msgid "Action" -msgstr "Semua Pilihan" +msgstr "Aksi" #: editor/project_settings_editor.cpp msgid "Deadzone" diff --git a/editor/translations/nb.po b/editor/translations/nb.po index d4f7d1ec99..dcbe8e6950 100644 --- a/editor/translations/nb.po +++ b/editor/translations/nb.po @@ -2050,14 +2050,29 @@ msgstr "Arvet av:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Kort beskrivelse:" +msgid "Description" +msgstr "Beskrivelse:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "Online dokumentasjon:" #: editor/editor_help.cpp msgid "Properties" msgstr "Egenskaper" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "Overskriv" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Standard" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metoder" @@ -2071,37 +2086,18 @@ msgid "Enumerations" msgstr "Nummereringer" #: editor/editor_help.cpp -msgid "enum " -msgstr "num " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstanter" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "Beskrivelse" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "Online dokumentasjon:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Det finnes i øyeblikket ingen beskrivelse av denne metoden, men du kan " -"[colour=$color][url=$url]bidra med en[/url][/color] eller [color=$color][url=" -"$url2]be om en[/url][/color]." +msgid "Property Descriptions" +msgstr "Egenskapsbeskrivelse:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "Egenskapsbeskrivelse:" +msgid "(value)" +msgstr "Verdi:" #: editor/editor_help.cpp msgid "" @@ -4814,7 +4810,6 @@ msgid "Animation Tools" msgstr "Animasjonsverktøy" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animasjon" @@ -5964,6 +5959,11 @@ msgid "Auto Insert Key" msgstr "Anim Sett Inn Nøkkel" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animasjonslengde (sekunder)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Sett inn Nøkkel (Eksisterende Spor)" @@ -6262,7 +6262,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7722,6 +7721,10 @@ msgid "Cinematic Preview" msgstr "Lager ForhÃ¥ndsvisning av Mesh" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -13031,6 +13034,26 @@ msgstr "" msgid "Constants cannot be modified." msgstr "Konstanter kan ikke endres." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Det finnes i øyeblikket ingen beskrivelse av denne metoden, men du kan " +#~ "[colour=$color][url=$url]bidra med en[/url][/color] eller [color=$color]" +#~ "[url=$url2]be om en[/url][/color]." + +#~ msgid "enum " +#~ msgstr "num " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Kort beskrivelse:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "Beskrivelse" + #~ msgid "Project export failed with error code %d." #~ msgstr "Eksport av prosjektet mislyktes med feilkode %d." diff --git a/editor/translations/nl.po b/editor/translations/nl.po index 87f02bce48..39bca63def 100644 --- a/editor/translations/nl.po +++ b/editor/translations/nl.po @@ -39,12 +39,12 @@ # ebbe <ebbesteenhoudt@gmail.com>, 2019. # Tirrin <lensenjoe@gmail.com>, 2019. # Filip Van Raemdonck <arrawn@gmail.com>, 2019. -# Julian <jdhoogvorst@gmail.com>, 2019. +# Julian <jdhoogvorst@gmail.com>, 2019, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-12 13:26+0000\n" +"PO-Revision-Date: 2020-01-27 07:09+0000\n" "Last-Translator: Stijn Hinlopen <f.a.hinlopen@gmail.com>\n" "Language-Team: Dutch <https://hosted.weblate.org/projects/godot-engine/godot/" "nl/>\n" @@ -53,7 +53,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10.1\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -288,7 +288,7 @@ msgstr "Schakel deze track aan/uit." #: editor/animation_track_editor.cpp msgid "Update Mode (How this property is set)" -msgstr "Update Modus (Setting van deze eigenschap)" +msgstr "Bijwerkmodus (hoe de eigenschap ingesteld wordt)" #: editor/animation_track_editor.cpp msgid "Interpolation Mode" @@ -296,8 +296,7 @@ msgstr "Interpolatiemodus" #: editor/animation_track_editor.cpp msgid "Loop Wrap Mode (Interpolate end with beginning on loop)" -msgstr "" -"Terugloopmodus (Interpolatie tussen het begin en het einde van de loop)" +msgstr "Naadloze-lusmodus (interpoleert einde met begin van lus)" #: editor/animation_track_editor.cpp msgid "Remove this track." @@ -363,11 +362,11 @@ msgstr "Sleutel(s) verwijderen" #: editor/animation_track_editor.cpp msgid "Change Animation Update Mode" -msgstr "Verander animatie update modus" +msgstr "Animatiebijwerkmodus veranderen" #: editor/animation_track_editor.cpp msgid "Change Animation Interpolation Mode" -msgstr "Verander Animatie Interpolatiemodus" +msgstr "Animatieinterpolatiemodus veranderen" #: editor/animation_track_editor.cpp msgid "Change Animation Loop Mode" @@ -1230,9 +1229,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Fout bij het openen van het pakketbestand, geen zip-formaat." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Bestaat al" +msgstr "%s (bestaat al)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1243,9 +1241,8 @@ msgid "The following files failed extraction from package:" msgstr "De volgende bestanden konden niet worden uitgepakt:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "nog %d bestand(en)" +msgstr "En nog %s bestand(en)." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1257,9 +1254,8 @@ msgid "Success!" msgstr "Gelukt!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Inhoud:" +msgstr "Pakketinhoud:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1376,15 +1372,15 @@ msgstr "Verplaats audiobus" #: editor/editor_audio_buses.cpp msgid "Save Audio Bus Layout As..." -msgstr "Sla Audio Bus Layout Op Als..." +msgstr "Audiobusindeling opslaan als..." #: editor/editor_audio_buses.cpp msgid "Location for New Layout..." -msgstr "Locatie voor Nieuwe Layout..." +msgstr "Opslagplaats voor nieuwe indeling..." #: editor/editor_audio_buses.cpp msgid "Open Audio Bus Layout" -msgstr "Open Audio Bus Lay-out" +msgstr "Audiobusindeling openen" #: editor/editor_audio_buses.cpp msgid "There is no '%s' file." @@ -1396,12 +1392,11 @@ msgstr "Indeling" #: editor/editor_audio_buses.cpp msgid "Invalid file, not an audio bus layout." -msgstr "Ongeldig bestand, geen audiobus layout." +msgstr "Ongeldig bestand, geen audiobusindeling." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Error bij het opslaan van bestand!" +msgstr "Fout bij het opslaan van bestand: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1409,7 +1404,7 @@ msgstr "Bus Toevoegen" #: editor/editor_audio_buses.cpp msgid "Add a new Audio Bus to this layout." -msgstr "Voeg een nieuwe Audio Bus toe aan deze layout." +msgstr "Nieuwe audiobus toevoegen aan deze indeling." #: editor/editor_audio_buses.cpp editor/editor_properties.cpp #: editor/plugins/animation_player_editor_plugin.cpp editor/property_editor.cpp @@ -1419,7 +1414,7 @@ msgstr "Laden" #: editor/editor_audio_buses.cpp msgid "Load an existing Bus Layout." -msgstr "Laad een bestaand audiobus layout." +msgstr "Bestaande busindeling laden." #: editor/editor_audio_buses.cpp msgid "Save As" @@ -1427,7 +1422,7 @@ msgstr "Opslaan Als" #: editor/editor_audio_buses.cpp msgid "Save this Bus Layout to a file." -msgstr "Sla deze audiobus layout op in een bestand." +msgstr "Audiobusindeling opslaan in een bestand." #: editor/editor_audio_buses.cpp editor/import_dock.cpp msgid "Load Default" @@ -1435,11 +1430,11 @@ msgstr "Laad standaard" #: editor/editor_audio_buses.cpp msgid "Load the default Bus Layout." -msgstr "Laad de standaard audiobus layout." +msgstr "Standaard audiobusindeling laden." #: editor/editor_audio_buses.cpp msgid "Create a new Bus Layout." -msgstr "Maak een nieuwe audiobus layout." +msgstr "Maak een nieuwe audiobusindeling." #: editor/editor_autoload_settings.cpp msgid "Invalid name." @@ -1532,7 +1527,7 @@ msgstr "Singleton" #: editor/editor_data.cpp msgid "Updating Scene" -msgstr "Scene aan het Updaten" +msgstr "Scène aan het bijwerken" #: editor/editor_data.cpp msgid "Storing local changes..." @@ -1540,7 +1535,7 @@ msgstr "Lokale wijziging aan het opslaan..." #: editor/editor_data.cpp msgid "Updating scene..." -msgstr "Scene aan het updaten..." +msgstr "Scène aan het bijwerken..." #: editor/editor_data.cpp editor/editor_properties.cpp msgid "[empty]" @@ -1654,7 +1649,7 @@ msgstr "Asset bibliotheek" #: editor/editor_feature_profile.cpp msgid "Scene Tree Editing" -msgstr "Scene structuur bewerking" +msgstr "Scèneboombewerking" #: editor/editor_feature_profile.cpp msgid "Import Dock" @@ -1878,7 +1873,7 @@ msgstr "Toggle Favoriet" #: editor/editor_file_dialog.cpp msgid "Toggle Mode" -msgstr "Toggle Modus" +msgstr "Modus omschakelen" #: editor/editor_file_dialog.cpp msgid "Focus Path" @@ -1976,14 +1971,26 @@ msgid "Inherited by:" msgstr "Geërfd door:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Korte Omschrijving" +msgid "Description" +msgstr "Beschrijving" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Online Zelfstudie" #: editor/editor_help.cpp msgid "Properties" msgstr "Eigenschappen" #: editor/editor_help.cpp +msgid "override:" +msgstr "overschreven:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "standaard:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Methodes" @@ -1996,36 +2003,18 @@ msgid "Enumerations" msgstr "Enumeraties" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Constanten" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Klassebeschrijving" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Online Zelfstudie" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Er is momenteel geen handleiding voor deze methode. Help ons alsjeblieft " -"door [color=$color][url=$url]een toe te voegen[/url][/color] of [color=" -"$color][url=$url2]een aan te vragen[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Eigenschap Beschrijvingen" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(waarde)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -2212,8 +2201,8 @@ msgid "" "This resource can't be saved because it does not belong to the edited scene. " "Make it unique first." msgstr "" -"Deze hulpbron kan niet bewaard worden omdat ze geen deel uitmaakt van de " -"bewerkte scene. Maak ze eerst alleenstaand." +"Deze hulpbron kan niet opgeslagen worden omdat het niet bij de bewerkte " +"scène hoort. Maak het eerst uniek." #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp msgid "Save Resource As..." @@ -2254,7 +2243,7 @@ msgstr "Fout tijdens het laden van '%s'." #: editor/editor_node.cpp msgid "Saving Scene" -msgstr "Scene Aan Het Opslaan" +msgstr "Scène aan het opslaan" #: editor/editor_node.cpp msgid "Analyzing" @@ -2273,7 +2262,8 @@ msgid "" "This scene can't be saved because there is a cyclic instancing inclusion.\n" "Please resolve it and then attempt to save again." msgstr "" -"Deze scene kan niet opgeslagen worden vanwege een cyclische instantiëring.\n" +"Deze scène kan niet opgeslagen worden omdat er een cyclische instantiëring " +"aanwezig is.\n" "Opslaan is pas mogelijk als dit opgelost wordt." #: editor/editor_node.cpp @@ -2281,12 +2271,12 @@ msgid "" "Couldn't save scene. Likely dependencies (instances or inheritance) couldn't " "be satisfied." msgstr "" -"Kon de scene niet opslaan. Waarschijnlijk konden afhankelijkheden " +"Kon de scène niet opslaan. Waarschijnlijk konden afhankelijkheden " "(instanties of erfelijkheden) niet voldaan worden." #: editor/editor_node.cpp editor/scene_tree_dock.cpp msgid "Can't overwrite scene that is still open!" -msgstr "Kan geen scenes overschrijven die nog open zijn!" +msgstr "Kan geen scènes overschrijven die nog open zijn!" #: editor/editor_node.cpp msgid "Can't load MeshLibrary for merging!" @@ -2306,19 +2296,19 @@ msgstr "Error bij het opslaan van TileSet!" #: editor/editor_node.cpp msgid "Error trying to save layout!" -msgstr "Error bij het opslaan van layout!" +msgstr "Fout bij het opslaan van indeling!" #: editor/editor_node.cpp msgid "Default editor layout overridden." -msgstr "Standaard editor layout overschreven." +msgstr "Standaardeditorindeling overschreven." #: editor/editor_node.cpp msgid "Layout name not found!" -msgstr "Lay-out naam niet gevonden!" +msgstr "Indelingsnaam niet gevonden!" #: editor/editor_node.cpp msgid "Restored default layout to base settings." -msgstr "Standaard layout hersteld naar basisinstellingen." +msgstr "Standaardindeling teruggezet naar basisinstellingen." #: editor/editor_node.cpp msgid "" @@ -2337,7 +2327,7 @@ msgid "" msgstr "" "Dit bestand hoort bij een scene die geïnstantieerd of overgeërfd werd.\n" "Aanpassingen zullen niet worden behouden bij het opslaan van de huidige " -"scene." +"scène." #: editor/editor_node.cpp msgid "" @@ -2357,7 +2347,7 @@ msgstr "" "Deze scene werd geïmporteerd, dus aanpassingen zullen niet worden behouden.\n" "Door het te instantiëren of over te erven kunnen er wijzigingen worden " "aangebracht.\n" -"Lees de documentatie met betrekking tot importeren van scenes om dit proces " +"Lees de documentatie met betrekking tot importeren van scènes om dit proces " "beter te begrijpen." #: editor/editor_node.cpp @@ -2372,11 +2362,11 @@ msgstr "" #: editor/editor_node.cpp msgid "There is no defined scene to run." -msgstr "Er is geen startscene gedefinieerd." +msgstr "Er is geen startscène ingesteld." #: editor/editor_node.cpp msgid "Current scene was never saved, please save it prior to running." -msgstr "De huidige scene werd nooit opgeslagen, sla ze op voor het uitvoeren." +msgstr "De huidige scène is nooit opgeslagen, sla het op voor het uitvoeren." #: editor/editor_node.cpp msgid "Could not start subprocess!" @@ -2384,11 +2374,11 @@ msgstr "Kon het subproces niet opstarten!" #: editor/editor_node.cpp editor/filesystem_dock.cpp msgid "Open Scene" -msgstr "Scene Openen" +msgstr "Scène openen" #: editor/editor_node.cpp msgid "Open Base Scene" -msgstr "Open Basisscene" +msgstr "Basisscène openen" #: editor/editor_node.cpp msgid "Quick Open..." @@ -2396,7 +2386,7 @@ msgstr "Snel Openen..." #: editor/editor_node.cpp msgid "Quick Open Scene..." -msgstr "Open Scene Snel..." +msgstr "Scène snel openen..." #: editor/editor_node.cpp msgid "Quick Open Script..." @@ -2420,7 +2410,7 @@ msgstr "Een wortelknoop is nodig om de scène op te slaan." #: editor/editor_node.cpp msgid "Save Scene As..." -msgstr "Sla Scene Op Als..." +msgstr "Scène opslaan als..." #: editor/editor_node.cpp msgid "No" @@ -2436,7 +2426,7 @@ msgstr "Deze scene is nooit opgeslagen. Sla op voor het uitvoeren?" #: editor/editor_node.cpp editor/scene_tree_dock.cpp msgid "This operation can't be done without a scene." -msgstr "Deze operatie kan niet uitgevoerd worden zonder scene." +msgstr "Deze operatie kan niet uitgevoerd worden zonder scène." #: editor/editor_node.cpp msgid "Export Mesh Library" @@ -2457,11 +2447,11 @@ msgstr "" #: editor/editor_node.cpp msgid "Current scene not saved. Open anyway?" -msgstr "De huidige scene is nog niet opgeslagen. Toch openen?" +msgstr "De huidige scène is niet opgeslagen. Toch openen?" #: editor/editor_node.cpp msgid "Can't reload a scene that was never saved." -msgstr "Een scene die nooit opgeslagen is kan je niet opnieuw laden." +msgstr "Een scène die nooit opgeslagen is kan niet opnieuw laden worden." #: editor/editor_node.cpp msgid "Revert" @@ -2473,7 +2463,7 @@ msgstr "Deze actie kan niet ongedaan gemaakt worden. Toch herstellen?" #: editor/editor_node.cpp msgid "Quick Run Scene..." -msgstr "Snel Scene Uitvoeren..." +msgstr "Scène snel starten..." #: editor/editor_node.cpp msgid "Quit" @@ -2481,7 +2471,7 @@ msgstr "Afsluiten" #: editor/editor_node.cpp msgid "Exit the editor?" -msgstr "Sluit de editor af?" +msgstr "Editor afsluiten?" #: editor/editor_node.cpp msgid "Open Project Manager?" @@ -2493,8 +2483,7 @@ msgstr "Opslaan & Afsluiten" #: editor/editor_node.cpp msgid "Save changes to the following scene(s) before quitting?" -msgstr "" -"Wil je de wijzigen aan de volgende scene(s) opslaan voor het afsluiten?" +msgstr "Wijzigen aan de volgende scène(s) opslaan voor het afsluiten?" #: editor/editor_node.cpp msgid "Save changes the following scene(s) before opening Project Manager?" @@ -2511,15 +2500,15 @@ msgstr "" #: editor/editor_node.cpp msgid "Pick a Main Scene" -msgstr "Kies een Hoofdscene" +msgstr "Kies een startscène" #: editor/editor_node.cpp msgid "Close Scene" -msgstr "Scene Sluiten" +msgstr "Scène sluiten" #: editor/editor_node.cpp msgid "Reopen Closed Scene" -msgstr "Gesloten Scène Opnieuw Openen" +msgstr "Gesloten scène heropenen" #: editor/editor_node.cpp msgid "Unable to enable addon plugin at: '%s' parsing of config failed." @@ -2553,7 +2542,7 @@ msgstr "" #: editor/editor_node.cpp msgid "Unable to load addon script from path: '%s' Script is not in tool mode." msgstr "" -"Volgend script kon niet geladen worden: '%s' Script is niet in tool modus." +"Uitbreidingsscript kon niet geladen worden: '%s' Script is niet in toolmodus." #: editor/editor_node.cpp msgid "" @@ -2575,7 +2564,7 @@ msgstr "" #: editor/editor_node.cpp msgid "Scene '%s' has broken dependencies:" -msgstr "De scene '%s' heeft kapotte afhankelijkheden:" +msgstr "De scène '%s' heeft verbroken afhankelijkheden:" #: editor/editor_node.cpp msgid "Clear Recent Scenes" @@ -2587,9 +2576,8 @@ msgid "" "You can change it later in \"Project Settings\" under the 'application' " "category." msgstr "" -"Er is nooit een hoofdscene gekozen, wil je er een selecteren?\n" -"Je kan dit later nog aanpassen in \"Projectinstellingen\" onder de categorie " -"'toepassing'." +"Er is nooit een startscène gekozen, wil je er een selecteren?\n" +"Je kan dit later nog aanpassen in Project→Projectinstellingen→Application." #: editor/editor_node.cpp msgid "" @@ -2598,8 +2586,7 @@ msgid "" "category." msgstr "" "De geselecteerde scene '%s' bestaat niet, selecteer een andere?\n" -"Je kan dit later aanpassen in \"Projectinstellingen\" onder de categorie " -"'toepassing'." +"Je kan dit later nog aanpassen in Project→Projectinstellingen→Application." #: editor/editor_node.cpp msgid "" @@ -2607,17 +2594,16 @@ msgid "" "You can change it later in \"Project Settings\" under the 'application' " "category." msgstr "" -"De geselecteerde scene '%s' is geen scenebestand, selecteer een andere?\n" -"Je kan dit later aanpassen in \"Projectinstellingen\" onder de categorie " -"'toepassing'." +"De geselecteerde scene '%s' is geen scènebestand, selecteer een andere?\n" +"Je kan dit later nog aanpassen in Project→Projectinstellingen→Application." #: editor/editor_node.cpp msgid "Save Layout" -msgstr "Layout Opslaan" +msgstr "Indeling opslaan" #: editor/editor_node.cpp msgid "Delete Layout" -msgstr "Layout Verwijderen" +msgstr "Indeling verwijderen" #: editor/editor_node.cpp editor/import_dock.cpp #: editor/script_create_dialog.cpp @@ -2655,7 +2641,7 @@ msgstr "Sluit Alle Tabbladen" #: editor/editor_node.cpp msgid "Switch Scene Tab" -msgstr "Scenetab Wisselen" +msgstr "Scènetab wisselen" #: editor/editor_node.cpp msgid "%d more files or folders" @@ -2675,15 +2661,15 @@ msgstr "Tabbladpositie" #: editor/editor_node.cpp msgid "Distraction Free Mode" -msgstr "Afleidingsvrije Modus" +msgstr "Afleidingsvrijemodus" #: editor/editor_node.cpp msgid "Toggle distraction-free mode." -msgstr "Afleidingsvrije modus veranderen." +msgstr "Afleidingsvrijemodus omschakelen." #: editor/editor_node.cpp msgid "Add a new scene." -msgstr "Nieuwe scene toevoegen." +msgstr "Nieuwe scène toevoegen." #: editor/editor_node.cpp msgid "Scene" @@ -2691,7 +2677,7 @@ msgstr "Scène" #: editor/editor_node.cpp msgid "Go to previously opened scene." -msgstr "Ga naar de vorige geopende scene." +msgstr "Ga naar de eerder geopende scène." #: editor/editor_node.cpp msgid "Copy Text" @@ -2711,19 +2697,19 @@ msgstr "Bestanden Filteren..." #: editor/editor_node.cpp msgid "Operations with scene files." -msgstr "Operaties met scenebestanden." +msgstr "Operaties met scènebestanden." #: editor/editor_node.cpp msgid "New Scene" -msgstr "Nieuwe Scene" +msgstr "Nieuwe scène" #: editor/editor_node.cpp msgid "New Inherited Scene..." -msgstr "Nieuwe Geërfde Scene..." +msgstr "Nieuwe geërfde scène..." #: editor/editor_node.cpp msgid "Open Scene..." -msgstr "Scene Openen..." +msgstr "Scène openen..." #: editor/editor_node.cpp editor/plugins/script_editor_plugin.cpp msgid "Open Recent" @@ -2731,11 +2717,11 @@ msgstr "Recente Scenes Openen" #: editor/editor_node.cpp msgid "Save Scene" -msgstr "Scene Opslaan" +msgstr "Scène opslaan" #: editor/editor_node.cpp msgid "Save All Scenes" -msgstr "Alle Scènes Opslaan" +msgstr "Alle scènes opslaan" #: editor/editor_node.cpp msgid "Convert To..." @@ -2761,7 +2747,7 @@ msgstr "Opnieuw" #: editor/editor_node.cpp msgid "Revert Scene" -msgstr "Scene Herstellen" +msgstr "Scène terugzetten" #: editor/editor_node.cpp msgid "Miscellaneous project or scene-wide tools." @@ -2875,7 +2861,7 @@ msgstr "" #: editor/editor_node.cpp msgid "Sync Scene Changes" -msgstr "Sceneveranderingen synchroniseren" +msgstr "Scèneveranderingen synchroniseren" #: editor/editor_node.cpp msgid "" @@ -2915,7 +2901,7 @@ msgstr "Editor Instellingen..." #: editor/editor_node.cpp msgid "Editor Layout" -msgstr "Editor Layout" +msgstr "Editorindeling" #: editor/editor_node.cpp msgid "Take Screenshot" @@ -2931,7 +2917,7 @@ msgstr "Schakel Volledig Scherm" #: editor/editor_node.cpp msgid "Toggle System Console" -msgstr "Systeemconsole (on)zichtbaar maken" +msgstr "Systeemconsole aan-/uitschakelen" #: editor/editor_node.cpp msgid "Open Editor Data/Settings Folder" @@ -3001,11 +2987,11 @@ msgstr "Pauzeer de uitvoering van de scène voor foutopsporing." #: editor/editor_node.cpp msgid "Pause Scene" -msgstr "Pauzeer Scene" +msgstr "Scène pauzeren" #: editor/editor_node.cpp msgid "Stop the scene." -msgstr "Stop de scene." +msgstr "Scène stoppen." #: editor/editor_node.cpp msgid "Play the edited scene." @@ -3391,7 +3377,7 @@ msgstr "Schrijf je logica in de _run() methode." #: editor/editor_run_script.cpp msgid "There is an edited scene already." -msgstr "Er is al een bewerkte scene." +msgstr "Er is al een bewerkte scène." #: editor/editor_run_script.cpp msgid "Couldn't instance script:" @@ -3419,7 +3405,7 @@ msgstr "Bladeren" #: editor/editor_sub_scene.cpp msgid "Scene Path:" -msgstr "Scene Pad:" +msgstr "Scènepad:" #: editor/editor_sub_scene.cpp msgid "Import From Node:" @@ -3703,11 +3689,11 @@ msgstr "Folder dupliceren:" #: editor/filesystem_dock.cpp msgid "New Inherited Scene" -msgstr "Nieuwe overgeërfde scene" +msgstr "Nieuwe geërfde scène" #: editor/filesystem_dock.cpp msgid "Set As Main Scene" -msgstr "Instellen als hoofdscène" +msgstr "Instellen als startscène" #: editor/filesystem_dock.cpp msgid "Open Scenes" @@ -3788,7 +3774,7 @@ msgstr "Bestandssysteem Opnieuw Scannen" #: editor/filesystem_dock.cpp msgid "Toggle Split Mode" -msgstr "Split-modus in-/uitschakelen" +msgstr "Splitsmodus omschakelen" #: editor/filesystem_dock.cpp msgid "Search files" @@ -4576,7 +4562,6 @@ msgid "Animation Tools" msgstr "Animatiehulpmiddelen" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animatie" @@ -5408,7 +5393,7 @@ msgstr "Zoom terugzetten" #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp msgid "Select Mode" -msgstr "Selecteer Modus" +msgstr "Selecteermodus" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Drag: Rotate" @@ -5441,7 +5426,7 @@ msgstr "Rotatiemodus" #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp msgid "Scale Mode" -msgstr "Schaalwijze" +msgstr "Schaalmodus" #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp @@ -5449,8 +5434,8 @@ msgid "" "Show a list of all objects at the position clicked\n" "(same as Alt+RMB in select mode)." msgstr "" -"Toon een lijst van alle objecten op de aangeklikte positie\n" -"(hetzelfde als Alt+RMK in de selectiemodus)." +"Toon alle knopen op de aangeklikte positie\n" +"(zelfde als Alt+RMK in de selecteermodus)." #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Click to change object's rotation pivot." @@ -5458,7 +5443,7 @@ msgstr "Klik om het draaipunt van het object aan te passen." #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Pan Mode" -msgstr "Verschuif Modus" +msgstr "Verschuifmodus" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Ruler Mode" @@ -5653,6 +5638,10 @@ msgid "Auto Insert Key" msgstr "Sleutel automatisch invoegen" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Opties voor animatiesleutels en -poses" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Sleutel invoegen (in bestaande sporen)" @@ -5696,7 +5685,7 @@ msgstr "Knoop maken" #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp editor/scene_tree_dock.cpp msgid "Error instancing scene from %s" -msgstr "Er is iets misgegaan bij het instantiëren van scene vanaf %s" +msgstr "Fout bij het instantiëren van scène vanaf %s" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Change Default Type" @@ -5761,20 +5750,18 @@ msgstr "Emissiemasker" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Krimpen (Pixels): " +msgstr "Vaste pixels" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Randpixels" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Mappen & Bestanden:" +msgstr "Gerichte randpixels" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5906,7 +5893,7 @@ msgstr "Creëer een statisch convex lichaam" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "This doesn't work on scene root!" -msgstr "Dit werkt niet op scene root!" +msgstr "Dit werkt niet op scènewortel!" #: editor/plugins/mesh_instance_editor_plugin.cpp msgid "Create Trimesh Static Shape" @@ -5937,7 +5924,6 @@ msgid "No mesh to debug." msgstr "Geen mesh om te debuggen." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Model heeft geen UV in deze laag" @@ -6014,7 +6000,7 @@ msgid "" "Update from existing scene?:\n" "%s" msgstr "" -"Update vanuit bestaande scène?:\n" +"Bijwerken vanuit bestaande scène?:\n" "%s" #: editor/plugins/mesh_library_editor_plugin.cpp @@ -6036,7 +6022,7 @@ msgstr "Vanuit scène importeren" #: editor/plugins/mesh_library_editor_plugin.cpp msgid "Update from Scene" -msgstr "Update Vanuit Scene" +msgstr "Bijwerken vanuit scène" #: editor/plugins/multimesh_editor_plugin.cpp msgid "No mesh source specified (and no MultiMesh set in node)." @@ -6666,13 +6652,13 @@ msgstr "Script herladen mislukt, zie de console voor foutmeldingen." #: editor/plugins/script_editor_plugin.cpp msgid "Script is not in tool mode, will not be able to run." -msgstr "Script is niet in 'tool' modus en kan niet uitgevoerd worden." +msgstr "Script is niet in 'tool'-modus en kan niet uitgevoerd worden." #: editor/plugins/script_editor_plugin.cpp msgid "" "To run this script, it must inherit EditorScript and be set to tool mode." msgstr "" -"Om dit script uit te voeren moet het erven van EditorScript en in 'tool' " +"Om dit script uit te voeren moet het erven van EditorScript en in 'tool'-" "modus gezet worden." #: editor/plugins/script_editor_plugin.cpp @@ -6922,7 +6908,7 @@ msgstr "Alleen bronnen uit bestandssysteem kunnen gedropt worden." #: modules/visual_script/visual_script_editor.cpp msgid "Can't drop nodes because script '%s' is not used in this scene." msgstr "" -"Kan knopen niet plaatsen, script '%s'' wordt niet in deze scène gebruikt." +"Kan knopen niet plaatsen, script '%s' wordt niet in deze scène gebruikt." #: editor/plugins/script_text_editor.cpp msgid "Lookup Symbol" @@ -7275,7 +7261,7 @@ msgstr "Deze bewerking vereist één geselecteerde knoop." #: editor/plugins/spatial_editor_plugin.cpp msgid "Lock View Rotation" -msgstr "Vergrendel View Rotatie" +msgstr "Beeldrotatie vergrendelen" #: editor/plugins/spatial_editor_plugin.cpp msgid "Display Normal" @@ -7326,6 +7312,10 @@ msgid "Cinematic Preview" msgstr "Bioscoop Preview" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Niet beschikbaar bij gebruik van de GLES2 renderer." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Vrijekijk Links" @@ -7368,7 +7358,7 @@ msgstr "" #: editor/plugins/spatial_editor_plugin.cpp msgid "View Rotation Locked" -msgstr "Bekijk rotatie vergrendeld" +msgstr "Beeldrotatie vergrendeld" #: editor/plugins/spatial_editor_plugin.cpp msgid "XForm Dialog" @@ -8073,11 +8063,11 @@ msgstr "Geselecteerde Texture uit TileSet verwijderen." #: editor/plugins/tile_set_editor_plugin.cpp msgid "Create from Scene" -msgstr "Creëer vanuit Scene" +msgstr "Vanuit scène maken" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Merge from Scene" -msgstr "Vervoeg vanuit Scene" +msgstr "Vanuit scène samenvoegen" #: editor/plugins/tile_set_editor_plugin.cpp msgid "New Single Tile" @@ -8137,19 +8127,19 @@ msgstr "Z Index" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Region Mode" -msgstr "Regio Modus" +msgstr "Bereikmodus" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Collision Mode" -msgstr "Collision modus" +msgstr "Botsingsmodus" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Occlusion Mode" -msgstr "Occlusion Mode" +msgstr "Occlusiemodus" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Navigation Mode" -msgstr "Navigatie Modus" +msgstr "Navigatiemodus" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Bitmask Mode" @@ -8157,15 +8147,15 @@ msgstr "Bitmaskermodus" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Priority Mode" -msgstr "Prioriteit Modus" +msgstr "Prioriteitmodus" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Icon Mode" -msgstr "Icoon Modus" +msgstr "Icoonmodus" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Z Index Mode" -msgstr "Z Index Modus" +msgstr "Z-Indexmodus" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Copy bitmask." @@ -8218,11 +8208,11 @@ msgstr "Geen Texture geselecteerd om te verwijderen." #: editor/plugins/tile_set_editor_plugin.cpp msgid "Create from scene? This will overwrite all current tiles." -msgstr "Creëer vanuit scène? Hiermee worden alle huidige tegels overschreven." +msgstr "Vanuit scène maken? Alle huidige tegels zullen worden overschreven." #: editor/plugins/tile_set_editor_plugin.cpp msgid "Merge from scene?" -msgstr "Vervoegen vanuit scene?" +msgstr "Vanuit scène samenvoegen?" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Remove Texture" @@ -9450,7 +9440,7 @@ msgstr "Exporteer alle bronnen in het project" #: editor/project_export.cpp msgid "Export selected scenes (and dependencies)" -msgstr "Exporteer geselecteerde scenes (en afhankelijkheden)" +msgstr "Exporteer geselecteerde scènes (en afhankelijkheden)" #: editor/project_export.cpp msgid "Export selected resources (and dependencies)" @@ -9458,7 +9448,7 @@ msgstr "Exporteer geselecteerde bronnen (en afhankelijkheden)" #: editor/project_export.cpp msgid "Export Mode:" -msgstr "Exporteer Modus:" +msgstr "Exporteermodus:" #: editor/project_export.cpp msgid "Resources to export:" @@ -9510,7 +9500,7 @@ msgstr "Script" #: editor/project_export.cpp msgid "Script Export Mode:" -msgstr "Script Exporteer modus:" +msgstr "Script-exporteermodus:" #: editor/project_export.cpp msgid "Text" @@ -9542,7 +9532,7 @@ msgstr "Project Exporteren" #: editor/project_export.cpp msgid "Export mode?" -msgstr "Exporteer modus?" +msgstr "Exporteermodus?" #: editor/project_export.cpp msgid "Export All" @@ -9711,7 +9701,7 @@ msgstr "" #: editor/project_manager.cpp msgid "Renderer can be changed later, but scenes may need to be adjusted." msgstr "" -"Renderer kan later worden gewijzigd, scenes moeten dan mogelijk worden " +"Renderer kan later worden gewijzigd, scènes moeten dan mogelijk worden " "bijgesteld." #: editor/project_manager.cpp @@ -9720,7 +9710,7 @@ msgstr "Naamloos Project" #: editor/project_manager.cpp msgid "Missing Project" -msgstr "Ontbrekend project" +msgstr "Bestanden ontbreken" #: editor/project_manager.cpp msgid "Error: Project is missing on the filesystem." @@ -9790,9 +9780,9 @@ msgid "" "Please edit the project and set the main scene in the Project Settings under " "the \"Application\" category." msgstr "" -"Kan project niet uitvoeren: geen hoofdscène gedefinieerd.\n" -"Bewerk het project en stel de hoofdscène in bij \"Projectinstellingen\" " -"onder de categorie \"Toepassing\"." +"Kan project niet uitvoeren: geen startscène gedefinieerd.\n" +"Bewerk het project en stel de startscène in " +"Project→Projectinstellingen→Application." #: editor/project_manager.cpp msgid "" @@ -9828,7 +9818,7 @@ msgid "" "The project folders' contents won't be modified." msgstr "" "Alle ontbrekende projecten uit de lijst verwijderen?\n" -"De inhoud van de projectmap wordt niet geraakt." +"De inhoud van de projectmap wordt niet veranderd." #: editor/project_manager.cpp msgid "" @@ -9873,7 +9863,7 @@ msgstr "Nieuw Project" #: editor/project_manager.cpp msgid "Remove Missing" -msgstr "Ontbrekende verwijderen" +msgstr "Lijst opruimen" #: editor/project_manager.cpp msgid "Templates" @@ -10117,7 +10107,7 @@ msgstr "Lokale Filter Gewijzigd" #: editor/project_settings_editor.cpp msgid "Changed Locale Filter Mode" -msgstr "Lokale Filtermodus Gewijzigd" +msgstr "Taalfiltermodus gewijzigd" #: editor/project_settings_editor.cpp msgid "Project Settings (project.godot)" @@ -10201,7 +10191,7 @@ msgstr "Alleen geselecteerde talen tonen" #: editor/project_settings_editor.cpp msgid "Filter mode:" -msgstr "Filter modus:" +msgstr "Filtermodus:" #: editor/project_settings_editor.cpp msgid "Locales:" @@ -10305,7 +10295,7 @@ msgstr "Knooptype" #: editor/rename_dialog.cpp msgid "Current scene name" -msgstr "Huidige scene naam" +msgstr "Naam huidige scène" #: editor/rename_dialog.cpp msgid "Root node name" @@ -10395,7 +10385,7 @@ msgstr "Knoopouder wijzigen" #: editor/reparent_dialog.cpp msgid "Reparent Location (Select new Parent):" -msgstr "Reparent Locatie (Selecteer nieuwe Ouder):" +msgstr "Plaats instellen (selecteer nieuwe ouder):" #: editor/reparent_dialog.cpp msgid "Keep Global Transform" @@ -10403,7 +10393,7 @@ msgstr "Houd Globale Transformatie" #: editor/reparent_dialog.cpp editor/scene_tree_dock.cpp msgid "Reparent" -msgstr "Reparent" +msgstr "Ouder veranderen" #: editor/run_settings_dialog.cpp msgid "Run Mode:" @@ -10411,23 +10401,23 @@ msgstr "Uitvoermodus:" #: editor/run_settings_dialog.cpp msgid "Current Scene" -msgstr "Huidige Scene" +msgstr "Huidige scène" #: editor/run_settings_dialog.cpp msgid "Main Scene" -msgstr "Hoofdscène" +msgstr "Startscène" #: editor/run_settings_dialog.cpp msgid "Main Scene Arguments:" -msgstr "Hoofdscene Argumenten:" +msgstr "Startscène argumenten:" #: editor/run_settings_dialog.cpp msgid "Scene Run Settings" -msgstr "Scene Uitvoerinstellingen" +msgstr "Scène uitvoerinstellingen" #: editor/scene_tree_dock.cpp msgid "No parent to instance the scenes at." -msgstr "Geen ouder om scenes mee te instantiëren." +msgstr "Geen ouder om scènes mee te instantiëren." #: editor/scene_tree_dock.cpp msgid "Error loading scene from %s" @@ -10443,15 +10433,15 @@ msgstr "" #: editor/scene_tree_dock.cpp msgid "Instance Scene(s)" -msgstr "Instantie Scene(s)" +msgstr "Scène(s) instantiëren" #: editor/scene_tree_dock.cpp msgid "Replace with Branch Scene" -msgstr "Vervangen met vertakte Scene" +msgstr "Vervangen met vertakte scène" #: editor/scene_tree_dock.cpp msgid "Instance Child Scene" -msgstr "Initialiseer Kind Scene" +msgstr "Scène instantiëren" #: editor/scene_tree_dock.cpp msgid "Clear Script" @@ -10476,7 +10466,7 @@ msgstr "Dupliceer knoop/knopen" #: editor/scene_tree_dock.cpp msgid "Can't reparent nodes in inherited scenes, order of nodes can't change." msgstr "" -"Kan ouderschap van knopen in geërfde scenes niet aanpassen, volgorde van " +"Kan ouderschap van knopen in geërfde scènes niet aanpassen, volgorde van " "knopen kan niet veranderen." #: editor/scene_tree_dock.cpp @@ -10485,7 +10475,7 @@ msgstr "Knoop moet bij de bewerkte scène horen om wortelknoop te worden." #: editor/scene_tree_dock.cpp msgid "Instantiated scenes can't become root" -msgstr "Scene kan geen wortel worden" +msgstr "Geïnstantieerde scène kan geen wortel worden" #: editor/scene_tree_dock.cpp msgid "Make node as Root" @@ -10513,11 +10503,11 @@ msgstr "Kan deze operatie niet uitvoeren met de wortelknoop." #: editor/scene_tree_dock.cpp msgid "This operation can't be done on instanced scenes." -msgstr "Deze operatie kan niet worden uitgevoerd op instanced scenes." +msgstr "Deze operatie kan niet worden uitgevoerd op geïnstantieerde scènes." #: editor/scene_tree_dock.cpp msgid "Save New Scene As..." -msgstr "Nieuwe Scène Opslaan Als..." +msgstr "Nieuwe scène opslaan als..." #: editor/scene_tree_dock.cpp msgid "" @@ -10542,7 +10532,7 @@ msgstr "Maak locaal" #: editor/scene_tree_dock.cpp msgid "New Scene Root" -msgstr "Nieuwe wortel Scene" +msgstr "Nieuwe scènewortel" #: editor/scene_tree_dock.cpp msgid "Create Root Node:" @@ -10594,11 +10584,11 @@ msgstr "" #: editor/scene_tree_dock.cpp msgid "Error saving scene." -msgstr "Fout bij het opslaan van de scene." +msgstr "Fout bij het opslaan van de scène." #: editor/scene_tree_dock.cpp msgid "Error duplicating scene to save it." -msgstr "Fout bij het opslaan van een gekopieerde scene." +msgstr "Fout bij het opslaan van een gekopieerde scène." #: editor/scene_tree_dock.cpp msgid "Sub-Resources" @@ -10626,11 +10616,11 @@ msgstr "Knoop hieronder toevoegen" #: editor/scene_tree_dock.cpp msgid "Expand/Collapse All" -msgstr "Alles Uitklappen/Inklappen" +msgstr "Alles uit-/inklappen" #: editor/scene_tree_dock.cpp msgid "Change Type" -msgstr "Verander het type" +msgstr "Type veranderen" #: editor/scene_tree_dock.cpp msgid "Reparent to New Node" @@ -10638,15 +10628,15 @@ msgstr "Onder nieuwe knoop hangen" #: editor/scene_tree_dock.cpp msgid "Make Scene Root" -msgstr "Maak Scene wortel" +msgstr "Scènewortel instellen" #: editor/scene_tree_dock.cpp msgid "Merge From Scene" -msgstr "Samenvoegen uit scene" +msgstr "Samenvoegen uit scène" #: editor/scene_tree_dock.cpp editor/script_editor_debugger.cpp msgid "Save Branch as Scene" -msgstr "Tak opslaan als Scene" +msgstr "Tak opslaan als scène" #: editor/scene_tree_dock.cpp editor/script_editor_debugger.cpp msgid "Copy Node Path" @@ -10741,7 +10731,7 @@ msgid "" "Node is locked.\n" "Click to unlock it." msgstr "" -"Knooppund vergrendeld.\n" +"Knoop is vergrendeld.\n" "Klik om te ontgrendelen." #: editor/scene_tree_editor.cpp @@ -10862,7 +10852,7 @@ msgstr "Toegestaan: a-z, A-Z, 0-9 en ." #: editor/script_create_dialog.cpp msgid "Built-in script (into scene file)." -msgstr "Ingebouwd script (in scene bestand)." +msgstr "Ingebouwd script (in scènebestand)." #: editor/script_create_dialog.cpp msgid "Will create a new script file." @@ -10873,9 +10863,8 @@ msgid "Will load an existing script file." msgstr "Laad bestaand script." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "Bestaat al" +msgstr "Scriptbestand bestaat al." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12074,7 +12063,7 @@ msgid "" "scenes). The first created one will work, while the rest will be ignored." msgstr "" "Maar één zichtbare CanvasModulate is toegestaan per scene (of set van " -"geïnstantieerde scenes). De eerst gemaakte zal werken, terwijl de rest " +"geïnstantieerde scènes). De eerst gemaakte zal werken, terwijl de rest " "genegeerd wordt." #: scene/2d/collision_object_2d.cpp @@ -12498,8 +12487,8 @@ msgstr "" msgid "" "Only one WorldEnvironment is allowed per scene (or set of instanced scenes)." msgstr "" -"Slechts één WorldEnvironment is toegestaan per scene (of set van " -"geïnstantieerde scenes)." +"Slechts één WorldEnvironment is toegestaan per scène (of verzameling van " +"geïnstantieerde scènes)." #: scene/3d/world_environment.cpp msgid "" @@ -12556,11 +12545,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Kleur: #%s\n" +"LMK: Kleur instellen\n" +"RMK: Voorinstelling verwijderen" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Kies een kleur van het scherm." +msgstr "Kies een kleur uit het editorvenster." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12682,6 +12673,24 @@ msgstr "Varyings kunnen alleen worden toegewezenin vertex functies." msgid "Constants cannot be modified." msgstr "Constanten kunnen niet worden aangepast." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Er is momenteel geen handleiding voor deze methode. Help ons alsjeblieft " +#~ "door [color=$color][url=$url]een toe te voegen[/url][/color] of [color=" +#~ "$color][url=$url2]een aan te vragen[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Korte Omschrijving" + +#~ msgid "Class Description" +#~ msgstr "Klassebeschrijving" + #~ msgid "Project export failed with error code %d." #~ msgstr "Project exporteren faalt door foutcode %d." diff --git a/editor/translations/or.po b/editor/translations/or.po index 881d3aee64..5cddf8dee7 100644 --- a/editor/translations/or.po +++ b/editor/translations/or.po @@ -1884,50 +1884,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4355,7 +4352,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5398,6 +5394,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5678,7 +5678,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7048,6 +7047,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/pl.po b/editor/translations/pl.po index 25d7a396af..e5e5e91d65 100644 --- a/editor/translations/pl.po +++ b/editor/translations/pl.po @@ -42,7 +42,7 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" +"PO-Revision-Date: 2020-01-27 07:10+0000\n" "Last-Translator: Tomek <kobewi4e@gmail.com>\n" "Language-Team: Polish <https://hosted.weblate.org/projects/godot-engine/" "godot/pl/>\n" @@ -52,7 +52,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 " "|| n%100>=20) ? 1 : 2;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1223,9 +1223,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "BÅ‚Ä…d otwierania pliku pakietu, nie jest w formacie ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Już istnieje" +msgstr "%s (już istnieje)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1236,9 +1235,8 @@ msgid "The following files failed extraction from package:" msgstr "Nie powiodÅ‚o się wypakowanie z pakietu nastÄ™pujÄ…cych plików:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "PozostaÅ‚o %d plików" +msgstr "I jeszcze %s plików." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1250,9 +1248,8 @@ msgid "Success!" msgstr "Sukces!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Zawartość:" +msgstr "Zawartość paczki:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1392,9 +1389,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Plik niepoprawny, nie jest ukÅ‚adem magistral audio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "BÅ‚Ä…d zapisywania pliku!" +msgstr "BÅ‚Ä…d zapisywania pliku: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1966,14 +1962,26 @@ msgid "Inherited by:" msgstr "Dziedziczone przez:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Krótki opis" +msgid "Description" +msgstr "Opis" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Poradniki online" #: editor/editor_help.cpp msgid "Properties" msgstr "WÅ‚aÅ›ciwoÅ›ci" #: editor/editor_help.cpp +msgid "override:" +msgstr "nadpisanie:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "domyÅ›lne:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metody" @@ -1986,36 +1994,18 @@ msgid "Enumerations" msgstr "Wyliczenia" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "StaÅ‚e" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Opis klasy" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Poradniki online" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Obecnie nie ma żadnych samouczków dla tej klasy, możesz [color=$color][url=" -"$url]dodać jeden[/url][/color] lub [color=$color][url=$url2]poprosić o " -"jakiÅ›[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Opisy wÅ‚aÅ›ciwoÅ›ci" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(wartość)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4556,7 +4546,6 @@ msgid "Animation Tools" msgstr "NarzÄ™dzia do animacji" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animacja" @@ -5633,6 +5622,10 @@ msgid "Auto Insert Key" msgstr "Automatycznie wstaw klucz" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Opcje kluczy animacji i pozy" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Wstaw klucz (istniejÄ…ce Å›cieżki)" @@ -5741,20 +5734,18 @@ msgstr "Maska emisji" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Zmniejsz (piksele): " +msgstr "Widoczne piksele" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Brzegowe piksele" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Katalogi i pliki:" +msgstr "Skierowane brzegowe piksele" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5917,7 +5908,6 @@ msgid "No mesh to debug." msgstr "Brak siatki do debugowania." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Model nie posiada UV w tej warstwie" @@ -7304,6 +7294,10 @@ msgid "Cinematic Preview" msgstr "PodglÄ…d kinowy" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "NiedostÄ™pne dla renderera GLES2." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "\"Wolny widok\" w lewo" @@ -8013,8 +8007,8 @@ msgid "" "Shift+LMB: Line Draw\n" "Shift+Ctrl+LMB: Rectangle Paint" msgstr "" -"Shift+PPM: Rysowanie linii\n" -"Shift+Ctrl+PPM: Malowanie prostokÄ…ta" +"Shift+LPM: Rysowanie linii\n" +"Shift+Ctrl+LPM: Malowanie prostokÄ…ta" #: editor/plugins/tile_map_editor_plugin.cpp msgid "Pick Tile" @@ -10834,9 +10828,8 @@ msgid "Will load an existing script file." msgstr "Wczytaj istniejÄ…cy plik skryptu." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "PodziaÅ‚ już istnieje." +msgstr "Plik skryptu już istnieje." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12517,11 +12510,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Kolor: #%s\n" +"LPM: Ustaw ten kolor\n" +"PPM: UsuÅ„ próbkÄ™" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Pobierz kolor z ekranu." +msgstr "Pobierz kolor z okna edytora." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12641,6 +12636,24 @@ msgstr "Varying może być przypisane tylko w funkcji wierzchoÅ‚ków." msgid "Constants cannot be modified." msgstr "StaÅ‚e nie mogÄ… być modyfikowane." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Obecnie nie ma żadnych samouczków dla tej klasy, możesz [color=$color]" +#~ "[url=$url]dodać jeden[/url][/color] lub [color=$color][url=$url2]poprosić " +#~ "o jakiÅ›[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Krótki opis" + +#~ msgid "Class Description" +#~ msgstr "Opis klasy" + #~ msgid "Project export failed with error code %d." #~ msgstr "Eksport projektu nie powiódÅ‚ siÄ™, kod bÅ‚Ä™du to %d." diff --git a/editor/translations/pr.po b/editor/translations/pr.po index b46588aa01..e77bf47b81 100644 --- a/editor/translations/pr.po +++ b/editor/translations/pr.po @@ -1954,14 +1954,26 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "Yar, Blow th' Selected Down!" #: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "" + +#: editor/editor_help.cpp msgid "Properties" msgstr "" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "" + +#: editor/editor_help.cpp msgid "Methods" msgstr "" @@ -1976,31 +1988,15 @@ msgid "Enumerations" msgstr "Yer functions:" #: editor/editor_help.cpp -msgid "enum " -msgstr "" - -#: editor/editor_help.cpp msgid "Constants" msgstr "" #: editor/editor_help.cpp -#, fuzzy -msgid "Class Description" -msgstr "Yar, Blow th' Selected Down!" - -#: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" - -#: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4510,7 +4506,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5581,6 +5576,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5867,7 +5866,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7277,6 +7275,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12456,6 +12458,10 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "Yar, Blow th' Selected Down!" + #~ msgid "Base Type:" #~ msgstr "th' Base Type:" diff --git a/editor/translations/pt_BR.po b/editor/translations/pt_BR.po index 212e1ceae1..a7d921b78e 100644 --- a/editor/translations/pt_BR.po +++ b/editor/translations/pt_BR.po @@ -78,12 +78,14 @@ # Zeero <igcdzeero@gmail.com>, 2019. # Gian Penna <gianfrancopen@gmail.com>, 2020. # sribgui <sribgui@gmail.com>, 2020. +# patrickvob <patrickvob@gmail.com>, 2020. +# Michael Leocádio <aeronmike@gmail.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: 2016-05-30\n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" -"Last-Translator: sribgui <sribgui@gmail.com>\n" +"PO-Revision-Date: 2020-01-27 07:10+0000\n" +"Last-Translator: Michael Leocádio <aeronmike@gmail.com>\n" "Language-Team: Portuguese (Brazil) <https://hosted.weblate.org/projects/" "godot-engine/godot/pt_BR/>\n" "Language: pt_BR\n" @@ -91,7 +93,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n > 1;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -238,11 +240,11 @@ msgstr "Alterar Tempo de Quadro-Chave da Anim Multi" #: editor/animation_track_editor.cpp msgid "Anim Multi Change Transition" -msgstr "Alterar Transição da Animação Múltipla" +msgstr "Transição de Animação com Múltiplas Mudanças" #: editor/animation_track_editor.cpp msgid "Anim Multi Change Transform" -msgstr "Alterar Transformação da Animação Múltipla" +msgstr "Transformação de Animação com Múltiplas Mudanças" #: editor/animation_track_editor.cpp msgid "Anim Multi Change Keyframe Value" @@ -344,7 +346,7 @@ msgstr "Tempo (s): " #: editor/animation_track_editor.cpp msgid "Toggle Track Enabled" -msgstr "Alternar Trilha Ativado" +msgstr "Habilitar/Desabilitar Trilha" #: editor/animation_track_editor.cpp msgid "Continuous" @@ -492,7 +494,7 @@ msgstr "Não é possÃvel adicionar uma nova trilha sem uma raiz" #: editor/animation_track_editor.cpp msgid "Invalid track for Bezier (no suitable sub-properties)" -msgstr "trajeto inválido para Bézier (sem subpropriedades adequadas)" +msgstr "Trilha inválida para Bézier (sem subpropriedades adequadas)" #: editor/animation_track_editor.cpp msgid "Add Bezier Track" @@ -508,7 +510,7 @@ msgstr "Trilha não é do tipo Espacial,não pode inserir chave" #: editor/animation_track_editor.cpp msgid "Add Transform Track Key" -msgstr "Adicionar Chave de Transformação de Trilha" +msgstr "Adicionar Chave de Trilha de Transformação" #: editor/animation_track_editor.cpp msgid "Add Track Key" @@ -521,7 +523,7 @@ msgstr "" #: editor/animation_track_editor.cpp msgid "Add Method Track Key" -msgstr "Adicionar Chave de Trilha de Chamada de Método" +msgstr "Adicionar Chave de Trilha de Método" #: editor/animation_track_editor.cpp msgid "Method not found in object: " @@ -732,7 +734,7 @@ msgstr "Adicionar Clipe de Trilha de Ãudio" #: editor/animation_track_editor_plugins.cpp msgid "Change Audio Track Clip Start Offset" -msgstr "Alterar Deslocamento do InÃcio de Clipe da Trilha de Ãudio" +msgstr "Alterar Offset de InÃcio do Clipe da Trilha de Ãudio" #: editor/animation_track_editor_plugins.cpp msgid "Change Audio Track Clip End Offset" @@ -1262,9 +1264,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Erro ao abrir arquivo compactado, não está no formato ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Já existe" +msgstr "%s (Já existe)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1275,9 +1276,8 @@ msgid "The following files failed extraction from package:" msgstr "Os arquivos a seguir falharam ao serem extraÃdos do pacote:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d mais arquivo(s)" +msgstr "%s mais arquivo(s)." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1289,7 +1289,6 @@ msgid "Success!" msgstr "Sucesso!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" msgstr "Conteúdo:" @@ -1431,9 +1430,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Arquivo inválido, não é um layout de canais de áudio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Erro ao salvar o arquivo!" +msgstr "Erro ao salvar o arquivo: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1441,7 +1439,7 @@ msgstr "Adicionar Canal" #: editor/editor_audio_buses.cpp msgid "Add a new Audio Bus to this layout." -msgstr "Adicionar novo Canal de Ãudio a esse layout." +msgstr "Adicionar novo Canal de Ãudio a este layout." #: editor/editor_audio_buses.cpp editor/editor_properties.cpp #: editor/plugins/animation_player_editor_plugin.cpp editor/property_editor.cpp @@ -2007,14 +2005,26 @@ msgid "Inherited by:" msgstr "Herdado por:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Breve Descrição" +msgid "Description" +msgstr "Descrição" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Tutoriais Online" #: editor/editor_help.cpp msgid "Properties" msgstr "Propriedades" #: editor/editor_help.cpp +msgid "override:" +msgstr "sobrescrever:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "padrão:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Métodos" @@ -2027,36 +2037,18 @@ msgid "Enumerations" msgstr "Enumerações" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Constantes" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Descrição da Classe" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Tutoriais Online" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Atualmente não há tutoriais para essa classe. Você pode [color=$color][url=" -"$url]contribuir criando um[/url][/color] ou [color=$color][url=" -"$url2]solicitar[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Descrições da Propriedade" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(valor)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -2143,7 +2135,7 @@ msgstr "Propriedade" #: editor/editor_help_search.cpp msgid "Theme Property" -msgstr "Propriedades do Tema" +msgstr "Propriedade do Tema" #: editor/editor_inspector.cpp editor/project_settings_editor.cpp msgid "Property:" @@ -3118,11 +3110,11 @@ msgid "" "preset." msgstr "" "Isso irá configurar seu projeto para compilações customizadas do Android " -"instalando o modelo de origem para \"res://android/build\".\n" +"instalando o template raÃz em \"res://android/build\".\n" "Em seguida, você pode aplicar modificações e compilar seu próprio APK " -"customizado na exportação (Adicionando módulos, alterando o AndroidManifest." +"customizado na exportação (adicionando módulos, alterando o AndroidManifest." "xml, etc.).\n" -"Note que para fazer uma compilação customizada, em vez de usar APKs pre-" +"Note que para fazer uma compilação customizada em vez de usar APKs pre-" "compilados, a opção \"Usar compilação customizada\" deve estar ativa nas " "predefinições de exportação do Android." @@ -4612,7 +4604,6 @@ msgid "Animation Tools" msgstr "Ferramentas de Animação" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animação" @@ -5272,8 +5263,8 @@ msgid "" "Children of containers have their anchors and margins values overridden by " "their parent." msgstr "" -"Filhos de contêineres tem suas ancoragens e valores de margem sobrescritos " -"pelos seus pais." +"Filhos de contêineres tem suas posições e margens sobrescritos pelos seus " +"pais." #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Presets for the anchors and margins values of a Control node." @@ -5342,11 +5333,11 @@ msgstr "Inferior Largo" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "VCenter Wide" -msgstr "Visão Centralizada Verticalmente" +msgstr "Centro Vertical Largo" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "HCenter Wide" -msgstr "Visão Centralizada Horizontalmente" +msgstr "Centro Horizontal Largo" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Full Rect" @@ -5687,6 +5678,10 @@ msgid "Auto Insert Key" msgstr "Inserir Chave Automaticamente" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Opções de Chave e Pose de Animação" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Inserir Chave (Trilhas Existentes)" @@ -5795,20 +5790,18 @@ msgstr "Máscara de Emissão" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Diminuir (Pixels): " +msgstr "Pixels Sólidos" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Pixels de Borda" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Diretórios & Arquivos:" +msgstr "Pixels de Borda Direcionados" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5971,7 +5964,6 @@ msgid "No mesh to debug." msgstr "Nenhuma malha para depurar." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Modelo não tem uma UV nesta camada" @@ -6999,7 +6991,7 @@ msgstr "Marcadores" #: editor/plugins/script_text_editor.cpp msgid "Breakpoints" -msgstr "Pontos de interrupção(Breakpoints)" +msgstr "Breakpoints" #: editor/plugins/script_text_editor.cpp scene/gui/line_edit.cpp #: scene/gui/text_edit.cpp @@ -7361,6 +7353,10 @@ msgid "Cinematic Preview" msgstr "Pré-visualização Cinemática" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Não disponÃvel ao usar o renderizador GLES2." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Visão Livre Esquerda" @@ -7622,7 +7618,7 @@ msgstr "Visualizar PolÃgono De Colisão 2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create LightOccluder2D" -msgstr "Criar OclusorDeLuz2D" +msgstr "Criar LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "LightOccluder2D Preview" @@ -7799,7 +7795,7 @@ msgstr "Selecionar/Deselecionar Todos os Frames" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "Create Frames from Sprite Sheet" -msgstr "Criar Frames a partir da Planilha de Sprites" +msgstr "Criar Frames a partir da Sprite Sheet" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "SpriteFrames" @@ -7928,7 +7924,7 @@ msgstr "Item Rádio Marcado" #: editor/plugins/theme_editor_plugin.cpp msgid "Named Sep." -msgstr "Sep. Nomeado" +msgstr "Sep. Nomeado." #: editor/plugins/theme_editor_plugin.cpp msgid "Submenu" @@ -8058,7 +8054,7 @@ msgstr "Filtros do tile" #: editor/plugins/tile_map_editor_plugin.cpp msgid "Give a TileSet resource to this TileMap to use its tiles." -msgstr "Atribua um recurso TileSet a este TileMap para usar seus tiles." +msgstr "Atribua um recurso de TileSet a este TileMap para usar seus tiles." #: editor/plugins/tile_map_editor_plugin.cpp msgid "Paint Tile" @@ -8078,11 +8074,11 @@ msgstr "Pegar Tile" #: editor/plugins/tile_map_editor_plugin.cpp msgid "Rotate Left" -msgstr "Rotacionar para a esquerda" +msgstr "Girar à esquerda" #: editor/plugins/tile_map_editor_plugin.cpp msgid "Rotate Right" -msgstr "Rotacionar para a direita" +msgstr "Girar à direita" #: editor/plugins/tile_map_editor_plugin.cpp msgid "Flip Horizontally" @@ -10889,9 +10885,8 @@ msgid "Will load an existing script file." msgstr "Carregará arquivo de script existente." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "A ação \"%s\" já existe!" +msgstr "O arquivo de script já existe." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12570,11 +12565,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Cor: #%s\n" +"LMB: Escolher cor\n" +"RMB: Remover preset" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Escolha uma cor da tela." +msgstr "Escolha uma cor da janela do editor." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12696,6 +12693,24 @@ msgstr "Variáveis só podem ser atribuÃdas na função de vértice." msgid "Constants cannot be modified." msgstr "Constantes não podem serem modificadas." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Atualmente não há tutoriais para essa classe. Você pode [color=$color]" +#~ "[url=$url]contribuir criando um[/url][/color] ou [color=$color][url=" +#~ "$url2]solicitar[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Breve Descrição" + +#~ msgid "Class Description" +#~ msgstr "Descrição da Classe" + #~ msgid "Project export failed with error code %d." #~ msgstr "Falha na exportação do projeto com código de erro %d." diff --git a/editor/translations/pt_PT.po b/editor/translations/pt_PT.po index f0728bd81d..d293860dec 100644 --- a/editor/translations/pt_PT.po +++ b/editor/translations/pt_PT.po @@ -19,7 +19,7 @@ msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" +"PO-Revision-Date: 2020-01-27 07:10+0000\n" "Last-Translator: João Lopes <linux-man@hotmail.com>\n" "Language-Team: Portuguese (Portugal) <https://hosted.weblate.org/projects/" "godot-engine/godot/pt_PT/>\n" @@ -28,7 +28,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1202,9 +1202,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Erro ao abrir ficheiro comprimido, não está no formato ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Já existe" +msgstr "%s (Já Existe)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1215,9 +1214,8 @@ msgid "The following files failed extraction from package:" msgstr "Falhou a extração dos seguintes Ficheiros do pacote:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d mais Ficheiros" +msgstr "E mais %s ficheiros." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1229,9 +1227,8 @@ msgid "Success!" msgstr "Sucesso!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Conteúdos:" +msgstr "Conteúdo do Pacote:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1371,9 +1368,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "Ficheiro inválido, não é um Modelo válido de barramento de áudio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Erro ao guardar ficheiro!" +msgstr "Erro ao guardar ficheiro: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1949,14 +1945,26 @@ msgid "Inherited by:" msgstr "Herdado por:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Breve Descrição" +msgid "Description" +msgstr "Descrição" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Tutoriais Online" #: editor/editor_help.cpp msgid "Properties" msgstr "Propriedades" #: editor/editor_help.cpp +msgid "override:" +msgstr "Sobrepõe:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "Padrão:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Métodos" @@ -1969,36 +1977,18 @@ msgid "Enumerations" msgstr "Enumerações" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Constantes" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Descrição da Classe" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Tutoriais Online" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Atualmente não existem tutoriais para esta classe, pode [color=$color][url=" -"$url]contribuir com um[/url][/color] ou [color=$color][url=$url2]solicitar " -"um[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Descrições da Propriedade" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(valor)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4475,7 +4465,7 @@ msgstr "Renomear Animação" #: editor/plugins/animation_player_editor_plugin.cpp msgid "Blend Next Changed" -msgstr "Misturar seguinte alterado" +msgstr "Misturar Seguinte Alterado" #: editor/plugins/animation_player_editor_plugin.cpp msgid "Change Blend Time" @@ -4543,7 +4533,6 @@ msgid "Animation Tools" msgstr "Ferramentas de Animação" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animação" @@ -4636,7 +4625,7 @@ msgstr "Tempos de Mistura:" #: editor/plugins/animation_player_editor_plugin.cpp msgid "Next (Auto Queue):" -msgstr "Próximo (auto-fila):" +msgstr "Próximo (Auto-Fila):" #: editor/plugins/animation_player_editor_plugin.cpp msgid "Cross-Animation Blend Times" @@ -5025,7 +5014,7 @@ msgstr "Anterior" #: editor/plugins/asset_library_editor_plugin.cpp msgid "Next" -msgstr "Proximo" +msgstr "Próximo" #: editor/plugins/asset_library_editor_plugin.cpp msgid "Last" @@ -5613,6 +5602,10 @@ msgid "Auto Insert Key" msgstr "Inserir Chave automaticamente" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Chave de Animação e Opções de Pose" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Inserir Chave (Pistas existentes)" @@ -5721,20 +5714,18 @@ msgstr "Máscara de Emissão" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "Encolher (Pixeis): " +msgstr "Pixeis Sólidos" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Pixeis da Margem" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Diretorias e Ficheiros:" +msgstr "Pixeis da Margem Dirigidos" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5897,7 +5888,6 @@ msgid "No mesh to debug." msgstr "Nenhuma malha para depurar." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "O Modelo não tem UV nesta camada" @@ -6727,7 +6717,7 @@ msgstr "Histórico Anterior" #: editor/plugins/script_editor_plugin.cpp msgid "History Next" -msgstr "Histórico seguinte" +msgstr "Histórico Seguinte" #: editor/plugins/script_editor_plugin.cpp #: editor/plugins/theme_editor_plugin.cpp @@ -7281,6 +7271,10 @@ msgid "Cinematic Preview" msgstr "Pré-visualização Cinemática" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Não disponÃvel para o renderizador GLES2." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Vista livre esquerda" @@ -7602,7 +7596,7 @@ msgstr "Encolher (Pixeis): " #: editor/plugins/sprite_editor_plugin.cpp msgid "Grow (Pixels): " -msgstr "Crescer (Pixeis): " +msgstr "Aumentar (Pixeis): " #: editor/plugins/sprite_editor_plugin.cpp msgid "Update Preview" @@ -10802,9 +10796,8 @@ msgid "Will load an existing script file." msgstr "Vai carregar ficheiro de script existente." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "Separação já existe." +msgstr "Ficheiro Script já existe." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -10884,7 +10877,7 @@ msgstr "Inspecionar instância anterior" #: editor/script_editor_debugger.cpp msgid "Inspect Next Instance" -msgstr "Inspecionar próxima instância" +msgstr "Inspecionar Próxima Instância" #: editor/script_editor_debugger.cpp msgid "Stack Frames" @@ -11158,11 +11151,11 @@ msgstr "Objeto não fornece um comprimento." #: modules/gridmap/grid_map_editor_plugin.cpp msgid "Next Plane" -msgstr "Plano seguinte" +msgstr "Plano Seguinte" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "Previous Plane" -msgstr "Plano anterior" +msgstr "Plano Anterior" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "Plane:" @@ -12480,11 +12473,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Cor: #%s\n" +"LMB: Definir color\n" +"RMB: Remover predefinição" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Escolha uma cor do ecrã." +msgstr "Escolha uma cor através do editor." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12605,6 +12600,24 @@ msgstr "Variações só podem ser atribuÃdas na função vértice." msgid "Constants cannot be modified." msgstr "Constantes não podem ser modificadas." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Atualmente não existem tutoriais para esta classe, pode [color=$color]" +#~ "[url=$url]contribuir com um[/url][/color] ou [color=$color][url=" +#~ "$url2]solicitar um[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#~ msgid "Brief Description" +#~ msgstr "Breve Descrição" + +#~ msgid "Class Description" +#~ msgstr "Descrição da Classe" + #~ msgid "Project export failed with error code %d." #~ msgstr "Exportação do projeto falhou com código de erro %d." diff --git a/editor/translations/ro.po b/editor/translations/ro.po index 6625e3a8b4..e73e0c1703 100644 --- a/editor/translations/ro.po +++ b/editor/translations/ro.po @@ -9,12 +9,14 @@ # Grigore Antoniuc <grisa181@gmail.com>, 2018. # Boby Ilea <boby.ilea@gmail.com>, 2019. # EVOKZH <avip.ady@gmail.com>, 2019. +# Marincia Catalin <catalinmarincia@gmail.com>, 2020. +# Marincia Cătălin <catalinmarincia@gmail.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2019-11-09 22:04+0000\n" -"Last-Translator: EVOKZH <avip.ady@gmail.com>\n" +"PO-Revision-Date: 2020-01-23 15:05+0000\n" +"Last-Translator: Marincia Cătălin <catalinmarincia@gmail.com>\n" "Language-Team: Romanian <https://hosted.weblate.org/projects/godot-engine/" "godot/ro/>\n" "Language: ro\n" @@ -23,26 +25,26 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=n==1 ? 0 : (n==0 || (n%100 > 0 && n%100 < " "20)) ? 1 : 2;\n" -"X-Generator: Weblate 3.10-dev\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp msgid "Invalid type argument to convert(), use TYPE_* constants." -msgstr "Argument de tip invalid pentru convert(), folosiÈ›i constante TYPE_*" +msgstr "Argument de tip invalid pentru convert(), folosiÈ›i constante TYPE_*." #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp msgid "Expected a string of length 1 (a character)." -msgstr "" +msgstr "Se aÈ™teaptă un È™ir de lungime 1 (un caracter)." #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/mono/glue/gd_glue.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp msgid "Not enough bytes for decoding bytes, or invalid format." -msgstr "Bytes insuficienti pentru decodare bytes, sau format invalid" +msgstr "Bytes insuficienti pentru decodare bytes, sau format invalid." #: core/math/expression.cpp msgid "Invalid input %i (not passed) in expression" -msgstr "Intrare invalida %i in expresie" +msgstr "Intrare invalida %i (nu a fost transmisă) in expresie" #: core/math/expression.cpp msgid "self can't be used because instance is null (not passed)" @@ -50,7 +52,7 @@ msgstr "self nu poate fi folosit deoarece instanÈ›a este nulă (nefurnizat)" #: core/math/expression.cpp msgid "Invalid operands to operator %s, %s and %s." -msgstr "Operanzi invalizi la operatorii %s, %s È™i %s" +msgstr "Operanzi invalizi la operatorii %s, %s È™i %s." #: core/math/expression.cpp msgid "Invalid index of type %s for base type %s" @@ -177,19 +179,16 @@ msgid "Anim Multi Change Transform" msgstr "Anim Transformare multifuncÈ›ională" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Anim Multi Change Keyframe Value" msgstr "Anim Schimbare valoare cadre cheie" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Anim Multi Change Call" -msgstr "Anim Schimbare apelare" +msgstr "Anim Apel multi-schimbare" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Change Animation Length" -msgstr "Schimbă Numele AnimaÈ›iei:" +msgstr "Schimbă Durata AnimaÈ›iei" #: editor/animation_track_editor.cpp #: editor/plugins/sprite_frames_editor_plugin.cpp @@ -198,99 +197,88 @@ msgstr "SchimbaÈ›i Bucla AnimaÈ›iei" #: editor/animation_track_editor.cpp msgid "Property Track" -msgstr "" +msgstr "Lista De Proprietati" #: editor/animation_track_editor.cpp -#, fuzzy msgid "3D Transform Track" -msgstr "Transformare hartă UV" +msgstr "Transformare Pistei 3d" #: editor/animation_track_editor.cpp msgid "Call Method Track" -msgstr "" +msgstr "Cheama linia de metode" #: editor/animation_track_editor.cpp msgid "Bezier Curve Track" -msgstr "" +msgstr "Traseu curbă Bezier" #: editor/animation_track_editor.cpp msgid "Audio Playback Track" -msgstr "" +msgstr "Cale Audio Playback" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Animation Playback Track" -msgstr "OpreÈ™te rularea animaÈ›iei. (S)" +msgstr "OpreÈ™te rularea animaÈ›iei" #: editor/animation_track_editor.cpp msgid "Animation length (frames)" -msgstr "Lungime AnimaÈ›ie (în frame-uri)." +msgstr "Lungime AnimaÈ›ie (în frame-uri)" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Animation length (seconds)" -msgstr "Lungime AnimaÈ›ie (în secunde)." +msgstr "Lungime AnimaÈ›ie (în secunde)" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Add Track" -msgstr "Anim AdăugaÈ›i Pistă" +msgstr "AdăugaÈ›i Pistă" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Animation Looping" -msgstr "Zoom AnimaÈ›ie." +msgstr "Zoom AnimaÈ›ie" #: editor/animation_track_editor.cpp #: modules/visual_script/visual_script_editor.cpp msgid "Functions:" -msgstr "" +msgstr "FuncÈ›ii:" #: editor/animation_track_editor.cpp msgid "Audio Clips:" -msgstr "" +msgstr "SecvenÈ›e Audio:" #: editor/animation_track_editor.cpp msgid "Anim Clips:" -msgstr "" +msgstr "SecvenÈ›e Anim:" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Change Track Path" -msgstr "SchimbaÈ›i Valoarea Array-ului" +msgstr "SchimbaÈ›i Valoarea Pistei" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Toggle this track on/off." -msgstr "Comutează modul fără distrageri." +msgstr "Comutează această pistă pornit/oprit." #: editor/animation_track_editor.cpp msgid "Update Mode (How this property is set)" -msgstr "" +msgstr "Modul Actualizare (Cum este setată această proprietate)" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Interpolation Mode" -msgstr "Nod de AnimaÈ›ie" +msgstr "Mod Intercalare" #: editor/animation_track_editor.cpp msgid "Loop Wrap Mode (Interpolate end with beginning on loop)" msgstr "" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Remove this track." msgstr "ȘtergeÈ›i pista selectată." #: editor/animation_track_editor.cpp -#, fuzzy msgid "Time (s): " -msgstr "Timp X-Decolorare (s):" +msgstr "Timp (s): " #: editor/animation_track_editor.cpp -#, fuzzy msgid "Toggle Track Enabled" -msgstr "Activare mod Doppler" +msgstr "Comută Pista Activată" #: editor/animation_track_editor.cpp msgid "Continuous" @@ -305,13 +293,12 @@ msgid "Trigger" msgstr "Trăgaci" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Capture" -msgstr "Viitor" +msgstr "Capturează" #: editor/animation_track_editor.cpp msgid "Nearest" -msgstr "" +msgstr "Cel mai apropiat" #: editor/animation_track_editor.cpp editor/plugins/curve_editor_plugin.cpp #: editor/property_editor.cpp @@ -320,7 +307,7 @@ msgstr "Linear" #: editor/animation_track_editor.cpp msgid "Cubic" -msgstr "" +msgstr "Cubic" #: editor/animation_track_editor.cpp msgid "Clamp Loop Interp" @@ -336,29 +323,24 @@ msgid "Insert Key" msgstr "Inserează Notă" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Duplicate Key(s)" -msgstr "Anim Clonare Chei" +msgstr "Clonare Chei(s)" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Delete Key(s)" -msgstr "Anim ȘtergeÈ›i Cheile" +msgstr "ȘtergeÈ›i Cheile" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Change Animation Update Mode" -msgstr "Schimbă Numele AnimaÈ›iei:" +msgstr "Schimbă Modul de Actualizare al AnimaÈ›iei" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Change Animation Interpolation Mode" -msgstr "Nod de AnimaÈ›ie" +msgstr "Schimbă Modul de Intercalare al AnimaÈ›iei" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Change Animation Loop Mode" -msgstr "SchimbaÈ›i Bucla Anim" +msgstr "SchimbaÈ›i Bucla AnimaÈ›iei" #: editor/animation_track_editor.cpp msgid "Remove Anim Track" @@ -390,7 +372,7 @@ msgstr "Anim InseraÈ›i" #: editor/animation_track_editor.cpp msgid "AnimationPlayer can't animate itself, only other players." -msgstr "" +msgstr "AnimationPlayer nu se poate anima singur, doar alÈ›i jucători." #: editor/animation_track_editor.cpp msgid "Anim Create & Insert" @@ -405,18 +387,16 @@ msgid "Anim Insert Key" msgstr "Anim InseraÈ›i Cheie" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Change Animation Step" -msgstr "Schimbă Numele AnimaÈ›iei:" +msgstr "Schimbă Pasul AnimaÈ›iei" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Rearrange Tracks" msgstr "RearanjaÈ›i Autoload-urile" #: editor/animation_track_editor.cpp msgid "Transform tracks only apply to Spatial-based nodes." -msgstr "" +msgstr "Transformă pistele se aplică numai nodurile SpaÈ›ial-bazate." #: editor/animation_track_editor.cpp msgid "" @@ -428,7 +408,7 @@ msgstr "" #: editor/animation_track_editor.cpp msgid "Animation tracks can only point to AnimationPlayer nodes." -msgstr "" +msgstr "Pistele de animaÈ›ie pot direcÈ›iona numai nodurilor AnimaÈ›ieJucător." #: editor/animation_track_editor.cpp msgid "An animation player can't animate itself, only other players." @@ -436,61 +416,55 @@ msgstr "" #: editor/animation_track_editor.cpp msgid "Not possible to add a new track without a root" -msgstr "" +msgstr "Nu este posibil să fie adăugată o nouă pistă fără a avea o rădăcină" #: editor/animation_track_editor.cpp msgid "Invalid track for Bezier (no suitable sub-properties)" -msgstr "" +msgstr "Pistă invalidă pentru Bezier(nicio sub-proprietate corespunzătoare)" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Add Bezier Track" -msgstr "Anim AdăugaÈ›i Pistă" +msgstr "AdăugaÈ›i Pistă Bezier" #: editor/animation_track_editor.cpp msgid "Track path is invalid, so can't add a key." -msgstr "" +msgstr "Calea pistei este invalidă, aÈ™a că nu poate fi adăugată o cheie." #: editor/animation_track_editor.cpp msgid "Track is not of type Spatial, can't insert key" -msgstr "" +msgstr "Pista nu este de tipul Spatial, nu se poate insera cheie" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Add Transform Track Key" -msgstr "Transformare hartă UV" +msgstr "Adăugare Cheie de Tranformare a Pistei" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Add Track Key" msgstr "Anim AdăugaÈ›i Pistă" #: editor/animation_track_editor.cpp msgid "Track path is invalid, so can't add a method key." -msgstr "" +msgstr "Calea pistei este invalidă, aÈ™a că nu poate fi adăugată o metodă." #: editor/animation_track_editor.cpp -#, fuzzy msgid "Add Method Track Key" -msgstr "Anim InseraÈ›i Pistă È™i Cheie" +msgstr "InseraÈ›i Pistă È™i Cheie" #: editor/animation_track_editor.cpp msgid "Method not found in object: " -msgstr "" +msgstr "Metoda nu a fost găsită în obiect: " #: editor/animation_track_editor.cpp msgid "Anim Move Keys" msgstr "Anim MutaÈ›i Cheie" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Clipboard is empty" -msgstr "Clip-board de resurse gol !" +msgstr "Clip-board de resurse gol" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Paste Tracks" -msgstr "LipiÅ£i Parametrii" +msgstr "LipiÅ£i Piste" #: editor/animation_track_editor.cpp msgid "Anim Scale Keys" @@ -500,6 +474,8 @@ msgstr "Anim ScalaÈ›i Cheile" msgid "" "This option does not work for Bezier editing, as it's only a single track." msgstr "" +"Această opÈ›iune nu funcÈ›ionează pentru editarea Bezier, din moment ce e o " +"singură pistă." #: editor/animation_track_editor.cpp msgid "" @@ -516,38 +492,36 @@ msgstr "" #: editor/animation_track_editor.cpp msgid "Warning: Editing imported animation" -msgstr "" +msgstr "Avertisment: Se editează animaÈ›ia încărcată" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Select an AnimationPlayer node to create and edit animations." -msgstr "SelectaÈ›i un Animator din Copacul Scenă să editaÈ›i animaÈ›ii." +msgstr "SelectaÈ›i un nod Animator pentru a crea È™i edita animaÈ›ii." #: editor/animation_track_editor.cpp msgid "Only show tracks from nodes selected in tree." msgstr "" +"Arată numai pistele ce aparÈ›in nodurilor selectate în managerul de file." #: editor/animation_track_editor.cpp msgid "Group tracks by node or display them as plain list." -msgstr "" +msgstr "Grupează pistele în funcÈ›ie de nod sau afiÈ™ează-le ca o listă simplă." #: editor/animation_track_editor.cpp -#, fuzzy msgid "Snap:" -msgstr "Aliniere" +msgstr "Fixare:" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Animation step value." -msgstr "Arborele AnimaÈ›iei este valid." +msgstr "Pasul AnimaÈ›iei." #: editor/animation_track_editor.cpp msgid "Seconds" -msgstr "" +msgstr "Secunde" #: editor/animation_track_editor.cpp msgid "FPS" -msgstr "" +msgstr "FPS(cadre pe secundă)" #: editor/animation_track_editor.cpp editor/editor_properties.cpp #: editor/plugins/polygon_2d_editor_plugin.cpp @@ -560,14 +534,12 @@ msgid "Edit" msgstr "Modificare" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Animation properties." -msgstr "ArboreAnimaÈ›ie" +msgstr "Proprietăți animaÈ›ie." #: editor/animation_track_editor.cpp -#, fuzzy msgid "Copy Tracks" -msgstr "Copie Parametrii" +msgstr "Copiază Piste" #: editor/animation_track_editor.cpp msgid "Scale Selection" @@ -586,17 +558,14 @@ msgid "Duplicate Transposed" msgstr "DuplicaÈ›i Transpunerea" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Delete Selection" -msgstr "Centrează SelecÈ›ia" +msgstr "Șterge SelecÈ›ia" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Go to Next Step" msgstr "MergeÈ›i la Pasul Următor" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Go to Previous Step" msgstr "MergeÈ›i la Pasul Anterior" @@ -610,11 +579,11 @@ msgstr "CurățaÈ›i AnimaÈ›ia" #: editor/animation_track_editor.cpp msgid "Pick the node that will be animated:" -msgstr "" +msgstr "Alege nodul care urmează să fie animat:" #: editor/animation_track_editor.cpp msgid "Use Bezier Curves" -msgstr "" +msgstr "FoloseÈ™te curbe Bezier" #: editor/animation_track_editor.cpp msgid "Anim. Optimizer" @@ -661,9 +630,8 @@ msgid "Scale Ratio:" msgstr "ProporÈ›ie Scalare:" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Select Tracks to Copy" -msgstr "Setează TranziÈ›ii la:" +msgstr "Selectează Pistele de Copiat" #: editor/animation_track_editor.cpp editor/editor_log.cpp #: editor/editor_properties.cpp @@ -672,17 +640,15 @@ msgstr "Setează TranziÈ›ii la:" #: editor/plugins/sprite_frames_editor_plugin.cpp editor/property_editor.cpp #: scene/gui/line_edit.cpp scene/gui/text_edit.cpp msgid "Copy" -msgstr "" +msgstr "Copiază" #: editor/animation_track_editor.cpp -#, fuzzy msgid "Select All/None" -msgstr "Mod Selectare" +msgstr "Selectează Tot/Nimic" #: editor/animation_track_editor_plugins.cpp -#, fuzzy msgid "Add Audio Track Clip" -msgstr "Anim AdăugaÈ›i Pistă" +msgstr "Anim AdăugaÈ›i Pistă Audio" #: editor/animation_track_editor_plugins.cpp msgid "Change Audio Track Clip Start Offset" @@ -718,12 +684,11 @@ msgstr "ÃŽnlocuit %d potriviri." #: editor/code_editor.cpp editor/editor_help.cpp msgid "%d match." -msgstr "" +msgstr "%d potriviri." #: editor/code_editor.cpp editor/editor_help.cpp -#, fuzzy msgid "%d matches." -msgstr "Nici o Potrivire" +msgstr "%d potriviri." #: editor/code_editor.cpp editor/find_in_files.cpp msgid "Match Case" @@ -748,7 +713,7 @@ msgstr "Numai SelecÈ›ia" #: editor/code_editor.cpp editor/plugins/script_text_editor.cpp #: editor/plugins/text_editor.cpp msgid "Standard" -msgstr "" +msgstr "Standard" #: editor/code_editor.cpp editor/plugins/script_editor_plugin.cpp msgid "Toggle Scripts Panel" @@ -772,45 +737,39 @@ msgstr "ResetaÈ›i Zoom-area" #: editor/code_editor.cpp msgid "Warnings" -msgstr "" +msgstr "Avertismente" #: editor/code_editor.cpp msgid "Line and column numbers." -msgstr "" +msgstr "Numerele liniilor È™i coloanelor." #: editor/connections_dialog.cpp -#, fuzzy msgid "Method in target node must be specified." -msgstr "Metoda din Nod-ul È›intă trebuie specificată!" +msgstr "Metoda din nodul È›intă trebuie specificată." #: editor/connections_dialog.cpp -#, fuzzy msgid "" "Target method not found. Specify a valid method or attach a script to the " "target node." msgstr "" "Metoda È›intă nu există! SpecificaÈ›i o metodă validă sau ataÈ™aÈ›i un script la " -"Nod-ul È›intă." +"nodul È›intă." #: editor/connections_dialog.cpp -#, fuzzy msgid "Connect to Node:" msgstr "ConectaÈ›i la Nod:" #: editor/connections_dialog.cpp -#, fuzzy msgid "Connect to Script:" -msgstr "Nu se poate conecta la gazda:" +msgstr "Conectează la Script:" #: editor/connections_dialog.cpp -#, fuzzy msgid "From Signal:" msgstr "Semnale:" #: editor/connections_dialog.cpp -#, fuzzy msgid "Scene does not contain any script." -msgstr "Nodul nu conÈ›ine geometrie." +msgstr "Scena nu conÈ›ine niciun script." #: editor/connections_dialog.cpp editor/editor_autoload_settings.cpp #: editor/groups_editor.cpp editor/plugins/item_list_editor_plugin.cpp @@ -838,14 +797,12 @@ msgid "Extra Call Arguments:" msgstr "Extra Argumente de Chemare:" #: editor/connections_dialog.cpp -#, fuzzy msgid "Receiver Method:" -msgstr "Proprietățile obiectului." +msgstr "Metodă Primitor:" #: editor/connections_dialog.cpp -#, fuzzy msgid "Advanced" -msgstr "OpÈ›iuni Snapping" +msgstr "Avansate" #: editor/connections_dialog.cpp msgid "Deferred" @@ -862,12 +819,11 @@ msgstr "Tragere unică" #: editor/connections_dialog.cpp msgid "Disconnects the signal after its first emission." -msgstr "" +msgstr "Deconectează semnalul după prima emitere." #: editor/connections_dialog.cpp -#, fuzzy msgid "Cannot connect signal" -msgstr "ConectaÈ›i Semnal:" +msgstr "Nu se poate conecta semnalul" #: editor/connections_dialog.cpp editor/dependency_editor.cpp #: editor/export_template_manager.cpp editor/groups_editor.cpp @@ -889,9 +845,8 @@ msgid "Connect" msgstr "ConectaÈ›i" #: editor/connections_dialog.cpp -#, fuzzy msgid "Signal:" -msgstr "Semnale:" +msgstr "Semnal:" #: editor/connections_dialog.cpp msgid "Connect '%s' to '%s'" @@ -902,7 +857,6 @@ msgid "Disconnect '%s' from '%s'" msgstr "DeconectaÈ›i '%s' de la '%s'" #: editor/connections_dialog.cpp -#, fuzzy msgid "Disconnect all from signal: '%s'" msgstr "DeconectaÈ›i '%s' de la '%s'" @@ -916,19 +870,16 @@ msgid "Disconnect" msgstr "DeconectaÈ›i" #: editor/connections_dialog.cpp -#, fuzzy msgid "Connect a Signal to a Method" -msgstr "ConectaÈ›i Semnal:" +msgstr "ConectaÈ›i Semnal la o Metodă" #: editor/connections_dialog.cpp -#, fuzzy msgid "Edit Connection:" -msgstr "Eroare de Conexiune" +msgstr "Modifică Conexiunea:" #: editor/connections_dialog.cpp -#, fuzzy msgid "Are you sure you want to remove all connections from the \"%s\" signal?" -msgstr "EÈ™ti sigur că vrei să execuÈ›i acel proiect?" +msgstr "EÈ™ti sigur că vrei să È™tergi toate conexiunile de la semnalul \"%s\"?" #: editor/connections_dialog.cpp editor/editor_help.cpp editor/node_dock.cpp msgid "Signals" @@ -936,22 +887,19 @@ msgstr "Semnale" #: editor/connections_dialog.cpp msgid "Are you sure you want to remove all connections from this signal?" -msgstr "" +msgstr "EÈ™ti sigur că vrei să È™tergi toate conexiunile de la acest semnal?" #: editor/connections_dialog.cpp -#, fuzzy msgid "Disconnect All" -msgstr "DeconectaÈ›i" +msgstr "DeconectaÈ›i Toate" #: editor/connections_dialog.cpp -#, fuzzy msgid "Edit..." -msgstr "Modificare" +msgstr "Modificare..." #: editor/connections_dialog.cpp -#, fuzzy msgid "Go To Method" -msgstr "Metode" +msgstr "Mergi la Metodă" #: editor/create_dialog.cpp msgid "Change %s Type" @@ -1003,16 +951,14 @@ msgid "Dependencies For:" msgstr "DependenÈ›e Pentru:" #: editor/dependency_editor.cpp -#, fuzzy msgid "" "Scene '%s' is currently being edited.\n" "Changes will only take effect when reloaded." msgstr "" "Scena '%s' este în proces de editare. \n" -"Modificările nu vor avea efect dacă nu reîncărcaÈ›i." +"Modificările vor avea efect doar după reîncărcare." #: editor/dependency_editor.cpp -#, fuzzy msgid "" "Resource '%s' is in use.\n" "Changes will only take effect when reloaded." @@ -1065,9 +1011,8 @@ msgid "Owners Of:" msgstr "Stăpâni La:" #: editor/dependency_editor.cpp -#, fuzzy msgid "Remove selected files from the project? (Can't be restored)" -msgstr "ȘtergeÈ›i fiÈ™ierele selectate din proiect? (fără anulare)" +msgstr "ȘtergeÈ›i fiÈ™ierele selectate din proiect? (AcÈ›iune ireversibilă)" #: editor/dependency_editor.cpp msgid "" @@ -1088,7 +1033,6 @@ msgid "Error loading:" msgstr "Eroare încărcând:" #: editor/dependency_editor.cpp -#, fuzzy msgid "Load failed due to missing dependencies:" msgstr "Scena nu a putut fi încărcata deoarece are dependenÈ›e în lipsa:" @@ -1113,9 +1057,8 @@ msgid "Permanently delete %d item(s)? (No undo!)" msgstr "ȘtergeÈ›i permanent %d articol(e)? (Fără anulare!)" #: editor/dependency_editor.cpp -#, fuzzy msgid "Show Dependencies" -msgstr "DependenÈ›e" +msgstr "Arată DependenÈ›e" #: editor/dependency_editor.cpp msgid "Orphan Resource Explorer" @@ -1206,12 +1149,10 @@ msgid "License" msgstr "Licență" #: editor/editor_about.cpp -#, fuzzy msgid "Third-party Licenses" msgstr "LicenÅ£e Thirdparty" #: editor/editor_about.cpp -#, fuzzy msgid "" "Godot Engine relies on a number of third-party free and open source " "libraries, all compatible with the terms of its MIT license. The following " @@ -1220,8 +1161,8 @@ msgid "" msgstr "" "Motorul Godot se bazează pe un număr de biblioteci thirdparty gratis È™i " "opensource, toate compatibile cu termenii licenÅ£ei MIT ai lui. Mai jos este " -"o listă exhaustivă a tuturor acestor componente de thirdparty cu declaraÅ£ii " -"de autor respective ÅŸi termenii licenÈ›ei." +"o listă exhaustivă a tuturor acestor componente de thirdparty cu " +"declaraÅ£iile de autor respective ÅŸi termenii licenÈ›ei." #: editor/editor_about.cpp msgid "All Components" @@ -1236,14 +1177,12 @@ msgid "Licenses" msgstr "LicenÈ›e" #: editor/editor_asset_installer.cpp editor/project_manager.cpp -#, fuzzy msgid "Error opening package file, not in ZIP format." -msgstr "Eroare la deschiderea fiÅŸierului pachet, nu este în format zip." +msgstr "Eroare la deschiderea fiÅŸierului pachet, nu este în format ZIP." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "AutoLoad '%s' există deja!" +msgstr "%s (Există deja)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1251,17 +1190,15 @@ msgstr "Decomprimare Asset-uri" #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "The following files failed extraction from package:" -msgstr "" +msgstr "Următoarele file au eÈ™uat extragerea din pachet:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d mai multe fiÈ™iere" +msgstr "È™i %d alte fiÈ™iere." #: editor/editor_asset_installer.cpp editor/project_manager.cpp -#, fuzzy msgid "Package installed successfully!" -msgstr "Pachet Instalat cu Succes!" +msgstr "Pachet instalat cu succes!" #: editor/editor_asset_installer.cpp #: editor/plugins/asset_library_editor_plugin.cpp @@ -1269,9 +1206,8 @@ msgid "Success!" msgstr "Succes!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "ConÈ›inut:" +msgstr "ConÈ›inutul pachetului:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1326,7 +1262,6 @@ msgid "Delete Bus Effect" msgstr "ȘtergeÈ›i Pista Efect" #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Drag & drop to rearrange." msgstr "Pista Audio, TrageÈ›i È™i PlasaÈ›i pentru a rearanja." @@ -1401,7 +1336,7 @@ msgstr "Deschide Schema Pistei Audio" #: editor/editor_audio_buses.cpp msgid "There is no '%s' file." -msgstr "" +msgstr "Nu este niciun '%s' în filă." #: editor/editor_audio_buses.cpp editor/plugins/canvas_item_editor_plugin.cpp msgid "Layout" @@ -1412,18 +1347,16 @@ msgid "Invalid file, not an audio bus layout." msgstr "FiÅŸier nevalid, nu este o schemă de pistă audio." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Eroare la salvarea TileSet!" +msgstr "Eroare la salvarea filei: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" msgstr "AdaugaÈ›i Pistă Audio" #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Add a new Audio Bus to this layout." -msgstr "SalvaÈ›i Schema Pistei Audio Ca..." +msgstr "AdăgaÈ›i un nou Audio Bus acestei aÈ™ezări." #: editor/editor_audio_buses.cpp editor/editor_properties.cpp #: editor/plugins/animation_player_editor_plugin.cpp editor/property_editor.cpp @@ -1464,24 +1397,20 @@ msgid "Valid characters:" msgstr "Caractere valide:" #: editor/editor_autoload_settings.cpp -#, fuzzy msgid "Must not collide with an existing engine class name." msgstr "" -"Nume nevalid. Nu trebuie să se lovească cu un nume de clasa deja existent în " -"motor." +"Nume nevalid. Nu trebuie să se lovească cu un nume de clasa deja existent." #: editor/editor_autoload_settings.cpp -#, fuzzy msgid "Must not collide with an existing built-in type name." msgstr "" -"Nume nevalid. Nu trebuie să se lovească cu un nume de tip deja existent în " -"motor tip." +"Nume nevalid. Nu trebuie să se lovească cu un nume de tip rezervat al " +"motorului." #: editor/editor_autoload_settings.cpp -#, fuzzy msgid "Must not collide with an existing global constant name." msgstr "" -"Nume nevalid. Nu trebuie să se lovească cu un nume ce constante globale." +"Nume nevalid. Nu trebuie să se lovească cu un nume de constantă globală." #: editor/editor_autoload_settings.cpp msgid "Keyword cannot be used as an autoload name." @@ -1516,7 +1445,6 @@ msgid "Rearrange Autoloads" msgstr "RearanjaÈ›i Autoload-urile" #: editor/editor_autoload_settings.cpp editor/script_create_dialog.cpp -#, fuzzy msgid "Invalid path." msgstr "Cale nevalidă." @@ -1574,9 +1502,8 @@ msgid "[unsaved]" msgstr "[nesalvat]" #: editor/editor_dir_dialog.cpp -#, fuzzy msgid "Please select a base directory first." -msgstr "Vă rugăm să selectaÅ£i mai întâi un director de baza" +msgstr "Vă rugăm să selectaÅ£i mai întâi un director de bază." #: editor/editor_dir_dialog.cpp msgid "Choose a Directory" @@ -1639,9 +1566,8 @@ msgstr "" #: editor/editor_export.cpp platform/android/export/export.cpp #: platform/iphone/export/export.cpp platform/javascript/export/export.cpp #: platform/osx/export/export.cpp platform/uwp/export/export.cpp -#, fuzzy msgid "Custom debug template not found." -msgstr "FiÈ™ierul È™ablon nu a fost găsit:" +msgstr "FiÈ™ierul È™ablon de depanare personalizat nu a fost găsit." #: editor/editor_export.cpp platform/android/export/export.cpp #: platform/iphone/export/export.cpp platform/javascript/export/export.cpp @@ -1658,91 +1584,76 @@ msgid "On 32-bit exports the embedded PCK cannot be bigger than 4 GiB." msgstr "" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "3D Editor" -msgstr "Editor" +msgstr "Editor 3D" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Script Editor" -msgstr "Deschide Editorul de Scripturi" +msgstr "Editorul de Scripturi" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Asset Library" -msgstr "Deschide Librăria de Asseturi" +msgstr "Librăria de Resurse" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Scene Tree Editing" -msgstr "Setările de ExecuÈ›ie ale Scenei" +msgstr "Editează Arborele Scenei" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Import Dock" -msgstr "Importă" +msgstr "Importă Bară" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Node Dock" -msgstr "Mod Mutare" +msgstr "Nod Bară" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "FileSystem and Import Docks" -msgstr "Sistemul De FiÈ™iere" +msgstr "Sistemul De FiÈ™iere È™i încărcare Bare" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Erase profile '%s'? (no undo)" -msgstr "ÃŽnlocuiÈ›i Tot" +msgstr "ȘtergeÈ›i profilul '%s'?(ireversibil)" #: editor/editor_feature_profile.cpp msgid "Profile must be a valid filename and must not contain '.'" msgstr "" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Profile with this name already exists." -msgstr "Un fiÈ™ier sau un director cu acest nume există deja." +msgstr "Un profil cu acest nume există deja." #: editor/editor_feature_profile.cpp msgid "(Editor Disabled, Properties Disabled)" msgstr "" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "(Properties Disabled)" -msgstr "Proprietăți" +msgstr "(Proprietăți Dezactivate)" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "(Editor Disabled)" -msgstr "Dezactivat" +msgstr "(Editor Dezactivat)" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Class Options:" -msgstr "Descriere:" +msgstr "OpÈ›iuni Clasă:" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Enable Contextual Editor" -msgstr "Deschide Editorul următor" +msgstr "Activează Editorul Contextual" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Enabled Properties:" -msgstr "Proprietăți" +msgstr "Proprietăți Activate:" #: editor/editor_feature_profile.cpp msgid "Enabled Features:" msgstr "" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Enabled Classes:" -msgstr "Căutare Clase" +msgstr "Clase Activate:" #: editor/editor_feature_profile.cpp msgid "File '%s' format is invalid, import aborted." @@ -1755,23 +1666,20 @@ msgid "" msgstr "" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Error saving profile to path: '%s'." -msgstr "Eroare la salvarea TileSet!" +msgstr "Eroare la salvarea profilului la calea: '%s'." #: editor/editor_feature_profile.cpp msgid "Unset" msgstr "" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Current Profile:" -msgstr "Versiune Curentă:" +msgstr "Profil Curent:" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Make Current" -msgstr "Curent:" +msgstr "FaceÈ›i Curent" #: editor/editor_feature_profile.cpp #: editor/plugins/animation_player_editor_plugin.cpp @@ -1789,44 +1697,36 @@ msgid "Export" msgstr "Exportare" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Available Profiles:" -msgstr "Proprietăți" +msgstr "Profile Disponibile:" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Class Options" -msgstr "Descriere" +msgstr "OpÈ›iuni Clase" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "New profile name:" -msgstr "Nume nou:" +msgstr "Nume de profil nou:" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Erase Profile" -msgstr "RMB: Șterge Punctul." +msgstr "Ștergere Profil" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Godot Feature Profile" msgstr "Administrează Șabloanele de Export" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Import Profile(s)" -msgstr "%d mai multe fiÈ™iere" +msgstr "ÃŽncarcă Profil(e)" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Export Profile" -msgstr "Exportă Proiectul" +msgstr "Exportă Profil" #: editor/editor_feature_profile.cpp -#, fuzzy msgid "Manage Editor Feature Profiles" -msgstr "Administrează Șabloanele de Export" +msgstr "Administrează Profilele Ferestrei de Editare" #: editor/editor_file_dialog.cpp scene/gui/file_dialog.cpp msgid "Select Current Folder" @@ -1837,7 +1737,6 @@ msgid "File Exists, Overwrite?" msgstr "FiÈ™ierul există, suprascrieÅ£i?" #: editor/editor_file_dialog.cpp scene/gui/file_dialog.cpp -#, fuzzy msgid "Select This Folder" msgstr "SelectaÅ£i directorul curent" @@ -1846,13 +1745,11 @@ msgid "Copy Path" msgstr "CopiaÅ£i Calea" #: editor/editor_file_dialog.cpp editor/filesystem_dock.cpp -#, fuzzy msgid "Open in File Manager" -msgstr "ArătaÈ›i în Administratorul de FiÈ™iere" +msgstr "DeschideÈ›i în Administratorul de FiÈ™iere" #: editor/editor_file_dialog.cpp editor/editor_node.cpp #: editor/filesystem_dock.cpp editor/project_manager.cpp -#, fuzzy msgid "Show in File Manager" msgstr "ArătaÈ›i în Administratorul de FiÈ™iere" @@ -1937,44 +1834,36 @@ msgid "Move Favorite Down" msgstr "DeplasaÈ›i Favorit Jos" #: editor/editor_file_dialog.cpp -#, fuzzy msgid "Go to previous folder." -msgstr "AccesaÈ›i Directorul Părinte" +msgstr "AccesaÈ›i Directorul Precedent." #: editor/editor_file_dialog.cpp -#, fuzzy msgid "Go to next folder." -msgstr "AccesaÈ›i Directorul Părinte" +msgstr "Mergi la următorul director." #: editor/editor_file_dialog.cpp scene/gui/file_dialog.cpp -#, fuzzy msgid "Go to parent folder." -msgstr "AccesaÈ›i Directorul Părinte" +msgstr "Mergi la Directorul Părinte." #: editor/editor_file_dialog.cpp scene/gui/file_dialog.cpp -#, fuzzy msgid "Refresh files." -msgstr "Căutare Clase" +msgstr "Reîmprospătează filele." #: editor/editor_file_dialog.cpp -#, fuzzy msgid "(Un)favorite current folder." -msgstr "Directorul nu a putut fi creat." +msgstr "(Șterge)Adaugă directorul curent la favorite." #: editor/editor_file_dialog.cpp scene/gui/file_dialog.cpp -#, fuzzy msgid "Toggle the visibility of hidden files." -msgstr "ComutaÈ›i FiÈ™iere Ascunse" +msgstr "ComutaÈ›i Vizibilitatea FiÈ™ierelor Ascunse." #: editor/editor_file_dialog.cpp editor/filesystem_dock.cpp -#, fuzzy msgid "View items as a grid of thumbnails." -msgstr "Vizualizează articolele ca È™i o grilă de miniaturi" +msgstr "Vizualizează articolele ca o grilă de miniaturi." #: editor/editor_file_dialog.cpp editor/filesystem_dock.cpp -#, fuzzy msgid "View items as a list." -msgstr "Vizualizează articolele ca È™i o listă" +msgstr "Vizualizează articolele sub forma unei liste." #: editor/editor_file_dialog.cpp scene/gui/file_dialog.cpp msgid "Directories & Files:" @@ -2026,59 +1915,48 @@ msgid "Inherited by:" msgstr "MoÅŸtenit de:" #: editor/editor_help.cpp -#, fuzzy -msgid "Brief Description" -msgstr "Descriere Scurtă:" +msgid "Description" +msgstr "Descriere" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Tutoriale Online" #: editor/editor_help.cpp msgid "Properties" msgstr "Proprietăți" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "implicit:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metode" #: editor/editor_help.cpp -#, fuzzy msgid "Theme Properties" -msgstr "Proprietăți" +msgstr "Proprietățile Temei" #: editor/editor_help.cpp msgid "Enumerations" msgstr "Enumerări" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Constante" #: editor/editor_help.cpp -#, fuzzy -msgid "Class Description" -msgstr "Descriere" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "Tutoriale Internet:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Nu există în prezent nici un tutorial pentru această clasă, puteÅ£i [culoare " -"= $color] [url = $url] contribui unul [/ URL] [/ color] sau [culoare = " -"$color] [url = $url2] cerere unul[/ URL] [/ color]." +msgid "Property Descriptions" +msgstr "Descriere Proprietate" #: editor/editor_help.cpp -#, fuzzy -msgid "Property Descriptions" -msgstr "Descriere Proprietate:" +msgid "(value)" +msgstr "(valoare)" #: editor/editor_help.cpp msgid "" @@ -2090,9 +1968,8 @@ msgstr "" "color]!" #: editor/editor_help.cpp -#, fuzzy msgid "Method Descriptions" -msgstr "Descrierea metodei:" +msgstr "Descrierile Metodei" #: editor/editor_help.cpp msgid "" @@ -2108,83 +1985,68 @@ msgid "Search Help" msgstr "CăutaÈ›i în Ajutor" #: editor/editor_help_search.cpp -#, fuzzy msgid "Case Sensitive" -msgstr "ÃŽnchide Scena" +msgstr "Sensibil la Majuscule" #: editor/editor_help_search.cpp -#, fuzzy msgid "Show Hierarchy" -msgstr "Arată AsistenÈ›ii" +msgstr "Arată Ierarhie" #: editor/editor_help_search.cpp -#, fuzzy msgid "Display All" -msgstr "ÃŽnlocuiÈ›i Tot" +msgstr "AfiÈ™ează Tot" #: editor/editor_help_search.cpp -#, fuzzy msgid "Classes Only" -msgstr "Clase" +msgstr "Doar Clase" #: editor/editor_help_search.cpp -#, fuzzy msgid "Methods Only" -msgstr "Metode" +msgstr "Doar Metode" #: editor/editor_help_search.cpp -#, fuzzy msgid "Signals Only" -msgstr "Semnale" +msgstr "Doar Semnale" #: editor/editor_help_search.cpp -#, fuzzy msgid "Constants Only" -msgstr "Constante" +msgstr "Doar Constante" #: editor/editor_help_search.cpp -#, fuzzy msgid "Properties Only" -msgstr "Proprietăți" +msgstr "Doar Proprietăți" #: editor/editor_help_search.cpp -#, fuzzy msgid "Theme Properties Only" -msgstr "Proprietăți" +msgstr "Doar Proprietăți ale Temei" #: editor/editor_help_search.cpp -#, fuzzy msgid "Member Type" -msgstr "Membri" +msgstr "Tip Membru" #: editor/editor_help_search.cpp -#, fuzzy msgid "Class" -msgstr "Clasă:" +msgstr "Clasă" #: editor/editor_help_search.cpp -#, fuzzy msgid "Method" -msgstr "Metode" +msgstr "Metodă" #: editor/editor_help_search.cpp editor/plugins/script_text_editor.cpp -#, fuzzy msgid "Signal" -msgstr "Semnale" +msgstr "Semnal" #: editor/editor_help_search.cpp editor/plugins/theme_editor_plugin.cpp msgid "Constant" msgstr "Permanent" #: editor/editor_help_search.cpp -#, fuzzy msgid "Property" -msgstr "Proprietăți" +msgstr "Proprietate" #: editor/editor_help_search.cpp -#, fuzzy msgid "Theme Property" -msgstr "Proprietăți" +msgstr "Proprietate Temă" #: editor/editor_inspector.cpp editor/project_settings_editor.cpp msgid "Property:" @@ -2203,9 +2065,8 @@ msgid "Output:" msgstr "AfiÈ™are:" #: editor/editor_log.cpp editor/plugins/tile_map_editor_plugin.cpp -#, fuzzy msgid "Copy Selection" -msgstr "ElminaÈ›i SelecÈ›ia" +msgstr "Copiază SelecÈ›ia" #: editor/editor_log.cpp editor/editor_network_profiler.cpp #: editor/editor_profiler.cpp editor/editor_properties.cpp @@ -2228,16 +2089,14 @@ msgstr "OpreÈ™te" #: editor/editor_network_profiler.cpp editor/editor_profiler.cpp #: editor/plugins/animation_state_machine_editor.cpp editor/rename_dialog.cpp -#, fuzzy msgid "Start" -msgstr "Start!" +msgstr "Start" #: editor/editor_network_profiler.cpp msgid "%s/s" msgstr "" #: editor/editor_network_profiler.cpp -#, fuzzy msgid "Down" msgstr "Descarcă" @@ -4603,9 +4462,8 @@ msgid "Audio Clips" msgstr "Anim AdăugaÈ›i Pistă" #: editor/plugins/animation_blend_tree_editor_plugin.cpp -#, fuzzy msgid "Functions" -msgstr "FaceÈ›i FuncÈ›ia" +msgstr "FuncÈ›ii" #: editor/plugins/animation_blend_tree_editor_plugin.cpp #: editor/plugins/animation_state_machine_editor.cpp @@ -4742,7 +4600,6 @@ msgid "Animation Tools" msgstr "Unelte AnimaÈ›ie" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "AnimaÈ›ie" @@ -5881,6 +5738,11 @@ msgid "Auto Insert Key" msgstr "Anim InseraÈ›i Cheie" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Lungime AnimaÈ›ie (în secunde)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Inserează Notă (Melodii existente)" @@ -6179,7 +6041,6 @@ msgid "No mesh to debug." msgstr "Niciun mesh de depanat." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Modelul nu are UV în acest strat" @@ -6570,7 +6431,7 @@ msgstr "Setare poziÈ›ie punct de curbă" #: editor/plugins/path_editor_plugin.cpp msgid "Set Curve In Position" -msgstr "Setare poziÈ›ie de intrare a curbei" +msgstr "Setare Curbă ÃŽn PoziÈ›ie" #: editor/plugins/path_editor_plugin.cpp msgid "Set Curve Out Position" @@ -7416,7 +7277,6 @@ msgid "Create physical bones" msgstr "Creează un Mesh de Navigare" #: editor/plugins/skeleton_editor_plugin.cpp -#, fuzzy msgid "Skeleton" msgstr "Singleton (Unicat)" @@ -7625,6 +7485,10 @@ msgid "Cinematic Preview" msgstr "Se creează Previzualizările Mesh-ului" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -8863,9 +8727,8 @@ msgid "Scalar" msgstr "Dimensiune:" #: editor/plugins/visual_shader_editor_plugin.cpp -#, fuzzy msgid "Vector" -msgstr "Inspector" +msgstr "Vector" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Boolean" @@ -10423,9 +10286,8 @@ msgid "Action:" msgstr "" #: editor/project_settings_editor.cpp -#, fuzzy msgid "Action" -msgstr "AcÈ›iune de Mutare" +msgstr "AcÈ›iune" #: editor/project_settings_editor.cpp msgid "Deadzone" @@ -11268,9 +11130,8 @@ msgid "Profiler" msgstr "" #: editor/script_editor_debugger.cpp -#, fuzzy msgid "Network Profiler" -msgstr "Exportă Proiectul" +msgstr "Analizator Network" #: editor/script_editor_debugger.cpp msgid "Monitor" @@ -12865,6 +12726,26 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Nu există în prezent nici un tutorial pentru această clasă, puteÅ£i " +#~ "[culoare = $color] [url = $url] contribui unul [/ URL] [/ color] sau " +#~ "[culoare = $color] [url = $url2] cerere unul[/ URL] [/ color]." + +#~ msgid "enum " +#~ msgstr "enum " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Descriere Scurtă:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "Descriere" + #~ msgid "Project export failed with error code %d." #~ msgstr "Exportul de proiect nu a reuÅŸit cu un cod de eroare %d." diff --git a/editor/translations/ru.po b/editor/translations/ru.po index 67e54e0a3b..9c56393ae8 100644 --- a/editor/translations/ru.po +++ b/editor/translations/ru.po @@ -56,17 +56,18 @@ # КонÑтантин Рин <email.to.rean@gmail.com>, 2019. # Maxim Samburskiy <alpacones@outlook.com>, 2019. # Dima Koshel <form.eater@gmail.com>, 2019. -# Danil Alexeev <danil@alexeev.xyz>, 2019. +# Danil Alexeev <danil@alexeev.xyz>, 2019, 2020. # Ravager <al.porkhunov@gmail.com>, 2019. # ÐлекÑандр <akonn7@mail.ru>, 2019. # Rei <clxgamer12@gmail.com>, 2019. # Vitaly <arkology11@gmail.com>, 2019. +# Andy <8ofproject@gmail.com>, 2020. msgid "" msgstr "" "Project-Id-Version: Godot Engine editor\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" -"Last-Translator: Vladislav <onion.ring@mail.ru>\n" +"PO-Revision-Date: 2020-01-27 07:10+0000\n" +"Last-Translator: Danil Alexeev <danil@alexeev.xyz>\n" "Language-Team: Russian <https://hosted.weblate.org/projects/godot-engine/" "godot/ru/>\n" "Language: ru\n" @@ -75,7 +76,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -187,7 +188,7 @@ msgstr "Добавить точку Безье" #: editor/animation_bezier_editor.cpp msgid "Move Bezier Points" -msgstr "Передвинуть Точку Безье" +msgstr "Передвинуть точки Безье" #: editor/animation_bezier_editor.cpp editor/animation_track_editor.cpp msgid "Anim Duplicate Keys" @@ -222,14 +223,17 @@ msgid "Anim Multi Change Keyframe Time" msgstr "Ð’Ñ€ÐµÐ¼Ñ Ñмены ключевых кадров анимации" #: editor/animation_track_editor.cpp +#, fuzzy msgid "Anim Multi Change Transition" msgstr "ÐÐ½Ð¸Ð¼Ð°Ñ†Ð¸Ñ ÐœÐ½Ð¾Ð³Ð¾ÐºÑ€Ð°Ñ‚Ð½Ð¾Ðµ изменение Переход" #: editor/animation_track_editor.cpp +#, fuzzy msgid "Anim Multi Change Transform" msgstr "Ðнимационное многоÑменное преобразование" #: editor/animation_track_editor.cpp +#, fuzzy msgid "Anim Multi Change Keyframe Value" msgstr "ÐÐ½Ð¸Ð¼Ð°Ñ†Ð¸Ñ Ð¼Ð½Ð¾Ð³Ð¾ÐºÑ€Ð°Ñ‚Ð½Ð¾Ðµ изменение ключевых кадров Значение" @@ -244,31 +248,31 @@ msgstr "Изменить длину анимации" #: editor/animation_track_editor.cpp #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "Change Animation Loop" -msgstr "Изменить цикличноÑÑ‚ÑŒ анимации" +msgstr "Изменить цикл анимации" #: editor/animation_track_editor.cpp msgid "Property Track" -msgstr "Трек Параметра" +msgstr "Трек параметра" #: editor/animation_track_editor.cpp msgid "3D Transform Track" -msgstr "Трек 3D ПреобразованиÑ" +msgstr "Трек 3D преобразованиÑ" #: editor/animation_track_editor.cpp msgid "Call Method Track" -msgstr "Трек Вызова Метода" +msgstr "Трек вызова метода" #: editor/animation_track_editor.cpp msgid "Bezier Curve Track" -msgstr "Трек Кривой Безье" +msgstr "Трек кривой Безье" #: editor/animation_track_editor.cpp msgid "Audio Playback Track" -msgstr "Трек Ðудио Дорожки" +msgstr "Трек аудио дорожки" #: editor/animation_track_editor.cpp msgid "Animation Playback Track" -msgstr "Трек ВоÑÐ¿Ñ€Ð¾Ð¸Ð·Ð²ÐµÐ´ÐµÐ½Ð¸Ñ Ðнимации" +msgstr "Трек воÑÐ¿Ñ€Ð¾Ð¸Ð·Ð²ÐµÐ´ÐµÐ½Ð¸Ñ Ð°Ð½Ð¸Ð¼Ð°Ñ†Ð¸Ð¸" #: editor/animation_track_editor.cpp msgid "Animation length (frames)" @@ -280,7 +284,7 @@ msgstr "ПродолжительноÑÑ‚ÑŒ анимации (в Ñекундах #: editor/animation_track_editor.cpp msgid "Add Track" -msgstr "Добавить новый Трек" +msgstr "Добавить новый трек" #: editor/animation_track_editor.cpp msgid "Animation Looping" @@ -297,7 +301,7 @@ msgstr "Ðудиодорожки:" #: editor/animation_track_editor.cpp msgid "Anim Clips:" -msgstr "Дорожки Ðнимации:" +msgstr "Дорожки анимации:" #: editor/animation_track_editor.cpp msgid "Change Track Path" @@ -392,7 +396,7 @@ msgstr "Изменить метод интерполÑции анимации" #: editor/animation_track_editor.cpp msgid "Change Animation Loop Mode" -msgstr "Изменить Режим Цикла Ðнимации" +msgstr "Изменить режим цикла анимации" #: editor/animation_track_editor.cpp msgid "Remove Anim Track" @@ -428,11 +432,11 @@ msgstr "AnimationPlayer не может анимировать Ñам ÑебÑ, #: editor/animation_track_editor.cpp msgid "Anim Create & Insert" -msgstr "Создать и Ð’Ñтавить" +msgstr "Создать и вÑтавить" #: editor/animation_track_editor.cpp msgid "Anim Insert Track & Key" -msgstr "Ð’Ñтавить Дорожку и Ключ" +msgstr "Ð’Ñтавить дорожку и ключ" #: editor/animation_track_editor.cpp msgid "Anim Insert Key" @@ -440,11 +444,11 @@ msgstr "Ð’Ñтавить ключ" #: editor/animation_track_editor.cpp msgid "Change Animation Step" -msgstr "Изменить Шаг Ðнимации" +msgstr "Изменить шаг анимации" #: editor/animation_track_editor.cpp msgid "Rearrange Tracks" -msgstr "ПереÑтавить Дорожки" +msgstr "ПереÑтавить дорожки" #: editor/animation_track_editor.cpp msgid "Transform tracks only apply to Spatial-based nodes." @@ -481,7 +485,7 @@ msgstr "Ðеверный трек Ð´Ð»Ñ ÐºÑ€Ð¸Ð²Ð¾Ð¹ Безье (нет Ð¿Ð¾Ð´Ñ #: editor/animation_track_editor.cpp msgid "Add Bezier Track" -msgstr "Добавить Дорожку Безье" +msgstr "Добавить дорожку Безье" #: editor/animation_track_editor.cpp msgid "Track path is invalid, so can't add a key." @@ -493,11 +497,11 @@ msgstr "Трек не имеет тип Spatial, Ð½ÐµÐ»ÑŒÐ·Ñ Ð´Ð¾Ð±Ð°Ð²Ð¸Ñ‚ÑŒ Ð #: editor/animation_track_editor.cpp msgid "Add Transform Track Key" -msgstr "Добавить Ключ ОтÑÐ»ÐµÐ¶Ð¸Ð²Ð°Ð½Ð¸Ñ Ð¢Ñ€Ð°Ð½Ñформации" +msgstr "Добавить ключ дорожки преобразованиÑ" #: editor/animation_track_editor.cpp msgid "Add Track Key" -msgstr "Добавить Ключ Дорожки" +msgstr "Добавить ключ дорожки" #: editor/animation_track_editor.cpp msgid "Track path is invalid, so can't add a method key." @@ -521,7 +525,7 @@ msgstr "Буфер обмена пуÑÑ‚" #: editor/animation_track_editor.cpp msgid "Paste Tracks" -msgstr "Ð’Ñтавить Треки" +msgstr "Ð’Ñтавить треки" #: editor/animation_track_editor.cpp msgid "Anim Scale Keys" @@ -605,7 +609,7 @@ msgstr "СвойÑтва анимации." #: editor/animation_track_editor.cpp msgid "Copy Tracks" -msgstr "Копировать Треки" +msgstr "Копировать треки" #: editor/animation_track_editor.cpp msgid "Scale Selection" @@ -718,15 +722,15 @@ msgstr "Добавить звуковую дорожку" #: editor/animation_track_editor_plugins.cpp msgid "Change Audio Track Clip Start Offset" -msgstr "Изменение Ðачального Сдвига Ðудио Дорожки" +msgstr "Изменение начального Ñдвига аудио дорожки" #: editor/animation_track_editor_plugins.cpp msgid "Change Audio Track Clip End Offset" -msgstr "Изменение Конечного Сдвига Ðудио Дорожки" +msgstr "Изменение конечного Ñдвига аудио дорожки" #: editor/array_property_edit.cpp msgid "Resize Array" -msgstr "Изменить размер МаÑÑива" +msgstr "Изменить размер маÑÑива" #: editor/array_property_edit.cpp msgid "Change Array Value Type" @@ -823,7 +827,7 @@ msgstr "" #: editor/connections_dialog.cpp msgid "Connect to Node:" -msgstr "ПриÑоединить к Узлу:" +msgstr "ПриÑоединить к узлу:" #: editor/connections_dialog.cpp msgid "Connect to Script:" @@ -863,9 +867,8 @@ msgid "Extra Call Arguments:" msgstr "Дополнительные параметры вызова:" #: editor/connections_dialog.cpp -#, fuzzy msgid "Receiver Method:" -msgstr "Выбрать метод" +msgstr "Метод-приёмник:" #: editor/connections_dialog.cpp msgid "Advanced" @@ -915,7 +918,7 @@ msgstr "ПриÑоединить" #: editor/connections_dialog.cpp msgid "Signal:" -msgstr "Сигналы:" +msgstr "Сигнал:" #: editor/connections_dialog.cpp msgid "Connect '%s' to '%s'" @@ -940,11 +943,11 @@ msgstr "ОтÑоединить" #: editor/connections_dialog.cpp msgid "Connect a Signal to a Method" -msgstr "Подключить Сигнал к Методу" +msgstr "Подключить Ñигнал к методу" #: editor/connections_dialog.cpp msgid "Edit Connection:" -msgstr "Редактировать Подключение:" +msgstr "Редактировать подключение:" #: editor/connections_dialog.cpp msgid "Are you sure you want to remove all connections from the \"%s\" signal?" @@ -964,11 +967,11 @@ msgstr "ОтÑоединить вÑе" #: editor/connections_dialog.cpp msgid "Edit..." -msgstr "Редактирование..." +msgstr "Редактировать..." #: editor/connections_dialog.cpp msgid "Go To Method" -msgstr "Перейти к Методу" +msgstr "Перейти к методу" #: editor/create_dialog.cpp msgid "Change %s Type" @@ -1162,7 +1165,7 @@ msgstr "СпаÑибо от ÑообщеÑтва Godot!" #: editor/editor_about.cpp msgid "Godot Engine contributors" -msgstr "Ðвторы Движка Godot" +msgstr "Ðвторы Godot Engine" #: editor/editor_about.cpp msgid "Project Founders" @@ -1170,7 +1173,7 @@ msgstr "ОÑнователи Проекта" #: editor/editor_about.cpp msgid "Lead Developer" -msgstr "Ведущий Разработчик" +msgstr "Ведущий разработчик" #: editor/editor_about.cpp msgid "Project Manager " @@ -1186,27 +1189,27 @@ msgstr "Ðвторы" #: editor/editor_about.cpp msgid "Platinum Sponsors" -msgstr "Платиновые СпонÑоры" +msgstr "Платиновые ÑпонÑоры" #: editor/editor_about.cpp msgid "Gold Sponsors" -msgstr "Золотые СпонÑоры" +msgstr "Золотые ÑпонÑоры" #: editor/editor_about.cpp msgid "Mini Sponsors" -msgstr "Мини СпонÑоры" +msgstr "Мини ÑпонÑоры" #: editor/editor_about.cpp msgid "Gold Donors" -msgstr "Золотые Доноры" +msgstr "Золотые доноры" #: editor/editor_about.cpp msgid "Silver Donors" -msgstr "СеребрÑные Доноры" +msgstr "СеребрÑные доноры" #: editor/editor_about.cpp msgid "Bronze Donors" -msgstr "Бронзовые Доноры" +msgstr "Бронзовые доноры" #: editor/editor_about.cpp msgid "Donors" @@ -1249,9 +1252,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Ошибка при открытии файла пакета, не в формате zip." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Уже ÑущеÑтвует" +msgstr "%s (Уже ÑущеÑтвует)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1262,9 +1264,8 @@ msgid "The following files failed extraction from package:" msgstr "Следующие файлы не удалоÑÑŒ извлечь из пакета:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "Ещё %d файла(ов)" +msgstr "Ещё %d файла(ов)." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1276,9 +1277,8 @@ msgid "Success!" msgstr "УÑпех!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "Содержание:" +msgstr "Содержимое пакета:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1418,9 +1418,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "ÐедопуÑтимый файл, не раÑкладка аудио шины." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Ошибка при Ñохранении файла!" +msgstr "Ошибка при Ñохранении файла: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1537,7 +1536,7 @@ msgstr "Путь:" #: editor/editor_autoload_settings.cpp msgid "Node Name:" -msgstr "Ð˜Ð¼Ñ Ð£Ð·Ð»Ð°:" +msgstr "Ð˜Ð¼Ñ ÑƒÐ·Ð»Ð°:" #: editor/editor_autoload_settings.cpp editor/editor_help_search.cpp #: editor/editor_profiler.cpp editor/project_manager.cpp @@ -1894,7 +1893,7 @@ msgstr "Скрыть файлы" #: editor/editor_file_dialog.cpp msgid "Toggle Favorite" -msgstr "Переключить Избранное" +msgstr "Переключить избранное" #: editor/editor_file_dialog.cpp msgid "Toggle Mode" @@ -1996,14 +1995,28 @@ msgid "Inherited by:" msgstr "УнаÑледован:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Краткое опиÑание" +msgid "Description" +msgstr "ОпиÑание" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Онлайн-уроки" #: editor/editor_help.cpp msgid "Properties" msgstr "СвойÑтва" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "Переопределить" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "По умолчанию" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Методы" @@ -2016,36 +2029,19 @@ msgid "Enumerations" msgstr "ПеречиÑлениÑ" #: editor/editor_help.cpp -msgid "enum " -msgstr "перечиÑление " - -#: editor/editor_help.cpp msgid "Constants" msgstr "КонÑтанты" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "ОпиÑание клаÑÑа" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Онлайн-уроки" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Ð’ наÑтоÑщее Ð²Ñ€ÐµÐ¼Ñ Ð¾Ñ‚ÑутÑтвуют учебники Ð´Ð»Ñ Ñтого клаÑÑа, вы можете его " -"[color=$color][url=$url]добавить[/url][/color] или [color=$color][url=" -"$url2]запроÑить[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "ОпиÑание ÑвойÑтв" #: editor/editor_help.cpp +#, fuzzy +msgid "(value)" +msgstr "Значение" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -2075,9 +2071,8 @@ msgid "Case Sensitive" msgstr "ЧувÑтвительноÑÑ‚ÑŒ региÑтра" #: editor/editor_help_search.cpp -#, fuzzy msgid "Show Hierarchy" -msgstr "Показывать помощники" +msgstr "Показывать иерархию" #: editor/editor_help_search.cpp msgid "Display All" @@ -2116,9 +2111,8 @@ msgid "Class" msgstr "КлаÑÑ" #: editor/editor_help_search.cpp -#, fuzzy msgid "Method" -msgstr "Методы" +msgstr "Метод" #: editor/editor_help_search.cpp editor/plugins/script_text_editor.cpp msgid "Signal" @@ -2129,14 +2123,12 @@ msgid "Constant" msgstr "КонÑтанта" #: editor/editor_help_search.cpp -#, fuzzy msgid "Property" -msgstr "Параметр:" +msgstr "Параметр" #: editor/editor_help_search.cpp -#, fuzzy msgid "Theme Property" -msgstr "СвойÑтва темы" +msgstr "СвойÑтво темы" #: editor/editor_inspector.cpp editor/project_settings_editor.cpp msgid "Property:" @@ -2148,7 +2140,7 @@ msgstr "Задать" #: editor/editor_inspector.cpp msgid "Set Multiple:" -msgstr "УÑтановить МножеÑтво:" +msgstr "Задать неÑколько:" #: editor/editor_log.cpp msgid "Output:" @@ -2225,7 +2217,7 @@ msgstr "Импортированные реÑурÑÑ‹ не могут быть Ñ #: editor/editor_node.cpp editor/plugins/script_editor_plugin.cpp #: scene/gui/dialogs.cpp msgid "OK" -msgstr "Ок" +msgstr "OK" #: editor/editor_node.cpp editor/plugins/animation_player_editor_plugin.cpp msgid "Error saving resource!" @@ -2986,7 +2978,7 @@ msgstr "ПоиÑк" #: editor/editor_node.cpp editor/plugins/script_editor_plugin.cpp #: editor/plugins/shader_editor_plugin.cpp msgid "Online Docs" -msgstr "Онлайн ДокументациÑ" +msgstr "Онлайн документациÑ" #: editor/editor_node.cpp msgid "Q&A" @@ -3147,7 +3139,7 @@ msgstr "Открыть и запуÑтить Ñкрипт" #: editor/editor_node.cpp msgid "New Inherited" -msgstr "ÐÐ¾Ð²Ð°Ñ ÑƒÐ½Ð°ÑÐ»ÐµÐ´Ð¾Ð²Ð°Ð½Ð½Ð°Ñ Ð¡Ñ†ÐµÐ½Ð°" +msgstr "ÐÐ¾Ð²Ð°Ñ ÑƒÐ½Ð°ÑÐ»ÐµÐ´Ð¾Ð²Ð°Ð½Ð½Ð°Ñ Ñцена" #: editor/editor_node.cpp msgid "Load Errors" @@ -3182,9 +3174,8 @@ msgid "Open the previous Editor" msgstr "Открыть предыдущий редактор" #: editor/editor_node.h -#, fuzzy msgid "Warning!" -msgstr "Предупреждение" +msgstr "Внимание!" #: editor/editor_path.cpp msgid "No sub-resources found." @@ -3428,7 +3419,7 @@ msgstr "Быть может вы забыли метод _run()?" #: editor/editor_sub_scene.cpp msgid "Select Node(s) to Import" -msgstr "Выберите Узел(узлы) Ð´Ð»Ñ Ð¸Ð¼Ð¿Ð¾Ñ€Ñ‚Ð°" +msgstr "Выберите узлы Ð´Ð»Ñ Ð¸Ð¼Ð¿Ð¾Ñ€Ñ‚Ð°" #: editor/editor_sub_scene.cpp editor/project_manager.cpp msgid "Browse" @@ -3440,7 +3431,7 @@ msgstr "Путь к Ñцене:" #: editor/editor_sub_scene.cpp msgid "Import From Node:" -msgstr "Импортировать из Узла:" +msgstr "Импортировать из узла:" #: editor/export_template_manager.cpp msgid "Redownload" @@ -3504,14 +3495,13 @@ msgid "Importing:" msgstr "ИмпортируетÑÑ:" #: editor/export_template_manager.cpp -#, fuzzy msgid "Error getting the list of mirrors." -msgstr "Ошибка при Ñоздании объекта подпиÑи." +msgstr "Ошибка при получении ÑпиÑка зеркал." #: editor/export_template_manager.cpp -#, fuzzy msgid "Error parsing JSON of mirror list. Please report this issue!" -msgstr "Ошибка разбора ÑпиÑка зеркал. ПожалуйÑта, Ñообщите об Ñтой проблеме!" +msgstr "" +"Ошибка парÑинга JSON ÑпиÑка зеркал. ПожалуйÑта, Ñообщите об Ñтой проблеме!" #: editor/export_template_manager.cpp msgid "" @@ -3649,7 +3639,7 @@ msgstr "Менеджер шаблонов ÑкÑпорта" #: editor/export_template_manager.cpp msgid "Download Templates" -msgstr "Загрузить Шаблоны" +msgstr "Загрузить шаблоны" #: editor/export_template_manager.cpp msgid "Select mirror from list: (Shift+Click: Open in Browser)" @@ -3934,7 +3924,7 @@ msgstr "Фильтр узлов" #: editor/groups_editor.cpp msgid "Nodes in Group" -msgstr "Узлы в Группе" +msgstr "Узлы в группе" #: editor/groups_editor.cpp msgid "Empty groups will be automatically removed." @@ -3946,7 +3936,7 @@ msgstr "Редактор групп" #: editor/groups_editor.cpp msgid "Manage Groups" -msgstr "Управление Группами" +msgstr "Управление группами" #: editor/import/resource_importer_scene.cpp msgid "Import as Single Scene" @@ -4159,11 +4149,11 @@ msgstr "Редактировать плагин" #: editor/plugin_config_dialog.cpp msgid "Create a Plugin" -msgstr "Создать Дополнение" +msgstr "Создать дополнение" #: editor/plugin_config_dialog.cpp msgid "Plugin Name:" -msgstr "Ð˜Ð¼Ñ Ð”Ð¾Ð¿Ð¾Ð»Ð½ÐµÐ½Ð¸Ñ:" +msgstr "Ð˜Ð¼Ñ Ð´Ð¾Ð¿Ð¾Ð»Ð½ÐµÐ½Ð¸Ñ:" #: editor/plugin_config_dialog.cpp msgid "Subfolder:" @@ -4175,7 +4165,7 @@ msgstr "Язык:" #: editor/plugin_config_dialog.cpp msgid "Script Name:" -msgstr "Ð˜Ð¼Ñ Ð¡ÐºÑ€Ð¸Ð¿Ñ‚Ð°:" +msgstr "Ð˜Ð¼Ñ Ñкрипта:" #: editor/plugin_config_dialog.cpp msgid "Activate now?" @@ -4184,7 +4174,7 @@ msgstr "Ðктивировать ÑейчаÑ?" #: editor/plugins/abstract_polygon_2d_editor.cpp #: editor/plugins/polygon_2d_editor_plugin.cpp msgid "Create Polygon" -msgstr "Создать Полигон" +msgstr "Создать полигон" #: editor/plugins/abstract_polygon_2d_editor.cpp #: editor/plugins/animation_blend_space_1d_editor.cpp @@ -4217,11 +4207,11 @@ msgstr "Ð’Ñтавить точку" #: editor/plugins/abstract_polygon_2d_editor.cpp msgid "Edit Polygon (Remove Point)" -msgstr "Редактировать Полигон (удалить точку)" +msgstr "Редактировать полигон (удалить точку)" #: editor/plugins/abstract_polygon_2d_editor.cpp msgid "Remove Polygon And Point" -msgstr "Удалить Полигон и Точку" +msgstr "Удалить полигон и точку" #: editor/plugins/animation_blend_space_1d_editor.cpp #: editor/plugins/animation_blend_space_2d_editor.cpp @@ -4319,7 +4309,7 @@ msgstr "Открыть редактор" #: editor/plugins/animation_blend_tree_editor_plugin.cpp #: editor/plugins/animation_state_machine_editor.cpp msgid "Open Animation Node" -msgstr "Открыть Узел Ðнимации" +msgstr "Открыть узел анимации" #: editor/plugins/animation_blend_space_2d_editor.cpp msgid "Triangle already exists." @@ -4347,7 +4337,7 @@ msgstr "Удалить треугольник BlendSpace2D" #: editor/plugins/animation_blend_space_2d_editor.cpp msgid "BlendSpace2D does not belong to an AnimationTree node." -msgstr "BlendSpace2D не принадлежит Узлу AnimationTree." +msgstr "BlendSpace2D не принадлежит узлу AnimationTree." #: editor/plugins/animation_blend_space_2d_editor.cpp msgid "No triangles exist, so no blending can take place." @@ -4413,7 +4403,7 @@ msgstr "Узлы разъединены" #: editor/plugins/animation_blend_tree_editor_plugin.cpp msgid "Set Animation" -msgstr "Задать Ðнимацию" +msgstr "Задать анимацию" #: editor/plugins/animation_blend_tree_editor_plugin.cpp #: editor/plugins/visual_shader_editor_plugin.cpp @@ -4526,7 +4516,7 @@ msgstr "Изменена поÑÐ»ÐµÐ´ÑƒÑŽÑ‰Ð°Ñ Ð°Ð½Ð¸Ð¼Ð°Ñ†Ð¸Ñ" #: editor/plugins/animation_player_editor_plugin.cpp msgid "Change Blend Time" -msgstr "Изменить Ð²Ñ€ÐµÐ¼Ñ \"ÑмешиваниÑ\"" +msgstr "Изменить Ð²Ñ€ÐµÐ¼Ñ ÑмешиваниÑ" #: editor/plugins/animation_player_editor_plugin.cpp msgid "Load Animation" @@ -4592,7 +4582,6 @@ msgid "Animation Tools" msgstr "ИнÑтрументы анимации" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "ÐнимациÑ" @@ -4602,7 +4591,7 @@ msgstr "Редактировать переходы..." #: editor/plugins/animation_player_editor_plugin.cpp msgid "Open in Inspector" -msgstr "Открыть в ИнÑпекторе" +msgstr "Открыть в инÑпекторе" #: editor/plugins/animation_player_editor_plugin.cpp msgid "Display list of animations in player." @@ -4696,9 +4685,8 @@ msgid "Move Node" msgstr "ПеремеÑтить узел" #: editor/plugins/animation_state_machine_editor.cpp -#, fuzzy msgid "Transition exists!" -msgstr "Переходы" +msgstr "Переход уже ÑущеÑтвует!" #: editor/plugins/animation_state_machine_editor.cpp msgid "Add Transition" @@ -4786,9 +4774,8 @@ msgid "Transition: " msgstr "Переход: " #: editor/plugins/animation_state_machine_editor.cpp -#, fuzzy msgid "Play Mode:" -msgstr "Режим оÑмотра" +msgstr "Режим воÑпроизведениÑ:" #: editor/plugins/animation_tree_editor_plugin.cpp #: editor/plugins/animation_tree_player_editor_plugin.cpp @@ -4937,7 +4924,7 @@ msgstr "Содержание:" #: editor/plugins/asset_library_editor_plugin.cpp msgid "View Files" -msgstr "ПроÑмотр Файлов" +msgstr "ПроÑмотр файлов" #: editor/plugins/asset_library_editor_plugin.cpp msgid "Connection error, please try again." @@ -5005,7 +4992,7 @@ msgstr "Ðе удалоÑÑŒ проверить sha256 Ñ…Ñш" #: editor/plugins/asset_library_editor_plugin.cpp msgid "Asset Download Error:" -msgstr "Ошибка Загрузки Шаблона:" +msgstr "Ошибка загрузки шаблона:" #: editor/plugins/asset_library_editor_plugin.cpp msgid "Downloading (%s / %s)..." @@ -5049,7 +5036,7 @@ msgstr "Ðедавно обновлённые" #: editor/plugins/asset_library_editor_plugin.cpp msgid "Least Recently Updated" -msgstr "ПоÑледнее обновление" +msgstr "Давно обновлённые" #: editor/plugins/asset_library_editor_plugin.cpp msgid "Name (A-Z)" @@ -5178,12 +5165,11 @@ msgstr "Шаг Ñетки:" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Primary Line Every:" -msgstr "ÐŸÐµÑ€Ð²Ð¸Ñ‡Ð½Ð°Ñ Ð»Ð¸Ð½Ð¸Ñ ÐšÐ°Ð¶Ð´Ð°Ñ:" +msgstr "Ð–Ð¸Ñ€Ð½Ð°Ñ Ð»Ð¸Ð½Ð¸Ñ ÐºÐ°Ð¶Ð´Ñ‹Ðµ:" #: editor/plugins/canvas_item_editor_plugin.cpp -#, fuzzy msgid "steps" -msgstr "шаги" +msgstr "шагов" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Rotation Offset:" @@ -5271,62 +5257,61 @@ msgstr "Слева вверху" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Top Right" -msgstr "Верхнее право" +msgstr "Справа вверху" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Bottom Right" -msgstr "Ðижнее право" +msgstr "Справа внизу" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Bottom Left" -msgstr "Ðижнее левое" +msgstr "Слева внизу" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Center Left" -msgstr "Центр Слева" +msgstr "Слева по центру" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Center Top" -msgstr "Топ-центр" +msgstr "Вверху поÑередине" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Center Right" -msgstr "Центральное право" +msgstr "Справа по центру" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Center Bottom" -msgstr "Центральное дно" +msgstr "Внизу поÑередине" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Center" -msgstr "Центр" +msgstr "По центру" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Left Wide" -msgstr "Ðалево Широко" +msgstr "Слева по вÑей выÑоте" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Top Wide" -msgstr "Широчайший Ñпектр" +msgstr "Сверху по вÑей ширине" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Right Wide" -msgstr "ÐŸÑ€Ð°Ð²Ð°Ñ Ð¨Ð¸Ñ€Ð¾Ñ‚Ð°" +msgstr "Справа по вÑей выÑоте" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Bottom Wide" -msgstr "Широкий нижний край" +msgstr "Снизу по вÑей ширине" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "VCenter Wide" -msgstr "V Центр Широкий" +msgstr "ПоÑередине по вÑей выÑоте" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "HCenter Wide" -msgstr "H Центр Широкий" +msgstr "По центру по вÑей ширине" #: editor/plugins/canvas_item_editor_plugin.cpp -#, fuzzy msgid "Full Rect" msgstr "Полный прÑмоугольник" @@ -5353,7 +5338,7 @@ msgid "" "Overrides game camera with editor viewport camera." msgstr "" "Переопределение игровой камеры\n" -"ПереопределÑет игровую камеру Ñ Ð¿Ð¾Ð¼Ð¾Ñ‰ÑŒÑŽ камеры редактора вью-порта." +"ПереопределÑет игровую камеру камерой редактора viewport." #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp @@ -5499,7 +5484,7 @@ msgstr "ИÑпользовать привÑзку к Ñетке" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Snapping Options" -msgstr "Параметры ПривÑзки" +msgstr "Параметры привÑзки" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Use Rotation Snap" @@ -5507,7 +5492,7 @@ msgstr "ИÑпользовать привÑзку вращениÑ" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Use Scale Snap" -msgstr "ИÑпользовать умную привÑзку" +msgstr "ИÑпользовать привÑзку маÑштабированиÑ" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Snap Relative" @@ -5580,11 +5565,11 @@ msgstr "Показать коÑти" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Make Custom Bone(s) from Node(s)" -msgstr "Сделать ПользовательÑкие КоÑÑ‚ÑŒ(и) от Узла(ов)" +msgstr "Сделать пользовательÑкие коÑÑ‚ÑŒ(и) от узла(ов)" #: editor/plugins/canvas_item_editor_plugin.cpp msgid "Clear Custom Bones" -msgstr "ОчиÑтить ПользовательÑкие КоÑти" +msgstr "ОчиÑтить пользовательÑкие коÑти" #: editor/plugins/canvas_item_editor_plugin.cpp #: editor/plugins/spatial_editor_plugin.cpp @@ -5666,6 +5651,11 @@ msgid "Auto Insert Key" msgstr "ÐвтовÑтавка ключа" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Ключ анимации вÑтавлен." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Ð’Ñтавить ключ (ÑущеÑтвующие треки)" @@ -5777,7 +5767,7 @@ msgstr "МаÑка излучениÑ" #: editor/plugins/particles_2d_editor_plugin.cpp #, fuzzy msgid "Solid Pixels" -msgstr "Сжатие (пикÑели): " +msgstr "Твёрдые пикÑели" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5788,7 +5778,7 @@ msgstr "" #: editor/plugins/particles_2d_editor_plugin.cpp #, fuzzy msgid "Directed Border Pixels" -msgstr "Каталоги и файлы:" +msgstr "Ðаправленные граничные пикÑели" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5802,7 +5792,7 @@ msgstr "Цвета излучениÑ" #: editor/plugins/cpu_particles_editor_plugin.cpp msgid "CPUParticles" -msgstr "ЦПУЧаÑтицы" +msgstr "CPU ЧаÑтицы" #: editor/plugins/cpu_particles_editor_plugin.cpp #: editor/plugins/particles_editor_plugin.cpp @@ -5815,14 +5805,12 @@ msgid "Create Emission Points From Node" msgstr "Создать излучатель из узла" #: editor/plugins/curve_editor_plugin.cpp -#, fuzzy msgid "Flat 0" -msgstr "ПлоÑкий0" +msgstr "ПлоÑкий 0" #: editor/plugins/curve_editor_plugin.cpp -#, fuzzy msgid "Flat 1" -msgstr "ПлоÑкий1" +msgstr "ПлоÑкий 1" #: editor/plugins/curve_editor_plugin.cpp editor/property_editor.cpp msgid "Ease In" @@ -5954,7 +5942,6 @@ msgid "No mesh to debug." msgstr "Ðет полиÑетки Ð´Ð»Ñ Ð¾Ñ‚Ð»Ð°Ð´ÐºÐ¸." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "У модели нет UV в Ñтом Ñлое" @@ -6020,25 +6007,24 @@ msgid "Outline Size:" msgstr "Размер обводки:" #: editor/plugins/mesh_instance_editor_plugin.cpp -#, fuzzy msgid "UV Channel Debug" -msgstr "Отладка УФ канала" +msgstr "Отладка UV канала" #: editor/plugins/mesh_library_editor_plugin.cpp msgid "Remove item %d?" msgstr "Удалить Ñлемент %d?" #: editor/plugins/mesh_library_editor_plugin.cpp -#, fuzzy msgid "" "Update from existing scene?:\n" "%s" -msgstr "Обновить из Ñцены" +msgstr "" +"Обновить из ÑущеÑтвующей Ñцены?:\n" +"%s" #: editor/plugins/mesh_library_editor_plugin.cpp -#, fuzzy msgid "Mesh Library" -msgstr "Библиотека полиÑеток..." +msgstr "Библиотека полиÑеток" #: editor/plugins/mesh_library_editor_plugin.cpp #: editor/plugins/theme_editor_plugin.cpp @@ -6183,7 +6169,7 @@ msgstr "Грани данной геометрии не Ñодержат никР#: editor/plugins/particles_editor_plugin.cpp #, fuzzy msgid "The geometry doesn't contain any faces." -msgstr "Узел не Ñодержит геометрии (грани)." +msgstr "Ð”Ð°Ð½Ð½Ð°Ñ Ð³ÐµÐ¾Ð¼ÐµÑ‚Ñ€Ð¸Ñ Ð½Ðµ Ñодержит граней." #: editor/plugins/particles_editor_plugin.cpp msgid "\"%s\" doesn't inherit from Spatial." @@ -6211,7 +6197,7 @@ msgstr "Точки поверхноÑти" #: editor/plugins/particles_editor_plugin.cpp msgid "Surface Points+Normal (Directed)" -msgstr "Точки поверхноÑти + Ðормаль(ÐаправленнаÑ)" +msgstr "Точки поверхноÑти + Ðормаль (направленнаÑ)" #: editor/plugins/particles_editor_plugin.cpp msgid "Volume" @@ -6223,7 +6209,7 @@ msgstr "ИÑточник излучениÑ: " #: editor/plugins/particles_editor_plugin.cpp msgid "A processor material of type 'ParticlesMaterial' is required." -msgstr "ТребуетÑÑ Ð¼Ð°Ñ‚ÐµÑ€Ð¸Ð°Ð» типа 'ParticlesMaterial'." +msgstr "ТребуетÑÑ Ð¼Ð°Ñ‚ÐµÑ€Ð¸Ð°Ð» типа 'ParticlesMaterial'." #: editor/plugins/particles_editor_plugin.cpp msgid "Generating AABB" @@ -6278,7 +6264,7 @@ msgstr "Выбрать точки" #: editor/plugins/path_2d_editor_plugin.cpp #: editor/plugins/path_editor_plugin.cpp msgid "Shift+Drag: Select Control Points" -msgstr "Shift+Drag: Выбрать точки управлениÑ" +msgstr "Shift+Тащить: Выбрать точки управлениÑ" #: editor/plugins/path_2d_editor_plugin.cpp #: editor/plugins/path_editor_plugin.cpp @@ -6301,7 +6287,7 @@ msgstr "Выбор точек ÑƒÐ¿Ñ€Ð°Ð²Ð»ÐµÐ½Ð¸Ñ (Shift+Тащить)" #: editor/plugins/path_2d_editor_plugin.cpp #: editor/plugins/path_editor_plugin.cpp msgid "Add Point (in empty space)" -msgstr "Добавить точку (в пуÑтом проÑтранÑтрве)" +msgstr "Добавить точку (в пуÑтом проÑтранÑтве)" #: editor/plugins/path_2d_editor_plugin.cpp #: editor/plugins/path_editor_plugin.cpp @@ -6400,7 +6386,7 @@ msgstr "" #: editor/plugins/polygon_2d_editor_plugin.cpp msgid "Create Polygon & UV" -msgstr "Создать Полигон и UV" +msgstr "Создать полигон и UV" #: editor/plugins/polygon_2d_editor_plugin.cpp msgid "Create Internal Vertex" @@ -6412,7 +6398,7 @@ msgstr "Удалить внутреннюю вершину" #: editor/plugins/polygon_2d_editor_plugin.cpp msgid "Invalid Polygon (need 3 different vertices)" -msgstr "Ðекорректный Полигон (требуетÑÑ 3 различные вершины)" +msgstr "Ðекорректный полигон (требуетÑÑ 3 различные вершины)" #: editor/plugins/polygon_2d_editor_plugin.cpp msgid "Add Custom Polygon" @@ -6460,7 +6446,7 @@ msgstr "КоÑти" #: editor/plugins/polygon_2d_editor_plugin.cpp msgid "Move Points" -msgstr "Передвинуть Точку" +msgstr "Передвинуть точки" #: editor/plugins/polygon_2d_editor_plugin.cpp msgid "Ctrl: Rotate" @@ -6627,7 +6613,7 @@ msgstr "Путь к AnimationPlayer недейÑтвительный" #: editor/plugins/script_editor_plugin.cpp msgid "Clear Recent Files" -msgstr "ОчиÑтить Ðедавние Файлы" +msgstr "ОчиÑтить недавние файлы" #: editor/plugins/script_editor_plugin.cpp msgid "Close and save changes?" @@ -6682,9 +6668,8 @@ msgid "Script failed reloading, check console for errors." msgstr "Ðе удалоÑÑŒ перезагрузить Ñкрипт, проверьте конÑоль на наличие ошибок." #: editor/plugins/script_editor_plugin.cpp -#, fuzzy msgid "Script is not in tool mode, will not be able to run." -msgstr "Скрипт не находитÑÑ Ð² режиме инÑтрумента, запуÑк невозможен." +msgstr "Скрипт не в режиме инÑтрумента, запуÑк невозможен." #: editor/plugins/script_editor_plugin.cpp msgid "" @@ -6711,7 +6696,7 @@ msgstr "Сохранить тему как..." #: editor/plugins/script_editor_plugin.cpp msgid "%s Class Reference" -msgstr "%s Справка по клаÑÑу" +msgstr "Справка по клаÑÑу %s" #: editor/plugins/script_editor_plugin.cpp #: editor/plugins/script_text_editor.cpp @@ -6970,7 +6955,7 @@ msgstr "ПропиÑные" #: editor/plugins/script_text_editor.cpp editor/plugins/text_editor.cpp msgid "Syntax Highlighter" -msgstr "ПодÑветка СинтакÑиÑа" +msgstr "ПодÑветка ÑинтакÑиÑа" #: editor/plugins/script_text_editor.cpp #: editor/plugins/shader_editor_plugin.cpp editor/plugins/text_editor.cpp @@ -7239,7 +7224,7 @@ msgstr "Вид Ñверху." #: editor/plugins/spatial_editor_plugin.cpp msgid "Bottom View." -msgstr "Вид Снизу." +msgstr "Вид Ñнизу." #: editor/plugins/spatial_editor_plugin.cpp msgid "Bottom" @@ -7278,14 +7263,12 @@ msgid "Rear" msgstr "Зад" #: editor/plugins/spatial_editor_plugin.cpp -#, fuzzy msgid "Align Transform with View" -msgstr "ВыравнÑÑ‚ÑŒ Ñ Ð¾Ð±Ð»Ð°Ñтью проÑмотра" +msgstr "ВыравнÑÑ‚ÑŒ преобразование Ñ Ð¾Ð±Ð»Ð°Ñтью проÑмотра" #: editor/plugins/spatial_editor_plugin.cpp -#, fuzzy msgid "Align Rotation with View" -msgstr "СовмеÑтить выбранное Ñ Ð²Ð¸Ð´Ð¾Ð¼" +msgstr "ВыравнÑÑ‚ÑŒ поворот Ñ Ð¾Ð±Ð»Ð°Ñтью проÑмотра" #: editor/plugins/spatial_editor_plugin.cpp editor/scene_tree_dock.cpp msgid "No parent to instance a child at." @@ -7333,22 +7316,25 @@ msgstr "Показывать FPS" #: editor/plugins/spatial_editor_plugin.cpp msgid "Half Resolution" -msgstr "Половинчатое разрешение" +msgstr "Половинное разрешение" #: editor/plugins/spatial_editor_plugin.cpp msgid "Audio Listener" msgstr "ПроÑлушиватель звука" #: editor/plugins/spatial_editor_plugin.cpp -#, fuzzy msgid "Enable Doppler" -msgstr "Включить фильтр" +msgstr "Включить Ñффект Doppler" #: editor/plugins/spatial_editor_plugin.cpp msgid "Cinematic Preview" msgstr "КинематографичеÑкий предварительный проÑмотр" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "ÐедоÑтупно при иÑпользовании рендерера GLES2." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Обзор налево" @@ -7377,9 +7363,8 @@ msgid "Freelook Speed Modifier" msgstr "Обзор модификатор ÑкороÑти" #: editor/plugins/spatial_editor_plugin.cpp -#, fuzzy msgid "Freelook Slow Modifier" -msgstr "Обзор модификатор ÑкороÑти" +msgstr "Медленный модификатор Ñвободного проÑмотра" #: editor/plugins/spatial_editor_plugin.cpp msgid "" @@ -7426,7 +7411,7 @@ msgstr "ИÑпользовать привÑзку" #: editor/plugins/spatial_editor_plugin.cpp msgid "Bottom View" -msgstr "Вид Снизу" +msgstr "Вид Ñнизу" #: editor/plugins/spatial_editor_plugin.cpp msgid "Top View" @@ -7584,43 +7569,39 @@ msgstr "ПоÑле" #: editor/plugins/spatial_editor_plugin.cpp msgid "Nameless gizmo" -msgstr "БезымÑÐ½Ð½Ð°Ñ ÑˆÑ‚ÑƒÐºÐ¾Ð²Ð¸Ð½Ð°" +msgstr "БезымÑнный гизмо" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create Mesh2D" msgstr "Создать Mesh2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "Mesh2D Preview" -msgstr "Создание предпроÑмотра" +msgstr "ПредпроÑмотр Mesh2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create Polygon2D" msgstr "Создать Polygon2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "Polygon2D Preview" -msgstr "Предварительный проÑмотр Polygon2D" +msgstr "ПредпроÑмотр Polygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create CollisionPolygon2D" msgstr "Создать CollisionPolygon2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "CollisionPolygon2D Preview" -msgstr "Создать CollisionPolygon2D" +msgstr "ПредпроÑмотр CollisionPolygon2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Create LightOccluder2D" msgstr "Создан LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "LightOccluder2D Preview" -msgstr "Создан LightOccluder2D" +msgstr "ПредпроÑмотр LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Sprite is empty!" @@ -7653,19 +7634,16 @@ msgstr "" "ÐÐµÐºÐ¾Ñ€Ñ€ÐµÐºÑ‚Ð½Ð°Ñ Ð³ÐµÐ¾Ð¼ÐµÑ‚Ñ€Ð¸Ñ, Ð½ÐµÐ»ÑŒÐ·Ñ Ñоздать полигональную Ñетку Ñтолкновений." #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "Create CollisionPolygon2D Sibling" -msgstr "Создать полигон Ñтолкновений" +msgstr "Создать ÑоÑедний CollisionPolygon2D" #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "Invalid geometry, can't create light occluder." -msgstr "ÐÐµÐºÐ¾Ñ€Ñ€ÐµÐºÑ‚Ð½Ð°Ñ Ð³ÐµÐ¾Ð¼ÐµÑ‚Ñ€Ð¸Ñ, не может быть заменена Ñеткой." +msgstr "ÐÐµÐºÐ¾Ñ€Ñ€ÐµÐºÑ‚Ð½Ð°Ñ Ð³ÐµÐ¾Ð¼ÐµÑ‚Ñ€Ð¸Ñ, невозможно Ñоздать окклюдер." #: editor/plugins/sprite_editor_plugin.cpp -#, fuzzy msgid "Create LightOccluder2D Sibling" -msgstr "Создан затенÑющий полигон" +msgstr "Создать ÑоÑедний LightOccluder2D" #: editor/plugins/sprite_editor_plugin.cpp msgid "Sprite" @@ -7704,9 +7682,8 @@ msgid "Add Frame" msgstr "Добавить кадр" #: editor/plugins/sprite_frames_editor_plugin.cpp -#, fuzzy msgid "Unable to load images" -msgstr "Ðевозможно загрузить изображение:" +msgstr "Ðевозможно загрузить изображениÑ" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "ERROR: Couldn't load frame resource!" @@ -7766,11 +7743,11 @@ msgstr "Добавить кадры из Ñпрайт-лиÑта" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "Insert Empty (Before)" -msgstr "Ð’Ñтавить пуÑтоту (До)" +msgstr "Ð’Ñтавить пуÑтоту (до)" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "Insert Empty (After)" -msgstr "Ð’Ñтавить пуÑтоту (ПоÑле)" +msgstr "Ð’Ñтавить пуÑтоту (поÑле)" #: editor/plugins/sprite_frames_editor_plugin.cpp msgid "Move (Before)" @@ -7847,7 +7824,7 @@ msgstr "Разделитель:" #: editor/plugins/texture_region_editor_plugin.cpp msgid "TextureRegion" -msgstr "ОблаÑтьТекÑтуры" +msgstr "ОблаÑÑ‚ÑŒ текÑтуры" #: editor/plugins/theme_editor_plugin.cpp msgid "Add All Items" @@ -8112,23 +8089,20 @@ msgid "Merge from Scene" msgstr "СлиÑние из Ñцены" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "New Single Tile" msgstr "ÐÐ¾Ð²Ð°Ñ Ð¾Ð´Ð¸Ð½Ð¾Ñ‡Ð½Ð°Ñ Ð¿Ð»Ð¸Ñ‚ÐºÐ°" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "New Autotile" -msgstr "Отключить автотайлы" +msgstr "Ðовый автотайл" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "New Atlas" -msgstr "ÐтлаÑÑ‹:" +msgstr "Ðовый атлаÑ" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Next Coordinate" -msgstr "Ð¡Ð»ÐµÐ´ÑƒÑŽÑ‰Ð°Ñ ÐšÐ¾Ð¾Ñ€Ð´Ð¸Ð½Ð°Ñ‚Ð°" +msgstr "Ð¡Ð»ÐµÐ´ÑƒÑŽÑ‰Ð°Ñ ÐºÐ¾Ð¾Ñ€Ð´Ð¸Ð½Ð°Ñ‚Ð°" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Select the next shape, subtile, or Tile." @@ -8136,46 +8110,39 @@ msgstr "Выберите Ñледующую фигуру, Ñлемент тайР#: editor/plugins/tile_set_editor_plugin.cpp msgid "Previous Coordinate" -msgstr "ÐŸÑ€ÐµÐ´Ñ‹Ð´ÑƒÑ‰Ð°Ñ ÐšÐ¾Ð¾Ñ€Ð´Ð¸Ð½Ð°Ñ‚Ð°" +msgstr "ÐŸÑ€ÐµÐ´Ñ‹Ð´ÑƒÑ‰Ð°Ñ ÐºÐ¾Ð¾Ñ€Ð´Ð¸Ð½Ð°Ñ‚Ð°" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Select the previous shape, subtile, or Tile." msgstr "Выберите предыдущую форму, Ñлемент тайла или тайл." #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Region" -msgstr "Режим региона" +msgstr "Регион" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Collision" -msgstr "Режим ÑтолкновениÑ" +msgstr "Столкновение" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Occlusion" -msgstr "Режим перекрытиÑ" +msgstr "Перекрытие" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Navigation" -msgstr "Режим навигации" +msgstr "ÐавигациÑ" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Bitmask" -msgstr "Режим битовой маÑки" +msgstr "Ð‘Ð¸Ñ‚Ð¾Ð²Ð°Ñ Ð¼Ð°Ñка" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Priority" -msgstr "Режим приоритета" +msgstr "Приоритет" #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "Z Index" -msgstr "ИндекÑ:" +msgstr "Положение по оÑи Z" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Region Mode" @@ -8298,7 +8265,6 @@ msgid "Delete polygon." msgstr "Удалить полигон." #: editor/plugins/tile_set_editor_plugin.cpp -#, fuzzy msgid "" "LMB: Set bit on.\n" "RMB: Set bit off.\n" @@ -8307,6 +8273,7 @@ msgid "" msgstr "" "ЛКМ: уÑтановить бит.\n" "ПКМ: ÑнÑÑ‚ÑŒ бит.\n" +"Shift+ЛКМ: уÑтановить бит подÑтановки.\n" "Ðажмите на другой тайл чтобы его отредактировать." #: editor/plugins/tile_set_editor_plugin.cpp @@ -8345,7 +8312,7 @@ msgstr "Создать тайл" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Set Tile Icon" -msgstr "УÑтановить Иконку Плитки" +msgstr "Задать иконку тайла" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Edit Tile Bitmask" @@ -8353,7 +8320,7 @@ msgstr "Редактировать битовую маÑку тайла" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Edit Collision Polygon" -msgstr "Редактирование полигона Ñтолкновений" +msgstr "Редактировать полигон Ñтолкновений" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Edit Occlusion Polygon" @@ -8361,7 +8328,7 @@ msgstr "Редактировать полигон перекрытиÑ" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Edit Navigation Polygon" -msgstr "Редактирование полигона навигации" +msgstr "Редактирование полигон навигации" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Paste Tile Bitmask" @@ -8369,15 +8336,15 @@ msgstr "Ð’Ñтавить битовую маÑку тайла" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Clear Tile Bitmask" -msgstr "ОчиÑтить Битовую МаÑку Плитки" +msgstr "ОчиÑтить битовую маÑку тайла" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Make Polygon Concave" -msgstr "Сделать Полигон Вогнутым" +msgstr "Сделать полигон вогнутым" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Make Polygon Convex" -msgstr "Сделать Полигон Выпуклым" +msgstr "Сделать полигон выпуклым" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Remove Tile" @@ -8406,12 +8373,12 @@ msgstr "Редактирование Z индекÑа плитки" #: editor/plugins/tile_set_editor_plugin.cpp #, fuzzy msgid "Make Convex" -msgstr "Сделать Полигон Выпуклым" +msgstr "Сделать Convex" #: editor/plugins/tile_set_editor_plugin.cpp #, fuzzy msgid "Make Concave" -msgstr "Сделать Полигон Вогнутым" +msgstr "Сделать Concave" #: editor/plugins/tile_set_editor_plugin.cpp msgid "Create Collision Polygon" @@ -8427,7 +8394,7 @@ msgstr "Ðто ÑвойÑтво не может быть изменено." #: editor/plugins/tile_set_editor_plugin.cpp msgid "TileSet" -msgstr "Ðабор Тайлов" +msgstr "Ðабор тайлов" #: editor/plugins/version_control_editor_plugin.cpp msgid "No VCS addons are available." @@ -8512,14 +8479,12 @@ msgid "Status" msgstr "СтатуÑ" #: editor/plugins/version_control_editor_plugin.cpp -#, fuzzy msgid "View file diffs before committing them to the latest version" msgstr "ПроÑмотр различий в файлах перед коммитом" #: editor/plugins/version_control_editor_plugin.cpp -#, fuzzy msgid "No file diff is active" -msgstr "Файлы не выбраны!" +msgstr "Ðет выбранных изменений" #: editor/plugins/version_control_editor_plugin.cpp msgid "Detect changes in file diff" @@ -8591,7 +8556,7 @@ msgstr "Изменить размеры узла визуального шейд #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Set Uniform Name" -msgstr "Задать единообразное имÑ" +msgstr "Задать Ð¸Ð¼Ñ uniform" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Set Input Default Port" @@ -8599,7 +8564,7 @@ msgstr "Задать входной порт по умолчанию" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Add Node to Visual Shader" -msgstr "Добавить Узел в Визуальный Шейдер" +msgstr "Добавить узел в визуальный шейдер" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Duplicate Nodes" @@ -8616,7 +8581,7 @@ msgstr "Удалить узлы" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Visual Shader Input Type Changed" -msgstr "Изменен тип ввода Визуального Шейдера" +msgstr "Изменен тип ввода визуального шейдера" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Vertex" @@ -8681,7 +8646,7 @@ msgstr "Оператор выцветаниÑ." #: editor/plugins/visual_shader_editor_plugin.cpp #, fuzzy msgid "HardLight operator." -msgstr "Оператор жёÑткого Ñвета" +msgstr "Оператор жёÑткого Ñвета." #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Lighten operator." @@ -8902,7 +8867,7 @@ msgstr "ВычиÑлÑет ближайшее целое чиÑло, большР#: editor/plugins/visual_shader_editor_plugin.cpp msgid "Constrains a value to lie between two further values." -msgstr "Ограничивает значение лежать между Ð´Ð²ÑƒÐ¼Ñ Ð´Ñ€ÑƒÐ³Ð¸Ð¼Ð¸ значениÑми." +msgstr "Удерживает значение в пределах двух других значений." #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Returns the cosine of the parameter." @@ -9393,22 +9358,21 @@ msgstr "" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "VisualShader" -msgstr "Визуальный Шейдер" +msgstr "Визуальный шейдер" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Edit Visual Property" -msgstr "Редактировать Визуальное СвойÑтво" +msgstr "Редактировать визуальное ÑвойÑтво" #: editor/plugins/visual_shader_editor_plugin.cpp msgid "Visual Shader Mode Changed" -msgstr "Режим Визуального Шейдера был изменен" +msgstr "Режим визуального шейдера был изменен" #: editor/project_export.cpp msgid "Runnable" msgstr "Ðктивный" #: editor/project_export.cpp -#, fuzzy msgid "Add initial export..." msgstr "Добавить начальный ÑкÑпорт..." @@ -9418,7 +9382,7 @@ msgstr "Добавить предыдущие патчи..." #: editor/project_export.cpp msgid "Delete patch '%s' from list?" -msgstr "Удалить латку '%s' из ÑпиÑка?" +msgstr "Удалить патч '%s' из ÑпиÑка?" #: editor/project_export.cpp msgid "Delete preset '%s'?" @@ -9521,11 +9485,11 @@ msgstr "" #: editor/project_export.cpp msgid "Patches" -msgstr "Латки" +msgstr "Патчи" #: editor/project_export.cpp msgid "Make Patch" -msgstr "Создать латку" +msgstr "Создать патч" #: editor/project_export.cpp msgid "Pack File" @@ -9533,7 +9497,7 @@ msgstr "Файл пакета" #: editor/project_export.cpp msgid "Features" -msgstr "ОÑобенноÑти" +msgstr "СвойÑтва" #: editor/project_export.cpp msgid "Custom (comma-separated):" @@ -9936,7 +9900,7 @@ msgstr "" #: editor/project_settings_editor.cpp msgid "Key " -msgstr "Ключ " +msgstr "Клавиша " #: editor/project_settings_editor.cpp msgid "Joy Button" @@ -9968,7 +9932,7 @@ msgstr "Переименовать дейÑтвие" #: editor/project_settings_editor.cpp msgid "Change Action deadzone" -msgstr "Изменить ДейÑтвие мертвой зоны" +msgstr "Изменить мёртвую зону дейÑтвиÑ" #: editor/project_settings_editor.cpp msgid "Add Input Action Event" @@ -9984,11 +9948,11 @@ msgstr "УÑтройÑтво" #: editor/project_settings_editor.cpp editor/settings_config_dialog.cpp msgid "Press a Key..." -msgstr "Ðажмите любую клавишу..." +msgstr "Ðажмите клавишу..." #: editor/project_settings_editor.cpp msgid "Mouse Button Index:" -msgstr "Ð˜Ð½Ð´ÐµÐºÑ ÐºÐ»Ð°Ð²Ð¸ÑˆÐ¸ мыши:" +msgstr "Ð˜Ð½Ð´ÐµÐºÑ ÐºÐ½Ð¾Ð¿ÐºÐ¸ мыши:" #: editor/project_settings_editor.cpp msgid "Left Button" @@ -10121,7 +10085,7 @@ msgstr "Добавить дейÑтвие" #: editor/project_settings_editor.cpp msgid "Override for Feature" -msgstr "Переопределение СвойÑтва" +msgstr "Переопределение ÑвойÑтва" #: editor/project_settings_editor.cpp msgid "Add Translation" @@ -10189,7 +10153,7 @@ msgstr "ДейÑтвие" #: editor/project_settings_editor.cpp msgid "Deadzone" -msgstr "ÐœÐµÑ€Ñ‚Ð²Ð°Ñ Ð·Ð¾Ð½Ð°" +msgstr "ÐœÑ‘Ñ€Ñ‚Ð²Ð°Ñ Ð·Ð¾Ð½Ð°" #: editor/project_settings_editor.cpp msgid "Device:" @@ -10357,7 +10321,7 @@ msgid "" "Compare counter options." msgstr "" "ПоÑледовательный целочиÑленный Ñчетчик.\n" -"Сравните параметров Ñчетчика." +"Сравните параметры Ñчетчика." #: editor/rename_dialog.cpp msgid "Per Level counter" @@ -10435,7 +10399,7 @@ msgstr "Переподчинить узел" #: editor/reparent_dialog.cpp msgid "Reparent Location (Select new Parent):" -msgstr "Ðовое меÑто (выберите нового РодителÑ):" +msgstr "Ðовое меÑто (выберите нового родителÑ):" #: editor/reparent_dialog.cpp msgid "Keep Global Transform" @@ -10503,11 +10467,11 @@ msgstr "Ðта Ð¾Ð¿ÐµÑ€Ð°Ñ†Ð¸Ñ Ð½Ðµ может быть произведена #: editor/scene_tree_dock.cpp msgid "Move Node In Parent" -msgstr "Перемещение узла в РодительÑкий" +msgstr "Перемещение узла в родительÑкий" #: editor/scene_tree_dock.cpp msgid "Move Nodes In Parent" -msgstr "Перемещение узлов в РодительÑкий" +msgstr "Перемещение узлов в родительÑкий" #: editor/scene_tree_dock.cpp msgid "Duplicate Node(s)" @@ -10557,7 +10521,7 @@ msgstr "Ðта Ð¾Ð¿ÐµÑ€Ð°Ñ†Ð¸Ñ Ð½Ðµ может быть Ñделана на рР#: editor/scene_tree_dock.cpp msgid "Save New Scene As..." -msgstr "Сохранить новую Сцену как..." +msgstr "Сохранить новую Ñцену как..." #: editor/scene_tree_dock.cpp msgid "" @@ -10742,7 +10706,7 @@ msgstr "Группа кнопок" #: editor/scene_tree_editor.cpp msgid "(Connecting From)" -msgstr "(Подключение от)" +msgstr "(ИÑточник)" #: editor/scene_tree_editor.cpp msgid "Node configuration warning:" @@ -10865,9 +10829,8 @@ msgid "Error loading script from %s" msgstr "Ошибка при загрузке Ñкрипта из %s" #: editor/script_create_dialog.cpp -#, fuzzy msgid "Overrides" -msgstr "ПерезапиÑать" +msgstr "Переопределить" #: editor/script_create_dialog.cpp msgid "N/A" @@ -10875,7 +10838,7 @@ msgstr "Ð/Д" #: editor/script_create_dialog.cpp msgid "Open Script / Choose Location" -msgstr "Открыть Скрипт / Выбрать МеÑто" +msgstr "Открыть Ñкрипт / Выбрать меÑто" #: editor/script_create_dialog.cpp msgid "Open Script" @@ -10914,9 +10877,8 @@ msgid "Will load an existing script file." msgstr "Будет загружен ÑущеÑтвующий Ñкрипт." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "Разрез уже ÑущеÑтвует." +msgstr "Файл Ñкрипта уже ÑущеÑтвует." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -10972,7 +10934,7 @@ msgstr "ИÑходный код C++:" #: editor/script_editor_debugger.cpp msgid "Stack Trace" -msgstr "ТраÑÑировка Стека" +msgstr "ТраÑÑировка Ñтека" #: editor/script_editor_debugger.cpp msgid "Errors" @@ -11081,15 +11043,15 @@ msgstr "ÐкÑпорт измерений в CSV" #: editor/settings_config_dialog.cpp msgid "Erase Shortcut" -msgstr "Удалить ПривÑзанную Кнопку" +msgstr "Удалить горÑчую клавишу" #: editor/settings_config_dialog.cpp msgid "Restore Shortcut" -msgstr "ВоÑÑтановить ПривÑзанную Кнопку" +msgstr "ВоÑÑтановить горÑчую клавишу" #: editor/settings_config_dialog.cpp msgid "Change Shortcut" -msgstr "Изменить ПривÑзанную Кнопку" +msgstr "Изменить горÑчую клавишу" #: editor/settings_config_dialog.cpp msgid "Editor Settings" @@ -11097,7 +11059,7 @@ msgstr "ÐаÑтройки редактора" #: editor/settings_config_dialog.cpp msgid "Shortcuts" -msgstr "ПривÑзанные кнопки" +msgstr "ГорÑчие клавиши" #: editor/settings_config_dialog.cpp msgid "Binding" @@ -11384,14 +11346,13 @@ msgstr "Заполнить выбранное" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "GridMap Settings" -msgstr "GridMap Параметры" +msgstr "Параметры GridMap" #: modules/gridmap/grid_map_editor_plugin.cpp msgid "Pick Distance:" msgstr "РаÑÑтоÑние выбора:" #: modules/gridmap/grid_map_editor_plugin.cpp -#, fuzzy msgid "Filter meshes" msgstr "Фильтр полиÑеток" @@ -11718,18 +11679,15 @@ msgid "Paste VisualScript Nodes" msgstr "Ð’Ñтавить узлы VisualScript" #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Can't create function with a function node." -msgstr "Ðе удаётÑÑ Ñкопировать узел функцию." +msgstr "Ðе удаётÑÑ Ñоздать функцию Ñ Ñ„ÑƒÐ½ÐºÑ†Ð¸Ð¾Ð½Ð°Ð»ÑŒÐ½Ñ‹Ð¼ узлом." #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Can't create function of nodes from nodes of multiple functions." msgstr "" -"Ðевозможно Ñоздать функцию из узлов, принадлежащим неÑкольким функциÑм." +"Ðевозможно Ñоздать функцию узлов из узлов принадлежащим неÑкольким функциÑм." #: modules/visual_script/visual_script_editor.cpp -#, fuzzy msgid "Select at least one node with sequence port." msgstr "Выберите по крайней мере один узел Ñ Ð¿Ð¾Ñледовательным портом." @@ -11764,7 +11722,7 @@ msgstr "Редактирование Ñигнала:" #: modules/visual_script/visual_script_editor.cpp #, fuzzy msgid "Make Tool:" -msgstr "Сделать инÑтрумент:" +msgstr "Сделать инÑтрументом:" #: modules/visual_script/visual_script_editor.cpp msgid "Members:" @@ -12051,18 +12009,16 @@ msgid "Using default boot splash image." msgstr "ИÑпользовать Ð¸Ð·Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ Ð·Ð°Ñтавки по умолчанию." #: platform/uwp/export/export.cpp -#, fuzzy msgid "Invalid package short name." -msgstr "ÐедопуÑтимое Ð¸Ð¼Ñ Ð¿Ð°ÐºÐµÑ‚Ð°:" +msgstr "ÐедопуÑтимое короткое Ð¸Ð¼Ñ Ð¿Ð°ÐºÐµÑ‚Ð°." #: platform/uwp/export/export.cpp msgid "Invalid package unique name." msgstr "Ðеверное уникальное Ð¸Ð¼Ñ Ð¿Ð°ÐºÐµÑ‚Ð°." #: platform/uwp/export/export.cpp -#, fuzzy msgid "Invalid package publisher display name." -msgstr "Ðеверное уникальное Ð¸Ð¼Ñ Ð¿Ð°ÐºÐµÑ‚Ð°." +msgstr "Ðеверное Ð¸Ð¼Ñ Ð¸Ð·Ð´Ð°Ñ‚ÐµÐ»Ñ Ð¿Ð°ÐºÐµÑ‚Ð°." #: platform/uwp/export/export.cpp msgid "Invalid product GUID." @@ -12105,13 +12061,12 @@ msgid "Invalid splash screen image dimensions (should be 620x300)." msgstr "Ðеверные размеры заÑтавки (должны быть 620x300)." #: scene/2d/animated_sprite.cpp -#, fuzzy msgid "" "A SpriteFrames resource must be created or set in the \"Frames\" property in " "order for AnimatedSprite to display frames." msgstr "" -"Чтобы AnimatedSprite отображал кадры, пожалуйÑта уÑтановите или Ñоздайте " -"реÑÑƒÑ€Ñ SpriteFrames в параметре 'Frames'." +"Чтобы AnimatedSprite отображал кадры, реÑÑƒÑ€Ñ SpriteFrames должен быть Ñоздан " +"или задан в ÑвойÑтве «Frames»." #: scene/2d/canvas_modulate.cpp msgid "" @@ -12175,12 +12130,11 @@ msgstr "" "включенной функцией \"Particles Animation\"." #: scene/2d/light_2d.cpp -#, fuzzy msgid "" "A texture with the shape of the light must be supplied to the \"Texture\" " "property." msgstr "" -"ТекÑтуры Ñ Ñ„Ð¾Ñ€Ð¼Ð¾Ð¹ Ñвета должны быть предоÑтавлены параметру \"texture\"." +"ТекÑтуры Ñ Ñ„Ð¾Ñ€Ð¼Ð¾Ð¹ Ñвета должны быть предоÑтавлены параметру \"Texture\"." #: scene/2d/light_occluder_2d.cpp msgid "" @@ -12283,25 +12237,22 @@ msgstr "" "Skeleton2D и уÑтановите её." #: scene/2d/tile_map.cpp -#, fuzzy msgid "" "TileMap with Use Parent on needs a parent CollisionObject2D to give shapes " "to. Please use it as a child of Area2D, StaticBody2D, RigidBody2D, " "KinematicBody2D, etc. to give them a shape." msgstr "" -"CollisionShape2D Ñлужит только Ð´Ð»Ñ Ð¾Ð±ÐµÑÐ¿ÐµÑ‡ÐµÐ½Ð¸Ñ Ñтолкновений фигурам типа " -"CollisionObject2D. ПожалуйÑта иÑпользовать его только в качеÑтве дочернего " -"Ð´Ð»Ñ Area2D, StaticBody2D, RigidBody2D, KinematicBody2D и др. чтобы придать " -"им форму." +"Узлу TileMap Ñ Â«Use Parent» необходим родитель CollisionObject2D. " +"ПожалуйÑта, иÑпользуйте данный узел в качеÑтве дочернего Ð´Ð»Ñ Area2D, " +"StaticBody2D, RigidBody2D, KinematicBody2D и др. чтобы придать им форму." #: scene/2d/visibility_notifier_2d.cpp -#, fuzzy msgid "" "VisibilityEnabler2D works best when used with the edited scene root directly " "as parent." msgstr "" -"VisibilityEnable2D работает наилучшим образом при иÑпользовании ÐºÐ¾Ñ€Ð½Ñ " -"редактируемой Ñцены, как прÑмого родителÑ." +"VisibilityEnable2D работает лучше вÑего когда корень редактируемой Ñцены " +"ÑвлÑетÑÑ ÐµÐ³Ð¾ прÑмым родителем." #: scene/3d/arvr_nodes.cpp msgid "ARVRCamera must have an ARVROrigin node as its parent." @@ -12349,7 +12300,7 @@ msgstr "ПоÑтроение полиÑетки: " #: scene/3d/baked_lightmap.cpp msgid "Plotting Lights:" -msgstr "ПоÑтроение Света:" +msgstr "ПоÑтроение Ñвета:" #: scene/3d/baked_lightmap.cpp scene/3d/gi_probe.cpp msgid "Finishing Plot" @@ -12395,13 +12346,12 @@ msgstr "" "Area, StaticBody, RigidBody, KinematicBody и др. чтобы придать им форму." #: scene/3d/collision_shape.cpp -#, fuzzy msgid "" "A shape must be provided for CollisionShape to function. Please create a " "shape resource for it." msgstr "" -"Shape должен быть предуÑмотрен Ð´Ð»Ñ Ñ„ÑƒÐ½ÐºÑ†Ð¸Ð¹ CollisionShape. ПожалуйÑта, " -"Ñоздайте shape-реÑÑƒÑ€Ñ Ð´Ð»Ñ Ñтого!" +"Shape должен быть предоÑтавлен Ð´Ð»Ñ CollisionShape. ПожалуйÑта, Ñоздайте " +"shape-реÑÑƒÑ€Ñ Ð´Ð»Ñ Ñтого." #: scene/3d/collision_shape.cpp msgid "" @@ -12416,13 +12366,12 @@ msgid "Nothing is visible because no mesh has been assigned." msgstr "Ðичто не видно, потому что не назначена Ñетка." #: scene/3d/cpu_particles.cpp -#, fuzzy msgid "" "CPUParticles animation requires the usage of a SpatialMaterial whose " "Billboard Mode is set to \"Particle Billboard\"." msgstr "" -"ÐÐ½Ð¸Ð¼Ð°Ñ†Ð¸Ñ CPUParticles требует иÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ SpatialMaterial Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð½Ð¾Ð¹ " -"функцией \"Billboard Particles\"." +"ÐÐ½Ð¸Ð¼Ð°Ñ†Ð¸Ñ CPUParticles требует иÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ SpatialMaterial, в котором " +"Billboard Mode задано в «Particle Billboard»." #: scene/3d/gi_probe.cpp msgid "Plotting Meshes" @@ -12469,13 +12418,12 @@ msgid "" msgstr "Ðичего не видно, потому что полиÑетки не были назначены на отриÑовку." #: scene/3d/particles.cpp -#, fuzzy msgid "" "Particles animation requires the usage of a SpatialMaterial whose Billboard " "Mode is set to \"Particle Billboard\"." msgstr "" -"ÐÐ½Ð¸Ð¼Ð°Ñ†Ð¸Ñ Ñ‡Ð°Ñтиц требует иÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ SpatialMaterial Ñ Ð²ÐºÐ»ÑŽÑ‡ÐµÐ½Ð½Ð¾Ð¹ функцией " -"\"Billboard Particles\"." +"ÐÐ½Ð¸Ð¼Ð°Ñ†Ð¸Ñ Ñ‡Ð°Ñтиц требует иÑÐ¿Ð¾Ð»ÑŒÐ·Ð¾Ð²Ð°Ð½Ð¸Ñ SpatialMaterial, в котором Billboard " +"Mode уÑтановлено в «Particle Billboard»." #: scene/3d/path.cpp msgid "PathFollow only works when set as a child of a Path node." @@ -12608,11 +12556,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Цвет: #%s\n" +"ЛКМ: УÑтановить цвет\n" +"ПКМ: Удалить преÑет" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Выбрать цвет Ñ Ñкрана." +msgstr "Выберите цвет в Ñкране редактора." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12620,7 +12570,7 @@ msgstr "HSV" #: scene/gui/color_picker.cpp msgid "Raw" -msgstr "Сырой" +msgstr "Raw" #: scene/gui/color_picker.cpp msgid "Switch between hexadecimal and code values." @@ -12631,16 +12581,15 @@ msgid "Add current color as a preset." msgstr "Добавить текущий цвет как преÑет." #: scene/gui/container.cpp -#, fuzzy msgid "" "Container by itself serves no purpose unless a script configures its " "children placement behavior.\n" "If you don't intend to add a script, use a plain Control node instead." msgstr "" "Контейнер Ñам по Ñебе не имеет ÑмыÑла, пока Ñкрипт не наÑтроит режим " -"Ñ€Ð°Ð·Ð¼ÐµÑ‰ÐµÐ½Ð¸Ñ ÐµÐ³Ð¾ детей.\n" -"ЕÑли вы не ÑобираетеÑÑŒ добавлÑÑ‚ÑŒ Ñкрипт, иÑпользуйте вмеÑто Ñтого проÑтой " -"узел 'Control'." +"Ñ€Ð°Ð·Ð¼ÐµÑ‰ÐµÐ½Ð¸Ñ ÐµÐ³Ð¾ дочерних Ñлементов.\n" +"ЕÑли не будете добавлÑÑ‚ÑŒ Ñкрипт, то иÑпользуйте вмеÑто Ñтого узел \"Control" +"\"." #: scene/gui/control.cpp msgid "" @@ -12660,15 +12609,14 @@ msgid "Please Confirm..." msgstr "Подтверждение..." #: scene/gui/popup.cpp -#, fuzzy msgid "" "Popups will hide by default unless you call popup() or any of the popup*() " "functions. Making them visible for editing is fine, but they will hide upon " "running." msgstr "" -"ПоÑле запуÑка вÑплывающие окна по умолчанию Ñкрыты, Ð´Ð»Ñ Ð¸Ñ… Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ " -"иÑпользуйте функцию popup() или любую из popup*(). Делать их видимыми Ð´Ð»Ñ " -"Ñ€ÐµÐ´Ð°ÐºÑ‚Ð¸Ñ€Ð¾Ð²Ð°Ð½Ð¸Ñ - нормально, но они будут Ñкрыты при запуÑке." +"Ð’Ñплывающие окна по умолчанию Ñкрыты, Ð´Ð»Ñ Ð¸Ñ… Ð¾Ñ‚Ð¾Ð±Ñ€Ð°Ð¶ÐµÐ½Ð¸Ñ Ð¸Ñпользуйте одну из " +"функций popup() или popup*(). Их можно делать видимыми при редактировании, " +"но они будут Ñкрыты при запуÑке." #: scene/gui/range.cpp msgid "If \"Exp Edit\" is enabled, \"Min Value\" must be greater than 0." @@ -12739,6 +12687,24 @@ msgstr "Ð˜Ð·Ð¼ÐµÐ½ÐµÐ½Ð¸Ñ Ð¼Ð¾Ð³ÑƒÑ‚ быть назначены только Ð msgid "Constants cannot be modified." msgstr "КонÑтанты не могут быть изменены." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Ð’ наÑтоÑщее Ð²Ñ€ÐµÐ¼Ñ Ð¾Ñ‚ÑутÑтвуют учебники Ð´Ð»Ñ Ñтого клаÑÑа, вы можете его " +#~ "[color=$color][url=$url]добавить[/url][/color] или [color=$color][url=" +#~ "$url2]запроÑить[/url][/color]." + +#~ msgid "enum " +#~ msgstr "перечиÑление " + +#~ msgid "Brief Description" +#~ msgstr "Краткое опиÑание" + +#~ msgid "Class Description" +#~ msgstr "ОпиÑание клаÑÑа" + #~ msgid "Project export failed with error code %d." #~ msgstr "ÐкÑпорт проекта не удалÑÑ, код %d." diff --git a/editor/translations/si.po b/editor/translations/si.po index 3876763252..bd57c6a782 100644 --- a/editor/translations/si.po +++ b/editor/translations/si.po @@ -1907,50 +1907,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4390,7 +4387,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5444,6 +5440,11 @@ msgid "Auto Insert Key" msgstr "Anim යà¶à·”රක් ඇà¶à·”ලà¶à·Š කරන්න" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "සජීවීකරණ කà·à¶½à¶º (à¶à¶´à·Šà¶´à¶»)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5728,7 +5729,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7099,6 +7099,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/sk.po b/editor/translations/sk.po index 9760450e61..a81d842616 100644 --- a/editor/translations/sk.po +++ b/editor/translations/sk.po @@ -1963,14 +1963,27 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "Popis:" #: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "" + +#: editor/editor_help.cpp msgid "Properties" msgstr "" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "NaÄÃtaÅ¥ predvolené" + +#: editor/editor_help.cpp msgid "Methods" msgstr "" @@ -1985,34 +1998,19 @@ msgid "Enumerations" msgstr "Popis:" #: editor/editor_help.cpp -msgid "enum " -msgstr "" - -#: editor/editor_help.cpp #, fuzzy msgid "Constants" msgstr "KonÅ¡tanty:" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" +msgid "Property Descriptions" msgstr "Popis:" #: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" - -#: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "Popis:" +msgid "(value)" +msgstr "Hodnota:" #: editor/editor_help.cpp msgid "" @@ -4519,7 +4517,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5602,6 +5599,11 @@ msgid "Auto Insert Key" msgstr "Animácia VložiÅ¥ KľúÄ" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Dĺžka ÄŒasu Animácie (v sekundách)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5893,7 +5895,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7306,6 +7307,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12492,6 +12497,14 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Popis:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "Popis:" + #~ msgid "Shift+" #~ msgstr "Shift+" diff --git a/editor/translations/sl.po b/editor/translations/sl.po index fd3d3ed35d..6f63bb7483 100644 --- a/editor/translations/sl.po +++ b/editor/translations/sl.po @@ -2033,14 +2033,28 @@ msgstr "Podedovano od:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Kratek Opis:" +msgid "Description" +msgstr "Opis:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "Spletne Vaje:" #: editor/editor_help.cpp msgid "Properties" msgstr "Lastnosti" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Prevzeto" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metode" @@ -2054,36 +2068,18 @@ msgid "Enumerations" msgstr "OÅ¡tevilÄenja" #: editor/editor_help.cpp -msgid "enum " -msgstr "oÅ¡tevil " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstante" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "Opis" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "Spletne Vaje:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Trenutno ni vaj za ta razred, lahko ga [color=$color][url=$url]prispevate[/" -"url][/color] ali [color=$color][url=$url2]zahtevate enega[/url][/color]." +msgid "Property Descriptions" +msgstr "Opis lastnosti:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "Opis lastnosti:" +msgid "(value)" +msgstr "Novo ime:" #: editor/editor_help.cpp msgid "" @@ -4736,7 +4732,6 @@ msgid "Animation Tools" msgstr "Animacijska Orodja" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animacija" @@ -5872,6 +5867,11 @@ msgid "Auto Insert Key" msgstr "V Animacijo Vstavi KljuÄ" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Dolžina animacije (v sekundah)." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -6163,7 +6163,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7596,6 +7595,10 @@ msgid "Cinematic Preview" msgstr "Ustvari Predogled Modela" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12873,6 +12876,26 @@ msgstr "" msgid "Constants cannot be modified." msgstr "Konstante ni možno spreminjati." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Trenutno ni vaj za ta razred, lahko ga [color=$color][url=" +#~ "$url]prispevate[/url][/color] ali [color=$color][url=$url2]zahtevate " +#~ "enega[/url][/color]." + +#~ msgid "enum " +#~ msgstr "oÅ¡tevil " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Kratek Opis:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "Opis" + #~ msgid "Project export failed with error code %d." #~ msgstr "Izvoz projekta ni uspelo s kodno napako %d." diff --git a/editor/translations/sq.po b/editor/translations/sq.po index 398a9072b8..3c55191a34 100644 --- a/editor/translations/sq.po +++ b/editor/translations/sq.po @@ -1967,14 +1967,29 @@ msgstr "E trashëguar nga:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Përshkrim i Shkurtër:" +msgid "Description" +msgstr "Përshkrimi:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "Tutorialet Online:" #: editor/editor_help.cpp msgid "Properties" msgstr "Vetitë" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "Mbishkruaj" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "E Parazgjedhur" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metodat" @@ -1987,35 +2002,17 @@ msgid "Enumerations" msgstr "Enumeracionet" #: editor/editor_help.cpp -msgid "enum " -msgstr "" - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstantet" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Përshkrimi i Klasës" +msgid "Property Descriptions" +msgstr "Përshkrimi i Vetive" #: editor/editor_help.cpp #, fuzzy -msgid "Online Tutorials" -msgstr "Tutorialet Online:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Nuk ka për momentin tutoriale për këtë klas, ti mund të [color=$color][url=" -"$url]contribute one[/url][/color] ose [color=$color][url=$url2]request one[/" -"url][/color]." - -#: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "Përshkrimi i Vetive" +msgid "(value)" +msgstr "Vlerë e Re:" #: editor/editor_help.cpp msgid "" @@ -4599,7 +4596,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5664,6 +5660,11 @@ msgid "Auto Insert Key" msgstr "Vendos Key" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Kohëzgjatja e Animacionit (sekonda)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5951,7 +5952,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7339,6 +7339,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12426,6 +12430,22 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Nuk ka për momentin tutoriale për këtë klas, ti mund të [color=$color]" +#~ "[url=$url]contribute one[/url][/color] ose [color=$color][url=" +#~ "$url2]request one[/url][/color]." + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Përshkrim i Shkurtër:" + +#~ msgid "Class Description" +#~ msgstr "Përshkrimi i Klasës" + #~ msgid "Project export failed with error code %d." #~ msgstr "Eksportimi i projektit dështoi me kodin e gabimit %d." diff --git a/editor/translations/sr_Cyrl.po b/editor/translations/sr_Cyrl.po index 3d0341383f..366c12b77c 100644 --- a/editor/translations/sr_Cyrl.po +++ b/editor/translations/sr_Cyrl.po @@ -2037,14 +2037,28 @@ msgstr "ÐаÑлеђено од:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Кратак опиÑ:" +msgid "Description" +msgstr "ОпиÑ:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "Онлајн документација" #: editor/editor_help.cpp msgid "Properties" msgstr "ОÑобине" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Уобичајено" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Методе" @@ -2058,37 +2072,18 @@ msgid "Enumerations" msgstr "Енумерације" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "КонÑтанте" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "ОпиÑ" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "Онлајн документација" - -#: editor/editor_help.cpp -#, fuzzy -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Тренутно нема опиÑа ове методе. Молимо помозите нама тако што ћете [color=" -"$color][url=$url]напиÑати једну[/url][/color]!" +msgid "Property Descriptions" +msgstr "ÐžÐ¿Ð¸Ñ Ð¾Ñобине:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "ÐžÐ¿Ð¸Ñ Ð¾Ñобине:" +msgid "(value)" +msgstr "Ðово име:" #: editor/editor_help.cpp msgid "" @@ -4761,7 +4756,6 @@ msgid "Animation Tools" msgstr "Ðнимационе алатке" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Ðнимација" @@ -5897,6 +5891,11 @@ msgid "Auto Insert Key" msgstr "Уметни кључ" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Ðнимациони кључ убачен." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Убаци кључ (поÑтојеће траке)" @@ -6195,7 +6194,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7663,6 +7661,10 @@ msgid "Cinematic Preview" msgstr "Ðаправи приказ мрежа" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Слободан поглед лево" @@ -12979,6 +12981,26 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Тренутно нема опиÑа ове методе. Молимо помозите нама тако што ћете [color=" +#~ "$color][url=$url]напиÑати једну[/url][/color]!" + +#~ msgid "enum " +#~ msgstr "enum " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Кратак опиÑ:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "ОпиÑ" + #~ msgid "Password:" #~ msgstr "Лозинка:" diff --git a/editor/translations/sr_Latn.po b/editor/translations/sr_Latn.po index b9aa895863..e55a90f6f8 100644 --- a/editor/translations/sr_Latn.po +++ b/editor/translations/sr_Latn.po @@ -1919,51 +1919,49 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" -msgstr "" +#, fuzzy +msgid "(value)" +msgstr "Vrednost:" #: editor/editor_help.cpp msgid "" @@ -4409,7 +4407,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5471,6 +5468,11 @@ msgid "Auto Insert Key" msgstr "Animacija dodaj kljuÄ" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Dužina Animacije (secunde)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5756,7 +5758,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7139,6 +7140,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/sv.po b/editor/translations/sv.po index 0a949e6f4e..0da6531121 100644 --- a/editor/translations/sv.po +++ b/editor/translations/sv.po @@ -2023,14 +2023,28 @@ msgstr "Ärvd av:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Kort Beskrivning:" +msgid "Description" +msgstr "Beskrivning:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "Dokumentation Online" #: editor/editor_help.cpp msgid "Properties" msgstr "Egenskaper" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Standard" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metoder" @@ -2044,37 +2058,18 @@ msgid "Enumerations" msgstr "Uppräkningar" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Konstanter" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "Beskrivning" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "Dokumentation Online" - -#: editor/editor_help.cpp -#, fuzzy -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Det finns för närvarande ingen beskrivning för denna metod. Snälla hjälp oss " -"genom att [color=$color][url=$url]bidra med en[/url][/color]!" +msgid "Property Descriptions" +msgstr "Egenskapsbeskrivning:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "Egenskapsbeskrivning:" +msgid "(value)" +msgstr "Värde" #: editor/editor_help.cpp msgid "" @@ -4713,7 +4708,6 @@ msgid "Animation Tools" msgstr "Animeringsverktyg" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animering" @@ -5817,6 +5811,11 @@ msgid "Auto Insert Key" msgstr "Anim Infoga Nyckel" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animation längd (i sekunder)." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -6111,7 +6110,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7548,6 +7546,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12820,6 +12822,26 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Det finns för närvarande ingen beskrivning för denna metod. Snälla hjälp " +#~ "oss genom att [color=$color][url=$url]bidra med en[/url][/color]!" + +#~ msgid "enum " +#~ msgstr "enum " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Kort Beskrivning:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "Beskrivning" + #~ msgid "Project export failed with error code %d." #~ msgstr "Projekt exporten misslyckades med följande felmeddelande %d." diff --git a/editor/translations/ta.po b/editor/translations/ta.po index 7e85c8a469..0c08e2f565 100644 --- a/editor/translations/ta.po +++ b/editor/translations/ta.po @@ -1909,50 +1909,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4392,7 +4389,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5446,6 +5442,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5728,7 +5728,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7101,6 +7100,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/te.po b/editor/translations/te.po index 3943a5f713..2efe179ce6 100644 --- a/editor/translations/te.po +++ b/editor/translations/te.po @@ -1886,50 +1886,47 @@ msgid "Inherited by:" msgstr "" #: editor/editor_help.cpp -msgid "Brief Description" +msgid "Description" msgstr "" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -msgid "Theme Properties" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "Enumerations" +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "Methods" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Theme Properties" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Property Descriptions" msgstr "" #: editor/editor_help.cpp -msgid "Property Descriptions" +msgid "(value)" msgstr "" #: editor/editor_help.cpp @@ -4357,7 +4354,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5400,6 +5396,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5680,7 +5680,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7050,6 +7049,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" diff --git a/editor/translations/th.po b/editor/translations/th.po index f027ef1ccb..73a18a006d 100644 --- a/editor/translations/th.po +++ b/editor/translations/th.po @@ -2035,14 +2035,29 @@ msgstr "สืบทà¸à¸”โดย:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "รายละเà¸à¸µà¸¢à¸”:" #: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "สà¸à¸™à¹ƒà¸Šà¹‰à¸‡à¸²à¸™à¸à¸à¸™à¹„ลน์:" + +#: editor/editor_help.cpp msgid "Properties" msgstr "คุณสมบัติ" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "à¸à¸³à¸«à¸™à¸”เฉพาะ..." + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "ค่าเริ่มต้น" + +#: editor/editor_help.cpp msgid "Methods" msgstr "รายชื่à¸à¹€à¸¡à¸—็à¸à¸”" @@ -2056,36 +2071,18 @@ msgid "Enumerations" msgstr "ค่าคงที่" #: editor/editor_help.cpp -msgid "enum " -msgstr "à¸à¸¥à¸¸à¹ˆà¸¡à¸„่าคงที่ " - -#: editor/editor_help.cpp msgid "Constants" msgstr "ค่าคงที่" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "รายละเà¸à¸µà¸¢à¸”" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "สà¸à¸™à¹ƒà¸Šà¹‰à¸‡à¸²à¸™à¸à¸à¸™à¹„ลน์:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"คลาสนี้ยังไม่มีà¸à¸²à¸£à¸ªà¸à¸™à¸à¸²à¸£à¹ƒà¸Šà¹‰à¸‡à¸²à¸™ ท่านสามารถ[color=$color][url=$url]ช่วยเขียน[/url][/" -"color] หรืภ[color=$color][url=$url2]ขà¸à¹ƒà¸«à¹‰à¸ˆà¸±à¸”ทำ[/url][/color]" +msgid "Property Descriptions" +msgstr "รายละเà¸à¸µà¸¢à¸”ตัวà¹à¸›à¸£:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "รายละเà¸à¸µà¸¢à¸”ตัวà¹à¸›à¸£:" +msgid "(value)" +msgstr "ค่า" #: editor/editor_help.cpp msgid "" @@ -4683,7 +4680,6 @@ msgid "Animation Tools" msgstr "เครื่à¸à¸‡à¸¡à¸·à¸à¹à¸à¸™à¸´à¹€à¸¡à¸Šà¸±à¸™" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "à¹à¸à¸™à¸´à¹€à¸¡à¸Šà¸±à¸™" @@ -5816,6 +5812,11 @@ msgid "Auto Insert Key" msgstr "à¹à¸—รà¸à¸„ีย์à¹à¸à¸™à¸´à¹€à¸¡à¸Šà¸±à¸™" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "à¹à¸—รà¸à¸„ีย์à¹à¸à¸™à¸´à¹€à¸¡à¸Šà¸±à¸™" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "เพิ่มคีย์ (à¹à¸—ร็à¸à¸—ี่มีà¸à¸¢à¸¹à¹ˆà¹à¸¥à¹‰à¸§)" @@ -6115,7 +6116,6 @@ msgid "No mesh to debug." msgstr "ไม่มีพื้นผิวให้à¹à¸à¹‰à¹„ขจุดบà¸à¸žà¸£à¹ˆà¸à¸‡" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "โมเดลไม่มี UV ในชั้นนี้" @@ -7571,6 +7571,10 @@ msgid "Cinematic Preview" msgstr "à¸à¸³à¸¥à¸±à¸‡à¸ªà¸£à¹‰à¸²à¸‡à¸ าพตัวà¸à¸¢à¹ˆà¸²à¸‡ Mesh" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "มุมมà¸à¸‡à¸à¸´à¸ªà¸£à¸° ไปซ้าย" @@ -12979,6 +12983,25 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "คลาสนี้ยังไม่มีà¸à¸²à¸£à¸ªà¸à¸™à¸à¸²à¸£à¹ƒà¸Šà¹‰à¸‡à¸²à¸™ ท่านสามารถ[color=$color][url=$url]ช่วยเขียน[/url][/" +#~ "color] หรืภ[color=$color][url=$url2]ขà¸à¹ƒà¸«à¹‰à¸ˆà¸±à¸”ทำ[/url][/color]" + +#~ msgid "enum " +#~ msgstr "à¸à¸¥à¸¸à¹ˆà¸¡à¸„่าคงที่ " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "รายละเà¸à¸µà¸¢à¸”:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "รายละเà¸à¸µà¸¢à¸”" + #~ msgid "Password:" #~ msgstr "รหัสผ่าน:" diff --git a/editor/translations/tr.po b/editor/translations/tr.po index e43c4e7211..192364f0c6 100644 --- a/editor/translations/tr.po +++ b/editor/translations/tr.po @@ -1974,14 +1974,29 @@ msgid "Inherited by:" msgstr "Åžundan miras alındı:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "Kısa Açıklama" +#, fuzzy +msgid "Description" +msgstr "Açıklama:" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Çevrimiçi Rehberler" #: editor/editor_help.cpp msgid "Properties" msgstr "Özellikler" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "Ãœzerine Yaz" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Varsayılan" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Metotlar" @@ -1994,36 +2009,19 @@ msgid "Enumerations" msgstr "Numaralandırmalar" #: editor/editor_help.cpp -msgid "enum " -msgstr "enum… " - -#: editor/editor_help.cpp msgid "Constants" msgstr "Sabitler" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Sınıf Açıklaması" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Çevrimiçi Rehberler" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"Bu metot için henüz bir rehber yok. Siz de\n" -"[color=$color][url=$url]hazırlayabilir[/url][/color] ya da \n" -"[color=$color][url=$url2]öneride bulunabilirsiniz[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "Özellik Açıklamaları" #: editor/editor_help.cpp +#, fuzzy +msgid "(value)" +msgstr "DeÄŸer" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4570,7 +4568,6 @@ msgid "Animation Tools" msgstr "Animasyon Araçları" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Animasyon" @@ -5663,6 +5660,11 @@ msgid "Auto Insert Key" msgstr "Otomatik Anahtar Gir" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Animasyon Anahtarı Eklendi." + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Anahtar Gir (Var Olan Ä°zler)" @@ -5947,7 +5949,6 @@ msgid "No mesh to debug." msgstr "Hata ayıklaöma için örüntü yok." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Model bu katmanda UV'ye sahip deÄŸil" @@ -7330,6 +7331,10 @@ msgid "Cinematic Preview" msgstr "Sinematik Önizleme" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "Serbestbakış Sola" @@ -12732,6 +12737,24 @@ msgstr "DeÄŸiÅŸkenler yalnızca tepe iÅŸlevinde atanabilir." msgid "Constants cannot be modified." msgstr "Sabit deÄŸerler deÄŸiÅŸtirilemez." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "Bu metot için henüz bir rehber yok. Siz de\n" +#~ "[color=$color][url=$url]hazırlayabilir[/url][/color] ya da \n" +#~ "[color=$color][url=$url2]öneride bulunabilirsiniz[/url][/color]." + +#~ msgid "enum " +#~ msgstr "enum… " + +#~ msgid "Brief Description" +#~ msgstr "Kısa Açıklama" + +#~ msgid "Class Description" +#~ msgstr "Sınıf Açıklaması" + #~ msgid "Project export failed with error code %d." #~ msgstr "Proje dışa aktarımı %d hata koduyla baÅŸarısız." diff --git a/editor/translations/uk.po b/editor/translations/uk.po index 227e219c54..aca5040517 100644 --- a/editor/translations/uk.po +++ b/editor/translations/uk.po @@ -17,8 +17,8 @@ msgid "" msgstr "" "Project-Id-Version: Ukrainian (Godot Engine)\n" "POT-Creation-Date: \n" -"PO-Revision-Date: 2020-01-03 21:21+0000\n" -"Last-Translator: Tymofij Lytvynenko <till.svit@gmail.com>\n" +"PO-Revision-Date: 2020-01-27 07:10+0000\n" +"Last-Translator: Yuri Chornoivan <yurchor@ukr.net>\n" "Language-Team: Ukrainian <https://hosted.weblate.org/projects/godot-engine/" "godot/uk/>\n" "Language: uk\n" @@ -27,7 +27,7 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=3; plural=n%10==1 && n%100!=11 ? 0 : n%10>=2 && n" "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n" -"X-Generator: Weblate 3.10\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1207,9 +1207,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "Помилка під Ñ‡Ð°Ñ Ñпроби відкрити файл пакунка — дані не у форматі zip." #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "Вже Ñ–Ñнує" +msgstr "%s (вже Ñ–Ñнує)" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1220,9 +1219,8 @@ msgid "The following files failed extraction from package:" msgstr "Ðе вдалоÑÑ Ð²Ð¸Ð´Ð¾Ð±ÑƒÑ‚Ð¸ такі файли з пакунка:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "%d більше файлів" +msgstr "І ще %s файлів." #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1234,9 +1232,8 @@ msgid "Success!" msgstr "УÑпіх!" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "ЗміÑÑ‚:" +msgstr "ВміÑÑ‚ пакунка:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1376,9 +1373,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "ÐеприпуÑтимий файл, це не ÐºÐ¾Ð¼Ð¿Ð¾Ð½ÑƒÐ²Ð°Ð½Ð½Ñ Ð°ÑƒÐ´Ñ–Ð¾-шини." #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "Помилка під Ñ‡Ð°Ñ Ð·Ð±ÐµÑ€ÐµÐ¶ÐµÐ½Ð½Ñ Ñ„Ð°Ð¹Ð»Ð°!" +msgstr "Помилка під Ñ‡Ð°Ñ Ð·Ð±ÐµÑ€ÐµÐ¶ÐµÐ½Ð½Ñ Ñ„Ð°Ð¹Ð»Ð°: %s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1954,14 +1950,26 @@ msgid "Inherited by:" msgstr "УÑпадковано:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "СтиÑлий опиÑ" +msgid "Description" +msgstr "ОпиÑ" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "Підручники в інтернеті" #: editor/editor_help.cpp msgid "Properties" msgstr "ВлаÑтивоÑÑ‚Ñ–" #: editor/editor_help.cpp +msgid "override:" +msgstr "перевизначеннÑ:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "типовий:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Методи" @@ -1974,36 +1982,18 @@ msgid "Enumerations" msgstr "Перелічуваний" #: editor/editor_help.cpp -msgid "enum " -msgstr "перелічуваний " - -#: editor/editor_help.cpp msgid "Constants" msgstr "КонÑтанти" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "ÐžÐ¿Ð¸Ñ ÐºÐ»Ð°Ñу" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "Підручники в інтернеті" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"ÐаÑтанов щодо цього клаÑу ще немає. Ви можете [color=$color][url=" -"$url]Ñтворити Ñ—Ñ…[/url][/color] або [color=$color][url=$url2]надіÑлати запит " -"щодо їхнього ÑтвореннÑ[/url][/color]." - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "ОпиÑи влаÑтивоÑтей" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(значеннÑ)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4554,7 +4544,6 @@ msgid "Animation Tools" msgstr "ІнÑтрументи анімації" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "ÐнімаціÑ" @@ -5628,6 +5617,10 @@ msgid "Auto Insert Key" msgstr "ÐвтовÑÑ‚Ð°Ð²Ð»ÐµÐ½Ð½Ñ ÐºÐ»ÑŽÑ‡Ð¾Ð²Ð¾Ð³Ð¾ кадру" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "Параметри ключового кадру та пози анімації" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "Ð’Ñтавити ключ (Ñ–Ñнуючі доріжки)" @@ -5737,20 +5730,18 @@ msgstr "МаÑка випромінюваннÑ" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "СтиÑÐºÐ°Ð½Ð½Ñ (пікÑелі): " +msgstr "Суцільні пікÑелі" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "Межеві пікÑелі" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "Каталоги та файли:" +msgstr "ПікÑелі на ÑпрÑмованій межі" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5913,7 +5904,6 @@ msgid "No mesh to debug." msgstr "Ðемає Ñітки Ð´Ð»Ñ Ð½Ð°Ð»Ð°Ð³Ð¾Ð´Ð¶ÐµÐ½Ð½Ñ." #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "Модель не має UV на цьому шарі" @@ -7305,6 +7295,10 @@ msgid "Cinematic Preview" msgstr "Кінематичний переглÑд" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "Є недоÑтупним, Ñкщо викориÑтовуєтьÑÑ Ð¾Ð±Ñ€Ð¾Ð±Ð½Ð¸Ðº GLES2." + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "ОглÑд ліворуч" @@ -10843,9 +10837,8 @@ msgid "Will load an existing script file." msgstr "Завантажити наÑвний файл Ñкрипту." #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "Поділ вже Ñ–Ñнує." +msgstr "Файл Ñкрипту вже Ñ–Ñнує." #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12536,11 +12529,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"Колір: #%s\n" +"Ліва кнопка: вÑтановити колір\n" +"Права кнопка: вилучити взірець" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "Вибрати колір з екрана." +msgstr "Вибрати колір з вікна редактора." #: scene/gui/color_picker.cpp msgid "HSV" @@ -12663,6 +12658,24 @@ msgstr "Змінні величини можна пов'Ñзувати лише msgid "Constants cannot be modified." msgstr "Сталі не можна змінювати." +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "ÐаÑтанов щодо цього клаÑу ще немає. Ви можете [color=$color][url=" +#~ "$url]Ñтворити Ñ—Ñ…[/url][/color] або [color=$color][url=$url2]надіÑлати " +#~ "запит щодо їхнього ÑтвореннÑ[/url][/color]." + +#~ msgid "enum " +#~ msgstr "перелічуваний " + +#~ msgid "Brief Description" +#~ msgstr "СтиÑлий опиÑ" + +#~ msgid "Class Description" +#~ msgstr "ÐžÐ¿Ð¸Ñ ÐºÐ»Ð°Ñу" + #~ msgid "Project export failed with error code %d." #~ msgstr "Ðе вдалоÑÑ ÐµÐºÑпортувати проєкт, код помилки — %d." diff --git a/editor/translations/ur_PK.po b/editor/translations/ur_PK.po index e3ebee0a76..5cbc202847 100644 --- a/editor/translations/ur_PK.po +++ b/editor/translations/ur_PK.po @@ -1925,48 +1925,40 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" +msgid "Description" msgstr "سب سکریپشن بنائیں" #: editor/editor_help.cpp -msgid "Properties" +msgid "Online Tutorials" msgstr "" #: editor/editor_help.cpp -msgid "Methods" +msgid "Properties" msgstr "" #: editor/editor_help.cpp -#, fuzzy -msgid "Theme Properties" -msgstr ".تمام کا انتخاب" - -#: editor/editor_help.cpp -msgid "Enumerations" +msgid "override:" msgstr "" #: editor/editor_help.cpp -msgid "enum " +msgid "default:" msgstr "" #: editor/editor_help.cpp -msgid "Constants" +msgid "Methods" msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "سب سکریپشن بنائیں" +msgid "Theme Properties" +msgstr ".تمام کا انتخاب" #: editor/editor_help.cpp -msgid "Online Tutorials" +msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "Constants" msgstr "" #: editor/editor_help.cpp @@ -1975,6 +1967,10 @@ msgid "Property Descriptions" msgstr "سب سکریپشن بنائیں" #: editor/editor_help.cpp +msgid "(value)" +msgstr "" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4450,7 +4446,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5521,6 +5516,10 @@ msgid "Auto Insert Key" msgstr "" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5807,7 +5806,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7206,6 +7204,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12321,6 +12323,10 @@ msgid "Constants cannot be modified." msgstr "" #, fuzzy +#~ msgid "Class Description" +#~ msgstr "سب سکریپشن بنائیں" + +#, fuzzy #~ msgid "Class Description:" #~ msgstr "سب سکریپشن بنائیں" diff --git a/editor/translations/vi.po b/editor/translations/vi.po index 6c2bcb20e4..d6f5114a98 100644 --- a/editor/translations/vi.po +++ b/editor/translations/vi.po @@ -1947,14 +1947,29 @@ msgstr "Äược thừa kế bởi:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "Mô tả ngắn gá»n:" +msgid "Description" +msgstr "Mô tả:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "HÆ°á»›ng dẫn trá»±c tuyến:" #: editor/editor_help.cpp msgid "Properties" msgstr "Thuá»™c tÃnh" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "Ghi đè" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "Mặc định" + +#: editor/editor_help.cpp msgid "Methods" msgstr "Hà m" @@ -1967,33 +1982,18 @@ msgid "Enumerations" msgstr "" #: editor/editor_help.cpp -msgid "enum " -msgstr "" - -#: editor/editor_help.cpp msgid "Constants" msgstr "" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "Mô tả lá»›p" - -#: editor/editor_help.cpp #, fuzzy -msgid "Online Tutorials" -msgstr "HÆ°á»›ng dẫn trá»±c tuyến:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" +msgid "Property Descriptions" +msgstr "Mô tả ngắn gá»n:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "Mô tả ngắn gá»n:" +msgid "(value)" +msgstr "Giá trị:" #: editor/editor_help.cpp msgid "" @@ -4514,7 +4514,6 @@ msgid "Animation Tools" msgstr "Công cụ Hoạt ảnh" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "Hoạt ảnh" @@ -5600,6 +5599,11 @@ msgid "Auto Insert Key" msgstr "Chèn Key Anim" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "Äá»™ dà i hoạt ảnh (giây)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -5886,7 +5890,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7300,6 +7303,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12475,6 +12482,13 @@ msgstr "" msgid "Constants cannot be modified." msgstr "Không thể chỉnh sá»a hằng số." +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "Mô tả ngắn gá»n:" + +#~ msgid "Class Description" +#~ msgstr "Mô tả lá»›p" + #~ msgid "Project export failed with error code %d." #~ msgstr "Xuất dá»± án thất bại vá»›i mã lá»—i %d." diff --git a/editor/translations/zh_CN.po b/editor/translations/zh_CN.po index a1edaeec7e..67f2738f86 100644 --- a/editor/translations/zh_CN.po +++ b/editor/translations/zh_CN.po @@ -63,7 +63,7 @@ msgid "" msgstr "" "Project-Id-Version: Chinese (Simplified) (Godot Engine)\n" "POT-Creation-Date: 2018-01-20 12:15+0200\n" -"PO-Revision-Date: 2020-01-12 13:26+0000\n" +"PO-Revision-Date: 2020-01-27 07:10+0000\n" "Last-Translator: Haoyu Qiu <timothyqiu32@gmail.com>\n" "Language-Team: Chinese (Simplified) <https://hosted.weblate.org/projects/" "godot-engine/godot/zh_Hans/>\n" @@ -72,7 +72,7 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=1; plural=0;\n" -"X-Generator: Weblate 3.10.1\n" +"X-Generator: Weblate 3.11-dev\n" #: core/math/expression.cpp modules/gdscript/gdscript_functions.cpp #: modules/visual_script/visual_script_builtin_funcs.cpp @@ -1229,9 +1229,8 @@ msgid "Error opening package file, not in ZIP format." msgstr "打开压缩文件时出错,éžzipæ ¼å¼ã€‚" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "%s (Already Exists)" -msgstr "å·²ç»å˜åœ¨" +msgstr "%s(已å˜åœ¨ï¼‰" #: editor/editor_asset_installer.cpp msgid "Uncompressing Assets" @@ -1242,9 +1241,8 @@ msgid "The following files failed extraction from package:" msgstr "ä»¥ä¸‹æ–‡ä»¶æ— æ³•ä»ŽåŒ…ä¸æå–:" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "And %s more files." -msgstr "其它 %d 个文件" +msgstr "以åŠå…¶å®ƒ%s个文件。" #: editor/editor_asset_installer.cpp editor/project_manager.cpp msgid "Package installed successfully!" @@ -1256,9 +1254,8 @@ msgid "Success!" msgstr "æˆåŠŸï¼" #: editor/editor_asset_installer.cpp -#, fuzzy msgid "Package Contents:" -msgstr "内容:" +msgstr "包内容:" #: editor/editor_asset_installer.cpp editor/editor_node.cpp msgid "Install" @@ -1398,9 +1395,8 @@ msgid "Invalid file, not an audio bus layout." msgstr "æ— æ•ˆæ–‡ä»¶ï¼Œä¸æ˜¯éŸ³é¢‘总线布局。" #: editor/editor_audio_buses.cpp -#, fuzzy msgid "Error saving file: %s" -msgstr "ä¿å˜æ–‡ä»¶æ—¶å‡ºé”™ï¼" +msgstr "ä¿å˜æ–‡ä»¶æ—¶å‡ºé”™ï¼š%s" #: editor/editor_audio_buses.cpp msgid "Add Bus" @@ -1965,14 +1961,26 @@ msgid "Inherited by:" msgstr "派生:" #: editor/editor_help.cpp -msgid "Brief Description" -msgstr "简介" +msgid "Description" +msgstr "æè¿°" + +#: editor/editor_help.cpp +msgid "Online Tutorials" +msgstr "在线教程" #: editor/editor_help.cpp msgid "Properties" msgstr "属性" #: editor/editor_help.cpp +msgid "override:" +msgstr "覆盖:" + +#: editor/editor_help.cpp +msgid "default:" +msgstr "默认:" + +#: editor/editor_help.cpp msgid "Methods" msgstr "方法" @@ -1985,35 +1993,18 @@ msgid "Enumerations" msgstr "枚举" #: editor/editor_help.cpp -msgid "enum " -msgstr "枚举 " - -#: editor/editor_help.cpp msgid "Constants" msgstr "常é‡" #: editor/editor_help.cpp -msgid "Class Description" -msgstr "类说明" - -#: editor/editor_help.cpp -msgid "Online Tutorials" -msgstr "在线教程" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"当å‰æ²¡æœ‰æ¤ç±»åž‹çš„æ•™ç¨‹ï¼Œä½ å¯ä»¥[color=$color][url=$url]贡献一个[/url][/color]或" -"[color=$color][url=$url2]请求一个[/url][/color]。" - -#: editor/editor_help.cpp msgid "Property Descriptions" msgstr "属性说明" #: editor/editor_help.cpp +msgid "(value)" +msgstr "(值)" + +#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4491,7 +4482,6 @@ msgid "Animation Tools" msgstr "动画工具" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "动画" @@ -5549,6 +5539,10 @@ msgid "Auto Insert Key" msgstr "自动æ’入关键帧" #: editor/plugins/canvas_item_editor_plugin.cpp +msgid "Animation Key and Pose Options" +msgstr "动画关键帧与姿势选项" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "æ’入关键帧(已有轨é“)" @@ -5657,20 +5651,18 @@ msgstr "å‘å°„é®ç½©" #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Solid Pixels" -msgstr "收缩(åƒç´ ): " +msgstr "实体åƒç´ " #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp msgid "Border Pixels" -msgstr "" +msgstr "边界åƒç´ " #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp -#, fuzzy msgid "Directed Border Pixels" -msgstr "目录与文件:" +msgstr "有å‘边界åƒç´ " #: editor/plugins/cpu_particles_2d_editor_plugin.cpp #: editor/plugins/particles_2d_editor_plugin.cpp @@ -5689,12 +5681,12 @@ msgstr "CPUç²’å" #: editor/plugins/cpu_particles_editor_plugin.cpp #: editor/plugins/particles_editor_plugin.cpp msgid "Create Emission Points From Mesh" -msgstr "ä»Žç½‘æ ¼ï¼ˆ Mesh)创建å‘射器(Emission)" +msgstr "从Mesh创建å‘射点" #: editor/plugins/cpu_particles_editor_plugin.cpp #: editor/plugins/particles_editor_plugin.cpp msgid "Create Emission Points From Node" -msgstr "从节点创建å‘射器(Emission)" +msgstr "从Node创建å‘射点" #: editor/plugins/curve_editor_plugin.cpp msgid "Flat 0" @@ -5833,7 +5825,6 @@ msgid "No mesh to debug." msgstr "没有è¦è°ƒè¯•çš„ç½‘æ ¼ã€‚" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "模型在æ¤å±‚上没有UV图" @@ -7209,6 +7200,10 @@ msgid "Cinematic Preview" msgstr "效果预览" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "使用GLES2渲染器时ä¸å¯ç”¨ã€‚" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "自由视图 å·¦" @@ -10661,9 +10656,8 @@ msgid "Will load an existing script file." msgstr "å°†åŠ è½½çŽ°æœ‰çš„è„šæœ¬æ–‡ä»¶ã€‚" #: editor/script_create_dialog.cpp -#, fuzzy msgid "Script file already exists." -msgstr "拆分已å˜åœ¨ã€‚" +msgstr "脚本文件已å˜åœ¨ã€‚" #: editor/script_create_dialog.cpp msgid "Class Name:" @@ -12257,11 +12251,13 @@ msgid "" "LMB: Set color\n" "RMB: Remove preset" msgstr "" +"颜色:#%s\n" +"é¼ æ ‡å·¦é”®ï¼šè®¾ç½®é¢œè‰²\n" +"é¼ æ ‡å³é”®ï¼šåˆ 除预设" #: scene/gui/color_picker.cpp -#, fuzzy msgid "Pick a color from the editor window." -msgstr "从å±å¹•ä¸é€‰æ‹©ä¸€ç§é¢œè‰²ã€‚" +msgstr "从编辑器窗å£ä¸é€‰æ‹©ä¸€ç§é¢œè‰²ã€‚" #: scene/gui/color_picker.cpp msgid "HSV" @@ -12375,6 +12371,23 @@ msgstr "å˜é‡åªèƒ½åœ¨é¡¶ç‚¹å‡½æ•°ä¸æŒ‡å®šã€‚" msgid "Constants cannot be modified." msgstr "ä¸å…许修改常é‡ã€‚" +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "当å‰æ²¡æœ‰æ¤ç±»åž‹çš„æ•™ç¨‹ï¼Œä½ å¯ä»¥[color=$color][url=$url]贡献一个[/url][/color]" +#~ "或[color=$color][url=$url2]请求一个[/url][/color]。" + +#~ msgid "enum " +#~ msgstr "枚举 " + +#~ msgid "Brief Description" +#~ msgstr "简介" + +#~ msgid "Class Description" +#~ msgstr "类说明" + #~ msgid "Project export failed with error code %d." #~ msgstr "项目导出失败,错误代ç %d。" diff --git a/editor/translations/zh_HK.po b/editor/translations/zh_HK.po index d52249df61..e57c2c0303 100644 --- a/editor/translations/zh_HK.po +++ b/editor/translations/zh_HK.po @@ -2060,14 +2060,28 @@ msgstr "" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "簡述:" +msgid "Description" +msgstr "æ述:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "é—œé–‰å ´æ™¯" #: editor/editor_help.cpp msgid "Properties" msgstr "" #: editor/editor_help.cpp +msgid "override:" +msgstr "" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "é è¨" + +#: editor/editor_help.cpp #, fuzzy msgid "Methods" msgstr "é¸æ“‡æ¨¡å¼" @@ -2083,37 +2097,20 @@ msgid "Enumerations" msgstr "ç¿»è¯:" #: editor/editor_help.cpp -msgid "enum " -msgstr "" - -#: editor/editor_help.cpp #, fuzzy msgid "Constants" msgstr "常數" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "æ述:" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "é—œé–‰å ´æ™¯" +msgid "Property Descriptions" +msgstr "簡述:" #: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." +msgid "(value)" msgstr "" #: editor/editor_help.cpp -#, fuzzy -msgid "Property Descriptions" -msgstr "簡述:" - -#: editor/editor_help.cpp msgid "" "There is currently no description for this property. Please help us by " "[color=$color][url=$url]contributing one[/url][/color]!" @@ -4759,7 +4756,6 @@ msgid "Animation Tools" msgstr "" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "" @@ -5870,6 +5866,11 @@ msgid "Auto Insert Key" msgstr "å‹•æ™æ’入關éµå¹€ï¼Ÿ" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "時長(秒)。" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "" @@ -6161,7 +6162,6 @@ msgid "No mesh to debug." msgstr "" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7610,6 +7610,10 @@ msgid "Cinematic Preview" msgstr "" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "" @@ -12897,6 +12901,14 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "簡述:" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "æ述:" + #~ msgid "Password:" #~ msgstr "密碼:" diff --git a/editor/translations/zh_TW.po b/editor/translations/zh_TW.po index 1ca1a64015..6dfb9304f9 100644 --- a/editor/translations/zh_TW.po +++ b/editor/translations/zh_TW.po @@ -2060,14 +2060,29 @@ msgstr "繼承:" #: editor/editor_help.cpp #, fuzzy -msgid "Brief Description" -msgstr "ç°¡è¦èªªæ˜Žï¼š" +msgid "Description" +msgstr "æè¿°:" + +#: editor/editor_help.cpp +#, fuzzy +msgid "Online Tutorials" +msgstr "線上教å¸:" #: editor/editor_help.cpp msgid "Properties" msgstr "性質" #: editor/editor_help.cpp +#, fuzzy +msgid "override:" +msgstr "覆蓋" + +#: editor/editor_help.cpp +#, fuzzy +msgid "default:" +msgstr "é è¨" + +#: editor/editor_help.cpp msgid "Methods" msgstr "方法" @@ -2081,36 +2096,18 @@ msgid "Enumerations" msgstr "枚舉" #: editor/editor_help.cpp -msgid "enum " -msgstr "枚舉 " - -#: editor/editor_help.cpp msgid "Constants" msgstr "定數" #: editor/editor_help.cpp #, fuzzy -msgid "Class Description" -msgstr "æè¿°:" - -#: editor/editor_help.cpp -#, fuzzy -msgid "Online Tutorials" -msgstr "線上教å¸:" - -#: editor/editor_help.cpp -msgid "" -"There are currently no tutorials for this class, you can [color=$color][url=" -"$url]contribute one[/url][/color] or [color=$color][url=$url2]request one[/" -"url][/color]." -msgstr "" -"ç›®å‰æ²’有這個 class çš„æ•™å¸ï¼Œä½ å¯ä»¥[color=$color][url=$url]è²¢ç»ä¸€å€‹[/url][/" -"color]或[color=$color][url=$url2]è¦æ±‚一個[/url][/color]。" +msgid "Property Descriptions" +msgstr "Property 說明:" #: editor/editor_help.cpp #, fuzzy -msgid "Property Descriptions" -msgstr "Property 說明:" +msgid "(value)" +msgstr "數值" #: editor/editor_help.cpp msgid "" @@ -4724,7 +4721,6 @@ msgid "Animation Tools" msgstr "動畫工具" #: editor/plugins/animation_player_editor_plugin.cpp -#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Animation" msgstr "å‹•ç•«" @@ -5850,6 +5846,11 @@ msgid "Auto Insert Key" msgstr "新增關éµç•«æ ¼" #: editor/plugins/canvas_item_editor_plugin.cpp +#, fuzzy +msgid "Animation Key and Pose Options" +msgstr "動畫長度(秒)" + +#: editor/plugins/canvas_item_editor_plugin.cpp msgid "Insert Key (Existing Tracks)" msgstr "æ’入幀 (ç¾æœ‰è»Œé“)" @@ -6145,7 +6146,6 @@ msgid "No mesh to debug." msgstr "沒有è¦èª¿è©¦çš„ç¶²æ ¼ã€‚" #: editor/plugins/mesh_instance_editor_plugin.cpp -#: editor/plugins/sprite_editor_plugin.cpp msgid "Model has no UV in this layer" msgstr "" @@ -7586,6 +7586,10 @@ msgid "Cinematic Preview" msgstr "影片é 覽" #: editor/plugins/spatial_editor_plugin.cpp +msgid "Not available when using the GLES2 renderer." +msgstr "" + +#: editor/plugins/spatial_editor_plugin.cpp msgid "Freelook Left" msgstr "自由視圖 å·¦" @@ -12900,6 +12904,25 @@ msgstr "" msgid "Constants cannot be modified." msgstr "" +#~ msgid "" +#~ "There are currently no tutorials for this class, you can [color=$color]" +#~ "[url=$url]contribute one[/url][/color] or [color=$color][url=" +#~ "$url2]request one[/url][/color]." +#~ msgstr "" +#~ "ç›®å‰æ²’有這個 class çš„æ•™å¸ï¼Œä½ å¯ä»¥[color=$color][url=$url]è²¢ç»ä¸€å€‹[/url][/" +#~ "color]或[color=$color][url=$url2]è¦æ±‚一個[/url][/color]。" + +#~ msgid "enum " +#~ msgstr "枚舉 " + +#, fuzzy +#~ msgid "Brief Description" +#~ msgstr "ç°¡è¦èªªæ˜Žï¼š" + +#, fuzzy +#~ msgid "Class Description" +#~ msgstr "æè¿°:" + #~ msgid "Project export failed with error code %d." #~ msgstr "專案輸出失敗,錯誤代碼是 %d。" diff --git a/main/gamecontrollerdb.txt b/main/gamecontrollerdb.txt index 9f7cd83641..90d309c1c8 100644 --- a/main/gamecontrollerdb.txt +++ b/main/gamecontrollerdb.txt @@ -32,8 +32,8 @@ 03000000c82d00006228000000000000,8BitDo SN30 GP,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a5,start:b11,x:b4,y:b3,platform:Windows, 03000000c82d00000160000000000000,8BitDo SN30 Pro,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a5,start:b11,x:b4,y:b3,platform:Windows, 03000000c82d00000161000000000000,8BitDo SN30 Pro,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a5,start:b11,x:b4,y:b3,platform:Windows, -03000000c82d00000260000000000000,8BitDo SN30 Pro+,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Windows, -03000000c82d00000261000000000000,8BitDo SN30 Pro+,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a5,start:b11,x:b4,y:b3,platform:Windows, +03000000c82d00000260000000000000,8BitDo SN30 Pro+,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Windows, +03000000c82d00000261000000000000,8BitDo SN30 Pro+,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Windows, 03000000c82d00000031000000000000,8BitDo Wireless Adapter,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a3,righty:a4,start:b11,x:b4,y:b3,platform:Windows, 03000000a00500003232000000000000,8Bitdo Zero GamePad,a:b0,b:b1,back:b10,dpdown:+a2,dpleft:-a0,dpright:+a0,dpup:-a2,leftshoulder:b6,rightshoulder:b7,start:b11,x:b3,y:b4,platform:Windows, 030000008f0e00001200000000000000,Acme GA-02,a:b0,b:b1,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b4,leftstick:b10,lefttrigger:b5,leftx:a0,lefty:a1,rightshoulder:b6,rightstick:b11,righttrigger:b7,rightx:a3,righty:a2,start:b9,x:b2,y:b3,platform:Windows, @@ -310,6 +310,7 @@ 03000000786901006e70000000000000,XInput Controller,a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b10,leftshoulder:b4,leftstick:b8,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b9,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Windows, xinput,XInput Controller,a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b10,leftshoulder:b4,leftstick:b8,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b9,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Windows, 03000000790000004f18000000000000,ZD-T Android,a:b0,b:b1,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b12,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a3,righty:a4,start:b11,x:b3,y:b4,platform:Windows, +03000000c82d00003032000000000000,8BitDo Zero 2,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b6,leftx:a0,lefty:a1,rightshoulder:b7,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Windows, # Mac OS X 030000008f0e00000300000009010000,2In1 USB Joystick,+leftx:h0.2,+lefty:h0.4,-leftx:h0.8,-lefty:h0.1,a:b2,b:b1,back:b8,dpdown:+a1,dpleft:-a0,dpright:+a0,dpup:-a1,leftshoulder:b4,leftstick:b10,lefttrigger:b6,rightshoulder:b5,rightstick:b11,righttrigger:b7,rightx:a2,righty:a3,start:b9,x:b3,y:b0,platform:Mac OS X, @@ -319,9 +320,10 @@ xinput,XInput Controller,a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2, 03000000c82d00000190000001000000,8Bitdo NES30 Pro,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Mac OS X, 03000000102800000900000000000000,8Bitdo SFC30 GamePad Joystick,a:b1,b:b0,back:b10,leftshoulder:b6,leftx:a0,lefty:a1,rightshoulder:b7,start:b11,x:b4,y:b3,platform:Mac OS X, 03000000c82d00000161000000010000,8BitDo SN30 Pro,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a5,start:b11,x:b4,y:b3,platform:Mac OS X, -03000000c82d00000260000001000000,8BitDo SN30 Pro+,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a3,righty:a4,start:b11,x:b4,y:b3,platform:Mac OS X, -03000000c82d00000261000000010000,8BitDo SN30 Pro+,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a3,righty:a4,start:b11,x:b4,y:b3,platform:Mac OS X, +03000000c82d00000260000001000000,8BitDo SN30 Pro+,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Mac OS X, +03000000c82d00000261000000010000,8BitDo SN30 Pro+,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b2,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Mac OS X, 03000000c82d00000031000001000000,8BitDo Wireless Adapter,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b6,leftstick:b13,lefttrigger:b8,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:b9,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Mac OS X, +03000000c82d00003032000000010000,8BitDo Zero 2,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b6,leftx:a0,lefty:a1,rightshoulder:b7,rightx:a2,righty:a31,start:b11,x:b4,y:b3,platform:Mac OS X, 03000000a00500003232000008010000,8Bitdo Zero GamePad,a:b0,b:b1,back:b10,dpdown:+a1,dpleft:-a0,dpright:+a0,dpup:-a1,leftshoulder:b6,rightshoulder:b7,start:b11,x:b3,y:b4,platform:Mac OS X, 03000000a00500003232000009010000,8Bitdo Zero GamePad,a:b0,b:b1,back:b10,dpdown:+a1,dpleft:-a0,dpright:+a0,dpup:-a1,leftshoulder:b6,rightshoulder:b7,start:b11,x:b3,y:b4,platform:Mac OS X, 03000000050b00000045000031000000,ASUS Gamepad,a:b0,b:b1,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b4,leftstick:b7,lefttrigger:a5,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b8,righttrigger:a4,rightx:a2,righty:a3,start:b9,x:b2,y:b3,platform:Mac OS X, @@ -719,6 +721,7 @@ xinput,XInput Controller,a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2, 05000000172700004431000029010000,XiaoMi Game Controller,a:b0,b:b1,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b20,leftshoulder:b6,leftstick:b13,lefttrigger:a7,leftx:a0,lefty:a1,rightshoulder:b7,rightstick:b14,righttrigger:a6,rightx:a2,righty:a5,start:b11,x:b3,y:b4,platform:Linux, 03000000c0160000e105000001010000,Xin-Mo Xin-Mo Dual Arcade,a:b4,b:b3,back:b6,dpdown:b12,dpleft:b13,dpright:b14,dpup:b11,guide:b9,leftshoulder:b2,leftx:a0,lefty:a1,rightshoulder:b5,start:b7,x:b1,y:b0,platform:Linux, xinput,XInput Controller,a:b0,b:b1,back:b6,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b8,leftshoulder:b4,leftstick:b9,lefttrigger:a2,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b10,righttrigger:a5,rightx:a3,righty:a4,start:b7,x:b2,y:b3,platform:Linux, +05000000c82d00003032000000010000,8BitDo Zero 2,a:b1,b:b0,back:b10,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,leftshoulder:b6,leftx:a0,lefty:a1,rightshoulder:b7,rightx:a2,righty:a3,start:b11,x:b4,y:b3,platform:Linux, 03000000120c0000100e000011010000,ZEROPLUS P4 Gamepad,a:b1,b:b2,back:b8,dpdown:h0.4,dpleft:h0.8,dpright:h0.2,dpup:h0.1,guide:b12,leftshoulder:b4,leftstick:b10,lefttrigger:a3,leftx:a0,lefty:a1,rightshoulder:b5,rightstick:b11,righttrigger:a4,rightx:a2,righty:a5,start:b9,x:b0,y:b3,platform:Linux, # Android diff --git a/main/main.cpp b/main/main.cpp index 5cfab3dc4a..650a680d87 100644 --- a/main/main.cpp +++ b/main/main.cpp @@ -292,7 +292,7 @@ void Main::print_help(const char *p_binary) { OS::get_singleton()->print(" --export-pack <preset> <path> Same as --export, but only export the game pack for the given preset. The <path> extension determines whether it will be in PCK or ZIP format.\n"); OS::get_singleton()->print(" --doctool <path> Dump the engine API reference to the given <path> in XML format, merging if existing files are found.\n"); OS::get_singleton()->print(" --no-docbase Disallow dumping the base types (used with --doctool).\n"); - OS::get_singleton()->print(" --build-solutions Build the scripting solutions (e.g. for C# projects).\n"); + OS::get_singleton()->print(" --build-solutions Build the scripting solutions (e.g. for C# projects). Implies --editor and requires a valid project to edit.\n"); #ifdef DEBUG_METHODS_ENABLED OS::get_singleton()->print(" --gdnative-generate-json-api Generate JSON dump of the Godot API for GDNative bindings.\n"); #endif @@ -854,7 +854,7 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph #ifdef TOOLS_ENABLED editor = false; #else - String error_msg = "Error: Could not load game data at path '" + project_path + "'. Is the .pck file missing?\n"; + const String error_msg = "Error: Couldn't load project data at path \"" + project_path + "\". Is the .pck file missing?\nIf you've renamed the executable, the associated .pck file should also be renamed to match the executable's name (without the extension).\n"; OS::get_singleton()->print("%s", error_msg.ascii().get_data()); OS::get_singleton()->alert(error_msg); @@ -1035,7 +1035,7 @@ Error Main::setup(const char *execpath, int argc, char *argv[], bool p_second_ph // window compositor ("--enable-vsync-via-compositor" or // "--disable-vsync-via-compositor") was present then it overrides the // project setting. - video_mode.vsync_via_compositor = GLOBAL_DEF("display/window/vsync/vsync_via_compositor", true); + video_mode.vsync_via_compositor = GLOBAL_DEF("display/window/vsync/vsync_via_compositor", false); } OS::get_singleton()->_vsync_via_compositor = video_mode.vsync_via_compositor; @@ -1266,7 +1266,7 @@ Error Main::setup2(Thread::ID p_main_tid_override) { boot_logo.instance(); Error load_err = ImageLoader::load_image(boot_logo_path, boot_logo); if (load_err) - ERR_PRINTS("Non-existing or invalid boot splash at '" + boot_logo_path + "'. Loading default splash."); + ERR_PRINT("Non-existing or invalid boot splash at '" + boot_logo_path + "'. Loading default splash."); } Color boot_bg_color = GLOBAL_DEF("application/boot_splash/bg_color", boot_splash_bg_color); @@ -1900,6 +1900,8 @@ bool Main::start() { ProgressDialog *progress_dialog = memnew(ProgressDialog); pmanager->add_child(progress_dialog); sml->get_root()->add_child(pmanager); + // Speed up rendering slightly by disabling 3D features while in the project manager. + sml->get_root()->set_usage(Viewport::USAGE_2D_NO_SAMPLING); OS::get_singleton()->set_context(OS::CONTEXT_PROJECTMAN); project_manager = true; } @@ -2112,8 +2114,12 @@ bool Main::iteration() { #ifdef TOOLS_ENABLED if (auto_build_solutions) { auto_build_solutions = false; + // Only relevant when running the editor. + if (!editor) { + ERR_FAIL_V_MSG(true, "Command line option --build-solutions was passed, but no project is being edited. Aborting."); + } if (!EditorNode::get_singleton()->call_build()) { - ERR_FAIL_V(true); + ERR_FAIL_V_MSG(true, "Command line option --build-solutions was passed, but the build callback failed. Aborting."); } } #endif @@ -2165,6 +2171,9 @@ void Main::cleanup() { ScriptServer::finish_languages(); + // Sync pending commands that may have been queued from a different thread during ScriptServer finalization + VisualServer::get_singleton()->sync(); + #ifdef TOOLS_ENABLED EditorNode::unregister_editor_types(); #endif diff --git a/misc/dist/docker/Dockerfile b/misc/dist/docker/Dockerfile deleted file mode 100644 index 428de9d1a7..0000000000 --- a/misc/dist/docker/Dockerfile +++ /dev/null @@ -1,13 +0,0 @@ -FROM ubuntu:14.04 -MAINTAINER Mohammad Rezai, https://github.com/mrezai -WORKDIR /godot-dev -COPY scripts/install-android-tools /godot-dev/ -ENV DEBIAN_FRONTEND noninteractive -RUN dpkg --add-architecture i386 && \ - apt-get update && \ - apt-get upgrade -y && \ - apt-get install --no-install-recommends -y -q \ - build-essential gcc-multilib g++-multilib mingw32 mingw-w64 scons pkg-config libx11-dev libxcursor-dev \ - libasound2-dev libfreetype6-dev libgl1-mesa-dev libglu-dev libssl-dev libxinerama-dev libudev-dev \ - git wget openjdk-7-jdk libbcprov-java libc6:i386 libncurses5:i386 libstdc++6:i386 zlib1g:i386 lib32z1 - diff --git a/misc/dist/docker/README.md b/misc/dist/docker/README.md deleted file mode 100644 index 71aac8a77c..0000000000 --- a/misc/dist/docker/README.md +++ /dev/null @@ -1,40 +0,0 @@ -## A Docker image to build Linux, Windows and Android godot binaries. - -The main reason to write this, is to provide a simple way in all platforms to integrate external godot modules and build a custom version of godot. - -## usage -1. Install docker on Linux or docker toolbox on Windows or Mac. -2. Open a terminal on linux or "Docker Quickstart Terminal" on Windows or Mac. -3. Run command: - - Linux: `cd` - - Windows: `cd /c/Users/YOUR_USERNAME` - - Mac: `cd /Users/YOUR_USERNAME` -4. Get godot source code: `git clone https://github.com/godotengine/godot.git` -5. Run command: `cd godot/tools/docker` -6. Run command: `docker build -t godot .`(In Linux run Docker commands with `sudo` or add your user to docker group before run the Docker commands). The godot docker image will be build after a while. -7. Run command: - - Linux: `docker run -it --name=godot-dev -v /home/YOUR_USERNAME/godot:/godot-dev/godot godot` - - Windows: `docker run -it --name=godot-dev -v /c/Users/YOUR_USERNAME/godot:/godot-dev/godot godot` - - Mac: `docker run -it --name=godot-dev -v /Users/YOUR_USERNAME/godot:/godot-dev/godot godot` - You are in the godot-dev container and /godot-dev directory now. -8. Run `./install-android-tools` to download and install all android development tools. -9. Run command: `source ~/.bashrc` -10. Run command: `cd godot` -11. Run command: `scons p=android target=release` to test everything is ok. You can set platform to x11, windows, android, haiku and server. - -After use and exit, you can use this environment again by open terminal and type commands: `docker start godot-dev && docker attach godot-dev`. - -### Windows and Mac stuffs: - -- Speed up compilation: - - Exit from container. - - Run command: `docker-machine stop` - - Open "Oracle VM VirtualBox". - - In settings of default VM increase CPU cores and RAM to suitable values. - - Run command: `docker-machine start` - - Run command: `docker start godot-dev && docker attach godot-dev` - -- ssh to VM(can be useful sometimes): - - `docker-machine ssh` - -Check docker and boot2docker projects for more details. diff --git a/misc/dist/docker/scripts/install-android-tools b/misc/dist/docker/scripts/install-android-tools deleted file mode 100644 index 8a617d9942..0000000000 --- a/misc/dist/docker/scripts/install-android-tools +++ /dev/null @@ -1,90 +0,0 @@ -#!/bin/bash - -BASH_RC=~/.bashrc -GODOT_BUILD_TOOLS_PATH=/godot-dev/build-tools -mkdir -p $GODOT_BUILD_TOOLS_PATH -cd $GODOT_BUILD_TOOLS_PATH - -ANDROID_BASE_URL=http://dl.google.com/android - -ANDROID_SDK_RELEASE=android-sdk_r24.4.1 -ANDROID_SDK_DIR=android-sdk-linux -ANDROID_SDK_FILENAME=$ANDROID_SDK_RELEASE-linux.tgz -ANDROID_SDK_URL=$ANDROID_BASE_URL/$ANDROID_SDK_FILENAME -ANDROID_SDK_PATH=$GODOT_BUILD_TOOLS_PATH/$ANDROID_SDK_DIR -ANDROID_SDK_SHA1=725bb360f0f7d04eaccff5a2d57abdd49061326d - -ANDROID_NDK_RELEASE=android-ndk-r10e -ANDROID_NDK_DIR=$ANDROID_NDK_RELEASE -ANDROID_NDK_FILENAME=$ANDROID_NDK_RELEASE-linux-x86_64.bin -ANDROID_NDK_URL=$ANDROID_BASE_URL/ndk/$ANDROID_NDK_FILENAME -ANDROID_NDK_PATH=$GODOT_BUILD_TOOLS_PATH/$ANDROID_NDK_DIR -ANDROID_NDK_MD5=19af543b068bdb7f27787c2bc69aba7f - -echo -echo "Download and install Android development tools ..." -echo - -if [ ! -e $ANDROID_SDK_FILENAME ]; then - echo "Downloading: Android SDK ..." - wget $ANDROID_SDK_URL -else - echo $ANDROID_SDK_SHA1 $ANDROID_SDK_FILENAME > $ANDROID_SDK_FILENAME.sha1 - sha1sum --check --strict $ANDROID_SDK_FILENAME.sha1 - if [ ! $? -eq 0 ]; then - echo "Downloading: Android SDK ..." - wget $ANDROID_SDK_URL - fi -fi - -if [ ! -d $ANDROID_SDK_DIR ]; then - tar -xvzf $ANDROID_SDK_FILENAME -fi - -if [ ! -e $ANDROID_NDK_FILENAME ]; then - echo "Downloading: Android NDK ..." - wget $ANDROID_NDK_URL -else - echo $ANDROID_NDK_MD5 $ANDROID_NDK_FILENAME > $ANDROID_NDK_FILENAME.md5 - md5sum --check --strict $ANDROID_NDK_FILENAME.md5 - if [ ! $? -eq 0 ]; then - echo "Downloading: Android NDK ..." - wget $ANDROID_NDK_URL - fi -fi - -if [ ! -d $ANDROID_NDK_DIR ]; then - chmod a+x $ANDROID_NDK_FILENAME - ./$ANDROID_NDK_FILENAME - echo -fi - -cd $ANDROID_SDK_DIR/tools -chmod a+x android - -if ! ./android list target | grep -q 'android-19'; then - echo "Installing: Android Tools ..." - echo y | ./android update sdk --no-ui --all --filter "platform-tools,android-19,build-tools-19.1.0,\ - extra-android-m2repository,extra-android-support,extra-google-google_play_services,extra-google-m2repository,\ - extra-google-play_apk_expansion,extra-google-play_billing,extra-google-play_licensing" -fi - -EXPORT_VAL="export ANDROID_HOME=$ANDROID_SDK_PATH" -if ! grep -q "^$EXPORT_VAL" $BASH_RC; then - echo $EXPORT_VAL >> ~/.bashrc -fi - - -EXPORT_VAL="export ANDROID_NDK_ROOT=$ANDROID_NDK_PATH" -if ! grep -q "^$EXPORT_VAL" $BASH_RC; then - echo $EXPORT_VAL >> ~/.bashrc -fi - -EXPORT_VAL="export PATH=$PATH:$ANDROID_SDK_PATH/tools" -if ! grep -q "^export PATH=.*$ANDROID_SDK_PATH/tools.*" $BASH_RC; then - echo $EXPORT_VAL >> ~/.bashrc -fi - -echo -echo "Done!" -echo
\ No newline at end of file diff --git a/misc/dist/linux/godot.6 b/misc/dist/linux/godot.6 index 4860c7b5a8..00d19c5178 100644 --- a/misc/dist/linux/godot.6 +++ b/misc/dist/linux/godot.6 @@ -1,4 +1,4 @@ -.TH GODOT "6" "March 2019" "godot 3.2" "Games" +.TH GODOT "6" "January 2020" "godot 4.0" "Games" .SH NAME godot \- multi\-platform 2D and 3D game engine with a feature\-rich editor .SH SYNOPSIS @@ -85,6 +85,12 @@ Force low\-DPI mode (macOS and Windows only). .TP \fB\-\-no\-window\fR Disable window creation (Windows only). Useful together with \fB\-\-script\fR. +.TP +\fB\-\-enable\-vsync\-via\-compositor\fR +When vsync is enabled, vsync via the OS' window compositor (Windows only). +.TP +\fB\-\-disable\-vsync\-via\-compositor\fR +Disable vsync via the OS' window compositor (Windows only). .SS "Debug options:" .TP \fB\-d\fR, \fB\-\-debug\fR @@ -130,11 +136,16 @@ Run a script. \fB\-\-check\-only\fR Only parse for errors and quit (use with --script). .TP -\fB\-\-export\fR <target> -Export the project using the given export target. Export only main pack if path ends with .pck or .zip. +\fB\-\-export\fR <preset> <path> +Export the project using the given preset and matching release template. The preset name should match one defined in export_presets.cfg. +.br +<path> should be absolute or relative to the project directory, and include the filename for the binary (e.g. 'builds/game.exe'). The target directory should exist. +.TP +\fB\-\-export\-debug\fR <preset> <path> +Same as \-\-export, but using the debug template. .TP -\fB\-\-export\-debug\fR <target> -Like \-\-export, but use debug template. +\fB\-\-export\-pack\fR <preset> <path> +Same as \-\-export, but only export the game pack for the given preset. The <path> extension determines whether it will be in PCK or ZIP format. .TP \fB\-\-doctool\fR <path> Dump the engine API reference to the given <path> in XML format, merging if existing files are found. @@ -143,7 +154,7 @@ Dump the engine API reference to the given <path> in XML format, merging if exis Disallow dumping the base types (used with \fB\-\-doctool\fR). .TP \fB\-\-build\-solutions\fR -Build the scripting solutions (e.g. for C# projects). +Build the scripting solutions (e.g. for C# projects). Implies \-\-editor and requires a valid project to edit. .TP \fB\-\-gdnative\-generate\-json\-api\fR Generate JSON dump of the Godot API for GDNative bindings. @@ -179,5 +190,5 @@ Godot Engine is a free and open source project and welcomes any kind of contributions. In particular, you can report issues or make suggestions on Godot's issue tracker at \fIhttps://github.com/godotengine/godot/issues\fR. .SH AUTHOR -Man page written by Rémi Verschelde <akien@godotengine.org> on behalf of the +Man page written by Rémi Verschelde <remi@godotengine.org> on behalf of the Godot Engine development team. diff --git a/misc/dist/linux/org.godotengine.Godot.appdata.xml b/misc/dist/linux/org.godotengine.Godot.appdata.xml index 45a4bbdd9e..2b30036006 100644 --- a/misc/dist/linux/org.godotengine.Godot.appdata.xml +++ b/misc/dist/linux/org.godotengine.Godot.appdata.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8"?> -<!-- Copyright 2017-2020 Rémi Verschelde <akien@godotengine.org> --> +<!-- Copyright 2017-2020 Rémi Verschelde <remi@godotengine.org> --> <component type="desktop"> <id>org.godotengine.Godot</id> <metadata_license>CC0-1.0</metadata_license> diff --git a/misc/dist/osx_tools.app/Contents/Info.plist b/misc/dist/osx_tools.app/Contents/Info.plist index 46d2d4cb6e..46550ba6c7 100755 --- a/misc/dist/osx_tools.app/Contents/Info.plist +++ b/misc/dist/osx_tools.app/Contents/Info.plist @@ -19,11 +19,11 @@ <key>CFBundlePackageType</key> <string>APPL</string> <key>CFBundleShortVersionString</key> - <string>3.2</string> + <string>4.0</string> <key>CFBundleSignature</key> <string>godot</string> <key>CFBundleVersion</key> - <string>3.2</string> + <string>4.0</string> <key>NSMicrophoneUsageDescription</key> <string>Microphone access is required to capture audio.</string> <key>NSCameraUsageDescription</key> diff --git a/misc/dist/shell/godot.bash-completion b/misc/dist/shell/godot.bash-completion new file mode 100644 index 0000000000..714b6758e3 --- /dev/null +++ b/misc/dist/shell/godot.bash-completion @@ -0,0 +1,124 @@ +#!/usr/bin/env bash + +# Bash completion for the Godot editor +# To use it, install this file in `/etc/bash_completion.d` then restart your shell. +# You can also `source` this file directly in your shell startup file. +# +# Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. +# Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). +# +# Permission is hereby granted, free of charge, to any person obtaining a copy +# of this software and associated documentation files (the "Software"), to deal +# in the Software without restriction, including without limitation the rights +# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +# copies of the Software, and to permit persons to whom the Software is +# furnished to do so, subject to the following conditions: +# +# The above copyright notice and this permission notice shall be included in all +# copies or substantial portions of the Software. +# +# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +# SOFTWARE. + +_complete_godot_options() { + # Since Bash doesn't support option descriptions in autocompletion, + # only display long options to be more descriptive. + # shellcheck disable=SC2207 + COMPREPLY=($(compgen -W " \ +--help +--version +--verbose +--quiet +--editor +--project-manager +--quit +--language +--path +--upwards +--main-pack +--render-thread +--remote-fs +--remote-fs-password +--audio-driver +--video-driver +--fullscreen +--maximized +--windowed +--always-on-top +--resolution +--position +--low-dpi +--no-window +--enable-vsync-via-compositor +--disable-vsync-via-compositor +--debug +--breakpoints +--profiling +--remote-debug +--debug-collisions +--debug-navigation +--frame-delay +--time-scale +--disable-render-loop +--disable-crash-handler +--fixed-fps +--print-fps +--script +--check-only +--export +--export-debug +--export-pack +--doctool +--no-docbase +--build-solutions +--gdnative-generate-json-api +--test +" -- "$1")) +} + +_complete_godot_bash() { + local cur="${COMP_WORDS[$COMP_CWORD]}" prev + + # Complete options or the positional argument. + if [[ $cur == -* ]]; then + _complete_godot_options "$cur" + else + local IFS=$'\n\t' + # shellcheck disable=SC2207 + COMPREPLY=($(compgen -f -X "!*.@(scn|tscn|escn|godot)" -- "$cur")) + fi + + # If the array is accessed out of bounds (which will happen for the first argument), + # `$prev` will be an empty string and won't match any of the conditions below. + prev="${COMP_WORDS[$((COMP_CWORD-1))]}" + + # Complete option values. + if [[ $prev == "--render-thread" ]]; then + local IFS=$' \n\t' + # shellcheck disable=SC2207 + COMPREPLY=($(compgen -W "unsafe safe separate" -- "$cur")) + elif [[ $prev == "--video-driver" ]]; then + local IFS=$' \n\t' + # shellcheck disable=SC2207 + COMPREPLY=($(compgen -W "GLES3 GLES2" -- "$cur")) + elif [[ $prev == "--path" || $prev == "--doctool" ]]; then + local IFS=$'\n\t' + # shellcheck disable=SC2207 + COMPREPLY=($(compgen -d -- "$cur")) + elif [[ $prev == "--main-pack" ]]; then + local IFS=$'\n\t' + # shellcheck disable=SC2207 + COMPREPLY=($(compgen -f -X "!*.@(pck|zip)" -- "$cur")) + elif [[ $prev == "-s" || $prev == "--script" ]]; then + local IFS=$'\n\t' + # shellcheck disable=SC2207 + COMPREPLY=($(compgen -f -X "!*.gd" -- "$cur")) + fi +} + +complete -o filenames -F _complete_godot_bash godot diff --git a/modules/assimp/editor_scene_importer_assimp.cpp b/modules/assimp/editor_scene_importer_assimp.cpp index 726f4c1ed0..69ab068648 100644 --- a/modules/assimp/editor_scene_importer_assimp.cpp +++ b/modules/assimp/editor_scene_importer_assimp.cpp @@ -188,22 +188,22 @@ template <> struct EditorSceneImporterAssetImportInterpolate<Quat> { Quat lerp(const Quat &a, const Quat &b, float c) const { - ERR_FAIL_COND_V(!a.is_normalized(), Quat()); - ERR_FAIL_COND_V(!b.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!a.is_normalized(), Quat(), "The quaternion \"a\" must be normalized."); + ERR_FAIL_COND_V_MSG(!b.is_normalized(), Quat(), "The quaternion \"b\" must be normalized."); return a.slerp(b, c).normalized(); } Quat catmull_rom(const Quat &p0, const Quat &p1, const Quat &p2, const Quat &p3, float c) { - ERR_FAIL_COND_V(!p1.is_normalized(), Quat()); - ERR_FAIL_COND_V(!p2.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!p1.is_normalized(), Quat(), "The quaternion \"p1\" must be normalized."); + ERR_FAIL_COND_V_MSG(!p2.is_normalized(), Quat(), "The quaternion \"p2\" must be normalized."); return p1.slerp(p2, c).normalized(); } Quat bezier(Quat start, Quat control_1, Quat control_2, Quat end, float t) { - ERR_FAIL_COND_V(!start.is_normalized(), Quat()); - ERR_FAIL_COND_V(!end.is_normalized(), Quat()); + ERR_FAIL_COND_V_MSG(!start.is_normalized(), Quat(), "The start quaternion must be normalized."); + ERR_FAIL_COND_V_MSG(!end.is_normalized(), Quat(), "The end quaternion must be normalized."); return start.slerp(end, t).normalized(); } @@ -389,7 +389,7 @@ EditorSceneImporterAssimp::_generate_scene(const String &p_path, aiScene *scene, Spatial *parent_node = parent_lookup->value(); ERR_FAIL_COND_V_MSG(parent_node == NULL, state.root, - "Parent node invalid even though lookup successful, out of ram?") + "Parent node invalid even though lookup successful, out of ram?"); if (spatial != state.root) { parent_node->add_child(spatial); diff --git a/modules/assimp/import_utils.h b/modules/assimp/import_utils.h index f4505249db..c522b01727 100644 --- a/modules/assimp/import_utils.h +++ b/modules/assimp/import_utils.h @@ -355,11 +355,13 @@ public: print_verbose("Open Asset Import: Loading embedded texture " + filename); if (tex->mHeight == 0) { if (tex->CheckFormat("png")) { + ERR_FAIL_COND_V(Image::_png_mem_loader_func == NULL, Ref<Image>()); Ref<Image> img = Image::_png_mem_loader_func((uint8_t *)tex->pcData, tex->mWidth); ERR_FAIL_COND_V(img.is_null(), Ref<Image>()); state.path_to_image_cache.insert(p_path, img); return img; } else if (tex->CheckFormat("jpg")) { + ERR_FAIL_COND_V(Image::_jpg_mem_loader_func == NULL, Ref<Image>()); Ref<Image> img = Image::_jpg_mem_loader_func((uint8_t *)tex->pcData, tex->mWidth); ERR_FAIL_COND_V(img.is_null(), Ref<Image>()); state.path_to_image_cache.insert(p_path, img); diff --git a/modules/bullet/area_bullet.cpp b/modules/bullet/area_bullet.cpp index 79ada54f0f..8d03a99556 100644 --- a/modules/bullet/area_bullet.cpp +++ b/modules/bullet/area_bullet.cpp @@ -167,7 +167,7 @@ bool AreaBullet::is_monitoring() const { } void AreaBullet::main_shape_changed() { - CRASH_COND(!get_main_shape()) + CRASH_COND(!get_main_shape()); btGhost->setCollisionShape(get_main_shape()); } @@ -245,7 +245,7 @@ void AreaBullet::set_param(PhysicsServer::AreaParameter p_param, const Variant & set_spOv_gravityPointAttenuation(p_value); break; default: - WARN_PRINTS("Area doesn't support this parameter in the Bullet backend: " + itos(p_param)); + WARN_PRINT("Area doesn't support this parameter in the Bullet backend: " + itos(p_param)); } } @@ -268,7 +268,7 @@ Variant AreaBullet::get_param(PhysicsServer::AreaParameter p_param) const { case PhysicsServer::AREA_PARAM_GRAVITY_POINT_ATTENUATION: return spOv_gravityPointAttenuation; default: - WARN_PRINTS("Area doesn't support this parameter in the Bullet backend: " + itos(p_param)); + WARN_PRINT("Area doesn't support this parameter in the Bullet backend: " + itos(p_param)); return Variant(); } } diff --git a/modules/bullet/bullet_physics_server.cpp b/modules/bullet/bullet_physics_server.cpp index 6662e130c8..e507987297 100644 --- a/modules/bullet/bullet_physics_server.cpp +++ b/modules/bullet/bullet_physics_server.cpp @@ -57,10 +57,10 @@ // <--------------- Joint creation asserts /// Assert the body is assigned to a space -#define JointAssertSpace(body, bIndex, ret) \ - if (!body->get_space()) { \ - ERR_PRINTS("Before create a joint the Body" + String(bIndex) + " must be added to a space!"); \ - return ret; \ +#define JointAssertSpace(body, bIndex, ret) \ + if (!body->get_space()) { \ + ERR_PRINT("Before create a joint the Body" + String(bIndex) + " must be added to a space!"); \ + return ret; \ } /// Assert the two bodies of joint are in the same space diff --git a/modules/bullet/doc_classes/BulletPhysicsDirectBodyState.xml b/modules/bullet/doc_classes/BulletPhysicsDirectBodyState.xml index 078bcc45a8..5ea1b810a1 100644 --- a/modules/bullet/doc_classes/BulletPhysicsDirectBodyState.xml +++ b/modules/bullet/doc_classes/BulletPhysicsDirectBodyState.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BulletPhysicsDirectBodyState" inherits="PhysicsDirectBodyState" category="Core" version="3.2"> +<class name="BulletPhysicsDirectBodyState" inherits="PhysicsDirectBodyState" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/bullet/doc_classes/BulletPhysicsServer.xml b/modules/bullet/doc_classes/BulletPhysicsServer.xml index 2a37f6af5e..af8fb3c02c 100644 --- a/modules/bullet/doc_classes/BulletPhysicsServer.xml +++ b/modules/bullet/doc_classes/BulletPhysicsServer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="BulletPhysicsServer" inherits="PhysicsServer" category="Core" version="3.2"> +<class name="BulletPhysicsServer" inherits="PhysicsServer" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/bullet/rigid_body_bullet.cpp b/modules/bullet/rigid_body_bullet.cpp index 1dd75eb8a9..dfc9647813 100644 --- a/modules/bullet/rigid_body_bullet.cpp +++ b/modules/bullet/rigid_body_bullet.cpp @@ -320,7 +320,7 @@ void RigidBodyBullet::destroy_kinematic_utilities() { } void RigidBodyBullet::main_shape_changed() { - CRASH_COND(!get_main_shape()) + CRASH_COND(!get_main_shape()); btBody->setCollisionShape(get_main_shape()); set_continuous_collision_detection(is_continuous_collision_detection_enabled()); // Reset } @@ -515,7 +515,7 @@ void RigidBodyBullet::set_param(PhysicsServer::BodyParameter p_param, real_t p_v scratch_space_override_modificator(); break; default: - WARN_PRINTS("Parameter " + itos(p_param) + " not supported by bullet. Value: " + itos(p_value)); + WARN_PRINT("Parameter " + itos(p_param) + " not supported by bullet. Value: " + itos(p_value)); } } @@ -536,7 +536,7 @@ real_t RigidBodyBullet::get_param(PhysicsServer::BodyParameter p_param) const { case PhysicsServer::BODY_PARAM_GRAVITY_SCALE: return gravity_scale; default: - WARN_PRINTS("Parameter " + itos(p_param) + " not supported by bullet"); + WARN_PRINT("Parameter " + itos(p_param) + " not supported by bullet"); return 0; } } @@ -619,7 +619,7 @@ Variant RigidBodyBullet::get_state(PhysicsServer::BodyState p_state) const { case PhysicsServer::BODY_STATE_CAN_SLEEP: return can_sleep; default: - WARN_PRINTS("This state " + itos(p_state) + " is not supported by Bullet"); + WARN_PRINT("This state " + itos(p_state) + " is not supported by Bullet"); return Variant(); } } @@ -795,12 +795,12 @@ Vector3 RigidBodyBullet::get_angular_velocity() const { void RigidBodyBullet::set_transform__bullet(const btTransform &p_global_transform) { if (mode == PhysicsServer::BODY_MODE_KINEMATIC) { - if (space) + if (space && space->get_delta_time() != 0) btBody->setLinearVelocity((p_global_transform.getOrigin() - btBody->getWorldTransform().getOrigin()) / space->get_delta_time()); // The kinematic use MotionState class godotMotionState->moveBody(p_global_transform); } else { - // Is necesasry to avoid wrong location on the rendering side on the next frame + // Is necessary to avoid wrong location on the rendering side on the next frame godotMotionState->setWorldTransform(p_global_transform); } CollisionObjectBullet::set_transform__bullet(p_global_transform); diff --git a/modules/bullet/space_bullet.cpp b/modules/bullet/space_bullet.cpp index 0f50d31611..762637ce75 100644 --- a/modules/bullet/space_bullet.cpp +++ b/modules/bullet/space_bullet.cpp @@ -110,7 +110,7 @@ bool BulletPhysicsDirectSpaceState::intersect_ray(const Vector3 &p_from, const V r_result.collider_id = gObj->get_instance_id(); r_result.collider = 0 == r_result.collider_id ? NULL : ObjectDB::get_instance(r_result.collider_id); } else { - WARN_PRINTS("The raycast performed has hit a collision object that is not part of Godot scene, please check it."); + WARN_PRINT("The raycast performed has hit a collision object that is not part of Godot scene, please check it."); } return true; } else { @@ -127,7 +127,7 @@ int BulletPhysicsDirectSpaceState::intersect_shape(const RID &p_shape, const Tra btCollisionShape *btShape = shape->create_bt_shape(p_xform.basis.get_scale_abs(), p_margin); if (!btShape->isConvex()) { bulletdelete(btShape); - ERR_PRINTS("The shape is not a convex shape, then is not supported: shape type: " + itos(shape->get_type())); + ERR_PRINT("The shape is not a convex shape, then is not supported: shape type: " + itos(shape->get_type())); return 0; } btConvexShape *btConvex = static_cast<btConvexShape *>(btShape); @@ -157,7 +157,7 @@ bool BulletPhysicsDirectSpaceState::cast_motion(const RID &p_shape, const Transf btCollisionShape *btShape = shape->create_bt_shape(p_xform.basis.get_scale(), p_margin); if (!btShape->isConvex()) { bulletdelete(btShape); - ERR_PRINTS("The shape is not a convex shape, then is not supported: shape type: " + itos(shape->get_type())); + ERR_PRINT("The shape is not a convex shape, then is not supported: shape type: " + itos(shape->get_type())); return false; } btConvexShape *bt_convex_shape = static_cast<btConvexShape *>(btShape); @@ -212,7 +212,7 @@ bool BulletPhysicsDirectSpaceState::collide_shape(RID p_shape, const Transform & btCollisionShape *btShape = shape->create_bt_shape(p_shape_xform.basis.get_scale_abs(), p_margin); if (!btShape->isConvex()) { bulletdelete(btShape); - ERR_PRINTS("The shape is not a convex shape, then is not supported: shape type: " + itos(shape->get_type())); + ERR_PRINT("The shape is not a convex shape, then is not supported: shape type: " + itos(shape->get_type())); return 0; } btConvexShape *btConvex = static_cast<btConvexShape *>(btShape); @@ -244,7 +244,7 @@ bool BulletPhysicsDirectSpaceState::rest_info(RID p_shape, const Transform &p_sh btCollisionShape *btShape = shape->create_bt_shape(p_shape_xform.basis.get_scale_abs(), p_margin); if (!btShape->isConvex()) { bulletdelete(btShape); - ERR_PRINTS("The shape is not a convex shape, then is not supported: shape type: " + itos(shape->get_type())); + ERR_PRINT("The shape is not a convex shape, then is not supported: shape type: " + itos(shape->get_type())); return 0; } btConvexShape *btConvex = static_cast<btConvexShape *>(btShape); @@ -389,7 +389,7 @@ void SpaceBullet::set_param(PhysicsServer::AreaParameter p_param, const Variant case PhysicsServer::AREA_PARAM_GRAVITY_POINT_ATTENUATION: break; default: - WARN_PRINTS("This set parameter (" + itos(p_param) + ") is ignored, the SpaceBullet doesn't support it."); + WARN_PRINT("This set parameter (" + itos(p_param) + ") is ignored, the SpaceBullet doesn't support it."); break; } } @@ -412,7 +412,7 @@ Variant SpaceBullet::get_param(PhysicsServer::AreaParameter p_param) { case PhysicsServer::AREA_PARAM_GRAVITY_POINT_ATTENUATION: return 0; default: - WARN_PRINTS("This get parameter (" + itos(p_param) + ") is ignored, the SpaceBullet doesn't support it."); + WARN_PRINT("This get parameter (" + itos(p_param) + ") is ignored, the SpaceBullet doesn't support it."); return Variant(); } } @@ -428,7 +428,7 @@ void SpaceBullet::set_param(PhysicsServer::SpaceParameter p_param, real_t p_valu case PhysicsServer::SPACE_PARAM_BODY_ANGULAR_VELOCITY_DAMP_RATIO: case PhysicsServer::SPACE_PARAM_CONSTRAINT_DEFAULT_BIAS: default: - WARN_PRINTS("This set parameter (" + itos(p_param) + ") is ignored, the SpaceBullet doesn't support it."); + WARN_PRINT("This set parameter (" + itos(p_param) + ") is ignored, the SpaceBullet doesn't support it."); break; } } @@ -444,7 +444,7 @@ real_t SpaceBullet::get_param(PhysicsServer::SpaceParameter p_param) { case PhysicsServer::SPACE_PARAM_BODY_ANGULAR_VELOCITY_DAMP_RATIO: case PhysicsServer::SPACE_PARAM_CONSTRAINT_DEFAULT_BIAS: default: - WARN_PRINTS("The SpaceBullet doesn't support this get parameter (" + itos(p_param) + "), 0 is returned."); + WARN_PRINT("The SpaceBullet doesn't support this get parameter (" + itos(p_param) + "), 0 is returned."); return 0.f; } } diff --git a/modules/csg/doc_classes/CSGBox.xml b/modules/csg/doc_classes/CSGBox.xml index 14f5a1952e..e2f0f8488a 100644 --- a/modules/csg/doc_classes/CSGBox.xml +++ b/modules/csg/doc_classes/CSGBox.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGBox" inherits="CSGPrimitive" category="Core" version="3.2"> +<class name="CSGBox" inherits="CSGPrimitive" version="4.0"> <brief_description> A CSG Box shape. </brief_description> diff --git a/modules/csg/doc_classes/CSGCombiner.xml b/modules/csg/doc_classes/CSGCombiner.xml index 51428b25f8..ab95d3c3ee 100644 --- a/modules/csg/doc_classes/CSGCombiner.xml +++ b/modules/csg/doc_classes/CSGCombiner.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGCombiner" inherits="CSGShape" category="Core" version="3.2"> +<class name="CSGCombiner" inherits="CSGShape" version="4.0"> <brief_description> A CSG node that allows you to combine other CSG modifiers. </brief_description> diff --git a/modules/csg/doc_classes/CSGCylinder.xml b/modules/csg/doc_classes/CSGCylinder.xml index 9fc0281887..2dd8c6a8d0 100644 --- a/modules/csg/doc_classes/CSGCylinder.xml +++ b/modules/csg/doc_classes/CSGCylinder.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGCylinder" inherits="CSGPrimitive" category="Core" version="3.2"> +<class name="CSGCylinder" inherits="CSGPrimitive" version="4.0"> <brief_description> A CSG Cylinder shape. </brief_description> diff --git a/modules/csg/doc_classes/CSGMesh.xml b/modules/csg/doc_classes/CSGMesh.xml index afe0bc262d..f1fe2c286b 100644 --- a/modules/csg/doc_classes/CSGMesh.xml +++ b/modules/csg/doc_classes/CSGMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGMesh" inherits="CSGPrimitive" category="Core" version="3.2"> +<class name="CSGMesh" inherits="CSGPrimitive" version="4.0"> <brief_description> A CSG Mesh shape that uses a mesh resource. </brief_description> @@ -12,9 +12,10 @@ </methods> <members> <member name="material" type="Material" setter="set_material" getter="get_material"> + The [Material] used in drawing the CSG shape. </member> <member name="mesh" type="Mesh" setter="set_mesh" getter="get_mesh"> - The mesh resource to use as a CSG shape. + The [Mesh] resource to use as a CSG shape. </member> </members> <constants> diff --git a/modules/csg/doc_classes/CSGPolygon.xml b/modules/csg/doc_classes/CSGPolygon.xml index 0ecee92cd5..64ae46c69a 100644 --- a/modules/csg/doc_classes/CSGPolygon.xml +++ b/modules/csg/doc_classes/CSGPolygon.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGPolygon" inherits="CSGPrimitive" category="Core" version="3.2"> +<class name="CSGPolygon" inherits="CSGPrimitive" version="4.0"> <brief_description> Extrudes a 2D polygon shape to create a 3D mesh. </brief_description> diff --git a/modules/csg/doc_classes/CSGPrimitive.xml b/modules/csg/doc_classes/CSGPrimitive.xml index 6c2f837637..ba395b7edd 100644 --- a/modules/csg/doc_classes/CSGPrimitive.xml +++ b/modules/csg/doc_classes/CSGPrimitive.xml @@ -1,9 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGPrimitive" inherits="CSGShape" category="Core" version="3.2"> +<class name="CSGPrimitive" inherits="CSGShape" version="4.0"> <brief_description> Base class for CSG primitives. </brief_description> <description> + Parent class for various CSG primitives. It contains code and functionality that is common between them. It cannot be used directly. Instead use one of the various classes that inherit from it. </description> <tutorials> </tutorials> diff --git a/modules/csg/doc_classes/CSGShape.xml b/modules/csg/doc_classes/CSGShape.xml index 755d8df67e..64a2fb1840 100644 --- a/modules/csg/doc_classes/CSGShape.xml +++ b/modules/csg/doc_classes/CSGShape.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGShape" inherits="GeometryInstance" category="Core" version="3.2"> +<class name="CSGShape" inherits="GeometryInstance" version="4.0"> <brief_description> The CSG base class. </brief_description> @@ -31,6 +31,7 @@ <return type="Array"> </return> <description> + Returns an [Array] with two elements, the first is the [Transform] of this node and the second is the root [Mesh] of this node. Only works when this node is the root shape. </description> </method> <method name="is_root_shape" qualifiers="const"> @@ -79,6 +80,7 @@ The operation that is performed on this shape. This is ignored for the first CSG child node as the operation is between this node and the previous child of this nodes parent. </member> <member name="snap" type="float" setter="set_snap" getter="get_snap" default="0.001"> + Snap makes the mesh snap to a given distance so that the faces of two meshes can be perfectly aligned. A lower value results in greater precision but may be harder to adjust. </member> <member name="use_collision" type="bool" setter="set_use_collision" getter="is_using_collision" default="false"> Adds a collision shape to the physics engine for our CSG shape. This will always act like a static body. Note that the collision shape is still active even if the CSG shape itself is hidden. diff --git a/modules/csg/doc_classes/CSGSphere.xml b/modules/csg/doc_classes/CSGSphere.xml index 714e725acb..847cc63586 100644 --- a/modules/csg/doc_classes/CSGSphere.xml +++ b/modules/csg/doc_classes/CSGSphere.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGSphere" inherits="CSGPrimitive" category="Core" version="3.2"> +<class name="CSGSphere" inherits="CSGPrimitive" version="4.0"> <brief_description> A CSG Sphere shape. </brief_description> diff --git a/modules/csg/doc_classes/CSGTorus.xml b/modules/csg/doc_classes/CSGTorus.xml index 5dc6bb8380..84a08edaf5 100644 --- a/modules/csg/doc_classes/CSGTorus.xml +++ b/modules/csg/doc_classes/CSGTorus.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="CSGTorus" inherits="CSGPrimitive" category="Core" version="3.2"> +<class name="CSGTorus" inherits="CSGPrimitive" version="4.0"> <brief_description> A CSG Torus shape. </brief_description> diff --git a/modules/enet/doc_classes/NetworkedMultiplayerENet.xml b/modules/enet/doc_classes/NetworkedMultiplayerENet.xml index 9509adfb18..76b3710e96 100644 --- a/modules/enet/doc_classes/NetworkedMultiplayerENet.xml +++ b/modules/enet/doc_classes/NetworkedMultiplayerENet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NetworkedMultiplayerENet" inherits="NetworkedMultiplayerPeer" category="Core" version="3.2"> +<class name="NetworkedMultiplayerENet" inherits="NetworkedMultiplayerPeer" version="4.0"> <brief_description> PacketPeer implementation using the [url=http://enet.bespin.org/index.html]ENet[/url] library. </brief_description> @@ -67,14 +67,14 @@ <return type="int"> </return> <description> - Returns the channel of the last packet fetched via [method PacketPeer.get_packet] + Returns the channel of the last packet fetched via [method PacketPeer.get_packet]. </description> </method> <method name="get_packet_channel" qualifiers="const"> <return type="int"> </return> <description> - Returns the channel of the next packet that will be retrieved via [method PacketPeer.get_packet] + Returns the channel of the next packet that will be retrieved via [method PacketPeer.get_packet]. </description> </method> <method name="get_peer_address" qualifiers="const"> diff --git a/modules/enet/networked_multiplayer_enet.cpp b/modules/enet/networked_multiplayer_enet.cpp index 61fc7688c5..21dd758391 100644 --- a/modules/enet/networked_multiplayer_enet.cpp +++ b/modules/enet/networked_multiplayer_enet.cpp @@ -479,23 +479,23 @@ void NetworkedMultiplayerENet::disconnect_peer(int p_peer, bool now) { ERR_FAIL_COND(!peer_map.has(p_peer)); if (now) { + int *id = (int *)peer_map[p_peer]->data; enet_peer_disconnect_now(peer_map[p_peer], 0); // enet_peer_disconnect_now doesn't generate ENET_EVENT_TYPE_DISCONNECT, // notify everyone else, send disconnect signal & remove from peer_map like in poll() + if (server_relay) { + for (Map<int, ENetPeer *>::Element *E = peer_map.front(); E; E = E->next()) { - int *id = NULL; - for (Map<int, ENetPeer *>::Element *E = peer_map.front(); E; E = E->next()) { + if (E->key() == p_peer) { + continue; + } - if (E->key() == p_peer) { - id = (int *)(E->get()->data); - continue; + ENetPacket *packet = enet_packet_create(NULL, 8, ENET_PACKET_FLAG_RELIABLE); + encode_uint32(SYSMSG_REMOVE_PEER, &packet->data[0]); + encode_uint32(p_peer, &packet->data[4]); + enet_peer_send(E->get(), SYSCH_CONFIG, packet); } - - ENetPacket *packet = enet_packet_create(NULL, 8, ENET_PACKET_FLAG_RELIABLE); - encode_uint32(SYSMSG_REMOVE_PEER, &packet->data[0]); - encode_uint32(p_peer, &packet->data[4]); - enet_peer_send(E->get(), SYSCH_CONFIG, packet); } if (id) diff --git a/modules/gdnative/SCsub b/modules/gdnative/SCsub index 0cdd585558..a18c75fa27 100644 --- a/modules/gdnative/SCsub +++ b/modules/gdnative/SCsub @@ -30,23 +30,3 @@ _, gensource = env_gdnative.CommandNoCache(['include/gdnative_api_struct.gen.h', env_gdnative.add_source_files(env.modules_sources, [gensource]) env.use_ptrcall = True - - -if ARGUMENTS.get('gdnative_wrapper', False): - gensource, = env_gdnative.CommandNoCache('gdnative_wrapper_code.gen.cpp', 'gdnative_api.json', run_in_subprocess(gdnative_builders.build_gdnative_wrapper_code)) - - gd_wrapper_env = env.Clone() - gd_wrapper_env.Prepend(CPPPATH=['#modules/gdnative/include/']) - - if gd_wrapper_env['use_lto']: - if not env.msvc: - gd_wrapper_env.Append(CCFLAGS=['-fno-lto']) - gd_wrapper_env.Append(LINKFLAGS=['-fno-lto']) - else: - gd_wrapper_env.Append(CCFLAGS=['/GL-']) - gd_wrapper_env.Append(LINKFLAGS=['/LTCG:OFF']) - - if not env.msvc: - gd_wrapper_env.Append(CCFLAGS=['-fPIC']) - - lib = gd_wrapper_env.add_library("#bin/gdnative_wrapper_code", [gensource]) diff --git a/modules/gdnative/doc_classes/@NativeScript.xml b/modules/gdnative/doc_classes/@NativeScript.xml index cb5de198ac..809b225e21 100644 --- a/modules/gdnative/doc_classes/@NativeScript.xml +++ b/modules/gdnative/doc_classes/@NativeScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="@NativeScript" category="Core" version="3.2"> +<class name="@NativeScript" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/doc_classes/ARVRInterfaceGDNative.xml b/modules/gdnative/doc_classes/ARVRInterfaceGDNative.xml index 47c2ee3358..e8405b64a3 100644 --- a/modules/gdnative/doc_classes/ARVRInterfaceGDNative.xml +++ b/modules/gdnative/doc_classes/ARVRInterfaceGDNative.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ARVRInterfaceGDNative" inherits="ARVRInterface" category="Core" version="3.2"> +<class name="ARVRInterfaceGDNative" inherits="ARVRInterface" version="4.0"> <brief_description> GDNative wrapper for an ARVR interface. </brief_description> diff --git a/modules/gdnative/doc_classes/GDNative.xml b/modules/gdnative/doc_classes/GDNative.xml index 8750ddc56d..b4b63bf04a 100644 --- a/modules/gdnative/doc_classes/GDNative.xml +++ b/modules/gdnative/doc_classes/GDNative.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GDNative" inherits="Reference" category="Core" version="3.2"> +<class name="GDNative" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/doc_classes/GDNativeLibrary.xml b/modules/gdnative/doc_classes/GDNativeLibrary.xml index aa48ab44f2..820f126dd1 100644 --- a/modules/gdnative/doc_classes/GDNativeLibrary.xml +++ b/modules/gdnative/doc_classes/GDNativeLibrary.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GDNativeLibrary" inherits="Resource" category="Core" version="3.2"> +<class name="GDNativeLibrary" inherits="Resource" version="4.0"> <brief_description> An external library containing functions or script classes to use in Godot. </brief_description> diff --git a/modules/gdnative/doc_classes/MultiplayerPeerGDNative.xml b/modules/gdnative/doc_classes/MultiplayerPeerGDNative.xml index b9a01672a6..9f33d32e81 100644 --- a/modules/gdnative/doc_classes/MultiplayerPeerGDNative.xml +++ b/modules/gdnative/doc_classes/MultiplayerPeerGDNative.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MultiplayerPeerGDNative" inherits="NetworkedMultiplayerPeer" category="Core" version="3.2"> +<class name="MultiplayerPeerGDNative" inherits="NetworkedMultiplayerPeer" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/doc_classes/NativeScript.xml b/modules/gdnative/doc_classes/NativeScript.xml index dc735546e3..b21d16a6fd 100644 --- a/modules/gdnative/doc_classes/NativeScript.xml +++ b/modules/gdnative/doc_classes/NativeScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NativeScript" inherits="Script" category="Core" version="3.2"> +<class name="NativeScript" inherits="Script" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/doc_classes/PacketPeerGDNative.xml b/modules/gdnative/doc_classes/PacketPeerGDNative.xml index acfb597cff..ea9869cc58 100644 --- a/modules/gdnative/doc_classes/PacketPeerGDNative.xml +++ b/modules/gdnative/doc_classes/PacketPeerGDNative.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PacketPeerGDNative" inherits="PacketPeer" category="Core" version="3.2"> +<class name="PacketPeerGDNative" inherits="PacketPeer" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/doc_classes/PluginScript.xml b/modules/gdnative/doc_classes/PluginScript.xml index 33b5f02bd4..9616101090 100644 --- a/modules/gdnative/doc_classes/PluginScript.xml +++ b/modules/gdnative/doc_classes/PluginScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="PluginScript" inherits="Script" category="Core" version="3.2"> +<class name="PluginScript" inherits="Script" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/doc_classes/StreamPeerGDNative.xml b/modules/gdnative/doc_classes/StreamPeerGDNative.xml index f7e0d76fdb..de76277fff 100644 --- a/modules/gdnative/doc_classes/StreamPeerGDNative.xml +++ b/modules/gdnative/doc_classes/StreamPeerGDNative.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="StreamPeerGDNative" inherits="StreamPeer" category="Core" version="3.2"> +<class name="StreamPeerGDNative" inherits="StreamPeer" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/doc_classes/VideoStreamGDNative.xml b/modules/gdnative/doc_classes/VideoStreamGDNative.xml index ed7678b7be..153988bad8 100644 --- a/modules/gdnative/doc_classes/VideoStreamGDNative.xml +++ b/modules/gdnative/doc_classes/VideoStreamGDNative.xml @@ -1,8 +1,11 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VideoStreamGDNative" inherits="VideoStream" category="Core" version="3.2"> +<class name="VideoStreamGDNative" inherits="VideoStream" version="4.0"> <brief_description> + [VideoStream] resource for for video formats implemented via GDNative. </brief_description> <description> + [VideoStream] resource for for video formats implemented via GDNative. + It can be used via [url=https://github.com/KidRigger/godot-videodecoder]godot-videodecoder[/url] which uses the [url=https://ffmpeg.org]FFmpeg[/url] library. </description> <tutorials> </tutorials> @@ -11,6 +14,7 @@ <return type="String"> </return> <description> + Returns the video file handled by this [VideoStreamGDNative]. </description> </method> <method name="set_file"> @@ -19,6 +23,7 @@ <argument index="0" name="file" type="String"> </argument> <description> + Sets the video file that this [VideoStreamGDNative] resource handles. The supported extensions depend on the GDNative plugins used to expose video formats. </description> </method> </methods> diff --git a/modules/gdnative/doc_classes/WebRTCDataChannelGDNative.xml b/modules/gdnative/doc_classes/WebRTCDataChannelGDNative.xml index ac18ec6020..f32a4f0a23 100644 --- a/modules/gdnative/doc_classes/WebRTCDataChannelGDNative.xml +++ b/modules/gdnative/doc_classes/WebRTCDataChannelGDNative.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebRTCDataChannelGDNative" inherits="WebRTCDataChannel" category="Core" version="3.2"> +<class name="WebRTCDataChannelGDNative" inherits="WebRTCDataChannel" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/doc_classes/WebRTCPeerConnectionGDNative.xml b/modules/gdnative/doc_classes/WebRTCPeerConnectionGDNative.xml index 44cb8e5db8..82f8633bb6 100644 --- a/modules/gdnative/doc_classes/WebRTCPeerConnectionGDNative.xml +++ b/modules/gdnative/doc_classes/WebRTCPeerConnectionGDNative.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebRTCPeerConnectionGDNative" inherits="WebRTCPeerConnection" category="Core" version="3.2"> +<class name="WebRTCPeerConnectionGDNative" inherits="WebRTCPeerConnection" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdnative/gdnative.cpp b/modules/gdnative/gdnative.cpp index d9dc256ac0..1571b821a5 100644 --- a/modules/gdnative/gdnative.cpp +++ b/modules/gdnative/gdnative.cpp @@ -339,7 +339,7 @@ bool GDNative::initialize() { if (err || !library_init) { OS::get_singleton()->close_dynamic_library(native_handle); native_handle = NULL; - ERR_PRINTS("Failed to obtain " + library->get_symbol_prefix() + "gdnative_init symbol"); + ERR_PRINT("Failed to obtain " + library->get_symbol_prefix() + "gdnative_init symbol"); return false; } diff --git a/modules/gdnative/gdnative_builders.py b/modules/gdnative/gdnative_builders.py index 20c1a2233c..0d95a65b7e 100644 --- a/modules/gdnative/gdnative_builders.py +++ b/modules/gdnative/gdnative_builders.py @@ -12,30 +12,6 @@ def _spaced(e): def _build_gdnative_api_struct_header(api): - gdnative_api_init_macro = [ - '\textern const godot_gdnative_core_api_struct *_gdnative_wrapper_api_struct;' - ] - - for ext in api['extensions']: - name = ext['name'] - gdnative_api_init_macro.append( - '\textern const godot_gdnative_ext_{0}_api_struct *_gdnative_wrapper_{0}_api_struct;'.format(name)) - - gdnative_api_init_macro.append('\t_gdnative_wrapper_api_struct = options->api_struct;') - gdnative_api_init_macro.append('\tfor (unsigned int i = 0; i < _gdnative_wrapper_api_struct->num_extensions; i++) { ') - gdnative_api_init_macro.append('\t\tswitch (_gdnative_wrapper_api_struct->extensions[i]->type) {') - - for ext in api['extensions']: - name = ext['name'] - gdnative_api_init_macro.append( - '\t\t\tcase GDNATIVE_EXT_%s:' % ext['type']) - gdnative_api_init_macro.append( - '\t\t\t\t_gdnative_wrapper_{0}_api_struct = (godot_gdnative_ext_{0}_api_struct *)' - ' _gdnative_wrapper_api_struct->extensions[i];'.format(name)) - gdnative_api_init_macro.append('\t\t\t\tbreak;') - gdnative_api_init_macro.append('\t\t}') - gdnative_api_init_macro.append('\t}') - out = [ '/* THIS FILE IS GENERATED DO NOT EDIT */', '#ifndef GODOT_GDNATIVE_API_STRUCT_H', @@ -49,8 +25,6 @@ def _build_gdnative_api_struct_header(api): '#include <pluginscript/godot_pluginscript.h>', '#include <videodecoder/godot_videodecoder.h>', '', - '#define GDNATIVE_API_INIT(options) do { \\\n' + ' \\\n'.join(gdnative_api_init_macro) + ' \\\n } while (0)', - '', '#ifdef __cplusplus', 'extern "C" {', '#endif', @@ -238,76 +212,5 @@ def build_gdnative_api_struct(target, source, env): fd.write(_build_gdnative_api_struct_source(api)) -def _build_gdnative_wrapper_code(api): - out = [ - '/* THIS FILE IS GENERATED DO NOT EDIT */', - '', - '#include <gdnative/gdnative.h>', - '#include <nativescript/godot_nativescript.h>', - '#include <pluginscript/godot_pluginscript.h>', - '#include <arvr/godot_arvr.h>', - '#include <videodecoder/godot_videodecoder.h>', - '', - '#include <gdnative_api_struct.gen.h>', - '', - '#ifdef __cplusplus', - 'extern "C" {', - '#endif', - '', - 'godot_gdnative_core_api_struct *_gdnative_wrapper_api_struct = 0;', - ] - - for ext in api['extensions']: - name = ext['name'] - out.append('godot_gdnative_ext_' + name + '_api_struct *_gdnative_wrapper_' + name + '_api_struct = 0;') - - out += [''] - - for funcdef in api['core']['api']: - args = ', '.join(['%s%s' % (_spaced(t), n) for t, n in funcdef['arguments']]) - out.append('%s%s(%s) {' % (_spaced(funcdef['return_type']), funcdef['name'], args)) - - args = ', '.join(['%s' % n for t, n in funcdef['arguments']]) - - return_line = '\treturn ' if funcdef['return_type'] != 'void' else '\t' - return_line += '_gdnative_wrapper_api_struct->' + funcdef['name'] + '(' + args + ');' - - out.append(return_line) - out.append('}') - out.append('') - - for ext in api['extensions']: - name = ext['name'] - for funcdef in ext['api']: - args = ', '.join(['%s%s' % (_spaced(t), n) for t, n in funcdef['arguments']]) - out.append('%s%s(%s) {' % (_spaced(funcdef['return_type']), funcdef['name'], args)) - - args = ', '.join(['%s' % n for t, n in funcdef['arguments']]) - - return_line = '\treturn ' if funcdef['return_type'] != 'void' else '\t' - return_line += '_gdnative_wrapper_' + name + '_api_struct->' + funcdef['name'] + '(' + args + ');' - - out.append(return_line) - out.append('}') - out.append('') - - out += [ - '#ifdef __cplusplus', - '}', - '#endif' - ] - - return '\n'.join(out) - - -def build_gdnative_wrapper_code(target, source, env): - with open(source[0], 'r') as fd: - api = json.load(fd) - - wrapper_file = target[0] - with open(wrapper_file, 'w') as fd: - fd.write(_build_gdnative_wrapper_code(api)) - - if __name__ == '__main__': subprocess_main(globals()) diff --git a/modules/gdnative/include/pluginscript/godot_pluginscript.h b/modules/gdnative/include/pluginscript/godot_pluginscript.h index 2c2528b8b9..e8822fc1ec 100644 --- a/modules/gdnative/include/pluginscript/godot_pluginscript.h +++ b/modules/gdnative/include/pluginscript/godot_pluginscript.h @@ -57,9 +57,6 @@ typedef struct { int p_argcount, godot_variant_call_error *r_error); void (*notification)(godot_pluginscript_instance_data *p_data, int p_notification); - // TODO: could this rpc mode stuff be moved to the godot_pluginscript_script_manifest ? - godot_method_rpc_mode (*get_rpc_mode)(godot_pluginscript_instance_data *p_data, const godot_string *p_method); - godot_method_rpc_mode (*get_rset_mode)(godot_pluginscript_instance_data *p_data, const godot_string *p_variable); //this is used by script languages that keep a reference counter of their own //you can make make Ref<> not die when it reaches zero, so deleting the reference diff --git a/modules/gdnative/nativescript/nativescript.cpp b/modules/gdnative/nativescript/nativescript.cpp index 7a5a7bbc3a..8b06af6c7b 100644 --- a/modules/gdnative/nativescript/nativescript.cpp +++ b/modules/gdnative/nativescript/nativescript.cpp @@ -746,7 +746,7 @@ void NativeScriptInstance::notification(int p_notification) { #ifdef DEBUG_ENABLED if (p_notification == MainLoop::NOTIFICATION_CRASH) { if (current_method_call != StringName("")) { - ERR_PRINTS("NativeScriptInstance detected crash on method: " + current_method_call); + ERR_PRINT("NativeScriptInstance detected crash on method: " + current_method_call); current_method_call = ""; } } diff --git a/modules/gdnative/pluginscript/pluginscript_instance.cpp b/modules/gdnative/pluginscript/pluginscript_instance.cpp index 97897870ba..c64a00a4d9 100644 --- a/modules/gdnative/pluginscript/pluginscript_instance.cpp +++ b/modules/gdnative/pluginscript/pluginscript_instance.cpp @@ -28,11 +28,13 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ +#include "pluginscript_instance.h" + // Godot imports #include "core/os/os.h" #include "core/variant.h" + // PluginScript imports -#include "pluginscript_instance.h" #include "pluginscript_language.h" #include "pluginscript_script.h" @@ -89,51 +91,6 @@ Variant PluginScriptInstance::call(const StringName &p_method, const Variant **p return var_ret; } -#if 0 // TODO: Don't rely on default implementations provided by ScriptInstance ? -void PluginScriptInstance::call_multilevel(const StringName& p_method,const Variant** p_args,int p_argcount) { - -#if 0 - PluginScript *sptr=script.ptr(); - Variant::CallError ce; - - while(sptr) { - Map<StringName,GDFunction*>::Element *E = sptr->member_functions.find(p_method); - if (E) { - E->get()->call(this,p_args,p_argcount,ce); - } - sptr = sptr->_base; - } -#endif - -} - -#if 0 -void PluginScriptInstance::_ml_call_reversed(PluginScript *sptr,const StringName& p_method,const Variant** p_args,int p_argcount) { - - if (sptr->_base) - _ml_call_reversed(sptr->_base,p_method,p_args,p_argcount); - - Variant::CallError ce; - - Map<StringName,GDFunction*>::Element *E = sptr->member_functions.find(p_method); - if (E) { - E->get()->call(this,p_args,p_argcount,ce); - } - -} -#endif - - -void PluginScriptInstance::call_multilevel_reversed(const StringName& p_method,const Variant** p_args,int p_argcount) { - -#if 0 - if (script.ptr()) { - _ml_call_reversed(script.ptr(),p_method,p_args,p_argcount); - } -#endif -} -#endif // Multilevel stuff - void PluginScriptInstance::notification(int p_notification) { _desc->notification(_data, p_notification); } diff --git a/modules/gdnative/pluginscript/pluginscript_instance.h b/modules/gdnative/pluginscript/pluginscript_instance.h index d92d3ace77..dc1229a44d 100644 --- a/modules/gdnative/pluginscript/pluginscript_instance.h +++ b/modules/gdnative/pluginscript/pluginscript_instance.h @@ -33,6 +33,7 @@ // Godot imports #include "core/script_language.h" + // PluginScript imports #include <pluginscript/godot_pluginscript.h> @@ -60,13 +61,12 @@ public: virtual bool has_method(const StringName &p_method) const; virtual Variant call(const StringName &p_method, const Variant **p_args, int p_argcount, Variant::CallError &r_error); -#if 0 - // Rely on default implementations provided by ScriptInstance for the moment. - // Note that multilevel call could be removed in 3.0 release, so stay tuned - // (see https://godotengine.org/qa/9244/can-override-the-_ready-and-_process-functions-child-classes) - virtual void call_multilevel(const StringName& p_method,const Variant** p_args,int p_argcount); - virtual void call_multilevel_reversed(const StringName& p_method,const Variant** p_args,int p_argcount); -#endif + + // Rely on default implementations provided by ScriptInstance for the moment. + // Note that multilevel call could be removed in 3.0 release, so stay tuned + // (see https://godotengine.org/qa/9244/can-override-the-_ready-and-_process-functions-child-classes) + //virtual void call_multilevel(const StringName& p_method,const Variant** p_args,int p_argcount); + //virtual void call_multilevel_reversed(const StringName& p_method,const Variant** p_args,int p_argcount); virtual void notification(int p_notification); diff --git a/modules/gdnative/register_types.cpp b/modules/gdnative/register_types.cpp index cb84c23e7a..4142f60ba6 100644 --- a/modules/gdnative/register_types.cpp +++ b/modules/gdnative/register_types.cpp @@ -278,7 +278,7 @@ void register_gdnative_types() { proc_ptr); if (err != OK) { - ERR_PRINTS("No " + lib->get_symbol_prefix() + "gdnative_singleton in \"" + singleton->get_library()->get_current_library_path() + "\" found"); + ERR_PRINT("No " + lib->get_symbol_prefix() + "gdnative_singleton in \"" + singleton->get_library()->get_current_library_path() + "\" found"); } else { singleton_gdnatives.push_back(singleton); ((void (*)())proc_ptr)(); diff --git a/modules/gdscript/doc_classes/@GDScript.xml b/modules/gdscript/doc_classes/@GDScript.xml index c4b7e4887e..b947d95fac 100644 --- a/modules/gdscript/doc_classes/@GDScript.xml +++ b/modules/gdscript/doc_classes/@GDScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="@GDScript" category="Core" version="3.2"> +<class name="@GDScript" version="4.0"> <brief_description> Built-in GDScript functions. </brief_description> @@ -39,12 +39,11 @@ <argument index="1" name="alpha" type="float" default="1.0"> </argument> <description> - Returns a color according to the standardised [code]name[/code] with [code]alpha[/code] ranging from 0 to 1. + Returns a color according to the standardized [code]name[/code] with [code]alpha[/code] ranging from 0 to 1. [codeblock] red = ColorN("red", 1) [/codeblock] - Supported color names: - "aliceblue", "antiquewhite", "aqua", "aquamarine", "azure", "beige", "bisque", "black", "blanchedalmond", "blue", "blueviolet", "brown", "burlywood", "cadetblue", "chartreuse", "chocolate", "coral", "cornflower", "cornsilk", "crimson", "cyan", "darkblue", "darkcyan", "darkgoldenrod", "darkgray", "darkgreen", "darkkhaki", "darkmagenta", "darkolivegreen", "darkorange", "darkorchid", "darkred", "darksalmon", "darkseagreen", "darkslateblue", "darkslategray", "darkturquoise", "darkviolet", "deeppink", "deepskyblue", "dimgray", "dodgerblue", "firebrick", "floralwhite", "forestgreen", "fuchsia", "gainsboro", "ghostwhite", "gold", "goldenrod", "gray", "webgray", "green", "webgreen", "greenyellow", "honeydew", "hotpink", "indianred", "indigo", "ivory", "khaki", "lavender", "lavenderblush", "lawngreen", "lemonchiffon", "lightblue", "lightcoral", "lightcyan", "lightgoldenrod", "lightgray", "lightgreen", "lightpink", "lightsalmon", "lightseagreen", "lightskyblue", "lightslategray", "lightsteelblue", "lightyellow", "lime", "limegreen", "linen", "magenta", "maroon", "webmaroon", "mediumaquamarine", "mediumblue", "mediumorchid", "mediumpurple", "mediumseagreen", "mediumslateblue", "mediumspringgreen", "mediumturquoise", "mediumvioletred", "midnightblue", "mintcream", "mistyrose", "moccasin", "navajowhite", "navyblue", "oldlace", "olive", "olivedrab", "orange", "orangered", "orchid", "palegoldenrod", "palegreen", "paleturquoise", "palevioletred", "papayawhip", "peachpuff", "peru", "pink", "plum", "powderblue", "purple", "webpurple", "rebeccapurple", "red", "rosybrown", "royalblue", "saddlebrown", "salmon", "sandybrown", "seagreen", "seashell", "sienna", "silver", "skyblue", "slateblue", "slategray", "snow", "springgreen", "steelblue", "tan", "teal", "thistle", "tomato", "turquoise", "violet", "wheat", "white", "whitesmoke", "yellow", "yellowgreen". + Supported color names are the same as the constants defined in [Color]. </description> </method> <method name="abs"> diff --git a/modules/gdscript/doc_classes/GDScript.xml b/modules/gdscript/doc_classes/GDScript.xml index 8e175a7ab8..5d0e93e117 100644 --- a/modules/gdscript/doc_classes/GDScript.xml +++ b/modules/gdscript/doc_classes/GDScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GDScript" inherits="Script" category="Core" version="3.2"> +<class name="GDScript" inherits="Script" version="4.0"> <brief_description> A script implemented in the GDScript programming language. </brief_description> diff --git a/modules/gdscript/doc_classes/GDScriptFunctionState.xml b/modules/gdscript/doc_classes/GDScriptFunctionState.xml index 690953108f..9a73764646 100644 --- a/modules/gdscript/doc_classes/GDScriptFunctionState.xml +++ b/modules/gdscript/doc_classes/GDScriptFunctionState.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GDScriptFunctionState" inherits="Reference" category="Core" version="3.2"> +<class name="GDScriptFunctionState" inherits="Reference" version="4.0"> <brief_description> State of a function call after yielding. </brief_description> @@ -33,7 +33,7 @@ </methods> <signals> <signal name="completed"> - <argument index="0" name="result" type="Nil"> + <argument index="0" name="result" type="Variant"> </argument> <description> </description> diff --git a/modules/gdscript/doc_classes/GDScriptNativeClass.xml b/modules/gdscript/doc_classes/GDScriptNativeClass.xml index 70583d47a7..0a8982de8e 100644 --- a/modules/gdscript/doc_classes/GDScriptNativeClass.xml +++ b/modules/gdscript/doc_classes/GDScriptNativeClass.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GDScriptNativeClass" inherits="Reference" category="Core" version="3.2"> +<class name="GDScriptNativeClass" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/gdscript/gdscript.cpp b/modules/gdscript/gdscript.cpp index 8abf2ee7ca..a255b92257 100644 --- a/modules/gdscript/gdscript.cpp +++ b/modules/gdscript/gdscript.cpp @@ -320,7 +320,7 @@ ScriptInstance *GDScript::instance_create(Object *p_this) { if (!ClassDB::is_parent_class(p_this->get_class_name(), top->native->get_name())) { if (ScriptDebugger::get_singleton()) { - GDScriptLanguage::get_singleton()->debug_break_parse(get_path(), 0, "Script inherits from native type '" + String(top->native->get_name()) + "', so it can't be instanced in object of type: '" + p_this->get_class() + "'"); + GDScriptLanguage::get_singleton()->debug_break_parse(get_path(), 1, "Script inherits from native type '" + String(top->native->get_name()) + "', so it can't be instanced in object of type: '" + p_this->get_class() + "'"); } ERR_FAIL_V_MSG(NULL, "Script inherits from native type '" + String(top->native->get_name()) + "', so it can't be instanced in object of type '" + p_this->get_class() + "'" + "."); } @@ -915,14 +915,43 @@ GDScript::GDScript() : #endif } +void GDScript::_save_orphaned_subclasses() { + struct ClassRefWithName { + ObjectID id; + String fully_qualified_name; + }; + Vector<ClassRefWithName> weak_subclasses; + // collect subclasses ObjectID and name + for (Map<StringName, Ref<GDScript> >::Element *E = subclasses.front(); E; E = E->next()) { + E->get()->_owner = NULL; //bye, you are no longer owned cause I died + ClassRefWithName subclass; + subclass.id = E->get()->get_instance_id(); + subclass.fully_qualified_name = E->get()->fully_qualified_name; + weak_subclasses.push_back(subclass); + } + + // clear subclasses to allow unused subclasses to be deleted + subclasses.clear(); + // subclasses are also held by constants, clear those as well + constants.clear(); + + // keep orphan subclass only for subclasses that are still in use + for (int i = 0; i < weak_subclasses.size(); i++) { + ClassRefWithName subclass = weak_subclasses[i]; + Object *obj = ObjectDB::get_instance(subclass.id); + if (!obj) + continue; + // subclass is not released + GDScriptLanguage::get_singleton()->add_orphan_subclass(subclass.fully_qualified_name, subclass.id); + } +} + GDScript::~GDScript() { for (Map<StringName, GDScriptFunction *>::Element *E = member_functions.front(); E; E = E->next()) { memdelete(E->get()); } - for (Map<StringName, Ref<GDScript> >::Element *E = subclasses.front(); E; E = E->next()) { - E->get()->_owner = NULL; //bye, you are no longer owned cause I died - } + _save_orphaned_subclasses(); #ifdef DEBUG_ENABLED if (GDScriptLanguage::get_singleton()->lock) { @@ -2176,6 +2205,22 @@ GDScriptLanguage::~GDScriptLanguage() { singleton = NULL; } +void GDScriptLanguage::add_orphan_subclass(const String &p_qualified_name, const ObjectID &p_subclass) { + orphan_subclasses[p_qualified_name] = p_subclass; +} + +Ref<GDScript> GDScriptLanguage::get_orphan_subclass(const String &p_qualified_name) { + Map<String, ObjectID>::Element *orphan_subclass_element = orphan_subclasses.find(p_qualified_name); + if (!orphan_subclass_element) + return Ref<GDScript>(); + ObjectID orphan_subclass = orphan_subclass_element->get(); + Object *obj = ObjectDB::get_instance(orphan_subclass); + orphan_subclasses.erase(orphan_subclass_element); + if (!obj) + return Ref<GDScript>(); + return Ref<GDScript>(Object::cast_to<GDScript>(obj)); +} + /*************** RESOURCE ***************/ RES ResourceFormatLoaderGDScript::load(const String &p_path, const String &p_original_path, Error *r_error) { diff --git a/modules/gdscript/gdscript.h b/modules/gdscript/gdscript.h index 72389cdddc..4ae52238ce 100644 --- a/modules/gdscript/gdscript.h +++ b/modules/gdscript/gdscript.h @@ -111,6 +111,7 @@ class GDScript : public Script { String source; String path; String name; + String fully_qualified_name; SelfList<GDScript> script_list; GDScriptInstance *_create_instance(const Variant **p_args, int p_argcount, Object *p_owner, bool p_isref, Variant::CallError &r_error); @@ -131,6 +132,8 @@ class GDScript : public Script { bool _update_exports(); + void _save_orphaned_subclasses(); + protected: bool _get(const StringName &p_name, Variant &r_ret) const; bool _set(const StringName &p_name, const Variant &p_value); @@ -354,6 +357,8 @@ class GDScriptLanguage : public ScriptLanguage { bool profiling; uint64_t script_frame_time; + Map<String, ObjectID> orphan_subclasses; + public: int calls; @@ -505,6 +510,9 @@ public: virtual bool handles_global_class_type(const String &p_type) const; virtual String get_global_class_name(const String &p_path, String *r_base_type = NULL, String *r_icon_path = NULL) const; + void add_orphan_subclass(const String &p_qualified_name, const ObjectID &p_subclass); + Ref<GDScript> get_orphan_subclass(const String &p_qualified_name); + GDScriptLanguage(); ~GDScriptLanguage(); }; diff --git a/modules/gdscript/gdscript_compiler.cpp b/modules/gdscript/gdscript_compiler.cpp index 7b3175d9cd..fba1b992ec 100644 --- a/modules/gdscript/gdscript_compiler.cpp +++ b/modules/gdscript/gdscript_compiler.cpp @@ -2123,14 +2123,21 @@ void GDScriptCompiler::_make_scripts(GDScript *p_script, const GDScriptParser::C StringName name = p_class->subclasses[i]->name; Ref<GDScript> subclass; + String fully_qualified_name = p_script->fully_qualified_name + "::" + name; if (old_subclasses.has(name)) { subclass = old_subclasses[name]; } else { - subclass.instance(); + Ref<GDScript> orphan_subclass = GDScriptLanguage::get_singleton()->get_orphan_subclass(fully_qualified_name); + if (orphan_subclass.is_valid()) { + subclass = orphan_subclass; + } else { + subclass.instance(); + } } subclass->_owner = p_script; + subclass->fully_qualified_name = fully_qualified_name; p_script->subclasses.insert(name, subclass); _make_scripts(subclass.ptr(), p_class->subclasses[i], false); @@ -2149,6 +2156,9 @@ Error GDScriptCompiler::compile(const GDScriptParser *p_parser, GDScript *p_scri source = p_script->get_path(); + // The best fully qualified name for a base level script is its file path + p_script->fully_qualified_name = p_script->path; + // Create scripts for subclasses beforehand so they can be referenced _make_scripts(p_script, static_cast<const GDScriptParser::ClassNode *>(root), p_keep_state); diff --git a/modules/gdscript/gdscript_editor.cpp b/modules/gdscript/gdscript_editor.cpp index e2f2b7fc3b..65c61cb57c 100644 --- a/modules/gdscript/gdscript_editor.cpp +++ b/modules/gdscript/gdscript_editor.cpp @@ -335,7 +335,9 @@ void GDScriptLanguage::debug_get_stack_level_members(int p_level, List<String> * ScriptInstance *GDScriptLanguage::debug_get_stack_level_instance(int p_level) { - ERR_FAIL_COND_V(_debug_parse_err_line >= 0, NULL); + if (_debug_parse_err_line >= 0) + return NULL; + ERR_FAIL_INDEX_V(p_level, _debug_call_stack_pos, NULL); int l = _debug_call_stack_pos - p_level - 1; @@ -555,7 +557,7 @@ static String _get_visual_datatype(const PropertyInfo &p_info, bool p_isarg = tr } if (p_info.type == Variant::NIL) { if (p_isarg || (p_info.usage & PROPERTY_USAGE_NIL_IS_VARIANT)) { - return "var"; + return "Variant"; } else { return "void"; } @@ -1736,14 +1738,12 @@ static String _make_arguments_hint(const MethodInfo &p_info, int p_arg_idx) { for (const List<PropertyInfo>::Element *E = p_info.arguments.front(); E; E = E->next()) { if (i > 0) { arghint += ", "; - } else { - arghint += " "; } if (i == p_arg_idx) { arghint += String::chr(0xFFFF); } - arghint += _get_visual_datatype(E->get(), true) + " " + E->get().name; + arghint += E->get().name + ": " + _get_visual_datatype(E->get(), true); if (i - def_args >= 0) { arghint += String(" = ") + p_info.default_arguments[i - def_args].get_construct_string(); @@ -1759,8 +1759,6 @@ static String _make_arguments_hint(const MethodInfo &p_info, int p_arg_idx) { if (p_info.flags & METHOD_FLAG_VARARG) { if (p_info.arguments.size() > 0) { arghint += ", "; - } else { - arghint += " "; } if (p_arg_idx >= p_info.arguments.size()) { arghint += String::chr(0xFFFF); @@ -1770,9 +1768,6 @@ static String _make_arguments_hint(const MethodInfo &p_info, int p_arg_idx) { arghint += String::chr(0xFFFF); } } - if (p_info.arguments.size() > 0 || (p_info.flags & METHOD_FLAG_VARARG)) { - arghint += " "; - } arghint += ")"; @@ -1787,14 +1782,12 @@ static String _make_arguments_hint(const GDScriptParser::FunctionNode *p_functio for (int i = 0; i < p_function->arguments.size(); i++) { if (i > 0) { arghint += ", "; - } else { - arghint += " "; } if (i == p_arg_idx) { arghint += String::chr(0xFFFF); } - arghint += p_function->argument_types[i].to_string() + " " + p_function->arguments[i].operator String(); + arghint += p_function->arguments[i].operator String() + ": " + p_function->argument_types[i].to_string(); if (i - def_args >= 0) { String def_val = "<unknown>"; @@ -1818,9 +1811,6 @@ static String _make_arguments_hint(const GDScriptParser::FunctionNode *p_functio } } - if (p_function->arguments.size() > 0) { - arghint += " "; - } arghint += ")"; return arghint; diff --git a/modules/gdscript/gdscript_function.cpp b/modules/gdscript/gdscript_function.cpp index eef39da8b5..452b1933eb 100644 --- a/modules/gdscript/gdscript_function.cpp +++ b/modules/gdscript/gdscript_function.cpp @@ -67,23 +67,23 @@ Variant *GDScriptFunction::_get_variant(int p_address, GDScriptInstance *p_insta case ADDR_TYPE_CLASS_CONSTANT: { //todo change to index! - GDScript *o = p_script; + GDScript *s = p_script; #ifdef DEBUG_ENABLED ERR_FAIL_INDEX_V(address, _global_names_count, NULL); #endif const StringName *sn = &_global_names_ptr[address]; - while (o) { - GDScript *s = o; - while (s) { + while (s) { + GDScript *o = s; + while (o) { - Map<StringName, Variant>::Element *E = s->constants.find(*sn); + Map<StringName, Variant>::Element *E = o->constants.find(*sn); if (E) { return &E->get(); } - s = s->_base; + o = o->_owner; } - o = o->_owner; + s = s->_base; } ERR_FAIL_V_MSG(NULL, "GDScriptCompiler bug."); @@ -1550,10 +1550,8 @@ Variant GDScriptFunction::call(GDScriptInstance *p_instance, const Variant **p_a OPCODE_BREAK; } -// Enable for debugging -#if 0 +#if 0 // Enable for debugging. default: { - err_text = "Illegal opcode " + itos(_code_ptr[ip]) + " at address " + itos(ip); OPCODE_BREAK; } diff --git a/modules/gdscript/gdscript_function.h b/modules/gdscript/gdscript_function.h index 236ca720a2..ad95ebc543 100644 --- a/modules/gdscript/gdscript_function.h +++ b/modules/gdscript/gdscript_function.h @@ -76,14 +76,17 @@ struct GDScriptDataType { if (p_variant.get_type() != Variant::OBJECT) { return false; } + Object *obj = p_variant.operator Object *(); - if (obj) { - if (!ClassDB::is_parent_class(obj->get_class_name(), native_type)) { - // Try with underscore prefix - StringName underscore_native_type = "_" + native_type; - if (!ClassDB::is_parent_class(obj->get_class_name(), underscore_native_type)) { - return false; - } + if (!obj || !ObjectDB::instance_validate(obj)) { + return false; + } + + if (!ClassDB::is_parent_class(obj->get_class_name(), native_type)) { + // Try with underscore prefix + StringName underscore_native_type = "_" + native_type; + if (!ClassDB::is_parent_class(obj->get_class_name(), underscore_native_type)) { + return false; } } return true; @@ -96,7 +99,12 @@ struct GDScriptDataType { if (p_variant.get_type() != Variant::OBJECT) { return false; } + Object *obj = p_variant.operator Object *(); + if (!obj || !ObjectDB::instance_validate(obj)) { + return false; + } + Ref<Script> base = obj && obj->get_script_instance() ? obj->get_script_instance()->get_script() : NULL; bool valid = false; while (base.is_valid()) { diff --git a/modules/gdscript/gdscript_functions.cpp b/modules/gdscript/gdscript_functions.cpp index 01d62a1c62..c398633dc5 100644 --- a/modules/gdscript/gdscript_functions.cpp +++ b/modules/gdscript/gdscript_functions.cpp @@ -800,7 +800,7 @@ void GDScriptFunctions::call(Function p_func, const Variant **p_args, int p_arg_ } String message = *p_args[0]; - ERR_PRINTS(message); + ERR_PRINT(message); r_ret = Variant(); } break; case PUSH_WARNING: { @@ -814,7 +814,7 @@ void GDScriptFunctions::call(Function p_func, const Variant **p_args, int p_arg_ } String message = *p_args[0]; - WARN_PRINTS(message); + WARN_PRINT(message); r_ret = Variant(); } break; case VAR_TO_STR: { @@ -1260,7 +1260,7 @@ void GDScriptFunctions::call(Function p_func, const Variant **p_args, int p_arg_ if (err != OK) { r_ret = Variant(); - ERR_PRINTS(vformat("Error parsing JSON at line %s: %s", errl, errs)); + ERR_PRINT(vformat("Error parsing JSON at line %s: %s", errl, errs)); } } break; diff --git a/modules/gdscript/gdscript_parser.cpp b/modules/gdscript/gdscript_parser.cpp index dcf5d35e36..d125da5b79 100644 --- a/modules/gdscript/gdscript_parser.cpp +++ b/modules/gdscript/gdscript_parser.cpp @@ -1868,6 +1868,10 @@ GDScriptParser::Node *GDScriptParser::_reduce_expression(Node *p_node, bool p_to _set_error("Can't assign to constant", tokenizer->get_token_line() - 1); error_line = op->line; return op; + } else if (op->arguments[0]->type == Node::TYPE_SELF) { + _set_error("Can't assign to self.", op->line); + error_line = op->line; + return op; } if (op->arguments[0]->type == Node::TYPE_OPERATOR) { @@ -4741,10 +4745,6 @@ void GDScriptParser::_parse_class(ClassNode *p_class) { member.line = tokenizer->get_token_line(); member.usages = 0; member.rpc_mode = rpc_mode; -#ifdef TOOLS_ENABLED - Variant::CallError ce; - member.default_value = Variant::construct(member._export.type, NULL, 0, ce); -#endif if (current_class->constant_expressions.has(member.identifier)) { _set_error("A constant named \"" + String(member.identifier) + "\" already exists in this class (at line: " + @@ -4797,6 +4797,32 @@ void GDScriptParser::_parse_class(ClassNode *p_class) { } } + if (autoexport && member.data_type.has_type) { + if (member.data_type.kind == DataType::BUILTIN) { + member._export.type = member.data_type.builtin_type; + } else if (member.data_type.kind == DataType::NATIVE) { + if (ClassDB::is_parent_class(member.data_type.native_type, "Resource")) { + member._export.type = Variant::OBJECT; + member._export.hint = PROPERTY_HINT_RESOURCE_TYPE; + member._export.usage |= PROPERTY_USAGE_SCRIPT_VARIABLE; + member._export.hint_string = member.data_type.native_type; + member._export.class_name = member.data_type.native_type; + } else { + _set_error("Invalid export type. Only built-in and native resource types can be exported.", member.line); + return; + } + + } else { + _set_error("Invalid export type. Only built-in and native resource types can be exported.", member.line); + return; + } + } + +#ifdef TOOLS_ENABLED + Variant::CallError ce; + member.default_value = Variant::construct(member._export.type, NULL, 0, ce); +#endif + if (tokenizer->get_token() == GDScriptTokenizer::TK_OP_ASSIGN) { #ifdef DEBUG_ENABLED @@ -4930,27 +4956,6 @@ void GDScriptParser::_parse_class(ClassNode *p_class) { member.initial_assignment = op; } - if (autoexport && member.data_type.has_type) { - if (member.data_type.kind == DataType::BUILTIN) { - member._export.type = member.data_type.builtin_type; - } else if (member.data_type.kind == DataType::NATIVE) { - if (ClassDB::is_parent_class(member.data_type.native_type, "Resource")) { - member._export.type = Variant::OBJECT; - member._export.hint = PROPERTY_HINT_RESOURCE_TYPE; - member._export.usage |= PROPERTY_USAGE_SCRIPT_VARIABLE; - member._export.hint_string = member.data_type.native_type; - member._export.class_name = member.data_type.native_type; - } else { - _set_error("Invalid export type. Only built-in and native resource types can be exported.", member.line); - return; - } - - } else { - _set_error("Invalid export type. Only built-in and native resource types can be exported.", member.line); - return; - } - } - if (tokenizer->get_token() == GDScriptTokenizer::TK_PR_SETGET) { tokenizer->advance(); @@ -5403,12 +5408,12 @@ void GDScriptParser::_determine_inheritance(ClassNode *p_class, bool p_recursive ident += ("." + subclass); - if (base_script->get_subclasses().has(subclass)) { + if (find_subclass->get_subclasses().has(subclass)) { - find_subclass = base_script->get_subclasses()[subclass]; - } else if (base_script->get_constants().has(subclass)) { + find_subclass = find_subclass->get_subclasses()[subclass]; + } else if (find_subclass->get_constants().has(subclass)) { - Ref<GDScript> new_base_class = base_script->get_constants()[subclass]; + Ref<GDScript> new_base_class = find_subclass->get_constants()[subclass]; if (new_base_class.is_null()) { _set_error("Constant isn't a class: " + ident, p_class->line); return; @@ -6289,6 +6294,7 @@ GDScriptParser::DataType GDScriptParser::_reduce_node_type(Node *p_node) { node_type.has_type = true; node_type.kind = DataType::CLASS; node_type.class_type = current_class; + node_type.is_constant = true; } break; case Node::TYPE_IDENTIFIER: { IdentifierNode *id = static_cast<IdentifierNode *>(p_node); @@ -7046,12 +7052,10 @@ GDScriptParser::DataType GDScriptParser::_reduce_function_call_type(const Operat return_type = _type_from_property(mi.return_val, false); -#ifdef DEBUG_ENABLED // Check all arguments beforehand to solve warnings for (int i = 1; i < p_call->arguments.size(); i++) { _reduce_node_type(p_call->arguments[i]); } -#endif // DEBUG_ENABLED // Check arguments @@ -7079,12 +7083,10 @@ GDScriptParser::DataType GDScriptParser::_reduce_function_call_type(const Operat ERR_FAIL_V(DataType()); } -#ifdef DEBUG_ENABLED // Check all arguments beforehand to solve warnings for (int i = arg_id + 1; i < p_call->arguments.size(); i++) { _reduce_node_type(p_call->arguments[i]); } -#endif // DEBUG_ENABLED IdentifierNode *func_id = static_cast<IdentifierNode *>(p_call->arguments[arg_id]); callee_name = func_id->name; @@ -8210,12 +8212,10 @@ void GDScriptParser::_check_block_types(BlockNode *p_block) { _add_warning(GDScriptWarning::FUNCTION_MAY_YIELD, op->line, _find_function_name(static_cast<OperatorNode *>(op->arguments[1]))); } - bool type_match = check_types; #endif // DEBUG_ENABLED + bool type_match = lh_type.has_type && rh_type.has_type; if (check_types && !_is_type_compatible(lh_type, rh_type)) { -#ifdef DEBUG_ENABLED type_match = false; -#endif // DEBUG_ENABLED // Try supertype test if (_is_type_compatible(rh_type, lh_type)) { @@ -8247,9 +8247,7 @@ void GDScriptParser::_check_block_types(BlockNode *p_block) { op->arguments.write[1] = convert_call; -#ifdef DEBUG_ENABLED type_match = true; // Since we are converting, the type is matching -#endif // DEBUG_ENABLED } #ifdef DEBUG_ENABLED if (lh_type.builtin_type == Variant::INT && rh_type.builtin_type == Variant::REAL) { @@ -8262,10 +8260,8 @@ void GDScriptParser::_check_block_types(BlockNode *p_block) { if (!rh_type.has_type && (op->op != OperatorNode::OP_ASSIGN || lh_type.has_type || op->arguments[0]->type == Node::TYPE_OPERATOR)) { _mark_line_as_unsafe(op->line); } - op->datatype.has_type = type_match; -#else - op->datatype.has_type = false; #endif // DEBUG_ENABLED + op->datatype.has_type = type_match; } break; case OperatorNode::OP_CALL: case OperatorNode::OP_PARENT_CALL: { diff --git a/modules/gdscript/language_server/gdscript_extend_parser.cpp b/modules/gdscript/language_server/gdscript_extend_parser.cpp index c8ff471401..0f6f13944b 100644 --- a/modules/gdscript/language_server/gdscript_extend_parser.cpp +++ b/modules/gdscript/language_server/gdscript_extend_parser.cpp @@ -112,9 +112,10 @@ void ExtendGDScriptParser::update_document_links(const String &p_code) { FileAccessRef fs = FileAccess::create(FileAccess::ACCESS_RESOURCES); tokenizer.set_code(p_code); while (true) { - if (tokenizer.get_token() == GDScriptTokenizer::TK_EOF) { + GDScriptTokenizerText::Token token = tokenizer.get_token(); + if (token == GDScriptTokenizer::TK_EOF || token == GDScriptTokenizer::TK_ERROR) { break; - } else if (tokenizer.get_token() == GDScriptTokenizer::TK_CONSTANT) { + } else if (token == GDScriptTokenizer::TK_CONSTANT) { const Variant &const_val = tokenizer.get_token_constant(); if (const_val.get_type() == Variant::STRING) { String path = const_val; @@ -538,16 +539,16 @@ Error ExtendGDScriptParser::get_left_function_call(const lsp::Position &p_positi } while (c >= 0) { - const CharType &charactor = line[c]; - if (charactor == ')') { + const CharType &character = line[c]; + if (character == ')') { ++bracket_stack; - } else if (charactor == '(') { + } else if (character == '(') { --bracket_stack; if (bracket_stack < 0) { found = true; } } - if (bracket_stack <= 0 && charactor == ',') { + if (bracket_stack <= 0 && character == ',') { ++index; } --c; @@ -756,7 +757,7 @@ Dictionary ExtendGDScriptParser::dump_class_api(const GDScriptParser::ClassNode Array static_functions; for (int i = 0; i < p_class->static_functions.size(); ++i) { - static_functions.append(dump_function_api(p_class->functions[i])); + static_functions.append(dump_function_api(p_class->static_functions[i])); } class_api["static_functions"] = static_functions; diff --git a/modules/gdscript/language_server/gdscript_language_protocol.cpp b/modules/gdscript/language_server/gdscript_language_protocol.cpp index cff7653d3a..7133c6b4be 100644 --- a/modules/gdscript/language_server/gdscript_language_protocol.cpp +++ b/modules/gdscript/language_server/gdscript_language_protocol.cpp @@ -156,7 +156,7 @@ void GDScriptLanguageProtocol::poll() { server->poll(); } -Error GDScriptLanguageProtocol::start(int p_port) { +Error GDScriptLanguageProtocol::start(int p_port, const IP_Address &p_bind_ip) { if (server == NULL) { server = dynamic_cast<WebSocketServer *>(ClassDB::instance("WebSocketServer")); ERR_FAIL_COND_V(!server, FAILED); @@ -165,6 +165,7 @@ Error GDScriptLanguageProtocol::start(int p_port) { server->connect("client_connected", this, "on_client_connected"); server->connect("client_disconnected", this, "on_client_disconnected"); } + server->set_bind_ip(p_bind_ip); return server->listen(p_port); } diff --git a/modules/gdscript/language_server/gdscript_language_protocol.h b/modules/gdscript/language_server/gdscript_language_protocol.h index e45db274e9..52c680ab19 100644 --- a/modules/gdscript/language_server/gdscript_language_protocol.h +++ b/modules/gdscript/language_server/gdscript_language_protocol.h @@ -77,7 +77,7 @@ public: _FORCE_INLINE_ bool is_initialized() const { return _initialized; } void poll(); - Error start(int p_port); + Error start(int p_port, const IP_Address &p_bind_ip); void stop(); void notify_all_clients(const String &p_method, const Variant &p_params = Variant()); diff --git a/modules/gdscript/language_server/gdscript_language_server.cpp b/modules/gdscript/language_server/gdscript_language_server.cpp index 19bb3ed1ee..7170c63058 100644 --- a/modules/gdscript/language_server/gdscript_language_server.cpp +++ b/modules/gdscript/language_server/gdscript_language_server.cpp @@ -84,7 +84,7 @@ void GDScriptLanguageServer::thread_main(void *p_userdata) { void GDScriptLanguageServer::start() { port = (int)_EDITOR_GET("network/language_server/remote_port"); use_thread = (bool)_EDITOR_GET("network/language_server/use_thread"); - if (protocol.start(port) == OK) { + if (protocol.start(port, IP_Address("127.0.0.1")) == OK) { EditorNode::get_log()->add_message("--- GDScript language server started ---", EditorLog::MSG_TYPE_EDITOR); if (use_thread) { ERR_FAIL_COND(thread != NULL); diff --git a/modules/gridmap/doc_classes/GridMap.xml b/modules/gridmap/doc_classes/GridMap.xml index 3de971db6d..37ebb3e5d5 100644 --- a/modules/gridmap/doc_classes/GridMap.xml +++ b/modules/gridmap/doc_classes/GridMap.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="GridMap" inherits="Spatial" category="Core" version="3.2"> +<class name="GridMap" inherits="Spatial" version="4.0"> <brief_description> Node for 3D tile-based maps. </brief_description> diff --git a/modules/gridmap/grid_map.cpp b/modules/gridmap/grid_map.cpp index 8126c9338f..3d40220869 100644 --- a/modules/gridmap/grid_map.cpp +++ b/modules/gridmap/grid_map.cpp @@ -122,7 +122,7 @@ bool GridMap::_get(const StringName &p_name, Variant &r_ret) const { Array ret; ret.resize(baked_meshes.size()); for (int i = 0; i < baked_meshes.size(); i++) { - ret.push_back(baked_meshes[i].mesh); + ret[i] = baked_meshes[i].mesh; } r_ret = ret; diff --git a/modules/hdr/image_loader_hdr.cpp b/modules/hdr/image_loader_hdr.cpp index 4505df0f8f..3fa7266f1a 100644 --- a/modules/hdr/image_loader_hdr.cpp +++ b/modules/hdr/image_loader_hdr.cpp @@ -47,7 +47,7 @@ Error ImageLoaderHDR::load_image(Ref<Image> p_image, FileAccess *f, bool p_force if (line.begins_with("FORMAT=")) { // leave option to implement other commands ERR_FAIL_COND_V_MSG(line != "FORMAT=32-bit_rle_rgbe", ERR_FILE_UNRECOGNIZED, "Only 32-bit_rle_rgbe is supported for HDR files."); } else if (!line.begins_with("#")) { // not comment - WARN_PRINTS("Ignoring unsupported header information in HDR: " + line + "."); + WARN_PRINT("Ignoring unsupported header information in HDR: " + line + "."); } } diff --git a/modules/mbedtls/crypto_mbedtls.cpp b/modules/mbedtls/crypto_mbedtls.cpp index 9b072785af..2bd80064e3 100644 --- a/modules/mbedtls/crypto_mbedtls.cpp +++ b/modules/mbedtls/crypto_mbedtls.cpp @@ -182,7 +182,7 @@ CryptoMbedTLS::CryptoMbedTLS() { mbedtls_entropy_init(&entropy); int ret = mbedtls_ctr_drbg_seed(&ctr_drbg, mbedtls_entropy_func, &entropy, NULL, 0); if (ret != 0) { - ERR_PRINTS(" failed\n ! mbedtls_ctr_drbg_seed returned an error" + itos(ret)); + ERR_PRINT(" failed\n ! mbedtls_ctr_drbg_seed returned an error" + itos(ret)); } } @@ -267,7 +267,7 @@ Ref<X509Certificate> CryptoMbedTLS::generate_self_signed_certificate(Ref<CryptoK if (err != 0) { mbedtls_mpi_free(&serial); mbedtls_x509write_crt_free(&crt); - ERR_PRINTS("Generated invalid certificate: " + itos(err)); + ERR_PRINT("Generated invalid certificate: " + itos(err)); return NULL; } diff --git a/modules/mbedtls/stream_peer_mbedtls.cpp b/modules/mbedtls/stream_peer_mbedtls.cpp index b88d9e48a4..f06327e0d5 100755 --- a/modules/mbedtls/stream_peer_mbedtls.cpp +++ b/modules/mbedtls/stream_peer_mbedtls.cpp @@ -88,7 +88,7 @@ Error StreamPeerMbedTLS::_do_handshake() { while ((ret = mbedtls_ssl_handshake(ssl_ctx->get_context())) != 0) { if (ret != MBEDTLS_ERR_SSL_WANT_READ && ret != MBEDTLS_ERR_SSL_WANT_WRITE) { // An error occurred. - ERR_PRINTS("TLS handshake error: " + itos(ret)); + ERR_PRINT("TLS handshake error: " + itos(ret)); _print_error(ret); disconnect_from_stream(); status = STATUS_ERROR; diff --git a/modules/mobile_vr/doc_classes/MobileVRInterface.xml b/modules/mobile_vr/doc_classes/MobileVRInterface.xml index a132333a87..7552abe61d 100644 --- a/modules/mobile_vr/doc_classes/MobileVRInterface.xml +++ b/modules/mobile_vr/doc_classes/MobileVRInterface.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="MobileVRInterface" inherits="ARVRInterface" category="Core" version="3.2"> +<class name="MobileVRInterface" inherits="ARVRInterface" version="4.0"> <brief_description> Generic mobile VR implementation. </brief_description> diff --git a/modules/mono/class_db_api_json.cpp b/modules/mono/class_db_api_json.cpp index c1d6f4dccf..b04e53bd81 100644 --- a/modules/mono/class_db_api_json.cpp +++ b/modules/mono/class_db_api_json.cpp @@ -71,6 +71,13 @@ void class_db_api_to_json(const String &p_output_file, ClassDB::APIType p_api) { while ((k = t->method_map.next(k))) { + String name = k->operator String(); + + ERR_CONTINUE(name.empty()); + + if (name[0] == '_') + continue; // Ignore non-virtual methods that start with an underscore + snames.push_back(*k); } diff --git a/modules/mono/csharp_script.cpp b/modules/mono/csharp_script.cpp index d82e78d080..752fc9e2cc 100644 --- a/modules/mono/csharp_script.cpp +++ b/modules/mono/csharp_script.cpp @@ -106,7 +106,7 @@ Error CSharpLanguage::execute_file(const String &p_path) { void CSharpLanguage::init() { #ifdef DEBUG_METHODS_ENABLED - if (OS::get_singleton()->get_cmdline_args().find("--class_db_to_json")) { + if (OS::get_singleton()->get_cmdline_args().find("--class-db-json")) { class_db_api_to_json("user://class_db_api.json", ClassDB::API_CORE); #ifdef TOOLS_ENABLED class_db_api_to_json("user://class_db_api_editor.json", ClassDB::API_EDITOR); @@ -159,6 +159,19 @@ void CSharpLanguage::finish() { // Clear here, after finalizing all domains to make sure there is nothing else referencing the elements. script_bindings.clear(); +#ifdef DEBUG_ENABLED + for (Map<ObjectID, int>::Element *E = unsafe_object_references.front(); E; E = E->next()) { + const ObjectID &id = E->get(); + Object *obj = ObjectDB::get_instance(id); + + if (obj) { + ERR_PRINT("Leaked unsafe reference to object: " + obj->get_class() + ":" + itos(id)); + } else { + ERR_PRINT("Leaked unsafe reference to deleted object: " + itos(id)); + } + } +#endif + finalizing = false; } @@ -546,6 +559,7 @@ Vector<ScriptLanguage::StackInfo> CSharpLanguage::debug_get_current_stack_info() #ifdef DEBUG_ENABLED _TLS_RECURSION_GUARD_V_(Vector<StackInfo>()); + GD_MONO_SCOPE_THREAD_ATTACH; if (!gdmono->is_runtime_initialized() || !GDMono::get_singleton()->get_core_api_assembly() || !GDMonoCache::cached_data.corlib_cache_updated) return Vector<StackInfo>(); @@ -570,6 +584,7 @@ Vector<ScriptLanguage::StackInfo> CSharpLanguage::debug_get_current_stack_info() Vector<ScriptLanguage::StackInfo> CSharpLanguage::stack_trace_get_info(MonoObject *p_stack_trace) { _TLS_RECURSION_GUARD_V_(Vector<StackInfo>()); + GD_MONO_SCOPE_THREAD_ATTACH; MonoException *exc = NULL; @@ -615,6 +630,25 @@ Vector<ScriptLanguage::StackInfo> CSharpLanguage::stack_trace_get_info(MonoObjec } #endif +void CSharpLanguage::post_unsafe_reference(Object *p_obj) { +#ifdef DEBUG_ENABLED + SCOPED_MUTEX_LOCK(unsafe_object_references_lock); + ObjectID id = p_obj->get_instance_id(); + unsafe_object_references[id]++; +#endif +} + +void CSharpLanguage::pre_unsafe_unreference(Object *p_obj) { +#ifdef DEBUG_ENABLED + SCOPED_MUTEX_LOCK(unsafe_object_references_lock); + ObjectID id = p_obj->get_instance_id(); + Map<ObjectID, int>::Element *elem = unsafe_object_references.find(id); + ERR_FAIL_NULL(elem); + if (--elem->value() == 0) + unsafe_object_references.erase(elem); +#endif +} + void CSharpLanguage::frame() { if (gdmono && gdmono->is_runtime_initialized() && gdmono->get_core_api_assembly() != NULL) { @@ -659,6 +693,7 @@ void CSharpLanguage::reload_all_scripts() { #ifdef GD_MONO_HOT_RELOAD if (is_assembly_reloading_needed()) { + GD_MONO_SCOPE_THREAD_ATTACH; reload_assemblies(false); } #endif @@ -676,6 +711,7 @@ void CSharpLanguage::reload_tool_script(const Ref<Script> &p_script, bool p_soft #ifdef GD_MONO_HOT_RELOAD if (is_assembly_reloading_needed()) { + GD_MONO_SCOPE_THREAD_ATTACH; reload_assemblies(p_soft_reload); } #endif @@ -1044,7 +1080,7 @@ void CSharpLanguage::_load_scripts_metadata() { int err_line; Error json_err = JSON::parse(old_json, old_dict_var, err_str, err_line); if (json_err != OK) { - ERR_PRINTS("Failed to parse metadata file: '" + err_str + "' (" + String::num_int64(err_line) + ")."); + ERR_PRINT("Failed to parse metadata file: '" + err_str + "' (" + String::num_int64(err_line) + ")."); return; } @@ -1212,6 +1248,14 @@ CSharpLanguage::CSharpLanguage() { language_bind_mutex = Mutex::create(); #endif +#ifdef DEBUG_ENABLED +#ifdef NO_THREADS + unsafe_object_references_lock = NULL; +#else + unsafe_object_references_lock = Mutex::create(); +#endif +#endif + lang_idx = -1; scripts_metadata_invalidated = true; @@ -1240,6 +1284,13 @@ CSharpLanguage::~CSharpLanguage() { script_gchandle_release_mutex = NULL; } +#ifdef DEBUG_ENABLED + if (unsafe_object_references_lock) { + memdelete(unsafe_object_references_lock); + unsafe_object_references_lock = NULL; + } +#endif + singleton = NULL; } @@ -1286,6 +1337,7 @@ bool CSharpLanguage::setup_csharp_script_binding(CSharpScriptBinding &r_script_b // See: godot_icall_Reference_Dtor(MonoObject *p_obj, Object *p_ptr) ref->reference(); + CSharpLanguage::get_singleton()->post_unsafe_reference(ref); } return true; @@ -1325,6 +1377,8 @@ void CSharpLanguage::free_instance_binding_data(void *p_data) { if (finalizing) return; // inside CSharpLanguage::finish(), all the gchandle bindings are released there + GD_MONO_ASSERT_THREAD_ATTACHED; + { SCOPED_MUTEX_LOCK(language_bind_mutex); @@ -1351,6 +1405,7 @@ void CSharpLanguage::refcount_incremented_instance_binding(Object *p_object) { #ifdef DEBUG_ENABLED CRASH_COND(!ref_owner); + CRASH_COND(!p_object->has_script_instance_binding(get_language_index())); #endif void *data = p_object->get_script_instance_binding(get_language_index()); @@ -1363,6 +1418,8 @@ void CSharpLanguage::refcount_incremented_instance_binding(Object *p_object) { return; if (ref_owner->reference_get_count() > 1 && gchandle->is_weak()) { // The managed side also holds a reference, hence 1 instead of 0 + GD_MONO_SCOPE_THREAD_ATTACH; + // The reference count was increased after the managed side was the only one referencing our owner. // This means the owner is being referenced again by the unmanaged side, // so the owner must hold the managed side alive again to avoid it from being GCed. @@ -1384,6 +1441,7 @@ bool CSharpLanguage::refcount_decremented_instance_binding(Object *p_object) { #ifdef DEBUG_ENABLED CRASH_COND(!ref_owner); + CRASH_COND(!p_object->has_script_instance_binding(get_language_index())); #endif void *data = p_object->get_script_instance_binding(get_language_index()); @@ -1398,6 +1456,8 @@ bool CSharpLanguage::refcount_decremented_instance_binding(Object *p_object) { return refcount == 0; if (refcount == 1 && gchandle.is_valid() && !gchandle->is_weak()) { // The managed side also holds a reference, hence 1 instead of 0 + GD_MONO_SCOPE_THREAD_ATTACH; + // If owner owner is no longer referenced by the unmanaged side, // the managed instance takes responsibility of deleting the owner when GCed. @@ -1449,6 +1509,8 @@ bool CSharpInstance::set(const StringName &p_name, const Variant &p_value) { ERR_FAIL_COND_V(!script.is_valid(), false); + GD_MONO_SCOPE_THREAD_ATTACH; + MonoObject *mono_object = get_mono_object(); ERR_FAIL_NULL_V(mono_object, false); @@ -1501,6 +1563,8 @@ bool CSharpInstance::get(const StringName &p_name, Variant &r_ret) const { ERR_FAIL_COND_V(!script.is_valid(), false); + GD_MONO_SCOPE_THREAD_ATTACH; + MonoObject *mono_object = get_mono_object(); ERR_FAIL_NULL_V(mono_object, false); @@ -1594,6 +1658,8 @@ void CSharpInstance::get_property_list(List<PropertyInfo> *p_properties) const { ERR_FAIL_COND(!script.is_valid()); + GD_MONO_SCOPE_THREAD_ATTACH; + MonoObject *mono_object = get_mono_object(); ERR_FAIL_NULL(mono_object); @@ -1638,6 +1704,8 @@ bool CSharpInstance::has_method(const StringName &p_method) const { if (!script.is_valid()) return false; + GD_MONO_SCOPE_THREAD_ATTACH; + GDMonoClass *top = script->script_class; while (top && top != script->native) { @@ -1653,6 +1721,11 @@ bool CSharpInstance::has_method(const StringName &p_method) const { Variant CSharpInstance::call(const StringName &p_method, const Variant **p_args, int p_argcount, Variant::CallError &r_error) { + if (!script.is_valid()) + ERR_FAIL_V(Variant()); + + GD_MONO_SCOPE_THREAD_ATTACH; + MonoObject *mono_object = get_mono_object(); if (!mono_object) { @@ -1660,9 +1733,6 @@ Variant CSharpInstance::call(const StringName &p_method, const Variant **p_args, ERR_FAIL_V(Variant()); } - if (!script.is_valid()) - ERR_FAIL_V(Variant()); - GDMonoClass *top = script->script_class; while (top && top != script->native) { @@ -1690,6 +1760,8 @@ Variant CSharpInstance::call(const StringName &p_method, const Variant **p_args, void CSharpInstance::call_multilevel(const StringName &p_method, const Variant **p_args, int p_argcount) { + GD_MONO_SCOPE_THREAD_ATTACH; + if (script.is_valid()) { MonoObject *mono_object = get_mono_object(); @@ -1701,6 +1773,8 @@ void CSharpInstance::call_multilevel(const StringName &p_method, const Variant * void CSharpInstance::_call_multilevel(MonoObject *p_mono_object, const StringName &p_method, const Variant **p_args, int p_argcount) { + GD_MONO_ASSERT_THREAD_ATTACHED; + GDMonoClass *top = script->script_class; while (top && top != script->native) { @@ -1736,9 +1810,12 @@ bool CSharpInstance::_reference_owner_unsafe() { // See: _unreference_owner_unsafe() // May not me referenced yet, so we must use init_ref() instead of reference() - bool success = Object::cast_to<Reference>(owner)->init_ref(); - unsafe_referenced = success; - return success; + if (static_cast<Reference *>(owner)->init_ref()) { + CSharpLanguage::get_singleton()->post_unsafe_reference(owner); + unsafe_referenced = true; + } + + return unsafe_referenced; } bool CSharpInstance::_unreference_owner_unsafe() { @@ -1759,6 +1836,7 @@ bool CSharpInstance::_unreference_owner_unsafe() { // See: _reference_owner_unsafe() // Destroying the owner here means self destructing, so we defer the owner destruction to the caller. + CSharpLanguage::get_singleton()->pre_unsafe_unreference(owner); return static_cast<Reference *>(owner)->unreference(); } @@ -1859,6 +1937,8 @@ void CSharpInstance::refcount_incremented() { Reference *ref_owner = Object::cast_to<Reference>(owner); if (ref_owner->reference_get_count() > 1 && gchandle->is_weak()) { // The managed side also holds a reference, hence 1 instead of 0 + GD_MONO_SCOPE_THREAD_ATTACH; + // The reference count was increased after the managed side was the only one referencing our owner. // This means the owner is being referenced again by the unmanaged side, // so the owner must hold the managed side alive again to avoid it from being GCed. @@ -1882,6 +1962,8 @@ bool CSharpInstance::refcount_decremented() { int refcount = ref_owner->reference_get_count(); if (refcount == 1 && !gchandle->is_weak()) { // The managed side also holds a reference, hence 1 instead of 0 + GD_MONO_SCOPE_THREAD_ATTACH; + // If owner owner is no longer referenced by the unmanaged side, // the managed instance takes responsibility of deleting the owner when GCed. @@ -1922,6 +2004,8 @@ MultiplayerAPI::RPCMode CSharpInstance::_member_get_rpc_mode(IMonoClassMember *p MultiplayerAPI::RPCMode CSharpInstance::get_rpc_mode(const StringName &p_method) const { + GD_MONO_SCOPE_THREAD_ATTACH; + GDMonoClass *top = script->script_class; while (top && top != script->native) { @@ -1938,6 +2022,8 @@ MultiplayerAPI::RPCMode CSharpInstance::get_rpc_mode(const StringName &p_method) MultiplayerAPI::RPCMode CSharpInstance::get_rset_mode(const StringName &p_variable) const { + GD_MONO_SCOPE_THREAD_ATTACH; + GDMonoClass *top = script->script_class; while (top && top != script->native) { @@ -1959,6 +2045,8 @@ MultiplayerAPI::RPCMode CSharpInstance::get_rset_mode(const StringName &p_variab void CSharpInstance::notification(int p_notification) { + GD_MONO_SCOPE_THREAD_ATTACH; + if (p_notification == Object::NOTIFICATION_PREDELETE) { // When NOTIFICATION_PREDELETE is sent, we also take the chance to call Dispose(). // It's safe to call Dispose() multiple times and NOTIFICATION_PREDELETE is guaranteed @@ -1996,6 +2084,8 @@ void CSharpInstance::notification(int p_notification) { void CSharpInstance::_call_notification(int p_notification) { + GD_MONO_ASSERT_THREAD_ATTACHED; + MonoObject *mono_object = get_mono_object(); ERR_FAIL_NULL(mono_object); @@ -2020,6 +2110,8 @@ void CSharpInstance::_call_notification(int p_notification) { } String CSharpInstance::to_string(bool *r_valid) { + GD_MONO_SCOPE_THREAD_ATTACH; + MonoObject *mono_object = get_mono_object(); if (mono_object == NULL) { @@ -2068,6 +2160,8 @@ CSharpInstance::CSharpInstance() : CSharpInstance::~CSharpInstance() { + GD_MONO_SCOPE_THREAD_ATTACH; + destructing_script_instance = true; if (gchandle.is_valid()) { @@ -2099,6 +2193,17 @@ CSharpInstance::~CSharpInstance() { // Transfer ownership to an "instance binding" + Reference *ref_owner = static_cast<Reference *>(owner); + + // We will unreference the owner before referencing it again, so we need to keep it alive + Ref<Reference> scope_keep_owner_alive(ref_owner); + (void)scope_keep_owner_alive; + + // Unreference the owner here, before the new "instance binding" references it. + // Otherwise, the unsafe reference debug checks will incorrectly detect a bug. + bool die = _unreference_owner_unsafe(); + CRASH_COND(die == true); // `owner_keep_alive` holds a reference, so it can't die + void *data = owner->get_script_instance_binding(CSharpLanguage::get_singleton()->get_language_index()); CRASH_COND(data == NULL); @@ -2114,8 +2219,10 @@ CSharpInstance::~CSharpInstance() { } } - bool die = _unreference_owner_unsafe(); - CRASH_COND(die == true); // The "instance binding" should be holding a reference +#ifdef DEBUG_ENABLED + // The "instance binding" holds a reference so the refcount should be at least 2 before `scope_keep_owner_alive` goes out of scope + CRASH_COND(ref_owner->reference_get_count() <= 1); +#endif } if (script.is_valid() && owner) { @@ -2158,6 +2265,8 @@ void CSharpScript::_update_exports_values(Map<StringName, Variant> &values, List void CSharpScript::_update_member_info_no_exports() { if (exports_invalidated) { + GD_MONO_ASSERT_THREAD_ATTACHED; + exports_invalidated = false; member_info.clear(); @@ -2216,6 +2325,8 @@ bool CSharpScript::_update_exports() { bool changed = false; if (exports_invalidated) { + GD_MONO_SCOPE_THREAD_ATTACH; + exports_invalidated = false; changed = true; @@ -2243,7 +2354,11 @@ bool CSharpScript::_update_exports() { MonoException *ctor_exc = NULL; ctor->invoke(tmp_object, NULL, &ctor_exc); + Object *tmp_native = GDMonoMarshal::unbox<Object *>(CACHED_FIELD(GodotObject, ptr)->get_value(tmp_object)); + if (ctor_exc) { + // TODO: Should we free 'tmp_native' if the exception was thrown after its creation? + MonoGCHandle::free_handle(tmp_pinned_gchandle); tmp_object = NULL; @@ -2310,6 +2425,9 @@ bool CSharpScript::_update_exports() { top = top->get_parent_class(); } + // Need to check this here, before disposal + bool base_ref = Object::cast_to<Reference>(tmp_native) != NULL; + // Dispose the temporary managed instance MonoException *exc = NULL; @@ -2322,6 +2440,15 @@ bool CSharpScript::_update_exports() { MonoGCHandle::free_handle(tmp_pinned_gchandle); tmp_object = NULL; + + if (tmp_native && !base_ref) { + Node *node = Object::cast_to<Node>(tmp_native); + if (node && node->is_inside_tree()) { + ERR_PRINT("Temporary instance was added to the scene tree."); + } else { + memdelete(tmp_native); + } + } } placeholder_fallback_enabled = false; @@ -2352,6 +2479,8 @@ void CSharpScript::load_script_signals(GDMonoClass *p_class, GDMonoClass *p_nati // make sure this classes signals are empty when loading for the first time _signals.clear(); + GD_MONO_SCOPE_THREAD_ATTACH; + GDMonoClass *top = p_class; while (top && top != p_native_class) { const Vector<GDMonoClass *> &delegates = top->get_all_delegates(); @@ -2372,6 +2501,8 @@ void CSharpScript::load_script_signals(GDMonoClass *p_class, GDMonoClass *p_nati } bool CSharpScript::_get_signal(GDMonoClass *p_class, GDMonoClass *p_delegate, Vector<Argument> ¶ms) { + GD_MONO_ASSERT_THREAD_ATTACHED; + if (p_delegate->has_attribute(CACHED_CLASS(SignalAttribute))) { MonoType *raw_type = p_delegate->get_mono_type(); @@ -2391,7 +2522,7 @@ bool CSharpScript::_get_signal(GDMonoClass *p_class, GDMonoClass *p_delegate, Ve arg.type = GDMonoMarshal::managed_to_variant_type(types[i]); if (arg.type == Variant::NIL) { - ERR_PRINTS("Unknown type of signal parameter: '" + arg.name + "' in '" + p_class->get_full_name() + "'."); + ERR_PRINT("Unknown type of signal parameter: '" + arg.name + "' in '" + p_class->get_full_name() + "'."); return false; } @@ -2413,13 +2544,15 @@ bool CSharpScript::_get_signal(GDMonoClass *p_class, GDMonoClass *p_delegate, Ve */ bool CSharpScript::_get_member_export(IMonoClassMember *p_member, bool p_inspect_export, PropertyInfo &r_prop_info, bool &r_exported) { + GD_MONO_ASSERT_THREAD_ATTACHED; + // Goddammit, C++. All I wanted was some nested functions. #define MEMBER_FULL_QUALIFIED_NAME(m_member) \ (m_member->get_enclosing_class()->get_full_name() + "." + (String)m_member->get_name()) if (p_member->is_static()) { if (p_member->has_attribute(CACHED_CLASS(ExportAttribute))) - ERR_PRINTS("Cannot export member because it is static: '" + MEMBER_FULL_QUALIFIED_NAME(p_member) + "'."); + ERR_PRINT("Cannot export member because it is static: '" + MEMBER_FULL_QUALIFIED_NAME(p_member) + "'."); return false; } @@ -2442,12 +2575,12 @@ bool CSharpScript::_get_member_export(IMonoClassMember *p_member, bool p_inspect GDMonoProperty *property = static_cast<GDMonoProperty *>(p_member); if (!property->has_getter()) { if (exported) - ERR_PRINTS("Read-only property cannot be exported: '" + MEMBER_FULL_QUALIFIED_NAME(p_member) + "'."); + ERR_PRINT("Read-only property cannot be exported: '" + MEMBER_FULL_QUALIFIED_NAME(p_member) + "'."); return false; } if (!property->has_setter()) { if (exported) - ERR_PRINTS("Write-only property (without getter) cannot be exported: '" + MEMBER_FULL_QUALIFIED_NAME(p_member) + "'."); + ERR_PRINT("Write-only property (without getter) cannot be exported: '" + MEMBER_FULL_QUALIFIED_NAME(p_member) + "'."); return false; } } @@ -2466,7 +2599,7 @@ bool CSharpScript::_get_member_export(IMonoClassMember *p_member, bool p_inspect String hint_string; if (variant_type == Variant::NIL) { - ERR_PRINTS("Unknown exported member type: '" + MEMBER_FULL_QUALIFIED_NAME(p_member) + "'."); + ERR_PRINT("Unknown exported member type: '" + MEMBER_FULL_QUALIFIED_NAME(p_member) + "'."); return false; } @@ -2491,6 +2624,8 @@ bool CSharpScript::_get_member_export(IMonoClassMember *p_member, bool p_inspect int CSharpScript::_try_get_member_export_hint(IMonoClassMember *p_member, ManagedType p_type, Variant::Type p_variant_type, bool p_allow_generics, PropertyHint &r_hint, String &r_hint_string) { + GD_MONO_ASSERT_THREAD_ATTACHED; + if (p_variant_type == Variant::INT && p_type.type_encoding == MONO_TYPE_VALUETYPE && mono_class_is_enum(p_type.type_class->get_mono_ptr())) { r_hint = PROPERTY_HINT_ENUM; @@ -2600,6 +2735,8 @@ Variant CSharpScript::call(const StringName &p_method, const Variant **p_args, i return Variant(); } + GD_MONO_SCOPE_THREAD_ATTACH; + GDMonoClass *top = script_class; while (top && top != native) { @@ -2754,7 +2891,7 @@ bool CSharpScript::can_instance() const { "Compile", ProjectSettings::get_singleton()->globalize_path(get_path())); } else { - ERR_PRINTS("C# project could not be created; cannot add file: '" + get_path() + "'."); + ERR_PRINT("C# project could not be created; cannot add file: '" + get_path() + "'."); } } } @@ -2792,6 +2929,8 @@ StringName CSharpScript::get_instance_base_type() const { CSharpInstance *CSharpScript::_create_instance(const Variant **p_args, int p_argcount, Object *p_owner, bool p_isref, Variant::CallError &r_error) { + GD_MONO_ASSERT_THREAD_ATTACHED; + /* STEP 1, CREATE */ // Search the constructor first, to fail with an error if it's not found before allocating anything else. @@ -2886,12 +3025,14 @@ Variant CSharpScript::_new(const Variant **p_args, int p_argcount, Variant::Call } r_error.error = Variant::CallError::CALL_OK; - REF ref; ERR_FAIL_NULL_V(native, Variant()); + GD_MONO_SCOPE_THREAD_ATTACH; + Object *owner = ClassDB::instance(NATIVE_GDMONOCLASS_NAME(native)); + REF ref; Reference *r = Object::cast_to<Reference>(owner); if (r) { ref = REF(r); @@ -2929,6 +3070,8 @@ ScriptInstance *CSharpScript::instance_create(Object *p_this) { } } + GD_MONO_SCOPE_THREAD_ATTACH; + Variant::CallError unchecked_error; return _create_instance(NULL, 0, p_this, Object::cast_to<Reference>(p_this) != NULL, unchecked_error); } @@ -2976,6 +3119,8 @@ void CSharpScript::get_script_method_list(List<MethodInfo> *p_list) const { if (!script_class) return; + GD_MONO_SCOPE_THREAD_ATTACH; + // TODO: Filter out things unsuitable for explicit calls, like constructors. const Vector<GDMonoMethod *> &methods = script_class->get_all_methods(); for (int i = 0; i < methods.size(); ++i) { @@ -2988,6 +3133,8 @@ bool CSharpScript::has_method(const StringName &p_method) const { if (!script_class) return false; + GD_MONO_SCOPE_THREAD_ATTACH; + return script_class->has_fetched_method_unknown_params(p_method); } @@ -2996,6 +3143,8 @@ MethodInfo CSharpScript::get_method_info(const StringName &p_method) const { if (!script_class) return MethodInfo(); + GD_MONO_SCOPE_THREAD_ATTACH; + GDMonoClass *top = script_class; while (top && top != native) { @@ -3020,6 +3169,8 @@ Error CSharpScript::reload(bool p_keep_state) { ERR_FAIL_COND_V(!p_keep_state && has_instances, ERR_ALREADY_IN_USE); + GD_MONO_SCOPE_THREAD_ATTACH; + GDMonoAssembly *project_assembly = GDMono::get_singleton()->get_project_assembly(); if (project_assembly) { @@ -3247,39 +3398,7 @@ RES ResourceFormatLoaderCSharpScript::load(const String &p_path, const String &p script->set_path(p_original_path); -#ifndef TOOLS_ENABLED - -#ifdef DEBUG_ENABLED - // User is responsible for thread attach/detach - CRASH_COND_MSG(mono_domain_get() == NULL, "Thread is not attached."); -#endif - -#endif - -#ifdef TOOLS_ENABLED - MonoDomain *domain = mono_domain_get(); - if (Engine::get_singleton()->is_editor_hint() && domain == NULL) { - - CRASH_COND(Thread::get_caller_id() == Thread::get_main_id()); - - // Thread is not attached, but we will make an exception in this case - // because this may be called by one of the editor's worker threads. - // Attach this thread temporarily to reload the script. - - if (domain) { - MonoThread *mono_thread = mono_thread_attach(domain); - CRASH_COND(mono_thread == NULL); - script->reload(); - mono_thread_detach(mono_thread); - } - - } else { // just reload it normally -#endif - script->reload(); - -#ifdef TOOLS_ENABLED - } -#endif + script->reload(); if (r_error) *r_error = OK; @@ -3318,7 +3437,7 @@ Error ResourceFormatSaverCSharpScript::save(const String &p_path, const RES &p_r "Compile", ProjectSettings::get_singleton()->globalize_path(p_path)); } else { - ERR_PRINTS("C# project could not be created; cannot add file: '" + p_path + "'."); + ERR_PRINT("C# project could not be created; cannot add file: '" + p_path + "'."); } } #endif diff --git a/modules/mono/csharp_script.h b/modules/mono/csharp_script.h index 027f429125..f244bc4119 100644 --- a/modules/mono/csharp_script.h +++ b/modules/mono/csharp_script.h @@ -307,6 +307,12 @@ class CSharpLanguage : public ScriptLanguage { Map<Object *, CSharpScriptBinding> script_bindings; +#ifdef DEBUG_ENABLED + // List of unsafe object references + Map<ObjectID, int> unsafe_object_references; + Mutex *unsafe_object_references_lock; +#endif + struct StringNameCache { StringName _signal_callback; @@ -458,6 +464,9 @@ public: Vector<StackInfo> stack_trace_get_info(MonoObject *p_stack_trace); #endif + void post_unsafe_reference(Object *p_obj); + void pre_unsafe_unreference(Object *p_obj); + CSharpLanguage(); ~CSharpLanguage(); }; diff --git a/modules/mono/editor/GodotTools/GodotTools.BuildLogger/GodotTools.BuildLogger.csproj b/modules/mono/editor/GodotTools/GodotTools.BuildLogger/GodotTools.BuildLogger.csproj index 1eaa36c1aa..8fdd485209 100644 --- a/modules/mono/editor/GodotTools/GodotTools.BuildLogger/GodotTools.BuildLogger.csproj +++ b/modules/mono/editor/GodotTools/GodotTools.BuildLogger/GodotTools.BuildLogger.csproj @@ -9,7 +9,7 @@ <AppDesignerFolder>Properties</AppDesignerFolder> <RootNamespace>GodotTools.BuildLogger</RootNamespace> <AssemblyName>GodotTools.BuildLogger</AssemblyName> - <TargetFrameworkVersion>v4.5</TargetFrameworkVersion> + <TargetFrameworkVersion>v4.7</TargetFrameworkVersion> <FileAlignment>512</FileAlignment> <LangVersion>7</LangVersion> </PropertyGroup> @@ -50,11 +50,11 @@ </ProjectReference> </ItemGroup> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> - <!-- To modify your build process, add your task inside one of the targets below and uncomment it. + <!-- To modify your build process, add your task inside one of the targets below and uncomment it. Other similar extension points exist, see Microsoft.Common.targets. <Target Name="BeforeBuild"> </Target> <Target Name="AfterBuild"> </Target> --> -</Project>
\ No newline at end of file +</Project> diff --git a/modules/mono/editor/GodotTools/GodotTools.Core/GodotTools.Core.csproj b/modules/mono/editor/GodotTools/GodotTools.Core/GodotTools.Core.csproj index 1974220f2f..2c35ef540a 100644 --- a/modules/mono/editor/GodotTools/GodotTools.Core/GodotTools.Core.csproj +++ b/modules/mono/editor/GodotTools/GodotTools.Core/GodotTools.Core.csproj @@ -7,7 +7,7 @@ <OutputType>Library</OutputType> <RootNamespace>GodotTools.Core</RootNamespace> <AssemblyName>GodotTools.Core</AssemblyName> - <TargetFrameworkVersion>v4.5</TargetFrameworkVersion> + <TargetFrameworkVersion>v4.7</TargetFrameworkVersion> <LangVersion>7</LangVersion> </PropertyGroup> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> @@ -36,4 +36,4 @@ <Compile Include="StringExtensions.cs" /> </ItemGroup> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> -</Project>
\ No newline at end of file +</Project> diff --git a/modules/mono/editor/GodotTools/GodotTools.IdeConnection/GodotTools.IdeConnection.csproj b/modules/mono/editor/GodotTools/GodotTools.IdeConnection/GodotTools.IdeConnection.csproj index 427a26508f..8454535fba 100644 --- a/modules/mono/editor/GodotTools/GodotTools.IdeConnection/GodotTools.IdeConnection.csproj +++ b/modules/mono/editor/GodotTools/GodotTools.IdeConnection/GodotTools.IdeConnection.csproj @@ -9,7 +9,7 @@ <AppDesignerFolder>Properties</AppDesignerFolder> <RootNamespace>GodotTools.IdeConnection</RootNamespace> <AssemblyName>GodotTools.IdeConnection</AssemblyName> - <TargetFrameworkVersion>v4.5</TargetFrameworkVersion> + <TargetFrameworkVersion>v4.7</TargetFrameworkVersion> <FileAlignment>512</FileAlignment> <LangVersion>7</LangVersion> </PropertyGroup> @@ -50,4 +50,4 @@ <Compile Include="Properties\AssemblyInfo.cs" /> </ItemGroup> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> -</Project>
\ No newline at end of file +</Project> diff --git a/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/GodotTools.ProjectEditor.csproj b/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/GodotTools.ProjectEditor.csproj index b6bb0aac34..b60e501beb 100644 --- a/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/GodotTools.ProjectEditor.csproj +++ b/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/GodotTools.ProjectEditor.csproj @@ -7,7 +7,7 @@ <OutputType>Library</OutputType> <RootNamespace>GodotTools.ProjectEditor</RootNamespace> <AssemblyName>GodotTools.ProjectEditor</AssemblyName> - <TargetFrameworkVersion>v4.5</TargetFrameworkVersion> + <TargetFrameworkVersion>v4.7</TargetFrameworkVersion> <BaseIntermediateOutputPath>obj</BaseIntermediateOutputPath> <LangVersion>7</LangVersion> </PropertyGroup> diff --git a/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectGenerator.cs b/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectGenerator.cs index 82627de01a..28b7832f90 100644 --- a/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectGenerator.cs +++ b/modules/mono/editor/GodotTools/GodotTools.ProjectEditor/ProjectGenerator.cs @@ -100,7 +100,7 @@ namespace GodotTools.ProjectEditor mainGroup.AddProperty("OutputPath", Path.Combine("bin", "$(Configuration)")); mainGroup.AddProperty("RootNamespace", IdentifierUtils.SanitizeQualifiedIdentifier(name, allowEmptyIdentifiers: true)); mainGroup.AddProperty("AssemblyName", name); - mainGroup.AddProperty("TargetFrameworkVersion", "v4.5"); + mainGroup.AddProperty("TargetFrameworkVersion", "v4.7"); mainGroup.AddProperty("GodotProjectGeneratorVersion", Assembly.GetExecutingAssembly().GetName().Version.ToString()); var debugGroup = root.AddPropertyGroup(); diff --git a/modules/mono/editor/GodotTools/GodotTools/CsProjOperations.cs b/modules/mono/editor/GodotTools/GodotTools/CsProjOperations.cs index 174509dc5b..9abfda4538 100644 --- a/modules/mono/editor/GodotTools/GodotTools/CsProjOperations.cs +++ b/modules/mono/editor/GodotTools/GodotTools/CsProjOperations.cs @@ -81,7 +81,12 @@ namespace GodotTools } } - ScriptClassParser.ParseFileOrThrow(projectIncludeFile, out var classes); + Error parseError = ScriptClassParser.ParseFile(projectIncludeFile, out var classes, out string errorStr); + if (parseError != Error.Ok) + { + GD.PushError($"Failed to determine namespace and class for script: {projectIncludeFile}. Parse error: {errorStr ?? parseError.ToString()}"); + continue; + } string searchName = System.IO.Path.GetFileNameWithoutExtension(projectIncludeFile); diff --git a/modules/mono/editor/GodotTools/GodotTools/Export/ExportPlugin.cs b/modules/mono/editor/GodotTools/GodotTools/Export/ExportPlugin.cs index 96cafba87f..3e2a8c22a9 100644 --- a/modules/mono/editor/GodotTools/GodotTools/Export/ExportPlugin.cs +++ b/modules/mono/editor/GodotTools/GodotTools/Export/ExportPlugin.cs @@ -17,6 +17,43 @@ namespace GodotTools.Export { public class ExportPlugin : EditorExportPlugin { + [Flags] + enum I18NCodesets + { + None = 0, + CJK = 1, + MidEast = 2, + Other = 4, + Rare = 8, + West = 16, + All = CJK | MidEast | Other | Rare | West + } + + private void AddI18NAssemblies(Godot.Collections.Dictionary<string, string> assemblies, string platform) + { + var codesets = (I18NCodesets) ProjectSettings.GetSetting("mono/export/i18n_codesets"); + + if (codesets == I18NCodesets.None) + return; + + string bclDir = DeterminePlatformBclDir(platform) ?? typeof(object).Assembly.Location.GetBaseDir(); + + void AddI18NAssembly(string name) => assemblies.Add(name, Path.Combine(bclDir, $"{name}.dll")); + + AddI18NAssembly("I18N"); + + if ((codesets & I18NCodesets.CJK) != 0) + AddI18NAssembly("I18N.CJK"); + if ((codesets & I18NCodesets.MidEast) != 0) + AddI18NAssembly("I18N.MidEast"); + if ((codesets & I18NCodesets.Other) != 0) + AddI18NAssembly("I18N.Other"); + if ((codesets & I18NCodesets.Rare) != 0) + AddI18NAssembly("I18N.Rare"); + if ((codesets & I18NCodesets.West) != 0) + AddI18NAssembly("I18N.West"); + } + public void RegisterExportSettings() { // TODO: These would be better as export preset options, but that doesn't seem to be supported yet @@ -24,6 +61,16 @@ namespace GodotTools.Export GlobalDef("mono/export/include_scripts_content", false); GlobalDef("mono/export/export_assemblies_inside_pck", true); + GlobalDef("mono/export/i18n_codesets", I18NCodesets.All); + + ProjectSettings.AddPropertyInfo(new Godot.Collections.Dictionary + { + ["type"] = Variant.Type.Int, + ["name"] = "mono/export/i18n_codesets", + ["hint"] = PropertyHint.Flags, + ["hint_string"] = "CJK,MidEast,Other,Rare,West" + }); + GlobalDef("mono/export/aot/enabled", false); GlobalDef("mono/export/aot/full_aot", false); @@ -145,6 +192,8 @@ namespace GodotTools.Export var initialDependencies = dependencies.Duplicate(); internal_GetExportedAssemblyDependencies(initialDependencies, buildConfig, DeterminePlatformBclDir(platform), dependencies); + AddI18NAssemblies(dependencies, platform); + string outputDataDir = null; if (PlatformHasTemplateDir(platform)) diff --git a/modules/mono/editor/GodotTools/GodotTools/GodotTools.csproj b/modules/mono/editor/GodotTools/GodotTools/GodotTools.csproj index 618527f916..379dfd9f7d 100644 --- a/modules/mono/editor/GodotTools/GodotTools/GodotTools.csproj +++ b/modules/mono/editor/GodotTools/GodotTools/GodotTools.csproj @@ -7,7 +7,7 @@ <OutputType>Library</OutputType> <RootNamespace>GodotTools</RootNamespace> <AssemblyName>GodotTools</AssemblyName> - <TargetFrameworkVersion>v4.5</TargetFrameworkVersion> + <TargetFrameworkVersion>v4.7</TargetFrameworkVersion> <GodotSourceRootPath>$(SolutionDir)/../../../../</GodotSourceRootPath> <DataDirToolsOutputPath>$(GodotSourceRootPath)/bin/GodotSharp/Tools</DataDirToolsOutputPath> <GodotApiConfiguration>Debug</GodotApiConfiguration> diff --git a/modules/mono/editor/GodotTools/GodotTools/Internals/ScriptClassParser.cs b/modules/mono/editor/GodotTools/GodotTools/Internals/ScriptClassParser.cs index 80e45b3a3c..7fb087467f 100644 --- a/modules/mono/editor/GodotTools/GodotTools/Internals/ScriptClassParser.cs +++ b/modules/mono/editor/GodotTools/GodotTools/Internals/ScriptClassParser.cs @@ -25,14 +25,17 @@ namespace GodotTools.Internals } [MethodImpl(MethodImplOptions.InternalCall)] - private static extern Error internal_ParseFile(string filePath, Array<Dictionary> classes); + private static extern Error internal_ParseFile(string filePath, Array<Dictionary> classes, out string errorStr); - public static void ParseFileOrThrow(string filePath, out IEnumerable<ClassDecl> classes) + public static Error ParseFile(string filePath, out IEnumerable<ClassDecl> classes, out string errorStr) { var classesArray = new Array<Dictionary>(); - var error = internal_ParseFile(filePath, classesArray); + var error = internal_ParseFile(filePath, classesArray, out errorStr); if (error != Error.Ok) - throw new Exception($"Failed to determine namespace and class for script: {filePath}. Parse error: {error}"); + { + classes = null; + return error; + } var classesList = new List<ClassDecl>(); @@ -47,6 +50,8 @@ namespace GodotTools.Internals } classes = classesList; + + return Error.Ok; } } } diff --git a/modules/mono/editor/bindings_generator.cpp b/modules/mono/editor/bindings_generator.cpp index 9beadb1778..34f01ce3c6 100644 --- a/modules/mono/editor/bindings_generator.cpp +++ b/modules/mono/editor/bindings_generator.cpp @@ -278,7 +278,7 @@ String BindingsGenerator::bbcode_to_xml(const String &p_bbcode, const TypeInterf Vector<String> link_target_parts = link_target.split("."); if (link_target_parts.size() <= 0 || link_target_parts.size() > 2) { - ERR_PRINTS("Invalid reference format: '" + tag + "'."); + ERR_PRINT("Invalid reference format: '" + tag + "'."); xml_output.append("<c>"); xml_output.append(tag); @@ -374,7 +374,7 @@ String BindingsGenerator::bbcode_to_xml(const String &p_bbcode, const TypeInterf xml_output.append(target_enum_itype.proxy_name); // Includes nesting class if any xml_output.append("\"/>"); } else { - ERR_PRINTS("Cannot resolve enum reference in documentation: '" + link_target + "'."); + ERR_PRINT("Cannot resolve enum reference in documentation: '" + link_target + "'."); xml_output.append("<c>"); xml_output.append(link_target); @@ -423,7 +423,7 @@ String BindingsGenerator::bbcode_to_xml(const String &p_bbcode, const TypeInterf xml_output.append(target_iconst->proxy_name); xml_output.append("\"/>"); } else { - ERR_PRINTS("Cannot resolve global constant reference in documentation: '" + link_target + "'."); + ERR_PRINT("Cannot resolve global constant reference in documentation: '" + link_target + "'."); xml_output.append("<c>"); xml_output.append(link_target); @@ -463,7 +463,7 @@ String BindingsGenerator::bbcode_to_xml(const String &p_bbcode, const TypeInterf xml_output.append(target_iconst->proxy_name); xml_output.append("\"/>"); } else { - ERR_PRINTS("Cannot resolve constant reference in documentation: '" + link_target + "'."); + ERR_PRINT("Cannot resolve constant reference in documentation: '" + link_target + "'."); xml_output.append("<c>"); xml_output.append(link_target); @@ -533,7 +533,7 @@ String BindingsGenerator::bbcode_to_xml(const String &p_bbcode, const TypeInterf xml_output.append(target_itype->proxy_name); xml_output.append("\"/>"); } else { - ERR_PRINTS("Cannot resolve type reference in documentation: '" + tag + "'."); + ERR_PRINT("Cannot resolve type reference in documentation: '" + tag + "'."); xml_output.append("<c>"); xml_output.append(tag); @@ -1207,7 +1207,7 @@ Error BindingsGenerator::_generate_cs_type(const TypeInterface &itype, const Str output.append(obj_types[itype.base_name].proxy_name); output.append("\n"); } else { - ERR_PRINTS("Base type '" + itype.base_name.operator String() + "' does not exist, for class '" + itype.name + "'."); + ERR_PRINT("Base type '" + itype.base_name.operator String() + "' does not exist, for class '" + itype.name + "'."); return ERR_INVALID_DATA; } } @@ -1646,7 +1646,7 @@ Error BindingsGenerator::_generate_cs_method(const BindingsGenerator::TypeInterf if (p_imethod.is_deprecated) { if (p_imethod.deprecation_message.empty()) - WARN_PRINTS("An empty deprecation message is discouraged. Method: '" + p_imethod.proxy_name + "'."); + WARN_PRINT("An empty deprecation message is discouraged. Method: '" + p_imethod.proxy_name + "'."); p_output.append(MEMBER_BEGIN "[Obsolete(\""); p_output.append(p_imethod.deprecation_message); @@ -2134,7 +2134,7 @@ const BindingsGenerator::TypeInterface *BindingsGenerator::_get_type_or_placehol if (found) return found; - ERR_PRINTS(String() + "Type not found. Creating placeholder: '" + p_typeref.cname.operator String() + "'."); + ERR_PRINT(String() + "Type not found. Creating placeholder: '" + p_typeref.cname.operator String() + "'."); const Map<StringName, TypeInterface>::Element *match = placeholder_types.find(p_typeref.cname); @@ -2358,9 +2358,9 @@ bool BindingsGenerator::_populate_object_type_interfaces() { // which could actually will return something different. // Let's put this to notify us if that ever happens. if (itype.cname != name_cache.type_Object || imethod.name != "free") { - WARN_PRINTS("Notification: New unexpected virtual non-overridable method found." - " We only expected Object.free, but found '" + - itype.name + "." + imethod.name + "'."); + WARN_PRINT("Notification: New unexpected virtual non-overridable method found." + " We only expected Object.free, but found '" + + itype.name + "." + imethod.name + "'."); } } else if (return_info.type == Variant::INT && return_info.usage & PROPERTY_USAGE_CLASS_IS_ENUM) { imethod.return_type.cname = return_info.class_name; @@ -2369,7 +2369,7 @@ bool BindingsGenerator::_populate_object_type_interfaces() { imethod.return_type.cname = return_info.class_name; if (!imethod.is_virtual && ClassDB::is_parent_class(return_info.class_name, name_cache.type_Reference) && return_info.hint != PROPERTY_HINT_RESOURCE_TYPE) { /* clang-format off */ - ERR_PRINTS("Return type is reference but hint is not '" _STR(PROPERTY_HINT_RESOURCE_TYPE) "'." + ERR_PRINT("Return type is reference but hint is not '" _STR(PROPERTY_HINT_RESOURCE_TYPE) "'." " Are you returning a reference type by pointer? Method: '" + itype.name + "." + imethod.name + "'."); /* clang-format on */ ERR_FAIL_V(false); @@ -3038,7 +3038,7 @@ void BindingsGenerator::_populate_global_constants() { // HARDCODED: The Error enum have the prefix 'ERR_' for everything except 'OK' and 'FAILED'. if (ienum.cname == name_cache.enum_Error) { if (prefix_length > 0) { // Just in case it ever changes - ERR_PRINTS("Prefix for enum '" _STR(Error) "' is not empty."); + ERR_PRINT("Prefix for enum '" _STR(Error) "' is not empty."); } prefix_length = 1; // 'ERR_' @@ -3133,7 +3133,7 @@ void BindingsGenerator::handle_cmdline_args(const List<String> &p_cmdline_args) glue_dir_path = path_elem->get(); elem = elem->next(); } else { - ERR_PRINTS(generate_all_glue_option + ": No output directory specified (expected path to '{GODOT_ROOT}/modules/mono/glue')."); + ERR_PRINT(generate_all_glue_option + ": No output directory specified (expected path to '{GODOT_ROOT}/modules/mono/glue')."); } --options_left; @@ -3144,7 +3144,7 @@ void BindingsGenerator::handle_cmdline_args(const List<String> &p_cmdline_args) cs_dir_path = path_elem->get(); elem = elem->next(); } else { - ERR_PRINTS(generate_cs_glue_option + ": No output directory specified."); + ERR_PRINT(generate_cs_glue_option + ": No output directory specified."); } --options_left; @@ -3155,7 +3155,7 @@ void BindingsGenerator::handle_cmdline_args(const List<String> &p_cmdline_args) cpp_dir_path = path_elem->get(); elem = elem->next(); } else { - ERR_PRINTS(generate_cpp_glue_option + ": No output directory specified."); + ERR_PRINT(generate_cpp_glue_option + ": No output directory specified."); } --options_left; @@ -3169,26 +3169,26 @@ void BindingsGenerator::handle_cmdline_args(const List<String> &p_cmdline_args) bindings_generator.set_log_print_enabled(true); if (!bindings_generator.initialized) { - ERR_PRINTS("Failed to initialize the bindings generator"); + ERR_PRINT("Failed to initialize the bindings generator"); ::exit(0); } if (glue_dir_path.length()) { if (bindings_generator.generate_glue(glue_dir_path) != OK) - ERR_PRINTS(generate_all_glue_option + ": Failed to generate the C++ glue."); + ERR_PRINT(generate_all_glue_option + ": Failed to generate the C++ glue."); if (bindings_generator.generate_cs_api(glue_dir_path.plus_file(API_SOLUTION_NAME)) != OK) - ERR_PRINTS(generate_all_glue_option + ": Failed to generate the C# API."); + ERR_PRINT(generate_all_glue_option + ": Failed to generate the C# API."); } if (cs_dir_path.length()) { if (bindings_generator.generate_cs_api(cs_dir_path) != OK) - ERR_PRINTS(generate_cs_glue_option + ": Failed to generate the C# API."); + ERR_PRINT(generate_cs_glue_option + ": Failed to generate the C# API."); } if (cpp_dir_path.length()) { if (bindings_generator.generate_glue(cpp_dir_path) != OK) - ERR_PRINTS(generate_cpp_glue_option + ": Failed to generate the C++ glue."); + ERR_PRINT(generate_cpp_glue_option + ": Failed to generate the C++ glue."); } // Exit once done diff --git a/modules/mono/editor/editor_internal_calls.cpp b/modules/mono/editor/editor_internal_calls.cpp index cfc869cd39..c8d20e80be 100644 --- a/modules/mono/editor/editor_internal_calls.cpp +++ b/modules/mono/editor/editor_internal_calls.cpp @@ -201,7 +201,9 @@ uint32_t godot_icall_BindingsGenerator_CsGlueVersion() { return CS_GLUE_VERSION; } -int32_t godot_icall_ScriptClassParser_ParseFile(MonoString *p_filepath, MonoObject *p_classes) { +int32_t godot_icall_ScriptClassParser_ParseFile(MonoString *p_filepath, MonoObject *p_classes, MonoString **r_error_str) { + *r_error_str = NULL; + String filepath = GDMonoMarshal::mono_string_to_godot(p_filepath); ScriptClassParser scp; @@ -220,6 +222,11 @@ int32_t godot_icall_ScriptClassParser_ParseFile(MonoString *p_filepath, MonoObje classDeclDict["base_count"] = classDecl.base.size(); classes.push_back(classDeclDict); } + } else { + String error_str = scp.get_error(); + if (!error_str.empty()) { + *r_error_str = GDMonoMarshal::mono_string_from_godot(error_str); + } } return err; } diff --git a/modules/mono/editor/script_class_parser.cpp b/modules/mono/editor/script_class_parser.cpp index c400479b89..bece23c9a6 100644 --- a/modules/mono/editor/script_class_parser.cpp +++ b/modules/mono/editor/script_class_parser.cpp @@ -302,8 +302,10 @@ Error ScriptClassParser::_skip_generic_type_params() { Error err = _skip_generic_type_params(); if (err) return err; - continue; - } else if (tk == TK_OP_GREATER) { + tk = get_token(); + } + + if (tk == TK_OP_GREATER) { return OK; } else if (tk != TK_COMMA) { error_str = "Unexpected token: " + get_token_name(tk); @@ -629,6 +631,84 @@ Error ScriptClassParser::parse(const String &p_code) { return OK; } +static String get_preprocessor_directive(const String &p_line, int p_from) { + CRASH_COND(p_line[p_from] != '#'); + p_from++; + int i = p_from; + while (i < p_line.length() && (p_line[i] == '_' || (p_line[i] >= 'A' && p_line[i] <= 'Z') || + (p_line[i] >= 'a' && p_line[i] <= 'z') || p_line[i] > 127)) { + i++; + } + return p_line.substr(p_from, i - p_from); +} + +static void run_dummy_preprocessor(String &r_source, const String &p_filepath) { + + Vector<String> lines = r_source.split("\n", /* p_allow_empty: */ true); + + bool *include_lines = memnew_arr(bool, lines.size()); + + int if_level = -1; + Vector<bool> is_branch_being_compiled; + + for (int i = 0; i < lines.size(); i++) { + const String &line = lines[i]; + + const int line_len = line.length(); + + int j; + for (j = 0; j < line_len; j++) { + if (line[j] != ' ' && line[j] != '\t') { + if (line[j] == '#') { + // First non-whitespace char of the line is '#' + include_lines[i] = false; + + String directive = get_preprocessor_directive(line, j); + + if (directive == "if") { + if_level++; + is_branch_being_compiled.push_back(if_level == 0 || is_branch_being_compiled[if_level - 1]); + } else if (directive == "elif") { + ERR_CONTINUE_MSG(if_level == -1, "Found unexpected '#elif' directive. File: '" + p_filepath + "'."); + is_branch_being_compiled.write[if_level] = false; + } else if (directive == "else") { + ERR_CONTINUE_MSG(if_level == -1, "Found unexpected '#else' directive. File: '" + p_filepath + "'."); + is_branch_being_compiled.write[if_level] = false; + } else if (directive == "endif") { + ERR_CONTINUE_MSG(if_level == -1, "Found unexpected '#endif' directive. File: '" + p_filepath + "'."); + is_branch_being_compiled.remove(if_level); + if_level--; + } + + break; + } else { + // First non-whitespace char of the line is not '#' + include_lines[i] = if_level == -1 || is_branch_being_compiled[if_level]; + break; + } + } + } + + if (j == line_len) { + // Loop ended without finding a non-whitespace character. + // Either the line was empty or it only contained whitespaces. + include_lines[i] = if_level == -1 || is_branch_being_compiled[if_level]; + } + } + + r_source.clear(); + + // Custom join ignoring lines removed by the preprocessor + for (int i = 0; i < lines.size(); i++) { + if (i > 0 && include_lines[i - 1]) + r_source += '\n'; + + if (include_lines[i]) { + r_source += lines[i]; + } + } +} + Error ScriptClassParser::parse_file(const String &p_filepath) { String source; @@ -641,6 +721,8 @@ Error ScriptClassParser::parse_file(const String &p_filepath) { " Please ensure that scripts are saved in valid UTF-8 unicode." : "Failed to read file: '" + p_filepath + "'."); + run_dummy_preprocessor(source, p_filepath); + return parse(source); } diff --git a/modules/mono/glue/GodotSharp/GodotSharp/Core/Basis.cs b/modules/mono/glue/GodotSharp/GodotSharp/Core/Basis.cs index c5e62b77c8..d38589013e 100644 --- a/modules/mono/glue/GodotSharp/GodotSharp/Core/Basis.cs +++ b/modules/mono/glue/GodotSharp/GodotSharp/Core/Basis.cs @@ -387,6 +387,19 @@ namespace Godot return b; } + public Basis Slerp(Basis target, real_t t) + { + var from = new Quat(this); + var to = new Quat(target); + + var b = new Basis(from.Slerp(to, t)); + b.Row0 *= Mathf.Lerp(Row0.Length(), target.Row0.Length(), t); + b.Row1 *= Mathf.Lerp(Row1.Length(), target.Row1.Length(), t); + b.Row2 *= Mathf.Lerp(Row2.Length(), target.Row2.Length(), t); + + return b; + } + public real_t Tdotx(Vector3 with) { return this.Row0[0] * with[0] + this.Row1[0] * with[1] + this.Row2[0] * with[2]; diff --git a/modules/mono/glue/GodotSharp/GodotSharp/Core/Extensions/NodeExtensions.cs b/modules/mono/glue/GodotSharp/GodotSharp/Core/Extensions/NodeExtensions.cs index 5023725f17..5d16260f5d 100644 --- a/modules/mono/glue/GodotSharp/GodotSharp/Core/Extensions/NodeExtensions.cs +++ b/modules/mono/glue/GodotSharp/GodotSharp/Core/Extensions/NodeExtensions.cs @@ -9,7 +9,7 @@ namespace Godot public T GetNodeOrNull<T>(NodePath path) where T : class { - return GetNode(path) as T; + return GetNodeOrNull(path) as T; } public T GetChild<T>(int idx) where T : class diff --git a/modules/mono/glue/GodotSharp/GodotSharp/Core/Quat.cs b/modules/mono/glue/GodotSharp/GodotSharp/Core/Quat.cs index 8f60867ac3..6702634c51 100644 --- a/modules/mono/glue/GodotSharp/GodotSharp/Core/Quat.cs +++ b/modules/mono/glue/GodotSharp/GodotSharp/Core/Quat.cs @@ -82,12 +82,20 @@ namespace Godot public Vector3 GetEuler() { +#if DEBUG + if (!IsNormalized()) + throw new InvalidOperationException("Quat is not normalized"); +#endif var basis = new Basis(this); return basis.GetEuler(); } public Quat Inverse() { +#if DEBUG + if (!IsNormalized()) + throw new InvalidOperationException("Quat is not normalized"); +#endif return new Quat(-x, -y, -z, w); } @@ -125,6 +133,13 @@ namespace Godot public Quat Slerp(Quat b, real_t t) { +#if DEBUG + if (!IsNormalized()) + throw new InvalidOperationException("Quat is not normalized"); + if (!b.IsNormalized()) + throw new ArgumentException("Argument is not normalized", nameof(b)); +#endif + // Calculate cosine real_t cosom = x * b.x + y * b.y + z * b.z + w * b.w; @@ -200,9 +215,13 @@ namespace Godot public Vector3 Xform(Vector3 v) { - Quat q = this * v; - q *= Inverse(); - return new Vector3(q.x, q.y, q.z); +#if DEBUG + if (!IsNormalized()) + throw new InvalidOperationException("Quat is not normalized"); +#endif + var u = new Vector3(x, y, z); + Vector3 uv = u.Cross(v); + return v + ((uv * w) + u.Cross(uv)) * 2; } // Static Readonly Properties @@ -257,8 +276,12 @@ namespace Godot public Quat(Vector3 axis, real_t angle) { +#if DEBUG + if (!axis.IsNormalized()) + throw new ArgumentException("Argument is not normalized", nameof(axis)); +#endif + real_t d = axis.Length(); - real_t angle_t = angle; if (d == 0f) { @@ -269,12 +292,14 @@ namespace Godot } else { - real_t s = Mathf.Sin(angle_t * 0.5f) / d; + real_t sinAngle = Mathf.Sin(angle * 0.5f); + real_t cosAngle = Mathf.Cos(angle * 0.5f); + real_t s = sinAngle / d; x = axis.x * s; y = axis.y * s; z = axis.z * s; - w = Mathf.Cos(angle_t * 0.5f); + w = cosAngle; } } diff --git a/modules/mono/glue/GodotSharp/GodotSharp/Core/Vector3.cs b/modules/mono/glue/GodotSharp/GodotSharp/Core/Vector3.cs index 025b09199f..fded34002d 100644 --- a/modules/mono/glue/GodotSharp/GodotSharp/Core/Vector3.cs +++ b/modules/mono/glue/GodotSharp/GodotSharp/Core/Vector3.cs @@ -255,7 +255,7 @@ namespace Godot { #if DEBUG if (!n.IsNormalized()) - throw new ArgumentException(String.Format("{0} is not normalized", n), nameof(n)); + throw new ArgumentException("Argument is not normalized", nameof(n)); #endif return 2.0f * n * Dot(n) - this; } @@ -296,6 +296,10 @@ namespace Godot public Vector3 Slerp(Vector3 b, real_t t) { +#if DEBUG + if (!IsNormalized()) + throw new InvalidOperationException("Vector3 is not normalized"); +#endif real_t theta = AngleTo(b); return Rotated(Cross(b), theta * t); } diff --git a/modules/mono/glue/base_object_glue.cpp b/modules/mono/glue/base_object_glue.cpp index 04a489f1f9..02246b2f2f 100644 --- a/modules/mono/glue/base_object_glue.cpp +++ b/modules/mono/glue/base_object_glue.cpp @@ -108,6 +108,7 @@ void godot_icall_Reference_Disposed(MonoObject *p_obj, Object *p_ptr, MonoBoolea // Unsafe refcount decrement. The managed instance also counts as a reference. // See: CSharpLanguage::alloc_instance_binding_data(Object *p_object) + CSharpLanguage::get_singleton()->pre_unsafe_unreference(ref); if (ref->unreference()) { memdelete(ref); } else { diff --git a/modules/mono/glue/gd_glue.cpp b/modules/mono/glue/gd_glue.cpp index 9bea625450..17483c4457 100644 --- a/modules/mono/glue/gd_glue.cpp +++ b/modules/mono/glue/gd_glue.cpp @@ -235,7 +235,7 @@ MonoObject *godot_icall_GD_str2var(MonoString *p_str) { Error err = VariantParser::parse(&ss, ret, errs, line); if (err != OK) { String err_str = "Parse error at line " + itos(line) + ": " + errs + "."; - ERR_PRINTS(err_str); + ERR_PRINT(err_str); ret = err_str; } @@ -247,11 +247,11 @@ MonoBoolean godot_icall_GD_type_exists(MonoString *p_type) { } void godot_icall_GD_pusherror(MonoString *p_str) { - ERR_PRINTS(GDMonoMarshal::mono_string_to_godot(p_str)); + ERR_PRINT(GDMonoMarshal::mono_string_to_godot(p_str)); } void godot_icall_GD_pushwarning(MonoString *p_str) { - WARN_PRINTS(GDMonoMarshal::mono_string_to_godot(p_str)); + WARN_PRINT(GDMonoMarshal::mono_string_to_godot(p_str)); } MonoArray *godot_icall_GD_var2bytes(MonoObject *p_var, MonoBoolean p_full_objects) { diff --git a/modules/mono/mono_gd/gd_mono.cpp b/modules/mono/mono_gd/gd_mono.cpp index 60008f8fab..895393537f 100644 --- a/modules/mono/mono_gd/gd_mono.cpp +++ b/modules/mono/mono_gd/gd_mono.cpp @@ -621,7 +621,7 @@ bool GDMono::copy_prebuilt_api_assembly(ApiAssemblyInfo::Type p_api_type, const memdelete(da); if (err != OK) { - ERR_PRINTS("Failed to create destination directory for the API assemblies. Error: " + itos(err) + "."); + ERR_PRINT("Failed to create destination directory for the API assemblies. Error: " + itos(err) + "."); return false; } } @@ -630,15 +630,15 @@ bool GDMono::copy_prebuilt_api_assembly(ApiAssemblyInfo::Type p_api_type, const String xml_file = assembly_name + ".xml"; if (da->copy(src_dir.plus_file(xml_file), dst_dir.plus_file(xml_file)) != OK) - WARN_PRINTS("Failed to copy '" + xml_file + "'."); + WARN_PRINT("Failed to copy '" + xml_file + "'."); String pdb_file = assembly_name + ".pdb"; if (da->copy(src_dir.plus_file(pdb_file), dst_dir.plus_file(pdb_file)) != OK) - WARN_PRINTS("Failed to copy '" + pdb_file + "'."); + WARN_PRINT("Failed to copy '" + pdb_file + "'."); String assembly_file = assembly_name + ".dll"; if (da->copy(src_dir.plus_file(assembly_file), dst_dir.plus_file(assembly_file)) != OK) { - ERR_PRINTS("Failed to copy '" + assembly_file + "'."); + ERR_PRINT("Failed to copy '" + assembly_file + "'."); return false; } @@ -1115,7 +1115,7 @@ Error GDMono::finalize_and_unload_domain(MonoDomain *p_domain) { mono_domain_try_unload(p_domain, (MonoObject **)&exc); if (exc) { - ERR_PRINTS("Exception thrown when unloading domain '" + domain_name + "'."); + ERR_PRINT("Exception thrown when unloading domain '" + domain_name + "'."); GDMonoUtils::debug_print_unhandled_exception(exc); return FAILED; } diff --git a/modules/mono/mono_gd/gd_mono_assembly.cpp b/modules/mono/mono_gd/gd_mono_assembly.cpp index 9d7ac5c5ea..6cf5377e2c 100644 --- a/modules/mono/mono_gd/gd_mono_assembly.cpp +++ b/modules/mono/mono_gd/gd_mono_assembly.cpp @@ -129,7 +129,7 @@ MonoAssembly *GDMonoAssembly::_search_hook(MonoAssemblyName *aname, void *user_d (void)user_data; // UNUSED - String name = mono_assembly_name_get_name(aname); + String name = String::utf8(mono_assembly_name_get_name(aname)); bool has_extension = name.ends_with(".dll") || name.ends_with(".exe"); if (no_search) @@ -176,7 +176,7 @@ MonoAssembly *GDMonoAssembly::_preload_hook(MonoAssemblyName *aname, char **, vo no_search = true; in_preload = true; - String name = mono_assembly_name_get_name(aname); + String name = String::utf8(mono_assembly_name_get_name(aname)); bool has_extension = name.ends_with(".dll"); GDMonoAssembly *res = NULL; @@ -276,7 +276,7 @@ GDMonoAssembly *GDMonoAssembly::_load_assembly_from(const String &p_name, const } void GDMonoAssembly::_wrap_mono_assembly(MonoAssembly *assembly) { - String name = mono_assembly_name_get_name(mono_assembly_get_name(assembly)); + String name = String::utf8(mono_assembly_name_get_name(mono_assembly_get_name(assembly))); MonoImage *image = mono_assembly_get_image(assembly); diff --git a/modules/mono/mono_gd/gd_mono_class.cpp b/modules/mono/mono_gd/gd_mono_class.cpp index 2132fd36f7..648f5f6c6b 100644 --- a/modules/mono/mono_gd/gd_mono_class.cpp +++ b/modules/mono/mono_gd/gd_mono_class.cpp @@ -166,8 +166,8 @@ void GDMonoClass::fetch_methods_with_godot_api_checks(GDMonoClass *p_native_base #ifdef DEBUG_ENABLED String fullname = method->get_ret_type_full_name() + " " + name + "(" + method->get_signature_desc(true) + ")"; - WARN_PRINTS("Method '" + fullname + "' is hidden by Godot API method. Should be '" + - method->get_full_name_no_class() + "'. In class '" + namespace_name + "." + class_name + "'."); + WARN_PRINT("Method '" + fullname + "' is hidden by Godot API method. Should be '" + + method->get_full_name_no_class() + "'. In class '" + namespace_name + "." + class_name + "'."); #endif continue; } @@ -185,8 +185,8 @@ void GDMonoClass::fetch_methods_with_godot_api_checks(GDMonoClass *p_native_base if (m && m->get_name() != name) { // found String fullname = m->get_ret_type_full_name() + " " + name + "(" + m->get_signature_desc(true) + ")"; - WARN_PRINTS("Method '" + fullname + "' should be '" + m->get_full_name_no_class() + - "'. In class '" + namespace_name + "." + class_name + "'."); + WARN_PRINT("Method '" + fullname + "' should be '" + m->get_full_name_no_class() + + "'. In class '" + namespace_name + "." + class_name + "'."); break; } diff --git a/modules/mono/mono_gd/gd_mono_field.cpp b/modules/mono/mono_gd/gd_mono_field.cpp index 3e0f9a3f15..178647b968 100644 --- a/modules/mono/mono_gd/gd_mono_field.cpp +++ b/modules/mono/mono_gd/gd_mono_field.cpp @@ -512,7 +512,7 @@ void GDMonoField::set_value_from_variant(MonoObject *p_object, const Variant &p_ } break; default: { - ERR_PRINTS("Attempted to set the value of a field of unexpected type encoding: " + itos(type.type_encoding) + "."); + ERR_PRINT("Attempted to set the value of a field of unexpected type encoding: " + itos(type.type_encoding) + "."); } break; } diff --git a/modules/mono/mono_gd/gd_mono_internals.cpp b/modules/mono/mono_gd/gd_mono_internals.cpp index 8669182c4e..75aa77c7b0 100644 --- a/modules/mono/mono_gd/gd_mono_internals.cpp +++ b/modules/mono/mono_gd/gd_mono_internals.cpp @@ -83,7 +83,9 @@ void tie_managed_to_unmanaged(MonoObject *managed, Object *unmanaged) { // See: godot_icall_Reference_Dtor(MonoObject *p_obj, Object *p_ptr) // May not me referenced yet, so we must use init_ref() instead of reference() - ref->init_ref(); + if (ref->init_ref()) { + CSharpLanguage::get_singleton()->post_unsafe_reference(ref); + } } // The object was just created, no script instance binding should have been attached diff --git a/modules/mono/mono_gd/gd_mono_log.cpp b/modules/mono/mono_gd/gd_mono_log.cpp index ad68a4d90e..76828a66e0 100644 --- a/modules/mono/mono_gd/gd_mono_log.cpp +++ b/modules/mono/mono_gd/gd_mono_log.cpp @@ -83,7 +83,7 @@ void GDMonoLog::mono_log_callback(const char *log_domain, const char *log_level, } if (fatal) { - ERR_PRINTS("Mono: FATAL ERROR, ABORTING! Logfile: '" + GDMonoLog::get_singleton()->log_file_path + "'."); + ERR_PRINT("Mono: FATAL ERROR, ABORTING! Logfile: '" + GDMonoLog::get_singleton()->log_file_path + "'."); // Make sure to flush before aborting f->flush(); f->close(); @@ -139,7 +139,7 @@ void GDMonoLog::initialize() { CharString log_level = OS::get_singleton()->get_environment("GODOT_MONO_LOG_LEVEL").utf8(); if (log_level.length() != 0 && get_log_level_id(log_level.get_data()) == -1) { - ERR_PRINTS(String() + "Mono: Ignoring invalid log level (GODOT_MONO_LOG_LEVEL): '" + log_level.get_data() + "'."); + ERR_PRINT(String() + "Mono: Ignoring invalid log level (GODOT_MONO_LOG_LEVEL): '" + log_level.get_data() + "'."); log_level = CharString(); } @@ -167,7 +167,7 @@ void GDMonoLog::initialize() { log_file = FileAccess::open(log_file_path, FileAccess::WRITE); if (!log_file) { - ERR_PRINTS("Mono: Cannot create log file at: " + log_file_path); + ERR_PRINT("Mono: Cannot create log file at: " + log_file_path); } } diff --git a/modules/mono/mono_gd/gd_mono_marshal.cpp b/modules/mono/mono_gd/gd_mono_marshal.cpp index b81c20348d..19d627218e 100644 --- a/modules/mono/mono_gd/gd_mono_marshal.cpp +++ b/modules/mono/mono_gd/gd_mono_marshal.cpp @@ -277,7 +277,7 @@ String mono_to_utf8_string(MonoString *p_mono_string) { char *utf8 = mono_string_to_utf8_checked(p_mono_string, &error); if (!mono_error_ok(&error)) { - ERR_PRINTS(String() + "Failed to convert MonoString* to UTF-8: '" + mono_error_get_message(&error) + "'."); + ERR_PRINT(String() + "Failed to convert MonoString* to UTF-8: '" + mono_error_get_message(&error) + "'."); mono_error_cleanup(&error); return String(); } diff --git a/modules/mono/mono_gd/gd_mono_utils.cpp b/modules/mono/mono_gd/gd_mono_utils.cpp index 3c8aa0c727..05077a00c4 100644 --- a/modules/mono/mono_gd/gd_mono_utils.cpp +++ b/modules/mono/mono_gd/gd_mono_utils.cpp @@ -115,6 +115,7 @@ MonoObject *unmanaged_get_managed(Object *unmanaged) { // but the managed instance is alive, the refcount will be 1 instead of 0. // See: godot_icall_Reference_Dtor(MonoObject *p_obj, Object *p_ptr) ref->reference(); + CSharpLanguage::get_singleton()->post_unsafe_reference(ref); } return mono_object; @@ -124,10 +125,12 @@ void set_main_thread(MonoThread *p_thread) { mono_thread_set_main(p_thread); } -void attach_current_thread() { - ERR_FAIL_COND(!GDMono::get_singleton()->is_runtime_initialized()); - MonoThread *mono_thread = mono_thread_attach(mono_get_root_domain()); - ERR_FAIL_NULL(mono_thread); +MonoThread *attach_current_thread() { + ERR_FAIL_COND_V(!GDMono::get_singleton()->is_runtime_initialized(), NULL); + MonoDomain *scripts_domain = GDMono::get_singleton()->get_scripts_domain(); + MonoThread *mono_thread = mono_thread_attach(scripts_domain ? scripts_domain : mono_get_root_domain()); + ERR_FAIL_NULL_V(mono_thread, NULL); + return mono_thread; } void detach_current_thread() { @@ -137,10 +140,20 @@ void detach_current_thread() { mono_thread_detach(mono_thread); } +void detach_current_thread(MonoThread *p_mono_thread) { + ERR_FAIL_COND(!GDMono::get_singleton()->is_runtime_initialized()); + ERR_FAIL_NULL(p_mono_thread); + mono_thread_detach(p_mono_thread); +} + MonoThread *get_current_thread() { return mono_thread_current(); } +bool is_thread_attached() { + return mono_domain_get() != NULL; +} + void runtime_object_init(MonoObject *p_this_obj, GDMonoClass *p_class, MonoException **r_exc) { GDMonoMethod *ctor = p_class->get_method(".ctor", 0); ERR_FAIL_NULL(ctor); @@ -341,7 +354,7 @@ void debug_send_unhandled_exception_error(MonoException *p_exc) { if (!ScriptDebugger::get_singleton()) { #ifdef TOOLS_ENABLED if (Engine::get_singleton()->is_editor_hint()) { - ERR_PRINTS(GDMonoUtils::get_exception_name_and_message(p_exc)); + ERR_PRINT(GDMonoUtils::get_exception_name_and_message(p_exc)); } #endif return; @@ -418,7 +431,7 @@ void set_pending_exception(MonoException *p_exc) { } if (!mono_runtime_set_pending_exception(p_exc, false)) { - ERR_PRINTS("Exception thrown from managed code, but it could not be set as pending:"); + ERR_PRINT("Exception thrown from managed code, but it could not be set as pending:"); GDMonoUtils::debug_print_unhandled_exception(p_exc); } #endif @@ -616,4 +629,19 @@ GDMonoClass *make_generic_dictionary_type(MonoReflectionType *p_key_reftype, Mon } // namespace Marshal +ScopeThreadAttach::ScopeThreadAttach() : + mono_thread(NULL) { + if (likely(GDMono::get_singleton()->is_runtime_initialized()) && unlikely(!mono_domain_get())) { + mono_thread = GDMonoUtils::attach_current_thread(); + } +} + +ScopeThreadAttach::~ScopeThreadAttach() { + if (unlikely(mono_thread)) { + GDMonoUtils::detach_current_thread(mono_thread); + } +} + +// namespace Marshal + } // namespace GDMonoUtils diff --git a/modules/mono/mono_gd/gd_mono_utils.h b/modules/mono/mono_gd/gd_mono_utils.h index d9eb912cd7..db9f99bfdc 100644 --- a/modules/mono/mono_gd/gd_mono_utils.h +++ b/modules/mono/mono_gd/gd_mono_utils.h @@ -83,9 +83,11 @@ _FORCE_INLINE_ void hash_combine(uint32_t &p_hash, const uint32_t &p_with_hash) MonoObject *unmanaged_get_managed(Object *unmanaged); void set_main_thread(MonoThread *p_thread); -void attach_current_thread(); +MonoThread *attach_current_thread(); void detach_current_thread(); +void detach_current_thread(MonoThread *p_mono_thread); MonoThread *get_current_thread(); +bool is_thread_attached(); _FORCE_INLINE_ bool is_main_thread() { return mono_domain_get() != NULL && mono_thread_get_main() == mono_thread_current(); @@ -142,6 +144,14 @@ uint64_t unbox_enum_value(MonoObject *p_boxed, MonoType *p_enum_basetype, bool & void dispose(MonoObject *p_mono_object, MonoException **r_exc); +struct ScopeThreadAttach { + ScopeThreadAttach(); + ~ScopeThreadAttach(); + +private: + MonoThread *mono_thread; +}; + } // namespace GDMonoUtils #define NATIVE_GDMONOCLASS_NAME(m_class) (GDMonoMarshal::mono_string_to_godot((MonoString *)m_class->get_field(BINDINGS_NATIVE_NAME_FIELD)->get_value(NULL))) @@ -153,4 +163,15 @@ void dispose(MonoObject *p_mono_object, MonoException **r_exc); #define GD_MONO_END_RUNTIME_INVOKE \ _runtime_invoke_count_ref -= 1; +#define GD_MONO_SCOPE_THREAD_ATTACH \ + GDMonoUtils::ScopeThreadAttach __gdmono__scope__thread__attach__; \ + (void)__gdmono__scope__thread__attach__; + +#ifdef DEBUG_ENABLED +#define GD_MONO_ASSERT_THREAD_ATTACHED \ + { CRASH_COND(!GDMonoUtils::is_thread_attached()); } +#else +#define GD_MONO_ASSERT_THREAD_ATTACHED +#endif + #endif // GD_MONOUTILS_H diff --git a/modules/opensimplex/doc_classes/NoiseTexture.xml b/modules/opensimplex/doc_classes/NoiseTexture.xml index 07d5eb27d6..0790cde557 100644 --- a/modules/opensimplex/doc_classes/NoiseTexture.xml +++ b/modules/opensimplex/doc_classes/NoiseTexture.xml @@ -1,11 +1,17 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="NoiseTexture" inherits="Texture" category="Core" version="3.2"> +<class name="NoiseTexture" inherits="Texture" version="4.0"> <brief_description> [OpenSimplexNoise] filled texture. </brief_description> <description> Uses an [OpenSimplexNoise] to fill the texture data. You can specify the texture size but keep in mind that larger textures will take longer to generate and seamless noise only works with square sized textures. NoiseTexture can also generate normalmap textures. + The class uses [Thread]s to generate the texture data internally, so [method Texture.get_data] may return [code]null[/code] if the generation process has not completed yet. In that case, you need to wait for the texture to be generated before accessing the data: + [codeblock] + var texture = preload("res://noise.tres") + yield(texture, "changed") + var image = texture.get_data() + [/codeblock] </description> <tutorials> </tutorials> @@ -16,6 +22,7 @@ If [code]true[/code], the resulting texture contains a normal map created from the original noise interpreted as a bump map. </member> <member name="bump_strength" type="float" setter="set_bump_strength" getter="get_bump_strength" default="8.0"> + Strength of the bump maps used in this texture. A higher value will make the bump maps appear larger while a lower value will make them appear softer. </member> <member name="flags" type="int" setter="set_flags" getter="get_flags" override="true" default="7" /> <member name="height" type="int" setter="set_height" getter="get_height" default="512"> diff --git a/modules/opensimplex/doc_classes/OpenSimplexNoise.xml b/modules/opensimplex/doc_classes/OpenSimplexNoise.xml index f3fbbab3da..d89828037f 100644 --- a/modules/opensimplex/doc_classes/OpenSimplexNoise.xml +++ b/modules/opensimplex/doc_classes/OpenSimplexNoise.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="OpenSimplexNoise" inherits="Resource" category="Core" version="3.2"> +<class name="OpenSimplexNoise" inherits="Resource" version="4.0"> <brief_description> Noise generator based on Open Simplex. </brief_description> @@ -117,7 +117,8 @@ Difference in period between [member octaves]. </member> <member name="octaves" type="int" setter="set_octaves" getter="get_octaves" default="3"> - Number of OpenSimplex noise layers that are sampled to get the fractal noise. + Number of OpenSimplex noise layers that are sampled to get the fractal noise. Higher values result in more detailed noise but take more time to generate. + [b]Note:[/b] The maximum allowed value is 9. </member> <member name="period" type="float" setter="set_period" getter="get_period" default="64.0"> Period of the base octave. A lower period results in a higher-frequency noise (more value changes across the same distance). diff --git a/modules/opensimplex/open_simplex_noise.cpp b/modules/opensimplex/open_simplex_noise.cpp index c99588aefa..bd187e6b5b 100644 --- a/modules/opensimplex/open_simplex_noise.cpp +++ b/modules/opensimplex/open_simplex_noise.cpp @@ -47,7 +47,7 @@ OpenSimplexNoise::~OpenSimplexNoise() { } void OpenSimplexNoise::_init_seeds() { - for (int i = 0; i < 6; ++i) { + for (int i = 0; i < MAX_OCTAVES; ++i) { open_simplex_noise(seed + i * 2, &(contexts[i])); } } @@ -71,7 +71,10 @@ int OpenSimplexNoise::get_seed() { void OpenSimplexNoise::set_octaves(int p_octaves) { if (p_octaves == octaves) return; - octaves = CLAMP(p_octaves, 1, 6); + + ERR_FAIL_COND_MSG(p_octaves > MAX_OCTAVES, vformat("The number of OpenSimplexNoise octaves is limited to %d; ignoring the new value.", MAX_OCTAVES)); + + octaves = CLAMP(p_octaves, 1, MAX_OCTAVES); emit_changed(); } @@ -182,7 +185,7 @@ void OpenSimplexNoise::_bind_methods() { ClassDB::bind_method(D_METHOD("get_noise_3dv", "pos"), &OpenSimplexNoise::get_noise_3dv); ADD_PROPERTY(PropertyInfo(Variant::INT, "seed"), "set_seed", "get_seed"); - ADD_PROPERTY(PropertyInfo(Variant::INT, "octaves", PROPERTY_HINT_RANGE, "1,6,1"), "set_octaves", "get_octaves"); + ADD_PROPERTY(PropertyInfo(Variant::INT, "octaves", PROPERTY_HINT_RANGE, vformat("1,%d,1", MAX_OCTAVES)), "set_octaves", "get_octaves"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "period", PROPERTY_HINT_RANGE, "0.1,256.0,0.1"), "set_period", "get_period"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "persistence", PROPERTY_HINT_RANGE, "0.0,1.0,0.001"), "set_persistence", "get_persistence"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "lacunarity", PROPERTY_HINT_RANGE, "0.1,4.0,0.01"), "set_lacunarity", "get_lacunarity"); diff --git a/modules/opensimplex/open_simplex_noise.h b/modules/opensimplex/open_simplex_noise.h index 89b12253b9..dce62bc1f9 100644 --- a/modules/opensimplex/open_simplex_noise.h +++ b/modules/opensimplex/open_simplex_noise.h @@ -37,11 +37,16 @@ #include "thirdparty/misc/open-simplex-noise.h" +// The maximum number of octaves allowed. Note that these are statically allocated. +// Higher values become exponentially slower, so this shouldn't be set too high +// to avoid freezing the editor for long periods of time. +#define MAX_OCTAVES 9 + class OpenSimplexNoise : public Resource { GDCLASS(OpenSimplexNoise, Resource); OBJ_SAVE_TYPE(OpenSimplexNoise); - osn_context contexts[6]; + osn_context contexts[MAX_OCTAVES]; int seed; float persistence; // Controls details, value in [0,1]. Higher increases grain, lower increases smoothness. diff --git a/modules/recast/register_types.cpp b/modules/recast/register_types.cpp index a1286c58c8..ea0ab00771 100644 --- a/modules/recast/register_types.cpp +++ b/modules/recast/register_types.cpp @@ -38,17 +38,17 @@ EditorNavigationMeshGenerator *_nav_mesh_generator = NULL; void register_recast_types() { #ifdef TOOLS_ENABLED - EditorPlugins::add_by_type<NavigationMeshEditorPlugin>(); - _nav_mesh_generator = memnew(EditorNavigationMeshGenerator); - ClassDB::APIType prev_api = ClassDB::get_current_api(); ClassDB::set_current_api(ClassDB::API_EDITOR); - ClassDB::register_class<EditorNavigationMeshGenerator>(); + EditorPlugins::add_by_type<NavigationMeshEditorPlugin>(); + _nav_mesh_generator = memnew(EditorNavigationMeshGenerator); - ClassDB::set_current_api(prev_api); + ClassDB::register_class<EditorNavigationMeshGenerator>(); Engine::get_singleton()->add_singleton(Engine::Singleton("NavigationMeshGenerator", EditorNavigationMeshGenerator::get_singleton())); + + ClassDB::set_current_api(prev_api); #endif } diff --git a/modules/regex/doc_classes/RegEx.xml b/modules/regex/doc_classes/RegEx.xml index 74b06039d4..e9f46b9853 100644 --- a/modules/regex/doc_classes/RegEx.xml +++ b/modules/regex/doc_classes/RegEx.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RegEx" inherits="Reference" category="Core" version="3.2"> +<class name="RegEx" inherits="Reference" version="4.0"> <brief_description> Class for searching text for patterns using regular expressions. </brief_description> @@ -10,7 +10,7 @@ var regex = RegEx.new() regex.compile("\\w-(\\d+)") [/codeblock] - The search pattern must be escaped first for gdscript before it is escaped for the expression. For example, [code]compile("\\d+")[/code] would be read by RegEx as [code]\d+[/code]. Similarly, [code]compile("\"(?:\\\\.|[^\"])*\"")[/code] would be read as [code]"(?:\\.|[^"])*"[/code] + The search pattern must be escaped first for gdscript before it is escaped for the expression. For example, [code]compile("\\d+")[/code] would be read by RegEx as [code]\d+[/code]. Similarly, [code]compile("\"(?:\\\\.|[^\"])*\"")[/code] would be read as [code]"(?:\\.|[^"])*"[/code]. Using [method search] you can find the pattern within the given text. If a pattern is found, [RegExMatch] is returned and you can retrieve details of the results using functions such as [method RegExMatch.get_string] and [method RegExMatch.get_start]. [codeblock] var regex = RegEx.new() diff --git a/modules/regex/doc_classes/RegExMatch.xml b/modules/regex/doc_classes/RegExMatch.xml index 6dec9fc516..151e881b6f 100644 --- a/modules/regex/doc_classes/RegExMatch.xml +++ b/modules/regex/doc_classes/RegExMatch.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="RegExMatch" inherits="Reference" category="Core" version="3.2"> +<class name="RegExMatch" inherits="Reference" version="4.0"> <brief_description> Contains the results of a [RegEx] search. </brief_description> diff --git a/modules/squish/image_compress_squish.cpp b/modules/squish/image_compress_squish.cpp index ef4ea93e57..58b8115dfc 100644 --- a/modules/squish/image_compress_squish.cpp +++ b/modules/squish/image_compress_squish.cpp @@ -73,7 +73,6 @@ void image_decompress_squish(Image *p_image) { p_image->create(p_image->get_width(), p_image->get_height(), p_image->has_mipmaps(), target_format, data); } -#ifdef TOOLS_ENABLED void image_compress_squish(Image *p_image, float p_lossy_quality, Image::CompressSource p_source) { if (p_image->get_format() >= Image::FORMAT_DXT1) @@ -203,4 +202,3 @@ void image_compress_squish(Image *p_image, float p_lossy_quality, Image::Compres p_image->create(p_image->get_width(), p_image->get_height(), p_image->has_mipmaps(), target_format, data); } } -#endif diff --git a/modules/squish/image_compress_squish.h b/modules/squish/image_compress_squish.h index 2666815e47..b5a209ceb9 100644 --- a/modules/squish/image_compress_squish.h +++ b/modules/squish/image_compress_squish.h @@ -33,9 +33,7 @@ #include "core/image.h" -#ifdef TOOLS_ENABLED void image_compress_squish(Image *p_image, float p_lossy_quality, Image::CompressSource p_source); -#endif void image_decompress_squish(Image *p_image); #endif // IMAGE_COMPRESS_SQUISH_H diff --git a/modules/squish/register_types.cpp b/modules/squish/register_types.cpp index 1cd551defb..2a0cf82b56 100644 --- a/modules/squish/register_types.cpp +++ b/modules/squish/register_types.cpp @@ -33,9 +33,7 @@ void register_squish_types() { -#ifdef TOOLS_ENABLED Image::set_compress_bc_func(image_compress_squish); -#endif Image::_image_decompress_bc = image_decompress_squish; } diff --git a/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp b/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp index b80b126bde..f2d0f5c9a6 100644 --- a/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp +++ b/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp @@ -57,7 +57,7 @@ void AudioStreamPlaybackOGGVorbis::_mix_internal(AudioFrame *p_buffer, int p_fra if (todo) { //end of file! - if (vorbis_stream->loop) { + if (vorbis_stream->loop && mixed > 0) { //loop seek(vorbis_stream->loop_offset); loops++; diff --git a/modules/stb_vorbis/audio_stream_ogg_vorbis.h b/modules/stb_vorbis/audio_stream_ogg_vorbis.h index cfa5e97faa..e909759acb 100644 --- a/modules/stb_vorbis/audio_stream_ogg_vorbis.h +++ b/modules/stb_vorbis/audio_stream_ogg_vorbis.h @@ -73,7 +73,7 @@ public: class AudioStreamOGGVorbis : public AudioStream { GDCLASS(AudioStreamOGGVorbis, AudioStream); - OBJ_SAVE_TYPE(AudioStream) //children are all saved as AudioStream, so they can be exchanged + OBJ_SAVE_TYPE(AudioStream); // Saves derived classes with common type so they can be interchanged. RES_BASE_EXTENSION("oggstr"); friend class AudioStreamPlaybackOGGVorbis; diff --git a/modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml b/modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml index 102a9b4236..38d3bd5468 100644 --- a/modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml +++ b/modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="AudioStreamOGGVorbis" inherits="AudioStream" category="Core" version="3.2"> +<class name="AudioStreamOGGVorbis" inherits="AudioStream" version="4.0"> <brief_description> OGG Vorbis audio stream driver. </brief_description> diff --git a/modules/svg/image_loader_svg.cpp b/modules/svg/image_loader_svg.cpp index 57097aaa06..11ae2f81bf 100644 --- a/modules/svg/image_loader_svg.cpp +++ b/modules/svg/image_loader_svg.cpp @@ -103,15 +103,17 @@ Error ImageLoaderSVG::_create_image(Ref<Image> p_image, const PoolVector<uint8_t ERR_PRINT("SVG Corrupted"); return ERR_FILE_CORRUPT; } - if (convert_colors) + + if (convert_colors) { _convert_colors(svg_image); + } - float upscale = upsample ? 2.0 : 1.0; + const float upscale = upsample ? 2.0 : 1.0; - int w = (int)(svg_image->width * p_scale * upscale); + const int w = (int)(svg_image->width * p_scale * upscale); ERR_FAIL_COND_V_MSG(w > Image::MAX_WIDTH, ERR_PARAMETER_RANGE_ERROR, vformat("Can't create image from SVG with scale %s, the resulting image size exceeds max width.", rtos(p_scale))); - int h = (int)(svg_image->height * p_scale * upscale); + const int h = (int)(svg_image->height * p_scale * upscale); ERR_FAIL_COND_V_MSG(h > Image::MAX_HEIGHT, ERR_PARAMETER_RANGE_ERROR, vformat("Can't create image from SVG with scale %s, the resulting image size exceeds max height.", rtos(p_scale))); PoolVector<uint8_t> dst_image; @@ -123,8 +125,9 @@ Error ImageLoaderSVG::_create_image(Ref<Image> p_image, const PoolVector<uint8_t dw.release(); p_image->create(w, h, false, Image::FORMAT_RGBA8, dst_image); - if (upsample) + if (upsample) { p_image->shrink_x2(); + } nsvgDelete(svg_image); diff --git a/modules/theora/doc_classes/VideoStreamTheora.xml b/modules/theora/doc_classes/VideoStreamTheora.xml index 696101e252..92244a4d28 100644 --- a/modules/theora/doc_classes/VideoStreamTheora.xml +++ b/modules/theora/doc_classes/VideoStreamTheora.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VideoStreamTheora" inherits="VideoStream" category="Core" version="3.2"> +<class name="VideoStreamTheora" inherits="VideoStream" version="4.0"> <brief_description> + [VideoStream] resource for Ogg Theora videos. </brief_description> <description> + [VideoStream] resource handling the [url=https://www.theora.org/]Ogg Theora[/url] video format with [code].ogv[/code] extension. </description> <tutorials> </tutorials> @@ -11,6 +13,7 @@ <return type="String"> </return> <description> + Returns the Ogg Theora video file handled by this [VideoStreamTheora]. </description> </method> <method name="set_file"> @@ -19,6 +22,7 @@ <argument index="0" name="file" type="String"> </argument> <description> + Sets the Ogg Theora video file that this [VideoStreamTheora] resource handles. The [code]file[/code] name should have the [code].o[/code] extension. </description> </method> </methods> diff --git a/modules/theora/video_stream_theora.cpp b/modules/theora/video_stream_theora.cpp index 9ba77d3c77..cf1fc3f175 100644 --- a/modules/theora/video_stream_theora.cpp +++ b/modules/theora/video_stream_theora.cpp @@ -147,7 +147,6 @@ void VideoStreamPlaybackTheora::clear() { thread = NULL; ring_buffer.clear(); #endif - //file_name = ""; theora_p = 0; vorbis_p = 0; diff --git a/modules/tinyexr/image_loader_tinyexr.cpp b/modules/tinyexr/image_loader_tinyexr.cpp index bca3b749e3..79cb135abb 100644 --- a/modules/tinyexr/image_loader_tinyexr.cpp +++ b/modules/tinyexr/image_loader_tinyexr.cpp @@ -69,7 +69,7 @@ Error ImageLoaderTinyEXR::load_image(Ref<Image> p_image, FileAccess *f, bool p_f ret = ParseEXRHeaderFromMemory(&exr_header, &exr_version, w.ptr(), src_image_len, &err); if (ret != TINYEXR_SUCCESS) { if (err) { - ERR_PRINTS(String(err)); + ERR_PRINT(String(err)); } return ERR_FILE_CORRUPT; } @@ -85,7 +85,7 @@ Error ImageLoaderTinyEXR::load_image(Ref<Image> p_image, FileAccess *f, bool p_f ret = LoadEXRImageFromMemory(&exr_image, &exr_header, w.ptr(), src_image_len, &err); if (ret != TINYEXR_SUCCESS) { if (err) { - ERR_PRINTS(String(err)); + ERR_PRINT(String(err)); } return ERR_FILE_CORRUPT; } diff --git a/modules/upnp/doc_classes/UPNP.xml b/modules/upnp/doc_classes/UPNP.xml index aac0932995..8549c173db 100644 --- a/modules/upnp/doc_classes/UPNP.xml +++ b/modules/upnp/doc_classes/UPNP.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="UPNP" inherits="Reference" category="Core" version="3.2"> +<class name="UPNP" inherits="Reference" version="4.0"> <brief_description> UPNP network functions. </brief_description> diff --git a/modules/upnp/doc_classes/UPNPDevice.xml b/modules/upnp/doc_classes/UPNPDevice.xml index 4d3a0f4f1d..f3b96bb89d 100644 --- a/modules/upnp/doc_classes/UPNPDevice.xml +++ b/modules/upnp/doc_classes/UPNPDevice.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="UPNPDevice" inherits="Reference" category="Core" version="3.2"> +<class name="UPNPDevice" inherits="Reference" version="4.0"> <brief_description> UPNP device. </brief_description> diff --git a/modules/visual_script/doc_classes/@VisualScript.xml b/modules/visual_script/doc_classes/@VisualScript.xml index 8d9408e6d4..a2b966bfbb 100644 --- a/modules/visual_script/doc_classes/@VisualScript.xml +++ b/modules/visual_script/doc_classes/@VisualScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="@VisualScript" category="Core" version="3.2"> +<class name="@VisualScript" version="4.0"> <brief_description> Built-in visual script functions. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScript.xml b/modules/visual_script/doc_classes/VisualScript.xml index 0d95075152..9cd79aa781 100644 --- a/modules/visual_script/doc_classes/VisualScript.xml +++ b/modules/visual_script/doc_classes/VisualScript.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScript" inherits="Script" category="Core" version="3.2"> +<class name="VisualScript" inherits="Script" version="4.0"> <brief_description> A script implemented in the Visual Script programming environment. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptBasicTypeConstant.xml b/modules/visual_script/doc_classes/VisualScriptBasicTypeConstant.xml index 6dc54dbc03..c8e391c4a1 100644 --- a/modules/visual_script/doc_classes/VisualScriptBasicTypeConstant.xml +++ b/modules/visual_script/doc_classes/VisualScriptBasicTypeConstant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptBasicTypeConstant" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptBasicTypeConstant" inherits="VisualScriptNode" version="4.0"> <brief_description> A Visual Script node representing a constant from the base types. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptBuiltinFunc.xml b/modules/visual_script/doc_classes/VisualScriptBuiltinFunc.xml index b5b452ee47..95085d9652 100644 --- a/modules/visual_script/doc_classes/VisualScriptBuiltinFunc.xml +++ b/modules/visual_script/doc_classes/VisualScriptBuiltinFunc.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptBuiltinFunc" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptBuiltinFunc" inherits="VisualScriptNode" version="4.0"> <brief_description> A Visual Script node used to call built-in functions. </brief_description> @@ -203,7 +203,7 @@ Deserialize a [Variant] from a [PoolByteArray] serialized using [constant VAR_TO_BYTES]. </constant> <constant name="COLORN" value="63" enum="BuiltinFunc"> - Return the [Color] with the given name and alpha ranging from 0 to 1 + Return the [Color] with the given name and alpha ranging from 0 to 1. [b]Note:[/b] Names are defined in [code]color_names.inc[/code]. </constant> <constant name="MATH_SMOOTHSTEP" value="64" enum="BuiltinFunc"> diff --git a/modules/visual_script/doc_classes/VisualScriptClassConstant.xml b/modules/visual_script/doc_classes/VisualScriptClassConstant.xml index 49ea7850ef..cf35808823 100644 --- a/modules/visual_script/doc_classes/VisualScriptClassConstant.xml +++ b/modules/visual_script/doc_classes/VisualScriptClassConstant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptClassConstant" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptClassConstant" inherits="VisualScriptNode" version="4.0"> <brief_description> Gets a constant from a given class. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptComment.xml b/modules/visual_script/doc_classes/VisualScriptComment.xml index 2538bc8356..243338ea52 100644 --- a/modules/visual_script/doc_classes/VisualScriptComment.xml +++ b/modules/visual_script/doc_classes/VisualScriptComment.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptComment" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptComment" inherits="VisualScriptNode" version="4.0"> <brief_description> A Visual Script node used to annotate the script. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptComposeArray.xml b/modules/visual_script/doc_classes/VisualScriptComposeArray.xml index 92efbc51d1..dec182abf6 100644 --- a/modules/visual_script/doc_classes/VisualScriptComposeArray.xml +++ b/modules/visual_script/doc_classes/VisualScriptComposeArray.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptComposeArray" inherits="VisualScriptLists" category="Core" version="3.2"> +<class name="VisualScriptComposeArray" inherits="VisualScriptLists" version="4.0"> <brief_description> A Visual Script Node used to create array from a list of items. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptCondition.xml b/modules/visual_script/doc_classes/VisualScriptCondition.xml index 12d85429cf..a9981c1f57 100644 --- a/modules/visual_script/doc_classes/VisualScriptCondition.xml +++ b/modules/visual_script/doc_classes/VisualScriptCondition.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptCondition" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptCondition" inherits="VisualScriptNode" version="4.0"> <brief_description> A Visual Script node which branches the flow. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptConstant.xml b/modules/visual_script/doc_classes/VisualScriptConstant.xml index eb12fc3731..69676c4bba 100644 --- a/modules/visual_script/doc_classes/VisualScriptConstant.xml +++ b/modules/visual_script/doc_classes/VisualScriptConstant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptConstant" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptConstant" inherits="VisualScriptNode" version="4.0"> <brief_description> Gets a contant's value. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptConstructor.xml b/modules/visual_script/doc_classes/VisualScriptConstructor.xml index 8da5055d83..2f162e78b6 100644 --- a/modules/visual_script/doc_classes/VisualScriptConstructor.xml +++ b/modules/visual_script/doc_classes/VisualScriptConstructor.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptConstructor" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptConstructor" inherits="VisualScriptNode" version="4.0"> <brief_description> A Visual Script node which calls a base type constructor. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptCustomNode.xml b/modules/visual_script/doc_classes/VisualScriptCustomNode.xml index f70e22c7d0..1c23b58507 100644 --- a/modules/visual_script/doc_classes/VisualScriptCustomNode.xml +++ b/modules/visual_script/doc_classes/VisualScriptCustomNode.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptCustomNode" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptCustomNode" inherits="VisualScriptNode" version="4.0"> <brief_description> A scripted Visual Script node. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptDeconstruct.xml b/modules/visual_script/doc_classes/VisualScriptDeconstruct.xml index c8543287b4..530c80530e 100644 --- a/modules/visual_script/doc_classes/VisualScriptDeconstruct.xml +++ b/modules/visual_script/doc_classes/VisualScriptDeconstruct.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptDeconstruct" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptDeconstruct" inherits="VisualScriptNode" version="4.0"> <brief_description> A Visual Script node which deconstructs a base type instance into its parts. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptEditor.xml b/modules/visual_script/doc_classes/VisualScriptEditor.xml index add2eb2275..186cd21239 100644 --- a/modules/visual_script/doc_classes/VisualScriptEditor.xml +++ b/modules/visual_script/doc_classes/VisualScriptEditor.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptEditor" inherits="Object" category="Core" version="3.2"> +<class name="VisualScriptEditor" inherits="Object" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptEmitSignal.xml b/modules/visual_script/doc_classes/VisualScriptEmitSignal.xml index 1a567905a9..60a19ac7a7 100644 --- a/modules/visual_script/doc_classes/VisualScriptEmitSignal.xml +++ b/modules/visual_script/doc_classes/VisualScriptEmitSignal.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptEmitSignal" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptEmitSignal" inherits="VisualScriptNode" version="4.0"> <brief_description> Emits a specified signal. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptEngineSingleton.xml b/modules/visual_script/doc_classes/VisualScriptEngineSingleton.xml index 05bd87ec22..8b7fd3a612 100644 --- a/modules/visual_script/doc_classes/VisualScriptEngineSingleton.xml +++ b/modules/visual_script/doc_classes/VisualScriptEngineSingleton.xml @@ -1,10 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptEngineSingleton" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptEngineSingleton" inherits="VisualScriptNode" version="4.0"> <brief_description> - A Visual Script node returning a singleton from [@GlobalScope] + A Visual Script node returning a singleton from [@GlobalScope]. </brief_description> <description> - A Visual Script node returning a singleton from [@GlobalScope] + A Visual Script node returning a singleton from [@GlobalScope]. </description> <tutorials> </tutorials> diff --git a/modules/visual_script/doc_classes/VisualScriptExpression.xml b/modules/visual_script/doc_classes/VisualScriptExpression.xml index eb6cdbb302..5253f7bc7d 100644 --- a/modules/visual_script/doc_classes/VisualScriptExpression.xml +++ b/modules/visual_script/doc_classes/VisualScriptExpression.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptExpression" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptExpression" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptFunction.xml b/modules/visual_script/doc_classes/VisualScriptFunction.xml index 152b48ca89..873d26a5be 100644 --- a/modules/visual_script/doc_classes/VisualScriptFunction.xml +++ b/modules/visual_script/doc_classes/VisualScriptFunction.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptFunction" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptFunction" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptFunctionCall.xml b/modules/visual_script/doc_classes/VisualScriptFunctionCall.xml index f7f86e8c80..16c3af7ab2 100644 --- a/modules/visual_script/doc_classes/VisualScriptFunctionCall.xml +++ b/modules/visual_script/doc_classes/VisualScriptFunctionCall.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptFunctionCall" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptFunctionCall" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptFunctionState.xml b/modules/visual_script/doc_classes/VisualScriptFunctionState.xml index a8e820e6ea..68083614a6 100644 --- a/modules/visual_script/doc_classes/VisualScriptFunctionState.xml +++ b/modules/visual_script/doc_classes/VisualScriptFunctionState.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptFunctionState" inherits="Reference" category="Core" version="3.2"> +<class name="VisualScriptFunctionState" inherits="Reference" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptGlobalConstant.xml b/modules/visual_script/doc_classes/VisualScriptGlobalConstant.xml index 6c70dc7dc4..ef17bd8a28 100644 --- a/modules/visual_script/doc_classes/VisualScriptGlobalConstant.xml +++ b/modules/visual_script/doc_classes/VisualScriptGlobalConstant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptGlobalConstant" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptGlobalConstant" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptIndexGet.xml b/modules/visual_script/doc_classes/VisualScriptIndexGet.xml index ba0dc1a3d0..bb1618a655 100644 --- a/modules/visual_script/doc_classes/VisualScriptIndexGet.xml +++ b/modules/visual_script/doc_classes/VisualScriptIndexGet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptIndexGet" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptIndexGet" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptIndexSet.xml b/modules/visual_script/doc_classes/VisualScriptIndexSet.xml index 09a8f2c8ad..4ff96f7211 100644 --- a/modules/visual_script/doc_classes/VisualScriptIndexSet.xml +++ b/modules/visual_script/doc_classes/VisualScriptIndexSet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptIndexSet" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptIndexSet" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptInputAction.xml b/modules/visual_script/doc_classes/VisualScriptInputAction.xml index 8c942813b2..0b6325bf0a 100644 --- a/modules/visual_script/doc_classes/VisualScriptInputAction.xml +++ b/modules/visual_script/doc_classes/VisualScriptInputAction.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptInputAction" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptInputAction" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptIterator.xml b/modules/visual_script/doc_classes/VisualScriptIterator.xml index 782bbfae20..1d4ab4daa9 100644 --- a/modules/visual_script/doc_classes/VisualScriptIterator.xml +++ b/modules/visual_script/doc_classes/VisualScriptIterator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptIterator" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptIterator" inherits="VisualScriptNode" version="4.0"> <brief_description> Steps through items in a given input. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptLists.xml b/modules/visual_script/doc_classes/VisualScriptLists.xml index 8cf3eb1d38..5b64d8438b 100644 --- a/modules/visual_script/doc_classes/VisualScriptLists.xml +++ b/modules/visual_script/doc_classes/VisualScriptLists.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptLists" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptLists" inherits="VisualScriptNode" version="4.0"> <brief_description> A Visual Script virtual class for in-graph editable nodes. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptLocalVar.xml b/modules/visual_script/doc_classes/VisualScriptLocalVar.xml index 8c21c3f0bc..6c31ae1a30 100644 --- a/modules/visual_script/doc_classes/VisualScriptLocalVar.xml +++ b/modules/visual_script/doc_classes/VisualScriptLocalVar.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptLocalVar" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptLocalVar" inherits="VisualScriptNode" version="4.0"> <brief_description> Gets a local variable's value. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptLocalVarSet.xml b/modules/visual_script/doc_classes/VisualScriptLocalVarSet.xml index a981432cdb..0a9a509958 100644 --- a/modules/visual_script/doc_classes/VisualScriptLocalVarSet.xml +++ b/modules/visual_script/doc_classes/VisualScriptLocalVarSet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptLocalVarSet" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptLocalVarSet" inherits="VisualScriptNode" version="4.0"> <brief_description> Changes a local variable's value. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptMathConstant.xml b/modules/visual_script/doc_classes/VisualScriptMathConstant.xml index 3be392aef5..18a1f030bc 100644 --- a/modules/visual_script/doc_classes/VisualScriptMathConstant.xml +++ b/modules/visual_script/doc_classes/VisualScriptMathConstant.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptMathConstant" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptMathConstant" inherits="VisualScriptNode" version="4.0"> <brief_description> Commonly used mathematical constants. </brief_description> @@ -21,28 +21,28 @@ </members> <constants> <constant name="MATH_CONSTANT_ONE" value="0" enum="MathConstant"> - Unity: [code]1[/code] + Unity: [code]1[/code]. </constant> <constant name="MATH_CONSTANT_PI" value="1" enum="MathConstant"> - Pi: [code]3.141593[/code] + Pi: [code]3.141593[/code]. </constant> <constant name="MATH_CONSTANT_HALF_PI" value="2" enum="MathConstant"> - Pi divided by two: [code]1.570796[/code] + Pi divided by two: [code]1.570796[/code]. </constant> <constant name="MATH_CONSTANT_TAU" value="3" enum="MathConstant"> - Tau: [code]6.283185[/code] + Tau: [code]6.283185[/code]. </constant> <constant name="MATH_CONSTANT_E" value="4" enum="MathConstant"> - Mathematical constant [code]e[/code], the natural log base: [code]2.718282[/code] + Mathematical constant [code]e[/code], the natural log base: [code]2.718282[/code]. </constant> <constant name="MATH_CONSTANT_SQRT2" value="5" enum="MathConstant"> - Square root of two: [code]1.414214[/code] + Square root of two: [code]1.414214[/code]. </constant> <constant name="MATH_CONSTANT_INF" value="6" enum="MathConstant"> - Infinity: [code]inf[/code] + Infinity: [code]inf[/code]. </constant> <constant name="MATH_CONSTANT_NAN" value="7" enum="MathConstant"> - Not a number: [code]nan[/code] + Not a number: [code]nan[/code]. </constant> <constant name="MATH_CONSTANT_MAX" value="8" enum="MathConstant"> Represents the size of the [enum MathConstant] enum. diff --git a/modules/visual_script/doc_classes/VisualScriptNode.xml b/modules/visual_script/doc_classes/VisualScriptNode.xml index 89fb5c81f8..82a023f3e4 100644 --- a/modules/visual_script/doc_classes/VisualScriptNode.xml +++ b/modules/visual_script/doc_classes/VisualScriptNode.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptNode" inherits="Resource" category="Core" version="3.2"> +<class name="VisualScriptNode" inherits="Resource" version="4.0"> <brief_description> A node which is part of a [VisualScript]. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptOperator.xml b/modules/visual_script/doc_classes/VisualScriptOperator.xml index 80449ac521..c8ce0f2732 100644 --- a/modules/visual_script/doc_classes/VisualScriptOperator.xml +++ b/modules/visual_script/doc_classes/VisualScriptOperator.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptOperator" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptOperator" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptPreload.xml b/modules/visual_script/doc_classes/VisualScriptPreload.xml index b3b39691c9..e11af6c805 100644 --- a/modules/visual_script/doc_classes/VisualScriptPreload.xml +++ b/modules/visual_script/doc_classes/VisualScriptPreload.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptPreload" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptPreload" inherits="VisualScriptNode" version="4.0"> <brief_description> Creates a new [Resource] or loads one from the filesystem. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptPropertyGet.xml b/modules/visual_script/doc_classes/VisualScriptPropertyGet.xml index af1e8e68e8..cf436116b8 100644 --- a/modules/visual_script/doc_classes/VisualScriptPropertyGet.xml +++ b/modules/visual_script/doc_classes/VisualScriptPropertyGet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptPropertyGet" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptPropertyGet" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptPropertySet.xml b/modules/visual_script/doc_classes/VisualScriptPropertySet.xml index 380c196caf..357b4b9f5c 100644 --- a/modules/visual_script/doc_classes/VisualScriptPropertySet.xml +++ b/modules/visual_script/doc_classes/VisualScriptPropertySet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptPropertySet" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptPropertySet" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptResourcePath.xml b/modules/visual_script/doc_classes/VisualScriptResourcePath.xml index da37bbbb2c..ea891be05f 100644 --- a/modules/visual_script/doc_classes/VisualScriptResourcePath.xml +++ b/modules/visual_script/doc_classes/VisualScriptResourcePath.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptResourcePath" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptResourcePath" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptReturn.xml b/modules/visual_script/doc_classes/VisualScriptReturn.xml index 9a81c671d4..502628925d 100644 --- a/modules/visual_script/doc_classes/VisualScriptReturn.xml +++ b/modules/visual_script/doc_classes/VisualScriptReturn.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptReturn" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptReturn" inherits="VisualScriptNode" version="4.0"> <brief_description> Exits a function and returns an optional value. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptSceneNode.xml b/modules/visual_script/doc_classes/VisualScriptSceneNode.xml index 99f4acbd27..ffe187a00e 100644 --- a/modules/visual_script/doc_classes/VisualScriptSceneNode.xml +++ b/modules/visual_script/doc_classes/VisualScriptSceneNode.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptSceneNode" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptSceneNode" inherits="VisualScriptNode" version="4.0"> <brief_description> Node reference. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptSceneTree.xml b/modules/visual_script/doc_classes/VisualScriptSceneTree.xml index 84718ba119..191d4b6977 100644 --- a/modules/visual_script/doc_classes/VisualScriptSceneTree.xml +++ b/modules/visual_script/doc_classes/VisualScriptSceneTree.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptSceneTree" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptSceneTree" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptSelect.xml b/modules/visual_script/doc_classes/VisualScriptSelect.xml index e6a6cd5a48..1dbc066e32 100644 --- a/modules/visual_script/doc_classes/VisualScriptSelect.xml +++ b/modules/visual_script/doc_classes/VisualScriptSelect.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptSelect" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptSelect" inherits="VisualScriptNode" version="4.0"> <brief_description> Chooses between two input values. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptSelf.xml b/modules/visual_script/doc_classes/VisualScriptSelf.xml index 231e7d8f0d..bb24f158c1 100644 --- a/modules/visual_script/doc_classes/VisualScriptSelf.xml +++ b/modules/visual_script/doc_classes/VisualScriptSelf.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptSelf" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptSelf" inherits="VisualScriptNode" version="4.0"> <brief_description> Outputs a reference to the current instance. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptSequence.xml b/modules/visual_script/doc_classes/VisualScriptSequence.xml index 2ceceb199f..664722574d 100644 --- a/modules/visual_script/doc_classes/VisualScriptSequence.xml +++ b/modules/visual_script/doc_classes/VisualScriptSequence.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptSequence" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptSequence" inherits="VisualScriptNode" version="4.0"> <brief_description> Executes a series of Sequence ports. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptSubCall.xml b/modules/visual_script/doc_classes/VisualScriptSubCall.xml index 51b0093209..cb3b04b583 100644 --- a/modules/visual_script/doc_classes/VisualScriptSubCall.xml +++ b/modules/visual_script/doc_classes/VisualScriptSubCall.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptSubCall" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptSubCall" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptSwitch.xml b/modules/visual_script/doc_classes/VisualScriptSwitch.xml index 3e3b88ebe0..74504948f0 100644 --- a/modules/visual_script/doc_classes/VisualScriptSwitch.xml +++ b/modules/visual_script/doc_classes/VisualScriptSwitch.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptSwitch" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptSwitch" inherits="VisualScriptNode" version="4.0"> <brief_description> Branches program flow based on a given input's value. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptTypeCast.xml b/modules/visual_script/doc_classes/VisualScriptTypeCast.xml index 999a190a9a..43fe9d16ea 100644 --- a/modules/visual_script/doc_classes/VisualScriptTypeCast.xml +++ b/modules/visual_script/doc_classes/VisualScriptTypeCast.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptTypeCast" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptTypeCast" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptVariableGet.xml b/modules/visual_script/doc_classes/VisualScriptVariableGet.xml index 40e461294b..0746ab293e 100644 --- a/modules/visual_script/doc_classes/VisualScriptVariableGet.xml +++ b/modules/visual_script/doc_classes/VisualScriptVariableGet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptVariableGet" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptVariableGet" inherits="VisualScriptNode" version="4.0"> <brief_description> Gets a variable's value. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptVariableSet.xml b/modules/visual_script/doc_classes/VisualScriptVariableSet.xml index 6c53ad61b4..e7d83e60ab 100644 --- a/modules/visual_script/doc_classes/VisualScriptVariableSet.xml +++ b/modules/visual_script/doc_classes/VisualScriptVariableSet.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptVariableSet" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptVariableSet" inherits="VisualScriptNode" version="4.0"> <brief_description> Changes a variable's value. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptWhile.xml b/modules/visual_script/doc_classes/VisualScriptWhile.xml index 77211fa088..f187957ad2 100644 --- a/modules/visual_script/doc_classes/VisualScriptWhile.xml +++ b/modules/visual_script/doc_classes/VisualScriptWhile.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptWhile" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptWhile" inherits="VisualScriptNode" version="4.0"> <brief_description> Conditional loop. </brief_description> diff --git a/modules/visual_script/doc_classes/VisualScriptYield.xml b/modules/visual_script/doc_classes/VisualScriptYield.xml index c506e6db01..0a8d529a48 100644 --- a/modules/visual_script/doc_classes/VisualScriptYield.xml +++ b/modules/visual_script/doc_classes/VisualScriptYield.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptYield" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptYield" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/doc_classes/VisualScriptYieldSignal.xml b/modules/visual_script/doc_classes/VisualScriptYieldSignal.xml index b9d7aedaab..8f6941ce1e 100644 --- a/modules/visual_script/doc_classes/VisualScriptYieldSignal.xml +++ b/modules/visual_script/doc_classes/VisualScriptYieldSignal.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VisualScriptYieldSignal" inherits="VisualScriptNode" category="Core" version="3.2"> +<class name="VisualScriptYieldSignal" inherits="VisualScriptNode" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/visual_script/visual_script_editor.cpp b/modules/visual_script/visual_script_editor.cpp index 4bfd4f48ce..ec20698ae8 100644 --- a/modules/visual_script/visual_script_editor.cpp +++ b/modules/visual_script/visual_script_editor.cpp @@ -575,7 +575,7 @@ void VisualScriptEditor::_update_graph(int p_only_id) { Button *btn = memnew(Button); btn->set_text(TTR("Add Input Port")); hbnc->add_child(btn); - btn->connect("pressed", this, "_add_input_port", varray(E->get())); + btn->connect("pressed", this, "_add_input_port", varray(E->get()), CONNECT_DEFERRED); } if (nd_list->is_output_port_editable()) { if (nd_list->is_input_port_editable()) @@ -584,7 +584,7 @@ void VisualScriptEditor::_update_graph(int p_only_id) { Button *btn = memnew(Button); btn->set_text(TTR("Add Output Port")); hbnc->add_child(btn); - btn->connect("pressed", this, "_add_output_port", varray(E->get())); + btn->connect("pressed", this, "_add_output_port", varray(E->get()), CONNECT_DEFERRED); } gnode->add_child(hbnc); } else if (Object::cast_to<VisualScriptExpression>(node.ptr())) { diff --git a/modules/visual_script/visual_script_nodes.cpp b/modules/visual_script/visual_script_nodes.cpp index 0a9f228b0a..36cafeec73 100644 --- a/modules/visual_script/visual_script_nodes.cpp +++ b/modules/visual_script/visual_script_nodes.cpp @@ -1842,7 +1842,7 @@ PropertyInfo VisualScriptGlobalConstant::get_input_value_port_info(int p_idx) co PropertyInfo VisualScriptGlobalConstant::get_output_value_port_info(int p_idx) const { String name = GlobalConstants::get_global_constant_name(index); - return PropertyInfo(Variant::REAL, name); + return PropertyInfo(Variant::INT, name); } String VisualScriptGlobalConstant::get_caption() const { @@ -2060,7 +2060,7 @@ PropertyInfo VisualScriptBasicTypeConstant::get_input_value_port_info(int p_idx) PropertyInfo VisualScriptBasicTypeConstant::get_output_value_port_info(int p_idx) const { - return PropertyInfo(Variant::INT, "value"); + return PropertyInfo(type, "value"); } String VisualScriptBasicTypeConstant::get_caption() const { @@ -2069,8 +2069,11 @@ String VisualScriptBasicTypeConstant::get_caption() const { } String VisualScriptBasicTypeConstant::get_text() const { - - return Variant::get_type_name(type) + "." + String(name); + if (name == "") { + return Variant::get_type_name(type); + } else { + return Variant::get_type_name(type) + "." + String(name); + } } void VisualScriptBasicTypeConstant::set_basic_type_constant(const StringName &p_which) { @@ -2087,6 +2090,23 @@ StringName VisualScriptBasicTypeConstant::get_basic_type_constant() const { void VisualScriptBasicTypeConstant::set_basic_type(Variant::Type p_which) { type = p_which; + + List<StringName> constants; + Variant::get_constants_for_type(type, &constants); + if (constants.size() > 0) { + bool found_name = false; + for (List<StringName>::Element *E = constants.front(); E; E = E->next()) { + if (E->get() == name) { + found_name = true; + break; + } + } + if (!found_name) { + name = constants[0]; + } + } else { + name = ""; + } _change_notify(); ports_changed_notify(); } @@ -2377,10 +2397,7 @@ VisualScriptEngineSingleton::TypeGuess VisualScriptEngineSingleton::guess_output return tg; } -void VisualScriptEngineSingleton::_bind_methods() { - - ClassDB::bind_method(D_METHOD("set_singleton", "name"), &VisualScriptEngineSingleton::set_singleton); - ClassDB::bind_method(D_METHOD("get_singleton"), &VisualScriptEngineSingleton::get_singleton); +void VisualScriptEngineSingleton::_validate_property(PropertyInfo &property) const { String cc; @@ -2397,7 +2414,16 @@ void VisualScriptEngineSingleton::_bind_methods() { cc += E->get().name; } - ADD_PROPERTY(PropertyInfo(Variant::STRING, "constant", PROPERTY_HINT_ENUM, cc), "set_singleton", "get_singleton"); + property.hint = PROPERTY_HINT_ENUM; + property.hint_string = cc; +} + +void VisualScriptEngineSingleton::_bind_methods() { + + ClassDB::bind_method(D_METHOD("set_singleton", "name"), &VisualScriptEngineSingleton::set_singleton); + ClassDB::bind_method(D_METHOD("get_singleton"), &VisualScriptEngineSingleton::get_singleton); + + ADD_PROPERTY(PropertyInfo(Variant::STRING, "constant"), "set_singleton", "get_singleton"); } VisualScriptEngineSingleton::VisualScriptEngineSingleton() { diff --git a/modules/visual_script/visual_script_nodes.h b/modules/visual_script/visual_script_nodes.h index fe44af277f..0df5071491 100644 --- a/modules/visual_script/visual_script_nodes.h +++ b/modules/visual_script/visual_script_nodes.h @@ -614,6 +614,9 @@ class VisualScriptEngineSingleton : public VisualScriptNode { String singleton; +protected: + void _validate_property(PropertyInfo &property) const; + static void _bind_methods(); public: diff --git a/modules/webm/doc_classes/VideoStreamWebm.xml b/modules/webm/doc_classes/VideoStreamWebm.xml index ff11bbb37d..dfa04720cf 100644 --- a/modules/webm/doc_classes/VideoStreamWebm.xml +++ b/modules/webm/doc_classes/VideoStreamWebm.xml @@ -1,8 +1,10 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="VideoStreamWebm" inherits="VideoStream" category="Core" version="3.2"> +<class name="VideoStreamWebm" inherits="VideoStream" version="4.0"> <brief_description> + [VideoStream] resource for WebM videos. </brief_description> <description> + [VideoStream] resource handling the [url=https://www.webmproject.org/]WebM[/url] video format with [code].webm[/code] extension. </description> <tutorials> </tutorials> @@ -11,6 +13,7 @@ <return type="String"> </return> <description> + Returns the WebM video file handled by this [VideoStreamWebm]. </description> </method> <method name="set_file"> @@ -19,6 +22,7 @@ <argument index="0" name="file" type="String"> </argument> <description> + Sets the WebM video file that this [VideoStreamWebm] resource handles. The [code]file[/code] name should have the [code].webm[/code] extension. </description> </method> </methods> diff --git a/modules/webm/video_stream_webm.cpp b/modules/webm/video_stream_webm.cpp index 6e2527595b..41f9e67672 100644 --- a/modules/webm/video_stream_webm.cpp +++ b/modules/webm/video_stream_webm.cpp @@ -30,21 +30,22 @@ #include "video_stream_webm.h" -#include "OpusVorbisDecoder.hpp" -#include "VPXDecoder.hpp" -#include <vpx/vpx_image.h> - -#include "mkvparser/mkvparser.h" - #include "core/os/file_access.h" #include "core/os/os.h" #include "core/project_settings.h" +#include "servers/audio_server.h" #include "thirdparty/misc/yuv2rgb.h" -#include "servers/audio_server.h" +// libsimplewebm +#include <OpusVorbisDecoder.hpp> +#include <VPXDecoder.hpp> + +// libvpx +#include <vpx/vpx_image.h> -#include <string.h> +// libwebm +#include <mkvparser/mkvparser.h> class MkvReader : public mkvparser::IMkvReader { @@ -335,22 +336,22 @@ void VideoStreamPlaybackWebm::update(float p_delta) { } else if (image.chromaShiftW == 1 && image.chromaShiftH == 1) { yuv420_2_rgb8888(w.ptr(), image.planes[0], image.planes[1], image.planes[2], image.w, image.h, image.linesize[0], image.linesize[1], image.w << 2); - // libyuv::I420ToARGB(image.planes[0], image.linesize[0], image.planes[2], image.linesize[2], image.planes[1], image.linesize[1], w.ptr(), image.w << 2, image.w, image.h); + //libyuv::I420ToARGB(image.planes[0], image.linesize[0], image.planes[2], image.linesize[2], image.planes[1], image.linesize[1], w.ptr(), image.w << 2, image.w, image.h); converted = true; } else if (image.chromaShiftW == 1 && image.chromaShiftH == 0) { yuv422_2_rgb8888(w.ptr(), image.planes[0], image.planes[1], image.planes[2], image.w, image.h, image.linesize[0], image.linesize[1], image.w << 2); - // libyuv::I422ToARGB(image.planes[0], image.linesize[0], image.planes[2], image.linesize[2], image.planes[1], image.linesize[1], w.ptr(), image.w << 2, image.w, image.h); + //libyuv::I422ToARGB(image.planes[0], image.linesize[0], image.planes[2], image.linesize[2], image.planes[1], image.linesize[1], w.ptr(), image.w << 2, image.w, image.h); converted = true; } else if (image.chromaShiftW == 0 && image.chromaShiftH == 0) { yuv444_2_rgb8888(w.ptr(), image.planes[0], image.planes[1], image.planes[2], image.w, image.h, image.linesize[0], image.linesize[1], image.w << 2); - // libyuv::I444ToARGB(image.planes[0], image.linesize[0], image.planes[2], image.linesize[2], image.planes[1], image.linesize[1], w.ptr(), image.w << 2, image.w, image.h); + //libyuv::I444ToARGB(image.planes[0], image.linesize[0], image.planes[2], image.linesize[2], image.planes[1], image.linesize[1], w.ptr(), image.w << 2, image.w, image.h); converted = true; } else if (image.chromaShiftW == 2 && image.chromaShiftH == 0) { - // libyuv::I411ToARGB(image.planes[0], image.linesize[0], image.planes[2], image.linesize[2], image.planes[1], image.linesize[1], w.ptr(), image.w << 2, image.w, image.h); - // converted = true; + //libyuv::I411ToARGB(image.planes[0], image.linesize[0], image.planes[2], image.linesize[2] image.planes[1], image.linesize[1], w.ptr(), image.w << 2, image.w, image.h); + //converted = true; } if (converted) { diff --git a/modules/webrtc/doc_classes/WebRTCDataChannel.xml b/modules/webrtc/doc_classes/WebRTCDataChannel.xml index 98715ee99b..5c90038b9a 100644 --- a/modules/webrtc/doc_classes/WebRTCDataChannel.xml +++ b/modules/webrtc/doc_classes/WebRTCDataChannel.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebRTCDataChannel" inherits="PacketPeer" category="Core" version="3.2"> +<class name="WebRTCDataChannel" inherits="PacketPeer" version="4.0"> <brief_description> </brief_description> <description> diff --git a/modules/webrtc/doc_classes/WebRTCMultiplayer.xml b/modules/webrtc/doc_classes/WebRTCMultiplayer.xml index 605b1ef082..5b9459bc27 100644 --- a/modules/webrtc/doc_classes/WebRTCMultiplayer.xml +++ b/modules/webrtc/doc_classes/WebRTCMultiplayer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebRTCMultiplayer" inherits="NetworkedMultiplayerPeer" category="Core" version="3.2"> +<class name="WebRTCMultiplayer" inherits="NetworkedMultiplayerPeer" version="4.0"> <brief_description> A simple interface to create a peer-to-peer mesh network composed of [WebRTCPeerConnection] that is compatible with the [MultiplayerAPI]. </brief_description> @@ -45,7 +45,7 @@ <return type="Dictionary"> </return> <description> - Returns a dictionary which keys are the peer ids and values the peer representation as in [method get_peer] + Returns a dictionary which keys are the peer ids and values the peer representation as in [method get_peer]. </description> </method> <method name="has_peer"> diff --git a/modules/webrtc/doc_classes/WebRTCPeerConnection.xml b/modules/webrtc/doc_classes/WebRTCPeerConnection.xml index 26082d73a8..504b4705d8 100644 --- a/modules/webrtc/doc_classes/WebRTCPeerConnection.xml +++ b/modules/webrtc/doc_classes/WebRTCPeerConnection.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebRTCPeerConnection" inherits="Reference" category="Core" version="3.2"> +<class name="WebRTCPeerConnection" inherits="Reference" version="4.0"> <brief_description> Interface to a WebRTC peer connection. </brief_description> @@ -143,7 +143,7 @@ </argument> <description> Emitted when a new in-band channel is received, i.e. when the channel was created with [code]negotiated: false[/code] (default). - The object will be an instance of [WebRTCDataChannel]. You must keep a reference of it or it will be closed automatically. See [method create_data_channel] + The object will be an instance of [WebRTCDataChannel]. You must keep a reference of it or it will be closed automatically. See [method create_data_channel]. </description> </signal> <signal name="ice_candidate_created"> diff --git a/modules/websocket/doc_classes/WebSocketClient.xml b/modules/websocket/doc_classes/WebSocketClient.xml index 705e3485f5..2549321db3 100644 --- a/modules/websocket/doc_classes/WebSocketClient.xml +++ b/modules/websocket/doc_classes/WebSocketClient.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebSocketClient" inherits="WebSocketMultiplayerPeer" category="Core" version="3.2"> +<class name="WebSocketClient" inherits="WebSocketMultiplayerPeer" version="4.0"> <brief_description> A WebSocket client implementation. </brief_description> @@ -27,7 +27,8 @@ Connects to the given URL requesting one of the given [code]protocols[/code] as sub-protocol. If the list empty (default), no sub-protocol will be requested. If [code]true[/code] is passed as [code]gd_mp_api[/code], the client will behave like a network peer for the [MultiplayerAPI], connections to non-Godot servers will not work, and [signal data_received] will not be emitted. If [code]false[/code] is passed instead (default), you must call [PacketPeer] functions ([code]put_packet[/code], [code]get_packet[/code], etc.) on the [WebSocketPeer] returned via [code]get_peer(1)[/code] and not on this object directly (e.g. [code]get_peer(1).put_packet(data)[/code]). - You can optionally pass a list of [code]custom_headers[/code] to be added to the handshake HTTP request (not supported in HTML5 platform). + You can optionally pass a list of [code]custom_headers[/code] to be added to the handshake HTTP request. + [b]Note:[/b] Specifying [code]custom_headers[/code] is not supported in HTML5 exports due to browsers restrictions. </description> </method> <method name="disconnect_from_host"> @@ -59,6 +60,7 @@ <members> <member name="trusted_ssl_certificate" type="X509Certificate" setter="set_trusted_ssl_certificate" getter="get_trusted_ssl_certificate"> If specified, this [X509Certificate] will be the only one accepted when connecting to an SSL host. Any other certificate provided by the server will be regarded as invalid. + [b]Note:[/b] Specifying a custom [code]trusted_ssl_certificate[/code] is not supported in HTML5 exports due to browsers restrictions. </member> <member name="verify_ssl" type="bool" setter="set_verify_ssl_enabled" getter="is_verify_ssl_enabled"> If [code]true[/code], SSL certificate verification is enabled. diff --git a/modules/websocket/doc_classes/WebSocketMultiplayerPeer.xml b/modules/websocket/doc_classes/WebSocketMultiplayerPeer.xml index 7070cfbdab..0679acf78a 100644 --- a/modules/websocket/doc_classes/WebSocketMultiplayerPeer.xml +++ b/modules/websocket/doc_classes/WebSocketMultiplayerPeer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebSocketMultiplayerPeer" inherits="NetworkedMultiplayerPeer" category="Core" version="3.2"> +<class name="WebSocketMultiplayerPeer" inherits="NetworkedMultiplayerPeer" version="4.0"> <brief_description> Base class for WebSocket server and client. </brief_description> diff --git a/modules/websocket/doc_classes/WebSocketPeer.xml b/modules/websocket/doc_classes/WebSocketPeer.xml index dd95f7432e..5125956416 100644 --- a/modules/websocket/doc_classes/WebSocketPeer.xml +++ b/modules/websocket/doc_classes/WebSocketPeer.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebSocketPeer" inherits="PacketPeer" category="Core" version="3.2"> +<class name="WebSocketPeer" inherits="PacketPeer" version="4.0"> <brief_description> A class representing a specific WebSocket connection. </brief_description> @@ -53,6 +53,16 @@ Returns [code]true[/code] if this peer is currently connected. </description> </method> + <method name="set_no_delay"> + <return type="void"> + </return> + <argument index="0" name="enabled" type="bool"> + </argument> + <description> + Disable Nagle's algorithm on the underling TCP socket (default). See [method StreamPeerTCP.set_no_delay] for more information. + [b]Note:[/b] Not available in the HTML5 export. + </description> + </method> <method name="set_write_mode"> <return type="void"> </return> @@ -66,7 +76,7 @@ <return type="bool"> </return> <description> - Returns [code]true[/code] if the last received packet was sent as a text payload. See [enum WriteMode] + Returns [code]true[/code] if the last received packet was sent as a text payload. See [enum WriteMode]. </description> </method> </methods> diff --git a/modules/websocket/doc_classes/WebSocketServer.xml b/modules/websocket/doc_classes/WebSocketServer.xml index 86f2dae64f..f66e1bf54b 100644 --- a/modules/websocket/doc_classes/WebSocketServer.xml +++ b/modules/websocket/doc_classes/WebSocketServer.xml @@ -1,12 +1,12 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="WebSocketServer" inherits="WebSocketMultiplayerPeer" category="Core" version="3.2"> +<class name="WebSocketServer" inherits="WebSocketMultiplayerPeer" version="4.0"> <brief_description> A WebSocket server implementation. </brief_description> <description> This class implements a WebSocket server that can also support the high-level multiplayer API. After starting the server ([method listen]), you will need to [method NetworkedMultiplayerPeer.poll] it at regular intervals (e.g. inside [method Node._process]). When clients connect, disconnect, or send data, you will receive the appropriate signal. - [b]Note:[/b] This class will not work in HTML5 exports due to browser restrictions. + [b]Note:[/b] Not available in HTML5 exports. </description> <tutorials> </tutorials> @@ -83,6 +83,9 @@ </method> </methods> <members> + <member name="bind_ip" type="String" setter="set_bind_ip" getter="get_bind_ip" default=""*""> + When not set to [code]*[/code] will restrict incoming connections to the specified IP address. Setting [code]bind_ip[/code] to [code]127.0.0.1[/code] will cause the server to listen only to the local host. + </member> <member name="ca_chain" type="X509Certificate" setter="set_ca_chain" getter="get_ca_chain"> When using SSL (see [member private_key] and [member ssl_certificate]), you can set this to a valid [X509Certificate] to be provided as additional CA chain information during the SSL handshake. </member> diff --git a/modules/websocket/emws_peer.cpp b/modules/websocket/emws_peer.cpp index d07360c525..effed8e4d9 100644 --- a/modules/websocket/emws_peer.cpp +++ b/modules/websocket/emws_peer.cpp @@ -139,6 +139,11 @@ uint16_t EMWSPeer::get_connected_port() const { ERR_FAIL_V_MSG(0, "Not supported in HTML5 export."); }; +void EMWSPeer::set_no_delay(bool p_enabled) { + + ERR_FAIL_MSG("'set_no_delay' is not supported in HTML5 export."); +} + EMWSPeer::EMWSPeer() { peer_sock = -1; write_mode = WRITE_MODE_BINARY; diff --git a/modules/websocket/emws_peer.h b/modules/websocket/emws_peer.h index 9fe7fb8edc..43b42f9be6 100644 --- a/modules/websocket/emws_peer.h +++ b/modules/websocket/emws_peer.h @@ -68,6 +68,7 @@ public: virtual WriteMode get_write_mode() const; virtual void set_write_mode(WriteMode p_mode); virtual bool was_string_packet() const; + virtual void set_no_delay(bool p_enabled); EMWSPeer(); ~EMWSPeer(); diff --git a/modules/websocket/websocket_multiplayer_peer.cpp b/modules/websocket/websocket_multiplayer_peer.cpp index b639c635fd..27ea50b524 100644 --- a/modules/websocket/websocket_multiplayer_peer.cpp +++ b/modules/websocket/websocket_multiplayer_peer.cpp @@ -98,7 +98,7 @@ void WebSocketMultiplayerPeer::_bind_methods() { // int WebSocketMultiplayerPeer::get_available_packet_count() const { - ERR_FAIL_COND_V_MSG(!_is_multiplayer, ERR_UNCONFIGURED, "Please use get_peer(ID).get_available_packet_count to get available packet count from peers when not using the MultiplayerAPI."); + ERR_FAIL_COND_V_MSG(!_is_multiplayer, 0, "Please use get_peer(ID).get_available_packet_count to get available packet count from peers when not using the MultiplayerAPI."); return _incoming_packets.size(); } diff --git a/modules/websocket/websocket_peer.cpp b/modules/websocket/websocket_peer.cpp index 474b11f012..30a5972330 100644 --- a/modules/websocket/websocket_peer.cpp +++ b/modules/websocket/websocket_peer.cpp @@ -46,6 +46,7 @@ void WebSocketPeer::_bind_methods() { ClassDB::bind_method(D_METHOD("close", "code", "reason"), &WebSocketPeer::close, DEFVAL(1000), DEFVAL("")); ClassDB::bind_method(D_METHOD("get_connected_host"), &WebSocketPeer::get_connected_host); ClassDB::bind_method(D_METHOD("get_connected_port"), &WebSocketPeer::get_connected_port); + ClassDB::bind_method(D_METHOD("set_no_delay", "enabled"), &WebSocketPeer::set_no_delay); BIND_ENUM_CONSTANT(WRITE_MODE_TEXT); BIND_ENUM_CONSTANT(WRITE_MODE_BINARY); diff --git a/modules/websocket/websocket_peer.h b/modules/websocket/websocket_peer.h index c4e1984aa0..d4173600ec 100644 --- a/modules/websocket/websocket_peer.h +++ b/modules/websocket/websocket_peer.h @@ -64,6 +64,7 @@ public: virtual IP_Address get_connected_host() const = 0; virtual uint16_t get_connected_port() const = 0; virtual bool was_string_packet() const = 0; + virtual void set_no_delay(bool p_enabled) = 0; WebSocketPeer(); ~WebSocketPeer(); diff --git a/modules/websocket/websocket_server.cpp b/modules/websocket/websocket_server.cpp index ded1850846..a7ced65543 100644 --- a/modules/websocket/websocket_server.cpp +++ b/modules/websocket/websocket_server.cpp @@ -34,6 +34,7 @@ GDCINULL(WebSocketServer); WebSocketServer::WebSocketServer() { _peer_id = 1; + bind_ip = IP_Address("*"); } WebSocketServer::~WebSocketServer() { @@ -49,6 +50,10 @@ void WebSocketServer::_bind_methods() { ClassDB::bind_method(D_METHOD("get_peer_port", "id"), &WebSocketServer::get_peer_port); ClassDB::bind_method(D_METHOD("disconnect_peer", "id", "code", "reason"), &WebSocketServer::disconnect_peer, DEFVAL(1000), DEFVAL("")); + ClassDB::bind_method(D_METHOD("get_bind_ip"), &WebSocketServer::get_bind_ip); + ClassDB::bind_method(D_METHOD("set_bind_ip"), &WebSocketServer::set_bind_ip); + ADD_PROPERTY(PropertyInfo(Variant::STRING, "bind_ip"), "set_bind_ip", "get_bind_ip"); + ClassDB::bind_method(D_METHOD("get_private_key"), &WebSocketServer::get_private_key); ClassDB::bind_method(D_METHOD("set_private_key"), &WebSocketServer::set_private_key); ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "private_key", PROPERTY_HINT_RESOURCE_TYPE, "CryptoKey", 0), "set_private_key", "get_private_key"); @@ -67,6 +72,16 @@ void WebSocketServer::_bind_methods() { ADD_SIGNAL(MethodInfo("data_received", PropertyInfo(Variant::INT, "id"))); } +IP_Address WebSocketServer::get_bind_ip() const { + return bind_ip; +} + +void WebSocketServer::set_bind_ip(const IP_Address &p_bind_ip) { + ERR_FAIL_COND(is_listening()); + ERR_FAIL_COND(!p_bind_ip.is_valid() && !p_bind_ip.is_wildcard()); + bind_ip = p_bind_ip; +} + Ref<CryptoKey> WebSocketServer::get_private_key() const { return private_key; } @@ -99,7 +114,7 @@ NetworkedMultiplayerPeer::ConnectionStatus WebSocketServer::get_connection_statu return CONNECTION_CONNECTED; return CONNECTION_DISCONNECTED; -}; +} bool WebSocketServer::is_server() const { diff --git a/modules/websocket/websocket_server.h b/modules/websocket/websocket_server.h index bfdac11489..3ce4dbe711 100644 --- a/modules/websocket/websocket_server.h +++ b/modules/websocket/websocket_server.h @@ -41,6 +41,8 @@ class WebSocketServer : public WebSocketMultiplayerPeer { GDCLASS(WebSocketServer, WebSocketMultiplayerPeer); GDCICLASS(WebSocketServer); + IP_Address bind_ip; + protected: static void _bind_methods(); @@ -67,6 +69,9 @@ public: void _on_disconnect(int32_t p_peer_id, bool p_was_clean); void _on_close_request(int32_t p_peer_id, int p_code, String p_reason); + IP_Address get_bind_ip() const; + void set_bind_ip(const IP_Address &p_bind_ip); + Ref<CryptoKey> get_private_key() const; void set_private_key(Ref<CryptoKey> p_key); diff --git a/modules/websocket/wsl_client.cpp b/modules/websocket/wsl_client.cpp index 88a306c7f5..088f266f18 100644 --- a/modules/websocket/wsl_client.cpp +++ b/modules/websocket/wsl_client.cpp @@ -90,6 +90,7 @@ void WSLClient::_do_handshake() { data->is_server = false; data->id = 1; _peer->make_context(data, _in_buf_size, _in_pkt_size, _out_buf_size, _out_pkt_size); + _peer->set_no_delay(true); _on_connect(protocol); break; } diff --git a/modules/websocket/wsl_peer.cpp b/modules/websocket/wsl_peer.cpp index 2f7f84c893..08079145e4 100644 --- a/modules/websocket/wsl_peer.cpp +++ b/modules/websocket/wsl_peer.cpp @@ -243,6 +243,10 @@ Error WSLPeer::put_packet(const uint8_t *p_buffer, int p_buffer_size) { msg.msg_length = p_buffer_size; wslay_event_queue_msg(_data->ctx, &msg); + if (wslay_event_send(_data->ctx) < 0) { + close_now(); + return FAILED; + } return OK; } @@ -314,6 +318,12 @@ uint16_t WSLPeer::get_connected_port() const { return _data->tcp->get_connected_port(); } +void WSLPeer::set_no_delay(bool p_enabled) { + + ERR_FAIL_COND(!is_connected_to_host() || _data->tcp.is_null()); + _data->tcp->set_no_delay(p_enabled); +} + void WSLPeer::invalidate() { if (_data) _data->valid = false; diff --git a/modules/websocket/wsl_peer.h b/modules/websocket/wsl_peer.h index 2fbb7aeec3..f1c45ee859 100644 --- a/modules/websocket/wsl_peer.h +++ b/modules/websocket/wsl_peer.h @@ -109,6 +109,7 @@ public: virtual WriteMode get_write_mode() const; virtual void set_write_mode(WriteMode p_mode); virtual bool was_string_packet() const; + virtual void set_no_delay(bool p_enabled); void make_context(PeerData *p_data, unsigned int p_in_buf_size, unsigned int p_in_pkt_size, unsigned int p_out_buf_size, unsigned int p_out_pkt_size); Error parse_message(const wslay_event_on_msg_recv_arg *arg); diff --git a/modules/websocket/wsl_server.cpp b/modules/websocket/wsl_server.cpp index c98c62cce9..4db650a0c1 100644 --- a/modules/websocket/wsl_server.cpp +++ b/modules/websocket/wsl_server.cpp @@ -165,9 +165,7 @@ Error WSLServer::listen(int p_port, const Vector<String> p_protocols, bool gd_mp for (int i = 0; i < p_protocols.size(); i++) { pw[i] = p_protocols[i].strip_edges(); } - _server->listen(p_port); - - return OK; + return _server->listen(p_port, bind_ip); } void WSLServer::poll() { @@ -208,6 +206,7 @@ void WSLServer::poll() { Ref<WSLPeer> ws_peer = memnew(WSLPeer); ws_peer->make_context(data, _in_buf_size, _in_pkt_size, _out_buf_size, _out_pkt_size); + ws_peer->set_no_delay(true); _peer_map[id] = ws_peer; remove_peers.push_back(ppeer); diff --git a/scene/resources/room.cpp b/platform/android/api/api.cpp index 51c4489ec3..2146c5409b 100644 --- a/scene/resources/room.cpp +++ b/platform/android/api/api.cpp @@ -1,5 +1,5 @@ /*************************************************************************/ -/* room.cpp */ +/* api.cpp */ /*************************************************************************/ /* This file is part of: */ /* GODOT ENGINE */ @@ -28,43 +28,59 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ -#include "room.h" +#include "api.h" -#include "servers/visual_server.h" +#include "core/engine.h" +#include "java_class_wrapper.h" -// FIXME: Left for reference for reimplementation using Area -#if 0 -RID RoomBounds::get_rid() const { +#if !defined(ANDROID_ENABLED) +static JavaClassWrapper *java_class_wrapper = NULL; +#endif - return area; -} +void register_android_api() { -void RoomBounds::set_geometry_hint(const PoolVector<Face3> &p_geometry_hint) { +#if !defined(ANDROID_ENABLED) + java_class_wrapper = memnew(JavaClassWrapper); // Dummy +#endif - geometry_hint = p_geometry_hint; + ClassDB::register_class<JavaClass>(); + ClassDB::register_class<JavaClassWrapper>(); + Engine::get_singleton()->add_singleton(Engine::Singleton("JavaClassWrapper", JavaClassWrapper::get_singleton())); } -PoolVector<Face3> RoomBounds::get_geometry_hint() const { +void unregister_android_api() { - return geometry_hint; +#if !defined(ANDROID_ENABLED) + memdelete(java_class_wrapper); +#endif } -void RoomBounds::_bind_methods() { +void JavaClassWrapper::_bind_methods() { + + ClassDB::bind_method(D_METHOD("wrap", "name"), &JavaClassWrapper::wrap); +} - ClassDB::bind_method(D_METHOD("set_geometry_hint", "triangles"), &RoomBounds::set_geometry_hint); - ClassDB::bind_method(D_METHOD("get_geometry_hint"), &RoomBounds::get_geometry_hint); +#if !defined(ANDROID_ENABLED) - //ADD_PROPERTY( PropertyInfo( Variant::DICTIONARY, "bounds"), "set_bounds","get_bounds") ; - ADD_PROPERTY(PropertyInfo(Variant::POOL_VECTOR3_ARRAY, "geometry_hint"), "set_geometry_hint", "get_geometry_hint"); +Variant JavaClass::call(const StringName &, const Variant **, int, Variant::CallError &) { + return Variant(); } -RoomBounds::RoomBounds() { +JavaClass::JavaClass() { +} - area = VisualServer::get_singleton()->room_create(); +Variant JavaObject::call(const StringName &, const Variant **, int, Variant::CallError &) { + return Variant(); } -RoomBounds::~RoomBounds() { +JavaClassWrapper *JavaClassWrapper::singleton = NULL; - VisualServer::get_singleton()->free(area); +Ref<JavaClass> JavaClassWrapper::wrap(const String &) { + return Ref<JavaClass>(); } + +JavaClassWrapper::JavaClassWrapper() { + singleton = this; +} + #endif diff --git a/scene/resources/video_stream.cpp b/platform/android/api/api.h index 81b4477c9a..c7296d92a7 100644 --- a/scene/resources/video_stream.cpp +++ b/platform/android/api/api.h @@ -1,5 +1,5 @@ /*************************************************************************/ -/* video_stream.cpp */ +/* api.h */ /*************************************************************************/ /* This file is part of: */ /* GODOT ENGINE */ @@ -28,12 +28,5 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ -#include "video_stream.h" - -void VideoStreamPlayback::_bind_methods(){ - -}; - -VideoStreamPlayback::VideoStreamPlayback(){ - -}; +void register_android_api(); +void unregister_android_api(); diff --git a/platform/android/java_class_wrapper.h b/platform/android/api/java_class_wrapper.h index 8075b297b0..6c06d57ac1 100644 --- a/platform/android/java_class_wrapper.h +++ b/platform/android/api/java_class_wrapper.h @@ -32,16 +32,22 @@ #define JAVA_CLASS_WRAPPER_H #include "core/reference.h" + +#ifdef ANDROID_ENABLED #include <android/log.h> #include <jni.h> +#endif +#ifdef ANDROID_ENABLED class JavaObject; +#endif class JavaClass : public Reference { GDCLASS(JavaClass, Reference); - enum ArgumentType { +#ifdef ANDROID_ENABLED + enum ArgumentType{ ARG_TYPE_VOID, ARG_TYPE_BOOLEAN, @@ -159,6 +165,7 @@ class JavaClass : public Reference { friend class JavaClassWrapper; Map<StringName, List<MethodInfo> > methods; jclass _class; +#endif public: virtual Variant call(const StringName &p_method, const Variant **p_args, int p_argcount, Variant::CallError &r_error); @@ -170,22 +177,27 @@ class JavaObject : public Reference { GDCLASS(JavaObject, Reference); +#ifdef ANDROID_ENABLED Ref<JavaClass> base_class; friend class JavaClass; jobject instance; +#endif public: virtual Variant call(const StringName &p_method, const Variant **p_args, int p_argcount, Variant::CallError &r_error); +#ifdef ANDROID_ENABLED JavaObject(const Ref<JavaClass> &p_base, jobject *p_instance); ~JavaObject(); +#endif }; class JavaClassWrapper : public Object { GDCLASS(JavaClassWrapper, Object); +#ifdef ANDROID_ENABLED Map<String, Ref<JavaClass> > class_cache; friend class JavaClass; jclass activityClass; @@ -211,6 +223,7 @@ class JavaClassWrapper : public Object { jobject classLoader; bool _get_type_sig(JNIEnv *env, jobject obj, uint32_t &sig, String &strsig); +#endif static JavaClassWrapper *singleton; @@ -222,7 +235,11 @@ public: Ref<JavaClass> wrap(const String &p_class); +#ifdef ANDROID_ENABLED JavaClassWrapper(jobject p_activity = NULL); +#else + JavaClassWrapper(); +#endif }; #endif // JAVA_CLASS_WRAPPER_H diff --git a/platform/android/audio_driver_opensl.cpp b/platform/android/audio_driver_opensl.cpp index 9e294f3f14..6e9864c803 100644 --- a/platform/android/audio_driver_opensl.cpp +++ b/platform/android/audio_driver_opensl.cpp @@ -208,8 +208,8 @@ void AudioDriverOpenSL::_record_buffer_callback(SLAndroidSimpleBufferQueueItf qu for (int i = 0; i < rec_buffer.size(); i++) { int32_t sample = rec_buffer[i] << 16; - capture_buffer_write(sample); - capture_buffer_write(sample); // call twice to convert to Stereo + input_buffer_write(sample); + input_buffer_write(sample); // call twice to convert to Stereo } SLresult res = (*recordBufferQueueItf)->Enqueue(recordBufferQueueItf, rec_buffer.ptrw(), rec_buffer.size() * sizeof(int16_t)); @@ -280,7 +280,7 @@ Error AudioDriverOpenSL::capture_init_device() { const int rec_buffer_frames = 2048; rec_buffer.resize(rec_buffer_frames); - capture_buffer_init(rec_buffer_frames); + input_buffer_init(rec_buffer_frames); res = (*recordBufferQueueItf)->Enqueue(recordBufferQueueItf, rec_buffer.ptrw(), rec_buffer.size() * sizeof(int16_t)); ERR_FAIL_COND_V(res != SL_RESULT_SUCCESS, ERR_CANT_OPEN); diff --git a/platform/android/export/export.cpp b/platform/android/export/export.cpp index 8f784dd943..78d87c5629 100644 --- a/platform/android/export/export.cpp +++ b/platform/android/export/export.cpp @@ -30,6 +30,7 @@ #include "export.h" +#include "core/io/image_loader.h" #include "core/io/marshalls.h" #include "core/io/zip_io.h" #include "core/os/dir_access.h" @@ -37,6 +38,7 @@ #include "core/os/os.h" #include "core/project_settings.h" #include "core/version.h" +#include "drivers/png/png_driver_common.h" #include "editor/editor_export.h" #include "editor/editor_log.h" #include "editor/editor_node.h" @@ -196,16 +198,40 @@ static const char *android_perms[] = { }; struct LauncherIcon { - const char *option_id; const char *export_path; + int dimensions; }; -static const LauncherIcon launcher_icons[] = { - { "launcher_icons/xxxhdpi_192x192", "res/drawable-xxxhdpi-v4/icon.png" }, - { "launcher_icons/xxhdpi_144x144", "res/drawable-xxhdpi-v4/icon.png" }, - { "launcher_icons/xhdpi_96x96", "res/drawable-xhdpi-v4/icon.png" }, - { "launcher_icons/hdpi_72x72", "res/drawable-hdpi-v4/icon.png" }, - { "launcher_icons/mdpi_48x48", "res/drawable-mdpi-v4/icon.png" } +static const int icon_densities_count = 6; +static const char *launcher_icon_option = "launcher_icons/main_192x192"; +static const char *launcher_adaptive_icon_foreground_option = "launcher_icons/adaptive_foreground_432x432"; +static const char *launcher_adaptive_icon_background_option = "launcher_icons/adaptive_background_432x432"; + +static const LauncherIcon launcher_icons[icon_densities_count] = { + { "res/mipmap-xxxhdpi-v4/icon.png", 192 }, + { "res/mipmap-xxhdpi-v4/icon.png", 144 }, + { "res/mipmap-xhdpi-v4/icon.png", 96 }, + { "res/mipmap-hdpi-v4/icon.png", 72 }, + { "res/mipmap-mdpi-v4/icon.png", 48 }, + { "res/mipmap/icon.png", 192 } +}; + +static const LauncherIcon launcher_adaptive_icon_foregrounds[icon_densities_count] = { + { "res/mipmap-xxxhdpi-v4/icon_foreground.png", 432 }, + { "res/mipmap-xxhdpi-v4/icon_foreground.png", 324 }, + { "res/mipmap-xhdpi-v4/icon_foreground.png", 216 }, + { "res/mipmap-hdpi-v4/icon_foreground.png", 162 }, + { "res/mipmap-mdpi-v4/icon_foreground.png", 108 }, + { "res/mipmap/icon_foreground.png", 432 } +}; + +static const LauncherIcon launcher_adaptive_icon_backgrounds[icon_densities_count] = { + { "res/mipmap-xxxhdpi-v4/icon_background.png", 432 }, + { "res/mipmap-xxhdpi-v4/icon_background.png", 324 }, + { "res/mipmap-xhdpi-v4/icon_background.png", 216 }, + { "res/mipmap-hdpi-v4/icon_background.png", 162 }, + { "res/mipmap-mdpi-v4/icon_background.png", 108 }, + { "res/mipmap/icon_background.png", 432 } }; class EditorExportPlatformAndroid : public EditorExportPlatform { @@ -221,7 +247,6 @@ class EditorExportPlatformAndroid : public EditorExportPlatform { String name; String description; int api_level; - bool usb; }; struct APKExportData { @@ -248,20 +273,17 @@ class EditorExportPlatformAndroid : public EditorExportPlatform { String devices; List<String> args; args.push_back("devices"); - args.push_back("-l"); int ec; OS::get_singleton()->execute(adb, args, true, NULL, &devices, &ec); Vector<String> ds = devices.split("\n"); Vector<String> ldevices; - Vector<bool> ldevices_usbconnection; for (int i = 1; i < ds.size(); i++) { String d = ds[i]; - int dpos = d.find(" device "); + int dpos = d.find("device"); if (dpos == -1) continue; - ldevices_usbconnection.push_back(d.find(" usb:") != -1); d = d.substr(0, dpos).strip_edges(); ldevices.push_back(d); } @@ -292,7 +314,6 @@ class EditorExportPlatformAndroid : public EditorExportPlatform { Device d; d.id = ldevices[i]; - d.usb = ldevices_usbconnection[i]; for (int j = 0; j < ea->devices.size(); j++) { if (ea->devices[j].id == ldevices[i]) { d.description = ea->devices[j].description; @@ -347,17 +368,9 @@ class EditorExportPlatformAndroid : public EditorExportPlatform { } else if (p.begins_with("ro.opengles.version=")) { uint32_t opengl = p.get_slice("=", 1).to_int(); d.description += "OpenGL: " + itos(opengl >> 16) + "." + itos((opengl >> 8) & 0xFF) + "." + itos((opengl)&0xFF) + "\n"; - } else if (p.begins_with("ro.boot.serialno=")) { - d.description += "Serial: " + p.get_slice("=", 1).strip_edges() + "\n"; } } - if (d.usb) { - d.description += "Connection: USB\n"; - } else { - d.description += "Connection: " + d.id + "\n"; - } - d.name = vendor + " " + device; if (device == String()) continue; } @@ -597,7 +610,7 @@ class EditorExportPlatformAndroid : public EditorExportPlatform { static Error save_apk_so(void *p_userdata, const SharedObject &p_so) { if (!p_so.path.get_file().begins_with("lib")) { String err = "Android .so file names must start with \"lib\", but got: " + p_so.path; - ERR_PRINTS(err); + ERR_PRINT(err); return FAILED; } APKExportData *ed = (APKExportData *)p_userdata; @@ -618,7 +631,7 @@ class EditorExportPlatformAndroid : public EditorExportPlatform { if (!exported) { String abis_string = String(" ").join(abis); String err = "Cannot determine ABI for library \"" + p_so.path + "\". One of the supported ABIs must be used as a tag: " + abis_string; - ERR_PRINTS(err); + ERR_PRINT(err); return FAILED; } return OK; @@ -629,9 +642,6 @@ class EditorExportPlatformAndroid : public EditorExportPlatform { String dst_path = p_path.replace_first("res://", "assets/"); store_in_apk(ed, dst_path, p_data, _should_compress_asset(p_path, p_data) ? Z_DEFLATED : 0); - if (ed->ep->step("File: " + p_path, 3 + p_file * 100 / p_total)) { - return ERR_SKIP; - } return OK; } @@ -1298,6 +1308,27 @@ class EditorExportPlatformAndroid : public EditorExportPlatform { //printf("end\n"); } + void _process_launcher_icons(const String &p_processing_file_name, const Ref<Image> &p_source_image, const LauncherIcon p_icon, Vector<uint8_t> &p_data) { + if (p_processing_file_name == p_icon.export_path) { + Ref<Image> working_image = p_source_image; + + if (p_source_image->get_width() != p_icon.dimensions || p_source_image->get_height() != p_icon.dimensions) { + working_image = p_source_image->duplicate(); + working_image->resize(p_icon.dimensions, p_icon.dimensions, Image::Interpolation::INTERPOLATE_LANCZOS); + } + + PoolVector<uint8_t> png_buffer; + Error err = PNGDriverCommon::image_to_png(working_image, png_buffer); + if (err == OK) { + p_data.resize(png_buffer.size()); + memcpy(p_data.ptrw(), png_buffer.read().ptr(), p_data.size()); + } else { + String err_str = String("Failed to convert resized icon (") + p_processing_file_name + ") to png."; + WARN_PRINT(err_str.utf8().get_data()); + } + } + } + static Vector<String> get_enabled_abis(const Ref<EditorExportPreset> &p_preset) { Vector<String> abis = get_abis(); Vector<String> enabled_abis; @@ -1355,11 +1386,9 @@ public: r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "screen/support_large"), true)); r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "screen/support_xlarge"), true)); r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "screen/opengl_debug"), false)); - - for (uint64_t i = 0; i < sizeof(launcher_icons) / sizeof(launcher_icons[0]); ++i) { - r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, launcher_icons[i].option_id, PROPERTY_HINT_FILE, "*.png"), "")); - } - + r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, launcher_icon_option, PROPERTY_HINT_FILE, "*.png"), "")); + r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, launcher_adaptive_icon_foreground_option, PROPERTY_HINT_FILE, "*.png"), "")); + r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, launcher_adaptive_icon_background_option, PROPERTY_HINT_FILE, "*.png"), "")); r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "keystore/debug", PROPERTY_HINT_GLOBAL_FILE, "*.keystore"), "")); r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "keystore/debug_user"), "")); r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "keystore/debug_password"), "")); @@ -1450,28 +1479,28 @@ public: virtual Error run(const Ref<EditorExportPreset> &p_preset, int p_device, int p_debug_flags) { ERR_FAIL_INDEX_V(p_device, devices.size(), ERR_INVALID_PARAMETER); + + String can_export_error; + bool can_export_missing_templates; + if (!can_export(p_preset, can_export_error, can_export_missing_templates)) { + EditorNode::add_io_error(can_export_error); + return ERR_UNCONFIGURED; + } + device_lock->lock(); EditorProgress ep("run", "Running on " + devices[p_device].name, 3); String adb = EditorSettings::get_singleton()->get("export/android/adb"); - if (adb == "") { - - EditorNode::add_io_error("ADB executable not configured in settings, can't run."); - device_lock->unlock(); - return ERR_UNCONFIGURED; - } // Export_temp APK. - if (ep.step("Exporting APK", 0)) { + if (ep.step("Exporting APK...", 0)) { device_lock->unlock(); return ERR_SKIP; } const bool use_remote = (p_debug_flags & DEBUG_FLAG_REMOTE_DEBUG) || (p_debug_flags & DEBUG_FLAG_DUMB_CLIENT); - const bool use_reverse = devices[p_device].api_level >= 21 && devices[p_device].usb; - // Note: Reverse can still fail if device is connected by both usb and network - // Ideally we'd know for sure whether adb reverse would work before we build the APK + const bool use_reverse = devices[p_device].api_level >= 21; if (use_reverse) p_debug_flags |= DEBUG_FLAG_REMOTE_DEBUG_LOCALHOST; @@ -1515,7 +1544,7 @@ public: } print_line("Installing to device (please wait...): " + devices[p_device].name); - if (ep.step("Installing to device (please wait...)", 2)) { + if (ep.step("Installing to device, please wait...", 2)) { CLEANUP_AND_RETURN(ERR_SKIP); } @@ -1576,13 +1605,13 @@ public: } } else { - static const char *const msg = "--- Device API < 21 or no USB connection; debugging over Wi-Fi ---"; + static const char *const msg = "--- Device API < 21; debugging over Wi-Fi ---"; EditorNode::get_singleton()->get_log()->add_message(msg, EditorLog::MSG_TYPE_EDITOR); print_line(String(msg).to_upper()); } } - if (ep.step("Running on Device...", 3)) { + if (ep.step("Running on device...", 3)) { CLEANUP_AND_RETURN(ERR_SKIP); } args.clear(); @@ -1846,7 +1875,7 @@ public: new_file += "//CHUNK_" + text + "_BEGIN\n"; if (!found) { - ERR_PRINTS("No end marker found in build.gradle for chunk: " + text); + ERR_PRINT("No end marker found in build.gradle for chunk: " + text); f->seek(pos); } else { @@ -1882,7 +1911,7 @@ public: new_file += "//DIR_" + text + "_BEGIN\n"; if (!found) { - ERR_PRINTS("No end marker found in build.gradle for dir: " + text); + ERR_PRINT("No end marker found in build.gradle for dir: " + text); f->seek(pos); } else { //add chunk lines @@ -1941,7 +1970,7 @@ public: new_file += "<!--CHUNK_" + text + "_BEGIN-->\n"; if (!found) { - ERR_PRINTS("No end marker found in AndroidManifest.xml for chunk: " + text); + ERR_PRINT("No end marker found in AndroidManifest.xml for chunk: " + text); f->seek(pos); } else { //add chunk lines @@ -1957,10 +1986,10 @@ public: } } else if (l.strip_edges().begins_with("<application")) { - String last_tag = "android:icon=\"@drawable/icon\""; + String last_tag = "android:icon=\"@mipmap/icon\""; int last_tag_pos = l.find(last_tag); if (last_tag_pos == -1) { - ERR_PRINTS("Not adding application attributes as the expected tag was not found in '<application': " + last_tag); + ERR_PRINT("Not adding application attributes as the expected tag was not found in '<application': " + last_tag); new_file += l + "\n"; } else { String base = l.substr(0, last_tag_pos + last_tag.length()); @@ -2087,7 +2116,7 @@ public: FileAccess *src_f = NULL; zlib_filefunc_def io = zipio_create_io_from_file(&src_f); - if (ep.step("Creating APK", 0)) { + if (ep.step("Creating APK...", 0)) { return ERR_SKIP; } @@ -2136,6 +2165,35 @@ public: Vector<String> enabled_abis = get_enabled_abis(p_preset); + String project_icon_path = ProjectSettings::get_singleton()->get("application/config/icon"); + + // Prepare images to be resized for the icons. If some image ends up being uninitialized, the default image from the export template will be used. + Ref<Image> launcher_icon_image; + Ref<Image> launcher_adaptive_icon_foreground_image; + Ref<Image> launcher_adaptive_icon_background_image; + + launcher_icon_image.instance(); + launcher_adaptive_icon_foreground_image.instance(); + launcher_adaptive_icon_background_image.instance(); + + // Regular icon: user selection -> project icon -> default. + String path = static_cast<String>(p_preset->get(launcher_icon_option)).strip_edges(); + if (path.empty() || ImageLoader::load_image(path, launcher_icon_image) != OK) { + ImageLoader::load_image(project_icon_path, launcher_icon_image); + } + + // Adaptive foreground: user selection -> regular icon (user selection -> project icon -> default). + path = static_cast<String>(p_preset->get(launcher_adaptive_icon_foreground_option)).strip_edges(); + if (path.empty() || ImageLoader::load_image(path, launcher_adaptive_icon_foreground_image) != OK) { + launcher_adaptive_icon_foreground_image = launcher_icon_image; + } + + // Adaptive background: user selection -> default. + path = static_cast<String>(p_preset->get(launcher_adaptive_icon_background_option)).strip_edges(); + if (!path.empty()) { + ImageLoader::load_image(path, launcher_adaptive_icon_background_image); + } + while (ret == UNZ_OK) { //get filename @@ -2158,41 +2216,22 @@ public: //write if (file == "AndroidManifest.xml") { - _fix_manifest(p_preset, data, p_flags & (DEBUG_FLAG_DUMB_CLIENT | DEBUG_FLAG_REMOTE_DEBUG)); } if (file == "resources.arsc") { - _fix_resources(p_preset, data); } - if (file == "res/drawable-nodpi-v4/icon.png") { - bool found = false; - for (uint64_t i = 0; i < sizeof(launcher_icons) / sizeof(launcher_icons[0]); ++i) { - String icon_path = String(p_preset->get(launcher_icons[i].option_id)).strip_edges(); - if (icon_path != "" && icon_path.ends_with(".png")) { - FileAccess *f = FileAccess::open(icon_path, FileAccess::READ); - if (f) { - data.resize(f->get_len()); - f->get_buffer(data.ptrw(), data.size()); - memdelete(f); - found = true; - break; - } - } + for (int i = 0; i < icon_densities_count; ++i) { + if (launcher_icon_image.is_valid() && !launcher_icon_image->empty()) { + _process_launcher_icons(file, launcher_icon_image, launcher_icons[i], data); } - if (!found) { - - String appicon = ProjectSettings::get_singleton()->get("application/config/icon"); - if (appicon != "" && appicon.ends_with(".png")) { - FileAccess *f = FileAccess::open(appicon, FileAccess::READ); - if (f) { - data.resize(f->get_len()); - f->get_buffer(data.ptrw(), data.size()); - memdelete(f); - } - } + if (launcher_adaptive_icon_foreground_image.is_valid() && !launcher_adaptive_icon_foreground_image->empty()) { + _process_launcher_icons(file, launcher_adaptive_icon_foreground_image, launcher_adaptive_icon_foregrounds[i], data); + } + if (launcher_adaptive_icon_background_image.is_valid() && !launcher_adaptive_icon_background_image->empty()) { + _process_launcher_icons(file, launcher_adaptive_icon_background_image, launcher_adaptive_icon_backgrounds[i], data); } } @@ -2239,7 +2278,7 @@ public: ret = unzGoToNextFile(pkg); } - if (ep.step("Adding Files...", 1)) { + if (ep.step("Adding files...", 1)) { CLEANUP_AND_RETURN(ERR_SKIP); } Error err = OK; @@ -2291,19 +2330,6 @@ public: } } - if (!err) { - APKExportData ed; - ed.ep = &ep; - ed.apk = unaligned_apk; - for (uint64_t i = 0; i < sizeof(launcher_icons) / sizeof(launcher_icons[0]); ++i) { - String icon_path = String(p_preset->get(launcher_icons[i].option_id)).strip_edges(); - if (icon_path != "" && icon_path.ends_with(".png") && FileAccess::exists(icon_path)) { - Vector<uint8_t> data = FileAccess::get_file_as_array(icon_path); - store_in_apk(&ed, launcher_icons[i].export_path, data); - } - } - } - int xr_mode_index = p_preset->get("xr_features/xr_mode"); if (xr_mode_index == 1 /* XRMode.OVR */) { cl.push_back("--xr_mode_ovr"); diff --git a/platform/android/java/app/AndroidManifest.xml b/platform/android/java/app/AndroidManifest.xml index ba01ec313b..7e9ce70d80 100644 --- a/platform/android/java/app/AndroidManifest.xml +++ b/platform/android/java/app/AndroidManifest.xml @@ -27,7 +27,7 @@ <!-- Any tag in this line after android:icon will be erased when doing custom builds. --> <!-- If you want to add tags manually, do before it. --> <!-- WARNING: This should stay on a single line until the parsing code is improved. See GH-32414. --> - <application android:label="@string/godot_project_name_string" android:allowBackup="false" tools:ignore="GoogleAppIndexingWarning" android:icon="@drawable/icon" > + <application android:label="@string/godot_project_name_string" android:allowBackup="false" tools:ignore="GoogleAppIndexingWarning" android:icon="@mipmap/icon" > <!-- The following metadata values are replaced when Godot exports, modifying them here has no effect. --> <!-- Do these changes in the export preset. Adding new ones is fine. --> diff --git a/platform/android/java/app/build.gradle b/platform/android/java/app/build.gradle index 258ca9197a..2e4f2ffab0 100644 --- a/platform/android/java/app/build.gradle +++ b/platform/android/java/app/build.gradle @@ -33,6 +33,8 @@ allprojects { } dependencies { + implementation libraries.supportCoreUtils + if (rootProject.findProject(":lib")) { implementation project(":lib") } else { diff --git a/platform/android/java/app/config.gradle b/platform/android/java/app/config.gradle index 862a954fac..5550d3099d 100644 --- a/platform/android/java/app/config.gradle +++ b/platform/android/java/app/config.gradle @@ -4,11 +4,13 @@ ext.versions = [ minSdk : 18, targetSdk : 28, buildTools : '28.0.3', + supportCoreUtils : '28.0.0' ] ext.libraries = [ - androidGradlePlugin : "com.android.tools.build:gradle:$versions.androidGradlePlugin" + androidGradlePlugin : "com.android.tools.build:gradle:$versions.androidGradlePlugin", + supportCoreUtils : "com.android.support:support-core-utils:$versions.supportCoreUtils" ] ext.getExportPackageName = { -> diff --git a/platform/android/java/lib/AndroidManifest.xml b/platform/android/java/lib/AndroidManifest.xml index 517fc403b2..b133585f99 100644 --- a/platform/android/java/lib/AndroidManifest.xml +++ b/platform/android/java/lib/AndroidManifest.xml @@ -11,7 +11,7 @@ </application> <instrumentation - android:icon="@drawable/icon" + android:icon="@mipmap/icon" android:label="@string/godot_project_name_string" android:name=".GodotInstrumentation" android:targetPackage="org.godotengine.godot" /> diff --git a/platform/android/java/lib/build.gradle b/platform/android/java/lib/build.gradle index 13a14422ed..eb97484b9c 100644 --- a/platform/android/java/lib/build.gradle +++ b/platform/android/java/lib/build.gradle @@ -1,7 +1,7 @@ apply plugin: 'com.android.library' dependencies { - implementation "com.android.support:support-core-utils:28.0.0" + implementation libraries.supportCoreUtils } def pathToRootDir = "../../../../" diff --git a/platform/android/java/lib/res/drawable-nodpi/icon.png b/platform/android/java/lib/res/drawable-nodpi/icon.png Binary files differdeleted file mode 100644 index 6ad9b43117..0000000000 --- a/platform/android/java/lib/res/drawable-nodpi/icon.png +++ /dev/null diff --git a/platform/android/java/lib/res/mipmap-anydpi-v26/icon.xml b/platform/android/java/lib/res/mipmap-anydpi-v26/icon.xml new file mode 100644 index 0000000000..1ed4037035 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-anydpi-v26/icon.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="utf-8"?> +<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android"> + <background android:drawable="@mipmap/icon_background"/> + <foreground android:drawable="@mipmap/icon_foreground"/> +</adaptive-icon>
\ No newline at end of file diff --git a/platform/android/java/lib/res/mipmap-hdpi/icon.png b/platform/android/java/lib/res/mipmap-hdpi/icon.png Binary files differnew file mode 100644 index 0000000000..cc6e113e89 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-hdpi/icon.png diff --git a/platform/android/java/lib/res/mipmap-hdpi/icon_background.png b/platform/android/java/lib/res/mipmap-hdpi/icon_background.png Binary files differnew file mode 100644 index 0000000000..78445c0181 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-hdpi/icon_background.png diff --git a/platform/android/java/lib/res/mipmap-hdpi/icon_foreground.png b/platform/android/java/lib/res/mipmap-hdpi/icon_foreground.png Binary files differnew file mode 100644 index 0000000000..75e409ff74 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-hdpi/icon_foreground.png diff --git a/platform/android/java/lib/res/mipmap-mdpi/icon.png b/platform/android/java/lib/res/mipmap-mdpi/icon.png Binary files differnew file mode 100644 index 0000000000..e1968fe142 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-mdpi/icon.png diff --git a/platform/android/java/lib/res/mipmap-mdpi/icon_background.png b/platform/android/java/lib/res/mipmap-mdpi/icon_background.png Binary files differnew file mode 100644 index 0000000000..5813f751ed --- /dev/null +++ b/platform/android/java/lib/res/mipmap-mdpi/icon_background.png diff --git a/platform/android/java/lib/res/mipmap-mdpi/icon_foreground.png b/platform/android/java/lib/res/mipmap-mdpi/icon_foreground.png Binary files differnew file mode 100644 index 0000000000..982b69be1e --- /dev/null +++ b/platform/android/java/lib/res/mipmap-mdpi/icon_foreground.png diff --git a/platform/android/java/lib/res/mipmap-xhdpi/icon.png b/platform/android/java/lib/res/mipmap-xhdpi/icon.png Binary files differnew file mode 100644 index 0000000000..9281d8da48 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xhdpi/icon.png diff --git a/platform/android/java/lib/res/mipmap-xhdpi/icon_background.png b/platform/android/java/lib/res/mipmap-xhdpi/icon_background.png Binary files differnew file mode 100644 index 0000000000..4269c822a7 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xhdpi/icon_background.png diff --git a/platform/android/java/lib/res/mipmap-xhdpi/icon_foreground.png b/platform/android/java/lib/res/mipmap-xhdpi/icon_foreground.png Binary files differnew file mode 100644 index 0000000000..726b267ad6 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xhdpi/icon_foreground.png diff --git a/platform/android/java/lib/res/mipmap-xxhdpi/icon.png b/platform/android/java/lib/res/mipmap-xxhdpi/icon.png Binary files differnew file mode 100644 index 0000000000..7a6b67d273 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xxhdpi/icon.png diff --git a/platform/android/java/lib/res/mipmap-xxhdpi/icon_background.png b/platform/android/java/lib/res/mipmap-xxhdpi/icon_background.png Binary files differnew file mode 100644 index 0000000000..5e8b518d17 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xxhdpi/icon_background.png diff --git a/platform/android/java/lib/res/mipmap-xxhdpi/icon_foreground.png b/platform/android/java/lib/res/mipmap-xxhdpi/icon_foreground.png Binary files differnew file mode 100644 index 0000000000..b0c727f74c --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xxhdpi/icon_foreground.png diff --git a/platform/android/java/lib/res/mipmap-xxxhdpi/icon.png b/platform/android/java/lib/res/mipmap-xxxhdpi/icon.png Binary files differnew file mode 100644 index 0000000000..0881245802 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xxxhdpi/icon.png diff --git a/platform/android/java/lib/res/mipmap-xxxhdpi/icon_background.png b/platform/android/java/lib/res/mipmap-xxxhdpi/icon_background.png Binary files differnew file mode 100644 index 0000000000..004b6fd508 --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xxxhdpi/icon_background.png diff --git a/platform/android/java/lib/res/mipmap-xxxhdpi/icon_foreground.png b/platform/android/java/lib/res/mipmap-xxxhdpi/icon_foreground.png Binary files differnew file mode 100644 index 0000000000..72e6f92b6e --- /dev/null +++ b/platform/android/java/lib/res/mipmap-xxxhdpi/icon_foreground.png diff --git a/platform/android/java/lib/res/mipmap/icon.png b/platform/android/java/lib/res/mipmap/icon.png Binary files differnew file mode 100644 index 0000000000..0881245802 --- /dev/null +++ b/platform/android/java/lib/res/mipmap/icon.png diff --git a/platform/android/java/lib/res/mipmap/icon_background.png b/platform/android/java/lib/res/mipmap/icon_background.png Binary files differnew file mode 100644 index 0000000000..5813f751ed --- /dev/null +++ b/platform/android/java/lib/res/mipmap/icon_background.png diff --git a/platform/android/java/lib/res/mipmap/icon_foreground.png b/platform/android/java/lib/res/mipmap/icon_foreground.png Binary files differnew file mode 100644 index 0000000000..982b69be1e --- /dev/null +++ b/platform/android/java/lib/res/mipmap/icon_foreground.png diff --git a/platform/android/java/lib/src/org/godotengine/godot/GodotIO.java b/platform/android/java/lib/src/org/godotengine/godot/GodotIO.java index 271d508a4d..68ce40ba10 100644 --- a/platform/android/java/lib/src/org/godotengine/godot/GodotIO.java +++ b/platform/android/java/lib/src/org/godotengine/godot/GodotIO.java @@ -491,9 +491,9 @@ public class GodotIO { return (int)(metrics.density * 160f); } - public void showKeyboard(String p_existing_text) { + public void showKeyboard(String p_existing_text, int p_max_input_length) { if (edit != null) - edit.showKeyboard(p_existing_text); + edit.showKeyboard(p_existing_text, p_max_input_length); //InputMethodManager inputMgr = (InputMethodManager)activity.getSystemService(Context.INPUT_METHOD_SERVICE); //inputMgr.toggleSoftInput(InputMethodManager.SHOW_FORCED, 0); diff --git a/platform/android/java/lib/src/org/godotengine/godot/GodotLib.java b/platform/android/java/lib/src/org/godotengine/godot/GodotLib.java index 0ff37e3c37..e0b46673ba 100644 --- a/platform/android/java/lib/src/org/godotengine/godot/GodotLib.java +++ b/platform/android/java/lib/src/org/godotengine/godot/GodotLib.java @@ -102,7 +102,7 @@ public class GodotLib { /** * Forward double_tap events from the main thread to the GL thread. */ - public static native void double_tap(int x, int y); + public static native void doubletap(int x, int y); /** * Forward scroll events from the main thread to the GL thread. diff --git a/platform/android/java/lib/src/org/godotengine/godot/input/GodotEditText.java b/platform/android/java/lib/src/org/godotengine/godot/input/GodotEditText.java index 0d5521dd87..e901b4b36d 100644 --- a/platform/android/java/lib/src/org/godotengine/godot/input/GodotEditText.java +++ b/platform/android/java/lib/src/org/godotengine/godot/input/GodotEditText.java @@ -32,6 +32,7 @@ package org.godotengine.godot.input; import android.content.Context; import android.os.Handler; import android.os.Message; +import android.text.InputFilter; import android.util.AttributeSet; import android.view.KeyEvent; import android.view.inputmethod.EditorInfo; @@ -104,6 +105,7 @@ public class GodotEditText extends EditText { edit.append(text); edit.mInputWrapper.setOriginText(text); edit.addTextChangedListener(edit.mInputWrapper); + setMaxInputLength(edit, msg.arg1); final InputMethodManager imm = (InputMethodManager)mView.getContext().getSystemService(Context.INPUT_METHOD_SERVICE); imm.showSoftInput(edit, 0); } @@ -120,6 +122,16 @@ public class GodotEditText extends EditText { } } + private void setMaxInputLength(EditText p_edit_text, int p_max_input_length) { + if (p_max_input_length > 0) { + InputFilter[] filters = new InputFilter[1]; + filters[0] = new InputFilter.LengthFilter(p_max_input_length); + p_edit_text.setFilters(filters); + } else { + p_edit_text.setFilters(new InputFilter[] {}); + } + } + // =========================================================== // Getter & Setter // =========================================================== @@ -149,12 +161,13 @@ public class GodotEditText extends EditText { // =========================================================== // Methods // =========================================================== - public void showKeyboard(String p_existing_text) { + public void showKeyboard(String p_existing_text, int p_max_input_length) { this.mOriginText = p_existing_text; final Message msg = new Message(); msg.what = HANDLER_OPEN_IME_KEYBOARD; msg.obj = this; + msg.arg1 = p_max_input_length; sHandler.sendMessage(msg); } diff --git a/platform/android/java/lib/src/org/godotengine/godot/input/GodotGestureHandler.java b/platform/android/java/lib/src/org/godotengine/godot/input/GodotGestureHandler.java index b42b13894c..1a38a9c3d2 100644 --- a/platform/android/java/lib/src/org/godotengine/godot/input/GodotGestureHandler.java +++ b/platform/android/java/lib/src/org/godotengine/godot/input/GodotGestureHandler.java @@ -78,7 +78,7 @@ public class GodotGestureHandler extends GestureDetector.SimpleOnGestureListener queueEvent(new Runnable() { @Override public void run() { - GodotLib.double_tap(x, y); + GodotLib.doubletap(x, y); } }); return true; diff --git a/platform/android/java_class_wrapper.cpp b/platform/android/java_class_wrapper.cpp index feebea2738..fe2fd89710 100644 --- a/platform/android/java_class_wrapper.cpp +++ b/platform/android/java_class_wrapper.cpp @@ -28,7 +28,7 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ -#include "java_class_wrapper.h" +#include "api/java_class_wrapper.h" #include "string_android.h" #include "thread_jandroid.h" @@ -546,11 +546,6 @@ JavaObject::~JavaObject() { //////////////////// -void JavaClassWrapper::_bind_methods() { - - ClassDB::bind_method(D_METHOD("wrap", "name"), &JavaClassWrapper::wrap); -} - bool JavaClassWrapper::_get_type_sig(JNIEnv *env, jobject obj, uint32_t &sig, String &strsig) { jstring name2 = (jstring)env->CallObjectMethod(obj, Class_getName); diff --git a/platform/android/java_godot_io_wrapper.cpp b/platform/android/java_godot_io_wrapper.cpp index 671d1072ea..8d075f8e97 100644 --- a/platform/android/java_godot_io_wrapper.cpp +++ b/platform/android/java_godot_io_wrapper.cpp @@ -53,7 +53,7 @@ GodotIOJavaWrapper::GodotIOJavaWrapper(JNIEnv *p_env, jobject p_godot_io_instanc _get_model = p_env->GetMethodID(cls, "getModel", "()Ljava/lang/String;"); _get_screen_DPI = p_env->GetMethodID(cls, "getScreenDPI", "()I"); _get_unique_id = p_env->GetMethodID(cls, "getUniqueID", "()Ljava/lang/String;"); - _show_keyboard = p_env->GetMethodID(cls, "showKeyboard", "(Ljava/lang/String;)V"); + _show_keyboard = p_env->GetMethodID(cls, "showKeyboard", "(Ljava/lang/String;I)V"); _hide_keyboard = p_env->GetMethodID(cls, "hideKeyboard", "()V"); _set_screen_orientation = p_env->GetMethodID(cls, "setScreenOrientation", "(I)V"); _get_system_dir = p_env->GetMethodID(cls, "getSystemDir", "(I)Ljava/lang/String;"); @@ -135,11 +135,11 @@ bool GodotIOJavaWrapper::has_vk() { return (_show_keyboard != 0) && (_hide_keyboard != 0); } -void GodotIOJavaWrapper::show_vk(const String &p_existing) { +void GodotIOJavaWrapper::show_vk(const String &p_existing, int p_max_input_length) { if (_show_keyboard) { JNIEnv *env = ThreadAndroid::get_env(); jstring jStr = env->NewStringUTF(p_existing.utf8().get_data()); - env->CallVoidMethod(godot_io_instance, _show_keyboard, jStr); + env->CallVoidMethod(godot_io_instance, _show_keyboard, jStr, p_max_input_length); } } diff --git a/platform/android/java_godot_io_wrapper.h b/platform/android/java_godot_io_wrapper.h index 9fa6f2e469..7dfed52187 100644 --- a/platform/android/java_godot_io_wrapper.h +++ b/platform/android/java_godot_io_wrapper.h @@ -73,7 +73,7 @@ public: int get_screen_dpi(); String get_unique_id(); bool has_vk(); - void show_vk(const String &p_existing); + void show_vk(const String &p_existing, int p_max_input_length); void hide_vk(); int get_vk_height(); void set_vk_height(int p_height); diff --git a/platform/android/java_godot_lib_jni.cpp b/platform/android/java_godot_lib_jni.cpp index d3bc216608..dedb2ee114 100644 --- a/platform/android/java_godot_lib_jni.cpp +++ b/platform/android/java_godot_lib_jni.cpp @@ -33,6 +33,7 @@ #include "java_godot_wrapper.h" #include "android/asset_manager_jni.h" +#include "api/java_class_wrapper.h" #include "audio_driver_jandroid.h" #include "core/engine.h" #include "core/os/keyboard.h" @@ -40,7 +41,6 @@ #include "dir_access_jandroid.h" #include "file_access_android.h" #include "file_access_jandroid.h" -#include "java_class_wrapper.h" #include "main/input_default.h" #include "main/main.h" #include "net_socket_android.h" @@ -739,7 +739,6 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_setup(JNIEnv *env, jo } java_class_wrapper = memnew(JavaClassWrapper(godot_java->get_activity())); - Engine::get_singleton()->add_singleton(Engine::Singleton("JavaClassWrapper", java_class_wrapper)); _initialize_java_modules(); } @@ -835,7 +834,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_hover(JNIEnv *env, jo os_android->process_hover(p_type, Point2(p_x, p_y)); } -JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_double_tap(JNIEnv *env, jobject obj, jint p_x, jint p_y) { +JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_doubletap(JNIEnv *env, jobject obj, jint p_x, jint p_y) { if (step == 0) return; diff --git a/platform/android/java_godot_lib_jni.h b/platform/android/java_godot_lib_jni.h index 08029c3c30..71d4547f65 100644 --- a/platform/android/java_godot_lib_jni.h +++ b/platform/android/java_godot_lib_jni.h @@ -46,7 +46,7 @@ JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_step(JNIEnv *env, job JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_back(JNIEnv *env, jobject obj); JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_touch(JNIEnv *env, jobject obj, jint ev, jint pointer, jint count, jintArray positions); JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_hover(JNIEnv *env, jobject obj, jint p_type, jint p_x, jint p_y); -JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_double_tap(JNIEnv *env, jobject obj, jint p_x, jint p_y); +JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_doubletap(JNIEnv *env, jobject obj, jint p_x, jint p_y); JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_scroll(JNIEnv *env, jobject obj, jint p_x, jint p_y); JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_key(JNIEnv *env, jobject obj, jint p_scancode, jint p_unicode_char, jboolean p_pressed); JNIEXPORT void JNICALL Java_org_godotengine_godot_GodotLib_joybutton(JNIEnv *env, jobject obj, jint p_device, jint p_button, jboolean p_pressed); diff --git a/platform/android/os_android.cpp b/platform/android/os_android.cpp index bbea5e3699..44c5b5d6b4 100644 --- a/platform/android/os_android.cpp +++ b/platform/android/os_android.cpp @@ -559,10 +559,10 @@ int OS_Android::get_virtual_keyboard_height() const { // return 0; } -void OS_Android::show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect) { +void OS_Android::show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect, int p_max_input_length) { if (godot_io_java->has_vk()) { - godot_io_java->show_vk(p_existing_text); + godot_io_java->show_vk(p_existing_text, p_max_input_length); } else { ERR_PRINT("Virtual keyboard not available"); diff --git a/platform/android/os_android.h b/platform/android/os_android.h index 1cf64a2e84..c2f9a0992f 100644 --- a/platform/android/os_android.h +++ b/platform/android/os_android.h @@ -158,7 +158,7 @@ public: virtual bool has_touchscreen_ui_hint() const; virtual bool has_virtual_keyboard() const; - virtual void show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect = Rect2()); + virtual void show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect = Rect2(), int p_max_input_length = -1); virtual void hide_virtual_keyboard(); virtual int get_virtual_keyboard_height() const; diff --git a/platform/haiku/detect.py b/platform/haiku/detect.py index 2a3e165069..dd72294816 100644 --- a/platform/haiku/detect.py +++ b/platform/haiku/detect.py @@ -95,7 +95,7 @@ def configure(env): if not env['builtin_enet']: env.ParseConfig('pkg-config libenet --cflags --libs') - if not env['builtin_squish'] and env['tools']: + if not env['builtin_squish']: env.ParseConfig('pkg-config libsquish --cflags --libs') if not env['builtin_zstd']: diff --git a/platform/iphone/export/export.cpp b/platform/iphone/export/export.cpp index b606d570c2..104f9e751e 100644 --- a/platform/iphone/export/export.cpp +++ b/platform/iphone/export/export.cpp @@ -1030,7 +1030,7 @@ Error EditorExportPlatformIOS::export_project(const Ref<EditorExportPreset> &p_p print_line("Creating " + dir_name); Error dir_err = tmp_app_path->make_dir_recursive(dir_name); if (dir_err) { - ERR_PRINTS("Can't create '" + dir_name + "'."); + ERR_PRINT("Can't create '" + dir_name + "'."); unzClose(src_pkg_zip); memdelete(tmp_app_path); return ERR_CANT_CREATE; @@ -1040,7 +1040,7 @@ Error EditorExportPlatformIOS::export_project(const Ref<EditorExportPreset> &p_p /* write the file */ FileAccess *f = FileAccess::open(file, FileAccess::WRITE); if (!f) { - ERR_PRINTS("Can't write '" + file + "'."); + ERR_PRINT("Can't write '" + file + "'."); unzClose(src_pkg_zip); memdelete(tmp_app_path); return ERR_CANT_CREATE; @@ -1064,7 +1064,7 @@ Error EditorExportPlatformIOS::export_project(const Ref<EditorExportPreset> &p_p unzClose(src_pkg_zip); if (!found_library) { - ERR_PRINTS("Requested template library '" + library_to_use + "' not found. It might be missing from your template archive."); + ERR_PRINT("Requested template library '" + library_to_use + "' not found. It might be missing from your template archive."); memdelete(tmp_app_path); return ERR_FILE_NOT_FOUND; } @@ -1093,7 +1093,7 @@ Error EditorExportPlatformIOS::export_project(const Ref<EditorExportPreset> &p_p String project_file_name = dest_dir + binary_name + ".xcodeproj/project.pbxproj"; FileAccess *f = FileAccess::open(project_file_name, FileAccess::WRITE); if (!f) { - ERR_PRINTS("Can't write '" + project_file_name + "'."); + ERR_PRINT("Can't write '" + project_file_name + "'."); return ERR_CANT_CREATE; }; f->store_buffer(project_file_data.ptr(), project_file_data.size()); diff --git a/platform/iphone/os_iphone.cpp b/platform/iphone/os_iphone.cpp index 7b1d0e6db1..7a699f9b50 100644 --- a/platform/iphone/os_iphone.cpp +++ b/platform/iphone/os_iphone.cpp @@ -356,14 +356,32 @@ void OSIPhone::delete_main_loop() { void OSIPhone::finalize() { - if (main_loop) // should not happen? - memdelete(main_loop); + delete_main_loop(); + + memdelete(input); + memdelete(ios); + +#ifdef GAME_CENTER_ENABLED + memdelete(game_center); +#endif + +#ifdef STOREKIT_ENABLED + memdelete(store_kit); +#endif + +#ifdef ICLOUD_ENABLED + memdelete(icloud); +#endif visual_server->finish(); memdelete(visual_server); // memdelete(rasterizer); - memdelete(input); + // Free unhandled events before close + for (int i = 0; i < MAX_EVENTS; i++) { + event_queue[i].unref(); + }; + event_count = 0; }; void OSIPhone::set_mouse_show(bool p_show){}; @@ -464,7 +482,7 @@ extern Error _shell_open(String p_uri); extern void _set_keep_screen_on(bool p_enabled); extern void _vibrate(); -void OSIPhone::show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect) { +void OSIPhone::show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect, int p_max_input_length) { _show_keyboard(p_existing_text); }; diff --git a/platform/iphone/os_iphone.h b/platform/iphone/os_iphone.h index 4668471aa9..d2d96181f5 100644 --- a/platform/iphone/os_iphone.h +++ b/platform/iphone/os_iphone.h @@ -165,7 +165,7 @@ public: virtual bool can_draw() const; virtual bool has_virtual_keyboard() const; - virtual void show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect = Rect2()); + virtual void show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect = Rect2(), int p_max_input_length = -1); virtual void hide_virtual_keyboard(); virtual int get_virtual_keyboard_height() const; diff --git a/platform/javascript/audio_driver_javascript.cpp b/platform/javascript/audio_driver_javascript.cpp index 4144eb3499..f1bc7c4382 100644 --- a/platform/javascript/audio_driver_javascript.cpp +++ b/platform/javascript/audio_driver_javascript.cpp @@ -63,7 +63,7 @@ void AudioDriverJavaScript::mix_to_js() { void AudioDriverJavaScript::process_capture(float sample) { int32_t sample32 = int32_t(sample * 32768.f) * (1U << 16); - capture_buffer_write(sample32); + input_buffer_write(sample32); } Error AudioDriverJavaScript::init() { @@ -198,7 +198,7 @@ void AudioDriverJavaScript::finish() { Error AudioDriverJavaScript::capture_start() { - capture_buffer_init(buffer_length); + input_buffer_init(buffer_length); /* clang-format off */ EM_ASM({ @@ -245,6 +245,8 @@ Error AudioDriverJavaScript::capture_stop() { }); /* clang-format on */ + input_buffer.clear(); + return OK; } diff --git a/platform/javascript/detect.py b/platform/javascript/detect.py index 7bf3e1bc1d..1766833364 100644 --- a/platform/javascript/detect.py +++ b/platform/javascript/detect.py @@ -131,6 +131,11 @@ def configure(env): env.Append(LINKFLAGS=['-s', 'BINARYEN=1']) + # Only include the JavaScript support code for the web environment + # (i.e. exclude Node.js and other unused environments). + # This makes the JavaScript support code about 4 KB smaller. + env.Append(LINKFLAGS=['-s', 'ENVIRONMENT=web']) + # This needs to be defined for Emscripten using 'fastcomp' (default pre-1.39.0) # and undefined if using 'upstream'. And to make things simple, earlier # Emscripten versions didn't include 'fastcomp' in their path, so we check diff --git a/platform/javascript/export/export.cpp b/platform/javascript/export/export.cpp index 93c83f4ff4..9b93d4f140 100644 --- a/platform/javascript/export/export.cpp +++ b/platform/javascript/export/export.cpp @@ -87,16 +87,22 @@ public: String filepath = EditorSettings::get_singleton()->get_cache_dir().plus_file("tmp_js_export"); String basereq = "/tmp_js_export"; + String ctype = ""; if (req[1] == basereq + ".html") { filepath += ".html"; + ctype = "text/html"; } else if (req[1] == basereq + ".js") { filepath += ".js"; + ctype = "application/javascript"; } else if (req[1] == basereq + ".pck") { filepath += ".pck"; + ctype = "application/octet-stream"; } else if (req[1] == basereq + ".png") { filepath += ".png"; + ctype = "image/png"; } else if (req[1] == basereq + ".wasm") { filepath += ".wasm"; + ctype = "application/wasm"; } else { String s = "HTTP/1.1 404 Not Found\r\n"; s += "Connection: Close\r\n"; @@ -109,10 +115,14 @@ public: ERR_FAIL_COND(!f); String s = "HTTP/1.1 200 OK\r\n"; s += "Connection: Close\r\n"; + s += "Content-Type: " + ctype + "\r\n"; s += "\r\n"; CharString cs = s.utf8(); Error err = connection->put_data((const uint8_t *)cs.get_data(), cs.size() - 1); - ERR_FAIL_COND(err != OK); + if (err != OK) { + memdelete(f); + ERR_FAIL(); + } while (true) { uint8_t bytes[4096]; @@ -121,8 +131,12 @@ public: break; } err = connection->put_data(bytes, read); - ERR_FAIL_COND(err != OK); + if (err != OK) { + memdelete(f); + ERR_FAIL(); + } } + memdelete(f); } void poll() { diff --git a/platform/javascript/http_request.js b/platform/javascript/http_request.js index c112039d0b..f621689f9d 100644 --- a/platform/javascript/http_request.js +++ b/platform/javascript/http_request.js @@ -3,9 +3,10 @@ /*************************************************************************/ /* This file is part of: */ /* GODOT ENGINE */ -/* http://www.godotengine.org */ +/* https://godotengine.org */ /*************************************************************************/ /* Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). */ /* */ /* Permission is hereby granted, free of charge, to any person obtaining */ /* a copy of this software and associated documentation files (the */ diff --git a/platform/javascript/id_handler.js b/platform/javascript/id_handler.js index 36ef5aa8ef..3851123ed1 100644 --- a/platform/javascript/id_handler.js +++ b/platform/javascript/id_handler.js @@ -3,9 +3,10 @@ /*************************************************************************/ /* This file is part of: */ /* GODOT ENGINE */ -/* http://www.godotengine.org */ +/* https://godotengine.org */ /*************************************************************************/ -/* Copyright (c) 2007-2018 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). */ /* */ /* Permission is hereby granted, free of charge, to any person obtaining */ /* a copy of this software and associated documentation files (the */ diff --git a/platform/javascript/os_javascript.cpp b/platform/javascript/os_javascript.cpp index 5562b059f4..87764d5750 100644 --- a/platform/javascript/os_javascript.cpp +++ b/platform/javascript/os_javascript.cpp @@ -49,6 +49,7 @@ #define DOM_BUTTON_RIGHT 2 #define DOM_BUTTON_XBUTTON1 3 #define DOM_BUTTON_XBUTTON2 4 +#define GODOT_CANVAS_SELECTOR "#canvas" // Window (canvas) @@ -70,18 +71,23 @@ static bool is_canvas_focused() { /* clang-format on */ } -static Point2 correct_canvas_position(int x, int y) { +static Point2 compute_position_in_canvas(int x, int y) { + int canvas_x = EM_ASM_INT({ + return document.getElementById('canvas').getBoundingClientRect().x; + }); + int canvas_y = EM_ASM_INT({ + return document.getElementById('canvas').getBoundingClientRect().y; + }); int canvas_width; int canvas_height; - emscripten_get_canvas_element_size(NULL, &canvas_width, &canvas_height); + emscripten_get_canvas_element_size(GODOT_CANVAS_SELECTOR, &canvas_width, &canvas_height); double element_width; double element_height; - emscripten_get_element_css_size(NULL, &element_width, &element_height); + emscripten_get_element_css_size(GODOT_CANVAS_SELECTOR, &element_width, &element_height); - x = (int)(canvas_width / element_width * x); - y = (int)(canvas_height / element_height * y); - return Point2(x, y); + return Point2((int)(canvas_width / element_width * (x - canvas_x)), + (int)(canvas_height / element_height * (y - canvas_y))); } static bool cursor_inside_canvas = true; @@ -135,14 +141,14 @@ void OS_JavaScript::set_window_size(const Size2 p_size) { emscripten_exit_soft_fullscreen(); window_maximized = false; } - emscripten_set_canvas_element_size(NULL, p_size.x, p_size.y); + emscripten_set_canvas_element_size(GODOT_CANVAS_SELECTOR, p_size.x, p_size.y); } } Size2 OS_JavaScript::get_window_size() const { int canvas[2]; - emscripten_get_canvas_element_size(NULL, canvas, canvas + 1); + emscripten_get_canvas_element_size(GODOT_CANVAS_SELECTOR, canvas, canvas + 1); return Size2(canvas[0], canvas[1]); } @@ -162,7 +168,7 @@ void OS_JavaScript::set_window_maximized(bool p_enabled) { strategy.canvasResolutionScaleMode = EMSCRIPTEN_FULLSCREEN_CANVAS_SCALE_STDDEF; strategy.filteringMode = EMSCRIPTEN_FULLSCREEN_FILTERING_DEFAULT; strategy.canvasResizedCallback = NULL; - emscripten_enter_soft_fullscreen(NULL, &strategy); + emscripten_enter_soft_fullscreen(GODOT_CANVAS_SELECTOR, &strategy); window_maximized = p_enabled; } } @@ -191,7 +197,7 @@ void OS_JavaScript::set_window_fullscreen(bool p_enabled) { strategy.canvasResolutionScaleMode = EMSCRIPTEN_FULLSCREEN_CANVAS_SCALE_STDDEF; strategy.filteringMode = EMSCRIPTEN_FULLSCREEN_FILTERING_DEFAULT; strategy.canvasResizedCallback = NULL; - EMSCRIPTEN_RESULT result = emscripten_request_fullscreen_strategy(NULL, false, &strategy); + EMSCRIPTEN_RESULT result = emscripten_request_fullscreen_strategy(GODOT_CANVAS_SELECTOR, false, &strategy); ERR_FAIL_COND_MSG(result == EMSCRIPTEN_RESULT_FAILED_NOT_DEFERRED, "Enabling fullscreen is only possible from an input callback for the HTML5 platform."); ERR_FAIL_COND_MSG(result != EMSCRIPTEN_RESULT_SUCCESS, "Enabling fullscreen is only possible from an input callback for the HTML5 platform."); // Not fullscreen yet, so prevent "windowed" canvas dimensions from @@ -298,9 +304,10 @@ EM_BOOL OS_JavaScript::mouse_button_callback(int p_event_type, const EmscriptenM Ref<InputEventMouseButton> ev; ev.instance(); ev->set_pressed(p_event_type == EMSCRIPTEN_EVENT_MOUSEDOWN); - ev->set_position(correct_canvas_position(p_event->canvasX, p_event->canvasY)); + ev->set_position(compute_position_in_canvas(p_event->clientX, p_event->clientY)); ev->set_global_position(ev->get_position()); dom2godot_mod(p_event, ev); + switch (p_event->button) { case DOM_BUTTON_LEFT: ev->set_button_index(BUTTON_LEFT); break; case DOM_BUTTON_MIDDLE: ev->set_button_index(BUTTON_MIDDLE); break; @@ -312,7 +319,7 @@ EM_BOOL OS_JavaScript::mouse_button_callback(int p_event_type, const EmscriptenM if (ev->is_pressed()) { - uint64_t diff = p_event->timestamp - os->last_click_ms; + double diff = emscripten_get_now() - os->last_click_ms; if (ev->get_button_index() == os->last_click_button_index) { @@ -362,7 +369,7 @@ EM_BOOL OS_JavaScript::mousemove_callback(int p_event_type, const EmscriptenMous OS_JavaScript *os = get_singleton(); int input_mask = os->input->get_mouse_button_mask(); - Point2 pos = correct_canvas_position(p_event->canvasX, p_event->canvasY); + Point2 pos = compute_position_in_canvas(p_event->clientX, p_event->clientY); // For motion outside the canvas, only read mouse movement if dragging // started inside the canvas; imitating desktop app behaviour. if (!cursor_inside_canvas && !input_mask) @@ -696,7 +703,7 @@ EM_BOOL OS_JavaScript::touch_press_callback(int p_event_type, const EmscriptenTo if (!touch.isChanged) continue; ev->set_index(touch.identifier); - ev->set_position(correct_canvas_position(touch.canvasX, touch.canvasY)); + ev->set_position(compute_position_in_canvas(touch.clientX, touch.clientY)); os->touches[i] = ev->get_position(); ev->set_pressed(p_event_type == EMSCRIPTEN_EVENT_TOUCHSTART); @@ -721,7 +728,7 @@ EM_BOOL OS_JavaScript::touchmove_callback(int p_event_type, const EmscriptenTouc if (!touch.isChanged) continue; ev->set_index(touch.identifier); - ev->set_position(correct_canvas_position(touch.canvasX, touch.canvasY)); + ev->set_position(compute_position_in_canvas(touch.clientX, touch.clientY)); Point2 &prev = os->touches[i]; ev->set_relative(ev->get_position() - prev); prev = ev->get_position(); @@ -920,7 +927,7 @@ Error OS_JavaScript::initialize(const VideoMode &p_desired, int p_video_driver, } } - EMSCRIPTEN_WEBGL_CONTEXT_HANDLE ctx = emscripten_webgl_create_context(NULL, &attributes); + EMSCRIPTEN_WEBGL_CONTEXT_HANDLE ctx = emscripten_webgl_create_context(GODOT_CANVAS_SELECTOR, &attributes); if (emscripten_webgl_make_context_current(ctx) != EMSCRIPTEN_RESULT_SUCCESS) { gl_initialization_error = true; } @@ -973,7 +980,7 @@ Error OS_JavaScript::initialize(const VideoMode &p_desired, int p_video_driver, EMSCRIPTEN_RESULT result; #define EM_CHECK(ev) \ if (result != EMSCRIPTEN_RESULT_SUCCESS) \ - ERR_PRINTS("Error while setting " #ev " callback: Code " + itos(result)) + ERR_PRINT("Error while setting " #ev " callback: Code " + itos(result)) #define SET_EM_CALLBACK(target, ev, cb) \ result = emscripten_set_##ev##_callback(target, NULL, true, &cb); \ EM_CHECK(ev) @@ -983,21 +990,21 @@ Error OS_JavaScript::initialize(const VideoMode &p_desired, int p_video_driver, // These callbacks from Emscripten's html5.h suffice to access most // JavaScript APIs. For APIs that are not (sufficiently) exposed, EM_ASM // is used below. - SET_EM_CALLBACK("#window", mousemove, mousemove_callback) - SET_EM_CALLBACK("#canvas", mousedown, mouse_button_callback) - SET_EM_CALLBACK("#window", mouseup, mouse_button_callback) - SET_EM_CALLBACK("#window", wheel, wheel_callback) - SET_EM_CALLBACK("#window", touchstart, touch_press_callback) - SET_EM_CALLBACK("#window", touchmove, touchmove_callback) - SET_EM_CALLBACK("#window", touchend, touch_press_callback) - SET_EM_CALLBACK("#window", touchcancel, touch_press_callback) - SET_EM_CALLBACK("#canvas", keydown, keydown_callback) - SET_EM_CALLBACK("#canvas", keypress, keypress_callback) - SET_EM_CALLBACK("#canvas", keyup, keyup_callback) - SET_EM_CALLBACK(NULL, fullscreenchange, fullscreen_change_callback) + SET_EM_CALLBACK(EMSCRIPTEN_EVENT_TARGET_WINDOW, mousemove, mousemove_callback) + SET_EM_CALLBACK(GODOT_CANVAS_SELECTOR, mousedown, mouse_button_callback) + SET_EM_CALLBACK(EMSCRIPTEN_EVENT_TARGET_WINDOW, mouseup, mouse_button_callback) + SET_EM_CALLBACK(EMSCRIPTEN_EVENT_TARGET_WINDOW, wheel, wheel_callback) + SET_EM_CALLBACK(EMSCRIPTEN_EVENT_TARGET_WINDOW, touchstart, touch_press_callback) + SET_EM_CALLBACK(EMSCRIPTEN_EVENT_TARGET_WINDOW, touchmove, touchmove_callback) + SET_EM_CALLBACK(EMSCRIPTEN_EVENT_TARGET_WINDOW, touchend, touch_press_callback) + SET_EM_CALLBACK(EMSCRIPTEN_EVENT_TARGET_WINDOW, touchcancel, touch_press_callback) + SET_EM_CALLBACK(GODOT_CANVAS_SELECTOR, keydown, keydown_callback) + SET_EM_CALLBACK(GODOT_CANVAS_SELECTOR, keypress, keypress_callback) + SET_EM_CALLBACK(GODOT_CANVAS_SELECTOR, keyup, keyup_callback) + SET_EM_CALLBACK(EMSCRIPTEN_EVENT_TARGET_DOCUMENT, fullscreenchange, fullscreen_change_callback) SET_EM_CALLBACK_NOTARGET(gamepadconnected, gamepad_change_callback) SET_EM_CALLBACK_NOTARGET(gamepaddisconnected, gamepad_change_callback) -#undef SET_EM_CALLBACK_NODATA +#undef SET_EM_CALLBACK_NOTARGET #undef SET_EM_CALLBACK #undef EM_CHECK @@ -1078,15 +1085,15 @@ bool OS_JavaScript::main_loop_iterate() { strategy.canvasResolutionScaleMode = EMSCRIPTEN_FULLSCREEN_CANVAS_SCALE_STDDEF; strategy.filteringMode = EMSCRIPTEN_FULLSCREEN_FILTERING_DEFAULT; strategy.canvasResizedCallback = NULL; - emscripten_enter_soft_fullscreen(NULL, &strategy); + emscripten_enter_soft_fullscreen(GODOT_CANVAS_SELECTOR, &strategy); } else { - emscripten_set_canvas_element_size(NULL, windowed_size.width, windowed_size.height); + emscripten_set_canvas_element_size(GODOT_CANVAS_SELECTOR, windowed_size.width, windowed_size.height); } just_exited_fullscreen = false; } int canvas[2]; - emscripten_get_canvas_element_size(NULL, canvas, canvas + 1); + emscripten_get_canvas_element_size(GODOT_CANVAS_SELECTOR, canvas, canvas + 1); video_mode.width = canvas[0]; video_mode.height = canvas[1]; if (!window_maximized && !video_mode.fullscreen && !just_exited_fullscreen && !entering_fullscreen) { diff --git a/platform/javascript/os_javascript.h b/platform/javascript/os_javascript.h index a5696f8aae..5c02a292ee 100644 --- a/platform/javascript/os_javascript.h +++ b/platform/javascript/os_javascript.h @@ -55,7 +55,7 @@ class OS_JavaScript : public OS_Unix { Point2 touches[32]; Point2i last_click_pos; - uint64_t last_click_ms; + double last_click_ms; int last_click_button_index; MainLoop *main_loop; @@ -141,7 +141,7 @@ public: void run_async(); bool main_loop_iterate(); - virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL); + virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking = true, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL); virtual Error kill(const ProcessID &p_pid); virtual int get_process_id() const; diff --git a/platform/osx/detect.py b/platform/osx/detect.py index 7882253e7a..fe839199e8 100644 --- a/platform/osx/detect.py +++ b/platform/osx/detect.py @@ -27,6 +27,9 @@ def get_opts(): ('MACOS_SDK_PATH', 'Path to the macOS SDK', ''), EnumVariable('debug_symbols', 'Add debugging symbols to release builds', 'yes', ('yes', 'no', 'full')), BoolVariable('separate_debug_symbols', 'Create a separate file containing debugging symbols', False), + BoolVariable('use_ubsan', 'Use LLVM/GCC compiler undefined behavior sanitizer (UBSAN)', False), + BoolVariable('use_asan', 'Use LLVM/GCC compiler address sanitizer (ASAN))', False), + BoolVariable('use_tsan', 'Use LLVM/GCC compiler thread sanitizer (TSAN))', False), ] @@ -122,6 +125,21 @@ def configure(env): env["CC"] = "clang" env["LINK"] = "clang++" + if env['use_ubsan'] or env['use_asan'] or env['use_tsan']: + env.extra_suffix += "s" + + if env['use_ubsan']: + env.Append(CCFLAGS=['-fsanitize=undefined']) + env.Append(LINKFLAGS=['-fsanitize=undefined']) + + if env['use_asan']: + env.Append(CCFLAGS=['-fsanitize=address']) + env.Append(LINKFLAGS=['-fsanitize=address']) + + if env['use_tsan']: + env.Append(CCFLAGS=['-fsanitize=thread']) + env.Append(LINKFLAGS=['-fsanitize=thread']) + ## Dependencies if env['builtin_libtheora']: diff --git a/platform/osx/export/export.cpp b/platform/osx/export/export.cpp index cf38664022..f372093268 100644 --- a/platform/osx/export/export.cpp +++ b/platform/osx/export/export.cpp @@ -692,7 +692,7 @@ Error EditorExportPlatformOSX::export_project(const Ref<EditorExportPreset> &p_p unzClose(src_pkg_zip); if (!found_binary) { - ERR_PRINTS("Requested template binary '" + binary_to_use + "' not found. It might be missing from your template archive."); + ERR_PRINT("Requested template binary '" + binary_to_use + "' not found. It might be missing from your template archive."); err = ERR_FILE_NOT_FOUND; } diff --git a/platform/osx/os_osx.h b/platform/osx/os_osx.h index 58a47c102a..190dbcf662 100644 --- a/platform/osx/os_osx.h +++ b/platform/osx/os_osx.h @@ -76,8 +76,6 @@ public: List<String> args; MainLoop *main_loop; - IP_Unix *ip_unix; - #ifdef COREAUDIO_ENABLED AudioDriverCoreAudio audio_driver; #endif diff --git a/platform/osx/os_osx.mm b/platform/osx/os_osx.mm index 2b002d3b5d..bc77ac3cfd 100644 --- a/platform/osx/os_osx.mm +++ b/platform/osx/os_osx.mm @@ -115,6 +115,20 @@ static Vector2 get_mouse_pos(NSPoint locationInWindow, CGFloat backingScaleFacto return Vector2(mouse_x, mouse_y); } +static NSCursor *cursorFromSelector(SEL selector, SEL fallback = nil) { + if ([NSCursor respondsToSelector:selector]) { + id object = [NSCursor performSelector:selector]; + if ([object isKindOfClass:[NSCursor class]]) { + return object; + } + } + if (fallback) { + // Fallback should be a reasonable default, no need to check. + return [NSCursor performSelector:fallback]; + } + return [NSCursor arrowCursor]; +} + @interface GodotApplication : NSApplication @end @@ -479,7 +493,7 @@ static const NSRange kEmptyRange = { NSNotFound, 0 }; } - (NSRange)markedRange { - return (markedText.length > 0) ? NSMakeRange(0, markedText.length - 1) : kEmptyRange; + return NSMakeRange(0, markedText.length); } - (NSRange)selectedRange { @@ -492,6 +506,10 @@ static const NSRange kEmptyRange = { NSNotFound, 0 }; } else { [markedText initWithString:aString]; } + if (markedText.length == 0) { + [self unmarkText]; + return; + } if (OS_OSX::singleton->im_active) { imeInputEventInProgress = true; OS_OSX::singleton->im_text.parse_utf8([[markedText mutableString] UTF8String]); @@ -1809,15 +1827,15 @@ void OS_OSX::set_cursor_shape(CursorShape p_shape) { case CURSOR_BUSY: [[NSCursor arrowCursor] set]; break; case CURSOR_DRAG: [[NSCursor closedHandCursor] set]; break; case CURSOR_CAN_DROP: [[NSCursor openHandCursor] set]; break; - case CURSOR_FORBIDDEN: [[NSCursor arrowCursor] set]; break; - case CURSOR_VSIZE: [[NSCursor resizeUpDownCursor] set]; break; - case CURSOR_HSIZE: [[NSCursor resizeLeftRightCursor] set]; break; - case CURSOR_BDIAGSIZE: [[NSCursor arrowCursor] set]; break; - case CURSOR_FDIAGSIZE: [[NSCursor arrowCursor] set]; break; + case CURSOR_FORBIDDEN: [[NSCursor operationNotAllowedCursor] set]; break; + case CURSOR_VSIZE: [cursorFromSelector(@selector(_windowResizeNorthSouthCursor), @selector(resizeUpDownCursor)) set]; break; + case CURSOR_HSIZE: [cursorFromSelector(@selector(_windowResizeEastWestCursor), @selector(resizeLeftRightCursor)) set]; break; + case CURSOR_BDIAGSIZE: [cursorFromSelector(@selector(_windowResizeNorthEastSouthWestCursor)) set]; break; + case CURSOR_FDIAGSIZE: [cursorFromSelector(@selector(_windowResizeNorthWestSouthEastCursor)) set]; break; case CURSOR_MOVE: [[NSCursor arrowCursor] set]; break; case CURSOR_VSPLIT: [[NSCursor resizeUpDownCursor] set]; break; case CURSOR_HSPLIT: [[NSCursor resizeLeftRightCursor] set]; break; - case CURSOR_HELP: [[NSCursor arrowCursor] set]; break; + case CURSOR_HELP: [cursorFromSelector(@selector(_helpCursor)) set]; break; default: { }; } @@ -2913,7 +2931,7 @@ void OS_OSX::run() { quit = true; } } @catch (NSException *exception) { - ERR_PRINTS("NSException: " + String([exception reason].UTF8String)); + ERR_PRINT("NSException: " + String([exception reason].UTF8String)); } }; @@ -2969,7 +2987,7 @@ Error OS_OSX::move_to_trash(const String &p_path) { NSError *err; if (![fm trashItemAtURL:url resultingItemURL:nil error:&err]) { - ERR_PRINTS("trashItemAtURL error: " + String(err.localizedDescription.UTF8String)); + ERR_PRINT("trashItemAtURL error: " + String(err.localizedDescription.UTF8String)); return FAILED; } diff --git a/platform/server/detect.py b/platform/server/detect.py index b6028c20e3..d82df77957 100644 --- a/platform/server/detect.py +++ b/platform/server/detect.py @@ -162,7 +162,7 @@ def configure(env): if not env['builtin_enet']: env.ParseConfig('pkg-config libenet --cflags --libs') - if not env['builtin_squish'] and env['tools']: + if not env['builtin_squish']: env.ParseConfig('pkg-config libsquish --cflags --libs') if not env['builtin_zstd']: diff --git a/platform/server/os_server.h b/platform/server/os_server.h index 0aca8049f2..46ca9cb6d1 100644 --- a/platform/server/os_server.h +++ b/platform/server/os_server.h @@ -58,7 +58,6 @@ class OS_Server : public OS_Unix { bool grab; virtual void delete_main_loop(); - IP_Unix *ip_unix; bool force_quit; diff --git a/platform/uwp/export/export.cpp b/platform/uwp/export/export.cpp index 57fb9004b8..96a196c65d 100644 --- a/platform/uwp/export/export.cpp +++ b/platform/uwp/export/export.cpp @@ -1176,7 +1176,7 @@ public: err += TTR("Invalid square 71x71 logo image dimensions (should be 71x71).") + "\n"; } - if (!p_preset->get("images/square150x150_logo").is_zero() && !_valid_image((Object::cast_to<StreamTexture>((Object *)p_preset->get("images/square150x150_logo"))), 150, 0)) { + if (!p_preset->get("images/square150x150_logo").is_zero() && !_valid_image((Object::cast_to<StreamTexture>((Object *)p_preset->get("images/square150x150_logo"))), 150, 150)) { valid = false; err += TTR("Invalid square 150x150 logo image dimensions (should be 150x150).") + "\n"; } @@ -1397,7 +1397,7 @@ public: } if (!FileAccess::exists(signtool_path)) { - ERR_PRINTS("Could not find signtool executable at " + signtool_path + ", aborting."); + ERR_PRINT("Could not find signtool executable at " + signtool_path + ", aborting."); return ERR_FILE_NOT_FOUND; } @@ -1418,12 +1418,12 @@ public: } if (!FileAccess::exists(cert_path)) { - ERR_PRINTS("Could not find certificate file at " + cert_path + ", aborting."); + ERR_PRINT("Could not find certificate file at " + cert_path + ", aborting."); return ERR_FILE_NOT_FOUND; } if (cert_alg < 0 || cert_alg > 2) { - ERR_PRINTS("Invalid certificate algorithm " + itos(cert_alg) + ", aborting."); + ERR_PRINT("Invalid certificate algorithm " + itos(cert_alg) + ", aborting."); return ERR_INVALID_DATA; } diff --git a/platform/uwp/os_uwp.cpp b/platform/uwp/os_uwp.cpp index aec5da316b..d5047b53ab 100644 --- a/platform/uwp/os_uwp.cpp +++ b/platform/uwp/os_uwp.cpp @@ -801,7 +801,7 @@ bool OS_UWP::has_virtual_keyboard() const { return UIViewSettings::GetForCurrentView()->UserInteractionMode == UserInteractionMode::Touch; } -void OS_UWP::show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect) { +void OS_UWP::show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect, int p_max_input_length) { InputPane ^ pane = InputPane::GetForCurrentView(); pane->TryShow(); diff --git a/platform/uwp/os_uwp.h b/platform/uwp/os_uwp.h index edc63bd637..fb43ab382e 100644 --- a/platform/uwp/os_uwp.h +++ b/platform/uwp/os_uwp.h @@ -205,7 +205,7 @@ public: virtual void delay_usec(uint32_t p_usec) const; virtual uint64_t get_ticks_usec() const; - virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL); + virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking = true, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL); virtual Error kill(const ProcessID &p_pid); virtual bool has_environment(const String &p_var) const; @@ -239,7 +239,7 @@ public: virtual bool has_touchscreen_ui_hint() const; virtual bool has_virtual_keyboard() const; - virtual void show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect = Rect2()); + virtual void show_virtual_keyboard(const String &p_existing_text, const Rect2 &p_screen_rect = Rect2(), int p_max_input_length = -1); virtual void hide_virtual_keyboard(); virtual Error open_dynamic_library(const String p_path, void *&p_library_handle, bool p_also_set_library_path = false); diff --git a/platform/windows/context_gl_windows.cpp b/platform/windows/context_gl_windows.cpp index 21d954a736..ad62e3a306 100644 --- a/platform/windows/context_gl_windows.cpp +++ b/platform/windows/context_gl_windows.cpp @@ -43,6 +43,11 @@ #define WGL_CONTEXT_PROFILE_MASK_ARB 0x9126 #define WGL_CONTEXT_CORE_PROFILE_BIT_ARB 0x00000001 +#if defined(__GNUC__) +// Workaround GCC warning from -Wcast-function-type. +#define wglGetProcAddress (void *)wglGetProcAddress +#endif + typedef HGLRC(APIENTRY *PFNWGLCREATECONTEXTATTRIBSARBPROC)(HDC, HGLRC, const int *); void ContextGL_Windows::release_current() { @@ -89,7 +94,7 @@ void ContextGL_Windows::swap_buffers() { if (use_vsync) { bool vsync_via_compositor_now = should_vsync_via_compositor(); - if (vsync_via_compositor_now) { + if (vsync_via_compositor_now && wglGetSwapIntervalEXT() == 0) { DwmFlush(); } @@ -205,6 +210,7 @@ Error ContextGL_Windows::initialize() { } wglSwapIntervalEXT = (PFNWGLSWAPINTERVALEXTPROC)wglGetProcAddress("wglSwapIntervalEXT"); + wglGetSwapIntervalEXT = (PFNWGLGETSWAPINTERVALEXTPROC)wglGetProcAddress("wglGetSwapIntervalEXT"); //glWrapperInit(wrapper_get_proc_address); return OK; diff --git a/platform/windows/context_gl_windows.h b/platform/windows/context_gl_windows.h index 0c6a6d1814..280c5a1e3c 100644 --- a/platform/windows/context_gl_windows.h +++ b/platform/windows/context_gl_windows.h @@ -41,6 +41,7 @@ #include <windows.h> typedef bool(APIENTRY *PFNWGLSWAPINTERVALEXTPROC)(int interval); +typedef int(APIENTRY *PFNWGLGETSWAPINTERVALEXTPROC)(void); class ContextGL_Windows { @@ -53,6 +54,7 @@ class ContextGL_Windows { bool vsync_via_compositor; PFNWGLSWAPINTERVALEXTPROC wglSwapIntervalEXT; + PFNWGLGETSWAPINTERVALEXTPROC wglGetSwapIntervalEXT; static bool should_vsync_via_compositor(); diff --git a/platform/windows/export/export.cpp b/platform/windows/export/export.cpp index 34d66ecd79..31501c2cd3 100644 --- a/platform/windows/export/export.cpp +++ b/platform/windows/export/export.cpp @@ -105,7 +105,7 @@ void EditorExportPlatformWindows::_rcedit_add_data(const Ref<EditorExportPreset> } if (!FileAccess::exists(rcedit_path)) { - ERR_PRINTS("Could not find rcedit executable at " + rcedit_path + ", no icon or app information data will be included."); + ERR_PRINT("Could not find rcedit executable at " + rcedit_path + ", no icon or app information data will be included."); return; } @@ -114,7 +114,7 @@ void EditorExportPlatformWindows::_rcedit_add_data(const Ref<EditorExportPreset> String wine_path = EditorSettings::get_singleton()->get("export/windows/wine"); if (wine_path != String() && !FileAccess::exists(wine_path)) { - ERR_PRINTS("Could not find wine executable at " + wine_path + ", no icon or app information data will be included."); + ERR_PRINT("Could not find wine executable at " + wine_path + ", no icon or app information data will be included."); return; } @@ -188,7 +188,7 @@ Error EditorExportPlatformWindows::_code_sign(const Ref<EditorExportPreset> &p_p #ifdef WINDOWS_ENABLED String signtool_path = EditorSettings::get_singleton()->get("export/windows/signtool"); if (signtool_path != String() && !FileAccess::exists(signtool_path)) { - ERR_PRINTS("Could not find signtool executable at " + signtool_path + ", aborting."); + ERR_PRINT("Could not find signtool executable at " + signtool_path + ", aborting."); return ERR_FILE_NOT_FOUND; } if (signtool_path == String()) { @@ -197,7 +197,7 @@ Error EditorExportPlatformWindows::_code_sign(const Ref<EditorExportPreset> &p_p #else String signtool_path = EditorSettings::get_singleton()->get("export/windows/osslsigncode"); if (signtool_path != String() && !FileAccess::exists(signtool_path)) { - ERR_PRINTS("Could not find osslsigncode executable at " + signtool_path + ", aborting."); + ERR_PRINT("Could not find osslsigncode executable at " + signtool_path + ", aborting."); return ERR_FILE_NOT_FOUND; } if (signtool_path == String()) { diff --git a/platform/windows/joypad_windows.cpp b/platform/windows/joypad_windows.cpp index c82a90bf7d..49432435b9 100644 --- a/platform/windows/joypad_windows.cpp +++ b/platform/windows/joypad_windows.cpp @@ -37,6 +37,11 @@ #define __builtin_bswap32 _byteswap_ulong #endif +#if defined(__GNUC__) +// Workaround GCC warning from -Wcast-function-type. +#define GetProcAddress (void *)GetProcAddress +#endif + DWORD WINAPI _xinput_get_state(DWORD dwUserIndex, XINPUT_STATE *pState) { return ERROR_DEVICE_NOT_CONNECTED; } diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp index 3868d0bc63..2daaf9359a 100755 --- a/platform/windows/os_windows.cpp +++ b/platform/windows/os_windows.cpp @@ -74,6 +74,11 @@ __declspec(dllexport) int AmdPowerXpressRequestHighPerformance = 1; #define WM_POINTERUPDATE 0x0245 #endif +#if defined(__GNUC__) +// Workaround GCC warning from -Wcast-function-type. +#define GetProcAddress (void *)GetProcAddress +#endif + typedef struct { int count; int screen; @@ -2849,7 +2854,7 @@ void OS_Windows::set_native_icon(const String &p_filename) { ERR_FAIL_COND_MSG(big_icon_index == -1, "No valid icons found!"); if (small_icon_index == -1) { - WARN_PRINTS("No small icon found, reusing " + itos(big_icon_width) + "x" + itos(big_icon_width) + " @" + itos(big_icon_cc) + " icon!"); + WARN_PRINT("No small icon found, reusing " + itos(big_icon_width) + "x" + itos(big_icon_width) + " @" + itos(big_icon_cc) + " icon!"); small_icon_index = big_icon_index; small_icon_cc = big_icon_cc; } @@ -3358,7 +3363,7 @@ Error OS_Windows::move_to_trash(const String &p_path) { delete[] from; if (ret) { - ERR_PRINTS("SHFileOperation error: " + itos(ret)); + ERR_PRINT("SHFileOperation error: " + itos(ret)); return FAILED; } diff --git a/platform/windows/os_windows.h b/platform/windows/os_windows.h index 65d08f5d36..cf16295a70 100644 --- a/platform/windows/os_windows.h +++ b/platform/windows/os_windows.h @@ -359,7 +359,7 @@ public: virtual void delay_usec(uint32_t p_usec) const; virtual uint64_t get_ticks_usec() const; - virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL); + virtual Error execute(const String &p_path, const List<String> &p_arguments, bool p_blocking = true, ProcessID *r_child_id = NULL, String *r_pipe = NULL, int *r_exitcode = NULL, bool read_stderr = false, Mutex *p_pipe_mutex = NULL); virtual Error kill(const ProcessID &p_pid); virtual int get_process_id() const; diff --git a/platform/x11/detect.py b/platform/x11/detect.py index b8ff97279d..bd5e5e0812 100644 --- a/platform/x11/detect.py +++ b/platform/x11/detect.py @@ -171,7 +171,7 @@ def configure(env): else: env.Append(CCFLAGS=['-flto']) env.Append(LINKFLAGS=['-flto']) - + if not env['use_llvm']: env['RANLIB'] = 'gcc-ranlib' env['AR'] = 'gcc-ar' @@ -232,7 +232,7 @@ def configure(env): if not env['builtin_enet']: env.ParseConfig('pkg-config libenet --cflags --libs') - if not env['builtin_squish'] and env['tools']: + if not env['builtin_squish']: env.ParseConfig('pkg-config libsquish --cflags --libs') if not env['builtin_zstd']: @@ -329,9 +329,19 @@ def configure(env): if env["execinfo"]: env.Append(LIBS=['execinfo']) - + if not env['tools']: - env.Append(LINKFLAGS=['-T', 'platform/x11/pck_embed.ld']) + import subprocess + import re + linker_version_str = subprocess.check_output([env.subst(env["LINK"]), '-Wl,--version']).decode("utf-8") + gnu_ld_version = re.search('^GNU ld [^$]*(\d+\.\d+)$', linker_version_str, re.MULTILINE) + if not gnu_ld_version: + print("Warning: Creating template binaries enabled for PCK embedding is currently only supported with GNU ld") + else: + if float(gnu_ld_version.group(1)) >= 2.30: + env.Append(LINKFLAGS=['-T', 'platform/x11/pck_embed.ld']) + else: + env.Append(LINKFLAGS=['-T', 'platform/x11/pck_embed.legacy.ld']) ## Cross-compilation diff --git a/platform/x11/os_x11.cpp b/platform/x11/os_x11.cpp index 2f0d49e6dd..55a612eb37 100644 --- a/platform/x11/os_x11.cpp +++ b/platform/x11/os_x11.cpp @@ -1429,11 +1429,15 @@ void OS_X11::set_window_fullscreen(bool p_enabled) { set_window_maximized(true); } set_wm_fullscreen(p_enabled); - if (!p_enabled && !current_videomode.always_on_top) { + if (!p_enabled && current_videomode.always_on_top) { // Restore set_window_maximized(false); } - + if (!p_enabled) { + set_window_position(last_position_before_fs); + } else { + last_position_before_fs = get_window_position(); + } current_videomode.fullscreen = p_enabled; } @@ -2000,11 +2004,6 @@ void OS_X11::handle_key_event(XKeyEvent *p_event, bool p_echo) { if (last_is_pressed) { k->set_echo(true); } - } else { - //ignore - if (!last_is_pressed) { - return; - } } //printf("key: %x\n",k->get_scancode()); @@ -3407,7 +3406,7 @@ Error OS_X11::move_to_trash(const String &p_path) { // Issue an error if none of the previous locations is appropriate for the trash can. if (trash_can == "") { - ERR_PRINTS("move_to_trash: Could not determine the trash can location"); + ERR_PRINT("move_to_trash: Could not determine the trash can location"); return FAILED; } @@ -3418,7 +3417,7 @@ Error OS_X11::move_to_trash(const String &p_path) { // Issue an error if trash can is not created proprely. if (err != OK) { - ERR_PRINTS("move_to_trash: Could not create the trash can \"" + trash_can + "\""); + ERR_PRINT("move_to_trash: Could not create the trash can \"" + trash_can + "\""); return err; } @@ -3432,7 +3431,7 @@ Error OS_X11::move_to_trash(const String &p_path) { // Issue an error if "mv" failed to move the given resource to the trash can. if (err != OK || retval != 0) { - ERR_PRINTS("move_to_trash: Could not move the resource \"" + p_path + "\" to the trash can \"" + trash_can + "\""); + ERR_PRINT("move_to_trash: Could not move the resource \"" + p_path + "\" to the trash can \"" + trash_can + "\""); return FAILED; } @@ -3507,4 +3506,5 @@ OS_X11::OS_X11() { window_focused = true; xim_style = 0L; mouse_mode = MOUSE_MODE_VISIBLE; + last_position_before_fs = Vector2(); } diff --git a/platform/x11/os_x11.h b/platform/x11/os_x11.h index 01e5aac3df..25b406743b 100644 --- a/platform/x11/os_x11.h +++ b/platform/x11/os_x11.h @@ -115,6 +115,7 @@ class OS_X11 : public OS_Unix { // IME bool im_active; Vector2 im_position; + Vector2 last_position_before_fs; Size2 min_size; Size2 max_size; diff --git a/platform/x11/pck_embed.ld b/platform/x11/pck_embed.ld index fe09144d88..57a1994043 100644 --- a/platform/x11/pck_embed.ld +++ b/platform/x11/pck_embed.ld @@ -1,9 +1,9 @@ SECTIONS { /* Add a zero-sized section; the exporter will patch it to enclose the data appended to the executable (embedded PCK) */ - pck 0 (NOLOAD) : + pck 0 (INFO) : { - /* Just some content to avoid the linker discarding the section */ + /* binutils >= 2.30 allow it being zero-sized, but needs something between the braces to keep the section */ . = ALIGN(8); } } diff --git a/platform/x11/pck_embed.legacy.ld b/platform/x11/pck_embed.legacy.ld new file mode 100644 index 0000000000..a23013ba7a --- /dev/null +++ b/platform/x11/pck_embed.legacy.ld @@ -0,0 +1,10 @@ +SECTIONS +{ + /* The exporter will patch this section to enclose the data appended to the executable (embedded PCK) */ + pck 0 (INFO) : AT ( ADDR (.rodata) + SIZEOF (.rodata) ) + { + /* binutils < 2.30 need some actual content for the linker not to discard the section */ + BYTE(0); + } +} +INSERT AFTER .rodata; diff --git a/scene/2d/cpu_particles_2d.cpp b/scene/2d/cpu_particles_2d.cpp index 8296f35739..f59e3461b1 100644 --- a/scene/2d/cpu_particles_2d.cpp +++ b/scene/2d/cpu_particles_2d.cpp @@ -294,15 +294,6 @@ float CPUParticles2D::get_spread() const { return spread; } -void CPUParticles2D::set_flatness(float p_flatness) { - - flatness = p_flatness; -} -float CPUParticles2D::get_flatness() const { - - return flatness; -} - void CPUParticles2D::set_param(Parameter p_param, float p_value) { ERR_FAIL_INDEX(p_param, PARAM_MAX); @@ -422,7 +413,7 @@ bool CPUParticles2D::get_particle_flag(Flags p_flag) const { } void CPUParticles2D::set_emission_shape(EmissionShape p_shape) { - + ERR_FAIL_INDEX(p_shape, EMISSION_SHAPE_MAX); emission_shape = p_shape; _change_notify(); } @@ -772,6 +763,9 @@ void CPUParticles2D::_particles_process(float p_delta) { p.base_color = emission_colors.get(random_idx); } } break; + case EMISSION_SHAPE_MAX: { // Max value for validity check. + break; + } } if (!local_coords) { @@ -1166,7 +1160,6 @@ void CPUParticles2D::convert_from_particles(Node *p_particles) { Vector3 dir = material->get_direction(); set_direction(Vector2(dir.x, dir.y)); set_spread(material->get_spread()); - set_flatness(material->get_flatness()); set_color(material->get_color()); @@ -1280,9 +1273,6 @@ void CPUParticles2D::_bind_methods() { ClassDB::bind_method(D_METHOD("set_spread", "degrees"), &CPUParticles2D::set_spread); ClassDB::bind_method(D_METHOD("get_spread"), &CPUParticles2D::get_spread); - ClassDB::bind_method(D_METHOD("set_flatness", "amount"), &CPUParticles2D::set_flatness); - ClassDB::bind_method(D_METHOD("get_flatness"), &CPUParticles2D::get_flatness); - ClassDB::bind_method(D_METHOD("set_param", "param", "value"), &CPUParticles2D::set_param); ClassDB::bind_method(D_METHOD("get_param", "param"), &CPUParticles2D::get_param); @@ -1338,7 +1328,6 @@ void CPUParticles2D::_bind_methods() { ADD_GROUP("Direction", ""); ADD_PROPERTY(PropertyInfo(Variant::VECTOR2, "direction"), "set_direction", "get_direction"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "spread", PROPERTY_HINT_RANGE, "0,180,0.01"), "set_spread", "get_spread"); - ADD_PROPERTY(PropertyInfo(Variant::REAL, "flatness", PROPERTY_HINT_RANGE, "0,1,0.01"), "set_flatness", "get_flatness"); ADD_GROUP("Gravity", ""); ADD_PROPERTY(PropertyInfo(Variant::VECTOR2, "gravity"), "set_gravity", "get_gravity"); ADD_GROUP("Initial Velocity", "initial_"); @@ -1416,6 +1405,7 @@ void CPUParticles2D::_bind_methods() { BIND_ENUM_CONSTANT(EMISSION_SHAPE_RECTANGLE); BIND_ENUM_CONSTANT(EMISSION_SHAPE_POINTS); BIND_ENUM_CONSTANT(EMISSION_SHAPE_DIRECTED_POINTS); + BIND_ENUM_CONSTANT(EMISSION_SHAPE_MAX); } CPUParticles2D::CPUParticles2D() { @@ -1448,7 +1438,6 @@ CPUParticles2D::CPUParticles2D() { set_direction(Vector2(1, 0)); set_spread(45); - set_flatness(0); set_param(PARAM_INITIAL_LINEAR_VELOCITY, 0); set_param(PARAM_ANGULAR_VELOCITY, 0); set_param(PARAM_ORBIT_VELOCITY, 0); diff --git a/scene/2d/cpu_particles_2d.h b/scene/2d/cpu_particles_2d.h index 6ffa1f0e97..085ec99ea0 100644 --- a/scene/2d/cpu_particles_2d.h +++ b/scene/2d/cpu_particles_2d.h @@ -75,6 +75,7 @@ public: EMISSION_SHAPE_RECTANGLE, EMISSION_SHAPE_POINTS, EMISSION_SHAPE_DIRECTED_POINTS, + EMISSION_SHAPE_MAX }; private: @@ -153,7 +154,6 @@ private: Vector2 direction; float spread; - float flatness; float parameters[PARAM_MAX]; float randomness[PARAM_MAX]; @@ -242,9 +242,6 @@ public: void set_spread(float p_spread); float get_spread() const; - void set_flatness(float p_flatness); - float get_flatness() const; - void set_param(Parameter p_param, float p_value); float get_param(Parameter p_param) const; diff --git a/scene/2d/light_2d.cpp b/scene/2d/light_2d.cpp index eb66265010..1bffaf8084 100644 --- a/scene/2d/light_2d.cpp +++ b/scene/2d/light_2d.cpp @@ -189,6 +189,10 @@ float Light2D::get_energy() const { void Light2D::set_texture_scale(float p_scale) { _scale = p_scale; + // Avoid having 0 scale values, can lead to errors in physics and rendering. + if (_scale == 0) { + _scale = CMP_EPSILON; + } VS::get_singleton()->canvas_light_set_scale(canvas_light, _scale); item_rect_changed(); } diff --git a/scene/2d/navigation_polygon.cpp b/scene/2d/navigation_polygon.cpp index ea79f89dd9..883fb37668 100644 --- a/scene/2d/navigation_polygon.cpp +++ b/scene/2d/navigation_polygon.cpp @@ -259,7 +259,7 @@ void NavigationPolygon::make_polygons_from_outlines() { TriangulatorPartition tpart; if (tpart.ConvexPartition_HM(&in_poly, &out_poly) == 0) { //failed! - ERR_PRINTS("NavigationPolygon: Convex partition failed!"); + ERR_PRINT("NavigationPolygon: Convex partition failed!"); return; } diff --git a/scene/2d/node_2d.cpp b/scene/2d/node_2d.cpp index 7bbc7577ed..7deebe9b27 100644 --- a/scene/2d/node_2d.cpp +++ b/scene/2d/node_2d.cpp @@ -173,6 +173,7 @@ void Node2D::set_scale(const Size2 &p_scale) { if (_xform_dirty) ((Node2D *)this)->_update_xform_values(); _scale = p_scale; + // Avoid having 0 scale values, can lead to errors in physics and rendering. if (_scale.x == 0) _scale.x = CMP_EPSILON; if (_scale.y == 0) diff --git a/scene/2d/path_2d.cpp b/scene/2d/path_2d.cpp index e9296b0fe7..ef7c343c1a 100644 --- a/scene/2d/path_2d.cpp +++ b/scene/2d/path_2d.cpp @@ -120,9 +120,15 @@ void Path2D::_notification(int p_what) { } void Path2D::_curve_changed() { + if (!is_inside_tree()) { + return; + } + + if (!Engine::get_singleton()->is_editor_hint() && !get_tree()->is_debugging_navigation_hint()) { + return; + } - if (is_inside_tree() && Engine::get_singleton()->is_editor_hint()) - update(); + update(); } void Path2D::set_curve(const Ref<Curve2D> &p_curve) { @@ -260,7 +266,7 @@ void PathFollow2D::_validate_property(PropertyInfo &property) const { if (path && path->get_curve().is_valid()) max = path->get_curve()->get_baked_length(); - property.hint_string = "0," + rtos(max) + ",0.01,or_lesser"; + property.hint_string = "0," + rtos(max) + ",0.01,or_lesser,or_greater"; } } @@ -302,8 +308,8 @@ void PathFollow2D::_bind_methods() { ClassDB::bind_method(D_METHOD("set_lookahead", "lookahead"), &PathFollow2D::set_lookahead); ClassDB::bind_method(D_METHOD("get_lookahead"), &PathFollow2D::get_lookahead); - ADD_PROPERTY(PropertyInfo(Variant::REAL, "offset", PROPERTY_HINT_RANGE, "0,10000,0.01,or_lesser"), "set_offset", "get_offset"); - ADD_PROPERTY(PropertyInfo(Variant::REAL, "unit_offset", PROPERTY_HINT_RANGE, "0,1,0.0001,or_lesser", PROPERTY_USAGE_EDITOR), "set_unit_offset", "get_unit_offset"); + ADD_PROPERTY(PropertyInfo(Variant::REAL, "offset", PROPERTY_HINT_RANGE, "0,10000,0.01,or_lesser,or_greater"), "set_offset", "get_offset"); + ADD_PROPERTY(PropertyInfo(Variant::REAL, "unit_offset", PROPERTY_HINT_RANGE, "0,1,0.0001,or_lesser,or_greater", PROPERTY_USAGE_EDITOR), "set_unit_offset", "get_unit_offset"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "h_offset"), "set_h_offset", "get_h_offset"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "v_offset"), "set_v_offset", "get_v_offset"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "rotate"), "set_rotate", "is_rotating"); diff --git a/scene/2d/physics_body_2d.cpp b/scene/2d/physics_body_2d.cpp index 90663bd675..d42bd6adaf 100644 --- a/scene/2d/physics_body_2d.cpp +++ b/scene/2d/physics_body_2d.cpp @@ -1234,7 +1234,7 @@ Vector2 KinematicBody2D::move_and_slide(const Vector2 &p_linear_velocity, const on_ceiling = false; on_wall = false; colliders.clear(); - floor_normal = p_up_direction; + floor_normal = Vector2(); floor_velocity = Vector2(); while (p_max_slides) { @@ -1473,8 +1473,8 @@ void KinematicBody2D::_notification(int p_what) { void KinematicBody2D::_bind_methods() { ClassDB::bind_method(D_METHOD("move_and_collide", "rel_vec", "infinite_inertia", "exclude_raycast_shapes", "test_only"), &KinematicBody2D::_move, DEFVAL(true), DEFVAL(true), DEFVAL(false)); - ClassDB::bind_method(D_METHOD("move_and_slide", "linear_velocity", "floor_normal", "stop_on_slope", "max_slides", "floor_max_angle", "infinite_inertia"), &KinematicBody2D::move_and_slide, DEFVAL(Vector2(0, 0)), DEFVAL(false), DEFVAL(4), DEFVAL(Math::deg2rad((float)45)), DEFVAL(true)); - ClassDB::bind_method(D_METHOD("move_and_slide_with_snap", "linear_velocity", "snap", "floor_normal", "stop_on_slope", "max_slides", "floor_max_angle", "infinite_inertia"), &KinematicBody2D::move_and_slide_with_snap, DEFVAL(Vector2(0, 0)), DEFVAL(false), DEFVAL(4), DEFVAL(Math::deg2rad((float)45)), DEFVAL(true)); + ClassDB::bind_method(D_METHOD("move_and_slide", "linear_velocity", "up_direction", "stop_on_slope", "max_slides", "floor_max_angle", "infinite_inertia"), &KinematicBody2D::move_and_slide, DEFVAL(Vector2(0, 0)), DEFVAL(false), DEFVAL(4), DEFVAL(Math::deg2rad((float)45)), DEFVAL(true)); + ClassDB::bind_method(D_METHOD("move_and_slide_with_snap", "linear_velocity", "snap", "up_direction", "stop_on_slope", "max_slides", "floor_max_angle", "infinite_inertia"), &KinematicBody2D::move_and_slide_with_snap, DEFVAL(Vector2(0, 0)), DEFVAL(false), DEFVAL(4), DEFVAL(Math::deg2rad((float)45)), DEFVAL(true)); ClassDB::bind_method(D_METHOD("test_move", "from", "rel_vec", "infinite_inertia"), &KinematicBody2D::test_move, DEFVAL(true)); diff --git a/scene/2d/polygon_2d.cpp b/scene/2d/polygon_2d.cpp index c480423eca..a6da027e0a 100644 --- a/scene/2d/polygon_2d.cpp +++ b/scene/2d/polygon_2d.cpp @@ -346,195 +346,6 @@ void Polygon2D::_notification(int p_what) { if (total_indices.size()) { VS::get_singleton()->canvas_item_add_triangle_array(get_canvas_item(), total_indices, points, colors, uvs, bones, weights, texture.is_valid() ? texture->get_rid() : RID(), -1, RID(), antialiased); } - -#if 0 - //use splits - Vector<int> loop; - int sc = splits.size(); - PoolVector<int>::Read r = splits.read(); - - - print_line("has splits, amount " + itos(splits.size())); - Vector<Vector<int> > loops; - - // find a point that can be used to begin, must not be in a split, and have to the left and right the same one - // like this one -> x---o - // \ / \ . - // o---o - int base_point = -1; - { - int current_point = -1; - int base_point_prev_split = -1; - - - for (int i = 0; i < points.size(); i++) { - - //find if this point is in a split - int split_index = -1; - bool has_prev_split = false; - int min_dist_to_end = 0x7FFFFFFF; - - for (int j = 0; j < sc; j += 2) { - - int split_pos = -1; - int split_end = -1; - - if (r[j + 0] == i) { //found split in first point - split_pos = r[j + 0]; - split_end = r[j + 1]; - } else if (r[j + 1] == i) { //found split in second point - split_pos = r[j + 1]; - split_end = r[j + 0]; - } - - if (split_pos == split_end) { - continue; //either nothing found or begin == end, this not a split in either case - } - - if (j == base_point_prev_split) { - has_prev_split = true; - } - - //compute distance from split pos to split end in current traversal direction - int dist_to_end = split_end > split_pos ? split_end - split_pos : (last - split_pos + split_end); - - if (dist_to_end < min_dist_to_end) { - //always keep the valid split with the least distance to the loop - min_dist_to_end = dist_to_end; - split_index = j; - } - } - - if (split_index == -1) { - current_point = i; //no split here, we are testing this point - } else if (has_prev_split) { - base_point = current_point; // there is a split and it contains the previous visited split, success - break; - } else { - //invalidate current point and keep split - current_point = -1; - base_point_prev_split = split_index; - } - } - } - - print_line("found base point: " + itos(base_point)); - - if (base_point != -1) { - - int point = base_point; - int last = base_point; - //go through all the points, find splits - do { - - int split; - int last_dist_to_end = -1; //maximum valid distance to end - - do { - - loop.push_back(point); //push current point - - split = -1; - int end = -1; - - int max_dist_to_end = 0; - - //find if this point is in a split - for (int j = 0; j < sc; j += 2) { - - int split_pos = -1; - int split_end = -1; - - if (r[j + 0] == point) { //match first split index - split_pos = r[j + 0]; - split_end = r[j + 1]; - } else if (r[j + 1] == point) { //match second split index - split_pos = r[j + 1]; - split_end = r[j + 0]; - } - - if (split_pos == split_end) { - continue; //either nothing found or begin == end, this not a split in either case - } - - //compute distance from split pos to split end - int dist_to_end = split_end > split_pos ? split_end - split_pos : (points.size() - split_pos + split_end); - - if (last_dist_to_end != -1 && dist_to_end >= last_dist_to_end) { - //distance must be shorter than in last iteration, means we've tested this before so ignore - continue; - } else if (dist_to_end > max_dist_to_end) { - //always keep the valid point with the most distance (as long as it's valid) - max_dist_to_end = dist_to_end; - split = split_pos; - end = split_end; - } - } - - if (split != -1) { - //found a split! - int from = end; - - //add points until last is reached - while (true) { - //find if point is in a split - loop.push_back(from); - - if (from == last) { - break; - } - - from++; - if (from >= points.size()) { //wrap if reached end - from = 0; - } - - if (from == loop[0]) { - break; //end because we reached split source - } - } - - loops.push_back(loop); //done with this loop - loop.clear(); - - last_dist_to_end = max_dist_to_end; - last = end; //algorithm can safely finish in this split point - } - - } while (split != -1); - - } while (point != last); - } - - if (loop.size() >=2 ) { //points remained - //points remain - loop.push_back(last); //no splits found, use last - loops.push_back(loop); - } - - print_line("total loops: " + itos(loops.size())); - - if (loops.size()) { //loops found - Vector<int> indices; - - for (int i = 0; i < loops.size(); i++) { - Vector<int> loop = loops[i]; - Vector<Vector2> vertices; - vertices.resize(loop.size()); - for (int j = 0; j < vertices.size(); j++) { - vertices.write[j] = points[loop[j]]; - } - Vector<int> sub_indices = Geometry::triangulate_polygon(vertices); - int from = indices.size(); - indices.resize(from + sub_indices.size()); - for (int j = 0; j < sub_indices.size(); j++) { - indices.write[from + j] = loop[sub_indices[j]]; - } - } - - VS::get_singleton()->canvas_item_add_triangle_array(get_canvas_item(), indices, points, colors, uvs, bones, weights, texture.is_valid() ? texture->get_rid() : RID()); - } -#endif } } break; diff --git a/scene/3d/arvr_nodes.cpp b/scene/3d/arvr_nodes.cpp index 82293268b9..8d1556ef1c 100644 --- a/scene/3d/arvr_nodes.cpp +++ b/scene/3d/arvr_nodes.cpp @@ -85,9 +85,8 @@ Vector3 ARVRCamera::project_local_ray_normal(const Point2 &p_pos) const { Vector3 ray; CameraMatrix cm = arvr_interface->get_projection_for_eye(ARVRInterface::EYE_MONO, viewport_size.aspect(), get_znear(), get_zfar()); - float screen_w, screen_h; - cm.get_viewport_size(screen_w, screen_h); - ray = Vector3(((cpos.x / viewport_size.width) * 2.0 - 1.0) * screen_w, ((1.0 - (cpos.y / viewport_size.height)) * 2.0 - 1.0) * screen_h, -get_znear()).normalized(); + Vector2 screen_he = cm.get_viewport_half_extents(); + ray = Vector3(((cpos.x / viewport_size.width) * 2.0 - 1.0) * screen_he.x, ((1.0 - (cpos.y / viewport_size.height)) * 2.0 - 1.0) * screen_he.y, -get_znear()).normalized(); return ray; }; @@ -138,13 +137,12 @@ Vector3 ARVRCamera::project_position(const Point2 &p_point, float p_z_depth) con CameraMatrix cm = arvr_interface->get_projection_for_eye(ARVRInterface::EYE_MONO, viewport_size.aspect(), get_znear(), get_zfar()); - Size2 vp_size; - cm.get_viewport_size(vp_size.x, vp_size.y); + Vector2 vp_he = cm.get_viewport_half_extents(); Vector2 point; point.x = (p_point.x / viewport_size.x) * 2.0 - 1.0; point.y = (1.0 - (p_point.y / viewport_size.y)) * 2.0 - 1.0; - point *= vp_size; + point *= vp_he; Vector3 p(point.x, point.y, -p_z_depth); @@ -295,7 +293,8 @@ int ARVRController::get_joystick_id() const { ARVRPositionalTracker *tracker = arvr_server->find_by_type_and_id(ARVRServer::TRACKER_CONTROLLER, controller_id); if (tracker == NULL) { - return 0; + // No tracker? no joystick id... (0 is our first joystick) + return -1; }; return tracker->get_joy_id(); diff --git a/scene/3d/baked_lightmap.cpp b/scene/3d/baked_lightmap.cpp index 2234304e79..071afd1a69 100644 --- a/scene/3d/baked_lightmap.cpp +++ b/scene/3d/baked_lightmap.cpp @@ -360,7 +360,7 @@ BakedLightmap::BakeError BakedLightmap::bake(Node *p_from_node, bool p_create_vi //check for valid save path DirAccessRef d = DirAccess::open(save_path); if (!d) { - ERR_PRINTS("Invalid Save Path '" + save_path + "'."); + ERR_PRINT("Invalid Save Path '" + save_path + "'."); return BAKE_ERROR_NO_SAVE_PATH; } } diff --git a/scene/3d/camera.cpp b/scene/3d/camera.cpp index 3a30755f7f..640189a26e 100644 --- a/scene/3d/camera.cpp +++ b/scene/3d/camera.cpp @@ -291,9 +291,8 @@ Vector3 Camera::project_local_ray_normal(const Point2 &p_pos) const { } else { CameraMatrix cm; cm.set_perspective(fov, viewport_size.aspect(), near, far, keep_aspect == KEEP_WIDTH); - float screen_w, screen_h; - cm.get_viewport_size(screen_w, screen_h); - ray = Vector3(((cpos.x / viewport_size.width) * 2.0 - 1.0) * screen_w, ((1.0 - (cpos.y / viewport_size.height)) * 2.0 - 1.0) * screen_h, -near).normalized(); + Vector2 screen_he = cm.get_viewport_half_extents(); + ray = Vector3(((cpos.x / viewport_size.width) * 2.0 - 1.0) * screen_he.x, ((1.0 - (cpos.y / viewport_size.height)) * 2.0 - 1.0) * screen_he.y, -near).normalized(); } return ray; @@ -402,13 +401,12 @@ Vector3 Camera::project_position(const Point2 &p_point, float p_z_depth) const { else cm.set_perspective(fov, viewport_size.aspect(), p_z_depth, far, keep_aspect == KEEP_WIDTH); - Size2 vp_size; - cm.get_viewport_size(vp_size.x, vp_size.y); + Vector2 vp_he = cm.get_viewport_half_extents(); Vector2 point; point.x = (p_point.x / viewport_size.x) * 2.0 - 1.0; point.y = (1.0 - (p_point.y / viewport_size.y)) * 2.0 - 1.0; - point *= vp_size; + point *= vp_he; Vector3 p(point.x, point.y, -p_z_depth); diff --git a/scene/3d/cpu_particles.cpp b/scene/3d/cpu_particles.cpp index 0ac424b09e..aa7a413548 100644 --- a/scene/3d/cpu_particles.cpp +++ b/scene/3d/cpu_particles.cpp @@ -405,7 +405,7 @@ bool CPUParticles::get_particle_flag(Flags p_flag) const { } void CPUParticles::set_emission_shape(EmissionShape p_shape) { - + ERR_FAIL_INDEX(p_shape, EMISSION_SHAPE_MAX); emission_shape = p_shape; } @@ -784,6 +784,9 @@ void CPUParticles::_particles_process(float p_delta) { p.base_color = emission_colors.get(random_idx); } } break; + case EMISSION_SHAPE_MAX: { // Max value for validity check. + break; + } } if (!local_coords) { @@ -1488,6 +1491,7 @@ void CPUParticles::_bind_methods() { BIND_ENUM_CONSTANT(EMISSION_SHAPE_BOX); BIND_ENUM_CONSTANT(EMISSION_SHAPE_POINTS); BIND_ENUM_CONSTANT(EMISSION_SHAPE_DIRECTED_POINTS); + BIND_ENUM_CONSTANT(EMISSION_SHAPE_MAX); } CPUParticles::CPUParticles() { diff --git a/scene/3d/cpu_particles.h b/scene/3d/cpu_particles.h index 18f9718e70..d5a549b976 100644 --- a/scene/3d/cpu_particles.h +++ b/scene/3d/cpu_particles.h @@ -75,6 +75,7 @@ public: EMISSION_SHAPE_BOX, EMISSION_SHAPE_POINTS, EMISSION_SHAPE_DIRECTED_POINTS, + EMISSION_SHAPE_MAX }; private: diff --git a/scene/3d/path.cpp b/scene/3d/path.cpp index 3ed0677480..ac012de1ab 100644 --- a/scene/3d/path.cpp +++ b/scene/3d/path.cpp @@ -253,7 +253,7 @@ void PathFollow::_validate_property(PropertyInfo &property) const { if (path && path->get_curve().is_valid()) max = path->get_curve()->get_baked_length(); - property.hint_string = "0," + rtos(max) + ",0.01,or_lesser"; + property.hint_string = "0," + rtos(max) + ",0.01,or_lesser,or_greater"; } } @@ -297,8 +297,8 @@ void PathFollow::_bind_methods() { ClassDB::bind_method(D_METHOD("set_loop", "loop"), &PathFollow::set_loop); ClassDB::bind_method(D_METHOD("has_loop"), &PathFollow::has_loop); - ADD_PROPERTY(PropertyInfo(Variant::REAL, "offset", PROPERTY_HINT_RANGE, "0,10000,0.01,or_lesser"), "set_offset", "get_offset"); - ADD_PROPERTY(PropertyInfo(Variant::REAL, "unit_offset", PROPERTY_HINT_RANGE, "0,1,0.0001,or_lesser", PROPERTY_USAGE_EDITOR), "set_unit_offset", "get_unit_offset"); + ADD_PROPERTY(PropertyInfo(Variant::REAL, "offset", PROPERTY_HINT_RANGE, "0,10000,0.01,or_lesser,or_greater"), "set_offset", "get_offset"); + ADD_PROPERTY(PropertyInfo(Variant::REAL, "unit_offset", PROPERTY_HINT_RANGE, "0,1,0.0001,or_lesser,or_greater", PROPERTY_USAGE_EDITOR), "set_unit_offset", "get_unit_offset"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "h_offset"), "set_h_offset", "get_h_offset"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "v_offset"), "set_v_offset", "get_v_offset"); ADD_PROPERTY(PropertyInfo(Variant::INT, "rotation_mode", PROPERTY_HINT_ENUM, "None,Y,XY,XYZ,Oriented"), "set_rotation_mode", "get_rotation_mode"); diff --git a/scene/3d/physics_body.cpp b/scene/3d/physics_body.cpp index 999f39c841..caeae90238 100644 --- a/scene/3d/physics_body.cpp +++ b/scene/3d/physics_body.cpp @@ -1159,7 +1159,7 @@ Vector3 KinematicBody::move_and_slide(const Vector3 &p_linear_velocity, const Ve on_ceiling = false; on_wall = false; colliders.clear(); - floor_normal = p_up_direction; + floor_normal = Vector3(); floor_velocity = Vector3(); while (p_max_slides) { @@ -1401,7 +1401,7 @@ void KinematicBody::_bind_methods() { ClassDB::bind_method(D_METHOD("move_and_collide", "rel_vec", "infinite_inertia", "exclude_raycast_shapes", "test_only"), &KinematicBody::_move, DEFVAL(true), DEFVAL(true), DEFVAL(false)); ClassDB::bind_method(D_METHOD("move_and_slide", "linear_velocity", "up_direction", "stop_on_slope", "max_slides", "floor_max_angle", "infinite_inertia"), &KinematicBody::move_and_slide, DEFVAL(Vector3(0, 0, 0)), DEFVAL(false), DEFVAL(4), DEFVAL(Math::deg2rad((float)45)), DEFVAL(true)); - ClassDB::bind_method(D_METHOD("move_and_slide_with_snap", "linear_velocity", "snap", "floor_normal", "stop_on_slope", "max_slides", "floor_max_angle", "infinite_inertia"), &KinematicBody::move_and_slide_with_snap, DEFVAL(Vector3(0, 0, 0)), DEFVAL(false), DEFVAL(4), DEFVAL(Math::deg2rad((float)45)), DEFVAL(true)); + ClassDB::bind_method(D_METHOD("move_and_slide_with_snap", "linear_velocity", "snap", "up_direction", "stop_on_slope", "max_slides", "floor_max_angle", "infinite_inertia"), &KinematicBody::move_and_slide_with_snap, DEFVAL(Vector3(0, 0, 0)), DEFVAL(false), DEFVAL(4), DEFVAL(Math::deg2rad((float)45)), DEFVAL(true)); ClassDB::bind_method(D_METHOD("test_move", "from", "rel_vec", "infinite_inertia"), &KinematicBody::test_move, DEFVAL(true)); diff --git a/scene/3d/portal.cpp b/scene/3d/portal.cpp deleted file mode 100644 index e60ca619dd..0000000000 --- a/scene/3d/portal.cpp +++ /dev/null @@ -1,232 +0,0 @@ -/*************************************************************************/ -/* portal.cpp */ -/*************************************************************************/ -/* This file is part of: */ -/* GODOT ENGINE */ -/* https://godotengine.org */ -/*************************************************************************/ -/* Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. */ -/* Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). */ -/* */ -/* Permission is hereby granted, free of charge, to any person obtaining */ -/* a copy of this software and associated documentation files (the */ -/* "Software"), to deal in the Software without restriction, including */ -/* without limitation the rights to use, copy, modify, merge, publish, */ -/* distribute, sublicense, and/or sell copies of the Software, and to */ -/* permit persons to whom the Software is furnished to do so, subject to */ -/* the following conditions: */ -/* */ -/* The above copyright notice and this permission notice shall be */ -/* included in all copies or substantial portions of the Software. */ -/* */ -/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ -/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ -/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ -/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ -/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ -/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ -/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -/*************************************************************************/ - -#include "portal.h" -#include "core/project_settings.h" -#include "scene/resources/surface_tool.h" -#include "servers/visual_server.h" - -// FIXME: This will be removed, kept as reference for new implementation -#if 0 -bool Portal::_set(const StringName &p_name, const Variant &p_value) { - - if (p_name == "shape") { - PoolVector<float> src_coords = p_value; - Vector<Point2> points; - int src_coords_size = src_coords.size(); - ERR_FAIL_COND_V(src_coords_size % 2, false); - points.resize(src_coords_size / 2); - for (int i = 0; i < points.size(); i++) { - - points[i].x = src_coords[i * 2 + 0]; - points[i].y = src_coords[i * 2 + 1]; - set_shape(points); - } - } else if (p_name == "enabled") { - set_enabled(p_value); - } else if (p_name == "disable_distance") { - set_disable_distance(p_value); - } else if (p_name == "disabled_color") { - set_disabled_color(p_value); - } else if (p_name == "connect_range") { - set_connect_range(p_value); - } else - return false; - - return true; -} - -bool Portal::_get(const StringName &p_name, Variant &r_ret) const { - - if (p_name == "shape") { - Vector<Point2> points = get_shape(); - PoolVector<float> dst_coords; - dst_coords.resize(points.size() * 2); - - for (int i = 0; i < points.size(); i++) { - - dst_coords.set(i * 2 + 0, points[i].x); - dst_coords.set(i * 2 + 1, points[i].y); - } - - r_ret = dst_coords; - } else if (p_name == "enabled") { - r_ret = is_enabled(); - } else if (p_name == "disable_distance") { - r_ret = get_disable_distance(); - } else if (p_name == "disabled_color") { - r_ret = get_disabled_color(); - } else if (p_name == "connect_range") { - r_ret = get_connect_range(); - } else - return false; - return true; -} - -void Portal::_get_property_list(List<PropertyInfo> *p_list) const { - - p_list->push_back(PropertyInfo(Variant::POOL_REAL_ARRAY, "shape")); - p_list->push_back(PropertyInfo(Variant::BOOL, "enabled")); - p_list->push_back(PropertyInfo(Variant::REAL, "disable_distance", PROPERTY_HINT_RANGE, "0,4096,0.01")); - p_list->push_back(PropertyInfo(Variant::COLOR, "disabled_color")); - p_list->push_back(PropertyInfo(Variant::REAL, "connect_range", PROPERTY_HINT_RANGE, "0.1,4096,0.01")); -} - -AABB Portal::get_aabb() const { - - return aabb; -} -PoolVector<Face3> Portal::get_faces(uint32_t p_usage_flags) const { - - if (!(p_usage_flags & FACES_ENCLOSING)) - return PoolVector<Face3>(); - - Vector<Point2> shape = get_shape(); - if (shape.size() == 0) - return PoolVector<Face3>(); - - Vector2 center; - for (int i = 0; i < shape.size(); i++) { - - center += shape[i]; - } - - PoolVector<Face3> ret; - center /= shape.size(); - - for (int i = 0; i < shape.size(); i++) { - - int n = (i + 1) % shape.size(); - - Face3 f; - f.vertex[0] = Vector3(center.x, center.y, 0); - f.vertex[1] = Vector3(shape[i].x, shape[i].y, 0); - f.vertex[2] = Vector3(shape[n].x, shape[n].y, 0); - ret.push_back(f); - } - - return ret; -} - -void Portal::set_shape(const Vector<Point2> &p_shape) { - - VisualServer::get_singleton()->portal_set_shape(portal, p_shape); - shape = p_shape; - update_gizmo(); -} - -Vector<Point2> Portal::get_shape() const { - - return shape; -} - -void Portal::set_connect_range(float p_range) { - - connect_range = p_range; - //VisualServer::get_singleton()->portal_set_connect_range(portal,p_range); -} - -float Portal::get_connect_range() const { - - return connect_range; -} - -void Portal::set_enabled(bool p_enabled) { - - enabled = p_enabled; - VisualServer::get_singleton()->portal_set_enabled(portal, enabled); -} - -bool Portal::is_enabled() const { - - return enabled; -} - -void Portal::set_disable_distance(float p_distance) { - - disable_distance = p_distance; - VisualServer::get_singleton()->portal_set_disable_distance(portal, disable_distance); -} -float Portal::get_disable_distance() const { - - return disable_distance; -} - -void Portal::set_disabled_color(const Color &p_disabled_color) { - - disabled_color = p_disabled_color; - VisualServer::get_singleton()->portal_set_disabled_color(portal, disabled_color); -} - -Color Portal::get_disabled_color() const { - - return disabled_color; -} - -void Portal::_bind_methods() { - - ClassDB::bind_method(D_METHOD("set_shape", "points"), &Portal::set_shape); - ClassDB::bind_method(D_METHOD("get_shape"), &Portal::get_shape); - - ClassDB::bind_method(D_METHOD("set_enabled", "enable"), &Portal::set_enabled); - ClassDB::bind_method(D_METHOD("is_enabled"), &Portal::is_enabled); - - ClassDB::bind_method(D_METHOD("set_disable_distance", "distance"), &Portal::set_disable_distance); - ClassDB::bind_method(D_METHOD("get_disable_distance"), &Portal::get_disable_distance); - - ClassDB::bind_method(D_METHOD("set_disabled_color", "color"), &Portal::set_disabled_color); - ClassDB::bind_method(D_METHOD("get_disabled_color"), &Portal::get_disabled_color); - - ClassDB::bind_method(D_METHOD("set_connect_range", "range"), &Portal::set_connect_range); - ClassDB::bind_method(D_METHOD("get_connect_range"), &Portal::get_connect_range); -} - -Portal::Portal() { - - portal = VisualServer::get_singleton()->portal_create(); - Vector<Point2> points; - points.push_back(Point2(-1, 1)); - points.push_back(Point2(1, 1)); - points.push_back(Point2(1, -1)); - points.push_back(Point2(-1, -1)); - set_shape(points); // default shape - - set_connect_range(0.8); - set_disable_distance(50); - set_enabled(true); - - set_base(portal); -} - -Portal::~Portal() { - - VisualServer::get_singleton()->free(portal); -} -#endif diff --git a/scene/3d/portal.h b/scene/3d/portal.h deleted file mode 100644 index 7e8b016e79..0000000000 --- a/scene/3d/portal.h +++ /dev/null @@ -1,88 +0,0 @@ -/*************************************************************************/ -/* portal.h */ -/*************************************************************************/ -/* This file is part of: */ -/* GODOT ENGINE */ -/* https://godotengine.org */ -/*************************************************************************/ -/* Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. */ -/* Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). */ -/* */ -/* Permission is hereby granted, free of charge, to any person obtaining */ -/* a copy of this software and associated documentation files (the */ -/* "Software"), to deal in the Software without restriction, including */ -/* without limitation the rights to use, copy, modify, merge, publish, */ -/* distribute, sublicense, and/or sell copies of the Software, and to */ -/* permit persons to whom the Software is furnished to do so, subject to */ -/* the following conditions: */ -/* */ -/* The above copyright notice and this permission notice shall be */ -/* included in all copies or substantial portions of the Software. */ -/* */ -/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ -/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ -/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ -/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ -/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ -/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ -/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -/*************************************************************************/ - -#ifndef PORTAL_H -#define PORTAL_H - -#include "scene/3d/visual_instance.h" - -/* Portal Logic: - If a portal is placed next (very close to) a similar, opposing portal, they automatically connect, - otherwise, a portal connects to the parent room -*/ -// FIXME: This will be redone and replaced by area portals, left for reference -// since a new class with this name will have to exist and want to reuse the gizmos -#if 0 -class Portal : public VisualInstance { - - GDCLASS(Portal, VisualInstance); - - RID portal; - Vector<Point2> shape; - - bool enabled; - float disable_distance; - Color disabled_color; - float connect_range; - - AABB aabb; - -protected: - bool _set(const StringName &p_name, const Variant &p_value); - bool _get(const StringName &p_name, Variant &r_ret) const; - void _get_property_list(List<PropertyInfo> *p_list) const; - - static void _bind_methods(); - -public: - virtual AABB get_aabb() const; - virtual PoolVector<Face3> get_faces(uint32_t p_usage_flags) const; - - void set_enabled(bool p_enabled); - bool is_enabled() const; - - void set_disable_distance(float p_distance); - float get_disable_distance() const; - - void set_disabled_color(const Color &p_disabled_color); - Color get_disabled_color() const; - - void set_shape(const Vector<Point2> &p_shape); - Vector<Point2> get_shape() const; - - void set_connect_range(float p_range); - float get_connect_range() const; - - Portal(); - ~Portal(); -}; - -#endif -#endif diff --git a/scene/3d/room_instance.cpp b/scene/3d/room_instance.cpp deleted file mode 100644 index 61687360a6..0000000000 --- a/scene/3d/room_instance.cpp +++ /dev/null @@ -1,164 +0,0 @@ -/*************************************************************************/ -/* room_instance.cpp */ -/*************************************************************************/ -/* This file is part of: */ -/* GODOT ENGINE */ -/* https://godotengine.org */ -/*************************************************************************/ -/* Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. */ -/* Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). */ -/* */ -/* Permission is hereby granted, free of charge, to any person obtaining */ -/* a copy of this software and associated documentation files (the */ -/* "Software"), to deal in the Software without restriction, including */ -/* without limitation the rights to use, copy, modify, merge, publish, */ -/* distribute, sublicense, and/or sell copies of the Software, and to */ -/* permit persons to whom the Software is furnished to do so, subject to */ -/* the following conditions: */ -/* */ -/* The above copyright notice and this permission notice shall be */ -/* included in all copies or substantial portions of the Software. */ -/* */ -/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ -/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ -/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ -/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ -/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ -/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ -/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -/*************************************************************************/ - -#include "room_instance.h" - -#include "servers/visual_server.h" - -// FIXME: Will be removed, kept as reference for new implementation -#if 0 -#include "core/math/geometry.h" -#include "core/project_settings.h" -#include "scene/resources/surface_tool.h" - -void Room::_notification(int p_what) { - - switch (p_what) { - case NOTIFICATION_ENTER_WORLD: { - // go find parent level - Node *parent_room = get_parent(); - level = 0; - - while (parent_room) { - - Room *r = Object::cast_to<Room>(parent_room); - if (r) { - - level = r->level + 1; - break; - } - - parent_room = parent_room->get_parent(); - } - - } break; - case NOTIFICATION_TRANSFORM_CHANGED: { - } break; - case NOTIFICATION_EXIT_WORLD: { - - } break; - } -} - -AABB Room::get_aabb() const { - - if (room.is_null()) - return AABB(); - - return AABB(); -} - -PoolVector<Face3> Room::get_faces(uint32_t p_usage_flags) const { - - return PoolVector<Face3>(); -} - -void Room::set_room(const Ref<RoomBounds> &p_room) { - - room = p_room; - update_gizmo(); - - if (room.is_valid()) { - - set_base(room->get_rid()); - } else { - set_base(RID()); - } - - if (!is_inside_tree()) - return; - - propagate_notification(NOTIFICATION_AREA_CHANGED); - update_gizmo(); -} - -Ref<RoomBounds> Room::get_room() const { - - return room; -} - -void Room::_parse_node_faces(PoolVector<Face3> &all_faces, const Node *p_node) const { - - const VisualInstance *vi = Object::cast_to<VisualInstance>(p_node); - - if (vi) { - PoolVector<Face3> faces = vi->get_faces(FACES_ENCLOSING); - - if (faces.size()) { - int old_len = all_faces.size(); - all_faces.resize(all_faces.size() + faces.size()); - int new_len = all_faces.size(); - PoolVector<Face3>::Write all_facesw = all_faces.write(); - Face3 *all_facesptr = all_facesw.ptr(); - - PoolVector<Face3>::Read facesr = faces.read(); - const Face3 *facesptr = facesr.ptr(); - - Transform tr = vi->get_relative_transform(this); - - for (int i = old_len; i < new_len; i++) { - - Face3 f = facesptr[i - old_len]; - for (int j = 0; j < 3; j++) - f.vertex[j] = tr.xform(f.vertex[j]); - all_facesptr[i] = f; - } - } - } - - for (int i = 0; i < p_node->get_child_count(); i++) { - - _parse_node_faces(all_faces, p_node->get_child(i)); - } -} - -void Room::_bounds_changed() { - - update_gizmo(); -} - -void Room::_bind_methods() { - - ClassDB::bind_method(D_METHOD("set_room", "room"), &Room::set_room); - ClassDB::bind_method(D_METHOD("get_room"), &Room::get_room); - - ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "room/room", PROPERTY_HINT_RESOURCE_TYPE, "Area"), "set_room", "get_room"); -} - -Room::Room() { - - // sound_enabled=false; - - level = 0; -} - -Room::~Room() { -} -#endif diff --git a/scene/3d/room_instance.h b/scene/3d/room_instance.h deleted file mode 100644 index 071d42cff2..0000000000 --- a/scene/3d/room_instance.h +++ /dev/null @@ -1,81 +0,0 @@ -/*************************************************************************/ -/* room_instance.h */ -/*************************************************************************/ -/* This file is part of: */ -/* GODOT ENGINE */ -/* https://godotengine.org */ -/*************************************************************************/ -/* Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. */ -/* Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). */ -/* */ -/* Permission is hereby granted, free of charge, to any person obtaining */ -/* a copy of this software and associated documentation files (the */ -/* "Software"), to deal in the Software without restriction, including */ -/* without limitation the rights to use, copy, modify, merge, publish, */ -/* distribute, sublicense, and/or sell copies of the Software, and to */ -/* permit persons to whom the Software is furnished to do so, subject to */ -/* the following conditions: */ -/* */ -/* The above copyright notice and this permission notice shall be */ -/* included in all copies or substantial portions of the Software. */ -/* */ -/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ -/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ -/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ -/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ -/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ -/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ -/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -/*************************************************************************/ - -#ifndef ROOM_INSTANCE_H -#define ROOM_INSTANCE_H - -#include "scene/3d/visual_instance.h" -#include "scene/resources/room.h" - -/* RoomInstance Logic: - a) Instances that belong to the room are drawn only if the room is visible (seen through portal, or player inside) - b) Instances that don't belong to any room are considered to belong to the root room (RID empty) - c) "dynamic" Instances are assigned to the rooms their AABB touch - -*/ - -// FIXME: this will be removed, left for reference -#if 0 - -class Room : public VisualInstance { - - GDCLASS(Room, VisualInstance); - -public: -private: - Ref<RoomBounds> room; - - int level; - void _parse_node_faces(PoolVector<Face3> &all_faces, const Node *p_node) const; - - void _bounds_changed(); - -protected: - void _notification(int p_what); - - static void _bind_methods(); - -public: - enum { - // used to notify portals that the room in which they are has changed. - NOTIFICATION_AREA_CHANGED = 60 - }; - - virtual AABB get_aabb() const; - virtual PoolVector<Face3> get_faces(uint32_t p_usage_flags) const; - - void set_room(const Ref<RoomBounds> &p_room); - Ref<RoomBounds> get_room() const; - - Room(); - ~Room(); -}; -#endif -#endif // ROOM_INSTANCE_H diff --git a/scene/3d/skeleton.cpp b/scene/3d/skeleton.cpp index 5edce284b5..17e67c47d1 100644 --- a/scene/3d/skeleton.cpp +++ b/scene/3d/skeleton.cpp @@ -181,7 +181,7 @@ void Skeleton::_update_process_order() { if (bonesptr[i].parent >= len) { //validate this just in case - ERR_PRINTS("Bone " + itos(i) + " has invalid parent: " + itos(bonesptr[i].parent)); + ERR_PRINT("Bone " + itos(i) + " has invalid parent: " + itos(bonesptr[i].parent)); bonesptr[i].parent = -1; } order[i] = i; diff --git a/scene/3d/spatial.cpp b/scene/3d/spatial.cpp index b7cd2114db..f1911348ce 100644 --- a/scene/3d/spatial.cpp +++ b/scene/3d/spatial.cpp @@ -125,6 +125,7 @@ void Spatial::_notification(int p_what) { switch (p_what) { case NOTIFICATION_ENTER_TREE: { + ERR_FAIL_COND(!get_tree()); Node *p = get_parent(); if (p) diff --git a/scene/3d/voxel_light_baker.cpp b/scene/3d/voxel_light_baker.cpp index 9970b9350f..c1ec59d49f 100644 --- a/scene/3d/voxel_light_baker.cpp +++ b/scene/3d/voxel_light_baker.cpp @@ -29,6 +29,7 @@ /*************************************************************************/ #include "voxel_light_baker.h" + #include "core/os/os.h" #include "core/os/threaded_array_processor.h" @@ -2118,8 +2119,7 @@ Error VoxelLightBaker::make_lightmap(const Transform &p_xform, Ref<Mesh> &p_mesh } } -// Enable for debugging -#if 0 +#if 0 // Enable for debugging. { PoolVector<uint8_t> img; int ls = lightmap.size(); diff --git a/scene/animation/animation_blend_tree.cpp b/scene/animation/animation_blend_tree.cpp index a604fb9604..5c284cb483 100644 --- a/scene/animation/animation_blend_tree.cpp +++ b/scene/animation/animation_blend_tree.cpp @@ -29,6 +29,7 @@ /*************************************************************************/ #include "animation_blend_tree.h" + #include "scene/scene_string_names.h" void AnimationNodeAnimation::set_animation(const StringName &p_name) { @@ -718,21 +719,6 @@ String AnimationNodeTransition::get_input_caption(int p_input) const { return inputs[p_input].name; } -#if 0 - Ref<AnimationNodeBlendTree> tree = get_parent(); - - if (tree.is_valid() && current >= 0) { - prev = current; - prev_xfading = xfade; - time = 0; - current = p_current; - switched = true; - _change_notify("current"); - } else { - current = p_current; - } -#endif - void AnimationNodeTransition::set_cross_fade_time(float p_fade) { xfade = p_fade; } @@ -846,8 +832,8 @@ void AnimationNodeTransition::_bind_methods() { ADD_PROPERTY(PropertyInfo(Variant::REAL, "xfade_time", PROPERTY_HINT_RANGE, "0,120,0.01"), "set_cross_fade_time", "get_cross_fade_time"); for (int i = 0; i < MAX_INPUTS; i++) { - ADD_PROPERTYI(PropertyInfo(Variant::STRING, "input_" + itos(i) + "/name"), "set_input_caption", "get_input_caption", i); - ADD_PROPERTYI(PropertyInfo(Variant::BOOL, "input_" + itos(i) + "/auto_advance"), "set_input_as_auto_advance", "is_input_set_as_auto_advance", i); + ADD_PROPERTYI(PropertyInfo(Variant::STRING, "input_" + itos(i) + "/name", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_INTERNAL), "set_input_caption", "get_input_caption", i); + ADD_PROPERTYI(PropertyInfo(Variant::BOOL, "input_" + itos(i) + "/auto_advance", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_INTERNAL), "set_input_as_auto_advance", "is_input_set_as_auto_advance", i); } } diff --git a/scene/animation/animation_player.cpp b/scene/animation/animation_player.cpp index 2bc9336b14..7ec7037dd7 100644 --- a/scene/animation/animation_player.cpp +++ b/scene/animation/animation_player.cpp @@ -493,7 +493,7 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float pa->object->set_indexed(pa->subpath, value, &valid); //you are not speshul #ifdef DEBUG_ENABLED if (!valid) { - ERR_PRINTS("Failed setting track value '" + String(pa->owner->path) + "'. Check if property exists or the type of key is valid. Animation '" + a->get_name() + "' at node '" + get_path() + "'."); + ERR_PRINT("Failed setting track value '" + String(pa->owner->path) + "'. Check if property exists or the type of key is valid. Animation '" + a->get_name() + "' at node '" + get_path() + "'."); } #endif @@ -501,7 +501,7 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float case SP_NODE2D_POS: { #ifdef DEBUG_ENABLED if (value.get_type() != Variant::VECTOR2) { - ERR_PRINTS("Position key at time " + rtos(p_time) + " in Animation Track '" + String(pa->owner->path) + "' not of type Vector2(). Animation '" + a->get_name() + "' at node '" + get_path() + "'."); + ERR_PRINT("Position key at time " + rtos(p_time) + " in Animation Track '" + String(pa->owner->path) + "' not of type Vector2(). Animation '" + a->get_name() + "' at node '" + get_path() + "'."); } #endif static_cast<Node2D *>(pa->object)->set_position(value); @@ -509,7 +509,7 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float case SP_NODE2D_ROT: { #ifdef DEBUG_ENABLED if (value.is_num()) { - ERR_PRINTS("Rotation key at time " + rtos(p_time) + " in Animation Track '" + String(pa->owner->path) + "' not numerical. Animation '" + a->get_name() + "' at node '" + get_path() + "'."); + ERR_PRINT("Rotation key at time " + rtos(p_time) + " in Animation Track '" + String(pa->owner->path) + "' not numerical. Animation '" + a->get_name() + "' at node '" + get_path() + "'."); } #endif @@ -518,7 +518,7 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float case SP_NODE2D_SCALE: { #ifdef DEBUG_ENABLED if (value.get_type() != Variant::VECTOR2) { - ERR_PRINTS("Scale key at time " + rtos(p_time) + " in Animation Track '" + String(pa->owner->path) + "' not of type Vector2()." + a->get_name() + "' at node '" + get_path() + "'."); + ERR_PRINT("Scale key at time " + rtos(p_time) + " in Animation Track '" + String(pa->owner->path) + "' not of type Vector2()." + a->get_name() + "' at node '" + get_path() + "'."); } #endif @@ -553,7 +553,7 @@ void AnimationPlayer::_animation_process_animation(AnimationData *p_anim, float ERR_CONTINUE(s > VARIANT_ARG_MAX); #ifdef DEBUG_ENABLED if (!nc->node->has_method(method)) { - ERR_PRINTS("Invalid method call '" + method + "'. '" + a->get_name() + "' at node '" + get_path() + "'."); + ERR_PRINT("Invalid method call '" + method + "'. '" + a->get_name() + "' at node '" + get_path() + "'."); } #endif @@ -884,7 +884,7 @@ void AnimationPlayer::_animation_update_transforms() { pa->object->set_indexed(pa->subpath, pa->value_accum, &valid); //you are not speshul #ifdef DEBUG_ENABLED if (!valid) { - ERR_PRINTS("Failed setting key at time " + rtos(playback.current.pos) + " in Animation '" + get_current_animation() + "' at Node '" + get_path() + "', Track '" + String(pa->owner->path) + "'. Check if property exists or the type of key is right for the property"); + ERR_PRINT("Failed setting key at time " + rtos(playback.current.pos) + " in Animation '" + get_current_animation() + "' at Node '" + get_path() + "', Track '" + String(pa->owner->path) + "'. Check if property exists or the type of key is right for the property"); } #endif @@ -892,7 +892,7 @@ void AnimationPlayer::_animation_update_transforms() { case SP_NODE2D_POS: { #ifdef DEBUG_ENABLED if (pa->value_accum.get_type() != Variant::VECTOR2) { - ERR_PRINTS("Position key at time " + rtos(playback.current.pos) + " in Animation '" + get_current_animation() + "' at Node '" + get_path() + "', Track '" + String(pa->owner->path) + "' not of type Vector2()"); + ERR_PRINT("Position key at time " + rtos(playback.current.pos) + " in Animation '" + get_current_animation() + "' at Node '" + get_path() + "', Track '" + String(pa->owner->path) + "' not of type Vector2()"); } #endif static_cast<Node2D *>(pa->object)->set_position(pa->value_accum); @@ -900,7 +900,7 @@ void AnimationPlayer::_animation_update_transforms() { case SP_NODE2D_ROT: { #ifdef DEBUG_ENABLED if (pa->value_accum.is_num()) { - ERR_PRINTS("Rotation key at time " + rtos(playback.current.pos) + " in Animation '" + get_current_animation() + "' at Node '" + get_path() + "', Track '" + String(pa->owner->path) + "' not numerical"); + ERR_PRINT("Rotation key at time " + rtos(playback.current.pos) + " in Animation '" + get_current_animation() + "' at Node '" + get_path() + "', Track '" + String(pa->owner->path) + "' not numerical"); } #endif @@ -909,7 +909,7 @@ void AnimationPlayer::_animation_update_transforms() { case SP_NODE2D_SCALE: { #ifdef DEBUG_ENABLED if (pa->value_accum.get_type() != Variant::VECTOR2) { - ERR_PRINTS("Scale key at time " + rtos(playback.current.pos) + " in Animation '" + get_current_animation() + "' at Node '" + get_path() + "', Track '" + String(pa->owner->path) + "' not of type Vector2()"); + ERR_PRINT("Scale key at time " + rtos(playback.current.pos) + " in Animation '" + get_current_animation() + "' at Node '" + get_path() + "', Track '" + String(pa->owner->path) + "' not of type Vector2()"); } #endif diff --git a/scene/animation/animation_tree.cpp b/scene/animation/animation_tree.cpp index 8b2d8861e7..c28f8dc824 100644 --- a/scene/animation/animation_tree.cpp +++ b/scene/animation/animation_tree.cpp @@ -49,7 +49,7 @@ void AnimationNode::get_parameter_list(List<PropertyInfo> *r_list) const { Variant AnimationNode::get_parameter_default_value(const StringName &p_parameter) const { if (get_script_instance()) { - return get_script_instance()->call("get_parameter_default_value"); + return get_script_instance()->call("get_parameter_default_value", p_parameter); } return Variant(); } @@ -397,7 +397,7 @@ void AnimationNode::_validate_property(PropertyInfo &property) const { Ref<AnimationNode> AnimationNode::get_child_by_name(const StringName &p_name) { if (get_script_instance()) { - return get_script_instance()->call("get_child_by_name"); + return get_script_instance()->call("get_child_by_name", p_name); } return Ref<AnimationNode>(); } @@ -578,7 +578,7 @@ bool AnimationTree::_update_caches(AnimationPlayer *player) { Node *child = parent->get_node_and_resource(path, resource, leftover_path); if (!child) { - ERR_PRINTS("AnimationTree: '" + String(E->get()) + "', couldn't resolve track: '" + String(path) + "'"); + ERR_PRINT("AnimationTree: '" + String(E->get()) + "', couldn't resolve track: '" + String(path) + "'"); continue; } @@ -608,7 +608,7 @@ bool AnimationTree::_update_caches(AnimationPlayer *player) { Spatial *spatial = Object::cast_to<Spatial>(child); if (!spatial) { - ERR_PRINTS("AnimationTree: '" + String(E->get()) + "', transform track does not point to spatial: '" + String(path) + "'"); + ERR_PRINT("AnimationTree: '" + String(E->get()) + "', transform track does not point to spatial: '" + String(path) + "'"); continue; } diff --git a/scene/animation/skeleton_ik.cpp b/scene/animation/skeleton_ik.cpp index 99a266af0d..46028a9ce2 100644 --- a/scene/animation/skeleton_ik.cpp +++ b/scene/animation/skeleton_ik.cpp @@ -320,7 +320,7 @@ void FabrikInverseKinematic::solve(Task *p_task, real_t blending_delta, bool ove new_bone_pose.basis = new_bone_pose.basis * p_task->chain.tips[0].end_effector->goal_transform.basis; } - p_task->skeleton->set_bone_global_pose_override(ci->bone, new_bone_pose, 1.0); + p_task->skeleton->set_bone_global_pose_override(ci->bone, new_bone_pose, 1.0, true); if (!ci->children.empty()) ci = &ci->children.write[0]; @@ -329,6 +329,17 @@ void FabrikInverseKinematic::solve(Task *p_task, real_t blending_delta, bool ove } } +void FabrikInverseKinematic::reset(Task *p_task) { + ChainItem *ci(&p_task->chain.chain_root); + while (ci) { + p_task->skeleton->set_bone_global_pose_override(ci->bone, Transform(), 0); + if (!ci->children.empty()) + ci = &ci->children.write[0]; + else + ci = NULL; + } +} + void SkeletonIK::_validate_property(PropertyInfo &property) const { if (property.name == "root_bone" || property.name == "tip_bone") { @@ -531,6 +542,8 @@ void SkeletonIK::start(bool p_one_time) { void SkeletonIK::stop() { set_process_internal(false); + if (task) + FabrikInverseKinematic::reset(task); } Transform SkeletonIK::_get_target_transform() { diff --git a/scene/animation/skeleton_ik.h b/scene/animation/skeleton_ik.h index 9ae010dc4e..8fc8a58b99 100644 --- a/scene/animation/skeleton_ik.h +++ b/scene/animation/skeleton_ik.h @@ -139,6 +139,7 @@ public: static void set_goal(Task *p_task, const Transform &p_goal); static void make_goal(Task *p_task, const Transform &p_inverse_transf, real_t blending_delta); static void solve(Task *p_task, real_t blending_delta, bool override_tip_basis, bool p_use_magnet, const Vector3 &p_magnet_position); + static void reset(Task *p_task); }; class SkeletonIK : public Node { diff --git a/scene/animation/tween.cpp b/scene/animation/tween.cpp index 58212335c2..331a6c769c 100644 --- a/scene/animation/tween.cpp +++ b/scene/animation/tween.cpp @@ -827,6 +827,7 @@ bool Tween::start() { // Are there any pending updates? if (pending_update != 0) { // Start the tweens after deferring + call_deferred("start"); return true; } diff --git a/scene/debugger/script_debugger_remote.cpp b/scene/debugger/script_debugger_remote.cpp index 04d04ceb66..0a075df060 100644 --- a/scene/debugger/script_debugger_remote.cpp +++ b/scene/debugger/script_debugger_remote.cpp @@ -92,7 +92,7 @@ Error ScriptDebuggerRemote::connect_to_host(const String &p_host, uint16_t p_por if (tcp_client->get_status() != StreamPeerTCP::STATUS_CONNECTED) { - ERR_PRINTS("Remote Debugger: Unable to connect. Status: " + String::num(tcp_client->get_status()) + "."); + ERR_PRINT("Remote Debugger: Unable to connect. Status: " + String::num(tcp_client->get_status()) + "."); return FAILED; }; diff --git a/scene/gui/center_container.cpp b/scene/gui/center_container.cpp index 9f4353ceb6..64d6885bc8 100644 --- a/scene/gui/center_container.cpp +++ b/scene/gui/center_container.cpp @@ -54,7 +54,13 @@ Size2 CenterContainer::get_minimum_size() const { void CenterContainer::set_use_top_left(bool p_enable) { + if (use_top_left == p_enable) { + return; + } + use_top_left = p_enable; + + minimum_size_changed(); queue_sort(); } diff --git a/scene/gui/control.cpp b/scene/gui/control.cpp index 9a67745e0d..4c70bd1d39 100644 --- a/scene/gui/control.cpp +++ b/scene/gui/control.cpp @@ -462,11 +462,6 @@ void Control::_update_canvas_item_transform() { Transform2D xform = _get_internal_transform(); xform[2] += get_position(); - // We use a little workaround to avoid flickering when moving the pivot with _edit_set_pivot() - if (is_inside_tree() && Math::abs(Math::sin(data.rotation * 4.0f)) < 0.00001f && get_viewport()->is_snap_controls_to_pixels_enabled()) { - xform[2] = xform[2].round(); - } - VisualServer::get_singleton()->canvas_item_set_transform(get_canvas_item(), xform); } @@ -2475,9 +2470,9 @@ void Control::_window_find_focus_neighbour(const Vector2 &p_dir, Node *p_at, con Transform2D xform = c->get_global_transform(); points[0] = xform.xform(Point2()); - points[1] = xform.xform(Point2(get_size().x, 0)); - points[2] = xform.xform(get_size()); - points[3] = xform.xform(Point2(0, get_size().y)); + points[1] = xform.xform(Point2(c->get_size().x, 0)); + points[2] = xform.xform(c->get_size()); + points[3] = xform.xform(Point2(0, c->get_size().y)); float min = 1e7; @@ -2682,6 +2677,11 @@ Vector2 Control::get_pivot_offset() const { void Control::set_scale(const Vector2 &p_scale) { data.scale = p_scale; + // Avoid having 0 scale values, can lead to errors in physics and rendering. + if (data.scale.x == 0) + data.scale.x = CMP_EPSILON; + if (data.scale.y == 0) + data.scale.y = CMP_EPSILON; update(); _notify_transform(); } diff --git a/scene/gui/graph_edit.cpp b/scene/gui/graph_edit.cpp index 97954d9e7c..6a6fe43876 100644 --- a/scene/gui/graph_edit.cpp +++ b/scene/gui/graph_edit.cpp @@ -200,6 +200,13 @@ void GraphEdit::_update_scroll() { else v_scroll->show(); + Size2 hmin = h_scroll->get_combined_minimum_size(); + Size2 vmin = v_scroll->get_combined_minimum_size(); + + // Avoid scrollbar overlapping. + h_scroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, v_scroll->is_visible() ? -vmin.width : 0); + v_scroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, h_scroll->is_visible() ? -hmin.height : 0); + set_block_minimum_size_adjust(false); if (!awaiting_scroll_offset_update) { @@ -285,15 +292,15 @@ void GraphEdit::_notification(int p_what) { Size2 hmin = h_scroll->get_combined_minimum_size(); Size2 vmin = v_scroll->get_combined_minimum_size(); - v_scroll->set_anchor_and_margin(MARGIN_LEFT, ANCHOR_END, -vmin.width); - v_scroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, 0); - v_scroll->set_anchor_and_margin(MARGIN_TOP, ANCHOR_BEGIN, 0); - v_scroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, 0); - h_scroll->set_anchor_and_margin(MARGIN_LEFT, ANCHOR_BEGIN, 0); h_scroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, 0); h_scroll->set_anchor_and_margin(MARGIN_TOP, ANCHOR_END, -hmin.height); h_scroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, 0); + + v_scroll->set_anchor_and_margin(MARGIN_LEFT, ANCHOR_END, -vmin.width); + v_scroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, 0); + v_scroll->set_anchor_and_margin(MARGIN_TOP, ANCHOR_BEGIN, 0); + v_scroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, 0); } if (p_what == NOTIFICATION_DRAW) { @@ -1350,6 +1357,7 @@ GraphEdit::GraphEdit() { v_scroll = memnew(VScrollBar); v_scroll->set_name("_v_scroll"); top_layer->add_child(v_scroll); + updating = false; connecting = false; right_disconnects = false; diff --git a/scene/gui/item_list.cpp b/scene/gui/item_list.cpp index 2a812caf9a..526950dbb3 100644 --- a/scene/gui/item_list.cpp +++ b/scene/gui/item_list.cpp @@ -993,7 +993,7 @@ void ItemList::_notification(int p_what) { } //ensure_selected_visible needs to be checked before we draw the list. - if (ensure_selected_visible && current >= 0 && current <= items.size()) { + if (ensure_selected_visible && current >= 0 && current < items.size()) { Rect2 r = items[current].rect_cache; int from = scroll_bar->get_value(); diff --git a/scene/gui/label.cpp b/scene/gui/label.cpp index 77913efd1c..9b542cb179 100644 --- a/scene/gui/label.cpp +++ b/scene/gui/label.cpp @@ -232,7 +232,6 @@ void Label::_notification(int p_what) { return; } if (from->space_count) { - chars_total += from->space_count; /* spacing */ x_ofs += space_w * from->space_count; if (can_fill && align == ALIGN_FILL && spaces) { diff --git a/scene/gui/line_edit.cpp b/scene/gui/line_edit.cpp index a6cd9a0665..7afc3b0d00 100644 --- a/scene/gui/line_edit.cpp +++ b/scene/gui/line_edit.cpp @@ -128,7 +128,7 @@ void LineEdit::_gui_input(Ref<InputEvent> p_event) { selection.doubleclick = false; if (OS::get_singleton()->has_virtual_keyboard()) - OS::get_singleton()->show_virtual_keyboard(text, get_global_rect()); + OS::get_singleton()->show_virtual_keyboard(text, get_global_rect(), max_length); } update(); @@ -913,7 +913,7 @@ void LineEdit::_notification(int p_what) { OS::get_singleton()->set_ime_position(get_global_position() + cursor_pos); if (OS::get_singleton()->has_virtual_keyboard()) - OS::get_singleton()->show_virtual_keyboard(text, get_global_rect()); + OS::get_singleton()->show_virtual_keyboard(text, get_global_rect(), max_length); } break; case NOTIFICATION_FOCUS_EXIT: { @@ -1239,6 +1239,11 @@ void LineEdit::set_text(String p_text) { clear_internal(); append_at_cursor(p_text); + + if (expand_to_text_length) { + minimum_size_changed(); + } + update(); cursor_pos = 0; window_pos = 0; @@ -1482,6 +1487,7 @@ void LineEdit::set_editable(bool p_editable) { editable = p_editable; _generate_context_menu(); + minimum_size_changed(); update(); } @@ -1617,7 +1623,11 @@ bool LineEdit::get_expand_to_text_length() const { } void LineEdit::set_clear_button_enabled(bool p_enabled) { + if (clear_button_enabled == p_enabled) { + return; + } clear_button_enabled = p_enabled; + minimum_size_changed(); update(); } @@ -1653,6 +1663,7 @@ void LineEdit::set_right_icon(const Ref<Texture> &p_icon) { return; } right_icon = p_icon; + minimum_size_changed(); update(); } diff --git a/scene/gui/option_button.cpp b/scene/gui/option_button.cpp index 8598a953b4..3f46afa8e8 100644 --- a/scene/gui/option_button.cpp +++ b/scene/gui/option_button.cpp @@ -36,7 +36,14 @@ Size2 OptionButton::get_minimum_size() const { Size2 minsize = Button::get_minimum_size(); if (has_icon("arrow")) { - minsize.width += Control::get_icon("arrow")->get_width() + get_constant("hseparation"); + const Size2 padding = get_stylebox("normal")->get_minimum_size(); + const Size2 arrow_size = Control::get_icon("arrow")->get_size(); + + Size2 content_size = minsize - padding; + content_size.width += arrow_size.width + get_constant("hseparation"); + content_size.height = MAX(content_size.height, arrow_size.height); + + minsize = content_size + padding; } return minsize; diff --git a/scene/gui/scroll_container.cpp b/scene/gui/scroll_container.cpp index dc1183df74..509e6d19f6 100644 --- a/scene/gui/scroll_container.cpp +++ b/scene/gui/scroll_container.cpp @@ -219,16 +219,16 @@ void ScrollContainer::_update_scrollbar_position() { Size2 hmin = h_scroll->get_combined_minimum_size(); Size2 vmin = v_scroll->get_combined_minimum_size(); - v_scroll->set_anchor_and_margin(MARGIN_LEFT, ANCHOR_END, -vmin.width); - v_scroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, 0); - v_scroll->set_anchor_and_margin(MARGIN_TOP, ANCHOR_BEGIN, 0); - v_scroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, 0); - h_scroll->set_anchor_and_margin(MARGIN_LEFT, ANCHOR_BEGIN, 0); h_scroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, 0); h_scroll->set_anchor_and_margin(MARGIN_TOP, ANCHOR_END, -hmin.height); h_scroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, 0); + v_scroll->set_anchor_and_margin(MARGIN_LEFT, ANCHOR_END, -vmin.width); + v_scroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, 0); + v_scroll->set_anchor_and_margin(MARGIN_TOP, ANCHOR_BEGIN, 0); + v_scroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, 0); + h_scroll->raise(); v_scroll->raise(); } @@ -317,6 +317,7 @@ void ScrollContainer::_notification(int p_what) { r.position += ofs; fit_child_in_rect(c, r); } + update(); }; @@ -408,13 +409,17 @@ void ScrollContainer::update_scrollbars() { Size2 hmin; Size2 vmin; - if (scroll_h) hmin = h_scroll->get_combined_minimum_size(); - if (scroll_v) vmin = v_scroll->get_combined_minimum_size(); + if (scroll_h) { + hmin = h_scroll->get_combined_minimum_size(); + } + if (scroll_v) { + vmin = v_scroll->get_combined_minimum_size(); + } Size2 min = child_max_size; - bool hide_scroll_v = !scroll_v || min.height <= size.height - hmin.height; - bool hide_scroll_h = !scroll_h || min.width <= size.width - vmin.width; + bool hide_scroll_v = !scroll_v || min.height <= size.height; + bool hide_scroll_h = !scroll_h || min.width <= size.width; if (hide_scroll_v) { @@ -449,6 +454,10 @@ void ScrollContainer::update_scrollbars() { scroll.x = h_scroll->get_value(); } + + // Avoid scrollbar overlapping. + h_scroll->set_anchor_and_margin(MARGIN_RIGHT, ANCHOR_END, hide_scroll_v ? 0 : -vmin.width); + v_scroll->set_anchor_and_margin(MARGIN_BOTTOM, ANCHOR_END, hide_scroll_h ? 0 : -hmin.height); } void ScrollContainer::_scroll_moved(float) { @@ -461,8 +470,12 @@ void ScrollContainer::_scroll_moved(float) { }; void ScrollContainer::set_enable_h_scroll(bool p_enable) { + if (scroll_h == p_enable) { + return; + } scroll_h = p_enable; + minimum_size_changed(); queue_sort(); } @@ -472,8 +485,12 @@ bool ScrollContainer::is_h_scroll_enabled() const { } void ScrollContainer::set_enable_v_scroll(bool p_enable) { + if (scroll_v == p_enable) { + return; + } scroll_v = p_enable; + minimum_size_changed(); queue_sort(); } @@ -593,12 +610,11 @@ ScrollContainer::ScrollContainer() { h_scroll = memnew(HScrollBar); h_scroll->set_name("_h_scroll"); add_child(h_scroll); + h_scroll->connect("value_changed", this, "_scroll_moved"); v_scroll = memnew(VScrollBar); v_scroll->set_name("_v_scroll"); add_child(v_scroll); - - h_scroll->connect("value_changed", this, "_scroll_moved"); v_scroll->connect("value_changed", this, "_scroll_moved"); drag_speed = Vector2(); diff --git a/scene/gui/tab_container.cpp b/scene/gui/tab_container.cpp index c3ddc41813..b045ff4fe1 100644 --- a/scene/gui/tab_container.cpp +++ b/scene/gui/tab_container.cpp @@ -785,23 +785,25 @@ TabContainer::TabAlign TabContainer::get_tab_align() const { return align; } -void TabContainer::set_tabs_visible(bool p_visibe) { +void TabContainer::set_tabs_visible(bool p_visible) { - if (p_visibe == tabs_visible) + if (p_visible == tabs_visible) return; - tabs_visible = p_visibe; + tabs_visible = p_visible; Vector<Control *> tabs = _get_tabs(); for (int i = 0; i < tabs.size(); i++) { Control *c = tabs[i]; - if (p_visibe) + if (p_visible) c->set_margin(MARGIN_TOP, _get_top_margin()); else c->set_margin(MARGIN_TOP, 0); } + update(); + minimum_size_changed(); } bool TabContainer::are_tabs_visible() const { @@ -936,8 +938,10 @@ Size2 TabContainer::get_minimum_size() const { Ref<StyleBox> tab_disabled = get_stylebox("tab_disabled"); Ref<Font> font = get_font("font"); - ms.y += MAX(MAX(tab_bg->get_minimum_size().y, tab_fg->get_minimum_size().y), tab_disabled->get_minimum_size().y); - ms.y += font->get_height(); + if (tabs_visible) { + ms.y += MAX(MAX(tab_bg->get_minimum_size().y, tab_fg->get_minimum_size().y), tab_disabled->get_minimum_size().y); + ms.y += font->get_height(); + } Ref<StyleBox> sb = get_stylebox("panel"); ms += sb->get_minimum_size(); diff --git a/scene/gui/tab_container.h b/scene/gui/tab_container.h index e69c2ae289..c5a9045ca6 100644 --- a/scene/gui/tab_container.h +++ b/scene/gui/tab_container.h @@ -87,7 +87,7 @@ public: void set_tab_align(TabAlign p_align); TabAlign get_tab_align() const; - void set_tabs_visible(bool p_visibe); + void set_tabs_visible(bool p_visible); bool are_tabs_visible() const; void set_tab_title(int p_tab, const String &p_title); diff --git a/scene/gui/text_edit.cpp b/scene/gui/text_edit.cpp index 6de2f0b570..93d0ae080b 100644 --- a/scene/gui/text_edit.cpp +++ b/scene/gui/text_edit.cpp @@ -4480,7 +4480,7 @@ void TextEdit::cursor_set_line(int p_row, bool p_adjust_viewport, bool p_can_be_ if (p_row - move_up > 0 && !is_line_hidden(p_row - move_up)) { p_row -= move_up; } else { - WARN_PRINTS(("Cursor set to hidden line " + itos(p_row) + " and there are no nonhidden lines.")); + WARN_PRINT(("Cursor set to hidden line " + itos(p_row) + " and there are no nonhidden lines.")); } } } diff --git a/scene/gui/video_player.cpp b/scene/gui/video_player.cpp index 071e8a8ac6..0a693d4023 100644 --- a/scene/gui/video_player.cpp +++ b/scene/gui/video_player.cpp @@ -249,6 +249,10 @@ void VideoPlayer::set_stream(const Ref<VideoStream> &p_stream) { } update(); + + if (!expand) { + minimum_size_changed(); + } }; Ref<VideoStream> VideoPlayer::get_stream() const { diff --git a/scene/main/node.cpp b/scene/main/node.cpp index 350959dcc3..761fe3f90f 100644 --- a/scene/main/node.cpp +++ b/scene/main/node.cpp @@ -1192,7 +1192,7 @@ void Node::add_child_below_node(Node *p_node, Node *p_child, bool p_legible_uniq if (is_a_parent_of(p_node)) { move_child(p_child, p_node->get_position_in_parent() + 1); } else { - WARN_PRINTS("Cannot move under node " + p_node->get_name() + " as " + p_child->get_name() + " does not share a parent."); + WARN_PRINT("Cannot move under node " + p_node->get_name() + " as " + p_child->get_name() + " does not share a parent."); } } diff --git a/scene/main/scene_tree.cpp b/scene/main/scene_tree.cpp index da147e7112..c0e566eed5 100644 --- a/scene/main/scene_tree.cpp +++ b/scene/main/scene_tree.cpp @@ -423,7 +423,8 @@ void SceneTree::input_event(const Ref<InputEvent> &p_event) { input_handled = false; - const Ref<InputEvent> &ev = p_event; + // Don't make const ref unless you can find and fix what caused GH-34691. + Ref<InputEvent> ev = p_event; MainLoop::input_event(ev); @@ -458,10 +459,7 @@ void SceneTree::input_event(const Ref<InputEvent> &p_event) { } void SceneTree::init() { - - //_quit=false; initialized = true; - root->_set_tree(this); MainLoop::init(); } @@ -1284,6 +1282,14 @@ void SceneTree::_change_scene(Node *p_to) { current_scene = NULL; } + // If we're quitting, abort. + if (unlikely(_quit)) { + if (p_to) { // Prevent memory leak. + memdelete(p_to); + } + return; + } + if (p_to) { current_scene = p_to; root->add_child(p_to); @@ -1291,15 +1297,14 @@ void SceneTree::_change_scene(Node *p_to) { } Error SceneTree::change_scene(const String &p_path) { - Ref<PackedScene> new_scene = ResourceLoader::load(p_path); if (new_scene.is_null()) return ERR_CANT_OPEN; return change_scene_to(new_scene); } -Error SceneTree::change_scene_to(const Ref<PackedScene> &p_scene) { +Error SceneTree::change_scene_to(const Ref<PackedScene> &p_scene) { Node *new_scene = NULL; if (p_scene.is_valid()) { new_scene = p_scene->instance(); @@ -1309,8 +1314,8 @@ Error SceneTree::change_scene_to(const Ref<PackedScene> &p_scene) { call_deferred("_change_scene", new_scene); return OK; } -Error SceneTree::reload_current_scene() { +Error SceneTree::reload_current_scene() { ERR_FAIL_COND_V(!current_scene, ERR_UNCONFIGURED); String fname = current_scene->get_filename(); return change_scene(fname); @@ -1321,6 +1326,7 @@ void SceneTree::add_current_scene(Node *p_current) { current_scene = p_current; root->add_child(p_current); } + #ifdef DEBUG_ENABLED static void _fill_array(Node *p_node, Array &array, int p_level) { @@ -2106,7 +2112,7 @@ SceneTree::SceneTree() { ProjectSettings::get_singleton()->set("rendering/environment/default_environment", ""); } else { //file was erased, notify user. - ERR_PRINTS(RTR("Default Environment as specified in Project Settings (Rendering -> Environment -> Default Environment) could not be loaded.")); + ERR_PRINT(RTR("Default Environment as specified in Project Settings (Rendering -> Environment -> Default Environment) could not be loaded.")); } } } diff --git a/scene/main/viewport.cpp b/scene/main/viewport.cpp index a56903636f..72ab817e98 100644 --- a/scene/main/viewport.cpp +++ b/scene/main/viewport.cpp @@ -1845,7 +1845,7 @@ bool Viewport::_gui_drop(Control *p_at_control, Point2 p_at_pos, bool p_just_che void Viewport::_gui_input_event(Ref<InputEvent> p_event) { - ERR_FAIL_COND(p_event.is_null()) + ERR_FAIL_COND(p_event.is_null()); //? /* diff --git a/scene/register_scene_types.cpp b/scene/register_scene_types.cpp index 09d4505458..d53872df6e 100644 --- a/scene/register_scene_types.cpp +++ b/scene/register_scene_types.cpp @@ -194,13 +194,11 @@ #include "scene/3d/path.h" #include "scene/3d/physics_body.h" #include "scene/3d/physics_joint.h" -#include "scene/3d/portal.h" #include "scene/3d/position_3d.h" #include "scene/3d/proximity_group.h" #include "scene/3d/ray_cast.h" #include "scene/3d/reflection_probe.h" #include "scene/3d/remote_transform.h" -#include "scene/3d/room_instance.h" #include "scene/3d/skeleton.h" #include "scene/3d/soft_body.h" #include "scene/3d/spring_arm.h" @@ -751,7 +749,7 @@ void register_scene_types() { if (font_path != String()) { font = ResourceLoader::load(font_path); if (!font.is_valid()) { - ERR_PRINTS("Error loading custom font '" + font_path + "'"); + ERR_PRINT("Error loading custom font '" + font_path + "'"); } } @@ -766,7 +764,7 @@ void register_scene_types() { Theme::set_default_font(font); } } else { - ERR_PRINTS("Error loading custom theme '" + theme_path + "'"); + ERR_PRINT("Error loading custom theme '" + theme_path + "'"); } } } diff --git a/scene/resources/audio_stream_sample.cpp b/scene/resources/audio_stream_sample.cpp index bfc7f407eb..a412d8a5e2 100644 --- a/scene/resources/audio_stream_sample.cpp +++ b/scene/resources/audio_stream_sample.cpp @@ -29,6 +29,7 @@ /*************************************************************************/ #include "audio_stream_sample.h" + #include "core/io/marshalls.h" #include "core/os/file_access.h" @@ -518,7 +519,7 @@ PoolVector<uint8_t> AudioStreamSample::get_data() const { Error AudioStreamSample::save_to_wav(const String &p_path) { if (format == AudioStreamSample::FORMAT_IMA_ADPCM) { - WARN_PRINTS("Saving IMA_ADPC samples are not supported yet"); + WARN_PRINT("Saving IMA_ADPC samples are not supported yet"); return ERR_UNAVAILABLE; } @@ -656,8 +657,8 @@ AudioStreamSample::AudioStreamSample() { data = NULL; data_bytes = 0; } -AudioStreamSample::~AudioStreamSample() { +AudioStreamSample::~AudioStreamSample() { if (data) { AudioServer::get_singleton()->audio_data_free(data); data = NULL; diff --git a/scene/resources/audio_stream_sample.h b/scene/resources/audio_stream_sample.h index d5d8f073fb..adcac14ea8 100644 --- a/scene/resources/audio_stream_sample.h +++ b/scene/resources/audio_stream_sample.h @@ -28,8 +28,8 @@ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ -#ifndef AUDIOSTREAMSAMPLE_H -#define AUDIOSTREAMSAMPLE_H +#ifndef AUDIO_STREAM_SAMPLE_H +#define AUDIO_STREAM_SAMPLE_H #include "servers/audio/audio_stream.h" @@ -153,4 +153,4 @@ public: VARIANT_ENUM_CAST(AudioStreamSample::Format) VARIANT_ENUM_CAST(AudioStreamSample::LoopMode) -#endif // AUDIOSTREAMSample_H +#endif // AUDIO_STREAM_SAMPLE_H diff --git a/scene/resources/dynamic_font.cpp b/scene/resources/dynamic_font.cpp index 10d871aa92..d19d82d252 100644 --- a/scene/resources/dynamic_font.cpp +++ b/scene/resources/dynamic_font.cpp @@ -130,7 +130,10 @@ Error DynamicFontAtSize::_load() { } else { FileAccess *f = FileAccess::open(font->font_path, FileAccess::READ); - ERR_FAIL_COND_V_MSG(!f, ERR_CANT_OPEN, "Cannot open font file '" + font->font_path + "'."); + if (!f) { + FT_Done_FreeType(library); + ERR_FAIL_V_MSG(ERR_CANT_OPEN, "Cannot open font file '" + font->font_path + "'."); + } size_t len = f->get_len(); _fontdata[font->font_path] = Vector<uint8_t>(); @@ -145,7 +148,10 @@ Error DynamicFontAtSize::_load() { if (font->font_mem == NULL && font->font_path != String()) { FileAccess *f = FileAccess::open(font->font_path, FileAccess::READ); - ERR_FAIL_COND_V_MSG(!f, ERR_CANT_OPEN, "Cannot open font file '" + font->font_path + "'."); + if (!f) { + FT_Done_FreeType(library); + ERR_FAIL_V_MSG(ERR_CANT_OPEN, "Cannot open font file '" + font->font_path + "'."); + } memset(&stream, 0, sizeof(FT_StreamRec)); stream.base = NULL; @@ -176,6 +182,7 @@ Error DynamicFontAtSize::_load() { error = FT_Open_Face(library, &fargs, 0, &face); } else { + FT_Done_FreeType(library); ERR_FAIL_V_MSG(ERR_UNCONFIGURED, "DynamicFont uninitialized."); } @@ -314,7 +321,7 @@ float DynamicFontAtSize::draw_char(RID p_canvas_item, const Point2 &p_pos, CharT float advance = 0.0; - // use normal character size if there's no outline charater + // use normal character size if there's no outline character if (p_outline && !ch->found) { FT_GlyphSlot slot = face->glyph; int error = FT_Load_Char(face, p_char, FT_HAS_COLOR(face) ? FT_LOAD_COLOR : FT_LOAD_DEFAULT); @@ -1011,8 +1018,8 @@ void DynamicFont::_bind_methods() { ClassDB::bind_method(D_METHOD("get_fallback_count"), &DynamicFont::get_fallback_count); ADD_GROUP("Settings", ""); - ADD_PROPERTY(PropertyInfo(Variant::INT, "size", PROPERTY_HINT_RANGE, "1,255,1"), "set_size", "get_size"); - ADD_PROPERTY(PropertyInfo(Variant::INT, "outline_size", PROPERTY_HINT_RANGE, "0,255,1"), "set_outline_size", "get_outline_size"); + ADD_PROPERTY(PropertyInfo(Variant::INT, "size", PROPERTY_HINT_RANGE, "1,1024,1"), "set_size", "get_size"); + ADD_PROPERTY(PropertyInfo(Variant::INT, "outline_size", PROPERTY_HINT_RANGE, "0,1024,1"), "set_outline_size", "get_outline_size"); ADD_PROPERTY(PropertyInfo(Variant::COLOR, "outline_color"), "set_outline_color", "get_outline_color"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "use_mipmaps"), "set_use_mipmaps", "get_use_mipmaps"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "use_filter"), "set_use_filter", "get_use_filter"); diff --git a/scene/resources/font.cpp b/scene/resources/font.cpp index 960919df47..19c59b3817 100644 --- a/scene/resources/font.cpp +++ b/scene/resources/font.cpp @@ -628,8 +628,8 @@ void BitmapFont::_bind_methods() { ADD_PROPERTY(PropertyInfo(Variant::POOL_INT_ARRAY, "chars", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL), "_set_chars", "_get_chars"); ADD_PROPERTY(PropertyInfo(Variant::POOL_INT_ARRAY, "kernings", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL), "_set_kernings", "_get_kernings"); - ADD_PROPERTY(PropertyInfo(Variant::REAL, "height", PROPERTY_HINT_RANGE, "-1024,1024,1"), "set_height", "get_height"); - ADD_PROPERTY(PropertyInfo(Variant::REAL, "ascent", PROPERTY_HINT_RANGE, "-1024,1024,1"), "set_ascent", "get_ascent"); + ADD_PROPERTY(PropertyInfo(Variant::REAL, "height", PROPERTY_HINT_RANGE, "1,1024,1"), "set_height", "get_height"); + ADD_PROPERTY(PropertyInfo(Variant::REAL, "ascent", PROPERTY_HINT_RANGE, "0,1024,1"), "set_ascent", "get_ascent"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "distance_field"), "set_distance_field_hint", "is_distance_field_hint"); ADD_PROPERTY(PropertyInfo(Variant::OBJECT, "fallback", PROPERTY_HINT_RESOURCE_TYPE, "BitmapFont"), "set_fallback", "get_fallback"); } diff --git a/scene/resources/material.h b/scene/resources/material.h index 3c2a7c928a..8e66011bec 100644 --- a/scene/resources/material.h +++ b/scene/resources/material.h @@ -42,7 +42,7 @@ class Material : public Resource { GDCLASS(Material, Resource); RES_BASE_EXTENSION("material") - OBJ_SAVE_TYPE(Material) + OBJ_SAVE_TYPE(Material); RID material; Ref<Material> next_pass; @@ -249,7 +249,7 @@ private: uint64_t blend_mode : 2; uint64_t depth_draw_mode : 2; uint64_t cull_mode : 2; - uint64_t flags : 18; + uint64_t flags : 19; uint64_t detail_blend_mode : 2; uint64_t diffuse_mode : 3; uint64_t specular_mode : 3; diff --git a/scene/resources/particles_material.cpp b/scene/resources/particles_material.cpp index a058f42cb2..412b5c259c 100644 --- a/scene/resources/particles_material.cpp +++ b/scene/resources/particles_material.cpp @@ -198,6 +198,9 @@ void ParticlesMaterial::_update_shader() { code += "uniform sampler2D emission_texture_color : hint_white;\n"; } } break; + case EMISSION_SHAPE_MAX: { // Max value for validity check. + break; + } } code += "uniform vec4 color_value : hint_color;\n"; @@ -283,7 +286,7 @@ void ParticlesMaterial::_update_shader() { code += " float degree_to_rad = pi / 180.0;\n"; code += "\n"; - if (emission_shape >= EMISSION_SHAPE_POINTS) { + if (emission_shape == EMISSION_SHAPE_POINTS || emission_shape == EMISSION_SHAPE_DIRECTED_POINTS) { code += " int point = min(emission_texture_point_count - 1, int(rand_from_seed(alt_seed) * float(emission_texture_point_count)));\n"; code += " ivec2 emission_tex_size = textureSize(emission_texture_points, 0);\n"; code += " ivec2 emission_tex_ofs = ivec2(point % emission_tex_size.x, point / emission_tex_size.x);\n"; @@ -368,6 +371,9 @@ void ParticlesMaterial::_update_shader() { } } } break; + case EMISSION_SHAPE_MAX: { // Max value for validity check. + break; + } } code += " VELOCITY = (EMISSION_TRANSFORM * vec4(VELOCITY, 0.0)).xyz;\n"; code += " TRANSFORM = EMISSION_TRANSFORM * TRANSFORM;\n"; @@ -515,7 +521,7 @@ void ParticlesMaterial::_update_shader() { } else { code += " COLOR = hue_rot_mat * color_value;\n"; } - if (emission_color_texture.is_valid() && emission_shape >= EMISSION_SHAPE_POINTS) { + if (emission_color_texture.is_valid() && (emission_shape == EMISSION_SHAPE_POINTS || emission_shape == EMISSION_SHAPE_DIRECTED_POINTS)) { code += " COLOR *= texelFetch(emission_texture_color, emission_tex_ofs, 0);\n"; } if (trail_color_modifier.is_valid()) { @@ -894,7 +900,7 @@ bool ParticlesMaterial::get_flag(Flags p_flag) const { } void ParticlesMaterial::set_emission_shape(EmissionShape p_shape) { - + ERR_FAIL_INDEX(p_shape, EMISSION_SHAPE_MAX); emission_shape = p_shape; _change_notify(); _queue_shader_change(); @@ -1242,6 +1248,7 @@ void ParticlesMaterial::_bind_methods() { BIND_ENUM_CONSTANT(EMISSION_SHAPE_BOX); BIND_ENUM_CONSTANT(EMISSION_SHAPE_POINTS); BIND_ENUM_CONSTANT(EMISSION_SHAPE_DIRECTED_POINTS); + BIND_ENUM_CONSTANT(EMISSION_SHAPE_MAX); } ParticlesMaterial::ParticlesMaterial() : diff --git a/scene/resources/particles_material.h b/scene/resources/particles_material.h index 643c2cb10e..cc860b3812 100644 --- a/scene/resources/particles_material.h +++ b/scene/resources/particles_material.h @@ -69,6 +69,7 @@ public: EMISSION_SHAPE_BOX, EMISSION_SHAPE_POINTS, EMISSION_SHAPE_DIRECTED_POINTS, + EMISSION_SHAPE_MAX }; private: diff --git a/scene/resources/resource_format_text.cpp b/scene/resources/resource_format_text.cpp index eb05defddd..849fb087ba 100644 --- a/scene/resources/resource_format_text.cpp +++ b/scene/resources/resource_format_text.cpp @@ -1384,7 +1384,7 @@ void ResourceFormatSaverTextInstance::_find_resources(const Variant &p_variant, if (!p_main && (!bundle_resources) && res->get_path().length() && res->get_path().find("::") == -1) { if (res->get_path() == local_path) { - ERR_PRINTS("Circular reference to resource being saved found: '" + local_path + "' will be null next time it's loaded."); + ERR_PRINT("Circular reference to resource being saved found: '" + local_path + "' will be null next time it's loaded."); return; } int index = external_resources.size(); diff --git a/scene/resources/room.h b/scene/resources/room.h deleted file mode 100644 index 809a9c1de8..0000000000 --- a/scene/resources/room.h +++ /dev/null @@ -1,62 +0,0 @@ -/*************************************************************************/ -/* room.h */ -/*************************************************************************/ -/* This file is part of: */ -/* GODOT ENGINE */ -/* https://godotengine.org */ -/*************************************************************************/ -/* Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. */ -/* Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). */ -/* */ -/* Permission is hereby granted, free of charge, to any person obtaining */ -/* a copy of this software and associated documentation files (the */ -/* "Software"), to deal in the Software without restriction, including */ -/* without limitation the rights to use, copy, modify, merge, publish, */ -/* distribute, sublicense, and/or sell copies of the Software, and to */ -/* permit persons to whom the Software is furnished to do so, subject to */ -/* the following conditions: */ -/* */ -/* The above copyright notice and this permission notice shall be */ -/* included in all copies or substantial portions of the Software. */ -/* */ -/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ -/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ -/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ -/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ -/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ -/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ -/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -/*************************************************************************/ - -#ifndef ROOM_BOUNDS_H -#define ROOM_BOUNDS_H - -#include "core/math/bsp_tree.h" -#include "core/resource.h" - -// FIXME: left for reference but will be removed when portals are reimplemented using Area -#if 0 - -class RoomBounds : public Resource { - - GDCLASS(RoomBounds, Resource); - RES_BASE_EXTENSION("room"); - - RID area; - PoolVector<Face3> geometry_hint; - -protected: - static void _bind_methods(); - -public: - virtual RID get_rid() const; - - void set_geometry_hint(const PoolVector<Face3> &p_geometry_hint); - PoolVector<Face3> get_geometry_hint() const; - - RoomBounds(); - ~RoomBounds(); -}; - -#endif -#endif // ROOM_H diff --git a/scene/resources/texture.cpp b/scene/resources/texture.cpp index 4d23f0eb41..b7805b7e38 100644 --- a/scene/resources/texture.cpp +++ b/scene/resources/texture.cpp @@ -2374,13 +2374,13 @@ RES ResourceFormatLoaderTextureLayered::load(const String &p_path, const String if (tex3d.is_null()) { f->close(); memdelete(f); - ERR_FAIL_COND_V(tex3d.is_null(), RES()) + ERR_FAIL_COND_V(tex3d.is_null(), RES()); } } else if (header[0] == 'G' && header[1] == 'D' && header[2] == 'A' && header[3] == 'T') { if (texarr.is_null()) { f->close(); memdelete(f); - ERR_FAIL_COND_V(texarr.is_null(), RES()) + ERR_FAIL_COND_V(texarr.is_null(), RES()); } } else { diff --git a/scene/resources/texture.h b/scene/resources/texture.h index fcd8547d07..fa698d387b 100644 --- a/scene/resources/texture.h +++ b/scene/resources/texture.h @@ -45,7 +45,8 @@ class Texture : public Resource { GDCLASS(Texture, Resource); - OBJ_SAVE_TYPE(Texture); //children are all saved as Texture, so they can be exchanged + OBJ_SAVE_TYPE(Texture); // Saves derived classes with common type so they can be interchanged. + protected: static void _bind_methods(); diff --git a/scene/resources/tile_set.cpp b/scene/resources/tile_set.cpp index d9caf1d657..db5037172e 100644 --- a/scene/resources/tile_set.cpp +++ b/scene/resources/tile_set.cpp @@ -325,14 +325,14 @@ void TileSet::_get_property_list(List<PropertyInfo> *p_list) const { int id = E->key(); String pre = itos(id) + "/"; - p_list->push_back(PropertyInfo(Variant::STRING, pre + "name")); - p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "texture", PROPERTY_HINT_RESOURCE_TYPE, "Texture")); - p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "normal_map", PROPERTY_HINT_RESOURCE_TYPE, "Texture")); - p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "tex_offset")); - p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "material", PROPERTY_HINT_RESOURCE_TYPE, "ShaderMaterial")); - p_list->push_back(PropertyInfo(Variant::COLOR, pre + "modulate")); - p_list->push_back(PropertyInfo(Variant::RECT2, pre + "region")); - p_list->push_back(PropertyInfo(Variant::INT, pre + "tile_mode", PROPERTY_HINT_ENUM, "SINGLE_TILE,AUTO_TILE,ATLAS_TILE")); + p_list->push_back(PropertyInfo(Variant::STRING, pre + "name", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "texture", PROPERTY_HINT_RESOURCE_TYPE, "Texture", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "normal_map", PROPERTY_HINT_RESOURCE_TYPE, "Texture", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "tex_offset", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "material", PROPERTY_HINT_RESOURCE_TYPE, "ShaderMaterial", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::COLOR, pre + "modulate", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::RECT2, pre + "region", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::INT, pre + "tile_mode", PROPERTY_HINT_ENUM, "SINGLE_TILE,AUTO_TILE,ATLAS_TILE", PROPERTY_USAGE_NOEDITOR)); if (tile_get_tile_mode(id) == AUTO_TILE) { p_list->push_back(PropertyInfo(Variant::INT, pre + "autotile/bitmask_mode", PROPERTY_HINT_ENUM, "2X2,3X3 (minimal),3X3", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL)); p_list->push_back(PropertyInfo(Variant::ARRAY, pre + "autotile/bitmask_flags", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL)); @@ -352,17 +352,17 @@ void TileSet::_get_property_list(List<PropertyInfo> *p_list) const { p_list->push_back(PropertyInfo(Variant::ARRAY, pre + "autotile/priority_map", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL)); p_list->push_back(PropertyInfo(Variant::ARRAY, pre + "autotile/z_index_map", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL)); } - p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "occluder_offset")); - p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "occluder", PROPERTY_HINT_RESOURCE_TYPE, "OccluderPolygon2D")); - p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "navigation_offset")); - p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "navigation", PROPERTY_HINT_RESOURCE_TYPE, "NavigationPolygon")); - p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "shape_offset", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_EDITOR)); - p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "shape_transform", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_EDITOR)); - p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "shape", PROPERTY_HINT_RESOURCE_TYPE, "Shape2D", PROPERTY_USAGE_EDITOR)); - p_list->push_back(PropertyInfo(Variant::BOOL, pre + "shape_one_way", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_EDITOR)); - p_list->push_back(PropertyInfo(Variant::REAL, pre + "shape_one_way_margin", PROPERTY_HINT_RANGE, "0,128,0.01", PROPERTY_USAGE_EDITOR)); + p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "occluder_offset", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "occluder", PROPERTY_HINT_RESOURCE_TYPE, "OccluderPolygon2D", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "navigation_offset", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "navigation", PROPERTY_HINT_RESOURCE_TYPE, "NavigationPolygon", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "shape_offset", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::VECTOR2, pre + "shape_transform", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::OBJECT, pre + "shape", PROPERTY_HINT_RESOURCE_TYPE, "Shape2D", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::BOOL, pre + "shape_one_way", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); + p_list->push_back(PropertyInfo(Variant::REAL, pre + "shape_one_way_margin", PROPERTY_HINT_RANGE, "0,128,0.01", PROPERTY_USAGE_NOEDITOR)); p_list->push_back(PropertyInfo(Variant::ARRAY, pre + "shapes", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR)); - p_list->push_back(PropertyInfo(Variant::INT, pre + "z_index", PROPERTY_HINT_RANGE, itos(VS::CANVAS_ITEM_Z_MIN) + "," + itos(VS::CANVAS_ITEM_Z_MAX) + ",1")); + p_list->push_back(PropertyInfo(Variant::INT, pre + "z_index", PROPERTY_HINT_RANGE, itos(VS::CANVAS_ITEM_Z_MIN) + "," + itos(VS::CANVAS_ITEM_Z_MAX) + ",1", PROPERTY_USAGE_NOEDITOR)); } } @@ -1038,6 +1038,7 @@ void TileSet::_tile_set_shapes(int p_id, const Array &p_shapes) { } tile_map[p_id].shapes_data = shapes_data; + emit_changed(); } Array TileSet::_tile_get_shapes(int p_id) const { @@ -1232,6 +1233,7 @@ void TileSet::_bind_methods() { BIND_ENUM_CONSTANT(BIND_TOP); BIND_ENUM_CONSTANT(BIND_TOPRIGHT); BIND_ENUM_CONSTANT(BIND_LEFT); + BIND_ENUM_CONSTANT(BIND_CENTER); BIND_ENUM_CONSTANT(BIND_RIGHT); BIND_ENUM_CONSTANT(BIND_BOTTOMLEFT); BIND_ENUM_CONSTANT(BIND_BOTTOM); diff --git a/scene/resources/video_stream.h b/scene/resources/video_stream.h index d8aee2eac3..444bb698ae 100644 --- a/scene/resources/video_stream.h +++ b/scene/resources/video_stream.h @@ -37,9 +37,6 @@ class VideoStreamPlayback : public Resource { GDCLASS(VideoStreamPlayback, Resource); -protected: - static void _bind_methods(); - public: typedef int (*AudioMixCallback)(void *p_udata, const float *p_data, int p_frames); @@ -61,28 +58,22 @@ public: virtual void set_audio_track(int p_idx) = 0; - //virtual int mix(int16_t* p_buffer,int p_frames)=0; - virtual Ref<Texture> get_texture() const = 0; virtual void update(float p_delta) = 0; virtual void set_mix_callback(AudioMixCallback p_callback, void *p_userdata) = 0; virtual int get_channels() const = 0; virtual int get_mix_rate() const = 0; - - VideoStreamPlayback(); }; class VideoStream : public Resource { GDCLASS(VideoStream, Resource); - OBJ_SAVE_TYPE(VideoStream); //children are all saved as AudioStream, so they can be exchanged + OBJ_SAVE_TYPE(VideoStream); // Saves derived classes with common type so they can be interchanged. public: virtual void set_audio_track(int p_track) = 0; virtual Ref<VideoStreamPlayback> instance_playback() = 0; - - VideoStream() {} }; #endif diff --git a/scene/resources/visual_shader.cpp b/scene/resources/visual_shader.cpp index 37792eaaea..b3a72ea7b6 100644 --- a/scene/resources/visual_shader.cpp +++ b/scene/resources/visual_shader.cpp @@ -33,6 +33,10 @@ #include "core/vmap.h" #include "servers/visual/shader_types.h" +bool VisualShaderNode::is_simple_decl() const { + return simple_decl; +} + void VisualShaderNode::set_output_port_for_preview(int p_index) { port_preview = p_index; @@ -79,7 +83,7 @@ Vector<StringName> VisualShaderNode::get_editable_properties() const { return Vector<StringName>(); } -Array VisualShaderNode::_get_default_input_values() const { +Array VisualShaderNode::get_default_input_values() const { Array ret; for (Map<int, Variant>::Element *E = default_input_values.front(); E; E = E->next()) { @@ -88,7 +92,7 @@ Array VisualShaderNode::_get_default_input_values() const { } return ret; } -void VisualShaderNode::_set_default_input_values(const Array &p_values) { +void VisualShaderNode::set_default_input_values(const Array &p_values) { if (p_values.size() % 2 == 0) { for (int i = 0; i < p_values.size(); i += 2) { @@ -115,11 +119,11 @@ void VisualShaderNode::_bind_methods() { ClassDB::bind_method(D_METHOD("set_input_port_default_value", "port", "value"), &VisualShaderNode::set_input_port_default_value); ClassDB::bind_method(D_METHOD("get_input_port_default_value", "port"), &VisualShaderNode::get_input_port_default_value); - ClassDB::bind_method(D_METHOD("_set_default_input_values", "values"), &VisualShaderNode::_set_default_input_values); - ClassDB::bind_method(D_METHOD("_get_default_input_values"), &VisualShaderNode::_get_default_input_values); + ClassDB::bind_method(D_METHOD("set_default_input_values", "values"), &VisualShaderNode::set_default_input_values); + ClassDB::bind_method(D_METHOD("get_default_input_values"), &VisualShaderNode::get_default_input_values); ADD_PROPERTY(PropertyInfo(Variant::INT, "output_port_for_preview"), "set_output_port_for_preview", "get_output_port_for_preview"); - ADD_PROPERTY(PropertyInfo(Variant::ARRAY, "default_input_values", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR), "_set_default_input_values", "_get_default_input_values"); + ADD_PROPERTY(PropertyInfo(Variant::ARRAY, "default_input_values", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL), "set_default_input_values", "get_default_input_values"); ADD_SIGNAL(MethodInfo("editor_refresh_request")); BIND_ENUM_CONSTANT(PORT_TYPE_SCALAR); @@ -132,6 +136,7 @@ void VisualShaderNode::_bind_methods() { VisualShaderNode::VisualShaderNode() { port_preview = -1; + simple_decl = true; } ///////////////////////////////////////////////////////// @@ -241,6 +246,7 @@ String VisualShaderNodeCustom::generate_code(Shader::Mode p_mode, VisualShader:: code.remove(code.size() - 1); code += "}"; } + code += "\n"; return code; } @@ -273,6 +279,7 @@ void VisualShaderNodeCustom::_bind_methods() { } VisualShaderNodeCustom::VisualShaderNodeCustom() { + simple_decl = false; } ///////////////////////////////////////////////////////// @@ -378,6 +385,9 @@ void VisualShader::remove_node(Type p_type, int p_id) { List<Connection>::Element *N = E->next(); if (E->get().from_node == p_id || E->get().to_node == p_id) { g->connections.erase(E); + if (E->get().from_node == p_id) { + g->nodes[E->get().to_node].prev_connected_nodes.erase(p_id); + } } E = N; } @@ -399,6 +409,25 @@ bool VisualShader::is_node_connection(Type p_type, int p_from_node, int p_from_p return false; } +bool VisualShader::is_nodes_connected_relatively(const Graph *p_graph, int p_node, int p_target) const { + bool result = false; + + const VisualShader::Node &node = p_graph->nodes[p_node]; + + for (const List<int>::Element *E = node.prev_connected_nodes.front(); E; E = E->next()) { + + if (E->get() == p_target) { + return true; + } + + result = is_nodes_connected_relatively(p_graph, E->get(), p_target); + if (result) { + break; + } + } + return result; +} + bool VisualShader::can_connect_nodes(Type p_type, int p_from_node, int p_from_port, int p_to_node, int p_to_port) const { ERR_FAIL_INDEX_V(p_type, TYPE_MAX, false); @@ -433,6 +462,9 @@ bool VisualShader::can_connect_nodes(Type p_type, int p_from_node, int p_from_po } } + if (is_nodes_connected_relatively(g, p_from_node, p_to_node)) + return false; + return true; } @@ -449,6 +481,8 @@ void VisualShader::connect_nodes_forced(Type p_type, int p_from_node, int p_from c.to_node = p_to_node; c.to_port = p_to_port; g->connections.push_back(c); + g->nodes[p_to_node].prev_connected_nodes.push_back(p_from_node); + _queue_update(); } @@ -479,6 +513,7 @@ Error VisualShader::connect_nodes(Type p_type, int p_from_node, int p_from_port, c.to_node = p_to_node; c.to_port = p_to_port; g->connections.push_back(c); + g->nodes[p_to_node].prev_connected_nodes.push_back(p_from_node); _queue_update(); return OK; @@ -492,6 +527,7 @@ void VisualShader::disconnect_nodes(Type p_type, int p_from_node, int p_from_por if (E->get().from_node == p_from_node && E->get().from_port == p_from_port && E->get().to_node == p_to_node && E->get().to_port == p_to_port) { g->connections.erase(E); + g->nodes[p_to_node].prev_connected_nodes.erase(p_from_node); _queue_update(); return; } @@ -1075,17 +1111,17 @@ Error VisualShader::_write_node(Type type, StringBuilder &global_code, StringBui } else if (in_type == out_type) { inputs[i] = src_var; } else if (in_type == VisualShaderNode::PORT_TYPE_SCALAR && out_type == VisualShaderNode::PORT_TYPE_VECTOR) { - inputs[i] = "dot(" + src_var + ",vec3(0.333333,0.333333,0.333333))"; + inputs[i] = "dot(" + src_var + ", vec3(0.333333, 0.333333, 0.333333))"; } else if (in_type == VisualShaderNode::PORT_TYPE_VECTOR && out_type == VisualShaderNode::PORT_TYPE_SCALAR) { inputs[i] = "vec3(" + src_var + ")"; } else if (in_type == VisualShaderNode::PORT_TYPE_BOOLEAN && out_type == VisualShaderNode::PORT_TYPE_VECTOR) { inputs[i] = "all(bvec3(" + src_var + "))"; } else if (in_type == VisualShaderNode::PORT_TYPE_BOOLEAN && out_type == VisualShaderNode::PORT_TYPE_SCALAR) { - inputs[i] = src_var + ">0.0?true:false"; + inputs[i] = src_var + " > 0.0 ? true : false"; } else if (in_type == VisualShaderNode::PORT_TYPE_SCALAR && out_type == VisualShaderNode::PORT_TYPE_BOOLEAN) { - inputs[i] = src_var + "?1.0:0.0"; + inputs[i] = src_var + " ? 1.0 : 0.0"; } else if (in_type == VisualShaderNode::PORT_TYPE_VECTOR && out_type == VisualShaderNode::PORT_TYPE_BOOLEAN) { - inputs[i] = "vec3(" + src_var + "?1.0:0.0)"; + inputs[i] = "vec3(" + src_var + " ? 1.0 : 0.0)"; } } else { @@ -1101,7 +1137,7 @@ Error VisualShader::_write_node(Type type, StringBuilder &global_code, StringBui } else if (defval.get_type() == Variant::VECTOR3) { Vector3 val = defval; inputs[i] = "n_in" + itos(node) + "p" + itos(i); - code += "\tvec3 " + inputs[i] + " = " + vformat("vec3(%.5f,%.5f,%.5f);\n", val.x, val.y, val.z); + code += "\tvec3 " + inputs[i] + " = " + vformat("vec3(%.5f, %.5f, %.5f);\n", val.x, val.y, val.z); } else if (defval.get_type() == Variant::TRANSFORM) { Transform val = defval; val.basis.transpose(); @@ -1116,7 +1152,7 @@ Error VisualShader::_write_node(Type type, StringBuilder &global_code, StringBui values.push_back(val.origin.y); values.push_back(val.origin.z); bool err = false; - code += "\tmat4 " + inputs[i] + " = " + String("mat4( vec4(%.5f,%.5f,%.5f,0.0),vec4(%.5f,%.5f,%.5f,0.0),vec4(%.5f,%.5f,%.5f,0.0),vec4(%.5f,%.5f,%.5f,1.0) );\n").sprintf(values, &err); + code += "\tmat4 " + inputs[i] + " = " + String("mat4(vec4(%.5f, %.5f, %.5f, 0.0), vec4(%.5f, %.5f, %.5f, 0.0), vec4(%.5f, %.5f, %.5f, 0.0), vec4(%.5f, %.5f, %.5f, 1.0));\n").sprintf(values, &err); } else { //will go empty, node is expected to know what it is doing at this point and handle it } @@ -1128,15 +1164,29 @@ Error VisualShader::_write_node(Type type, StringBuilder &global_code, StringBui output_vars.resize(vsnode->get_output_port_count()); String *outputs = output_vars.ptrw(); - for (int i = 0; i < output_count; i++) { + if (vsnode->is_simple_decl()) { // less code to generate for some simple_decl nodes + for (int i = 0; i < output_count; i++) { + String var_name = "n_out" + itos(node) + "p" + itos(i); + switch (vsnode->get_output_port_type(i)) { + case VisualShaderNode::PORT_TYPE_SCALAR: outputs[i] = "float " + var_name; break; + case VisualShaderNode::PORT_TYPE_VECTOR: outputs[i] = "vec3 " + var_name; break; + case VisualShaderNode::PORT_TYPE_BOOLEAN: outputs[i] = "bool " + var_name; break; + case VisualShaderNode::PORT_TYPE_TRANSFORM: outputs[i] = "mat4 " + var_name; break; + default: { + } + } + } - outputs[i] = "n_out" + itos(node) + "p" + itos(i); - switch (vsnode->get_output_port_type(i)) { - case VisualShaderNode::PORT_TYPE_SCALAR: code += String() + "\tfloat " + outputs[i] + ";\n"; break; - case VisualShaderNode::PORT_TYPE_VECTOR: code += String() + "\tvec3 " + outputs[i] + ";\n"; break; - case VisualShaderNode::PORT_TYPE_BOOLEAN: code += String() + "\tbool " + outputs[i] + ";\n"; break; - case VisualShaderNode::PORT_TYPE_TRANSFORM: code += String() + "\tmat4 " + outputs[i] + ";\n"; break; - default: { + } else { + for (int i = 0; i < output_count; i++) { + outputs[i] = "n_out" + itos(node) + "p" + itos(i); + switch (vsnode->get_output_port_type(i)) { + case VisualShaderNode::PORT_TYPE_SCALAR: code += String() + "\tfloat " + outputs[i] + ";\n"; break; + case VisualShaderNode::PORT_TYPE_VECTOR: code += String() + "\tvec3 " + outputs[i] + ";\n"; break; + case VisualShaderNode::PORT_TYPE_BOOLEAN: code += String() + "\tbool " + outputs[i] + ";\n"; break; + case VisualShaderNode::PORT_TYPE_TRANSFORM: code += String() + "\tmat4 " + outputs[i] + ";\n"; break; + default: { + } } } } @@ -1326,6 +1376,7 @@ void VisualShader::_input_type_changed(Type p_type, int p_id) { List<Connection>::Element *N = E->next(); if (E->get().from_node == p_id) { g->connections.erase(E); + g->nodes[E->get().to_node].prev_connected_nodes.erase(p_id); } E = N; } @@ -1402,8 +1453,8 @@ const VisualShaderNodeInput::Port VisualShaderNodeInput::ports[] = { { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "normal", "NORMAL" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "tangent", "TANGENT" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "binormal", "BINORMAL" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "uv2", "vec3(UV2,0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV, 0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "uv2", "vec3(UV2, 0.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "color", "COLOR.rgb" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "COLOR.a" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "point_size", "POINT_SIZE" }, @@ -1425,13 +1476,13 @@ const VisualShaderNodeInput::Port VisualShaderNodeInput::ports[] = { { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "tangent", "TANGENT" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "binormal", "BINORMAL" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "view", "VIEW" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv2", "vec3(UV2,0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV, 0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv2", "vec3(UV2, 0.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "color", "COLOR.rgb" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "COLOR.a" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "point_coord", "vec3(POINT_COORD,0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "point_coord", "vec3(POINT_COORD, 0.0)" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV,0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV, 0.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "side", "float(FRONT_FACING ? 1.0 : 0.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_TRANSFORM, "world", "WORLD_MATRIX" }, @@ -1468,7 +1519,7 @@ const VisualShaderNodeInput::Port VisualShaderNodeInput::ports[] = { { Shader::MODE_SPATIAL, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "viewport_size", "vec3(VIEWPORT_SIZE, 0.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_BOOLEAN, "output_is_srgb", "OUTPUT_IS_SRGB" }, // Canvas Item, Vertex - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "vertex", "vec3(VERTEX,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "vertex", "vec3(VERTEX, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "color", "COLOR.rgb" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "COLOR.a" }, @@ -1482,13 +1533,13 @@ const VisualShaderNodeInput::Port VisualShaderNodeInput::ports[] = { { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "light_pass", "float(AT_LIGHT_PASS ? 1.0 : 0.0)" }, // Canvas Item, Fragment { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "fragcoord", "FRAGCOORD.xyz" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "color", "COLOR.rgb" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "COLOR.a" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "texture_pixel_size", "vec3(TEXTURE_PIXEL_SIZE, 1.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_pixel_size", "vec3(SCREEN_PIXEL_SIZE, 1.0)" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "point_coord", "vec3(POINT_COORD,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "point_coord", "vec3(POINT_COORD, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "time", "TIME" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "light_pass", "float(AT_LIGHT_PASS ? 1.0 : 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SAMPLER, "texture", "TEXTURE" }, @@ -1496,19 +1547,19 @@ const VisualShaderNodeInput::Port VisualShaderNodeInput::ports[] = { { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SAMPLER, "screen_texture", "SCREEN_TEXTURE" }, // Canvas Item, Light { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "fragcoord", "FRAGCOORD.xyz" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "normal", "NORMAL" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "color", "COLOR.rgb" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "COLOR.a" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "light_vec", "vec3(LIGHT_VEC,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "light_vec", "vec3(LIGHT_VEC, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SCALAR, "light_height", "LIGHT_HEIGHT" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "light_color", "LIGHT_COLOR.rgb" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "light_alpha", "LIGHT_COLOR.a" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "light_uv", "vec3(LIGHT_UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "light_uv", "vec3(LIGHT_UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "shadow_color", "SHADOW_COLOR.rgb" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "texture_pixel_size", "vec3(TEXTURE_PIXEL_SIZE, 1.0)" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "point_coord", "vec3(POINT_COORD,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "point_coord", "vec3(POINT_COORD, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SCALAR, "time", "TIME" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SAMPLER, "texture", "TEXTURE" }, @@ -1534,48 +1585,48 @@ const VisualShaderNodeInput::Port VisualShaderNodeInput::ports[] = { const VisualShaderNodeInput::Port VisualShaderNodeInput::preview_ports[] = { // Spatial, Fragment - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "normal", "vec3(0.0,0.0,1.0)" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "tangent", "vec3(0.0,1.0,0.0)" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "binormal", "vec3(1.0,0.0,0.0)" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv2", "vec3(UV,0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "normal", "vec3(0.0, 0.0, 1.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "tangent", "vec3(0.0, 1.0, 0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "binormal", "vec3(1.0, 0.0, 0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV, 0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv2", "vec3(UV, 0.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "color", "vec3(1.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "1.0" }, - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV,0.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV, 0.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "side", "1.0" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "time", "TIME" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "viewport_size", "vec3(1.0,1.0, 0.0)" }, // Spatial, Light - { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "normal", "vec3(0.0,0.0,1.0)" }, + { Shader::MODE_SPATIAL, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "normal", "vec3(0.0, 0.0, 1.0)" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SCALAR, "time", "TIME" }, { Shader::MODE_SPATIAL, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "viewport_size", "vec3(1.0, 1.0, 0.0)" }, // Canvas Item, Vertex - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "vertex", "vec3(VERTEX,0.0)" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "vertex", "vec3(VERTEX, 0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "color", "vec3(1.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "1.0" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "time", "TIME" }, // Canvas Item, Fragment - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "color", "vec3(1.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "1.0" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "time", "TIME" }, // Canvas Item, Light - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV,0.0)" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "normal", "vec3(0.0,0.0,1.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "uv", "vec3(UV, 0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "normal", "vec3(0.0, 0.0, 1.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "color", "vec3(1.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "1.0" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV,0.0)" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "screen_uv", "vec3(SCREEN_UV, 0.0)" }, { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SCALAR, "time", "TIME" }, // Particles, Vertex { Shader::MODE_PARTICLES, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "color", "vec3(1.0)" }, { Shader::MODE_PARTICLES, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "1.0" }, - { Shader::MODE_PARTICLES, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "velocity", "vec3(0.0,0.0,1.0)" }, + { Shader::MODE_PARTICLES, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "velocity", "vec3(0.0, 0.0, 1.0)" }, { Shader::MODE_PARTICLES, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "time", "TIME" }, { Shader::MODE_MAX, VisualShader::TYPE_MAX, VisualShaderNode::PORT_TYPE_TRANSFORM, NULL, NULL }, }; @@ -1860,7 +1911,7 @@ const VisualShaderNodeOutput::Port VisualShaderNodeOutput::ports[] = { { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_FRAGMENT, VisualShaderNode::PORT_TYPE_SCALAR, "normalmap_depth", "NORMALMAP_DEPTH" }, // Canvas Item, Light { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_VECTOR, "light", "LIGHT.rgb" }, - { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SCALAR, "light_alpha", "LIGHT.rgb" }, + { Shader::MODE_CANVAS_ITEM, VisualShader::TYPE_LIGHT, VisualShaderNode::PORT_TYPE_SCALAR, "light_alpha", "LIGHT.a" }, // Particles, Vertex { Shader::MODE_PARTICLES, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_VECTOR, "color", "COLOR.rgb" }, { Shader::MODE_PARTICLES, VisualShader::TYPE_VERTEX, VisualShaderNode::PORT_TYPE_SCALAR, "alpha", "COLOR.a" }, @@ -2472,13 +2523,7 @@ void VisualShaderNodeGroupBase::_bind_methods() { ClassDB::bind_method(D_METHOD("get_free_input_port_id"), &VisualShaderNodeGroupBase::get_free_input_port_id); ClassDB::bind_method(D_METHOD("get_free_output_port_id"), &VisualShaderNodeGroupBase::get_free_output_port_id); - ClassDB::bind_method(D_METHOD("set_control", "control", "index"), &VisualShaderNodeGroupBase::set_control); - ClassDB::bind_method(D_METHOD("get_control", "index"), &VisualShaderNodeGroupBase::get_control); - - ClassDB::bind_method(D_METHOD("set_editable", "enabled"), &VisualShaderNodeGroupBase::set_editable); - ClassDB::bind_method(D_METHOD("is_editable"), &VisualShaderNodeGroupBase::is_editable); - - ADD_PROPERTY(PropertyInfo(Variant::BOOL, "editable"), "set_editable", "is_editable"); + ADD_PROPERTY(PropertyInfo(Variant::VECTOR2, "size"), "set_size", "get_size"); } String VisualShaderNodeGroupBase::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { @@ -2490,6 +2535,7 @@ VisualShaderNodeGroupBase::VisualShaderNodeGroupBase() { inputs = ""; outputs = ""; editable = false; + simple_decl = false; } ////////////// Expression @@ -2502,10 +2548,6 @@ void VisualShaderNodeExpression::set_expression(const String &p_expression) { expression = p_expression; } -void VisualShaderNodeExpression::build() { - emit_changed(); -} - String VisualShaderNodeExpression::get_expression() const { return expression; } @@ -2595,14 +2637,14 @@ String VisualShaderNodeExpression::generate_code(Shader::Mode p_mode, VisualShad default: continue; } - output_initializer += "\t" + p_output_vars[i] + "=" + tk + ";\n"; + output_initializer += "\t" + p_output_vars[i] + " = " + tk + ";\n"; } String code; code += output_initializer; code += "\t{"; code += _expression; - code += "\n\t}"; + code += "\n\t}\n"; return code; } @@ -2612,8 +2654,6 @@ void VisualShaderNodeExpression::_bind_methods() { ClassDB::bind_method(D_METHOD("set_expression", "expression"), &VisualShaderNodeExpression::set_expression); ClassDB::bind_method(D_METHOD("get_expression"), &VisualShaderNodeExpression::get_expression); - ClassDB::bind_method(D_METHOD("build"), &VisualShaderNodeExpression::build); - ADD_PROPERTY(PropertyInfo(Variant::STRING, "expression"), "set_expression", "get_expression"); } diff --git a/scene/resources/visual_shader.h b/scene/resources/visual_shader.h index 0a3d5f96bd..f35318e090 100644 --- a/scene/resources/visual_shader.h +++ b/scene/resources/visual_shader.h @@ -65,6 +65,7 @@ private: struct Node { Ref<VisualShaderNode> node; Vector2 position; + List<int> prev_connected_nodes; }; struct Graph { @@ -135,6 +136,8 @@ public: void remove_node(Type p_type, int p_id); bool is_node_connection(Type p_type, int p_from_node, int p_from_port, int p_to_node, int p_to_port) const; + + bool is_nodes_connected_relatively(const Graph *p_graph, int p_node, int p_target) const; bool can_connect_nodes(Type p_type, int p_from_node, int p_from_port, int p_to_node, int p_to_port) const; Error connect_nodes(Type p_type, int p_from_node, int p_from_port, int p_to_node, int p_to_port); void disconnect_nodes(Type p_type, int p_from_node, int p_from_port, int p_to_node, int p_to_port); @@ -172,10 +175,8 @@ class VisualShaderNode : public Resource { Map<int, Variant> default_input_values; - Array _get_default_input_values() const; - void _set_default_input_values(const Array &p_values); - protected: + bool simple_decl; static void _bind_methods(); public: @@ -188,6 +189,8 @@ public: PORT_TYPE_MAX, }; + bool is_simple_decl() const; + virtual String get_caption() const = 0; virtual int get_input_port_count() const = 0; @@ -196,6 +199,8 @@ public: void set_input_port_default_value(int p_port, const Variant &p_value); Variant get_input_port_default_value(int p_port) const; // if NIL (default if node does not set anything) is returned, it means no default value is wanted if disconnected, thus no input var must be supplied (empty string will be supplied) + Array get_default_input_values() const; + void set_default_input_values(const Array &p_values); virtual int get_output_port_count() const = 0; virtual PortType get_output_port_type(int p_port) const = 0; @@ -455,8 +460,6 @@ public: void set_expression(const String &p_expression); String get_expression() const; - void build(); - virtual String generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview = false) const; VisualShaderNodeExpression(); diff --git a/scene/resources/visual_shader_nodes.cpp b/scene/resources/visual_shader_nodes.cpp index f46fba3b5b..daf770e92a 100644 --- a/scene/resources/visual_shader_nodes.cpp +++ b/scene/resources/visual_shader_nodes.cpp @@ -187,7 +187,7 @@ String VisualShaderNodeColorConstant::get_output_port_name(int p_port) const { String VisualShaderNodeColorConstant::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { String code; - code += "\t" + p_output_vars[0] + " = " + vformat("vec3(%.6f,%.6f,%.6f)", constant.r, constant.g, constant.b) + ";\n"; + code += "\t" + p_output_vars[0] + " = " + vformat("vec3(%.6f, %.6f, %.6f)", constant.r, constant.g, constant.b) + ";\n"; code += "\t" + p_output_vars[1] + " = " + vformat("%.6f", constant.a) + ";\n"; return code; @@ -253,7 +253,7 @@ String VisualShaderNodeVec3Constant::get_output_port_name(int p_port) const { } String VisualShaderNodeVec3Constant::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = " + vformat("vec3(%.6f,%.6f,%.6f)", constant.x, constant.y, constant.z) + ";\n"; + return "\t" + p_output_vars[0] + " = " + vformat("vec3(%.6f, %.6f, %.6f)", constant.x, constant.y, constant.z) + ";\n"; } void VisualShaderNodeVec3Constant::set_constant(Vector3 p_value) { @@ -319,10 +319,10 @@ String VisualShaderNodeTransformConstant::generate_code(Shader::Mode p_mode, Vis t.basis.transpose(); String code = "\t" + p_output_vars[0] + " = mat4("; - code += vformat("vec4(%.6f,%.6f,%.6f,0.0),", t.basis[0].x, t.basis[0].y, t.basis[0].z); - code += vformat("vec4(%.6f,%.6f,%.6f,0.0),", t.basis[1].x, t.basis[1].y, t.basis[1].z); - code += vformat("vec4(%.6f,%.6f,%.6f,0.0),", t.basis[2].x, t.basis[2].y, t.basis[2].z); - code += vformat("vec4(%.6f,%.6f,%.6f,1.0) );\n", t.origin.x, t.origin.y, t.origin.z); + code += vformat("vec4(%.6f, %.6f, %.6f, 0.0), ", t.basis[0].x, t.basis[0].y, t.basis[0].z); + code += vformat("vec4(%.6f, %.6f, %.6f, 0.0), ", t.basis[1].x, t.basis[1].y, t.basis[1].z); + code += vformat("vec4(%.6f, %.6f, %.6f, 0.0), ", t.basis[2].x, t.basis[2].y, t.basis[2].z); + code += vformat("vec4(%.6f, %.6f, %.6f, 1.0));\n", t.origin.x, t.origin.y, t.origin.z); return code; } @@ -440,7 +440,7 @@ String VisualShaderNodeTexture::generate_global(Shader::Mode p_mode, VisualShade case TYPE_COLOR: u += " : hint_albedo"; break; case TYPE_NORMALMAP: u += " : hint_normal"; break; } - return u + ";"; + return u + ";\n"; } return String(); @@ -454,16 +454,16 @@ String VisualShaderNodeTexture::generate_code(Shader::Mode p_mode, VisualShader: if (p_input_vars[0] == String()) { // Use UV by default. if (p_input_vars[1] == String()) { - code += "\tvec4 " + id + "_read = texture( " + id + " , UV.xy );\n"; + code += "\tvec4 " + id + "_read = texture(" + id + ", UV.xy);\n"; } else { - code += "\tvec4 " + id + "_read = textureLod( " + id + " , UV.xy , " + p_input_vars[1] + " );\n"; + code += "\tvec4 " + id + "_read = textureLod(" + id + ", UV.xy, " + p_input_vars[1] + ");\n"; } } else if (p_input_vars[1] == String()) { //no lod - code += "\tvec4 " + id + "_read = texture( " + id + " , " + p_input_vars[0] + ".xy );\n"; + code += "\tvec4 " + id + "_read = texture(" + id + ", " + p_input_vars[0] + ".xy);\n"; } else { - code += "\tvec4 " + id + "_read = textureLod( " + id + " , " + p_input_vars[0] + ".xy , " + p_input_vars[1] + " );\n"; + code += "\tvec4 " + id + "_read = textureLod(" + id + ", " + p_input_vars[0] + ".xy, " + p_input_vars[1] + ");\n"; } code += "\t" + p_output_vars[0] + " = " + id + "_read.rgb;\n"; @@ -482,16 +482,16 @@ String VisualShaderNodeTexture::generate_code(Shader::Mode p_mode, VisualShader: if (p_input_vars[0] == String()) { // Use UV by default. if (p_input_vars[1] == String()) { - code += "\t\tvec4 " + id + "_tex_read = texture( " + id + " , UV.xy );\n"; + code += "\t\tvec4 " + id + "_tex_read = texture(" + id + ", UV.xy);\n"; } else { - code += "\t\tvec4 " + id + "_tex_read = textureLod( " + id + " , UV.xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 " + id + "_tex_read = textureLod(" + id + ", UV.xy, " + p_input_vars[1] + ");\n"; } } else if (p_input_vars[1] == String()) { //no lod - code += "\t\tvec4 " + id + "_tex_read = texture( " + id + " , " + p_input_vars[0] + ".xy );\n"; + code += "\t\tvec4 " + id + "_tex_read = texture(" + id + ", " + p_input_vars[0] + ".xy);\n"; } else { - code += "\t\tvec4 " + id + "_tex_read = textureLod( " + id + " , " + p_input_vars[0] + ".xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 " + id + "_tex_read = textureLod(" + id + ", " + p_input_vars[0] + ".xy, " + p_input_vars[1] + ");\n"; } code += "\t\t" + p_output_vars[0] + " = " + id + "_tex_read.rgb;\n"; @@ -507,16 +507,16 @@ String VisualShaderNodeTexture::generate_code(Shader::Mode p_mode, VisualShader: if (p_input_vars[0] == String() || p_for_preview) { // Use UV by default. if (p_input_vars[1] == String()) { - code += "\t\tvec4 _tex_read = textureLod( SCREEN_TEXTURE , UV.xy , 0.0 );\n"; + code += "\t\tvec4 _tex_read = textureLod(SCREEN_TEXTURE, UV.xy, 0.0 );\n"; } else { - code += "\t\tvec4 _tex_read = textureLod( SCREEN_TEXTURE , UV.xy , " + p_input_vars[1] + ");\n"; + code += "\t\tvec4 _tex_read = textureLod(SCREEN_TEXTURE, UV.xy, " + p_input_vars[1] + ");\n"; } } else if (p_input_vars[1] == String()) { //no lod - code += "\t\tvec4 _tex_read = textureLod( SCREEN_TEXTURE , " + p_input_vars[0] + ".xy , 0.0 );\n"; + code += "\t\tvec4 _tex_read = textureLod(SCREEN_TEXTURE, " + p_input_vars[0] + ".xy, 0.0);\n"; } else { - code += "\t\tvec4 _tex_read = textureLod( SCREEN_TEXTURE , " + p_input_vars[0] + ".xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 _tex_read = textureLod(SCREEN_TEXTURE, " + p_input_vars[0] + ".xy, " + p_input_vars[1] + ");\n"; } code += "\t\t" + p_output_vars[0] + " = _tex_read.rgb;\n"; @@ -531,16 +531,16 @@ String VisualShaderNodeTexture::generate_code(Shader::Mode p_mode, VisualShader: if (p_input_vars[0] == String()) { // Use UV by default. if (p_input_vars[1] == String()) { - code += "\t\tvec4 _tex_read = texture( TEXTURE , UV.xy );\n"; + code += "\t\tvec4 _tex_read = texture(TEXTURE , UV.xy);\n"; } else { - code += "\t\tvec4 _tex_read = textureLod( TEXTURE , UV.xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 _tex_read = textureLod(TEXTURE, UV.xy, " + p_input_vars[1] + ");\n"; } } else if (p_input_vars[1] == String()) { //no lod - code += "\t\tvec4 _tex_read = texture( TEXTURE , " + p_input_vars[0] + ".xy );\n"; + code += "\t\tvec4 _tex_read = texture(TEXTURE, " + p_input_vars[0] + ".xy);\n"; } else { - code += "\t\tvec4 _tex_read = textureLod( TEXTURE , " + p_input_vars[0] + ".xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 _tex_read = textureLod(TEXTURE, " + p_input_vars[0] + ".xy, " + p_input_vars[1] + ");\n"; } code += "\t\t" + p_output_vars[0] + " = _tex_read.rgb;\n"; @@ -555,16 +555,16 @@ String VisualShaderNodeTexture::generate_code(Shader::Mode p_mode, VisualShader: if (p_input_vars[0] == String()) { // Use UV by default. if (p_input_vars[1] == String()) { - code += "\t\tvec4 _tex_read = texture( NORMAL_TEXTURE , UV.xy );\n"; + code += "\t\tvec4 _tex_read = texture(NORMAL_TEXTURE, UV.xy);\n"; } else { - code += "\t\tvec4 _tex_read = textureLod( NORMAL_TEXTURE , UV.xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 _tex_read = textureLod(NORMAL_TEXTURE, UV.xy, " + p_input_vars[1] + ");\n"; } } else if (p_input_vars[1] == String()) { //no lod - code += "\t\tvec4 _tex_read = texture( NORMAL_TEXTURE , " + p_input_vars[0] + ".xy );\n"; + code += "\t\tvec4 _tex_read = texture(NORMAL_TEXTURE, " + p_input_vars[0] + ".xy);\n"; } else { - code += "\t\tvec4 _tex_read = textureLod( NORMAL_TEXTURE , " + p_input_vars[0] + ".xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 _tex_read = textureLod(NORMAL_TEXTURE, " + p_input_vars[0] + ".xy, " + p_input_vars[1] + ");\n"; } code += "\t\t" + p_output_vars[0] + " = _tex_read.rgb;\n"; @@ -589,16 +589,16 @@ String VisualShaderNodeTexture::generate_code(Shader::Mode p_mode, VisualShader: if (p_input_vars[0] == String()) { // Use UV by default. if (p_input_vars[1] == String()) { - code += "\t\tfloat _depth = texture( DEPTH_TEXTURE , UV.xy ).r;\n"; + code += "\t\tfloat _depth = texture(DEPTH_TEXTURE, UV.xy).r;\n"; } else { - code += "\t\tfloat _depth = textureLod( DEPTH_TEXTURE , UV.xy , " + p_input_vars[1] + " ).r;\n"; + code += "\t\tfloat _depth = textureLod(DEPTH_TEXTURE, UV.xy, " + p_input_vars[1] + ").r;\n"; } } else if (p_input_vars[1] == String()) { //no lod - code += "\t\tfloat _depth = texture( DEPTH_TEXTURE , " + p_input_vars[0] + ".xy ).r;\n"; + code += "\t\tfloat _depth = texture(DEPTH_TEXTURE, " + p_input_vars[0] + ".xy).r;\n"; } else { - code += "\t\tfloat _depth = textureLod( DEPTH_TEXTURE , " + p_input_vars[0] + ".xy , " + p_input_vars[1] + " ).r;\n"; + code += "\t\tfloat _depth = textureLod(DEPTH_TEXTURE, " + p_input_vars[0] + ".xy, " + p_input_vars[1] + ").r;\n"; } code += "\t\t" + p_output_vars[0] + " = _depth;\n"; @@ -621,6 +621,26 @@ String VisualShaderNodeTexture::generate_code(Shader::Mode p_mode, VisualShader: void VisualShaderNodeTexture::set_source(Source p_source) { source = p_source; + switch (source) { + case SOURCE_TEXTURE: + simple_decl = true; + break; + case SOURCE_SCREEN: + simple_decl = false; + break; + case SOURCE_2D_TEXTURE: + simple_decl = false; + break; + case SOURCE_2D_NORMAL: + simple_decl = false; + break; + case SOURCE_DEPTH: + simple_decl = false; + break; + case SOURCE_PORT: + simple_decl = false; + break; + } emit_changed(); emit_signal("editor_refresh_request"); } @@ -792,7 +812,7 @@ String VisualShaderNodeCubeMap::generate_global(Shader::Mode p_mode, VisualShade case TYPE_COLOR: u += " : hint_albedo"; break; case TYPE_NORMALMAP: u += " : hint_normal"; break; } - return u + ";"; + return u + ";\n"; } return String(); } @@ -809,29 +829,33 @@ String VisualShaderNodeCubeMap::generate_code(Shader::Mode p_mode, VisualShader: return String(); } + code += "\t{\n"; + if (id == String()) { - code += "\tvec4 " + id + "_read = vec4(0.0);\n"; - code += "\t" + p_output_vars[0] + " = " + id + "_read.rgb;\n"; - code += "\t" + p_output_vars[1] + " = " + id + "_read.a;\n"; + code += "\t\tvec4 " + id + "_read = vec4(0.0);\n"; + code += "\t\t" + p_output_vars[0] + " = " + id + "_read.rgb;\n"; + code += "\t\t" + p_output_vars[1] + " = " + id + "_read.a;\n"; + code += "\t}\n"; return code; } if (p_input_vars[0] == String()) { // Use UV by default. if (p_input_vars[1] == String()) { - code += "\tvec4 " + id + "_read = texture( " + id + " , vec3( UV, 0.0 ) );\n"; + code += "\t\tvec4 " + id + "_read = texture(" + id + " , vec3(UV, 0.0));\n"; } else { - code += "\tvec4 " + id + "_read = textureLod( " + id + " , vec3( UV, 0.0 )" + " , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 " + id + "_read = textureLod(" + id + " , vec3(UV, 0.0)" + " , " + p_input_vars[1] + " );\n"; } } else if (p_input_vars[1] == String()) { //no lod - code += "\tvec4 " + id + "_read = texture( " + id + " , " + p_input_vars[0] + " );\n"; + code += "\t\tvec4 " + id + "_read = texture(" + id + ", " + p_input_vars[0] + ");\n"; } else { - code += "\tvec4 " + id + "_read = textureLod( " + id + " , " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 " + id + "_read = textureLod(" + id + ", " + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; } - code += "\t" + p_output_vars[0] + " = " + id + "_read.rgb;\n"; - code += "\t" + p_output_vars[1] + " = " + id + "_read.a;\n"; + code += "\t\t" + p_output_vars[0] + " = " + id + "_read.rgb;\n"; + code += "\t\t" + p_output_vars[1] + " = " + id + "_read.a;\n"; + code += "\t}\n"; return code; } @@ -909,6 +933,7 @@ void VisualShaderNodeCubeMap::_bind_methods() { VisualShaderNodeCubeMap::VisualShaderNodeCubeMap() { texture_type = TYPE_DATA; source = SOURCE_TEXTURE; + simple_decl = false; } ////////////// Scalar Op @@ -950,12 +975,12 @@ String VisualShaderNodeScalarOp::generate_code(Shader::Mode p_mode, VisualShader case OP_SUB: code += p_input_vars[0] + " - " + p_input_vars[1] + ";\n"; break; case OP_MUL: code += p_input_vars[0] + " * " + p_input_vars[1] + ";\n"; break; case OP_DIV: code += p_input_vars[0] + " / " + p_input_vars[1] + ";\n"; break; - case OP_MOD: code += "mod( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_POW: code += "pow( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_MAX: code += "max( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_MIN: code += "min( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_ATAN2: code += "atan( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_STEP: code += "step( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; + case OP_MOD: code += "mod(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_POW: code += "pow(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_MAX: code += "max(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_MIN: code += "min(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_ATAN2: code += "atan(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_STEP: code += "step(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; } return code; @@ -1042,14 +1067,14 @@ String VisualShaderNodeVectorOp::generate_code(Shader::Mode p_mode, VisualShader case OP_SUB: code += p_input_vars[0] + " - " + p_input_vars[1] + ";\n"; break; case OP_MUL: code += p_input_vars[0] + " * " + p_input_vars[1] + ";\n"; break; case OP_DIV: code += p_input_vars[0] + " / " + p_input_vars[1] + ";\n"; break; - case OP_MOD: code += "mod( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_POW: code += "pow( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_MAX: code += "max( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_MIN: code += "min( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_CROSS: code += "cross( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_ATAN2: code += "atan( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_REFLECT: code += "reflect( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; - case OP_STEP: code += "step( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; break; + case OP_MOD: code += "mod(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_POW: code += "pow(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_MAX: code += "max(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_MIN: code += "min(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_CROSS: code += "cross(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_ATAN2: code += "atan(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_REFLECT: code += "reflect(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; + case OP_STEP: code += "step(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; break; } return code; @@ -1136,27 +1161,27 @@ String VisualShaderNodeColorOp::generate_code(Shader::Mode p_mode, VisualShader: switch (op) { case OP_SCREEN: { - code += "\t" + p_output_vars[0] + "=vec3(1.0)-(vec3(1.0)-" + p_input_vars[0] + ")*(vec3(1.0)-" + p_input_vars[1] + ");\n"; + code += "\t" + p_output_vars[0] + " = vec3(1.0) - (vec3(1.0) - " + p_input_vars[0] + ") * (vec3(1.0) - " + p_input_vars[1] + ");\n"; } break; case OP_DIFFERENCE: { - code += "\t" + p_output_vars[0] + "=abs(" + p_input_vars[0] + "-" + p_input_vars[1] + ");\n"; + code += "\t" + p_output_vars[0] + " = abs(" + p_input_vars[0] + " - " + p_input_vars[1] + ");\n"; } break; case OP_DARKEN: { - code += "\t" + p_output_vars[0] + "=min(" + p_input_vars[0] + "," + p_input_vars[1] + ");\n"; + code += "\t" + p_output_vars[0] + " = min(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; } break; case OP_LIGHTEN: { - code += "\t" + p_output_vars[0] + "=max(" + p_input_vars[0] + "," + p_input_vars[1] + ");\n"; + code += "\t" + p_output_vars[0] + " = max(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; } break; case OP_OVERLAY: { for (int i = 0; i < 3; i++) { code += "\t{\n"; - code += "\t\tfloat base=" + p_input_vars[0] + "." + axisn[i] + ";\n"; - code += "\t\tfloat blend=" + p_input_vars[1] + "." + axisn[i] + ";\n"; + code += "\t\tfloat base = " + p_input_vars[0] + "." + axisn[i] + ";\n"; + code += "\t\tfloat blend = " + p_input_vars[1] + "." + axisn[i] + ";\n"; code += "\t\tif (base < 0.5) {\n"; code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = 2.0 * base * blend;\n"; code += "\t\t} else {\n"; @@ -1168,23 +1193,23 @@ String VisualShaderNodeColorOp::generate_code(Shader::Mode p_mode, VisualShader: } break; case OP_DODGE: { - code += "\t" + p_output_vars[0] + "=(" + p_input_vars[0] + ")/(vec3(1.0)-" + p_input_vars[1] + ");\n"; + code += "\t" + p_output_vars[0] + " = (" + p_input_vars[0] + ") / (vec3(1.0) - " + p_input_vars[1] + ");\n"; } break; case OP_BURN: { - code += "\t" + p_output_vars[0] + "=vec3(1.0)-(vec3(1.0)-" + p_input_vars[0] + ")/(" + p_input_vars[1] + ");\n"; + code += "\t" + p_output_vars[0] + " = vec3(1.0) - (vec3(1.0) - " + p_input_vars[0] + ") / (" + p_input_vars[1] + ");\n"; } break; case OP_SOFT_LIGHT: { for (int i = 0; i < 3; i++) { code += "\t{\n"; - code += "\t\tfloat base=" + p_input_vars[0] + "." + axisn[i] + ";\n"; - code += "\t\tfloat blend=" + p_input_vars[1] + "." + axisn[i] + ";\n"; + code += "\t\tfloat base = " + p_input_vars[0] + "." + axisn[i] + ";\n"; + code += "\t\tfloat blend = " + p_input_vars[1] + "." + axisn[i] + ";\n"; code += "\t\tif (base < 0.5) {\n"; - code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = (base * (blend+0.5));\n"; + code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = (base * (blend + 0.5));\n"; code += "\t\t} else {\n"; - code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = (1.0 - (1.0-base) * (1.0-(blend-0.5)));\n"; + code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = (1.0 - (1.0 - base) * (1.0 - (blend - 0.5)));\n"; code += "\t\t}\n"; code += "\t}\n"; } @@ -1194,12 +1219,12 @@ String VisualShaderNodeColorOp::generate_code(Shader::Mode p_mode, VisualShader: for (int i = 0; i < 3; i++) { code += "\t{\n"; - code += "\t\tfloat base=" + p_input_vars[0] + "." + axisn[i] + ";\n"; - code += "\t\tfloat blend=" + p_input_vars[1] + "." + axisn[i] + ";\n"; + code += "\t\tfloat base = " + p_input_vars[0] + "." + axisn[i] + ";\n"; + code += "\t\tfloat blend = " + p_input_vars[1] + "." + axisn[i] + ";\n"; code += "\t\tif (base < 0.5) {\n"; - code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = (base * (2.0*blend));\n"; + code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = (base * (2.0 * blend));\n"; code += "\t\t} else {\n"; - code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = (1.0 - (1.0-base) * (1.0-2.0*(blend-0.5)));\n"; + code += "\t\t\t" + p_output_vars[0] + "." + axisn[i] + " = (1.0 - (1.0 - base) * (1.0 - 2.0 * (blend - 0.5)));\n"; code += "\t\t}\n"; code += "\t}\n"; } @@ -1213,6 +1238,35 @@ String VisualShaderNodeColorOp::generate_code(Shader::Mode p_mode, VisualShader: void VisualShaderNodeColorOp::set_operator(Operator p_op) { op = p_op; + switch (op) { + case OP_SCREEN: + simple_decl = true; + break; + case OP_DIFFERENCE: + simple_decl = true; + break; + case OP_DARKEN: + simple_decl = true; + break; + case OP_LIGHTEN: + simple_decl = true; + break; + case OP_OVERLAY: + simple_decl = false; + break; + case OP_DODGE: + simple_decl = true; + break; + case OP_BURN: + simple_decl = true; + break; + case OP_SOFT_LIGHT: + simple_decl = false; + break; + case OP_HARD_LIGHT: + simple_decl = false; + break; + } emit_changed(); } @@ -1288,9 +1342,9 @@ String VisualShaderNodeTransformMult::generate_code(Shader::Mode p_mode, VisualS } else if (op == OP_BxA) { return "\t" + p_output_vars[0] + " = " + p_input_vars[1] + " * " + p_input_vars[0] + ";\n"; } else if (op == OP_AxB_COMP) { - return "\t" + p_output_vars[0] + " = matrixCompMult( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; + return "\t" + p_output_vars[0] + " = matrixCompMult(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; } else { - return "\t" + p_output_vars[0] + " = matrixCompMult( " + p_input_vars[1] + " , " + p_input_vars[0] + " );\n"; + return "\t" + p_output_vars[0] + " = matrixCompMult(" + p_input_vars[1] + ", " + p_input_vars[0] + ");\n"; } } @@ -1362,13 +1416,13 @@ String VisualShaderNodeTransformVecMult::get_output_port_name(int p_port) const String VisualShaderNodeTransformVecMult::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { if (op == OP_AxB) { - return "\t" + p_output_vars[0] + " = ( " + p_input_vars[0] + " * vec4(" + p_input_vars[1] + ", 1.0) ).xyz;\n"; + return "\t" + p_output_vars[0] + " = (" + p_input_vars[0] + " * vec4(" + p_input_vars[1] + ", 1.0)).xyz;\n"; } else if (op == OP_BxA) { - return "\t" + p_output_vars[0] + " = ( vec4(" + p_input_vars[1] + ", 1.0) * " + p_input_vars[0] + " ).xyz;\n"; + return "\t" + p_output_vars[0] + " = (vec4(" + p_input_vars[1] + ", 1.0) * " + p_input_vars[0] + ").xyz;\n"; } else if (op == OP_3x3_AxB) { - return "\t" + p_output_vars[0] + " = ( " + p_input_vars[0] + " * vec4(" + p_input_vars[1] + ", 0.0) ).xyz;\n"; + return "\t" + p_output_vars[0] + " = (" + p_input_vars[0] + " * vec4(" + p_input_vars[1] + ", 0.0)).xyz;\n"; } else { - return "\t" + p_output_vars[0] + " = ( vec4(" + p_input_vars[1] + ", 0.0) * " + p_input_vars[0] + " ).xyz;\n"; + return "\t" + p_output_vars[0] + " = (vec4(" + p_input_vars[1] + ", 0.0) * " + p_input_vars[0] + ").xyz;\n"; } } @@ -1459,7 +1513,7 @@ String VisualShaderNodeScalarFunc::generate_code(Shader::Mode p_mode, VisualShad "round($)", "ceil($)", "fract($)", - "min(max($,0.0),1.0)", + "min(max($, 0.0), 1.0)", "-($)", "acosh($)", "asinh($)", @@ -1469,10 +1523,10 @@ String VisualShaderNodeScalarFunc::generate_code(Shader::Mode p_mode, VisualShad "inversesqrt($)", "log2($)", "radians($)", - "1.0/($)", + "1.0 / ($)", "roundEven($)", "trunc($)", - "1.0-$" + "1.0 - $" }; return "\t" + p_output_vars[0] + " = " + String(scalar_func_id[func]).replace("$", p_input_vars[0]) + ";\n"; @@ -1575,9 +1629,9 @@ String VisualShaderNodeVectorFunc::generate_code(Shader::Mode p_mode, VisualShad static const char *vec_func_id[FUNC_ONEMINUS + 1] = { "normalize($)", - "max(min($,vec3(1.0)),vec3(0.0))", + "max(min($, vec3(1.0)), vec3(0.0))", "-($)", - "1.0/($)", + "1.0 / ($)", "", "", "abs($)", @@ -1608,7 +1662,7 @@ String VisualShaderNodeVectorFunc::generate_code(Shader::Mode p_mode, VisualShad "tan($)", "tanh($)", "trunc($)", - "vec3(1.0, 1.0, 1.0)-$" + "vec3(1.0, 1.0, 1.0) - $" }; String code; @@ -1621,18 +1675,18 @@ String VisualShaderNodeVectorFunc::generate_code(Shader::Mode p_mode, VisualShad code += "\t\tvec4 q = mix(vec4(p.xyw, c.r), vec4(c.r, p.yzx), step(p.x, c.r));\n"; code += "\t\tfloat d = q.x - min(q.w, q.y);\n"; code += "\t\tfloat e = 1.0e-10;\n"; - code += "\t\t" + p_output_vars[0] + "=vec3(abs(q.z + (q.w - q.y) / (6.0 * d + e)), d / (q.x + e), q.x);\n"; + code += "\t\t" + p_output_vars[0] + " = vec3(abs(q.z + (q.w - q.y) / (6.0 * d + e)), d / (q.x + e), q.x);\n"; code += "\t}\n"; } else if (func == FUNC_HSV2RGB) { code += "\t{\n"; code += "\t\tvec3 c = " + p_input_vars[0] + ";\n"; code += "\t\tvec4 K = vec4(1.0, 2.0 / 3.0, 1.0 / 3.0, 3.0);\n"; code += "\t\tvec3 p = abs(fract(c.xxx + K.xyz) * 6.0 - K.www);\n"; - code += "\t\t" + p_output_vars[0] + "=c.z * mix(K.xxx, clamp(p - K.xxx, 0.0, 1.0), c.y);\n"; + code += "\t\t" + p_output_vars[0] + " = c.z * mix(K.xxx, clamp(p - K.xxx, 0.0, 1.0), c.y);\n"; code += "\t}\n"; } else { - code += "\t" + p_output_vars[0] + "=" + String(vec_func_id[func]).replace("$", p_input_vars[0]) + ";\n"; + code += "\t" + p_output_vars[0] + " = " + String(vec_func_id[func]).replace("$", p_input_vars[0]) + ";\n"; } return code; @@ -1641,6 +1695,13 @@ String VisualShaderNodeVectorFunc::generate_code(Shader::Mode p_mode, VisualShad void VisualShaderNodeVectorFunc::set_function(Function p_func) { func = p_func; + if (func == FUNC_RGB2HSV) { + simple_decl = false; + } else if (func == FUNC_HSV2RGB) { + simple_decl = false; + } else { + simple_decl = true; + } emit_changed(); } @@ -1793,6 +1854,7 @@ void VisualShaderNodeColorFunc::_bind_methods() { VisualShaderNodeColorFunc::VisualShaderNodeColorFunc() { func = FUNC_GRAYSCALE; set_input_port_default_value(0, Vector3()); + simple_decl = false; } ////////////// Transform Func @@ -1833,7 +1895,7 @@ String VisualShaderNodeTransformFunc::generate_code(Shader::Mode p_mode, VisualS }; String code; - code += "\t" + p_output_vars[0] + "=" + String(funcs[func]).replace("$", p_input_vars[0]) + ";\n"; + code += "\t" + p_output_vars[0] + " = " + String(funcs[func]).replace("$", p_input_vars[0]) + ";\n"; return code; } @@ -1901,7 +1963,7 @@ String VisualShaderNodeDotProduct::get_output_port_name(int p_port) const { } String VisualShaderNodeDotProduct::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = dot( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; + return "\t" + p_output_vars[0] + " = dot(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; } VisualShaderNodeDotProduct::VisualShaderNodeDotProduct() { @@ -1940,7 +2002,7 @@ String VisualShaderNodeVectorLen::get_output_port_name(int p_port) const { } String VisualShaderNodeVectorLen::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = length( " + p_input_vars[0] + " );\n"; + return "\t" + p_output_vars[0] + " = length(" + p_input_vars[0] + ");\n"; } VisualShaderNodeVectorLen::VisualShaderNodeVectorLen() { @@ -1978,7 +2040,7 @@ String VisualShaderNodeDeterminant::get_output_port_name(int p_port) const { } String VisualShaderNodeDeterminant::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = determinant( " + p_input_vars[0] + " );\n"; + return "\t" + p_output_vars[0] + " = determinant(" + p_input_vars[0] + ");\n"; } VisualShaderNodeDeterminant::VisualShaderNodeDeterminant() { @@ -2024,7 +2086,7 @@ String VisualShaderNodeScalarDerivativeFunc::generate_code(Shader::Mode p_mode, }; String code; - code += "\t" + p_output_vars[0] + "=" + String(funcs[func]).replace("$", p_input_vars[0]) + ";\n"; + code += "\t" + p_output_vars[0] + " = " + String(funcs[func]).replace("$", p_input_vars[0]) + ";\n"; return code; } @@ -2101,7 +2163,7 @@ String VisualShaderNodeVectorDerivativeFunc::generate_code(Shader::Mode p_mode, }; String code; - code += "\t" + p_output_vars[0] + "=" + String(funcs[func]).replace("$", p_input_vars[0]) + ";\n"; + code += "\t" + p_output_vars[0] + " = " + String(funcs[func]).replace("$", p_input_vars[0]) + ";\n"; return code; } @@ -2176,7 +2238,7 @@ String VisualShaderNodeScalarClamp::get_output_port_name(int p_port) const { } String VisualShaderNodeScalarClamp::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = clamp( " + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = clamp(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeScalarClamp::VisualShaderNodeScalarClamp() { @@ -2222,7 +2284,7 @@ String VisualShaderNodeVectorClamp::get_output_port_name(int p_port) const { } String VisualShaderNodeVectorClamp::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = clamp( " + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = clamp(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeVectorClamp::VisualShaderNodeVectorClamp() { @@ -2271,7 +2333,7 @@ String VisualShaderNodeFaceForward::get_output_port_name(int p_port) const { } String VisualShaderNodeFaceForward::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = faceforward( " + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = faceforward(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeFaceForward::VisualShaderNodeFaceForward() { @@ -2318,7 +2380,7 @@ String VisualShaderNodeOuterProduct::get_output_port_name(int p_port) const { } String VisualShaderNodeOuterProduct::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = outerProduct( vec4(" + p_input_vars[0] + ", 0.0), vec4(" + p_input_vars[1] + ", 0.0) );\n"; + return "\t" + p_output_vars[0] + " = outerProduct(vec4(" + p_input_vars[0] + ", 0.0), vec4(" + p_input_vars[1] + ", 0.0));\n"; } VisualShaderNodeOuterProduct::VisualShaderNodeOuterProduct() { @@ -2364,7 +2426,7 @@ String VisualShaderNodeVectorScalarStep::get_output_port_name(int p_port) const } String VisualShaderNodeVectorScalarStep::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = step( " + p_input_vars[0] + ", " + p_input_vars[1] + " );\n"; + return "\t" + p_output_vars[0] + " = step(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; } VisualShaderNodeVectorScalarStep::VisualShaderNodeVectorScalarStep() { @@ -2409,7 +2471,7 @@ String VisualShaderNodeScalarSmoothStep::get_output_port_name(int p_port) const } String VisualShaderNodeScalarSmoothStep::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = smoothstep( " + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = smoothstep(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeScalarSmoothStep::VisualShaderNodeScalarSmoothStep() { @@ -2455,7 +2517,7 @@ String VisualShaderNodeVectorSmoothStep::get_output_port_name(int p_port) const } String VisualShaderNodeVectorSmoothStep::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = smoothstep( " + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = smoothstep(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeVectorSmoothStep::VisualShaderNodeVectorSmoothStep() { @@ -2506,7 +2568,7 @@ String VisualShaderNodeVectorScalarSmoothStep::get_output_port_name(int p_port) } String VisualShaderNodeVectorScalarSmoothStep::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = smoothstep( " + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = smoothstep(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeVectorScalarSmoothStep::VisualShaderNodeVectorScalarSmoothStep() { @@ -2551,7 +2613,7 @@ String VisualShaderNodeVectorDistance::get_output_port_name(int p_port) const { } String VisualShaderNodeVectorDistance::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = distance( " + p_input_vars[0] + " , " + p_input_vars[1] + " );\n"; + return "\t" + p_output_vars[0] + " = distance(" + p_input_vars[0] + ", " + p_input_vars[1] + ");\n"; } VisualShaderNodeVectorDistance::VisualShaderNodeVectorDistance() { @@ -2602,7 +2664,7 @@ String VisualShaderNodeVectorRefract::get_output_port_name(int p_port) const { } String VisualShaderNodeVectorRefract::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = refract( " + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = refract(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeVectorRefract::VisualShaderNodeVectorRefract() { @@ -2648,7 +2710,7 @@ String VisualShaderNodeScalarInterp::get_output_port_name(int p_port) const { } String VisualShaderNodeScalarInterp::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = mix( " + p_input_vars[0] + " , " + p_input_vars[1] + " , " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = mix(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeScalarInterp::VisualShaderNodeScalarInterp() { @@ -2694,7 +2756,7 @@ String VisualShaderNodeVectorInterp::get_output_port_name(int p_port) const { } String VisualShaderNodeVectorInterp::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = mix( " + p_input_vars[0] + " , " + p_input_vars[1] + " , " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = mix(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeVectorInterp::VisualShaderNodeVectorInterp() { @@ -2742,7 +2804,7 @@ String VisualShaderNodeVectorScalarMix::get_output_port_name(int p_port) const { } String VisualShaderNodeVectorScalarMix::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = mix( " + p_input_vars[0] + " , " + p_input_vars[1] + " , " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = mix(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeVectorScalarMix::VisualShaderNodeVectorScalarMix() { @@ -2788,7 +2850,7 @@ String VisualShaderNodeVectorCompose::get_output_port_name(int p_port) const { } String VisualShaderNodeVectorCompose::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = vec3( " + p_input_vars[0] + " , " + p_input_vars[1] + " , " + p_input_vars[2] + " );\n"; + return "\t" + p_output_vars[0] + " = vec3(" + p_input_vars[0] + ", " + p_input_vars[1] + ", " + p_input_vars[2] + ");\n"; } VisualShaderNodeVectorCompose::VisualShaderNodeVectorCompose() { @@ -2837,7 +2899,7 @@ String VisualShaderNodeTransformCompose::get_output_port_name(int p_port) const } String VisualShaderNodeTransformCompose::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { - return "\t" + p_output_vars[0] + " = mat4( vec4(" + p_input_vars[0] + ", 0.0) , vec4(" + p_input_vars[1] + ", 0.0) , vec4(" + p_input_vars[2] + ",0.0), vec4(" + p_input_vars[3] + ",1.0) );\n"; + return "\t" + p_output_vars[0] + " = mat4(vec4(" + p_input_vars[0] + ", 0.0), vec4(" + p_input_vars[1] + ", 0.0), vec4(" + p_input_vars[2] + ", 0.0), vec4(" + p_input_vars[3] + ", 1.0));\n"; } VisualShaderNodeTransformCompose::VisualShaderNodeTransformCompose() { @@ -3233,15 +3295,15 @@ String VisualShaderNodeTextureUniform::generate_code(Shader::Mode p_mode, Visual String code = "\t{\n"; if (p_input_vars[0] == String()) { // Use UV by default. if (p_input_vars[1] == String()) { - code += "\t\tvec4 n_tex_read = texture( " + id + " , UV.xy );\n"; + code += "\t\tvec4 n_tex_read = texture(" + id + ", UV.xy);\n"; } else { - code += "\t\tvec4 n_tex_read = textureLod( " + id + " , UV.xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 n_tex_read = textureLod(" + id + ", UV.xy, " + p_input_vars[1] + ");\n"; } } else if (p_input_vars[1] == String()) { //no lod - code += "\t\tvec4 n_tex_read = texture( " + id + " , " + p_input_vars[0] + ".xy );\n"; + code += "\t\tvec4 n_tex_read = texture(" + id + ", " + p_input_vars[0] + ".xy);\n"; } else { - code += "\t\tvec4 n_tex_read = textureLod( " + id + " , " + p_input_vars[0] + ".xy , " + p_input_vars[1] + " );\n"; + code += "\t\tvec4 n_tex_read = textureLod(" + id + ", " + p_input_vars[0] + ".xy, " + p_input_vars[1] + ");\n"; } code += "\t\t" + p_output_vars[0] + " = n_tex_read.rgb;\n"; @@ -3305,6 +3367,7 @@ String VisualShaderNodeTextureUniform::get_input_port_default_hint(int p_port) c VisualShaderNodeTextureUniform::VisualShaderNodeTextureUniform() { texture_type = TYPE_DATA; color_default = COLOR_DEFAULT_WHITE; + simple_decl = false; } ////////////// Texture Uniform (Triplanar) @@ -3523,17 +3586,17 @@ String VisualShaderNodeIf::get_output_port_name(int p_port) const { String VisualShaderNodeIf::generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview) const { String code; - code += "\tif(abs(" + p_input_vars[0] + "-" + p_input_vars[1] + ")<" + p_input_vars[2] + ")\n"; // abs(a - b) < tolerance eg. a == b + code += "\tif(abs(" + p_input_vars[0] + " - " + p_input_vars[1] + ") < " + p_input_vars[2] + ")\n"; // abs(a - b) < tolerance eg. a == b code += "\t{\n"; - code += "\t\t" + p_output_vars[0] + "=" + p_input_vars[3] + ";\n"; + code += "\t\t" + p_output_vars[0] + " = " + p_input_vars[3] + ";\n"; code += "\t}\n"; - code += "\telse if(" + p_input_vars[0] + "<" + p_input_vars[1] + ")\n"; // a < b + code += "\telse if(" + p_input_vars[0] + " < " + p_input_vars[1] + ")\n"; // a < b code += "\t{\n"; - code += "\t\t" + p_output_vars[0] + "=" + p_input_vars[5] + ";\n"; + code += "\t\t" + p_output_vars[0] + " = " + p_input_vars[5] + ";\n"; code += "\t}\n"; code += "\telse\n"; // a > b (or a >= b if abs(a - b) < tolerance is false) code += "\t{\n"; - code += "\t\t" + p_output_vars[0] + "=" + p_input_vars[4] + ";\n"; + code += "\t\t" + p_output_vars[0] + " = " + p_input_vars[4] + ";\n"; code += "\t}\n"; return code; } @@ -3545,6 +3608,7 @@ VisualShaderNodeIf::VisualShaderNodeIf() { set_input_port_default_value(3, Vector3(0.0, 0.0, 0.0)); set_input_port_default_value(4, Vector3(0.0, 0.0, 0.0)); set_input_port_default_value(5, Vector3(0.0, 0.0, 0.0)); + simple_decl = false; } ////////////// Switch @@ -3594,11 +3658,11 @@ String VisualShaderNodeSwitch::generate_code(Shader::Mode p_mode, VisualShader:: String code; code += "\tif(" + p_input_vars[0] + ")\n"; code += "\t{\n"; - code += "\t\t" + p_output_vars[0] + "=" + p_input_vars[1] + ";\n"; + code += "\t\t" + p_output_vars[0] + " = " + p_input_vars[1] + ";\n"; code += "\t}\n"; code += "\telse\n"; code += "\t{\n"; - code += "\t\t" + p_output_vars[0] + "=" + p_input_vars[2] + ";\n"; + code += "\t\t" + p_output_vars[0] + " = " + p_input_vars[2] + ";\n"; code += "\t}\n"; return code; } @@ -3607,6 +3671,7 @@ VisualShaderNodeSwitch::VisualShaderNodeSwitch() { set_input_port_default_value(0, false); set_input_port_default_value(1, Vector3(1.0, 1.0, 1.0)); set_input_port_default_value(2, Vector3(0.0, 0.0, 0.0)); + simple_decl = false; } ////////////// Switch(scalar) @@ -3699,7 +3764,7 @@ String VisualShaderNodeFresnel::generate_code(Shader::Mode p_mode, VisualShader: view = p_input_vars[1]; } - return "\t" + p_output_vars[0] + " = " + p_input_vars[2] + " ? (pow(clamp(dot(" + normal + ", " + view + "), 0.0, 1.0), " + p_input_vars[3] + ")) : (pow(1.0 - clamp(dot(" + normal + ", " + view + "), 0.0, 1.0), " + p_input_vars[3] + "));"; + return "\t" + p_output_vars[0] + " = " + p_input_vars[2] + " ? (pow(clamp(dot(" + normal + ", " + view + "), 0.0, 1.0), " + p_input_vars[3] + ")) : (pow(1.0 - clamp(dot(" + normal + ", " + view + "), 0.0, 1.0), " + p_input_vars[3] + "));\n"; } String VisualShaderNodeFresnel::get_input_port_default_hint(int p_port) const { @@ -3761,7 +3826,7 @@ String VisualShaderNodeIs::generate_code(Shader::Mode p_mode, VisualShader::Type }; String code; - code += "\t" + p_output_vars[0] + "=" + String(funcs[func]).replace("$", p_input_vars[0]) + ";\n"; + code += "\t" + p_output_vars[0] + " = " + String(funcs[func]).replace("$", p_input_vars[0]) + ";\n"; return code; } @@ -3896,31 +3961,31 @@ String VisualShaderNodeCompare::generate_code(Shader::Mode p_mode, VisualShader: switch (ctype) { case CTYPE_SCALAR: if (func == FUNC_EQUAL) { - code += "\t" + p_output_vars[0] + "=(abs(" + p_input_vars[0] + "-" + p_input_vars[1] + ")<" + p_input_vars[2] + ");"; + code += "\t" + p_output_vars[0] + " = (abs(" + p_input_vars[0] + " - " + p_input_vars[1] + ") < " + p_input_vars[2] + ");"; } else if (func == FUNC_NOT_EQUAL) { - code += "\t" + p_output_vars[0] + "=!(abs(" + p_input_vars[0] + "-" + p_input_vars[1] + ")<" + p_input_vars[2] + ");"; + code += "\t" + p_output_vars[0] + " = !(abs(" + p_input_vars[0] + " - " + p_input_vars[1] + ") < " + p_input_vars[2] + ");"; } else { - code += "\t" + p_output_vars[0] + "=" + (p_input_vars[0] + "$" + p_input_vars[1]).replace("$", ops[func]) + ";\n"; + code += "\t" + p_output_vars[0] + " = " + (p_input_vars[0] + "$" + p_input_vars[1]).replace("$", ops[func]) + ";\n"; } break; case CTYPE_VECTOR: code += "\t{\n"; - code += "\t\tbvec3 _bv=" + String(funcs[func]).replace("$", p_input_vars[0] + ", " + p_input_vars[1]) + ";\n"; - code += "\t\t" + p_output_vars[0] + "=" + String(conds[condition]).replace("$", "_bv") + ";\n"; + code += "\t\tbvec3 _bv = " + String(funcs[func]).replace("$", p_input_vars[0] + ", " + p_input_vars[1]) + ";\n"; + code += "\t\t" + p_output_vars[0] + " = " + String(conds[condition]).replace("$", "_bv") + ";\n"; code += "\t}\n"; break; case CTYPE_BOOLEAN: if (func > FUNC_NOT_EQUAL) - return "\t" + p_output_vars[0] + "=false;\n"; - code += "\t" + p_output_vars[0] + "=" + (p_input_vars[0] + "$" + p_input_vars[1]).replace("$", ops[func]) + ";\n"; + return "\t" + p_output_vars[0] + " = false;\n"; + code += "\t" + p_output_vars[0] + " = " + (p_input_vars[0] + " $ " + p_input_vars[1]).replace("$", ops[func]) + ";\n"; break; case CTYPE_TRANSFORM: if (func > FUNC_NOT_EQUAL) - return "\t" + p_output_vars[0] + "=false;\n"; - code += "\t" + p_output_vars[0] + "=" + (p_input_vars[0] + "$" + p_input_vars[1]).replace("$", ops[func]) + ";\n"; + return "\t" + p_output_vars[0] + " = false;\n"; + code += "\t" + p_output_vars[0] + " = " + (p_input_vars[0] + " $ " + p_input_vars[1]).replace("$", ops[func]) + ";\n"; break; default: @@ -3929,7 +3994,7 @@ String VisualShaderNodeCompare::generate_code(Shader::Mode p_mode, VisualShader: return code; } -void VisualShaderNodeCompare::set_comparsion_type(ComparsionType p_type) { +void VisualShaderNodeCompare::set_comparison_type(ComparisonType p_type) { ctype = p_type; @@ -3937,24 +4002,28 @@ void VisualShaderNodeCompare::set_comparsion_type(ComparsionType p_type) { case CTYPE_SCALAR: set_input_port_default_value(0, 0.0); set_input_port_default_value(1, 0.0); + simple_decl = true; break; case CTYPE_VECTOR: set_input_port_default_value(0, Vector3(0.0, 0.0, 0.0)); set_input_port_default_value(1, Vector3(0.0, 0.0, 0.0)); + simple_decl = false; break; case CTYPE_BOOLEAN: set_input_port_default_value(0, false); set_input_port_default_value(1, false); + simple_decl = true; break; case CTYPE_TRANSFORM: set_input_port_default_value(0, Transform()); set_input_port_default_value(1, Transform()); + simple_decl = true; break; } emit_changed(); } -VisualShaderNodeCompare::ComparsionType VisualShaderNodeCompare::get_comparsion_type() const { +VisualShaderNodeCompare::ComparisonType VisualShaderNodeCompare::get_comparison_type() const { return ctype; } @@ -3992,8 +4061,8 @@ Vector<StringName> VisualShaderNodeCompare::get_editable_properties() const { void VisualShaderNodeCompare::_bind_methods() { - ClassDB::bind_method(D_METHOD("set_comparsion_type", "type"), &VisualShaderNodeCompare::set_comparsion_type); - ClassDB::bind_method(D_METHOD("get_comparsion_type"), &VisualShaderNodeCompare::get_comparsion_type); + ClassDB::bind_method(D_METHOD("set_comparison_type", "type"), &VisualShaderNodeCompare::set_comparison_type); + ClassDB::bind_method(D_METHOD("get_comparison_type"), &VisualShaderNodeCompare::get_comparison_type); ClassDB::bind_method(D_METHOD("set_function", "func"), &VisualShaderNodeCompare::set_function); ClassDB::bind_method(D_METHOD("get_function"), &VisualShaderNodeCompare::get_function); @@ -4001,7 +4070,7 @@ void VisualShaderNodeCompare::_bind_methods() { ClassDB::bind_method(D_METHOD("set_condition", "condition"), &VisualShaderNodeCompare::set_condition); ClassDB::bind_method(D_METHOD("get_condition"), &VisualShaderNodeCompare::get_condition); - ADD_PROPERTY(PropertyInfo(Variant::INT, "type", PROPERTY_HINT_ENUM, "Scalar,Vector,Boolean,Transform"), "set_comparsion_type", "get_comparsion_type"); + ADD_PROPERTY(PropertyInfo(Variant::INT, "type", PROPERTY_HINT_ENUM, "Scalar,Vector,Boolean,Transform"), "set_comparison_type", "get_comparison_type"); ADD_PROPERTY(PropertyInfo(Variant::INT, "function", PROPERTY_HINT_ENUM, "a == b,a != b,a > b,a >= b,a < b,a <= b"), "set_function", "get_function"); ADD_PROPERTY(PropertyInfo(Variant::INT, "condition", PROPERTY_HINT_ENUM, "All,Any"), "set_condition", "get_condition"); diff --git a/scene/resources/visual_shader_nodes.h b/scene/resources/visual_shader_nodes.h index 0f428088e0..cca37273d9 100644 --- a/scene/resources/visual_shader_nodes.h +++ b/scene/resources/visual_shader_nodes.h @@ -1635,7 +1635,7 @@ class VisualShaderNodeCompare : public VisualShaderNode { GDCLASS(VisualShaderNodeCompare, VisualShaderNode); public: - enum ComparsionType { + enum ComparisonType { CTYPE_SCALAR, CTYPE_VECTOR, CTYPE_BOOLEAN, @@ -1657,7 +1657,7 @@ public: }; protected: - ComparsionType ctype; + ComparisonType ctype; Function func; Condition condition; @@ -1677,8 +1677,8 @@ public: virtual String generate_code(Shader::Mode p_mode, VisualShader::Type p_type, int p_id, const String *p_input_vars, const String *p_output_vars, bool p_for_preview = false) const; //if no output is connected, the output var passed will be empty. if no input is connected and input is NIL, the input var passed will be empty - void set_comparsion_type(ComparsionType p_type); - ComparsionType get_comparsion_type() const; + void set_comparison_type(ComparisonType p_type); + ComparisonType get_comparison_type() const; void set_function(Function p_func); Function get_function() const; @@ -1692,7 +1692,7 @@ public: VisualShaderNodeCompare(); }; -VARIANT_ENUM_CAST(VisualShaderNodeCompare::ComparsionType) +VARIANT_ENUM_CAST(VisualShaderNodeCompare::ComparisonType) VARIANT_ENUM_CAST(VisualShaderNodeCompare::Function) VARIANT_ENUM_CAST(VisualShaderNodeCompare::Condition) diff --git a/servers/audio/audio_stream.cpp b/servers/audio/audio_stream.cpp index 6b286e09e9..259c5487e9 100644 --- a/servers/audio/audio_stream.cpp +++ b/servers/audio/audio_stream.cpp @@ -29,6 +29,7 @@ /*************************************************************************/ #include "audio_stream.h" + #include "core/os/os.h" #include "core/project_settings.h" @@ -134,31 +135,31 @@ AudioStreamMicrophone::AudioStreamMicrophone() { void AudioStreamPlaybackMicrophone::_mix_internal(AudioFrame *p_buffer, int p_frames) { - AudioServer::get_singleton()->lock(); + AudioDriver::get_singleton()->lock(); - PoolVector<int32_t> capture_buffer = AudioServer::get_singleton()->get_capture_buffer(); - unsigned int capture_size = AudioServer::get_singleton()->get_capture_size(); - int mix_rate = AudioServer::get_singleton()->get_mix_rate(); - unsigned int playback_delay = MIN(((50 * mix_rate) / 1000) * 2, capture_buffer.size() >> 1); + Vector<int32_t> buf = AudioDriver::get_singleton()->get_input_buffer(); + unsigned int input_size = AudioDriver::get_singleton()->get_input_size(); + int mix_rate = AudioDriver::get_singleton()->get_mix_rate(); + unsigned int playback_delay = MIN(((50 * mix_rate) / 1000) * 2, buf.size() >> 1); #ifdef DEBUG_ENABLED - unsigned int capture_position = AudioServer::get_singleton()->get_capture_position(); + unsigned int input_position = AudioDriver::get_singleton()->get_input_position(); #endif - if (playback_delay > capture_size) { + if (playback_delay > input_size) { for (int i = 0; i < p_frames; i++) { p_buffer[i] = AudioFrame(0.0f, 0.0f); } - capture_ofs = 0; + input_ofs = 0; } else { for (int i = 0; i < p_frames; i++) { - if (capture_size > capture_ofs && (int)capture_ofs < capture_buffer.size()) { - float l = (capture_buffer[capture_ofs++] >> 16) / 32768.f; - if ((int)capture_ofs >= capture_buffer.size()) { - capture_ofs = 0; + if (input_size > input_ofs && (int)input_ofs < buf.size()) { + float l = (buf[input_ofs++] >> 16) / 32768.f; + if ((int)input_ofs >= buf.size()) { + input_ofs = 0; } - float r = (capture_buffer[capture_ofs++] >> 16) / 32768.f; - if ((int)capture_ofs >= capture_buffer.size()) { - capture_ofs = 0; + float r = (buf[input_ofs++] >> 16) / 32768.f; + if ((int)input_ofs >= buf.size()) { + input_ofs = 0; } p_buffer[i] = AudioFrame(l, r); @@ -169,12 +170,12 @@ void AudioStreamPlaybackMicrophone::_mix_internal(AudioFrame *p_buffer, int p_fr } #ifdef DEBUG_ENABLED - if (capture_ofs > capture_position && (int)(capture_ofs - capture_position) < (p_frames * 2)) { - print_verbose(String(get_class_name()) + " buffer underrun: capture_position=" + itos(capture_position) + " capture_ofs=" + itos(capture_ofs) + " capture_size=" + itos(capture_size)); + if (input_ofs > input_position && (int)(input_ofs - input_position) < (p_frames * 2)) { + print_verbose(String(get_class_name()) + " buffer underrun: input_position=" + itos(input_position) + " input_ofs=" + itos(input_ofs) + " input_size=" + itos(input_size)); } #endif - AudioServer::get_singleton()->unlock(); + AudioDriver::get_singleton()->unlock(); } void AudioStreamPlaybackMicrophone::mix(AudioFrame *p_buffer, float p_rate_scale, int p_frames) { @@ -192,13 +193,13 @@ void AudioStreamPlaybackMicrophone::start(float p_from_pos) { } if (!GLOBAL_GET("audio/enable_audio_input")) { - WARN_PRINTS("Need to enable Project settings > Audio > Enable Audio Input option to use capturing."); + WARN_PRINT("Need to enable Project settings > Audio > Enable Audio Input option to use capturing."); return; } - capture_ofs = 0; + input_ofs = 0; - if (AudioServer::get_singleton()->capture_start() == OK) { + if (AudioDriver::get_singleton()->capture_start() == OK) { active = true; _begin_resample(); } @@ -206,7 +207,7 @@ void AudioStreamPlaybackMicrophone::start(float p_from_pos) { void AudioStreamPlaybackMicrophone::stop() { if (active) { - AudioServer::get_singleton()->capture_stop(); + AudioDriver::get_singleton()->capture_stop(); active = false; } } diff --git a/servers/audio/audio_stream.h b/servers/audio/audio_stream.h index 58775c3d94..155b683d7d 100644 --- a/servers/audio/audio_stream.h +++ b/servers/audio/audio_stream.h @@ -82,7 +82,7 @@ public: class AudioStream : public Resource { GDCLASS(AudioStream, Resource); - OBJ_SAVE_TYPE(AudioStream) //children are all saved as AudioStream, so they can be exchanged + OBJ_SAVE_TYPE(AudioStream); // Saves derived classes with common type so they can be interchanged. protected: static void _bind_methods(); @@ -123,7 +123,7 @@ class AudioStreamPlaybackMicrophone : public AudioStreamPlaybackResampled { friend class AudioStreamMicrophone; bool active; - unsigned int capture_ofs; + unsigned int input_ofs; Ref<AudioStreamMicrophone> microphone; diff --git a/servers/audio/effects/audio_effect_record.cpp b/servers/audio/effects/audio_effect_record.cpp index 9b1fb1fefb..9be3a2d554 100644 --- a/servers/audio/effects/audio_effect_record.cpp +++ b/servers/audio/effects/audio_effect_record.cpp @@ -186,7 +186,7 @@ void AudioEffectRecord::ensure_thread_stopped() { void AudioEffectRecord::set_recording_active(bool p_record) { if (p_record) { if (current_instance == 0) { - WARN_PRINTS("Recording should not be set as active before Godot has initialized."); + WARN_PRINT("Recording should not be set as active before Godot has initialized."); recording_active = false; return; } diff --git a/servers/audio_server.cpp b/servers/audio_server.cpp index ccb406bf9a..1c84e97196 100644 --- a/servers/audio_server.cpp +++ b/servers/audio_server.cpp @@ -85,26 +85,26 @@ double AudioDriver::get_time_to_next_mix() const { return mix_buffer - total; } -void AudioDriver::capture_buffer_init(int driver_buffer_frames) { +void AudioDriver::input_buffer_init(int driver_buffer_frames) { - const int capture_buffer_channels = 2; - capture_buffer.resize(driver_buffer_frames * capture_buffer_channels * 4); - capture_position = 0; - capture_size = 0; + const int input_buffer_channels = 2; + input_buffer.resize(driver_buffer_frames * input_buffer_channels * 4); + input_position = 0; + input_size = 0; } -void AudioDriver::capture_buffer_write(int32_t sample) { +void AudioDriver::input_buffer_write(int32_t sample) { - if ((int)capture_position < capture_buffer.size()) { - capture_buffer.write()[capture_position++] = sample; - if ((int)capture_position >= capture_buffer.size()) { - capture_position = 0; + if ((int)input_position < input_buffer.size()) { + input_buffer.write[input_position++] = sample; + if ((int)input_position >= input_buffer.size()) { + input_position = 0; } - if ((int)capture_size < capture_buffer.size()) { - capture_size++; + if ((int)input_size < input_buffer.size()) { + input_size++; } } else { - WARN_PRINTS("capture_buffer_write: Invalid capture_position=" + itos(capture_position) + " capture_buffer.size()=" + itos(capture_buffer.size())); + WARN_PRINT("input_buffer_write: Invalid input_position=" + itos(input_position) + " input_buffer.size()=" + itos(input_buffer.size())); } } @@ -154,8 +154,8 @@ AudioDriver::AudioDriver() { _last_mix_time = 0; _last_mix_frames = 0; - capture_position = 0; - capture_size = 0; + input_position = 0; + input_size = 0; #ifdef DEBUG_ENABLED prof_time = 0; @@ -338,8 +338,6 @@ void AudioServer::_mix_step() { E->get().callback(E->get().userdata); } - emit_signal("audio_mix_callback"); - for (int i = buses.size() - 1; i >= 0; i--) { //go bus by bus Bus *bus = buses[i]; @@ -1059,8 +1057,6 @@ void AudioServer::update() { E->get().callback(E->get().userdata); } - - emit_signal("audio_update_callback"); } void AudioServer::load_default_bus_layout() { @@ -1079,7 +1075,6 @@ void AudioServer::finish() { for (int i = 0; i < AudioDriverManager::get_driver_count(); i++) { AudioDriverManager::get_driver(i)->finish(); - AudioDriverManager::get_driver(i)->clear_capture_buffer(); } for (int i = 0; i < buses.size(); i++) { @@ -1307,14 +1302,6 @@ void AudioServer::set_device(String device) { AudioDriver::get_singleton()->set_device(device); } -Error AudioServer::capture_start() { - return AudioDriver::get_singleton()->capture_start(); -} - -Error AudioServer::capture_stop() { - return AudioDriver::get_singleton()->capture_stop(); -} - Array AudioServer::capture_get_device_list() { return AudioDriver::get_singleton()->capture_get_device_list(); @@ -1330,18 +1317,6 @@ void AudioServer::capture_set_device(const String &p_name) { AudioDriver::get_singleton()->capture_set_device(p_name); } -PoolVector<int32_t> AudioServer::get_capture_buffer() { - return AudioDriver::get_singleton()->get_capture_buffer(); -} - -unsigned int AudioServer::get_capture_position() { - return AudioDriver::get_singleton()->get_capture_position(); -} - -unsigned int AudioServer::get_capture_size() { - return AudioDriver::get_singleton()->get_capture_size(); -} - void AudioServer::_bind_methods() { ClassDB::bind_method(D_METHOD("set_bus_count", "amount"), &AudioServer::set_bus_count); @@ -1402,28 +1377,18 @@ void AudioServer::_bind_methods() { ClassDB::bind_method(D_METHOD("get_time_since_last_mix"), &AudioServer::get_time_since_last_mix); ClassDB::bind_method(D_METHOD("get_output_latency"), &AudioServer::get_output_latency); - ClassDB::bind_method(D_METHOD("capture_start"), &AudioServer::capture_start); - ClassDB::bind_method(D_METHOD("capture_stop"), &AudioServer::capture_stop); - ClassDB::bind_method(D_METHOD("capture_get_device_list"), &AudioServer::capture_get_device_list); ClassDB::bind_method(D_METHOD("capture_get_device"), &AudioServer::capture_get_device); ClassDB::bind_method(D_METHOD("capture_set_device", "name"), &AudioServer::capture_set_device); - ClassDB::bind_method(D_METHOD("get_capture_buffer"), &AudioServer::get_capture_buffer); - ClassDB::bind_method(D_METHOD("get_capture_position"), &AudioServer::get_capture_position); - ClassDB::bind_method(D_METHOD("get_capture_size"), &AudioServer::get_capture_size); - ClassDB::bind_method(D_METHOD("set_bus_layout", "bus_layout"), &AudioServer::set_bus_layout); ClassDB::bind_method(D_METHOD("generate_bus_layout"), &AudioServer::generate_bus_layout); ADD_PROPERTY(PropertyInfo(Variant::INT, "bus_count"), "set_bus_count", "get_bus_count"); ADD_PROPERTY(PropertyInfo(Variant::STRING, "device"), "set_device", "get_device"); - ADD_PROPERTY(PropertyInfo(Variant::STRING, "capture_device"), "capture_set_device", "capture_get_device"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "global_rate_scale"), "set_global_rate_scale", "get_global_rate_scale"); ADD_SIGNAL(MethodInfo("bus_layout_changed")); - ADD_SIGNAL(MethodInfo("audio_mix_callback")); - ADD_SIGNAL(MethodInfo("audio_update_callback")); BIND_ENUM_CONSTANT(SPEAKER_MODE_STEREO); BIND_ENUM_CONSTANT(SPEAKER_SURROUND_31); diff --git a/servers/audio_server.h b/servers/audio_server.h index 8037c7feed..815200c811 100644 --- a/servers/audio_server.h +++ b/servers/audio_server.h @@ -53,14 +53,14 @@ class AudioDriver { #endif protected: - PoolVector<int32_t> capture_buffer; - unsigned int capture_position; - unsigned int capture_size; + Vector<int32_t> input_buffer; + unsigned int input_position; + unsigned int input_size; void audio_server_process(int p_frames, int32_t *p_buffer, bool p_update_mix_time = true); void update_mix_time(int p_frames); - void capture_buffer_init(int driver_buffer_frames); - void capture_buffer_write(int32_t sample); + void input_buffer_init(int driver_buffer_frames); + void input_buffer_write(int32_t sample); #ifdef DEBUG_ENABLED _FORCE_INLINE_ void start_counting_ticks() { prof_ticks = OS::get_singleton()->get_ticks_usec(); } @@ -111,11 +111,9 @@ public: SpeakerMode get_speaker_mode_by_total_channels(int p_channels) const; int get_total_channels_by_speaker_mode(SpeakerMode) const; - PoolVector<int32_t> get_capture_buffer() { return capture_buffer; } - unsigned int get_capture_position() { return capture_position; } - unsigned int get_capture_size() { return capture_size; } - - void clear_capture_buffer() { capture_buffer.resize(0); } + Vector<int32_t> get_input_buffer() { return input_buffer; } + unsigned int get_input_position() { return input_position; } + unsigned int get_input_size() { return input_size; } #ifdef DEBUG_ENABLED uint64_t get_profiling_time() const { return prof_time; } @@ -249,18 +247,6 @@ private: void _mix_step(); -#if 0 - struct AudioInBlock { - - Ref<AudioStreamSample> audio_stream; - int current_position; - bool loops; - }; - - Map<StringName, AudioInBlock *> audio_in_block_map; - Vector<AudioInBlock *> audio_in_blocks; -#endif - struct CallbackItem { AudioCallback callback; @@ -386,17 +372,10 @@ public: String get_device(); void set_device(String device); - Error capture_start(); - Error capture_stop(); - Array capture_get_device_list(); String capture_get_device(); void capture_set_device(const String &p_name); - PoolVector<int32_t> get_capture_buffer(); - unsigned int get_capture_position(); - unsigned int get_capture_size(); - AudioServer(); virtual ~AudioServer(); }; diff --git a/servers/physics/area_sw.cpp b/servers/physics/area_sw.cpp index f9f7f67a1e..398849edb8 100644 --- a/servers/physics/area_sw.cpp +++ b/servers/physics/area_sw.cpp @@ -46,6 +46,9 @@ AreaSW::BodyKey::BodyKey(AreaSW *p_body, uint32_t p_body_shape, uint32_t p_area_ } void AreaSW::_shapes_changed() { + + if (!moved_list.in_list() && get_space()) + get_space()->area_add_to_moved_list(&moved_list); } void AreaSW::set_transform(const Transform &p_transform) { diff --git a/servers/physics_2d/area_2d_sw.cpp b/servers/physics_2d/area_2d_sw.cpp index 110e94d22e..6f09041af8 100644 --- a/servers/physics_2d/area_2d_sw.cpp +++ b/servers/physics_2d/area_2d_sw.cpp @@ -46,6 +46,9 @@ Area2DSW::BodyKey::BodyKey(Area2DSW *p_body, uint32_t p_body_shape, uint32_t p_a } void Area2DSW::_shapes_changed() { + + if (!moved_list.in_list() && get_space()) + get_space()->area_add_to_moved_list(&moved_list); } void Area2DSW::set_transform(const Transform2D &p_transform) { diff --git a/servers/visual/shader_language.cpp b/servers/visual/shader_language.cpp index 225b382524..14d2f6d086 100644 --- a/servers/visual/shader_language.cpp +++ b/servers/visual/shader_language.cpp @@ -662,6 +662,8 @@ ShaderLanguage::Token ShaderLanguage::_get_token() { idx++; } + str = str.replace("dus_", "_"); + return _make_token(TK_IDENTIFIER, str); } @@ -856,6 +858,7 @@ void ShaderLanguage::clear() { completion_type = COMPLETION_NONE; completion_block = NULL; completion_function = StringName(); + completion_class = SubClassTag::TAG_GLOBAL; error_line = 0; tk_line = 1; @@ -1406,21 +1409,21 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "ivec4", TYPE_IVEC4, { TYPE_IVEC3, TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, { "ivec4", TYPE_IVEC4, { TYPE_IVEC2, TYPE_IVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "uint", TYPE_UINT, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec2", TYPE_UVEC2, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec2", TYPE_UVEC2, { TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec3", TYPE_UVEC3, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec3", TYPE_UVEC3, { TYPE_UINT, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec3", TYPE_UVEC3, { TYPE_UVEC2, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec3", TYPE_UVEC3, { TYPE_UINT, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_UINT, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_UVEC2, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UVEC2, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_UINT, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UVEC3, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, + { "uint", TYPE_UINT, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec2", TYPE_UVEC2, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec2", TYPE_UVEC2, { TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec3", TYPE_UVEC3, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec3", TYPE_UVEC3, { TYPE_UINT, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec3", TYPE_UVEC3, { TYPE_UVEC2, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec3", TYPE_UVEC3, { TYPE_UINT, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_UINT, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_UVEC2, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UVEC2, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_UINT, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UINT, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UVEC3, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, { "mat2", TYPE_MAT2, { TYPE_VEC2, TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "mat3", TYPE_MAT3, { TYPE_VEC3, TYPE_VEC3, TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1434,22 +1437,22 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "int", TYPE_INT, { TYPE_BOOL, TYPE_VOID }, TAG_GLOBAL, false }, { "int", TYPE_INT, { TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, - { "int", TYPE_INT, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, + { "int", TYPE_INT, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, { "int", TYPE_INT, { TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, false }, { "float", TYPE_FLOAT, { TYPE_BOOL, TYPE_VOID }, TAG_GLOBAL, false }, { "float", TYPE_FLOAT, { TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, - { "float", TYPE_FLOAT, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, + { "float", TYPE_FLOAT, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, { "float", TYPE_FLOAT, { TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uint", TYPE_UINT, { TYPE_BOOL, TYPE_VOID }, TAG_GLOBAL, false }, - { "uint", TYPE_UINT, { TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uint", TYPE_UINT, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "uint", TYPE_UINT, { TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, false }, + { "uint", TYPE_UINT, { TYPE_BOOL, TYPE_VOID }, TAG_GLOBAL, true }, + { "uint", TYPE_UINT, { TYPE_INT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uint", TYPE_UINT, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "uint", TYPE_UINT, { TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, true }, { "bool", TYPE_BOOL, { TYPE_BOOL, TYPE_VOID }, TAG_GLOBAL, false }, { "bool", TYPE_BOOL, { TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, - { "bool", TYPE_BOOL, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, + { "bool", TYPE_BOOL, { TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, { "bool", TYPE_BOOL, { TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, false }, //conversion vectors @@ -1461,57 +1464,57 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "vec2", TYPE_VEC2, { TYPE_BVEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "vec2", TYPE_VEC2, { TYPE_IVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "vec2", TYPE_VEC2, { TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, + { "vec2", TYPE_VEC2, { TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, { "vec2", TYPE_VEC2, { TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec2", TYPE_UVEC2, { TYPE_BVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec2", TYPE_UVEC2, { TYPE_IVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec2", TYPE_UVEC2, { TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec2", TYPE_UVEC2, { TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, + { "uvec2", TYPE_UVEC2, { TYPE_BVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec2", TYPE_UVEC2, { TYPE_IVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec2", TYPE_UVEC2, { TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec2", TYPE_UVEC2, { TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, true }, { "bvec2", TYPE_BVEC2, { TYPE_BVEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "bvec2", TYPE_BVEC2, { TYPE_IVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "bvec2", TYPE_BVEC2, { TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, + { "bvec2", TYPE_BVEC2, { TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, { "bvec2", TYPE_BVEC2, { TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "ivec3", TYPE_IVEC3, { TYPE_BVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "ivec3", TYPE_IVEC3, { TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "ivec3", TYPE_IVEC3, { TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, + { "ivec3", TYPE_IVEC3, { TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, { "ivec3", TYPE_IVEC3, { TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "vec3", TYPE_VEC3, { TYPE_BVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "vec3", TYPE_VEC3, { TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "vec3", TYPE_VEC3, { TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, + { "vec3", TYPE_VEC3, { TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, { "vec3", TYPE_VEC3, { TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec3", TYPE_UVEC3, { TYPE_BVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec3", TYPE_UVEC3, { TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec3", TYPE_UVEC3, { TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec3", TYPE_UVEC3, { TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, + { "uvec3", TYPE_UVEC3, { TYPE_BVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec3", TYPE_UVEC3, { TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec3", TYPE_UVEC3, { TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec3", TYPE_UVEC3, { TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, true }, { "bvec3", TYPE_BVEC3, { TYPE_BVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "bvec3", TYPE_BVEC3, { TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "bvec3", TYPE_BVEC3, { TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, + { "bvec3", TYPE_BVEC3, { TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, { "bvec3", TYPE_BVEC3, { TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "ivec4", TYPE_IVEC4, { TYPE_BVEC4, TYPE_VOID }, TAG_GLOBAL, false }, { "ivec4", TYPE_IVEC4, { TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "ivec4", TYPE_IVEC4, { TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "ivec4", TYPE_IVEC4, { TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "ivec4", TYPE_IVEC4, { TYPE_VEC4, TYPE_VOID }, TAG_GLOBAL, false }, { "vec4", TYPE_VEC4, { TYPE_BVEC4, TYPE_VOID }, TAG_GLOBAL, false }, { "vec4", TYPE_VEC4, { TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "vec4", TYPE_VEC4, { TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "vec4", TYPE_VEC4, { TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "vec4", TYPE_VEC4, { TYPE_VEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_BVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "uvec4", TYPE_UVEC4, { TYPE_VEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "uvec4", TYPE_UVEC4, { TYPE_BVEC4, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, + { "uvec4", TYPE_UVEC4, { TYPE_VEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "bvec4", TYPE_BVEC4, { TYPE_BVEC4, TYPE_VOID }, TAG_GLOBAL, false }, { "bvec4", TYPE_BVEC4, { TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "bvec4", TYPE_BVEC4, { TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "bvec4", TYPE_BVEC4, { TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "bvec4", TYPE_BVEC4, { TYPE_VEC4, TYPE_VOID }, TAG_GLOBAL, false }, //conversion between matrixes @@ -1703,13 +1706,13 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "min", TYPE_IVEC4, { TYPE_IVEC4, TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, { "min", TYPE_IVEC4, { TYPE_IVEC4, TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, - { "min", TYPE_UINT, { TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "min", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "min", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "min", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "min", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "min", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "min", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, + { "min", TYPE_UINT, { TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "min", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "min", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "min", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "min", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "min", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, + { "min", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, { "max", TYPE_FLOAT, { TYPE_FLOAT, TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, false }, { "max", TYPE_VEC2, { TYPE_VEC2, TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1727,13 +1730,13 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "max", TYPE_IVEC4, { TYPE_IVEC4, TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, { "max", TYPE_IVEC4, { TYPE_IVEC4, TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, - { "max", TYPE_UINT, { TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "max", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "max", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "max", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "max", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "max", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "max", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, + { "max", TYPE_UINT, { TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "max", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "max", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "max", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "max", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "max", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, + { "max", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, { "clamp", TYPE_FLOAT, { TYPE_FLOAT, TYPE_FLOAT, TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, false }, { "clamp", TYPE_VEC2, { TYPE_VEC2, TYPE_VEC2, TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1751,13 +1754,13 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "clamp", TYPE_IVEC3, { TYPE_IVEC3, TYPE_INT, TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, { "clamp", TYPE_IVEC4, { TYPE_IVEC4, TYPE_INT, TYPE_INT, TYPE_VOID }, TAG_GLOBAL, false }, - { "clamp", TYPE_UINT, { TYPE_UINT, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "clamp", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "clamp", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "clamp", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "clamp", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "clamp", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, - { "clamp", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, false }, + { "clamp", TYPE_UINT, { TYPE_UINT, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "clamp", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "clamp", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "clamp", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, + { "clamp", TYPE_UVEC2, { TYPE_UVEC2, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "clamp", TYPE_UVEC3, { TYPE_UVEC3, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, + { "clamp", TYPE_UVEC4, { TYPE_UVEC4, TYPE_UINT, TYPE_UINT, TYPE_VOID }, TAG_GLOBAL, true }, { "mix", TYPE_FLOAT, { TYPE_FLOAT, TYPE_FLOAT, TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, false }, { "mix", TYPE_VEC2, { TYPE_VEC2, TYPE_VEC2, TYPE_FLOAT, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1864,9 +1867,9 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "lessThan", TYPE_BVEC3, { TYPE_IVEC3, TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "lessThan", TYPE_BVEC4, { TYPE_IVEC4, TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "lessThan", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "lessThan", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "lessThan", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "lessThan", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "lessThan", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "lessThan", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "greaterThan", TYPE_BVEC2, { TYPE_VEC2, TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "greaterThan", TYPE_BVEC3, { TYPE_VEC3, TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1876,9 +1879,9 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "greaterThan", TYPE_BVEC3, { TYPE_IVEC3, TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "greaterThan", TYPE_BVEC4, { TYPE_IVEC4, TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "greaterThan", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "greaterThan", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "greaterThan", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "greaterThan", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "greaterThan", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "greaterThan", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "lessThanEqual", TYPE_BVEC2, { TYPE_VEC2, TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "lessThanEqual", TYPE_BVEC3, { TYPE_VEC3, TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1888,9 +1891,9 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "lessThanEqual", TYPE_BVEC3, { TYPE_IVEC3, TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "lessThanEqual", TYPE_BVEC4, { TYPE_IVEC4, TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "lessThanEqual", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "lessThanEqual", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "lessThanEqual", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "lessThanEqual", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "lessThanEqual", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "lessThanEqual", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "greaterThanEqual", TYPE_BVEC2, { TYPE_VEC2, TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "greaterThanEqual", TYPE_BVEC3, { TYPE_VEC3, TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1900,9 +1903,9 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "greaterThanEqual", TYPE_BVEC3, { TYPE_IVEC3, TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "greaterThanEqual", TYPE_BVEC4, { TYPE_IVEC4, TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "greaterThanEqual", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "greaterThanEqual", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "greaterThanEqual", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "greaterThanEqual", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "greaterThanEqual", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "greaterThanEqual", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "equal", TYPE_BVEC2, { TYPE_VEC2, TYPE_VEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "equal", TYPE_BVEC3, { TYPE_VEC3, TYPE_VEC3, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1912,9 +1915,9 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "equal", TYPE_BVEC3, { TYPE_IVEC3, TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "equal", TYPE_BVEC4, { TYPE_IVEC4, TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "equal", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "equal", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "equal", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "equal", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "equal", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "equal", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "equal", TYPE_BVEC2, { TYPE_BVEC2, TYPE_BVEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "equal", TYPE_BVEC3, { TYPE_BVEC3, TYPE_BVEC3, TYPE_VOID }, TAG_GLOBAL, false }, @@ -1928,9 +1931,9 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { { "notEqual", TYPE_BVEC3, { TYPE_IVEC3, TYPE_IVEC3, TYPE_VOID }, TAG_GLOBAL, false }, { "notEqual", TYPE_BVEC4, { TYPE_IVEC4, TYPE_IVEC4, TYPE_VOID }, TAG_GLOBAL, false }, - { "notEqual", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, false }, - { "notEqual", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, false }, - { "notEqual", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, false }, + { "notEqual", TYPE_BVEC2, { TYPE_UVEC2, TYPE_UVEC2, TYPE_VOID }, TAG_GLOBAL, true }, + { "notEqual", TYPE_BVEC3, { TYPE_UVEC3, TYPE_UVEC3, TYPE_VOID }, TAG_GLOBAL, true }, + { "notEqual", TYPE_BVEC4, { TYPE_UVEC4, TYPE_UVEC4, TYPE_VOID }, TAG_GLOBAL, true }, { "notEqual", TYPE_BVEC2, { TYPE_BVEC2, TYPE_BVEC2, TYPE_VOID }, TAG_GLOBAL, false }, { "notEqual", TYPE_BVEC3, { TYPE_BVEC3, TYPE_BVEC3, TYPE_VOID }, TAG_GLOBAL, false }, @@ -2060,7 +2063,7 @@ const ShaderLanguage::BuiltinFuncDef ShaderLanguage::builtin_func_defs[] = { //sub-functions //array - { "length", TYPE_INT, { TYPE_VOID }, TAG_ARRAY, false }, + { "length", TYPE_INT, { TYPE_VOID }, TAG_ARRAY, true }, { NULL, TYPE_VOID, { TYPE_VOID }, TAG_GLOBAL, false } @@ -3856,6 +3859,10 @@ Error ShaderLanguage::_parse_block(BlockNode *p_block, const Map<StringName, Bui DataType type = get_token_datatype(tk.type); + if (_validate_datatype(type) != OK) { + return ERR_PARSE_ERROR; + } + tk = _get_token(); Node *vardecl = NULL; @@ -3888,6 +3895,11 @@ Error ShaderLanguage::_parse_block(BlockNode *p_block, const Map<StringName, Bui if (tk.type == TK_BRACKET_OPEN) { bool unknown_size = false; + if (VisualServer::get_singleton()->is_low_end() && is_const) { + _set_error("Local const arrays are supported only on high-end platform!"); + return ERR_PARSE_ERROR; + } + ArrayDeclarationNode *node = alloc_node<ArrayDeclarationNode>(); node->datatype = type; node->precision = precision; @@ -3923,6 +3935,12 @@ Error ShaderLanguage::_parse_block(BlockNode *p_block, const Map<StringName, Bui tk = _get_token(); if (tk.type == TK_OP_ASSIGN) { + + if (VisualServer::get_singleton()->is_low_end()) { + _set_error("Array initialization is supported only on high-end platform!"); + return ERR_PARSE_ERROR; + } + tk = _get_token(); if (tk.type != TK_CURLY_BRACKET_OPEN) { @@ -3953,33 +3971,42 @@ Error ShaderLanguage::_parse_block(BlockNode *p_block, const Map<StringName, Bui tk = _get_token(); if (tk.type == TK_BRACKET_OPEN) { - Node *n = _parse_and_reduce_expression(p_block, p_builtin_types); - if (!n || n->type != Node::TYPE_CONSTANT || n->get_datatype() != TYPE_INT) { - _set_error("Expected single integer constant > 0"); - return ERR_PARSE_ERROR; - } + TkPos pos2 = _get_tkpos(); + tk = _get_token(); + if (tk.type == TK_BRACKET_CLOSE) { + array_size2 = var.array_size; + tk = _get_token(); + } else { + _set_tkpos(pos2); - ConstantNode *cnode = (ConstantNode *)n; - if (cnode->values.size() == 1) { - array_size2 = cnode->values[0].sint; - if (array_size2 <= 0) { + Node *n = _parse_and_reduce_expression(p_block, p_builtin_types); + if (!n || n->type != Node::TYPE_CONSTANT || n->get_datatype() != TYPE_INT) { + _set_error("Expected single integer constant > 0"); + return ERR_PARSE_ERROR; + } + + ConstantNode *cnode = (ConstantNode *)n; + if (cnode->values.size() == 1) { + array_size2 = cnode->values[0].sint; + if (array_size2 <= 0) { + _set_error("Expected single integer constant > 0"); + return ERR_PARSE_ERROR; + } + } else { _set_error("Expected single integer constant > 0"); return ERR_PARSE_ERROR; } - } else { - _set_error("Expected single integer constant > 0"); - return ERR_PARSE_ERROR; - } - tk = _get_token(); - if (tk.type != TK_BRACKET_CLOSE) { - _set_error("Expected ']"); - return ERR_PARSE_ERROR; - } else { tk = _get_token(); + if (tk.type != TK_BRACKET_CLOSE) { + _set_error("Expected ']'"); + return ERR_PARSE_ERROR; + } else { + tk = _get_token(); + } } } else { - _set_error("Expected '["); + _set_error("Expected '['"); return ERR_PARSE_ERROR; } @@ -4667,27 +4694,17 @@ Error ShaderLanguage::_validate_datatype(DataType p_type) { bool invalid_type = false; switch (p_type) { + case TYPE_UINT: + case TYPE_UVEC2: + case TYPE_UVEC3: + case TYPE_UVEC4: case TYPE_ISAMPLER2D: - invalid_type = true; - break; case TYPE_USAMPLER2D: - invalid_type = true; - break; case TYPE_SAMPLER3D: - invalid_type = true; - break; case TYPE_ISAMPLER3D: - invalid_type = true; - break; case TYPE_USAMPLER3D: - invalid_type = true; - break; case TYPE_SAMPLER2DARRAY: - invalid_type = true; - break; case TYPE_USAMPLER2DARRAY: - invalid_type = true; - break; case TYPE_ISAMPLER2DARRAY: invalid_type = true; break; @@ -5587,17 +5604,26 @@ Error ShaderLanguage::complete(const String &p_code, const Map<StringName, Funct } int idx = 0; + bool low_end = VisualServer::get_singleton()->is_low_end(); while (builtin_func_defs[idx].name) { - + if (low_end && builtin_func_defs[idx].high_end) { + idx++; + continue; + } matches.insert(String(builtin_func_defs[idx].name), ScriptCodeCompletionOption::KIND_FUNCTION); idx++; } } else { // sub-class int idx = 0; + bool low_end = VisualServer::get_singleton()->is_low_end(); while (builtin_func_defs[idx].name) { + if (low_end && builtin_func_defs[idx].high_end) { + idx++; + continue; + } if (builtin_func_defs[idx].tag == completion_class) { matches.insert(String(builtin_func_defs[idx].name), ScriptCodeCompletionOption::KIND_FUNCTION); } @@ -5661,9 +5687,15 @@ Error ShaderLanguage::complete(const String &p_code, const Map<StringName, Funct int idx = 0; String calltip; + bool low_end = VisualServer::get_singleton()->is_low_end(); while (builtin_func_defs[idx].name) { + if (low_end && builtin_func_defs[idx].high_end) { + idx++; + continue; + } + if (completion_function == builtin_func_defs[idx].name) { if (builtin_func_defs[idx].tag != completion_class) { diff --git a/servers/visual/visual_server_raster.cpp b/servers/visual/visual_server_raster.cpp index 23736b5e63..74a4265462 100644 --- a/servers/visual/visual_server_raster.cpp +++ b/servers/visual/visual_server_raster.cpp @@ -119,7 +119,7 @@ void VisualServerRaster::draw(bool p_swap_buffers, double frame_step) { obj->call(frame_drawn_callbacks.front()->get().method, &v, 1, ce); if (ce.error != Variant::CallError::CALL_OK) { String err = Variant::get_call_error_text(obj, frame_drawn_callbacks.front()->get().method, &v, 1, ce); - ERR_PRINTS("Error calling frame drawn function: " + err); + ERR_PRINT("Error calling frame drawn function: " + err); } } diff --git a/servers/visual/visual_server_raster.h b/servers/visual/visual_server_raster.h index 1a1e86833e..9afcfc4648 100644 --- a/servers/visual/visual_server_raster.h +++ b/servers/visual/visual_server_raster.h @@ -531,11 +531,10 @@ public: BIND2(scenario_set_fallback_environment, RID, RID) /* INSTANCING API */ - // from can be mesh, light, area and portal so far. BIND0R(RID, instance_create) - BIND2(instance_set_base, RID, RID) // from can be mesh, light, poly, area and portal so far. - BIND2(instance_set_scenario, RID, RID) // from can be mesh, light, poly, area and portal so far. + BIND2(instance_set_base, RID, RID) + BIND2(instance_set_scenario, RID, RID) BIND2(instance_set_layer_mask, RID, uint32_t) BIND2(instance_set_transform, RID, const Transform &) BIND2(instance_attach_object_instance_id, RID, ObjectID) diff --git a/servers/visual/visual_server_scene.cpp b/servers/visual/visual_server_scene.cpp index bf9db616e4..f5767e93a2 100644 --- a/servers/visual/visual_server_scene.cpp +++ b/servers/visual/visual_server_scene.cpp @@ -29,10 +29,13 @@ /*************************************************************************/ #include "visual_server_scene.h" + #include "core/os/os.h" #include "visual_server_globals.h" #include "visual_server_raster.h" + #include <new> + /* CAMERA API */ RID VisualServerScene::camera_create() { @@ -314,7 +317,6 @@ void VisualServerScene::_instance_queue_update(Instance *p_instance, bool p_upda _instance_update_list.add(&p_instance->update_item); } -// from can be mesh, light, area and portal so far. RID VisualServerScene::instance_create() { Instance *instance = memnew(Instance); @@ -1398,9 +1400,9 @@ bool VisualServerScene::_light_instance_update_shadow(Instance *p_instance, cons if (p_cam_orthogonal) { - float w, h; - p_cam_projection.get_viewport_size(w, h); - camera_matrix.set_orthogonal(w, aspect, distances[(i == 0 || !overlap) ? i : i - 1], distances[i + 1], false); + Vector2 vp_he = p_cam_projection.get_viewport_half_extents(); + + camera_matrix.set_orthogonal(vp_he.y * 2.0, aspect, distances[(i == 0 || !overlap) ? i : i - 1], distances[i + 1], false); } else { float fov = p_cam_projection.get_fov(); @@ -2088,8 +2090,8 @@ void VisualServerScene::_prepare_scene(const Transform p_cam_transform, const Ca float zn = p_cam_projection.get_z_near(); Plane p(cam_xf.origin + cam_xf.basis.get_axis(2) * -zn, -cam_xf.basis.get_axis(2)); //camera near plane - float vp_w, vp_h; //near plane size in screen coordinates - p_cam_projection.get_viewport_size(vp_w, vp_h); + // near plane half width and height + Vector2 vp_half_extents = p_cam_projection.get_viewport_half_extents(); switch (VSG::storage->light_get_type(ins->base)) { @@ -2115,7 +2117,7 @@ void VisualServerScene::_prepare_scene(const Transform p_cam_transform, const Ca } float screen_diameter = points[0].distance_to(points[1]) * 2; - coverage = screen_diameter / (vp_w + vp_h); + coverage = screen_diameter / (vp_half_extents.x + vp_half_extents.y); } break; case VS::LIGHT_SPOT: { @@ -2144,7 +2146,7 @@ void VisualServerScene::_prepare_scene(const Transform p_cam_transform, const Ca } float screen_diameter = points[0].distance_to(points[1]) * 2; - coverage = screen_diameter / (vp_w + vp_h); + coverage = screen_diameter / (vp_half_extents.x + vp_half_extents.y); } break; default: { diff --git a/servers/visual/visual_server_scene.h b/servers/visual/visual_server_scene.h index ad74250fe4..a174d9e616 100644 --- a/servers/visual/visual_server_scene.h +++ b/servers/visual/visual_server_scene.h @@ -55,22 +55,6 @@ public: static VisualServerScene *singleton; -// FIXME: Kept as reference for future implementation -#if 0 - struct Portal { - - bool enabled; - float disable_distance; - Color disable_color; - float connect_range; - Vector<Point2> shape; - Rect2 bounds; - - - Portal() { enabled=true; disable_distance=50; disable_color=Color(); connect_range=0.8; } - }; -#endif - /* CAMERA API */ struct Camera : public RID_Data { @@ -450,11 +434,10 @@ public: RID_Owner<Instance> instance_owner; - // from can be mesh, light, area and portal so far. - virtual RID instance_create(); // from can be mesh, light, poly, area and portal so far. + virtual RID instance_create(); - virtual void instance_set_base(RID p_instance, RID p_base); // from can be mesh, light, poly, area and portal so far. - virtual void instance_set_scenario(RID p_instance, RID p_scenario); // from can be mesh, light, poly, area and portal so far. + virtual void instance_set_base(RID p_instance, RID p_base); + virtual void instance_set_scenario(RID p_instance, RID p_scenario); virtual void instance_set_layer_mask(RID p_instance, uint32_t p_mask); virtual void instance_set_transform(RID p_instance, const Transform &p_transform); virtual void instance_attach_object_instance_id(RID p_instance, ObjectID p_id); diff --git a/servers/visual/visual_server_wrap_mt.h b/servers/visual/visual_server_wrap_mt.h index b8f433d006..b1bbed24fd 100644 --- a/servers/visual/visual_server_wrap_mt.h +++ b/servers/visual/visual_server_wrap_mt.h @@ -453,11 +453,10 @@ public: FUNC2(scenario_set_fallback_environment, RID, RID) /* INSTANCING API */ - // from can be mesh, light, area and portal so far. FUNCRID(instance) - FUNC2(instance_set_base, RID, RID) // from can be mesh, light, poly, area and portal so far. - FUNC2(instance_set_scenario, RID, RID) // from can be mesh, light, poly, area and portal so far. + FUNC2(instance_set_base, RID, RID) + FUNC2(instance_set_scenario, RID, RID) FUNC2(instance_set_layer_mask, RID, uint32_t) FUNC2(instance_set_transform, RID, const Transform &) FUNC2(instance_attach_object_instance_id, RID, ObjectID) diff --git a/servers/visual_server.cpp b/servers/visual_server.cpp index b9b492e758..19b9e2c783 100644 --- a/servers/visual_server.cpp +++ b/servers/visual_server.cpp @@ -2397,6 +2397,8 @@ VisualServer::VisualServer() { GLOBAL_DEF("rendering/quality/reflections/texture_array_reflections.mobile", false); GLOBAL_DEF("rendering/quality/reflections/high_quality_ggx", true); GLOBAL_DEF("rendering/quality/reflections/high_quality_ggx.mobile", false); + GLOBAL_DEF("rendering/quality/reflections/irradiance_max_size", 128); + ProjectSettings::get_singleton()->set_custom_property_info("rendering/quality/reflections/irradiance_max_size", PropertyInfo(Variant::INT, "rendering/quality/reflections/irradiance_max_size", PROPERTY_HINT_RANGE, "32,2048")); GLOBAL_DEF("rendering/quality/shading/force_vertex_shading", false); GLOBAL_DEF("rendering/quality/shading/force_vertex_shading.mobile", true); diff --git a/servers/visual_server.h b/servers/visual_server.h index 33a9e8d72b..e7662695a6 100644 --- a/servers/visual_server.h +++ b/servers/visual_server.h @@ -335,12 +335,14 @@ public: MULTIMESH_COLOR_NONE, MULTIMESH_COLOR_8BIT, MULTIMESH_COLOR_FLOAT, + MULTIMESH_COLOR_MAX, }; enum MultimeshCustomDataFormat { MULTIMESH_CUSTOM_DATA_NONE, MULTIMESH_CUSTOM_DATA_8BIT, MULTIMESH_CUSTOM_DATA_FLOAT, + MULTIMESH_CUSTOM_DATA_MAX, }; virtual void multimesh_allocate(RID p_multimesh, int p_instances, MultimeshTransformFormat p_transform_format, MultimeshColorFormat p_color_format, MultimeshCustomDataFormat p_data_format = MULTIMESH_CUSTOM_DATA_NONE) = 0; @@ -811,11 +813,10 @@ public: virtual RID instance_create2(RID p_base, RID p_scenario); - //virtual RID instance_create(RID p_base,RID p_scenario)=0; // from can be mesh, light, area and portal so far. - virtual RID instance_create() = 0; // from can be mesh, light, poly, area and portal so far. + virtual RID instance_create() = 0; - virtual void instance_set_base(RID p_instance, RID p_base) = 0; // from can be mesh, light, poly, area and portal so far. - virtual void instance_set_scenario(RID p_instance, RID p_scenario) = 0; // from can be mesh, light, poly, area and portal so far. + virtual void instance_set_base(RID p_instance, RID p_base) = 0; + virtual void instance_set_scenario(RID p_instance, RID p_scenario) = 0; virtual void instance_set_layer_mask(RID p_instance, uint32_t p_mask) = 0; virtual void instance_set_transform(RID p_instance, const Transform &p_transform) = 0; virtual void instance_attach_object_instance_id(RID p_instance, ObjectID p_id) = 0; diff --git a/thirdparty/README.md b/thirdparty/README.md index b68c585cac..9b6f670972 100644 --- a/thirdparty/README.md +++ b/thirdparty/README.md @@ -237,7 +237,7 @@ from the Android NDK r18. ## libwebp - Upstream: https://chromium.googlesource.com/webm/libwebp/ -- Version: 1.0.3 +- Version: 1.1.0 - License: BSD-3-Clause Files extracted from upstream source: @@ -253,10 +253,11 @@ changes are marked with `// -- GODOT --` comments. ## mbedtls - Upstream: https://tls.mbed.org/ -- Version: 2.16.3 +- Version: 2.16.4 - License: Apache 2.0 File extracted from upstream release tarball (`-apache.tgz` variant): + - All `*.h` from `include/mbedtls/` to `thirdparty/mbedtls/include/mbedtls/` - All `*.c` from `library/` to `thirdparty/mbedtls/library/` - LICENSE and apache-2.0.txt files diff --git a/thirdparty/libwebp/src/dec/frame_dec.c b/thirdparty/libwebp/src/dec/frame_dec.c index bda9e1a6f6..04609a8e56 100644 --- a/thirdparty/libwebp/src/dec/frame_dec.c +++ b/thirdparty/libwebp/src/dec/frame_dec.c @@ -732,7 +732,7 @@ static int AllocateMemory(VP8Decoder* const dec) { mem += f_info_size; dec->thread_ctx_.id_ = 0; dec->thread_ctx_.f_info_ = dec->f_info_; - if (dec->mt_method_ > 0) { + if (dec->filter_type_ > 0 && dec->mt_method_ > 0) { // secondary cache line. The deblocking process need to make use of the // filtering strength from previous macroblock row, while the new ones // are being decoded in parallel. We'll just swap the pointers. diff --git a/thirdparty/libwebp/src/dec/idec_dec.c b/thirdparty/libwebp/src/dec/idec_dec.c index 9bc9166808..9035df5659 100644 --- a/thirdparty/libwebp/src/dec/idec_dec.c +++ b/thirdparty/libwebp/src/dec/idec_dec.c @@ -166,9 +166,11 @@ static int AppendToMemBuffer(WebPIDecoder* const idec, VP8Decoder* const dec = (VP8Decoder*)idec->dec_; MemBuffer* const mem = &idec->mem_; const int need_compressed_alpha = NeedCompressedAlpha(idec); - const uint8_t* const old_start = mem->buf_ + mem->start_; + const uint8_t* const old_start = + (mem->buf_ == NULL) ? NULL : mem->buf_ + mem->start_; const uint8_t* const old_base = need_compressed_alpha ? dec->alpha_data_ : old_start; + assert(mem->buf_ != NULL || mem->start_ == 0); assert(mem->mode_ == MEM_MODE_APPEND); if (data_size > MAX_CHUNK_PAYLOAD) { // security safeguard: trying to allocate more than what the format @@ -184,7 +186,7 @@ static int AppendToMemBuffer(WebPIDecoder* const idec, uint8_t* const new_buf = (uint8_t*)WebPSafeMalloc(extra_size, sizeof(*new_buf)); if (new_buf == NULL) return 0; - memcpy(new_buf, old_base, current_size); + if (old_base != NULL) memcpy(new_buf, old_base, current_size); WebPSafeFree(mem->buf_); mem->buf_ = new_buf; mem->buf_size_ = (size_t)extra_size; @@ -192,6 +194,7 @@ static int AppendToMemBuffer(WebPIDecoder* const idec, mem->end_ = current_size; } + assert(mem->buf_ != NULL); memcpy(mem->buf_ + mem->end_, data, data_size); mem->end_ += data_size; assert(mem->end_ <= mem->buf_size_); @@ -204,7 +207,9 @@ static int RemapMemBuffer(WebPIDecoder* const idec, const uint8_t* const data, size_t data_size) { MemBuffer* const mem = &idec->mem_; const uint8_t* const old_buf = mem->buf_; - const uint8_t* const old_start = old_buf + mem->start_; + const uint8_t* const old_start = + (old_buf == NULL) ? NULL : old_buf + mem->start_; + assert(old_buf != NULL || mem->start_ == 0); assert(mem->mode_ == MEM_MODE_MAP); if (data_size < mem->buf_size_) return 0; // can't remap to a shorter buffer! diff --git a/thirdparty/libwebp/src/dec/vp8i_dec.h b/thirdparty/libwebp/src/dec/vp8i_dec.h index 3de8d86f90..600a684410 100644 --- a/thirdparty/libwebp/src/dec/vp8i_dec.h +++ b/thirdparty/libwebp/src/dec/vp8i_dec.h @@ -31,8 +31,8 @@ extern "C" { // version numbers #define DEC_MAJ_VERSION 1 -#define DEC_MIN_VERSION 0 -#define DEC_REV_VERSION 3 +#define DEC_MIN_VERSION 1 +#define DEC_REV_VERSION 0 // YUV-cache parameters. Cache is 32-bytes wide (= one cacheline). // Constraints are: We need to store one 16x16 block of luma samples (y), diff --git a/thirdparty/libwebp/src/dec/vp8l_dec.c b/thirdparty/libwebp/src/dec/vp8l_dec.c index d3e27119ea..93615d4ed2 100644 --- a/thirdparty/libwebp/src/dec/vp8l_dec.c +++ b/thirdparty/libwebp/src/dec/vp8l_dec.c @@ -754,11 +754,11 @@ static WEBP_INLINE HTreeGroup* GetHtreeGroupForPos(VP8LMetadata* const hdr, typedef void (*ProcessRowsFunc)(VP8LDecoder* const dec, int row); -static void ApplyInverseTransforms(VP8LDecoder* const dec, int num_rows, +static void ApplyInverseTransforms(VP8LDecoder* const dec, + int start_row, int num_rows, const uint32_t* const rows) { int n = dec->next_transform_; const int cache_pixs = dec->width_ * num_rows; - const int start_row = dec->last_row_; const int end_row = start_row + num_rows; const uint32_t* rows_in = rows; uint32_t* const rows_out = dec->argb_cache_; @@ -789,8 +789,7 @@ static void ProcessRows(VP8LDecoder* const dec, int row) { VP8Io* const io = dec->io_; uint8_t* rows_data = (uint8_t*)dec->argb_cache_; const int in_stride = io->width * sizeof(uint32_t); // in unit of RGBA - - ApplyInverseTransforms(dec, num_rows, rows); + ApplyInverseTransforms(dec, dec->last_row_, num_rows, rows); if (!SetCropWindow(io, dec->last_row_, row, &rows_data, in_stride)) { // Nothing to output (this time). } else { @@ -1193,6 +1192,7 @@ static int DecodeImageData(VP8LDecoder* const dec, uint32_t* const data, VP8LFillBitWindow(br); dist_code = GetCopyDistance(dist_symbol, br); dist = PlaneCodeToDistance(width, dist_code); + if (VP8LIsEndOfStream(br)) break; if (src - data < (ptrdiff_t)dist || src_end - src < (ptrdiff_t)length) { goto Error; @@ -1553,7 +1553,7 @@ static void ExtractAlphaRows(VP8LDecoder* const dec, int last_row) { const int cache_pixs = width * num_rows_to_process; uint8_t* const dst = output + width * cur_row; const uint32_t* const src = dec->argb_cache_; - ApplyInverseTransforms(dec, num_rows_to_process, in); + ApplyInverseTransforms(dec, cur_row, num_rows_to_process, in); WebPExtractGreen(src, dst, cache_pixs); AlphaApplyFilter(alph_dec, cur_row, cur_row + num_rows_to_process, dst, width); diff --git a/thirdparty/libwebp/src/dec/vp8li_dec.h b/thirdparty/libwebp/src/dec/vp8li_dec.h index 0a4d613f99..72b2e86120 100644 --- a/thirdparty/libwebp/src/dec/vp8li_dec.h +++ b/thirdparty/libwebp/src/dec/vp8li_dec.h @@ -37,7 +37,7 @@ struct VP8LTransform { int bits_; // subsampling bits defining transform window. int xsize_; // transform window X index. int ysize_; // transform window Y index. - uint32_t *data_; // transform data. + uint32_t* data_; // transform data. }; typedef struct { @@ -48,23 +48,23 @@ typedef struct { int huffman_mask_; int huffman_subsample_bits_; int huffman_xsize_; - uint32_t *huffman_image_; + uint32_t* huffman_image_; int num_htree_groups_; - HTreeGroup *htree_groups_; - HuffmanCode *huffman_tables_; + HTreeGroup* htree_groups_; + HuffmanCode* huffman_tables_; } VP8LMetadata; typedef struct VP8LDecoder VP8LDecoder; struct VP8LDecoder { VP8StatusCode status_; VP8LDecodeState state_; - VP8Io *io_; + VP8Io* io_; - const WebPDecBuffer *output_; // shortcut to io->opaque->output + const WebPDecBuffer* output_; // shortcut to io->opaque->output - uint32_t *pixels_; // Internal data: either uint8_t* for alpha + uint32_t* pixels_; // Internal data: either uint8_t* for alpha // or uint32_t* for BGRA. - uint32_t *argb_cache_; // Scratch buffer for temporary BGRA storage. + uint32_t* argb_cache_; // Scratch buffer for temporary BGRA storage. VP8LBitReader br_; int incremental_; // if true, incremental decoding is expected @@ -86,8 +86,8 @@ struct VP8LDecoder { // or'd bitset storing the transforms types. uint32_t transforms_seen_; - uint8_t *rescaler_memory; // Working memory for rescaling work. - WebPRescaler *rescaler; // Common rescaler for all channels. + uint8_t* rescaler_memory; // Working memory for rescaling work. + WebPRescaler* rescaler; // Common rescaler for all channels. }; //------------------------------------------------------------------------------ diff --git a/thirdparty/libwebp/src/demux/demux.c b/thirdparty/libwebp/src/demux/demux.c index ab6433e54b..1b3cc2e0a8 100644 --- a/thirdparty/libwebp/src/demux/demux.c +++ b/thirdparty/libwebp/src/demux/demux.c @@ -24,8 +24,8 @@ #include "src/webp/format_constants.h" #define DMUX_MAJ_VERSION 1 -#define DMUX_MIN_VERSION 0 -#define DMUX_REV_VERSION 3 +#define DMUX_MIN_VERSION 1 +#define DMUX_REV_VERSION 0 typedef struct { size_t start_; // start location of the data diff --git a/thirdparty/libwebp/src/dsp/dec_neon.c b/thirdparty/libwebp/src/dsp/dec_neon.c index ffa697fcf9..239ec4167e 100644 --- a/thirdparty/libwebp/src/dsp/dec_neon.c +++ b/thirdparty/libwebp/src/dsp/dec_neon.c @@ -1361,7 +1361,8 @@ static void RD4_NEON(uint8_t* dst) { // Down-right const uint32_t J = dst[-1 + 1 * BPS]; const uint32_t K = dst[-1 + 2 * BPS]; const uint32_t L = dst[-1 + 3 * BPS]; - const uint64x1_t LKJI____ = vcreate_u64(L | (K << 8) | (J << 16) | (I << 24)); + const uint64x1_t LKJI____ = + vcreate_u64((uint64_t)L | (K << 8) | (J << 16) | (I << 24)); const uint64x1_t LKJIXABC = vorr_u64(LKJI____, ____XABC); const uint8x8_t KJIXABC_ = vreinterpret_u8_u64(vshr_n_u64(LKJIXABC, 8)); const uint8x8_t JIXABC__ = vreinterpret_u8_u64(vshr_n_u64(LKJIXABC, 16)); @@ -1427,10 +1428,16 @@ static WEBP_INLINE void DC8_NEON(uint8_t* dst, int do_top, int do_left) { if (do_top) { const uint8x8_t A = vld1_u8(dst - BPS); // top row +#if defined(__aarch64__) + const uint16x8_t B = vmovl_u8(A); + const uint16_t p2 = vaddvq_u16(B); + sum_top = vdupq_n_u16(p2); +#else const uint16x4_t p0 = vpaddl_u8(A); // cascading summation of the top const uint16x4_t p1 = vpadd_u16(p0, p0); const uint16x4_t p2 = vpadd_u16(p1, p1); sum_top = vcombine_u16(p2, p2); +#endif } if (do_left) { diff --git a/thirdparty/libwebp/src/dsp/dsp.h b/thirdparty/libwebp/src/dsp/dsp.h index fafc2d05d3..a784de334a 100644 --- a/thirdparty/libwebp/src/dsp/dsp.h +++ b/thirdparty/libwebp/src/dsp/dsp.h @@ -246,9 +246,9 @@ extern VP8Fdct VP8FTransform2; // performs two transforms at a time extern VP8WHT VP8FTransformWHT; // Predictions // *dst is the destination block. *top and *left can be NULL. -typedef void (*VP8IntraPreds)(uint8_t *dst, const uint8_t* left, +typedef void (*VP8IntraPreds)(uint8_t* dst, const uint8_t* left, const uint8_t* top); -typedef void (*VP8Intra4Preds)(uint8_t *dst, const uint8_t* top); +typedef void (*VP8Intra4Preds)(uint8_t* dst, const uint8_t* top); extern VP8Intra4Preds VP8EncPredLuma4; extern VP8IntraPreds VP8EncPredLuma16; extern VP8IntraPreds VP8EncPredChroma8; diff --git a/thirdparty/libwebp/src/dsp/lossless.c b/thirdparty/libwebp/src/dsp/lossless.c index d05af84e7b..aad5f43ec9 100644 --- a/thirdparty/libwebp/src/dsp/lossless.c +++ b/thirdparty/libwebp/src/dsp/lossless.c @@ -81,7 +81,7 @@ static WEBP_INLINE uint32_t ClampedAddSubtractHalf(uint32_t c0, uint32_t c1, // gcc <= 4.9 on ARM generates incorrect code in Select() when Sub3() is // inlined. -#if defined(__arm__) && LOCAL_GCC_VERSION <= 0x409 +#if defined(__arm__) && defined(__GNUC__) && LOCAL_GCC_VERSION <= 0x409 # define LOCAL_INLINE __attribute__ ((noinline)) #else # define LOCAL_INLINE WEBP_INLINE @@ -167,15 +167,20 @@ static uint32_t Predictor13_C(uint32_t left, const uint32_t* const top) { return pred; } -GENERATE_PREDICTOR_ADD(Predictor0_C, PredictorAdd0_C) +static void PredictorAdd0_C(const uint32_t* in, const uint32_t* upper, + int num_pixels, uint32_t* out) { + int x; + (void)upper; + for (x = 0; x < num_pixels; ++x) out[x] = VP8LAddPixels(in[x], ARGB_BLACK); +} static void PredictorAdd1_C(const uint32_t* in, const uint32_t* upper, int num_pixels, uint32_t* out) { int i; uint32_t left = out[-1]; + (void)upper; for (i = 0; i < num_pixels; ++i) { out[i] = left = VP8LAddPixels(in[i], left); } - (void)upper; } GENERATE_PREDICTOR_ADD(Predictor2_C, PredictorAdd2_C) GENERATE_PREDICTOR_ADD(Predictor3_C, PredictorAdd3_C) diff --git a/thirdparty/libwebp/src/dsp/lossless_common.h b/thirdparty/libwebp/src/dsp/lossless_common.h index a2648d1737..9c2ebe6809 100644 --- a/thirdparty/libwebp/src/dsp/lossless_common.h +++ b/thirdparty/libwebp/src/dsp/lossless_common.h @@ -177,6 +177,7 @@ uint32_t VP8LSubPixels(uint32_t a, uint32_t b) { static void PREDICTOR_ADD(const uint32_t* in, const uint32_t* upper, \ int num_pixels, uint32_t* out) { \ int x; \ + assert(upper != NULL); \ for (x = 0; x < num_pixels; ++x) { \ const uint32_t pred = (PREDICTOR)(out[x - 1], upper + x); \ out[x] = VP8LAddPixels(in[x], pred); \ @@ -189,6 +190,7 @@ static void PREDICTOR_ADD(const uint32_t* in, const uint32_t* upper, \ static void PREDICTOR_SUB(const uint32_t* in, const uint32_t* upper, \ int num_pixels, uint32_t* out) { \ int x; \ + assert(upper != NULL); \ for (x = 0; x < num_pixels; ++x) { \ const uint32_t pred = (PREDICTOR)(in[x - 1], upper + x); \ out[x] = VP8LSubPixels(in[x], pred); \ diff --git a/thirdparty/libwebp/src/dsp/lossless_enc_sse2.c b/thirdparty/libwebp/src/dsp/lossless_enc_sse2.c index 8adc52139b..e676f6fdc9 100644 --- a/thirdparty/libwebp/src/dsp/lossless_enc_sse2.c +++ b/thirdparty/libwebp/src/dsp/lossless_enc_sse2.c @@ -455,8 +455,9 @@ static void PredictorSub0_SSE2(const uint32_t* in, const uint32_t* upper, _mm_storeu_si128((__m128i*)&out[i], res); } if (i != num_pixels) { - VP8LPredictorsSub_C[0](in + i, upper + i, num_pixels - i, out + i); + VP8LPredictorsSub_C[0](in + i, NULL, num_pixels - i, out + i); } + (void)upper; } #define GENERATE_PREDICTOR_1(X, IN) \ diff --git a/thirdparty/libwebp/src/dsp/lossless_sse2.c b/thirdparty/libwebp/src/dsp/lossless_sse2.c index 17d7576419..aef0cee1b3 100644 --- a/thirdparty/libwebp/src/dsp/lossless_sse2.c +++ b/thirdparty/libwebp/src/dsp/lossless_sse2.c @@ -191,8 +191,9 @@ static void PredictorAdd0_SSE2(const uint32_t* in, const uint32_t* upper, _mm_storeu_si128((__m128i*)&out[i], res); } if (i != num_pixels) { - VP8LPredictorsAdd_C[0](in + i, upper + i, num_pixels - i, out + i); + VP8LPredictorsAdd_C[0](in + i, NULL, num_pixels - i, out + i); } + (void)upper; } // Predictor1: left. diff --git a/thirdparty/libwebp/src/dsp/upsampling_msa.c b/thirdparty/libwebp/src/dsp/upsampling_msa.c index 99eea70e7d..f2e03e85e9 100644 --- a/thirdparty/libwebp/src/dsp/upsampling_msa.c +++ b/thirdparty/libwebp/src/dsp/upsampling_msa.c @@ -576,9 +576,9 @@ static void FUNC_NAME(const uint8_t* top_y, const uint8_t* bot_y, \ const uint32_t l_uv = ((cur_u[0]) | ((cur_v[0]) << 16)); \ const uint32_t uv0 = (3 * tl_uv + l_uv + 0x00020002u) >> 2; \ const uint8_t* ptop_y = &top_y[1]; \ - uint8_t *ptop_dst = top_dst + XSTEP; \ + uint8_t* ptop_dst = top_dst + XSTEP; \ const uint8_t* pbot_y = &bot_y[1]; \ - uint8_t *pbot_dst = bot_dst + XSTEP; \ + uint8_t* pbot_dst = bot_dst + XSTEP; \ \ FUNC(top_y[0], uv0 & 0xff, (uv0 >> 16), top_dst); \ if (bot_y != NULL) { \ diff --git a/thirdparty/libwebp/src/dsp/upsampling_neon.c b/thirdparty/libwebp/src/dsp/upsampling_neon.c index 17cbc9f911..6ba71a7de5 100644 --- a/thirdparty/libwebp/src/dsp/upsampling_neon.c +++ b/thirdparty/libwebp/src/dsp/upsampling_neon.c @@ -58,8 +58,8 @@ } while (0) // Turn the macro into a function for reducing code-size when non-critical -static void Upsample16Pixels_NEON(const uint8_t *r1, const uint8_t *r2, - uint8_t *out) { +static void Upsample16Pixels_NEON(const uint8_t* r1, const uint8_t* r2, + uint8_t* out) { UPSAMPLE_16PIXELS(r1, r2, out); } @@ -190,14 +190,14 @@ static const int16_t kCoeffs1[4] = { 19077, 26149, 6419, 13320 }; } #define NEON_UPSAMPLE_FUNC(FUNC_NAME, FMT, XSTEP) \ -static void FUNC_NAME(const uint8_t *top_y, const uint8_t *bottom_y, \ - const uint8_t *top_u, const uint8_t *top_v, \ - const uint8_t *cur_u, const uint8_t *cur_v, \ - uint8_t *top_dst, uint8_t *bottom_dst, int len) { \ +static void FUNC_NAME(const uint8_t* top_y, const uint8_t* bottom_y, \ + const uint8_t* top_u, const uint8_t* top_v, \ + const uint8_t* cur_u, const uint8_t* cur_v, \ + uint8_t* top_dst, uint8_t* bottom_dst, int len) { \ int block; \ /* 16 byte aligned array to cache reconstructed u and v */ \ uint8_t uv_buf[2 * 32 + 15]; \ - uint8_t *const r_uv = (uint8_t*)((uintptr_t)(uv_buf + 15) & ~15); \ + uint8_t* const r_uv = (uint8_t*)((uintptr_t)(uv_buf + 15) & ~15); \ const int uv_len = (len + 1) >> 1; \ /* 9 pixels must be read-able for each block */ \ const int num_blocks = (uv_len - 1) >> 3; \ diff --git a/thirdparty/libwebp/src/enc/histogram_enc.c b/thirdparty/libwebp/src/enc/histogram_enc.c index d89b98524a..a4e6bf3a98 100644 --- a/thirdparty/libwebp/src/enc/histogram_enc.c +++ b/thirdparty/libwebp/src/enc/histogram_enc.c @@ -641,7 +641,7 @@ static void HistogramAnalyzeEntropyBin(VP8LHistogramSet* const image_histo, // Merges some histograms with same bin_id together if it's advantageous. // Sets the remaining histograms to NULL. static void HistogramCombineEntropyBin(VP8LHistogramSet* const image_histo, - int *num_used, + int* num_used, const uint16_t* const clusters, uint16_t* const cluster_mappings, VP8LHistogram* cur_combo, diff --git a/thirdparty/libwebp/src/enc/picture_csp_enc.c b/thirdparty/libwebp/src/enc/picture_csp_enc.c index 02d9df76d5..718e014ed2 100644 --- a/thirdparty/libwebp/src/enc/picture_csp_enc.c +++ b/thirdparty/libwebp/src/enc/picture_csp_enc.c @@ -29,11 +29,15 @@ #define USE_INVERSE_ALPHA_TABLE #ifdef WORDS_BIGENDIAN -#define ALPHA_OFFSET 0 // uint32_t 0xff000000 is 0xff,00,00,00 in memory +// uint32_t 0xff000000 is 0xff,00,00,00 in memory +#define CHANNEL_OFFSET(i) (i) #else -#define ALPHA_OFFSET 3 // uint32_t 0xff000000 is 0x00,00,00,ff in memory +// uint32_t 0xff000000 is 0x00,00,00,ff in memory +#define CHANNEL_OFFSET(i) (3-(i)) #endif +#define ALPHA_OFFSET CHANNEL_OFFSET(0) + //------------------------------------------------------------------------------ // Detection of non-trivial transparency @@ -997,10 +1001,10 @@ static int PictureARGBToYUVA(WebPPicture* picture, WebPEncCSP colorspace, return WebPEncodingSetError(picture, VP8_ENC_ERROR_INVALID_CONFIGURATION); } else { const uint8_t* const argb = (const uint8_t*)picture->argb; - const uint8_t* const a = argb + (0 ^ ALPHA_OFFSET); - const uint8_t* const r = argb + (1 ^ ALPHA_OFFSET); - const uint8_t* const g = argb + (2 ^ ALPHA_OFFSET); - const uint8_t* const b = argb + (3 ^ ALPHA_OFFSET); + const uint8_t* const a = argb + CHANNEL_OFFSET(0); + const uint8_t* const r = argb + CHANNEL_OFFSET(1); + const uint8_t* const g = argb + CHANNEL_OFFSET(2); + const uint8_t* const b = argb + CHANNEL_OFFSET(3); picture->colorspace = WEBP_YUV420; return ImportYUVAFromRGBA(r, g, b, a, 4, 4 * picture->argb_stride, @@ -1050,7 +1054,7 @@ int WebPPictureYUVAToARGB(WebPPicture* picture) { const int height = picture->height; const int argb_stride = 4 * picture->argb_stride; uint8_t* dst = (uint8_t*)picture->argb; - const uint8_t *cur_u = picture->u, *cur_v = picture->v, *cur_y = picture->y; + const uint8_t* cur_u = picture->u, *cur_v = picture->v, *cur_y = picture->y; WebPUpsampleLinePairFunc upsample = WebPGetLinePairConverter(ALPHA_OFFSET > 0); diff --git a/thirdparty/libwebp/src/enc/vp8i_enc.h b/thirdparty/libwebp/src/enc/vp8i_enc.h index 24e1944610..fedcaeea27 100644 --- a/thirdparty/libwebp/src/enc/vp8i_enc.h +++ b/thirdparty/libwebp/src/enc/vp8i_enc.h @@ -31,8 +31,8 @@ extern "C" { // version numbers #define ENC_MAJ_VERSION 1 -#define ENC_MIN_VERSION 0 -#define ENC_REV_VERSION 3 +#define ENC_MIN_VERSION 1 +#define ENC_REV_VERSION 0 enum { MAX_LF_LEVELS = 64, // Maximum loop filter level MAX_VARIABLE_LEVEL = 67, // last (inclusive) level with variable cost @@ -249,7 +249,7 @@ typedef struct { int percent0_; // saved initial progress percent DError left_derr_; // left error diffusion (u/v) - DError *top_derr_; // top diffusion error - NULL if disabled + DError* top_derr_; // top diffusion error - NULL if disabled uint8_t* y_left_; // left luma samples (addressable from index -1 to 15). uint8_t* u_left_; // left u samples (addressable from index -1 to 7) diff --git a/thirdparty/libwebp/src/mux/muxi.h b/thirdparty/libwebp/src/mux/muxi.h index 7bc0b07e9b..ad3e1bdb97 100644 --- a/thirdparty/libwebp/src/mux/muxi.h +++ b/thirdparty/libwebp/src/mux/muxi.h @@ -28,8 +28,8 @@ extern "C" { // Defines and constants. #define MUX_MAJ_VERSION 1 -#define MUX_MIN_VERSION 0 -#define MUX_REV_VERSION 3 +#define MUX_MIN_VERSION 1 +#define MUX_REV_VERSION 0 // Chunk object. typedef struct WebPChunk WebPChunk; diff --git a/thirdparty/libwebp/src/mux/muxread.c b/thirdparty/libwebp/src/mux/muxread.c index 268f6acb53..ae3b876bc5 100644 --- a/thirdparty/libwebp/src/mux/muxread.c +++ b/thirdparty/libwebp/src/mux/muxread.c @@ -100,7 +100,7 @@ static int MuxImageParse(const WebPChunk* const chunk, int copy_data, WebPMuxImage* const wpi) { const uint8_t* bytes = chunk->data_.bytes; size_t size = chunk->data_.size; - const uint8_t* const last = bytes + size; + const uint8_t* const last = (bytes == NULL) ? NULL : bytes + size; WebPChunk subchunk; size_t subchunk_size; WebPChunk** unknown_chunk_list = &wpi->unknown_; diff --git a/thirdparty/libwebp/src/utils/color_cache_utils.h b/thirdparty/libwebp/src/utils/color_cache_utils.h index ec21d5199b..b45d47c2d5 100644 --- a/thirdparty/libwebp/src/utils/color_cache_utils.h +++ b/thirdparty/libwebp/src/utils/color_cache_utils.h @@ -26,7 +26,7 @@ extern "C" { // Main color cache struct. typedef struct { - uint32_t *colors_; // color entries + uint32_t* colors_; // color entries int hash_shift_; // Hash shift: 32 - hash_bits_. int hash_bits_; } VP8LColorCache; diff --git a/thirdparty/libwebp/src/utils/thread_utils.c b/thirdparty/libwebp/src/utils/thread_utils.c index 438296b45f..4e470e17ac 100644 --- a/thirdparty/libwebp/src/utils/thread_utils.c +++ b/thirdparty/libwebp/src/utils/thread_utils.c @@ -73,7 +73,7 @@ typedef struct { #endif static int pthread_create(pthread_t* const thread, const void* attr, - unsigned int (__stdcall *start)(void*), void* arg) { + unsigned int (__stdcall* start)(void*), void* arg) { (void)attr; #ifdef USE_CREATE_THREAD *thread = CreateThread(NULL, /* lpThreadAttributes */ diff --git a/thirdparty/libwebp/src/utils/utils.c b/thirdparty/libwebp/src/utils/utils.c index 44d5c14f01..764f752b82 100644 --- a/thirdparty/libwebp/src/utils/utils.c +++ b/thirdparty/libwebp/src/utils/utils.c @@ -216,9 +216,14 @@ void WebPSafeFree(void* const ptr) { free(ptr); } -// Public API function. +// Public API functions. + +void* WebPMalloc(size_t size) { + return WebPSafeMalloc(1, size); +} + void WebPFree(void* ptr) { - free(ptr); + WebPSafeFree(ptr); } //------------------------------------------------------------------------------ diff --git a/thirdparty/libwebp/src/webp/decode.h b/thirdparty/libwebp/src/webp/decode.h index ae8bfe840e..80dd0ef0cc 100644 --- a/thirdparty/libwebp/src/webp/decode.h +++ b/thirdparty/libwebp/src/webp/decode.h @@ -20,7 +20,7 @@ extern "C" { #endif -#define WEBP_DECODER_ABI_VERSION 0x0208 // MAJOR(8b) + MINOR(8b) +#define WEBP_DECODER_ABI_VERSION 0x0209 // MAJOR(8b) + MINOR(8b) // Note: forward declaring enumerations is not allowed in (strict) C and C++, // the types are left here for reference. @@ -91,9 +91,6 @@ WEBP_EXTERN uint8_t* WebPDecodeYUV(const uint8_t* data, size_t data_size, uint8_t** u, uint8_t** v, int* stride, int* uv_stride); -// Releases memory returned by the WebPDecode*() functions above. -WEBP_EXTERN void WebPFree(void* ptr); - // These five functions are variants of the above ones, that decode the image // directly into a pre-allocated buffer 'output_buffer'. The maximum storage // available in this buffer is indicated by 'output_buffer_size'. If this diff --git a/thirdparty/libwebp/src/webp/encode.h b/thirdparty/libwebp/src/webp/encode.h index 339f8810aa..655166e7d4 100644 --- a/thirdparty/libwebp/src/webp/encode.h +++ b/thirdparty/libwebp/src/webp/encode.h @@ -20,7 +20,7 @@ extern "C" { #endif -#define WEBP_ENCODER_ABI_VERSION 0x020e // MAJOR(8b) + MINOR(8b) +#define WEBP_ENCODER_ABI_VERSION 0x020f // MAJOR(8b) + MINOR(8b) // Note: forward declaring enumerations is not allowed in (strict) C and C++, // the types are left here for reference. @@ -79,9 +79,6 @@ WEBP_EXTERN size_t WebPEncodeLosslessBGRA(const uint8_t* bgra, int width, int height, int stride, uint8_t** output); -// Releases memory returned by the WebPEncode*() functions above. -WEBP_EXTERN void WebPFree(void* ptr); - //------------------------------------------------------------------------------ // Coding parameters @@ -306,7 +303,7 @@ struct WebPPicture { // YUV input (mostly used for input to lossy compression) WebPEncCSP colorspace; // colorspace: should be YUV420 for now (=Y'CbCr). int width, height; // dimensions (less or equal to WEBP_MAX_DIMENSION) - uint8_t *y, *u, *v; // pointers to luma/chroma planes. + uint8_t* y, *u, *v; // pointers to luma/chroma planes. int y_stride, uv_stride; // luma/chroma strides. uint8_t* a; // pointer to the alpha plane int a_stride; // stride of the alpha plane @@ -350,7 +347,7 @@ struct WebPPicture { uint32_t pad3[3]; // padding for later use // Unused for now - uint8_t *pad4, *pad5; + uint8_t* pad4, *pad5; uint32_t pad6[8]; // padding for later use // PRIVATE FIELDS diff --git a/thirdparty/libwebp/src/webp/mux.h b/thirdparty/libwebp/src/webp/mux.h index 66096a92e0..7d27489a40 100644 --- a/thirdparty/libwebp/src/webp/mux.h +++ b/thirdparty/libwebp/src/webp/mux.h @@ -57,7 +57,7 @@ extern "C" { WebPMuxGetChunk(mux, "ICCP", &icc_profile); // ... (Consume icc_data). WebPMuxDelete(mux); - free(data); + WebPFree(data); */ // Note: forward declaring enumerations is not allowed in (strict) C and C++, @@ -245,7 +245,7 @@ WEBP_EXTERN WebPMuxError WebPMuxPushFrame( WebPMux* mux, const WebPMuxFrameInfo* frame, int copy_data); // Gets the nth frame from the mux object. -// The content of 'frame->bitstream' is allocated using malloc(), and NOT +// The content of 'frame->bitstream' is allocated using WebPMalloc(), and NOT // owned by the 'mux' object. It MUST be deallocated by the caller by calling // WebPDataClear(). // nth=0 has a special meaning - last position. @@ -376,10 +376,10 @@ WEBP_EXTERN WebPMuxError WebPMuxNumChunks(const WebPMux* mux, // Assembles all chunks in WebP RIFF format and returns in 'assembled_data'. // This function also validates the mux object. // Note: The content of 'assembled_data' will be ignored and overwritten. -// Also, the content of 'assembled_data' is allocated using malloc(), and NOT -// owned by the 'mux' object. It MUST be deallocated by the caller by calling -// WebPDataClear(). It's always safe to call WebPDataClear() upon return, -// even in case of error. +// Also, the content of 'assembled_data' is allocated using WebPMalloc(), and +// NOT owned by the 'mux' object. It MUST be deallocated by the caller by +// calling WebPDataClear(). It's always safe to call WebPDataClear() upon +// return, even in case of error. // Parameters: // mux - (in/out) object whose chunks are to be assembled // assembled_data - (out) assembled WebP data diff --git a/thirdparty/libwebp/src/webp/mux_types.h b/thirdparty/libwebp/src/webp/mux_types.h index ceea77dfc6..2fe8195839 100644 --- a/thirdparty/libwebp/src/webp/mux_types.h +++ b/thirdparty/libwebp/src/webp/mux_types.h @@ -14,7 +14,6 @@ #ifndef WEBP_WEBP_MUX_TYPES_H_ #define WEBP_WEBP_MUX_TYPES_H_ -#include <stdlib.h> // free() #include <string.h> // memset() #include "./types.h" @@ -56,6 +55,7 @@ typedef enum WebPMuxAnimBlend { // Data type used to describe 'raw' data, e.g., chunk data // (ICC profile, metadata) and WebP compressed image data. +// 'bytes' memory must be allocated using WebPMalloc() and such. struct WebPData { const uint8_t* bytes; size_t size; @@ -68,11 +68,11 @@ static WEBP_INLINE void WebPDataInit(WebPData* webp_data) { } } -// Clears the contents of the 'webp_data' object by calling free(). Does not -// deallocate the object itself. +// Clears the contents of the 'webp_data' object by calling WebPFree(). +// Does not deallocate the object itself. static WEBP_INLINE void WebPDataClear(WebPData* webp_data) { if (webp_data != NULL) { - free((void*)webp_data->bytes); + WebPFree((void*)webp_data->bytes); WebPDataInit(webp_data); } } @@ -83,7 +83,7 @@ static WEBP_INLINE int WebPDataCopy(const WebPData* src, WebPData* dst) { if (src == NULL || dst == NULL) return 0; WebPDataInit(dst); if (src->bytes != NULL && src->size != 0) { - dst->bytes = (uint8_t*)malloc(src->size); + dst->bytes = (uint8_t*)WebPMalloc(src->size); if (dst->bytes == NULL) return 0; memcpy((void*)dst->bytes, src->bytes, src->size); dst->size = src->size; diff --git a/thirdparty/libwebp/src/webp/types.h b/thirdparty/libwebp/src/webp/types.h index 0ce2622e41..47f7f2b007 100644 --- a/thirdparty/libwebp/src/webp/types.h +++ b/thirdparty/libwebp/src/webp/types.h @@ -7,7 +7,7 @@ // be found in the AUTHORS file in the root of the source tree. // ----------------------------------------------------------------------------- // -// Common types +// Common types + memory wrappers // // Author: Skal (pascal.massimino@gmail.com) @@ -49,4 +49,20 @@ typedef long long int int64_t; // Macro to check ABI compatibility (same major revision number) #define WEBP_ABI_IS_INCOMPATIBLE(a, b) (((a) >> 8) != ((b) >> 8)) +#ifdef __cplusplus +extern "C" { +#endif + +// Allocates 'size' bytes of memory. Returns NULL upon error. Memory +// must be deallocated by calling WebPFree(). This function is made available +// by the core 'libwebp' library. +WEBP_EXTERN void* WebPMalloc(size_t size); + +// Releases memory returned by the WebPDecode*() functions (from decode.h). +WEBP_EXTERN void WebPFree(void* ptr); + +#ifdef __cplusplus +} // extern "C" +#endif + #endif // WEBP_WEBP_TYPES_H_ diff --git a/thirdparty/mbedtls/include/mbedtls/bignum.h b/thirdparty/mbedtls/include/mbedtls/bignum.h index 1c8607264f..22b373113e 100644 --- a/thirdparty/mbedtls/include/mbedtls/bignum.h +++ b/thirdparty/mbedtls/include/mbedtls/bignum.h @@ -184,7 +184,7 @@ extern "C" { */ typedef struct mbedtls_mpi { - int s; /*!< integer sign */ + int s; /*!< Sign: -1 if the mpi is negative, 1 otherwise */ size_t n; /*!< total # of limbs */ mbedtls_mpi_uint *p; /*!< pointer to limbs */ } @@ -560,6 +560,24 @@ int mbedtls_mpi_cmp_abs( const mbedtls_mpi *X, const mbedtls_mpi *Y ); int mbedtls_mpi_cmp_mpi( const mbedtls_mpi *X, const mbedtls_mpi *Y ); /** + * \brief Check if an MPI is less than the other in constant time. + * + * \param X The left-hand MPI. This must point to an initialized MPI + * with the same allocated length as Y. + * \param Y The right-hand MPI. This must point to an initialized MPI + * with the same allocated length as X. + * \param ret The result of the comparison: + * \c 1 if \p X is less than \p Y. + * \c 0 if \p X is greater than or equal to \p Y. + * + * \return 0 on success. + * \return MBEDTLS_ERR_MPI_BAD_INPUT_DATA if the allocated length of + * the two input MPIs is not the same. + */ +int mbedtls_mpi_lt_mpi_ct( const mbedtls_mpi *X, const mbedtls_mpi *Y, + unsigned *ret ); + +/** * \brief Compare an MPI with an integer. * * \param X The left-hand MPI. This must point to an initialized MPI. diff --git a/thirdparty/mbedtls/include/mbedtls/check_config.h b/thirdparty/mbedtls/include/mbedtls/check_config.h index 6eabcc8748..d076c2352f 100644 --- a/thirdparty/mbedtls/include/mbedtls/check_config.h +++ b/thirdparty/mbedtls/include/mbedtls/check_config.h @@ -281,6 +281,14 @@ #error "MBEDTLS_MEMORY_BUFFER_ALLOC_C defined, but not all prerequisites" #endif +#if defined(MBEDTLS_MEMORY_BACKTRACE) && !defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) +#error "MBEDTLS_MEMORY_BACKTRACE defined, but not all prerequesites" +#endif + +#if defined(MBEDTLS_MEMORY_DEBUG) && !defined(MBEDTLS_MEMORY_BUFFER_ALLOC_C) +#error "MBEDTLS_MEMORY_DEBUG defined, but not all prerequesites" +#endif + #if defined(MBEDTLS_PADLOCK_C) && !defined(MBEDTLS_HAVE_ASM) #error "MBEDTLS_PADLOCK_C defined, but not all prerequisites" #endif diff --git a/thirdparty/mbedtls/include/mbedtls/config.h b/thirdparty/mbedtls/include/mbedtls/config.h index 0cc502cd79..8d9c31a504 100644 --- a/thirdparty/mbedtls/include/mbedtls/config.h +++ b/thirdparty/mbedtls/include/mbedtls/config.h @@ -689,6 +689,13 @@ #define MBEDTLS_CIPHER_PADDING_ZEROS_AND_LEN #define MBEDTLS_CIPHER_PADDING_ZEROS +/** \def MBEDTLS_CTR_DRBG_USE_128_BIT_KEY + * + * Uncomment this macro to use a 128-bit key in the CTR_DRBG module. + * By default, CTR_DRBG uses a 256-bit key. + */ +//#define MBEDTLS_CTR_DRBG_USE_128_BIT_KEY + /** * \def MBEDTLS_ENABLE_WEAK_CIPHERSUITES * @@ -2149,7 +2156,11 @@ * * Enable the CTR_DRBG AES-based random generator. * The CTR_DRBG generator uses AES-256 by default. - * To use AES-128 instead, enable MBEDTLS_CTR_DRBG_USE_128_BIT_KEY below. + * To use AES-128 instead, enable \c MBEDTLS_CTR_DRBG_USE_128_BIT_KEY above. + * + * \note To achieve a 256-bit security strength with CTR_DRBG, + * you must use AES-256 *and* use sufficient entropy. + * See ctr_drbg.h for more details. * * Module: library/ctr_drbg.c * Caller: @@ -3043,7 +3054,6 @@ //#define MBEDTLS_CTR_DRBG_MAX_INPUT 256 /**< Maximum number of additional input bytes */ //#define MBEDTLS_CTR_DRBG_MAX_REQUEST 1024 /**< Maximum number of requested bytes per call */ //#define MBEDTLS_CTR_DRBG_MAX_SEED_INPUT 384 /**< Maximum size of (re)seed buffer */ -//#define MBEDTLS_CTR_DRBG_USE_128_BIT_KEY /**< Use 128-bit key for CTR_DRBG - may reduce security (see ctr_drbg.h) */ /* HMAC_DRBG options */ //#define MBEDTLS_HMAC_DRBG_RESEED_INTERVAL 10000 /**< Interval before reseed is performed by default */ diff --git a/thirdparty/mbedtls/include/mbedtls/ctr_drbg.h b/thirdparty/mbedtls/include/mbedtls/ctr_drbg.h index cc3df7b113..e0b5ed9c93 100644 --- a/thirdparty/mbedtls/include/mbedtls/ctr_drbg.h +++ b/thirdparty/mbedtls/include/mbedtls/ctr_drbg.h @@ -1,7 +1,8 @@ /** * \file ctr_drbg.h * - * \brief This file contains CTR_DRBG definitions and functions. + * \brief This file contains definitions and functions for the + * CTR_DRBG pseudorandom generator. * * CTR_DRBG is a standardized way of building a PRNG from a block-cipher * in counter mode operation, as defined in <em>NIST SP 800-90A: @@ -9,13 +10,35 @@ * Bit Generators</em>. * * The Mbed TLS implementation of CTR_DRBG uses AES-256 (default) or AES-128 - * as the underlying block cipher. - * - * \warning Using 128-bit keys for CTR_DRBG limits the security of generated - * keys and operations that use random values generated to 128-bit security. + * (if \c MBEDTLS_CTR_DRBG_USE_128_BIT_KEY is enabled at compile time) + * as the underlying block cipher, with a derivation function. + * The initial seeding grabs #MBEDTLS_CTR_DRBG_ENTROPY_LEN bytes of entropy. + * See the documentation of mbedtls_ctr_drbg_seed() for more details. + * + * Based on NIST SP 800-90A §10.2.1 table 3 and NIST SP 800-57 part 1 table 2, + * here are the security strengths achieved in typical configuration: + * - 256 bits under the default configuration of the library, with AES-256 + * and with #MBEDTLS_CTR_DRBG_ENTROPY_LEN set to 48 or more. + * - 256 bits if AES-256 is used, #MBEDTLS_CTR_DRBG_ENTROPY_LEN is set + * to 32 or more, and the DRBG is initialized with an explicit + * nonce in the \c custom parameter to mbedtls_ctr_drbg_seed(). + * - 128 bits if AES-256 is used but #MBEDTLS_CTR_DRBG_ENTROPY_LEN is + * between 24 and 47 and the DRBG is not initialized with an explicit + * nonce (see mbedtls_ctr_drbg_seed()). + * - 128 bits if AES-128 is used (\c MBEDTLS_CTR_DRBG_USE_128_BIT_KEY enabled) + * and #MBEDTLS_CTR_DRBG_ENTROPY_LEN is set to 24 or more (which is + * always the case unless it is explicitly set to a different value + * in config.h). + * + * Note that the value of #MBEDTLS_CTR_DRBG_ENTROPY_LEN defaults to: + * - \c 48 if the module \c MBEDTLS_SHA512_C is enabled and the symbol + * \c MBEDTLS_ENTROPY_FORCE_SHA256 is disabled at compile time. + * This is the default configuration of the library. + * - \c 32 if the module \c MBEDTLS_SHA512_C is disabled at compile time. + * - \c 32 if \c MBEDTLS_ENTROPY_FORCE_SHA256 is enabled at compile time. */ /* - * Copyright (C) 2006-2018, Arm Limited (or its affiliates), All Rights Reserved + * Copyright (C) 2006-2019, Arm Limited (or its affiliates), All Rights Reserved * SPDX-License-Identifier: Apache-2.0 * * Licensed under the Apache License, Version 2.0 (the "License"); you may @@ -56,9 +79,19 @@ #define MBEDTLS_CTR_DRBG_BLOCKSIZE 16 /**< The block size used by the cipher. */ #if defined(MBEDTLS_CTR_DRBG_USE_128_BIT_KEY) -#define MBEDTLS_CTR_DRBG_KEYSIZE 16 /**< The key size used by the cipher (compile-time choice: 128 bits). */ +#define MBEDTLS_CTR_DRBG_KEYSIZE 16 +/**< The key size in bytes used by the cipher. + * + * Compile-time choice: 16 bytes (128 bits) + * because #MBEDTLS_CTR_DRBG_USE_128_BIT_KEY is enabled. + */ #else -#define MBEDTLS_CTR_DRBG_KEYSIZE 32 /**< The key size used by the cipher (compile-time choice: 256 bits). */ +#define MBEDTLS_CTR_DRBG_KEYSIZE 32 +/**< The key size in bytes used by the cipher. + * + * Compile-time choice: 32 bytes (256 bits) + * because \c MBEDTLS_CTR_DRBG_USE_128_BIT_KEY is disabled. + */ #endif #define MBEDTLS_CTR_DRBG_KEYBITS ( MBEDTLS_CTR_DRBG_KEYSIZE * 8 ) /**< The key size for the DRBG operation, in bits. */ @@ -73,21 +106,31 @@ * \{ */ +/** \def MBEDTLS_CTR_DRBG_ENTROPY_LEN + * + * \brief The amount of entropy used per seed by default, in bytes. + */ #if !defined(MBEDTLS_CTR_DRBG_ENTROPY_LEN) #if defined(MBEDTLS_SHA512_C) && !defined(MBEDTLS_ENTROPY_FORCE_SHA256) +/** This is 48 bytes because the entropy module uses SHA-512 + * (\c MBEDTLS_ENTROPY_FORCE_SHA256 is disabled). + */ #define MBEDTLS_CTR_DRBG_ENTROPY_LEN 48 -/**< The amount of entropy used per seed by default: - * <ul><li>48 with SHA-512.</li> - * <li>32 with SHA-256.</li></ul> + +#else /* defined(MBEDTLS_SHA512_C) && !defined(MBEDTLS_ENTROPY_FORCE_SHA256) */ + +/** This is 32 bytes because the entropy module uses SHA-256 + * (the SHA512 module is disabled or + * \c MBEDTLS_ENTROPY_FORCE_SHA256 is enabled). */ -#else -#define MBEDTLS_CTR_DRBG_ENTROPY_LEN 32 -/**< Amount of entropy used per seed by default: - * <ul><li>48 with SHA-512.</li> - * <li>32 with SHA-256.</li></ul> +#if !defined(MBEDTLS_CTR_DRBG_USE_128_BIT_KEY) +/** \warning To achieve a 256-bit security strength, you must pass a nonce + * to mbedtls_ctr_drbg_seed(). */ -#endif -#endif +#endif /* !defined(MBEDTLS_CTR_DRBG_USE_128_BIT_KEY) */ +#define MBEDTLS_CTR_DRBG_ENTROPY_LEN 32 +#endif /* defined(MBEDTLS_SHA512_C) && !defined(MBEDTLS_ENTROPY_FORCE_SHA256) */ +#endif /* !defined(MBEDTLS_CTR_DRBG_ENTROPY_LEN) */ #if !defined(MBEDTLS_CTR_DRBG_RESEED_INTERVAL) #define MBEDTLS_CTR_DRBG_RESEED_INTERVAL 10000 @@ -106,7 +149,7 @@ #if !defined(MBEDTLS_CTR_DRBG_MAX_SEED_INPUT) #define MBEDTLS_CTR_DRBG_MAX_SEED_INPUT 384 -/**< The maximum size of seed or reseed buffer. */ +/**< The maximum size of seed or reseed buffer in bytes. */ #endif /* \} name SECTION: Module settings */ @@ -164,17 +207,68 @@ void mbedtls_ctr_drbg_init( mbedtls_ctr_drbg_context *ctx ); * \brief This function seeds and sets up the CTR_DRBG * entropy source for future reseeds. * - * \note Personalization data can be provided in addition to the more generic - * entropy source, to make this instantiation as unique as possible. - * + * A typical choice for the \p f_entropy and \p p_entropy parameters is + * to use the entropy module: + * - \p f_entropy is mbedtls_entropy_func(); + * - \p p_entropy is an instance of ::mbedtls_entropy_context initialized + * with mbedtls_entropy_init() (which registers the platform's default + * entropy sources). + * + * The entropy length is #MBEDTLS_CTR_DRBG_ENTROPY_LEN by default. + * You can override it by calling mbedtls_ctr_drbg_set_entropy_len(). + * + * You can provide a personalization string in addition to the + * entropy source, to make this instantiation as unique as possible. + * + * \note The _seed_material_ value passed to the derivation + * function in the CTR_DRBG Instantiate Process + * described in NIST SP 800-90A §10.2.1.3.2 + * is the concatenation of the string obtained from + * calling \p f_entropy and the \p custom string. + * The origin of the nonce depends on the value of + * the entropy length relative to the security strength. + * - If the entropy length is at least 1.5 times the + * security strength then the nonce is taken from the + * string obtained with \p f_entropy. + * - If the entropy length is less than the security + * strength, then the nonce is taken from \p custom. + * In this case, for compliance with SP 800-90A, + * you must pass a unique value of \p custom at + * each invocation. See SP 800-90A §8.6.7 for more + * details. + */ +#if MBEDTLS_CTR_DRBG_ENTROPY_LEN < MBEDTLS_CTR_DRBG_KEYSIZE * 3 / 2 +/** \warning When #MBEDTLS_CTR_DRBG_ENTROPY_LEN is less than + * #MBEDTLS_CTR_DRBG_KEYSIZE * 3 / 2, to achieve the + * maximum security strength permitted by CTR_DRBG, + * you must pass a value of \p custom that is a nonce: + * this value must never be repeated in subsequent + * runs of the same application or on a different + * device. + */ +#endif +/** * \param ctx The CTR_DRBG context to seed. + * It must have been initialized with + * mbedtls_ctr_drbg_init(). + * After a successful call to mbedtls_ctr_drbg_seed(), + * you may not call mbedtls_ctr_drbg_seed() again on + * the same context unless you call + * mbedtls_ctr_drbg_free() and mbedtls_ctr_drbg_init() + * again first. * \param f_entropy The entropy callback, taking as arguments the * \p p_entropy context, the buffer to fill, and the - length of the buffer. - * \param p_entropy The entropy context. - * \param custom Personalization data, that is device-specific - identifiers. Can be NULL. - * \param len The length of the personalization data. + * length of the buffer. + * \p f_entropy is always called with a buffer size + * equal to the entropy length. + * \param p_entropy The entropy context to pass to \p f_entropy. + * \param custom The personalization string. + * This can be \c NULL, in which case the personalization + * string is empty regardless of the value of \p len. + * \param len The length of the personalization string. + * This must be at most + * #MBEDTLS_CTR_DRBG_MAX_SEED_INPUT + * - #MBEDTLS_CTR_DRBG_ENTROPY_LEN. * * \return \c 0 on success. * \return #MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED on failure. @@ -197,7 +291,8 @@ void mbedtls_ctr_drbg_free( mbedtls_ctr_drbg_context *ctx ); * The default value is off. * * \note If enabled, entropy is gathered at the beginning of - * every call to mbedtls_ctr_drbg_random_with_add(). + * every call to mbedtls_ctr_drbg_random_with_add() + * or mbedtls_ctr_drbg_random(). * Only use this if your entropy source has sufficient * throughput. * @@ -209,18 +304,37 @@ void mbedtls_ctr_drbg_set_prediction_resistance( mbedtls_ctr_drbg_context *ctx, /** * \brief This function sets the amount of entropy grabbed on each - * seed or reseed. The default value is - * #MBEDTLS_CTR_DRBG_ENTROPY_LEN. + * seed or reseed. + * + * The default value is #MBEDTLS_CTR_DRBG_ENTROPY_LEN. + * + * \note The security strength of CTR_DRBG is bounded by the + * entropy length. Thus: + * - When using AES-256 + * (\c MBEDTLS_CTR_DRBG_USE_128_BIT_KEY is disabled, + * which is the default), + * \p len must be at least 32 (in bytes) + * to achieve a 256-bit strength. + * - When using AES-128 + * (\c MBEDTLS_CTR_DRBG_USE_128_BIT_KEY is enabled) + * \p len must be at least 16 (in bytes) + * to achieve a 128-bit strength. * * \param ctx The CTR_DRBG context. - * \param len The amount of entropy to grab. + * \param len The amount of entropy to grab, in bytes. + * This must be at most #MBEDTLS_CTR_DRBG_MAX_SEED_INPUT. */ void mbedtls_ctr_drbg_set_entropy_len( mbedtls_ctr_drbg_context *ctx, size_t len ); /** * \brief This function sets the reseed interval. - * The default value is #MBEDTLS_CTR_DRBG_RESEED_INTERVAL. + * + * The reseed interval is the number of calls to mbedtls_ctr_drbg_random() + * or mbedtls_ctr_drbg_random_with_add() after which the entropy function + * is called again. + * + * The default value is #MBEDTLS_CTR_DRBG_RESEED_INTERVAL. * * \param ctx The CTR_DRBG context. * \param interval The reseed interval. @@ -233,8 +347,12 @@ void mbedtls_ctr_drbg_set_reseed_interval( mbedtls_ctr_drbg_context *ctx, * extracts data from the entropy source. * * \param ctx The CTR_DRBG context. - * \param additional Additional data to add to the state. Can be NULL. + * \param additional Additional data to add to the state. Can be \c NULL. * \param len The length of the additional data. + * This must be less than + * #MBEDTLS_CTR_DRBG_MAX_SEED_INPUT - \c entropy_len + * where \c entropy_len is the entropy length + * configured for the context. * * \return \c 0 on success. * \return #MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED on failure. @@ -246,7 +364,8 @@ int mbedtls_ctr_drbg_reseed( mbedtls_ctr_drbg_context *ctx, * \brief This function updates the state of the CTR_DRBG context. * * \param ctx The CTR_DRBG context. - * \param additional The data to update the state with. + * \param additional The data to update the state with. This must not be + * \c NULL unless \p add_len is \c 0. * \param add_len Length of \p additional in bytes. This must be at * most #MBEDTLS_CTR_DRBG_MAX_SEED_INPUT. * @@ -264,14 +383,23 @@ int mbedtls_ctr_drbg_update_ret( mbedtls_ctr_drbg_context *ctx, * \brief This function updates a CTR_DRBG instance with additional * data and uses it to generate random data. * - * \note The function automatically reseeds if the reseed counter is exceeded. + * This function automatically reseeds if the reseed counter is exceeded + * or prediction resistance is enabled. * * \param p_rng The CTR_DRBG context. This must be a pointer to a * #mbedtls_ctr_drbg_context structure. * \param output The buffer to fill. - * \param output_len The length of the buffer. - * \param additional Additional data to update. Can be NULL. - * \param add_len The length of the additional data. + * \param output_len The length of the buffer in bytes. + * \param additional Additional data to update. Can be \c NULL, in which + * case the additional data is empty regardless of + * the value of \p add_len. + * \param add_len The length of the additional data + * if \p additional is not \c NULL. + * This must be less than #MBEDTLS_CTR_DRBG_MAX_INPUT + * and less than + * #MBEDTLS_CTR_DRBG_MAX_SEED_INPUT - \c entropy_len + * where \c entropy_len is the entropy length + * configured for the context. * * \return \c 0 on success. * \return #MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED or @@ -284,12 +412,14 @@ int mbedtls_ctr_drbg_random_with_add( void *p_rng, /** * \brief This function uses CTR_DRBG to generate random data. * - * \note The function automatically reseeds if the reseed counter is exceeded. + * This function automatically reseeds if the reseed counter is exceeded + * or prediction resistance is enabled. + * * * \param p_rng The CTR_DRBG context. This must be a pointer to a * #mbedtls_ctr_drbg_context structure. * \param output The buffer to fill. - * \param output_len The length of the buffer. + * \param output_len The length of the buffer in bytes. * * \return \c 0 on success. * \return #MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED or @@ -336,7 +466,7 @@ MBEDTLS_DEPRECATED void mbedtls_ctr_drbg_update( * * \return \c 0 on success. * \return #MBEDTLS_ERR_CTR_DRBG_FILE_IO_ERROR on file error. - * \return #MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED on + * \return #MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED on reseed * failure. */ int mbedtls_ctr_drbg_write_seed_file( mbedtls_ctr_drbg_context *ctx, const char *path ); @@ -350,8 +480,10 @@ int mbedtls_ctr_drbg_write_seed_file( mbedtls_ctr_drbg_context *ctx, const char * * \return \c 0 on success. * \return #MBEDTLS_ERR_CTR_DRBG_FILE_IO_ERROR on file error. - * \return #MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED or - * #MBEDTLS_ERR_CTR_DRBG_INPUT_TOO_BIG on failure. + * \return #MBEDTLS_ERR_CTR_DRBG_ENTROPY_SOURCE_FAILED on + * reseed failure. + * \return #MBEDTLS_ERR_CTR_DRBG_INPUT_TOO_BIG if the existing + * seed file is too large. */ int mbedtls_ctr_drbg_update_seed_file( mbedtls_ctr_drbg_context *ctx, const char *path ); #endif /* MBEDTLS_FS_IO */ diff --git a/thirdparty/mbedtls/include/mbedtls/hmac_drbg.h b/thirdparty/mbedtls/include/mbedtls/hmac_drbg.h index f1289cb306..7931c2281c 100644 --- a/thirdparty/mbedtls/include/mbedtls/hmac_drbg.h +++ b/thirdparty/mbedtls/include/mbedtls/hmac_drbg.h @@ -1,10 +1,14 @@ /** * \file hmac_drbg.h * - * \brief HMAC_DRBG (NIST SP 800-90A) + * \brief The HMAC_DRBG pseudorandom generator. + * + * This module implements the HMAC_DRBG pseudorandom generator described + * in <em>NIST SP 800-90A: Recommendation for Random Number Generation Using + * Deterministic Random Bit Generators</em>. */ /* - * Copyright (C) 2006-2015, ARM Limited, All Rights Reserved + * Copyright (C) 2006-2019, ARM Limited, All Rights Reserved * SPDX-License-Identifier: Apache-2.0 * * Licensed under the Apache License, Version 2.0 (the "License"); you may @@ -104,38 +108,72 @@ typedef struct mbedtls_hmac_drbg_context } mbedtls_hmac_drbg_context; /** - * \brief HMAC_DRBG context initialization - * Makes the context ready for mbedtls_hmac_drbg_seed(), - * mbedtls_hmac_drbg_seed_buf() or - * mbedtls_hmac_drbg_free(). + * \brief HMAC_DRBG context initialization. + * + * This function makes the context ready for mbedtls_hmac_drbg_seed(), + * mbedtls_hmac_drbg_seed_buf() or mbedtls_hmac_drbg_free(). * - * \param ctx HMAC_DRBG context to be initialized + * \param ctx HMAC_DRBG context to be initialized. */ void mbedtls_hmac_drbg_init( mbedtls_hmac_drbg_context *ctx ); /** - * \brief HMAC_DRBG initial seeding - * Seed and setup entropy source for future reseeds. - * - * \param ctx HMAC_DRBG context to be seeded - * \param md_info MD algorithm to use for HMAC_DRBG - * \param f_entropy Entropy callback (p_entropy, buffer to fill, buffer - * length) - * \param p_entropy Entropy context - * \param custom Personalization data (Device specific identifiers) - * (Can be NULL) - * \param len Length of personalization data - * - * \note The "security strength" as defined by NIST is set to: - * 128 bits if md_alg is SHA-1, - * 192 bits if md_alg is SHA-224, - * 256 bits if md_alg is SHA-256 or higher. - * Note that SHA-256 is just as efficient as SHA-224. + * \brief HMAC_DRBG initial seeding. + * + * Set the initial seed and set up the entropy source for future reseeds. + * + * A typical choice for the \p f_entropy and \p p_entropy parameters is + * to use the entropy module: + * - \p f_entropy is mbedtls_entropy_func(); + * - \p p_entropy is an instance of ::mbedtls_entropy_context initialized + * with mbedtls_entropy_init() (which registers the platform's default + * entropy sources). + * + * You can provide a personalization string in addition to the + * entropy source, to make this instantiation as unique as possible. * - * \return 0 if successful, or - * MBEDTLS_ERR_MD_BAD_INPUT_DATA, or - * MBEDTLS_ERR_MD_ALLOC_FAILED, or - * MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED. + * \note By default, the security strength as defined by NIST is: + * - 128 bits if \p md_info is SHA-1; + * - 192 bits if \p md_info is SHA-224; + * - 256 bits if \p md_info is SHA-256, SHA-384 or SHA-512. + * Note that SHA-256 is just as efficient as SHA-224. + * The security strength can be reduced if a smaller + * entropy length is set with + * mbedtls_hmac_drbg_set_entropy_len(). + * + * \note The default entropy length is the security strength + * (converted from bits to bytes). You can override + * it by calling mbedtls_hmac_drbg_set_entropy_len(). + * + * \note During the initial seeding, this function calls + * the entropy source to obtain a nonce + * whose length is half the entropy length. + * + * \param ctx HMAC_DRBG context to be seeded. + * \param md_info MD algorithm to use for HMAC_DRBG. + * \param f_entropy The entropy callback, taking as arguments the + * \p p_entropy context, the buffer to fill, and the + * length of the buffer. + * \p f_entropy is always called with a length that is + * less than or equal to the entropy length. + * \param p_entropy The entropy context to pass to \p f_entropy. + * \param custom The personalization string. + * This can be \c NULL, in which case the personalization + * string is empty regardless of the value of \p len. + * \param len The length of the personalization string. + * This must be at most #MBEDTLS_HMAC_DRBG_MAX_INPUT + * and also at most + * #MBEDTLS_HMAC_DRBG_MAX_SEED_INPUT - \p entropy_len * 3 / 2 + * where \p entropy_len is the entropy length + * described above. + * + * \return \c 0 if successful. + * \return #MBEDTLS_ERR_MD_BAD_INPUT_DATA if \p md_info is + * invalid. + * \return #MBEDTLS_ERR_MD_ALLOC_FAILED if there was not enough + * memory to allocate context data. + * \return #MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED + * if the call to \p f_entropy failed. */ int mbedtls_hmac_drbg_seed( mbedtls_hmac_drbg_context *ctx, const mbedtls_md_info_t * md_info, @@ -146,98 +184,131 @@ int mbedtls_hmac_drbg_seed( mbedtls_hmac_drbg_context *ctx, /** * \brief Initilisation of simpified HMAC_DRBG (never reseeds). - * (For use with deterministic ECDSA.) * - * \param ctx HMAC_DRBG context to be initialised - * \param md_info MD algorithm to use for HMAC_DRBG - * \param data Concatenation of entropy string and additional data - * \param data_len Length of data in bytes + * This function is meant for use in algorithms that need a pseudorandom + * input such as deterministic ECDSA. + * + * \param ctx HMAC_DRBG context to be initialised. + * \param md_info MD algorithm to use for HMAC_DRBG. + * \param data Concatenation of the initial entropy string and + * the additional data. + * \param data_len Length of \p data in bytes. * - * \return 0 if successful, or - * MBEDTLS_ERR_MD_BAD_INPUT_DATA, or - * MBEDTLS_ERR_MD_ALLOC_FAILED. + * \return \c 0 if successful. or + * \return #MBEDTLS_ERR_MD_BAD_INPUT_DATA if \p md_info is + * invalid. + * \return #MBEDTLS_ERR_MD_ALLOC_FAILED if there was not enough + * memory to allocate context data. */ int mbedtls_hmac_drbg_seed_buf( mbedtls_hmac_drbg_context *ctx, const mbedtls_md_info_t * md_info, const unsigned char *data, size_t data_len ); /** - * \brief Enable / disable prediction resistance (Default: Off) + * \brief This function turns prediction resistance on or off. + * The default value is off. * - * Note: If enabled, entropy is used for ctx->entropy_len before each call! - * Only use this if you have ample supply of good entropy! + * \note If enabled, entropy is gathered at the beginning of + * every call to mbedtls_hmac_drbg_random_with_add() + * or mbedtls_hmac_drbg_random(). + * Only use this if your entropy source has sufficient + * throughput. * - * \param ctx HMAC_DRBG context - * \param resistance MBEDTLS_HMAC_DRBG_PR_ON or MBEDTLS_HMAC_DRBG_PR_OFF + * \param ctx The HMAC_DRBG context. + * \param resistance #MBEDTLS_HMAC_DRBG_PR_ON or #MBEDTLS_HMAC_DRBG_PR_OFF. */ void mbedtls_hmac_drbg_set_prediction_resistance( mbedtls_hmac_drbg_context *ctx, int resistance ); /** - * \brief Set the amount of entropy grabbed on each reseed - * (Default: given by the security strength, which - * depends on the hash used, see \c mbedtls_hmac_drbg_init() ) + * \brief This function sets the amount of entropy grabbed on each + * seed or reseed. + * + * See the documentation of mbedtls_hmac_drbg_seed() for the default value. * - * \param ctx HMAC_DRBG context - * \param len Amount of entropy to grab, in bytes + * \param ctx The HMAC_DRBG context. + * \param len The amount of entropy to grab, in bytes. */ void mbedtls_hmac_drbg_set_entropy_len( mbedtls_hmac_drbg_context *ctx, size_t len ); /** - * \brief Set the reseed interval - * (Default: MBEDTLS_HMAC_DRBG_RESEED_INTERVAL) + * \brief Set the reseed interval. * - * \param ctx HMAC_DRBG context - * \param interval Reseed interval + * The reseed interval is the number of calls to mbedtls_hmac_drbg_random() + * or mbedtls_hmac_drbg_random_with_add() after which the entropy function + * is called again. + * + * The default value is #MBEDTLS_HMAC_DRBG_RESEED_INTERVAL. + * + * \param ctx The HMAC_DRBG context. + * \param interval The reseed interval. */ void mbedtls_hmac_drbg_set_reseed_interval( mbedtls_hmac_drbg_context *ctx, int interval ); /** - * \brief HMAC_DRBG update state + * \brief This function updates the state of the HMAC_DRBG context. * - * \param ctx HMAC_DRBG context - * \param additional Additional data to update state with, or NULL - * \param add_len Length of additional data, or 0 + * \param ctx The HMAC_DRBG context. + * \param additional The data to update the state with. + * If this is \c NULL, there is no additional data. + * \param add_len Length of \p additional in bytes. + * Unused if \p additional is \c NULL. * * \return \c 0 on success, or an error from the underlying * hash calculation. - * - * \note Additional data is optional, pass NULL and 0 as second - * third argument if no additional data is being used. */ int mbedtls_hmac_drbg_update_ret( mbedtls_hmac_drbg_context *ctx, const unsigned char *additional, size_t add_len ); /** - * \brief HMAC_DRBG reseeding (extracts data from entropy source) - * - * \param ctx HMAC_DRBG context - * \param additional Additional data to add to state (Can be NULL) - * \param len Length of additional data - * - * \return 0 if successful, or - * MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED + * \brief This function reseeds the HMAC_DRBG context, that is + * extracts data from the entropy source. + * + * \param ctx The HMAC_DRBG context. + * \param additional Additional data to add to the state. + * If this is \c NULL, there is no additional data + * and \p len should be \c 0. + * \param len The length of the additional data. + * This must be at most #MBEDTLS_HMAC_DRBG_MAX_INPUT + * and also at most + * #MBEDTLS_HMAC_DRBG_MAX_SEED_INPUT - \p entropy_len + * where \p entropy_len is the entropy length + * (see mbedtls_hmac_drbg_set_entropy_len()). + * + * \return \c 0 if successful. + * \return #MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED + * if a call to the entropy function failed. */ int mbedtls_hmac_drbg_reseed( mbedtls_hmac_drbg_context *ctx, const unsigned char *additional, size_t len ); /** - * \brief HMAC_DRBG generate random with additional update input - * - * Note: Automatically reseeds if reseed_counter is reached or PR is enabled. - * - * \param p_rng HMAC_DRBG context - * \param output Buffer to fill - * \param output_len Length of the buffer - * \param additional Additional data to update with (can be NULL) - * \param add_len Length of additional data (can be 0) - * - * \return 0 if successful, or - * MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED, or - * MBEDTLS_ERR_HMAC_DRBG_REQUEST_TOO_BIG, or - * MBEDTLS_ERR_HMAC_DRBG_INPUT_TOO_BIG. + * \brief This function updates an HMAC_DRBG instance with additional + * data and uses it to generate random data. + * + * This function automatically reseeds if the reseed counter is exceeded + * or prediction resistance is enabled. + * + * \param p_rng The HMAC_DRBG context. This must be a pointer to a + * #mbedtls_hmac_drbg_context structure. + * \param output The buffer to fill. + * \param output_len The length of the buffer in bytes. + * This must be at most #MBEDTLS_HMAC_DRBG_MAX_REQUEST. + * \param additional Additional data to update with. + * If this is \c NULL, there is no additional data + * and \p add_len should be \c 0. + * \param add_len The length of the additional data. + * This must be at most #MBEDTLS_HMAC_DRBG_MAX_INPUT. + * + * \return \c 0 if successful. + * \return #MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED + * if a call to the entropy source failed. + * \return #MBEDTLS_ERR_HMAC_DRBG_REQUEST_TOO_BIG if + * \p output_len > #MBEDTLS_HMAC_DRBG_MAX_REQUEST. + * \return #MBEDTLS_ERR_HMAC_DRBG_INPUT_TOO_BIG if + * \p add_len > #MBEDTLS_HMAC_DRBG_MAX_INPUT. */ int mbedtls_hmac_drbg_random_with_add( void *p_rng, unsigned char *output, size_t output_len, @@ -245,24 +316,29 @@ int mbedtls_hmac_drbg_random_with_add( void *p_rng, size_t add_len ); /** - * \brief HMAC_DRBG generate random - * - * Note: Automatically reseeds if reseed_counter is reached or PR is enabled. - * - * \param p_rng HMAC_DRBG context - * \param output Buffer to fill - * \param out_len Length of the buffer - * - * \return 0 if successful, or - * MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED, or - * MBEDTLS_ERR_HMAC_DRBG_REQUEST_TOO_BIG + * \brief This function uses HMAC_DRBG to generate random data. + * + * This function automatically reseeds if the reseed counter is exceeded + * or prediction resistance is enabled. + * + * \param p_rng The HMAC_DRBG context. This must be a pointer to a + * #mbedtls_hmac_drbg_context structure. + * \param output The buffer to fill. + * \param out_len The length of the buffer in bytes. + * This must be at most #MBEDTLS_HMAC_DRBG_MAX_REQUEST. + * + * \return \c 0 if successful. + * \return #MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED + * if a call to the entropy source failed. + * \return #MBEDTLS_ERR_HMAC_DRBG_REQUEST_TOO_BIG if + * \p out_len > #MBEDTLS_HMAC_DRBG_MAX_REQUEST. */ int mbedtls_hmac_drbg_random( void *p_rng, unsigned char *output, size_t out_len ); /** * \brief Free an HMAC_DRBG context * - * \param ctx HMAC_DRBG context to free. + * \param ctx The HMAC_DRBG context to free. */ void mbedtls_hmac_drbg_free( mbedtls_hmac_drbg_context *ctx ); @@ -273,17 +349,16 @@ void mbedtls_hmac_drbg_free( mbedtls_hmac_drbg_context *ctx ); #define MBEDTLS_DEPRECATED #endif /** - * \brief HMAC_DRBG update state + * \brief This function updates the state of the HMAC_DRBG context. * * \deprecated Superseded by mbedtls_hmac_drbg_update_ret() * in 2.16.0. * - * \param ctx HMAC_DRBG context - * \param additional Additional data to update state with, or NULL - * \param add_len Length of additional data, or 0 - * - * \note Additional data is optional, pass NULL and 0 as second - * third argument if no additional data is being used. + * \param ctx The HMAC_DRBG context. + * \param additional The data to update the state with. + * If this is \c NULL, there is no additional data. + * \param add_len Length of \p additional in bytes. + * Unused if \p additional is \c NULL. */ MBEDTLS_DEPRECATED void mbedtls_hmac_drbg_update( mbedtls_hmac_drbg_context *ctx, @@ -293,26 +368,31 @@ MBEDTLS_DEPRECATED void mbedtls_hmac_drbg_update( #if defined(MBEDTLS_FS_IO) /** - * \brief Write a seed file + * \brief This function writes a seed file. * - * \param ctx HMAC_DRBG context - * \param path Name of the file + * \param ctx The HMAC_DRBG context. + * \param path The name of the file. * - * \return 0 if successful, 1 on file error, or - * MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED + * \return \c 0 on success. + * \return #MBEDTLS_ERR_HMAC_DRBG_FILE_IO_ERROR on file error. + * \return #MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED on reseed + * failure. */ int mbedtls_hmac_drbg_write_seed_file( mbedtls_hmac_drbg_context *ctx, const char *path ); /** - * \brief Read and update a seed file. Seed is added to this - * instance - * - * \param ctx HMAC_DRBG context - * \param path Name of the file - * - * \return 0 if successful, 1 on file error, - * MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED or - * MBEDTLS_ERR_HMAC_DRBG_INPUT_TOO_BIG + * \brief This function reads and updates a seed file. The seed + * is added to this instance. + * + * \param ctx The HMAC_DRBG context. + * \param path The name of the file. + * + * \return \c 0 on success. + * \return #MBEDTLS_ERR_HMAC_DRBG_FILE_IO_ERROR on file error. + * \return #MBEDTLS_ERR_HMAC_DRBG_ENTROPY_SOURCE_FAILED on + * reseed failure. + * \return #MBEDTLS_ERR_HMAC_DRBG_INPUT_TOO_BIG if the existing + * seed file is too large. */ int mbedtls_hmac_drbg_update_seed_file( mbedtls_hmac_drbg_context *ctx, const char *path ); #endif /* MBEDTLS_FS_IO */ @@ -320,9 +400,10 @@ int mbedtls_hmac_drbg_update_seed_file( mbedtls_hmac_drbg_context *ctx, const ch #if defined(MBEDTLS_SELF_TEST) /** - * \brief Checkup routine + * \brief The HMAC_DRBG Checkup routine. * - * \return 0 if successful, or 1 if the test failed + * \return \c 0 if successful. + * \return \c 1 if the test failed. */ int mbedtls_hmac_drbg_self_test( int verbose ); #endif diff --git a/thirdparty/mbedtls/include/mbedtls/version.h b/thirdparty/mbedtls/include/mbedtls/version.h index b4eef71e50..aeffb16699 100644 --- a/thirdparty/mbedtls/include/mbedtls/version.h +++ b/thirdparty/mbedtls/include/mbedtls/version.h @@ -40,16 +40,16 @@ */ #define MBEDTLS_VERSION_MAJOR 2 #define MBEDTLS_VERSION_MINOR 16 -#define MBEDTLS_VERSION_PATCH 3 +#define MBEDTLS_VERSION_PATCH 4 /** * The single version number has the following structure: * MMNNPP00 * Major version | Minor version | Patch version */ -#define MBEDTLS_VERSION_NUMBER 0x02100300 -#define MBEDTLS_VERSION_STRING "2.16.3" -#define MBEDTLS_VERSION_STRING_FULL "mbed TLS 2.16.3" +#define MBEDTLS_VERSION_NUMBER 0x02100400 +#define MBEDTLS_VERSION_STRING "2.16.4" +#define MBEDTLS_VERSION_STRING_FULL "mbed TLS 2.16.4" #if defined(MBEDTLS_VERSION_C) diff --git a/thirdparty/mbedtls/library/aes.c b/thirdparty/mbedtls/library/aes.c index aff0a9939a..02a7986b59 100644 --- a/thirdparty/mbedtls/library/aes.c +++ b/thirdparty/mbedtls/library/aes.c @@ -918,6 +918,18 @@ int mbedtls_internal_aes_encrypt( mbedtls_aes_context *ctx, PUT_UINT32_LE( X2, output, 8 ); PUT_UINT32_LE( X3, output, 12 ); + mbedtls_platform_zeroize( &X0, sizeof( X0 ) ); + mbedtls_platform_zeroize( &X1, sizeof( X1 ) ); + mbedtls_platform_zeroize( &X2, sizeof( X2 ) ); + mbedtls_platform_zeroize( &X3, sizeof( X3 ) ); + + mbedtls_platform_zeroize( &Y0, sizeof( Y0 ) ); + mbedtls_platform_zeroize( &Y1, sizeof( Y1 ) ); + mbedtls_platform_zeroize( &Y2, sizeof( Y2 ) ); + mbedtls_platform_zeroize( &Y3, sizeof( Y3 ) ); + + mbedtls_platform_zeroize( &RK, sizeof( RK ) ); + return( 0 ); } #endif /* !MBEDTLS_AES_ENCRYPT_ALT */ @@ -986,6 +998,18 @@ int mbedtls_internal_aes_decrypt( mbedtls_aes_context *ctx, PUT_UINT32_LE( X2, output, 8 ); PUT_UINT32_LE( X3, output, 12 ); + mbedtls_platform_zeroize( &X0, sizeof( X0 ) ); + mbedtls_platform_zeroize( &X1, sizeof( X1 ) ); + mbedtls_platform_zeroize( &X2, sizeof( X2 ) ); + mbedtls_platform_zeroize( &X3, sizeof( X3 ) ); + + mbedtls_platform_zeroize( &Y0, sizeof( Y0 ) ); + mbedtls_platform_zeroize( &Y1, sizeof( Y1 ) ); + mbedtls_platform_zeroize( &Y2, sizeof( Y2 ) ); + mbedtls_platform_zeroize( &Y3, sizeof( Y3 ) ); + + mbedtls_platform_zeroize( &RK, sizeof( RK ) ); + return( 0 ); } #endif /* !MBEDTLS_AES_DECRYPT_ALT */ diff --git a/thirdparty/mbedtls/library/bignum.c b/thirdparty/mbedtls/library/bignum.c index d1717e9435..6713bcbf6f 100644 --- a/thirdparty/mbedtls/library/bignum.c +++ b/thirdparty/mbedtls/library/bignum.c @@ -1071,6 +1071,107 @@ int mbedtls_mpi_cmp_mpi( const mbedtls_mpi *X, const mbedtls_mpi *Y ) return( 0 ); } +/** Decide if an integer is less than the other, without branches. + * + * \param x First integer. + * \param y Second integer. + * + * \return 1 if \p x is less than \p y, 0 otherwise + */ +static unsigned ct_lt_mpi_uint( const mbedtls_mpi_uint x, + const mbedtls_mpi_uint y ) +{ + mbedtls_mpi_uint ret; + mbedtls_mpi_uint cond; + + /* + * Check if the most significant bits (MSB) of the operands are different. + */ + cond = ( x ^ y ); + /* + * If the MSB are the same then the difference x-y will be negative (and + * have its MSB set to 1 during conversion to unsigned) if and only if x<y. + */ + ret = ( x - y ) & ~cond; + /* + * If the MSB are different, then the operand with the MSB of 1 is the + * bigger. (That is if y has MSB of 1, then x<y is true and it is false if + * the MSB of y is 0.) + */ + ret |= y & cond; + + + ret = ret >> ( biL - 1 ); + + return (unsigned) ret; +} + +/* + * Compare signed values in constant time + */ +int mbedtls_mpi_lt_mpi_ct( const mbedtls_mpi *X, const mbedtls_mpi *Y, + unsigned *ret ) +{ + size_t i; + /* The value of any of these variables is either 0 or 1 at all times. */ + unsigned cond, done, X_is_negative, Y_is_negative; + + MPI_VALIDATE_RET( X != NULL ); + MPI_VALIDATE_RET( Y != NULL ); + MPI_VALIDATE_RET( ret != NULL ); + + if( X->n != Y->n ) + return MBEDTLS_ERR_MPI_BAD_INPUT_DATA; + + /* + * Set sign_N to 1 if N >= 0, 0 if N < 0. + * We know that N->s == 1 if N >= 0 and N->s == -1 if N < 0. + */ + X_is_negative = ( X->s & 2 ) >> 1; + Y_is_negative = ( Y->s & 2 ) >> 1; + + /* + * If the signs are different, then the positive operand is the bigger. + * That is if X is negative (X_is_negative == 1), then X < Y is true and it + * is false if X is positive (X_is_negative == 0). + */ + cond = ( X_is_negative ^ Y_is_negative ); + *ret = cond & X_is_negative; + + /* + * This is a constant-time function. We might have the result, but we still + * need to go through the loop. Record if we have the result already. + */ + done = cond; + + for( i = X->n; i > 0; i-- ) + { + /* + * If Y->p[i - 1] < X->p[i - 1] then X < Y is true if and only if both + * X and Y are negative. + * + * Again even if we can make a decision, we just mark the result and + * the fact that we are done and continue looping. + */ + cond = ct_lt_mpi_uint( Y->p[i - 1], X->p[i - 1] ); + *ret |= cond & ( 1 - done ) & X_is_negative; + done |= cond; + + /* + * If X->p[i - 1] < Y->p[i - 1] then X < Y is true if and only if both + * X and Y are positive. + * + * Again even if we can make a decision, we just mark the result and + * the fact that we are done and continue looping. + */ + cond = ct_lt_mpi_uint( X->p[i - 1], Y->p[i - 1] ); + *ret |= cond & ( 1 - done ) & ( 1 - X_is_negative ); + done |= cond; + } + + return( 0 ); +} + /* * Compare signed values */ @@ -2338,8 +2439,6 @@ static int mpi_miller_rabin( const mbedtls_mpi *X, size_t rounds, MBEDTLS_MPI_CHK( mbedtls_mpi_copy( &R, &W ) ); MBEDTLS_MPI_CHK( mbedtls_mpi_shift_r( &R, s ) ); - i = mbedtls_mpi_bitlen( X ); - for( i = 0; i < rounds; i++ ) { /* diff --git a/thirdparty/mbedtls/library/ctr_drbg.c b/thirdparty/mbedtls/library/ctr_drbg.c index fb121575bb..ad0a1936d1 100644 --- a/thirdparty/mbedtls/library/ctr_drbg.c +++ b/thirdparty/mbedtls/library/ctr_drbg.c @@ -62,68 +62,6 @@ void mbedtls_ctr_drbg_init( mbedtls_ctr_drbg_context *ctx ) #endif } -/* - * Non-public function wrapped by mbedtls_ctr_drbg_seed(). Necessary to allow - * NIST tests to succeed (which require known length fixed entropy) - */ -/* CTR_DRBG_Instantiate with derivation function (SP 800-90A §10.2.1.3.2) - * mbedtls_ctr_drbg_seed_entropy_len(ctx, f_entropy, p_entropy, - * custom, len, entropy_len) - * implements - * CTR_DRBG_Instantiate(entropy_input, nonce, personalization_string, - * security_strength) -> initial_working_state - * with inputs - * custom[:len] = nonce || personalization_string - * where entropy_input comes from f_entropy for entropy_len bytes - * and with outputs - * ctx = initial_working_state - */ -int mbedtls_ctr_drbg_seed_entropy_len( - mbedtls_ctr_drbg_context *ctx, - int (*f_entropy)(void *, unsigned char *, size_t), - void *p_entropy, - const unsigned char *custom, - size_t len, - size_t entropy_len ) -{ - int ret; - unsigned char key[MBEDTLS_CTR_DRBG_KEYSIZE]; - - memset( key, 0, MBEDTLS_CTR_DRBG_KEYSIZE ); - - mbedtls_aes_init( &ctx->aes_ctx ); - - ctx->f_entropy = f_entropy; - ctx->p_entropy = p_entropy; - - ctx->entropy_len = entropy_len; - ctx->reseed_interval = MBEDTLS_CTR_DRBG_RESEED_INTERVAL; - - /* - * Initialize with an empty key - */ - if( ( ret = mbedtls_aes_setkey_enc( &ctx->aes_ctx, key, MBEDTLS_CTR_DRBG_KEYBITS ) ) != 0 ) - { - return( ret ); - } - - if( ( ret = mbedtls_ctr_drbg_reseed( ctx, custom, len ) ) != 0 ) - { - return( ret ); - } - return( 0 ); -} - -int mbedtls_ctr_drbg_seed( mbedtls_ctr_drbg_context *ctx, - int (*f_entropy)(void *, unsigned char *, size_t), - void *p_entropy, - const unsigned char *custom, - size_t len ) -{ - return( mbedtls_ctr_drbg_seed_entropy_len( ctx, f_entropy, p_entropy, custom, len, - MBEDTLS_CTR_DRBG_ENTROPY_LEN ) ); -} - void mbedtls_ctr_drbg_free( mbedtls_ctr_drbg_context *ctx ) { if( ctx == NULL ) @@ -427,6 +365,63 @@ exit: return( ret ); } +/* CTR_DRBG_Instantiate with derivation function (SP 800-90A §10.2.1.3.2) + * mbedtls_ctr_drbg_seed(ctx, f_entropy, p_entropy, custom, len) + * implements + * CTR_DRBG_Instantiate(entropy_input, nonce, personalization_string, + * security_strength) -> initial_working_state + * with inputs + * custom[:len] = nonce || personalization_string + * where entropy_input comes from f_entropy for ctx->entropy_len bytes + * and with outputs + * ctx = initial_working_state + */ +int mbedtls_ctr_drbg_seed( mbedtls_ctr_drbg_context *ctx, + int (*f_entropy)(void *, unsigned char *, size_t), + void *p_entropy, + const unsigned char *custom, + size_t len ) +{ + int ret; + unsigned char key[MBEDTLS_CTR_DRBG_KEYSIZE]; + + memset( key, 0, MBEDTLS_CTR_DRBG_KEYSIZE ); + + mbedtls_aes_init( &ctx->aes_ctx ); + + ctx->f_entropy = f_entropy; + ctx->p_entropy = p_entropy; + + if( ctx->entropy_len == 0 ) + ctx->entropy_len = MBEDTLS_CTR_DRBG_ENTROPY_LEN; + ctx->reseed_interval = MBEDTLS_CTR_DRBG_RESEED_INTERVAL; + + /* + * Initialize with an empty key + */ + if( ( ret = mbedtls_aes_setkey_enc( &ctx->aes_ctx, key, MBEDTLS_CTR_DRBG_KEYBITS ) ) != 0 ) + { + return( ret ); + } + + if( ( ret = mbedtls_ctr_drbg_reseed( ctx, custom, len ) ) != 0 ) + { + return( ret ); + } + return( 0 ); +} + +/* Backward compatibility wrapper */ +int mbedtls_ctr_drbg_seed_entropy_len( + mbedtls_ctr_drbg_context *ctx, + int (*f_entropy)(void *, unsigned char *, size_t), void *p_entropy, + const unsigned char *custom, size_t len, + size_t entropy_len ) +{ + mbedtls_ctr_drbg_set_entropy_len( ctx, entropy_len ); + return( mbedtls_ctr_drbg_seed( ctx, f_entropy, p_entropy, custom, len ) ); +} + /* CTR_DRBG_Generate with derivation function (SP 800-90A §10.2.1.5.2) * mbedtls_ctr_drbg_random_with_add(ctx, output, output_len, additional, add_len) * implements @@ -517,7 +512,7 @@ int mbedtls_ctr_drbg_random_with_add( void *p_rng, exit: mbedtls_platform_zeroize( add_input, sizeof( add_input ) ); mbedtls_platform_zeroize( tmp, sizeof( tmp ) ); - return( 0 ); + return( ret ); } int mbedtls_ctr_drbg_random( void *p_rng, unsigned char *output, size_t output_len ) @@ -678,8 +673,11 @@ int mbedtls_ctr_drbg_self_test( int verbose ) mbedtls_printf( " CTR_DRBG (PR = TRUE) : " ); test_offset = 0; - CHK( mbedtls_ctr_drbg_seed_entropy_len( &ctx, ctr_drbg_self_test_entropy, - (void *) entropy_source_pr, nonce_pers_pr, 16, 32 ) ); + mbedtls_ctr_drbg_set_entropy_len( &ctx, 32 ); + CHK( mbedtls_ctr_drbg_seed( &ctx, + ctr_drbg_self_test_entropy, + (void *) entropy_source_pr, + nonce_pers_pr, 16 ) ); mbedtls_ctr_drbg_set_prediction_resistance( &ctx, MBEDTLS_CTR_DRBG_PR_ON ); CHK( mbedtls_ctr_drbg_random( &ctx, buf, MBEDTLS_CTR_DRBG_BLOCKSIZE ) ); CHK( mbedtls_ctr_drbg_random( &ctx, buf, MBEDTLS_CTR_DRBG_BLOCKSIZE ) ); @@ -699,8 +697,11 @@ int mbedtls_ctr_drbg_self_test( int verbose ) mbedtls_ctr_drbg_init( &ctx ); test_offset = 0; - CHK( mbedtls_ctr_drbg_seed_entropy_len( &ctx, ctr_drbg_self_test_entropy, - (void *) entropy_source_nopr, nonce_pers_nopr, 16, 32 ) ); + mbedtls_ctr_drbg_set_entropy_len( &ctx, 32 ); + CHK( mbedtls_ctr_drbg_seed( &ctx, + ctr_drbg_self_test_entropy, + (void *) entropy_source_nopr, + nonce_pers_nopr, 16 ) ); CHK( mbedtls_ctr_drbg_random( &ctx, buf, 16 ) ); CHK( mbedtls_ctr_drbg_reseed( &ctx, NULL, 0 ) ); CHK( mbedtls_ctr_drbg_random( &ctx, buf, 16 ) ); diff --git a/thirdparty/mbedtls/library/ecdsa.c b/thirdparty/mbedtls/library/ecdsa.c index 2b4800642d..3cf3d7cc4f 100644 --- a/thirdparty/mbedtls/library/ecdsa.c +++ b/thirdparty/mbedtls/library/ecdsa.c @@ -363,6 +363,7 @@ modn: MBEDTLS_MPI_CHK( mbedtls_mpi_add_mpi( &e, &e, s ) ); MBEDTLS_MPI_CHK( mbedtls_mpi_mul_mpi( &e, &e, &t ) ); MBEDTLS_MPI_CHK( mbedtls_mpi_mul_mpi( pk, pk, &t ) ); + MBEDTLS_MPI_CHK( mbedtls_mpi_mod_mpi( pk, pk, &grp->N ) ); MBEDTLS_MPI_CHK( mbedtls_mpi_inv_mod( s, pk, &grp->N ) ); MBEDTLS_MPI_CHK( mbedtls_mpi_mul_mpi( s, s, &e ) ); MBEDTLS_MPI_CHK( mbedtls_mpi_mod_mpi( s, s, &grp->N ) ); diff --git a/thirdparty/mbedtls/library/ecp.c b/thirdparty/mbedtls/library/ecp.c index db36191b9b..040c20bd38 100644 --- a/thirdparty/mbedtls/library/ecp.c +++ b/thirdparty/mbedtls/library/ecp.c @@ -2724,6 +2724,7 @@ int mbedtls_ecp_gen_privkey( const mbedtls_ecp_group *grp, { /* SEC1 3.2.1: Generate d such that 1 <= n < N */ int count = 0; + unsigned cmp = 0; /* * Match the procedure given in RFC 6979 (deterministic ECDSA): @@ -2748,9 +2749,14 @@ int mbedtls_ecp_gen_privkey( const mbedtls_ecp_group *grp, */ if( ++count > 30 ) return( MBEDTLS_ERR_ECP_RANDOM_FAILED ); + + ret = mbedtls_mpi_lt_mpi_ct( d, &grp->N, &cmp ); + if( ret != 0 ) + { + goto cleanup; + } } - while( mbedtls_mpi_cmp_int( d, 1 ) < 0 || - mbedtls_mpi_cmp_mpi( d, &grp->N ) >= 0 ); + while( mbedtls_mpi_cmp_int( d, 1 ) < 0 || cmp != 1 ); } #endif /* ECP_SHORTWEIERSTRASS */ diff --git a/thirdparty/mbedtls/library/hmac_drbg.c b/thirdparty/mbedtls/library/hmac_drbg.c index 50d88bd54b..284c9b4e96 100644 --- a/thirdparty/mbedtls/library/hmac_drbg.c +++ b/thirdparty/mbedtls/library/hmac_drbg.c @@ -273,16 +273,19 @@ int mbedtls_hmac_drbg_seed( mbedtls_hmac_drbg_context *ctx, ctx->reseed_interval = MBEDTLS_HMAC_DRBG_RESEED_INTERVAL; - /* - * See SP800-57 5.6.1 (p. 65-66) for the security strength provided by - * each hash function, then according to SP800-90A rev1 10.1 table 2, - * min_entropy_len (in bits) is security_strength. - * - * (This also matches the sizes used in the NIST test vectors.) - */ - ctx->entropy_len = md_size <= 20 ? 16 : /* 160-bits hash -> 128 bits */ - md_size <= 28 ? 24 : /* 224-bits hash -> 192 bits */ - 32; /* better (256+) -> 256 bits */ + if( ctx->entropy_len == 0 ) + { + /* + * See SP800-57 5.6.1 (p. 65-66) for the security strength provided by + * each hash function, then according to SP800-90A rev1 10.1 table 2, + * min_entropy_len (in bits) is security_strength. + * + * (This also matches the sizes used in the NIST test vectors.) + */ + ctx->entropy_len = md_size <= 20 ? 16 : /* 160-bits hash -> 128 bits */ + md_size <= 28 ? 24 : /* 224-bits hash -> 192 bits */ + 32; /* better (256+) -> 256 bits */ + } if( ( ret = hmac_drbg_reseed_core( ctx, custom, len, 1 /* add nonce */ ) ) != 0 ) @@ -303,7 +306,7 @@ void mbedtls_hmac_drbg_set_prediction_resistance( mbedtls_hmac_drbg_context *ctx } /* - * Set entropy length grabbed for reseeds + * Set entropy length grabbed for seeding */ void mbedtls_hmac_drbg_set_entropy_len( mbedtls_hmac_drbg_context *ctx, size_t len ) { diff --git a/thirdparty/mbedtls/library/version_features.c b/thirdparty/mbedtls/library/version_features.c index a99ee808d6..3b67b2be85 100644 --- a/thirdparty/mbedtls/library/version_features.c +++ b/thirdparty/mbedtls/library/version_features.c @@ -297,6 +297,9 @@ static const char *features[] = { #if defined(MBEDTLS_CIPHER_PADDING_ZEROS) "MBEDTLS_CIPHER_PADDING_ZEROS", #endif /* MBEDTLS_CIPHER_PADDING_ZEROS */ +#if defined(MBEDTLS_CTR_DRBG_USE_128_BIT_KEY) + "MBEDTLS_CTR_DRBG_USE_128_BIT_KEY", +#endif /* MBEDTLS_CTR_DRBG_USE_128_BIT_KEY */ #if defined(MBEDTLS_ENABLE_WEAK_CIPHERSUITES) "MBEDTLS_ENABLE_WEAK_CIPHERSUITES", #endif /* MBEDTLS_ENABLE_WEAK_CIPHERSUITES */ diff --git a/version.py b/version.py index 930981f7af..2a6a9c0a28 100644 --- a/version.py +++ b/version.py @@ -1,9 +1,9 @@ short_name = "godot" name = "Godot Engine" -major = 3 -minor = 2 +major = 4 +minor = 0 patch = 0 -status = "beta" +status = "dev" module_config = "" year = 2020 website = "https://godotengine.org" |