Commit graph

289 commits

Author SHA1 Message Date
Aaron Franke
c399424db9
Move 3D-only resources to their own folder 2024-02-26 05:23:04 -06:00
Rémi Verschelde
4859f8090f
Merge pull request #85455 from xiongyaohua/fix_CSGPolygon_not_following_Path3D
Notify CSGPolygon about transform changes in Path3D
2024-02-15 15:44:39 +01:00
A Thousand Ships
684752e75b
Replace error checks against size with is_empty 2024-02-09 12:50:15 +01:00
kobewi
0e8f90f4c8 Update deferred calls to use Callables 2024-01-09 16:11:47 +01:00
Yaohua Xiong
0e344f0d0b Path3D notify transform change to CSGPolygon 2024-01-08 18:29:18 +08:00
Yuri Sizov
e18659c69d Merge pull request #82872 from jsjtxietian/require-editor-restart-when-csg-gizmo-color-changed
Prompt require editor restart to user when gizmo color changed
2023-12-19 20:32:20 +01:00
Yuri Sizov
714e27393a Merge pull request #84652 from timothyqiu/enum-pun
Avoid punning enum names in documentation
2023-12-19 13:01:10 +01:00
Rémi Verschelde
94edf0f9a1
Merge pull request #80326 from MewPurPur/no-exp-with-zero
Remove exp hint of a few properties
2023-12-04 22:57:09 +01:00
Haoyu Qiu
cc3984f359 Avoid punning enum names in documentation 2023-11-09 17:16:30 +08:00
Yuri Sizov
a8bcbff59f Merge pull request #82133 from MewPurPur/svg-tweaks
Optimize and tweak some SVGs, improve consistency between icons, and fix broken masks in light mode
2023-11-06 13:22:59 +01:00
MewPurPur
03d1830176 Optimize, tweak, improve consistency in SVG icons, and fix masks in light mode 2023-11-04 17:36:18 +02:00
smix8
0cba21f2da Fix CSGShape debug_collision_shape crash
Fixes CSGShape debug_collision_shape crash.
2023-11-02 11:23:47 +01:00
jsjtxietian
173e2c7f29 Hide CSGShape's debug_collision_shape when it is invisible 2023-10-30 14:53:09 +08:00
jsjtxietian
b0ccd5c84f Prompt require editor restart to user when gizmo color changed 2023-10-06 15:02:03 +08:00
A Thousand Ships
517e9f8aef [Modules] Replace ERR_FAIL_COND with ERR_FAIL_NULL where applicable 2023-09-26 16:44:52 +02:00
MewPurPur
a40a2ff7d9 Improve the Torus icons 2023-09-20 15:42:37 +03:00
kobewi
015953a3d9 Add helper for 3D gizmos and unify box 2023-09-12 18:08:02 +02:00
pidogs
f476b74ecf
Make CSGShape follow curve's tilt in Path mode
Fixes #65634.
2023-08-17 12:01:29 +02:00
mandryskowski
378f835a9c
Clarify the behaviour of CSGMesh3D using ArrayMesh 2023-08-12 13:21:27 +02:00
MewPurPur
09270f9624 Remove exp hint of a few properties 2023-08-06 12:18:27 +03:00
kobewi
de4a3fa151 Unify and streamline connecting to Resource changes 2023-07-17 19:35:57 +02:00
Rémi Verschelde
81064cc239
Doctool: Remove version attribute from XML header
We don't use that info for anything, and it generates unnecessary diffs
every time we bump the minor version (and CI failures if we forget to
sync some files from opt-in modules (mono, text_server_fb).
2023-07-06 10:08:21 +02:00
Rémi Verschelde
346f1ab86b
Bump version to 4.2-dev
Keep on waitin'
2023-07-05 22:07:03 +02:00
Rémi Verschelde
25b2f1780a
Style: Harmonize header includes in modules
This applies our existing style guide, and adds a new rule to that style
guide for modular components such as platform ports and modules:

Includes from the platform port or module ("local" includes) should be listed
first in their own block using relative paths, before Godot's "core" includes
which use "absolute" (project folder relative) paths, and finally thirdparty
includes.

Includes in `#ifdef`s come after their relevant section, i.e. the overall
structure is:

- Local includes
  * Conditional local includes
- Core includes
  * Conditional core includes
- Thirdparty includes
  * Conditional thirdparty includes
2023-06-15 14:35:45 +02:00
VolTer
1f4c5a702c Optimize CSG icons and more 2023-05-29 11:26:10 +02:00
Evan Todd
da7e54ec17 Fix CSGPolygon3D in path mode disappearing at runtime. 2023-05-15 16:52:39 -07:00
Ninni Pipping
71ee65dc57 Enable shadow warnings and fix raised errors 2023-05-11 16:00:59 +02:00
Ricardo Buring
3f17a81f87 Add debug collision shape to CSG with collision 2023-05-03 08:41:37 +02:00
Justin Wash
1ac2c537da Fix infinite loop in Build2DFaces::_find_edge_intersections 2023-04-27 18:11:25 -05:00
K. S. Ernest (iFire) Lee
eaa84bc682
Fix CSG edge case causing intersection line to hit on common edge of 2 triangles.
The previous implementation assumed that the intersection entered or exited a
shape when it hit right on the common edge of 2 triangles. However, there is
also a case where it just "skirts" the other shape on the outside.

To fix this, we added code to check the intersection distance and if the
normals of the faces are pointed in the same direction as the intersection or
not (e.g. inner product > 0). This handles the case where the intersection
line hits the common edge of 2 triangles and skirts the other shape on the
outside.

Extended code to cover a third case.

Fixes #58637.

Co-authored-by: OldBelge <StevenGeens@users.noreply.github.com>
2023-04-27 11:39:29 +02:00
Yuri Sizov
391eccca76 Validate code tags in documentation for potential params
Adds a check to make_rst to look for matches
between the text inside of the [code][/code] tag
and known param identifiers.
Fixes most of what was revealed.
2023-04-26 21:36:04 +02:00
Rémi Verschelde
1c1524a651
Bump version to 4.1-dev
Can't stop, won't stop, they said, huh?
2023-03-01 01:44:37 +01:00
DESKTOP-9O27V4U\Navi
ac92704f39
Add compatibility code for CSGBox3D width/height/depth from Godot 3.x
Fixes #66420.
2023-02-13 20:41:23 +01:00
MinusKube
541b725190 Don't generate CSGPolygon3D shape before the assigned path is inside tree 2023-01-31 02:04:57 +01:00
kobewi
b58111588a Add EditorUndoRedoManager singleton 2023-01-16 01:11:52 +01:00
Rémi Verschelde
d95794ec8a
One Copyright Update to rule them all
As many open source projects have started doing it, we're removing the
current year from the copyright notice, so that we don't need to bump
it every year.

It seems like only the first year of publication is technically
relevant for copyright notices, and even that seems to be something
that many companies stopped listing altogether (in a version controlled
codebase, the commits are a much better source of date of publication
than a hardcoded copyright statement).

We also now list Godot Engine contributors first as we're collectively
the current maintainers of the project, and we clarify that the
"exclusive" copyright of the co-founders covers the timespan before
opensourcing (their further contributions are included as part of Godot
Engine contributors).

Also fixed "cf." Frenchism - it's meant as "refer to / see".
2023-01-05 13:25:55 +01:00
Hugo Locurcio
df636ac881
Document collision_priority in the CSGShape3D class 2022-10-24 18:44:30 +02:00
bruvzg
0103af1ddd
Fix MSVC warnings, rename shadowed variables, fix uninitialized values, change warnings=all to use /W4. 2022-10-07 11:32:33 +03:00
Micky
ae5771e1b1 Rename remaining "Spatial" in Plugins to "Node3D"
For EditorNode3DGizmo:
- `get_spatial_node` -> `get_node_3d`
- `set_spatial_node` -> `set_node_3d`

For EditorPlugin:
- `add_spatial_gizmo_plugin` -> `add_node_3d_gizmo_plugin`
- `remove_spatial_gizmo_plugin` -> `remove_node_3d_gizmo_plugin`

Also renames some internal methods for consistency (`forward_3d_draw_over_viewport` & `forward_3d_force_draw_over_viewport` ...). Basically, Spatial has been completely eradicated.
2022-10-04 16:27:29 +02:00
Rémi Verschelde
39facb35a0 SCons: Unify tools/target build type configuration
Implements https://github.com/godotengine/godot-proposals/issues/3371.

New `target` presets
====================

The `tools` option is removed and `target` changes to use three new presets,
which match the builds users are familiar with. These targets control the
default optimization level and enable editor-specific and debugging code:

- `editor`: Replaces `tools=yes target=release_debug`.
  * Defines: `TOOLS_ENABLED`, `DEBUG_ENABLED`, `-O2`/`/O2`
- `template_debug`: Replaces `tools=no target=release_debug`.
  * Defines: `DEBUG_ENABLED`, `-O2`/`/O2`
- `template_release`: Replaces `tools=no target=release`.
  * Defines: `-O3`/`/O2`

New `dev_build` option
======================

The previous `target=debug` is now replaced by a separate `dev_build=yes`
option, which can be used in combination with either of the three targets,
and changes the following:

- `dev_build`: Defines `DEV_ENABLED`, disables optimization (`-O0`/`/0d`),
  enables generating debug symbols, does not define `NDEBUG` so `assert()`
  works in thirdparty libraries, adds a `.dev` suffix to the binary name.

Note: Unlike previously, `dev_build` defaults to off so that users who
compile Godot from source get an optimized and small build by default.
Engine contributors should now set `dev_build=yes` in their build scripts or
IDE configuration manually.

Changed binary names
====================

The name of generated binaries and object files are changed too, to follow
this format:

`godot.<platform>.<target>[.dev][.double].<arch>[.<extra_suffix>][.<ext>]`

For example:
- `godot.linuxbsd.editor.dev.arm64`
- `godot.windows.template_release.double.x86_64.mono.exe`

Be sure to update your links/scripts/IDE config accordingly.

More flexible `optimize` and `debug_symbols` options
====================================================

The optimization level and whether to generate debug symbols can be further
specified with the `optimize` and `debug_symbols` options. So the default
values listed above for the various `target` and `dev_build` combinations
are indicative and can be replaced when compiling, e.g.:

`scons p=linuxbsd target=template_debug dev_build=yes optimize=debug`
will make a "debug" export template with dev-only code enabled, `-Og`
optimization level for GCC/Clang, and debug symbols. Perfect for debugging
complex crashes at runtime in an exported project.
2022-09-26 16:31:46 +02:00
Andy Maloney
49ff3d5489 Remove unused includes & move some includes to top of file 2022-09-23 19:06:31 -04:00
Hugo Locurcio
ae18928748
Rename Curve/Curve2D/Curve3D/Gradient interpolate() to sample()
"sampling" is a more accurate term than "interpolating" for what's
happening when using that function.
2022-08-30 22:08:38 +02:00
Micky
59e11934d8 Rename str2var to str_to_var and similar
Affects the Math class, a good chunk of the audio code, and a lot of other miscellaneous classes, too.

- `var2str` -> `var_to_str`
- `str2var` -> `str_to_var`
- `bytes2var` -> `bytes_to_var`
- `bytes2var_with_objects` -> `bytes_to_var_with_objects`
- `var2bytes` -> `var_to_bytes`
- `var2bytes_with_objects` -> `var_to_bytes_with_objects`
- `linear2db` -> `linear_to_db`
- `db2linear` -> `db_to_linear`
- `deg2rad` -> `deg_to_rad`
- `rad2deg` -> `rad_to_deg`

- `dict2inst` -> `dict_to_inst`
- `inst2dict` -> `inst_to_dict`
2022-08-26 14:58:22 +02:00
Rémi Verschelde
b8a64313f0
Merge pull request #59564 from KoBeWi/FINALLY,_ULTIMATE_UNDO_REDO 2022-08-22 22:37:33 +02:00
Rémi Verschelde
1f61d47766
Merge pull request #64339 from YuriSizov/core-multilevel-validate-property 2022-08-22 21:39:48 +02:00
kobewi
ece3df3938 Add per-scene UndoRedo 2022-08-22 18:05:10 +02:00
Yuri Sizov
1a24c9e14b Make _validate_property a multilevel method 2022-08-22 18:35:11 +03:00
Rémi Verschelde
5193332d10
Merge pull request #64343 from TokageItLab/priority-ph 2022-08-22 17:31:23 +02:00
RedMser
c25b8f2876 Remove unintentional PROPERTY_USAGE_INTERNAL
The flag only matters for property definition,
but was also used in _validate_property a lot.
2022-08-18 16:25:00 +02:00
Silc Renew
b31115cdc1 Add collision weight to PhysicsBody for penetrations must be avoided
Co-authored-by: Juan Linietsky <reduzio@gmail.com>
2022-08-18 08:10:31 +09:00