Some logging messages were still being issued when portals/debug/logging was false. This could be annoying in games that stream in parts of levels and repeatedly call `rooms_convert()`.
This PR allows all but essential logging to be disabled.
Groups the ill-defined NavigationAgent properties between pathfinding and avoidance to make it more clear which property affects what.
(cherry picked from commit dde09be302)
Mark Navigation/Navigation2D nodes as deprecated. They already just redirect calls to the NavigationServer and have no longer a real purpose. In Godot 4.0 both nodes are already removed for good reasons.
Backports features and bugfixes from current Godot 4.0 to 3.5 and brings functions and codebase of both version largely in sync to make tutorials more compatible and future backports easier.
Changes NavigationAgent avoidance callback to a toggle that is disabled by default.
Also fixes a few missing descriptions / wrong warnings.
(cherry picked from commit 7f3688603c)
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.
(cherry picked from commit 6b51ab66d8)
* Replace case-by-case extraction with PNAME & GNAME
* Fix group handling when group hint begins with property name
* Exclude properties that are PROPERTY_USAGE_NOEDITOR
Exposes get_rid() function for scripting.
Adds configuration warning when obstacle is used with not intended static body parent.
(cherry picked from commit 001d89223f)
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.
(cherry picked from commit cc707412e9)
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
The data flow to the VisualServer of current and previous transforms is essential for allowing correct interpolation. An optimization was present that disabled sending transforms when nodes were hidden, however this meant that when unhidden, nodes would interpolate incorrectly from the last transform received when hiding, rather than the up to date previous transform.
This PR disables the optimization and sends always sends transforms when a node is interpolated.
When switching emission on and off, processing was always being switched on and off using internal_process, which was incorrect for using physics interpolation (where physics_process is the relevant one).
This PR correctly updates the process mode according to whether physics interpolation is being used.
Move VisualServer interpolation data out of Scenario and into VisualServerScene, so the interpolation data and enabled status is now common to all Scenarios.
Fix physics interpolation in multithreaded mode by ensuring tick and pre-draw are called.
This allows for lower field of view (or higher zoom) in orthogonal
and frustum camera modes.
The property hint also allows setting the size with greater precision.
During room conversion, if a prefixed Spatial is converted to a Room / RoomGroup etc, when using instanced scenes the owner was incorrectly set, resulting in the instanced scene objects being duplicated.
This PR corrects this.
The previous and current transforms in the interpolation data were not being correctly updated in cases where two or more physics ticks occurred on a frame. This PR introduces a simple mechanism to ensure updates on interpolated spatials.
Introduces fallback path for geometry types that are not recognised.
Allows STATIC mode for CPUParticles (using expansion margin)
Allows STATIC mode for Particles (using "visibility_aabb")
In order to properly support the resource sharing paradigm, Occluders are split into Instances and Resources in the VisualServer. Instances are owned by a Scenario, and Resources are global. OccluderShape resources can now correctly be shared by multiple OccluderInstances.
Adds fixed timestep interpolation to the visual server.
Switchable on and off with project setting.
This version does not add new API for set_transform etc, when nodes have the interpolated flag set they will always use interpolation.
Instead of fitting all atlas slices into a single image, which meant there
was a hard limit on the size, BakedLightmap will now save as many images
as needed to fit all the slices generated by the lightmapper.
Using codespell 2.2-dev from current git.
Added `misc/scripts/codespell.sh` to make it easier to run it once in a
while and update the skip and ignore lists.
(cherry picked from commit 1bdb82c64e)
The portal system introduced basic mesh merging functionality, this has wide ranging uses outside of the portal system.
For this reason, this PR binds the mesh merging functionality.
It also slightly modifies the calling from RoomManager to use a Vector of Node *, in order to allow binding of the function.
A regression had occurred whereby particle systems in DYNAMIC mode weren't added to the room correctly.
This PR recognise the case and bypasses the function to retrieve geometry, as retrieving the geometry is not necessary for DYNAMIC objects as they should not affect the room bound. Their AABB will be retrieved during gameplay rather than once off at level conversion.
When editor continuous redraws is switched off, the editor only redraws when a redraw_request was issued by an element in the scene. This works well in most situations, but when scenes have dynamic content they will continuously issue redraw_requests.
This can be fine on high power desktops but can be an annoyance on lower power machines.
This PR splits redraw requests into high and low priority requests, defaulting to high priority. Requests due to e.g. shaders using TIME are assigned low priority.
An extra editor setting is used to record the user preference and an extra option is added to the editor spinner menu, to allow the user to select between 3 modes:
* Continuous
* Update all changes
* Update vital changes
Change the entire navigation system.
Remove editor prefix from nav mesh generator class. It is now used for baking
at runtime as well.
Navigation supports obstacle avoidance now with the RVO2 library.
Nav system will also automatically link all nav meshes together to form one
overall complete nav map.