Commit graph

29151 commits

Author SHA1 Message Date
Rémi Verschelde
7e2e96c587
Merge pull request #46552 from lawnjelly/projsettings_2d_renames
Renaming rendering/2d project settings.
2021-03-01 13:19:32 +01:00
lawnjelly
b1e24597e7 Renaming rendering/2d project settings.
The rendering/quality/2d section of project settings is becoming considerably expanded in 3.2.4, and arguably was not the correct place for settings that were not really to do with quality.

3.2.4 is the last sensible opportunity we will have to move these settings, as the only existing one likely to break compatibility in a small way is `pixel_snap`, and given that the whole snapping area is being overhauled we can draw attention to the fact it has changed in the release notes.

Class reference is also updated and slightly improved.

`pixel_snap` is renamed to `gpu_pixel_snap` in the project settings and code to help differentiate from CPU side transform snapping.
2021-03-01 11:38:46 +00:00
Rémi Verschelde
6b4abc6e17
Merge pull request #46520 from lawnjelly/soft_skin_aa
Disallow antialiasing for software skinned 2d polys
2021-03-01 10:21:31 +01:00
lawnjelly
7d5cf60149 Disallow antialiasing for software skinned 2d polys
Antialiasing is not supported for batched polys. Currently due to the fallback mechanism, skinned antialiased polys will be rendered without applying animation.

This PR simply treats such polys as if antialiasing had not been selected. The class reference is updated to reflect this.
2021-03-01 08:26:59 +00:00
Rémi Verschelde
4fcd8483d5
Merge pull request #43813 from lawnjelly/snap_2d_round
Change 2d transform snapping from floor to round
2021-03-01 08:54:41 +01:00
Rémi Verschelde
5c23fc4a06
Merge pull request #46519 from pdfrod/v3.2/fix-out-of-bounds-acess-on-x11
Fix out of bounds array access on OS_X11 code
2021-02-28 21:44:49 +01:00
Pedro Rodrigues
66da113237 Fix out of bounds array access on OS_X11 code
The problem happened on methods `get_screen_position`, `get_screen_size`
and `set_current_screen` when they were passed a negative screen value.

Fixes:
- #46184
- #46185
- #46186
2021-02-28 17:20:04 +00:00
lawnjelly
847a37b196 Change 2d transform snapping from floor to round
Two common problems have emerged as a result of transform snapping:
1) Camera jitter with a camera following a snapped object
2) Pixel gaps between e.g. a platform and a player, where a platform rounds down and a player rounds up

Using round seems to greatly reduce problems due to camera jitter. It also may prove better for  pixel gaps because pixel art is often designed on a grid, so whole numbers are too expected, which are unstable with floor().
2021-02-28 14:34:39 +00:00
Rémi Verschelde
8385a0d8ad
Merge pull request #46458 from m4gr3d/fix_invalid_missing_templates_error
[3.2] Fix invalid missing template error when the Android build template is not installed
2021-02-27 16:52:41 +01:00
Rémi Verschelde
3720dc2cfa
Merge pull request #46454 from m4gr3d/loosen_restrictions_on_plugin_loading_3_2
[3.2] Update the logic to load Godot Android plugins packaged into the binary.
2021-02-27 16:46:48 +01:00
Rémi Verschelde
1717e16c9e
Merge pull request #46471 from nmrkr/3.2-drag-preview-crash-after-free
[3.2] Fix crash during drag if user freed the drag preview
2021-02-27 16:32:18 +01:00
Delf Neumärker
7df977c3ed
Fix crash during drag if user freed the drag preview 2021-02-27 15:16:06 +01:00
Fredia Huya-Kouadio
92d3287648 Fix invalid missing template error when the Android build template is not installed. 2021-02-26 12:28:19 -08:00
Rémi Verschelde
9047e760d1
Merge pull request #46451 from hilfazer/click_mesh_instance_crash
Prevent crash when clicking Mesh in MeshInstance when is scene root
2021-02-26 20:59:19 +01:00
hilfazer
84a9efcebc Prevent crash when clicking Mesh in MeshInstance when is scene root 2021-02-26 18:58:05 +01:00
Fredia Huya-Kouadio
c5fb32d594 Update the logic to load Godot Android plugins packaged into the binary.
The previous logic had the side effect of imposing a limit of one plugin per `aar` binary. The update lifts that restriction.
2021-02-26 09:09:40 -08:00
Fabio Alessandrelli
43e429fa93 [HTML5] Add jsdoc2rst tool.
A template for `jsdoc` that generat the HTML5 public classref.

