You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-13 13:31:48 +00:00
Provide warning when using polygon shapes in CollisionShape2D node
`ConvexPolygonShape2D` and `ConcavePolygonShape2D` are only meant to be used directly in code and not in the editor for physics-based use cases specifically. Developers are advised to use `CollisionPolygon2D` instead, which does generate those shapes under the hood, handling polygon convexivity, proper orientation etc.
This commit is contained in:
@@ -242,9 +242,11 @@ void CollisionShape2DEditor::commit_handle(int idx, Variant &p_org) {
|
||||
} break;
|
||||
|
||||
case CONCAVE_POLYGON_SHAPE: {
|
||||
// Cannot be edited directly, use CollisionPolygon2D instead.
|
||||
} break;
|
||||
|
||||
case CONVEX_POLYGON_SHAPE: {
|
||||
// Cannot be edited directly, use CollisionPolygon2D instead.
|
||||
} break;
|
||||
|
||||
case LINE_SHAPE: {
|
||||
|
||||
Reference in New Issue
Block a user