Skip to content

Commit

Permalink
Merge pull request #956 from MagistrumT-T/move-points-down-a-bit
Browse files Browse the repository at this point in the history
move down `local points` assigment on gui/design
  • Loading branch information
myk002 authored Jan 23, 2024
2 parents 140b298 + effc478 commit 1bdb276
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ Template for new versions:

## Fixes
- `combine`: prevent stack sizes from growing beyond quantities that you would normally see in vanilla gameplay
- `gui/design`: Center dragging shapes now track the mouse correctly

## Misc Improvements
- `caravan`: enable searching within containers in trade screen when in "trade bin with contents" mode
Expand Down
6 changes: 3 additions & 3 deletions gui/design.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1247,9 +1247,6 @@ function Design:onRenderFrame(dc, rect)
self.marks[self.placing_mark.index] = mouse_pos
end

-- Set main points
local points = copyall(self.marks)

-- Set the pos of the currently moving extra point
if self.placing_extra.active then
self.extra_points[self.placing_extra.index] = mouse_pos
Expand Down Expand Up @@ -1289,6 +1286,9 @@ function Design:onRenderFrame(dc, rect)
self.prev_center = mouse_pos
end

-- Set main points
local points = copyall(self.marks)

if self.mirror_point then
points = self:get_mirrored_points(points)
end
Expand Down

0 comments on commit 1bdb276

Please sign in to comment.