diff options
author | jluehrs2 <jluehrs2@uiuc.edu> | 2007-09-07 17:55:58 -0500 |
---|---|---|
committer | jluehrs2 <jluehrs2@uiuc.edu> | 2007-09-07 17:55:58 -0500 |
commit | a1c37c716ba823832b193bb8ea01756e36b88765 (patch) | |
tree | c40e1e50b6d55cb2489927f774defce31c4ee6ac | |
parent | 0257d46539fe3118098672917909f2971fe0c8d5 (diff) | |
download | luancurses-a1c37c716ba823832b193bb8ea01756e36b88765.tar.gz luancurses-a1c37c716ba823832b193bb8ea01756e36b88765.zip |
off by one
-rw-r--r-- | test/test.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/test.lua b/test/test.lua index 0976b88..c6c24f8 100644 --- a/test/test.lua +++ b/test/test.lua @@ -18,11 +18,11 @@ while true do local c = curses.getch() if c == "left" and x > 0 then x = x - 1 - elseif c == "right" and x < maxx then + elseif c == "right" and x < maxx - 1 then x = x + 1 elseif c == "up" and y > 0 then y = y - 1 - elseif c == "down" and y < maxy then + elseif c == "down" and y < maxy - 1 then y = y + 1 elseif #c == 1 then curses.addstr(c) |