The script can be run via `npm run docs` to print to stdout.

You can dry run via `npm run docs -- --d dry-run` or write to file via
`npm run docs -- -d /path/to/file.rst`

Also update Makefile in `doc/` and add dry run test to CI.

(cherry picked from commit 472482013e)
2021-02-26 15:35:45 +01:00
Fabio Alessandrelli
681c10af45 [HTML5] Document Engine and EngineConfig (jsdoc).
This commit also removes the utils.js engine file, moving some of it's
content to config.js and some to engine.js .

(cherry picked from commit 018ee5a4dc)
2021-02-26 15:35:38 +01:00
Eric M
3b2c43312c Fixed issues with slider focus and scroll input
(cherry picked from commit 707cf278a5)
2021-02-26 15:27:42 +01:00
hilfazer
8a7d0d3ce0 Prevent 'Change Type' on nodes from an instanced scene
(cherry picked from commit e28cc34db8)
2021-02-26 15:26:31 +01:00
kobewi
ad204f9b95 Save ProjectSettings on editor restart
(cherry picked from commit 59e1c007a7)
2021-02-26 15:24:19 +01:00
Fabio Alessandrelli
9084e2e85b Fix thread_process_array when NO_THREADS.
(cherry picked from commit dfbeb5ae29)
2021-02-26 15:23:23 +01:00
Fabio Alessandrelli
e3664e971b [HTML5] Make editor HTML build tag scons4-proof.
We used to have it like `$GODOT_VERSION` which caused inconsistencies
between different scons versions when substituting it.
It's now `@GODOT_VERSION@`, which is safe on both scons3 and scons4.

(cherry picked from commit 4404eb57e4)
2021-02-26 15:22:51 +01:00
Meriipu
6f77f1bb3e If the mouse is held on notification_wm_mouse_exit, do not drop focus
This fixes a bug where users of the scrollbar had to be very careful
not to move the mouse outside the viewport, otherwise the scrollbar
would drop its drag-action and stop scrolling until clicked again.

The existing behaviour had the side-effect of also dropping the
cosmetic highlighting of the scrollbar (in addition to the dragging),
for the specific case where the mouse was move outside the window.
The previous behaviour did nothing to remove the highlight if the
mouse was released (but not moved) inside the viewport.

This separate issue with the lingering highlight of the scrollbar
(until a mouse-movement action is performed inside the viewport) is
fixed in an immediate followup to this commit.

Closes bug #39634

(cherry picked from commit 44657db3e2)
2021-02-26 15:22:08 +01:00
Delf Neumärker
28e36dc7b9 Fix crash when loading a scene containing an uncreatable type
(cherry picked from commit 04a4828c5e)
2021-02-26 11:30:38 +01:00
Mateo Kuruk Miccino
bdf335d369 SCons: Fix profile type. It is a string
(cherry picked from commit 42f6d7a401)
2021-02-26 11:30:19 +01:00
Haoyu Qiu
2003a41f0f Fixes typo in Array::bsearch_custom doc
(cherry picked from commit 31243e377f)
2021-02-26 11:29:35 +01:00
Pun1sher
1958a5b35e Checking for half_image_size[ x & y ] to be non-negative.
This make sure that (1x1) , (1 x X) and (X , 1) pixel images using sub-sampling will get correct half_image_size i.e NON-NEGATIVE.
fix : https://github.com/godotengine/godot/issues/42363

(cherry picked from commit ec6a4c92fe)
2021-02-26 11:27:45 +01:00
Carlos Cabello
d6c67d0521 Add descriptive error message when trying to access a dir fails
(cherry picked from commit edb8c11970)
2021-02-25 22:40:32 +01:00
Hugo Locurcio
b2725cb4b9 Improve the OS.get_environment()/OS.set_environment() documentation
(cherry picked from commit 355803db1b)
2021-02-25 22:38:07 +01:00
Hugo Locurcio
3b4dd88e56 Improve the editor HTML template
- Darken the header tab background to match the default editor
  background color.
- Hide the distracting focus outlines for the editor and game canvas.
- Use a pure black background for the game canvas to better distinguish it
  from the editor and provide a more neutral background.
- Use a bold font weight for the Start Godot editor button on the
  loader page.
- Link to the web editor documentation on the loader page.
- Clarify what happens when clicking "OK" in the persistent data removal
  warning dialog.
- Tidy up the HTML template by removing obsolete attributes.

(cherry picked from commit 3527756943)
2021-02-25 22:37:49 +01:00
Jack Linhart
8190305075 Added GridMap description to get_bake_meshes()
(cherry picked from commit 03fd2b4c86)
2021-02-25 22:37:29 +01:00
Hugo Locurcio
b3c01392fd Document seamless noise having a lower contrast than non-seamless noise
See #41787.

(cherry picked from commit 2e8e6e26a8)
2021-02-25 22:37:04 +01:00
booer
b8354a45bd Update Inspector when changing AudioEffectChorus voice_count
Fixes #31627.

(cherry picked from commit 65975b9a08)
2021-02-25 22:36:42 +01:00
Taylor C. Richberger
59b82e1b6a remove invalid codeLensProvider value from lsp
codeLensProvider was false, it may not be a boolean like some of the other providers can, only optionally present.

(cherry picked from commit 91ce8d5fff)
2021-02-25 22:34:56 +01:00
Pedro J. Estébanez
5a67eefbcf Fix SafeNumeric::conditional_increment() for NO_THREADS
(cherry picked from commit b1edb69249)
2021-02-25 22:34:15 +01:00
Rémi Verschelde
1aa02d5ceb
Merge pull request #46422 from touilleMan/exit-status-on-godot-error-cherry-pick-3.2
[3.2] Fix Godot returned status code on unexpected error
2021-02-25 22:34:08 +01:00
Rémi Verschelde
fb301a0c43
Merge pull request #38351 from avril-gh/remember-scripts-panel-visibility-in-project-metadata
preserve scripts panel visibility state between sessions in project metadata
2021-02-25 21:17:02 +01:00
Emmanuel Leblond
94fe2dd31e
Fix Godot returned status code on unexpected error 2021-02-25 18:39:29 +01:00
Rémi Verschelde
6fc9c409dd
Merge pull request #46420 from nekomatata/draw-collision-outline-option-3.2
[3.2] Added option in project settings to draw Shape2D outlines
2021-02-25 17:15:52 +01:00
Rémi Verschelde
e919a413fb
Merge pull request #46397 from trollodel/collisionobject3d-debug-shapes-3.2
Allow CollisionObject to show collision shape meshes
2021-02-25 16:54:47 +01:00
PouleyKetchoupp
d94cd42ccd Added option in project settings to draw Shape2D outlines
Disabling collision outlines can be useful for performance when the game
is running and many collision shapes are displayed.
2021-02-25 07:48:33 -07:00
Rémi Verschelde
dadba2b391
Merge pull request #46392 from YeldhamDev/here_comes_another_rc
Backport the Import Defaults Editor
2021-02-25 15:45:34 +01:00
Rémi Verschelde
c16e614d88
Merge pull request #46417 from akien-mga/3.2-cherrypicks
Cherry-picks for the 3.2 branch (future 3.2.4) - 25th batch
2021-02-25 15:35:42 +01:00
Rémi Verschelde
96d38d9751 Revert "Warn when setting Control size inside ready()"
This reverts commit a8105d73c7.

We need to improve the logic somewhat to make the warning more specific to
actual problematic scenarios. Will likely be cherry-picked again + fixes
for the next release.

Fixes #46376.
2021-02-25 15:14:32 +01:00
PouleyKetchoupp
ea1d4256a4 Added LocalVector to Visual Studio debugger visualization
(cherry picked from commit 27d5e1fff0)
2021-02-25 15:14:32 +01:00
kleonc
5d628535b9 Geometry2D::make_atlas Fail is passed invalid rect size
(cherry picked from commit 988f4cdc90)
2021-02-25 15:14:32 +01:00
Fredia Huya-Kouadio
65eb5fdf1e Update the initialization timeline for the Godot fragment to be more consistent with the previous activity based timeline.
(cherry picked from commit 3ce7678374)
2021-02-25 15:14:32 +01:00
Fredia Huya-Kouadio
9fb5215db5 Add logic to record the version of the Godot engine for the Android platform.
(cherry picked from commit bc5120eb97)
2021-02-25 15:14:32 +01:00
kleonc
80e4b2d02e MeshDataTool::create_from_surface Fail on invalid index data
(cherry picked from commit 8e82cf8174)
2021-02-25 15:14:32 +01:00