diff --git a/src/Tools/SelectionTools/ColorSelect.gd b/src/Tools/SelectionTools/ColorSelect.gd index 351ce0bf1..55964dad0 100644 --- a/src/Tools/SelectionTools/ColorSelect.gd +++ b/src/Tools/SelectionTools/ColorSelect.gd @@ -17,7 +17,7 @@ func apply_selection(position : Vector2) -> void: selection_bitmap_copy.set_bit_rect(full_rect, false) var cel_image := Image.new() - cel_image.copy_from(project.frames[project.current_frame].cels[project.current_layer].image) + cel_image.copy_from(_get_draw_image()) cel_image.lock() var color := cel_image.get_pixelv(position) for x in cel_image.get_width(): diff --git a/src/Tools/SelectionTools/Lasso.gd b/src/Tools/SelectionTools/Lasso.gd index 81ab22cc9..a84548be5 100644 --- a/src/Tools/SelectionTools/Lasso.gd +++ b/src/Tools/SelectionTools/Lasso.gd @@ -103,9 +103,8 @@ func lasso_selection(bitmap : BitMap, points : PoolVector2Array) -> void: else: bitmap.set_bit(point, !_subtract) - var image = _get_draw_image() var v := Vector2() - var image_size = image.get_size() + var image_size : Vector2 = project.size for x in image_size.x: v.x = x for y in image_size.y: diff --git a/src/Tools/SelectionTools/MagicWand.gd b/src/Tools/SelectionTools/MagicWand.gd index e0df62c36..f3cce67de 100644 --- a/src/Tools/SelectionTools/MagicWand.gd +++ b/src/Tools/SelectionTools/MagicWand.gd @@ -12,7 +12,7 @@ func apply_selection(position : Vector2) -> void: selection_bitmap_copy.set_bit_rect(full_rect, false) var cel_image := Image.new() - cel_image.copy_from(project.frames[project.current_frame].cels[project.current_layer].image) + cel_image.copy_from(_get_draw_image()) cel_image.lock() flood_fill(position, cel_image, selection_bitmap_copy) diff --git a/src/Tools/SelectionTools/PolygonSelect.gd b/src/Tools/SelectionTools/PolygonSelect.gd index b29b37b4c..fac55258b 100644 --- a/src/Tools/SelectionTools/PolygonSelect.gd +++ b/src/Tools/SelectionTools/PolygonSelect.gd @@ -140,9 +140,8 @@ func lasso_selection(bitmap : BitMap, points : PoolVector2Array) -> void: else: bitmap.set_bit(point, !_subtract) - var image = _get_draw_image() var v := Vector2() - var image_size = image.get_size() + var image_size : Vector2 = project.size for x in image_size.x: v.x = x for y in image_size.y: