Skip to content

Commit

Permalink
fix(game): Fix keyboard scroll bug
Browse files Browse the repository at this point in the history
  • Loading branch information
gabe565 committed Jul 15, 2024
1 parent 3890ba4 commit f23b5bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/game/game.go
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ func (g *Game) Update(msg tea.Msg) (tea.Model, tea.Cmd) {
if g.wrap {
g.pattern.Grid = append(g.pattern.Grid[1:], g.pattern.Grid[0])
} else {
g.y = min(g.y+1, g.BoardH(), g.viewH)
g.y = min(g.y+1, g.BoardH()-g.viewH)
}
case key.Matches(msg, g.keymap.moveRight):
if g.wrap {
Expand Down

0 comments on commit f23b5bb

Please sign in to comment.