Commit graph

27222 commits

Author SHA1 Message Date
Aaron Franke 01061c6fbb Simplify some code in platform/uwp/export
(cherry picked from commit 068054002d)
2020-06-15 14:34:35 +02:00
Tomasz Chabora 355868a5db Fix custom types in node list search
(cherry picked from commit 22f0de8a83)
2020-06-15 14:34:34 +02:00
Hugo Locurcio 5a1f94ba47 Document the in operator in String, Array and Dictionary classes
This also clarifies the `in` operator behavior in Object.

(cherry picked from commit 7f01f68226)
2020-06-15 14:34:34 +02:00
Pedro J. Estébanez c15e5af60e Fix wrong internal format for half-float textures 2020-06-15 13:03:13 +02:00
Rémi Verschelde 50c4834548
Merge pull request #39502 from bruvzg/kbd_layouts_3
[3.2] Add keyboard layout enumeration / set / get functions.
2020-06-15 11:11:08 +02:00
Rémi Verschelde ba47cdf815
Merge pull request #39501 from hilfazer/favourite-project-button
Fixed 'Favourite' button in Project Manager
2020-06-15 09:28:43 +02:00
Rémi Verschelde fac9f8f82d
Merge pull request #39538 from Faless/js/2phase
[3.2] Use 2-phase setup in JavaScript.
2020-06-14 22:57:56 +02:00
Fabio Alessandrelli 1c0abd6393 Use 2-phase setup in JavaScript.
Make the first iteration as soon as the canvas is setup, avoiding a
black screen before the next animation frame is requested.
Also create OS and do setup before syncing FS to avoid crash when IDBFS
access is denied.
2020-06-14 15:43:18 +02:00
Rémi Verschelde 6efab27a41
Merge pull request #39531 from lawnjelly/kessel_light_join_next
GLES2 Batching - Fix try_join_item logic for lights
2020-06-14 10:39:27 +02:00
lawnjelly 94d127ccc3 GLES2 Batching - Fix try_join_item logic for lights
The old logic was incorrect, the first item with lights would prevent joining the next item in case it didn't have lights. Now the check is deferred so that items without lights check to see if the previous item had lights, and if so they prevent a join.
2020-06-14 08:22:41 +01:00
Rémi Verschelde 879014c3ff
Merge pull request #39504 from madmiraal/fix-39500-3.2
[3.2] Ensure pair callback data is set to null when it's null.
2020-06-13 16:33:06 +02:00
Marcel Admiraal a48e13101d Ensure pair callback data is set to null when it's null. 2020-06-13 14:37:40 +01:00
hilfazer 14fcd20e86 Fixed "Favourite Project" button in Project Manager 2020-06-13 11:38:29 +02:00
bruvzg 2256946f79
[3.2] Add keyboard layout enumeration / set / get functions (macOS, Windows, Linux/X11). 2020-06-13 11:01:49 +03:00
Rémi Verschelde 6c9b7c27d5
Merge pull request #39428 from fire/gltf-lights
[3.2] Add GLTF light import
2020-06-11 22:40:47 +02:00
Rémi Verschelde 5ee9553591
Merge pull request #39463 from akien-mga/3.2-scons-py2-fixup
[3.2] SCons: Fix python2 compatibility after #37198 and #37248
2020-06-11 22:35:17 +02:00
Rémi Verschelde c87b4f9d71 SCons: Fix python2 compatibility after #37198 and #37248 2020-06-11 20:15:48 +02:00
Rémi Verschelde 362193db6a String: Use ABS macro in padding code
Follow-up to #39261.

(cherry picked from commit cbcc0eacd5)
2020-06-11 11:44:06 +02:00
Rémi Verschelde e241dae44d Set version to 3.2.2-rc once again 2020-06-11 10:00:52 +02:00
Rémi Verschelde d68e631566 i18n: Sync translations with Weblate 2020-06-11 10:00:07 +02:00
Rémi Verschelde c80ab247b7 doc: Sync classref with current source
(cherry picked from commit fef49bff0b)
2020-06-11 10:00:07 +02:00
Maganty Rushyendra 158e8ee051 Enable Unicode support for RegEx class
Build PCRE2 thirdparty library with unicode support. RegEx objects
in Godot can now be used to recognize unicode strings.

