From ec071d5bc677101c0168b5fb3065f2d928234ed9 Mon Sep 17 00:00:00 2001 From: Arne Dußin Date: Mon, 11 Jan 2021 12:10:16 +0100 Subject: Rect rooms are now normal polygon rooms in data Before there was an extra data type for rectangular rooms. This is now changed, with the rectangle tool remaining, to create these often required rooms faster, but the data type is just a normal polygon that is generated from a rect to reduce redundancy. --- src/tool/rect_room_tool.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/tool/rect_room_tool.rs') diff --git a/src/tool/rect_room_tool.rs b/src/tool/rect_room_tool.rs index 9445787..da23fd7 100644 --- a/src/tool/rect_room_tool.rs +++ b/src/tool/rect_room_tool.rs @@ -55,7 +55,7 @@ impl Tool for RectRoomTool { return; } - map.push_rect_room(Rect::bounding_rect(pos1, pos2)); + map.push_polygon_room(Rect::bounding_rect(pos1, pos2).into()); self.unfinished_rect = None; } else { self.unfinished_rect = Some((*mouse_pos_m, *mouse_pos_m)); @@ -69,7 +69,7 @@ impl Tool for RectRoomTool { return; } - map.push_rect_room(Rect::bounding_rect(pos1, pos2)); + map.push_polygon_room(Rect::bounding_rect(pos1, pos2).into()); self.unfinished_rect = None; } } -- cgit v1.2.3-70-g09d2