Commit Graph

1865 Commits

Author SHA1 Message Date
Hugo Locurcio aa9403bcda
Clamp VoxelGI extents to reasonable values to avoid breaking baking
This also prevents crashes when resizing a VoxelGI's extents to 0
on any axis.
2022-07-05 18:32:44 +02:00
bruvzg 329923c6ac
Use custom key structs, instead of raw hashes for the Label3D and TextMesh, to avoid potential hash collisions. 2022-07-04 09:47:49 +03:00
Rémi Verschelde 41fdddb1f8
Merge pull request #62677 from akien-mga/particles-fix-warnings-update 2022-07-03 18:42:51 +02:00
Rémi Verschelde 5d9e56ecec Particles: Fix missing configuration warning updates
Fixes #33488.
2022-07-03 16:04:20 +02:00
kleonc 73ecd71b7d Fix no `hint_string` for `frame` property in `AnimatedSprite`s 2022-07-03 15:31:43 +02:00
Rémi Verschelde a2459c7d35
Merge pull request #61610 from TokageItLab/importer-retarget-registered-gdhumanoid 2022-07-02 00:17:21 +02:00
Rémi Verschelde 692c2d9215
Merge pull request #50755 from foxydevloper/add-global-position-and-global-rotation
Add global_position and global_rotation to Node3D
2022-07-01 21:50:42 +02:00
Hugo Locurcio e7315fcc45
Clamp Decal's upper/lower fade to positive values
Negative easing values result in broken rendering.
2022-07-01 19:23:57 +02:00
foxydevloper 8b16a4131f Add global_position and global_rotation to Node3D 2022-07-01 10:27:07 -04:00
Hugo Locurcio 32973094f5
Add a Bake Mask property to GPUParticlesCollisionSDF3D
This allows not accounting for certain visible meshes during baking
(such as foliage and thin fixtures).

This also adds a clarification about transparent materials always
being excluded in the OccluderInstance3D documentation.
2022-06-30 23:12:40 +02:00
Silc Renew dc43cfc830 implement bone renamer in importer 2022-07-01 03:55:28 +09:00
Rémi Verschelde 8a00d7c847
Merge pull request #62527 from smix8/navigation_agent_property_groups
Group NavigationAgent properties
2022-06-30 01:24:05 +02:00
Rémi Verschelde a7e589df38
Merge pull request #62084 from smix8/path_debug_options_4.x
Add Path2D/3D debug options
2022-06-29 20:36:43 +02:00
smix8 dde09be302 Group NavigationAgent properties
Groups the ill-defined NavigationAgent properties between pathfinding and avoidance to make it more clear which property affects what.
2022-06-29 18:42:51 +02:00
Rémi Verschelde d53f1fb388
Merge pull request #60935 from Calinou/geometryinstance3d-gi-mode-default-static
Use the Static global illumination mode in GeometryInstance3D by default
2022-06-28 14:40:53 +02:00
Rémi Verschelde c79aad0257
Merge pull request #62396 from reduz/fix-local-vector-transitions-in-node3d
Fix VECTOR/LOCAL transitions in Node3D
2022-06-27 21:45:02 +02:00
reduz 7acf697479 Fix VECTOR/LOCAL transitions in Node3D
Fixes #62225, supersedes #62227
2022-06-27 13:45:35 +02:00
JFonS 12459ab334
Merge pull request #62124 from holgac/bugfix-62096
Fixes #62096: LightmapGIData::_get_light_textures_data crash on empty image
2022-06-26 12:30:19 +02:00
Rémi Verschelde dd3de622d8
Merge pull request #62372 from MarcusElg/nosliderrename
Rename @export_range's noslider option to no_slider
2022-06-25 14:03:44 +02:00
Juan Linietsky 14f9fbfed8
Revert "Refactored `rotation_mode` in Node3D" 2022-06-25 09:44:25 +02:00
Silc Renew 4880b86f07 fix set_position() 2022-06-25 06:17:41 +09:00
Priyansh Rathi e995764e50
add support for soft shadows to the lightmapper 2022-06-24 21:50:13 +05:30
Marcus Elg 6c1ac9f3be Rename export_range's noslider option to no_slider 2022-06-24 10:45:34 +02:00
Rémi Verschelde 49d8748848
Merge pull request #62227 from TokageItLab/fix-rotation-mode-node3d 2022-06-24 10:07:21 +02:00
Hugo Locurcio 610363add0
Use the Static global illumination mode in GeometryInstance3D by default
This makes VoxelGI and SDFGI work out of the box with primitive meshes,
loaded OBJ meshes and CSG nodes.
2022-06-23 22:34:23 +02:00
Silc Renew 51c884f7ac fix method when rotation_mode changed 2022-06-23 16:55:16 +09:00
reduz d69e3791bf Fix editor-only visibility for lights
* Update visibility again for editor-only lights if owner changes.

