1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-06 12:20:30 +00:00

AutoUse Pencil on Polygon creation

This commit is contained in:
Scayze
2017-08-25 19:51:07 +02:00
committed by Rémi Verschelde
parent 98ad0e5a02
commit fbda0cc45c
4 changed files with 18 additions and 0 deletions

View File

@@ -468,6 +468,10 @@ void CollisionPolygonEditor::edit(Node *p_collision_polygon) {
if (p_collision_polygon) {
node = Object::cast_to<CollisionPolygon>(p_collision_polygon);
//Enable the pencil tool if the polygon is empty
if (node->get_polygon().size() == 0) {
_menu_option(MODE_CREATE);
}
wip.clear();
wip_active = false;
edited_point = -1;