(cherry picked from commit 9f10f6779c)
2020-06-11 10:00:06 +02:00
Victoria Fisher aa448a2a07 Adds full description for AudioEffectRecord.xml
(cherry picked from commit 718221a2ff)
2020-06-11 10:00:06 +02:00
Maganty Rushyendra 0efa59bfdc Account for file deletion and renaming in Export Presets
Ensure that presets are updated with the latest files when
starting up or opening the Project Export dialog. Fixes the
error where Godot would attempt to export deleted files that
were previously selected.

(cherry picked from commit 44094b082d)
2020-06-11 10:00:06 +02:00
Hugo Locurcio c87128fa06 Improve the 3D light documentations
See https://github.com/godotengine/godot-docs/issues/3670.

(cherry picked from commit f7e21d8e88)
2020-06-11 10:00:06 +02:00
SaviHex fda49b74a1 Added a "title" attribute for the link tag in the docs xml
(cherry picked from commit 18c08f65d6)
2020-06-11 09:44:14 +02:00
Thibault Truffert 24b3bf0637 Make text deletion methods public for LineEdit
(cherry picked from commit 2bb44ea5bd)
2020-06-11 09:42:23 +02:00
Maganty Rushyendra 6344b75453 Enable zero padding with float specifier for format strings
Godot currently supports zero padding for integers, octals and
hexadecimals when using format strings, but not for floats.

This commit adds support for zero padding for floats, thus ensuring
consistent behavior for all types, and making Godot's format specifiers'
behavior closer to c's `printf()`.

Before: `print("<%07.2f>" % -0.2345)` prints `<  -0.23>`.
Now: `print("<%07.2f>" % -0.2345)` prints `<-000.23>`.
     `print("<%7.2f>" % -0.2345)` prints `<  -0.23>`.
(cherry picked from commit b7d835d9ca)
2020-06-11 09:41:37 +02:00
ntfs.hard a822d1f133 Fix for Expression class: inner string can be single quoted
(cherry picked from commit ec164b2301)
2020-06-11 09:41:13 +02:00
lawnjelly b330766c30 Fix overflow condition with QueryPerformanceCounter
The previous code for OS_Windows::get_ticks_usec() multiplied the tick count by 1000000 before dividing by ticks_per_second. The ticks is counted in a 64 bit integer and is susceptible to overflow when a machine has been running for a long period of time (days) with a high frequency timer.

This PR separates the overall calculation into one for seconds and one for the remainder, removing the possibility of overflow due to the multiplier.

(cherry picked from commit db9fa88160)
2020-06-11 09:40:04 +02:00
Rémi Verschelde 0eaefa73a1
Merge pull request #39448 from mrushyendra/duplicate_signals
[3.2] Fix signal duplication bug when duplicating node with instanced children
2020-06-11 09:29:20 +02:00
Aaron Franke e3cf64a7d8
[3.2] Add GLTF light import
Co-authored-by: K.S. Ernest (iFire) Lee <ernest.lee@chibifire.com>
2020-06-10 23:51:34 -04:00
Maganty Rushyendra 0df5d74e6e Fix signal duplication bug when duplicating node with instanced children
Change error checking in `duplicate_signals()` to check for path to
`p_original`, thus adhering to the method used in `duplicate`, instead
of checking for ownership.
2020-06-11 09:37:47 +08:00
Rémi Verschelde 1df2e81d3e
Merge pull request #38507 from RandomShaper/fix_cleanup_info_3.2
Fix potential crash when listing leaked objects (3.2)
2020-06-10 21:49:33 +02:00
Pedro J. Estébanez f09046a9ab Fix potential crash when listing leaked objects
Note:
Casting to the C++ classes and calling the methods there would work as well,
but would require including he header files for the specific object types handled
here, which wouldn't be OK either.
2020-06-10 20:16:10 +02:00
Rémi Verschelde 3fb9c776ff
Merge pull request #39437 from akien-mga/3.2-cherrypicks
Cherry-picks for the 3.2 branch (future 3.2.2) - 8th batch
2020-06-10 17:33:50 +02:00
Rémi Verschelde 3c7e03510c
Merge pull request #39256 from lawnjelly/tilemap_pixel2
GLES2 batching - Add UV precision adjustment for tilemaps
2020-06-10 15:52:00 +02:00
bruvzg f99ead735c Git Hooks: Suppress "which" error messages.
(cherry picked from commit 05f041127d)
2020-06-10 15:33:27 +02:00
bruvzg 320ae61090 Git Hooks: Add support for GUI git clients.
[ci skip]

(cherry picked from commit fdad0e3bd1)
2020-06-10 15:33:23 +02:00
PouleyKetchoupp ff11fdd017 Pre-commit hook instructions on Windows
(cherry picked from commit 7b6e664178)
2020-06-10 15:32:18 +02:00
Andrii Doroshenko (Xrayez) 23ef1e0f70 SCons: Dump construction environment to a file
A new `methods.dump(env)` is added to dump the construction environment
used by SCons to build Godot to a `.scons_env.json`. The file can be used
for debugging purposes and any external tool.

(cherry picked from commit 42bee75e86)
2020-06-10 15:30:52 +02:00
Andrii Doroshenko (Xrayez) bc21cd8592 Moved to methods.py as a show_progress method.
Some required changes are made:
- locally imported SCons-specific packages within the method;
- `global` variables converted to `nonlocal` (used in nested functions).

(cherry picked from commit d753a7630a)
2020-06-10 15:30:52 +02:00
Rémi Verschelde efdeba3326 Travis: Add static check for Python black formatting
Also install and use pygmentize to visualize clang-format and black
diffs.

(cherry picked from commit 3644036fd3)
2020-06-10 15:30:52 +02:00
Rémi Verschelde 243377ffac Hooks: Use pygmentize if available to visualize diff
(cherry picked from commit 4d52761da6)
2020-06-10 15:30:52 +02:00
Rémi Verschelde 1ec7a73d1c Hooks: Add pre-commit hook for psf/black formatting
(cherry picked from commit 164826a39b)
2020-06-10 15:30:52 +02:00
Rémi Verschelde 7bf9787921 SCons: Format buildsystem files with psf/black
Configured for a max line length of 120 characters.

psf/black is very opinionated and purposely doesn't leave much room for
configuration. The output is mostly OK so that should be fine for us,
but some things worth noting:

- Manually wrapped strings will be reflowed, so by using a line length
  of 120 for the sake of preserving readability for our long command
  calls, it also means that some manually wrapped strings are back on
  the same line and should be manually merged again.

- Code generators using string concatenation extensively look awful,
  since black puts each operand on a single line. We need to refactor
  these generators to use more pythonic string formatting, for which
  many options are available (`%`, `format` or f-strings).

- CI checks and a pre-commit hook will be added to ensure that future
  buildsystem changes are well-formatted.

(cherry picked from commit cd4e46ee65)
2020-06-10 15:30:52 +02:00
Hugo Locurcio c3d04167a4 Document the requirement to update the class reference when contributing
Documenting new additions has been an informal requirement for
a few months now. This makes it official.

(cherry picked from commit 6d0e8f9fb7)
2020-06-10 15:30:52 +02:00
Hugo Locurcio c39c3e3237 Improve CONTRIBUTING.md and update it to follow recent changes
- Improve the bug reporting guidelines for readability.
  - Make some guidelines more strictly applied in the interest of
    bug report quality.
- Mention that feature proposals should now be opened on the
  Godot Proposals repository.
- Update the Git commit message guide to be easier to follow.
- Fix warnings reported by markdownlint.

(cherry picked from commit 7b5c502ba5)
2020-06-10 15:30:52 +02:00
Hugo Locurcio 8e8861ed06 Mention ordering caveats for Dictionary.hash()
See https://github.com/godotengine/godot/issues/27615.

(cherry picked from commit 77b89263dd)
2020-06-10 15:30:52 +02:00
Michael Alexsander 5495bbdd47 Fix scene tree showing up when the root selection is present
(cherry picked from commit f30e4dbf54)
2020-06-10 15:30:52 +02:00