Fixes #26399, supersedes #52327
2022-06-23 08:19:18 +02:00
smix8 e12e239ab4 Add Path2D/3D debug options
Add Path2D/3D debug options.
2022-06-20 17:32:05 +02:00
Rémi Verschelde 21b0c7fc22
Merge pull request #62214 from smix8/navigation_layer_bitmask_helpers_4.x 2022-06-20 15:13:33 +02:00
Rémi Verschelde 3d49e89b9b
Merge pull request #62181 from smix8/navigation_navagent_pathpoint_dist_4.x 2022-06-20 14:54:16 +02:00
reduz 141c375581 Clean up Hash Functions
Clean up and do fixes to hash functions and newly introduced murmur3 hashes in #61934
* Clean up usage of murmur3
* Fixed usages of binary murmur3 on floats (this is invalid)
* Changed DJB2 to use xor (which seems to be better)
2022-06-20 12:54:19 +02:00
smix8 55923ade68 Add navigation layer bitmask helper functions
Adds helper functions to work with the navigation layer bitmask.
2022-06-19 13:47:19 +02:00
baihan da7eb96804 Fix physical bone is not animated in running project. 2022-06-19 09:46:34 +08:00
smix8 07740302f3 Add NavigationAgent desired path distance
Add NavigationAgent desired path distance
2022-06-18 19:11:49 +02:00
Hugo Locurcio 5b72ccc254
Fix Light3D `angular_distance` property hint being in radians
The unit is internally stored as degrees and is treated as such,
so it should be displayed as-is in the inspector.
2022-06-17 20:00:54 +02:00
Ellen Poe d384d84f45 Audio: Expose 2D/3D panning strength parameters 2022-06-17 13:08:48 +02:00
holgac a5c01dc25a Fixes #62096: LightmapGIData::_get_light_textures_data crash on empty image
The program crashes when trying to determine slice width/height if the
light texture is empty. This fix just returns an empty array, as if the
light texture does not exist.
2022-06-17 02:27:08 +02:00
bruvzg b5c96df277
Move duplicate AutoWrap, Overrun and VisibleChar behavior enums to the TextServer. 2022-06-16 16:49:37 +03:00
Rémi Verschelde 9ddf13e7ad
Merge pull request #60151 from Klowner/pathfollow3d-parallel-transport-improvement
PathFollow3D parallel transport frame reliability improvements
2022-06-15 23:54:00 +02:00
smix8 245da150e7 Streamline Navigation layer function names.
Streamline Navigation layer function names.
2022-06-15 00:18:48 +02:00
smix8 f10ff0efda Add NavigationAgent set_navigation_map() function
Add NavigationAgent set_navigation_map() and get_navigation_map() function.
2022-06-14 21:48:47 +02:00
Rémi Verschelde 111a3ca097
Merge pull request #59125 from KoBeWi/link_to_the_vector 2022-06-14 16:18:17 +02:00
Rémi Verschelde d845d690f2
Merge pull request #61861 from techiepriyansh/multi-image-atlases 2022-06-14 16:11:30 +02:00
kobewi 5553e27fe8 Add vector value linking
Co-authored-by: redlamp <244062+redlamp@users.noreply.github.com>
2022-06-14 14:58:44 +02:00
Priyansh Rathi d49c1cfc3e
save lightmap as multi-image atlas 2022-06-14 17:22:55 +05:30
Hugo Locurcio 0225c6d31a
Tweak Light3D property hints for greater flexibility
- Specular can now be set above 1.0.
- Blur can be set to 0 to disable shadow blurring entirely, which is useful
  on lights that have a non-zero size.
  - When shadow blurring is disabled, lights that have a non-zero size will
    not use PCSS-like soft shadows, speeding up shadow rendering
    considerably.
