mirror of
https://github.com/Orama-Interactive/Pixelorama.git
synced 2025-01-18 09:09:47 +00:00
Fix errors when attempting to draw on a 3D cel
Can occur when multiple cels are selected, some of them 3D and some of them pixel
This commit is contained in:
parent
85be0be2b5
commit
c2f6bf0f3f
|
@ -260,8 +260,9 @@ func _get_selected_draw_images() -> Array: # Array of Images
|
|||
var project: Project = Global.current_project
|
||||
for cel_index in project.selected_cels:
|
||||
var cel: BaseCel = project.frames[cel_index[0]].cels[cel_index[1]]
|
||||
if project.layers[cel_index[1]].can_layer_get_drawn():
|
||||
images.append(cel.get_image())
|
||||
if not cel is PixelCel:
|
||||
continue
|
||||
images.append(cel.get_image())
|
||||
return images
|
||||
|
||||
|
||||
|
|
|
@ -653,8 +653,7 @@ func _get_selected_draw_images() -> Array: # Array of Image(s)
|
|||
var cel: BaseCel = project.frames[cel_index[0]].cels[cel_index[1]]
|
||||
if not cel is PixelCel:
|
||||
continue
|
||||
if project.layers[cel_index[1]].can_layer_get_drawn():
|
||||
images.append(cel.image)
|
||||
images.append(cel.image)
|
||||
return images
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue