Commit graph

3096 commits

Author SHA1 Message Date
Marcel Admiraal
3697cc479d
Initialise Basis elements with a default Basis in the declaration.
Ensures a valid Basis is created with all constructors.

(cherry picked from commit 9149fb760c)
2020-09-08 15:04:54 +02:00
Marcel Admiraal
c6cccdf0c6 Ensure header guards enclose entire header.
(cherry picked from commit f6ad1954f7)
2020-09-04 08:48:35 +02:00
Hugo Locurcio
ee97e45a69 Improve the resource loading error message to mention the need to import
This is a common pitfall when setting up projects in a headless
environment.

(cherry picked from commit 58ed3037c0)
2020-09-04 08:48:17 +02:00
Yakov Borevich
63b2f69c7f
[funexpected] clear missed remaps on deinitialization, fixes godotengine/godot#34221
(cherry picked from commit 604bd75438)
2020-08-31 15:29:46 +02:00
Rémi Verschelde
5a96c24243
Revert "Check if global class file still exists before registering it"
And revert follow-up regression fix "Remap script path when registering class."

After the regression fix, the original issue is valid again so it's better
to go back to the previous state.

This reverts commits e264ae20d2 and
fceb64827e.

(cherry picked from commit f13207254c)
2020-08-25 14:33:46 +02:00
Rémi Verschelde
42dca43c50
Merge pull request #41029 from masi456/fix/40888
Make sure that Image is not locked before creation
2020-08-21 02:27:22 +02:00
Rémi Verschelde
e283d4b5c8 Update AUTHORS and DONORS list
New contributors added to AUTHORS:
@hinlopen, @naithar, @rrcore, @SkyLucilfer, @TwistedTwigleg

Thanks to all contributors and donors for making Godot possible!

---

Also changes to relevant code that parses the DONORS.md to match
the new tiers.

(cherry picked from commit d2d4c1c957)
2020-08-14 00:32:05 +02:00
Fabio Alessandrelli
a97b84378c Remap script path when registering class.
Was causing `class_name`-defined scripts to not being loaded in exported
games due to the remap from `*.gd` to `*.gdc`/`*.gde`.

(cherry picked from commit fceb64827e)
2020-08-14 00:32:04 +02:00
bruvzg
8dab067c01
Add missing NULL termination to the String::repeat function. 2020-08-11 17:23:44 +03:00
Marcel Schneider
c62ce03679 Make sure that a new image can only be created when the buffer is not currently locked 2020-08-05 20:55:31 +02:00
Wilson E. Alvarez
4f9ca00294 Check if global class file still exists before registering it
(cherry picked from commit e264ae20d2)
2020-07-29 18:23:03 +02:00
Nathan Franke
b9e1db7e03
Revert "Fix Directory Open Check"
This reverts commit 3f898f5207.
2020-07-28 13:54:13 -04:00
Nathan Franke
9de0439a45
Revert "Follow-Up Fix Directory Open"
This reverts commit ec787f0134.
2020-07-28 13:53:57 -04:00
Nathan Franke
4c100a593f
Revert "Fix Directory make_dir and make_dir_recursive"
This reverts commit 9b36357544.
2020-07-28 13:53:30 -04:00
Wilson E. Alvarez
993a421333 Show errors on Object.call_deferred
(cherry picked from commit 1cd02ef600)
2020-07-28 00:40:07 +02:00
Rémi Verschelde
a2edf04fd2
Merge pull request #40469 from nekomatata/virtual-keyboard-enter-fixes-3.2
[3.2] Fix Return key events in LineEdit & TextEdit on Android
2020-07-26 20:26:02 +02:00
Rémi Verschelde
b40f3f9740 Style: Sync other changes from new fix_style.sh and clang_format.sh 2020-07-24 10:39:18 +02:00
Adam Bates
b35970b9a5 issue-40396 - Added missing error strings to JSON parsing when array or object is never closed.
(cherry picked from commit 8f84dfa91d)
2020-07-24 10:31:57 +02:00
Nathan Franke
9b36357544 Fix Directory make_dir and make_dir_recursive
(cherry picked from commit 210ccb3a75)
2020-07-24 10:31:57 +02:00
Aaron Franke
3ab5183ffa
[3.2] Backport core documentation changes to 3.2
Also add AABB.abs()
2020-07-21 21:22:54 -04:00
PouleyKetchoupp
c0b394572f Fix Return key events in LineEdit & TextEdit on Android
Depending on the device implementation, editor actions could be
received with different action ids or not at all for multi-line.

Added a parameter to virtual keyboards to properly handle single-line
and multi-line cases in all situations.

Single-line:
Input type set to text without multiline to make sure actions are sent.
IME options are set to DONE action to force action id consistency.

Multi-line:
Input type set to text and multiline to make sure enter triggers new lines.
Actions are disabled by the multiline flag, so '\n' characters are
handled in text changed callbacks.
2020-07-17 18:25:40 +02:00
Fabio Alessandrelli
468a1c0271 UDPServer handles PacketPeerUDP-client association
UDPServer now uses a single socket which is shared with the
PacketPeerUDP it creates and has a new `poll` function to read incoming
packets on that socket and delivers them to the appropriate peer.
PacketPeerUDP created this way never reads from the socket, but are
allowed to write on it using sendto.

This is needed because Windows (unlike Linux/BSD) does not support
packet routing when multiple sockets are bound on the same address/port.

(cherry picked from commit 147bbe2155)
2020-07-15 12:48:18 +02:00
Rémi Verschelde
a06ee5e763 PO loader: Fix unclosed files and error messages
Fixes #40324.