- Some property hints now allow more precise values.
2022-06-13 14:31:46 +02:00
FireForge 4678736a39 Add suffixes to all nodes and resources 2022-06-11 09:41:05 -05:00
Rémi Verschelde 5c3081dae2 SoftBody: Fix attachments property names after #61180
Fixes #61581.
2022-06-10 14:16:14 +02:00
smix8 cfdfd304f1 Add NavigationRegion costs for pathfinding
Add NavigationRegion costs for pathfinding.
2022-06-06 15:25:06 +02:00
Rémi Verschelde 93bbbf8947
Merge pull request #61625 from smix8/navigation_debugview_mesh_scripted_4.x 2022-06-02 18:24:30 +02:00
JFonS 8abace0f79
Merge pull request #60517 from Calinou/3d-editor-audiostreamplayer3d-add-gizmo 2022-06-02 12:11:06 +02:00
smix8 b6eff47bac Add NavigationMesh debug when navmesh is added later through scripts
Add NavigationMesh debug when navmesh is added later through scripts
2022-06-02 10:55:19 +02:00
smix8 56fe26b5e0 Fix NavigationAgent reparent issues
Fix NavigationAgent reparent issues
2022-06-01 06:45:12 +02:00
Hugo Locurcio 93933e4085
Add a gizmo to visualize AudioStreamPlayer3D's audible radius
The ring's color changes depending on the attenuation model chosen,
and whether Max Distance is capping the distance the sound can be
heard at.

Cold colors are used when the volume cap is a "soft" cap (the sound
can still be heard past the distance, but only faintly).

