Skip to content

Commit

Permalink
Fix symmetry guide crash when opening pxo files
Browse files Browse the repository at this point in the history
Related to the PoolVectorArray locking issue (#331). This still doesn't fix the issue itself, but at least Pixelorama does not crash anymore. It is still possible, though, to fail to load a guide when opening a project. Opening it again may solve the issue.
  • Loading branch information
OverloadedOrama committed May 12, 2021
1 parent 99ce07b commit e8b36bb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/Classes/Project.gd
Original file line number Diff line number Diff line change
Expand Up @@ -358,10 +358,10 @@ func deserialize(dict : Dictionary) -> void:
if dict.has("symmetry_points"):
x_symmetry_point = dict.symmetry_points[0]
y_symmetry_point = dict.symmetry_points[1]
x_symmetry_axis.points[0].y = floor(y_symmetry_point / 2 + 1)
x_symmetry_axis.points[1].y = floor(y_symmetry_point / 2 + 1)
y_symmetry_axis.points[0].x = floor(x_symmetry_point / 2 + 1)
y_symmetry_axis.points[1].x = floor(x_symmetry_point / 2 + 1)
for point in x_symmetry_axis.points:
point.y = floor(y_symmetry_point / 2 + 1)
for point in y_symmetry_axis.points:
point.x = floor(x_symmetry_point / 2 + 1)
if dict.has("export_directory_path"):
directory_path = dict.export_directory_path
if dict.has("export_file_name"):
Expand Down

0 comments on commit e8b36bb

Please sign in to comment.