(cherry picked from commit 47cc202972)

Also removes empty `p_path` as done in 4857648a16.
2020-07-15 12:48:18 +02:00
Andrii Doroshenko (Xrayez)
813fab55d8 Fix overriding compression related settings
(cherry picked from commit 1f73469b50)
2020-07-13 15:15:40 +02:00
Hugo Locurcio
c2a4ce9380 Enable file logging by default on desktops to help with troubleshooting
- Use the `.log` file extension (recognized on Windows out of the box)
  to better hint that generated files are logs. Some editors provide
  dedicated syntax highlighting for those files.
- Use an underscore to separate the basename from the date and
  the date from the time in log filenames. This makes the filename
  easier to read.
- Keep only 5 log files by default to decrease disk usage in case
  messages are spammed.

(cherry picked from commit 20af28ec06)
2020-07-10 11:03:32 +02:00
Nathan Franke
ec787f0134 Follow-Up Fix Directory Open
(cherry picked from commit 6952458538)
2020-07-10 10:21:39 +02:00
PouleyKetchoupp
fe0adc4f77 Keep debug & verbose options after loading project from project manager
(cherry picked from commit b2d27214aa)
2020-07-10 08:51:21 +02:00
Nathan Franke
3f898f5207 Fix Directory Open Check
(cherry picked from commit 09aeb7706b)
2020-07-08 09:01:57 +02:00
bruvzg
e9ab41b71d
[macOS, 3.2] Implement seamless display scaling. 2020-07-07 22:54:33 +03:00
Rémi Verschelde
07b24de868
Merge pull request #38724 from madmiraal/fix-8368-3.2
[3.2] Support SDL2 half axes and inverted axes mappings.
2020-07-06 23:10:47 +02:00
Maganty Rushyendra
7670e1fc79 Fix errors in overflow checks for String conversion to int
Current error checks for to_int and to_int64 do not issue overflow error
messages for INT64_MAX + 1, INT64_MAX + 2, and others close to the
limits. Likewise, error checks for hex_to_int, hex_to_int64 and bin_to_int64
issue false positive error messages for INT64_MIN or INT32_MIN. This commit
fixes these error checks.
2020-07-06 08:44:18 +08:00
Rémi Verschelde
8e6dd3191f Image: Improve error messages for invalid creation size
(cherry picked from commit b5488def47)
2020-07-03 15:34:30 +02:00
Paul Herman
850f07a4d9 Expose loading TGA images in Image.
(cherry picked from commit 7d4b3e6587)
2020-07-03 13:17:57 +02:00
Marcel Admiraal
50d69a5a3d Call CRASH_COND_MSG if key not found in HashMap get function.
(cherry picked from commit 1b05f449f0)
2020-07-03 13:17:57 +02:00
Fabio Alessandrelli
dc8b7b3b17 Move frame delaying functions from Main to OS.
Will allow specific platforms to override it and avoid blocking on the
main/GUI thread.

(cherry picked from commit 1b6e3458b2)
2020-07-02 13:52:02 +02:00
Maganty Rushyendra
cd3a3eb3eb Fix weekday calculation in get_datetime_from_unix_time for negative times
Fix calculation for negative times to ensure Sundays are wrapped around to '0'
instead of '7', making it consistent with the output for positive times.

(cherry picked from commit aae5f246ff)
2020-06-29 10:58:41 +02:00
Rémi Verschelde
94eaeb5e84
Merge pull request #39903 from RandomShaper/fix_object_rc_leak
Fix leaked ObjectRCs on object Variant reassignment
2020-06-28 09:53:32 +02:00
Pedro J. Estébanez
b02e0b0c4b Fix debugger error when Dictionary key is a freed Object 2020-06-28 02:36:13 +02:00
Pedro J. Estébanez
dca653cc3a Fix leaked ObjectRCs on object Variant reassignment
Bonus:
- Add some (un)likely magic
- Use memdelete() instead of memfree() (not strictly needed, but more correct)
2020-06-28 01:31:00 +02:00
Marcel Admiraal
ebff150680 Support SDL2 half axes and inverted axes mappings. 2020-06-26 06:28:56 +01:00
Maganty Rushyendra
afac2514f8 Fix upscaling image with bilinear interpolation option specified
Fix error in calculation of 4 nearest points in source image when
resizing image with bilinear interpolation.

(cherry picked from commit f24ec3878e)
2020-06-24 22:52:05 +02:00
Rémi Verschelde
571a0c60c0 Revert "Implement Skew in Node2D"
This reverts commit 7f61710183.

See #38868, in its current implementation a small skew value might end up
serialized to scene files due to floating point precision errors, which is
detrimental to VCS.

This can be cherry-picked anew once a fix for #38868 has been found.
2020-06-22 10:26:06 +02:00
Sergey Minakov
af1788baf3 Variant: Fix potential crash when stringifying deleted Object
Fixes #38597.
2020-06-22 08:53:47 +02:00
Andy Maloney
7f18163ea6 [3.2] Ensure FileAccessBuffered structs are properly initialized 2020-06-19 11:32:53 -04:00
Aaron Franke
6e3a1074ce Simplify Transform2D get_rotation
(cherry picked from commit 0fa478a050)
2020-06-18 11:29:28 +02:00
Andrea Catania
74d10e766e - Added more euler rotation orders support.
- Fixed floating point issue on the old one.
- Fixed the equation on the get_euler_yxz function.
- Added unit tests.

This work has been kindly sponsored by IMVU.

(cherry picked from commit 2331300989)
2020-06-18 11:29:28 +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
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
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