Warm colors are used when the volume cap is a "hard" cap (the sound
can't be heard past the distance at all).

White is used for linear fade performed when the attenuation model
is Disabled and Max Distance is greater than 0.

No ring is drawn when the attenuation model is Disabled and Max Distance
is equal to 0 (since the sound can be heard from anywhere).
2022-05-26 20:53:07 +02:00
Yuri Rubinsky 8f57d9519e Fix errors when materials attached to 3d object are not freed 2022-05-26 09:42:59 +03:00
Lyuma 1f02bc0e3e Only call _update_panning during _physics_process. 2022-05-25 14:14:22 -07:00
Hugo Locurcio e85459dcd1
Add Cone and Cylinder shapes to FogVolume
This complements the existing Ellipsoid and Box local fog shapes.

This can be used to represent a light cone coming from a SpotLight.
2022-05-25 12:35:53 +02:00
Rémi Verschelde d3268c51ad
Merge pull request #61311 from trollodel/fix_joint3d_warning_crash 2022-05-23 22:23:53 +02:00
bruvzg f9fbe92e8a
[Label3D, 4.x] Monitor default theme font changes, to prevent use of invalid materials. 2022-05-23 18:15:34 +03:00
trollodel 51b229bffa Fix Joint3D and Joint2D warning causing a crash 2022-05-23 12:21:13 +02:00
Rémi Verschelde a80793fcb8
Merge pull request #61235 from smix8/navigation_agent_avoidance_processing_4.x 2022-05-22 19:11:32 +02:00
Hugo Locurcio df9340d552
Tweak the GPUParticles3D Transform Align property hint for readability 2022-05-21 13:13:48 +02:00
smix8 7f3688603c Process NavigationAgent2D/3D avoidance on demand only
Changes NavigationAgent avoidance callback to a toggle that is disabled by default.
Also fixes a few missing descriptions / wrong warnings.
2022-05-20 23:47:10 +02:00
reduz 45af29da80 Add a new HashSet template
* Intended to replace RBSet in most cases.
* Optimized for iteration speed
2022-05-20 22:40:38 +02:00
Aaron Franke 5dc3bfb80e
Use suffixes for units in nodes and resources 2022-05-19 14:34:27 -05:00
Rémi Verschelde ce069fbe99
Merge pull request #61128 from smix8/navigation_agent_process_mode_4.x 2022-05-19 15:24:34 +02:00
Aaron Record 900c676b02 Use range iterators for RBSet in most cases 2022-05-19 12:09:16 +02:00
Haoyu Qiu fc3b845c07 Add dedicated macros for property name extraction
* Replace case-by-case extraction with PNAME & GNAME
* Fix group handling when group hint begins with property name
* Exclude properties that are PROPERTY_USAGE_NO_EDITOR
* Extract missing ADD_ARRAY*, ADD_SUBGROUP* macros
2022-05-19 14:08:47 +08:00
Rémi Verschelde 03f240ba93
Merge pull request #60599 from rburing/rest_on_recovery_param 2022-05-18 17:36:24 +02:00
Ricardo Buring f072aa69a9 Add motion parameter to toggle whether recovery is reported as a collision
This makes the intent explicit in each use case.
2022-05-18 16:40:29 +02:00
kobewi 6b981bf12b Defer group calls in Node3D 2022-05-18 16:10:03 +02:00
smix8 6b51ab66d8 Make Navigation Agents and Obstacles respect parent process mode
Temporarily removes agent from navigation map when parent node cannot process due to SceneTree pause and process_mode property. Normal process_mode does not work as other agents would still avoid the paused agents because they were still active on the navigation map and the rvo world. Also fixes potential crash when region_get_map or agent_get_map is called while no map is set.
2022-05-17 20:08:39 +02:00
Mark Riedesel 281cf5fb81 PathFollow3D parallel transport frame reliability improvements 2022-05-17 11:17:00 -04:00
Rémi Verschelde 7b571ab8f7
Merge pull request #60986 from fire-forge/capitalism 2022-05-16 13:49:14 +02:00
Rémi Verschelde f95b7412c7
Merge pull request #61057 from smix8/navigation_obstacle_transform_error_4.x 2022-05-16 13:47:28 +02:00
Rémi Verschelde 9ba0fac1ba
Merge pull request #61038 from smix8/navigation_obstacle_rid_config_warn_4.x 2022-05-16 13:47:20 +02:00
Rémi Verschelde 95da5436dc
Merge pull request #61032 from smix8/navigationmesh_bake_no_threads_4.x 2022-05-16 13:47:06 +02:00
reduz 746dddc067 Replace most uses of Map by HashMap
* Map is unnecessary and inefficient in almost every case.
* Replaced by the new HashMap.
* Renamed Map to RBMap and Set to RBSet for cases that still make sense
  (order matters) but use is discouraged.

There were very few cases where replacing by HashMap was undesired because
keeping the key order was intended.
I tried to keep those (as RBMap) as much as possible, but might have missed
some. Review appreciated!
2022-05-16 10:37:48 +02:00
smix8 49c603e127 Disable threaded NavigationMesh bake on unsupported OS
Automatically disables threaded NavigationMesh bake when OS does not support threads.
2022-05-16 00:55:15 +02:00
smix8 cc707412e9 Fix NavigationObstacle2D/3D get_global_transform() error
Fixes NavigationObstacle2D/3D reporting a 'get_global_transform: Condition "!is_inside_tree()" error when estimating the agent radius.

The collisionshapes that are lower in the SceneTree order than the obstacle node are not loaded in the SceneTree yet so the global_transform function fails.

Also adds warning message when this happens.
2022-05-15 20:29:23 +02:00
smix8 001d89223f Expose NavigationObstacle2D/3D get_rid() and add config warning
Exposes get_rid() function for scripting.
Adds configuration warning when obstacle is used with not intended static body parent.
2022-05-15 01:03:22 +02:00
Hugo Locurcio 515676a7f5
Remove unused `GPUParticlesCollisionHeightField3D.follow_camera_push_ratio` property
- Rename setter/getter methods for consistency.
- Remove section in the inspector as there is now only 1 property
  within the section.
- Add performance hints to property hints.
2022-05-13 04:19:28 +02:00
FireForge 88a8038387 Capitalize/fix some property enum hints 2022-05-12 15:03:16 -05:00
Rémi Verschelde edf61c077c
Merge pull request #60917 from akien-mga/ci-emscripten-3.1.10 2022-05-10 15:08:32 +02:00
Rémi Verschelde b6983eeccf
Merge pull request #51591 from Calinou/call-group-default-immediate
Make `{call,set,notify}_group()` immediate by default
2022-05-10 14:52:23 +02:00
Rémi Verschelde d8935b27a9 Fix warnings found by Emscripten 3.1.10
Fix `-Wunused-but-set-variable`, `-Wunqualified-std-cast-call`, and
`-Wliteral-range` warnings.
2022-05-10 13:03:13 +02:00
Hugo Locurcio aabbb40009
Make `{call,set,notify}_group()` immediate by default
This results in less surprising behavior out of the box.

Internal usages were modified to keep the existing behavior
identical there.
2022-05-05 16:59:37 +02:00
Haoyu Qiu 312ec612c7 Add autocompletion for AnimatedSprite.play() 2022-05-05 14:36:35 +08:00
Pawel Lampe 88d3f14697 Add ability to `bake_navigation_mesh` off thread.
This feature makes it possible to workaround problems such as:
 - long baking time due to heavy synchronization when parsing geometry
   from mesh instances
 - crash when freeing `NavigationMeshInstance` while baking
 - errors when actively baking node tree is being detached from the
   scene tree
2022-05-04 23:00:18 +02:00
Aaron Franke fa7a7795f0
Rename Basis get_axis to get_column, remove redundant methods 2022-05-03 09:37:47 -05:00
Rémi Verschelde 931838b330
Merge pull request #60627 from aaronfranke/rename-elements
Rename Transform2D and Basis `elements` to `columns` and `rows` respectively
2022-05-03 14:40:01 +02:00
Hugo Locurcio 180e5d3028
Remove `RES` and `REF` typedefs in favor of spelled out `Ref<>`
These typedefs don't save much typing compared to the full `Ref<Resource>`
and `Ref<RefCounted>`, yet they sometimes introduce confusion among
new contributors.
2022-05-03 01:43:50 +02:00
Rémi Verschelde c273ddc3ee Style: Partially apply clang-tidy's `cppcoreguidelines-pro-type-member-init`
Didn't commit all the changes where it wants to initialize a struct
with `{}`. Should be reviewed in a separate PR.

Option `IgnoreArrays` enabled for now to be conservative, can be
disabled to see if it proposes more useful changes.

Also fixed manually a handful of other missing initializations / moved
some from constructors.
2022-05-02 16:28:25 +02:00
Rémi Verschelde 4e06ce7840
Merge pull request #60655 from smix8/navigation_region_rid_4.x
Add get_region_rid() to NavigationRegion2D and NavigationRegion3D
2022-05-01 14:17:40 +02:00
bruvzg 0a0e94d996
Expose Label3D and Sprite*3D material render priority properties. 2022-04-30 15:09:30 +03:00
smix8 05d06b8957 Add get_region_rid() NavigationRegion2D and NavigationRegion3D
Add get_region_rid() to NavigationRegion2D and NavigationRegion3D
2022-04-30 13:27:30 +02:00
Rémi Verschelde a817bd96c0
Merge pull request #59297 from fabriceci/fix-jitter-2D-slight-slope 2022-04-29 15:33:45 +02:00
Aaron Franke 1bf94dff3a
Rename Basis "elements" to "rows" 2022-04-29 08:02:56 -05:00
bruvzg be2ee9d277
[Label3D] Add offset property. 2022-04-28 21:23:15 +03:00
Rémi Verschelde 212989d467
Merge pull request #59438 from fabriceci/fix-move-and-collide-reported-collisions
Fix wrong collision reported on move_and_collide
2022-04-28 18:47:22 +02:00