Skip to content
Snippets Groups Projects
Commit 4df9b921 authored by Eugene Pin's avatar Eugene Pin
Browse files

Regalge d'un bug sur neighborhoodDialog

parent 8b139896
No related branches found
No related tags found
No related merge requests found
Pipeline #79326 canceled
......@@ -59,7 +59,8 @@ void NeighborhoodDialog::ResizeCreateGrid(int x, int y, Neighborhood& n)
}
else {
Coord newNeighborAbsolute = {currentPoint.x + newNeighborRelative.x, currentPoint.y + newNeighborRelative.y};
if( (newNeighborAbsolute.x < x && newNeighborAbsolute.y < y)) {
if( (newNeighborAbsolute.x < x && newNeighborAbsolute.y < y) &&
(newNeighborAbsolute.x >= 0 && newNeighborAbsolute.y >= 0)) {
newGrid.set_cell(newNeighborAbsolute, 1);
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment