Update area_create
description in PhysicsServer2D/3D
to clear up possible confusions
#91581
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I'm a newbie who never worked with game engine before so apologies in advance if this is incorrect.
I spent way too long trying to figure out why collisions with areas created from Area2D nodes were working but not between areas created using PhysicsServer2D.area_create().
From my testing it looks like by default the
monitorable
property is set to false, which can be confusing since there is no easy way to check it (noarea_get_monitorable()
method for example). Especially since areas created with Area2D nodes have this enabled by default.To reduce chances other people will be confused like me I updated the description of the method to explicitly state that.
I didn't mention
monitoring
property since areas are always monitoring, and disabling it in Area2D node just means setting empty callback. If you think there may be value in adding this as well, feel free to suggest changes.