diff options
author | RaindropsSys <contact@minteck.org> | 2023-09-02 15:32:03 +0200 |
---|---|---|
committer | RaindropsSys <contact@minteck.org> | 2023-09-02 15:32:03 +0200 |
commit | 6a20ab31ef4d9f6bb0e008b9f1b8d3fbeb6bd956 (patch) | |
tree | d425cdef328ed268fb149d6e2b139c9b2c26dbd2 /src/zoom.py | |
parent | c2f1ed6a85c3895483d36af0f64e2829c3fa3263 (diff) | |
download | blocks-6a20ab31ef4d9f6bb0e008b9f1b8d3fbeb6bd956.tar.gz blocks-6a20ab31ef4d9f6bb0e008b9f1b8d3fbeb6bd956.tar.bz2 blocks-6a20ab31ef4d9f6bb0e008b9f1b8d3fbeb6bd956.zip |
Updated 13 files and added 2 files (automated)
Diffstat (limited to 'src/zoom.py')
-rw-r--r-- | src/zoom.py | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/src/zoom.py b/src/zoom.py index 1e57d56..d3092e0 100644 --- a/src/zoom.py +++ b/src/zoom.py @@ -1,4 +1,4 @@ -offset_limit = 200 +offset_limit = 600 def zoom_in(zoom): if zoom[0] > 128: @@ -15,22 +15,22 @@ def zoom_reset(): offset = (0, 0) return zoom, offset -def offset_up(offset): - if offset[1] - 10 > -offset_limit: - offset = (offset[0], offset[1] - 10) - return offset - def offset_down(offset): - if offset[1] + 10 < offset_limit: - offset = (offset[0], offset[1] + 10) + if offset[1] - 20 > -offset_limit: + offset = (offset[0], offset[1] - 20) return offset -def offset_left(offset): - if offset[0] - 10 > -(offset_limit * 16/9): - offset = (offset[0] - 10, offset[1]) +def offset_up(offset): + if offset[1] + 20 < offset_limit: + offset = (offset[0], offset[1] + 20) return offset def offset_right(offset): - if offset[0] + 10 < offset_limit * 16/9: - offset = (offset[0] + 10, offset[1]) + if offset[0] - 20 > -(offset_limit * 16/9): + offset = (offset[0] - 20, offset[1]) + return offset + +def offset_left(offset): + if offset[0] + 20 < offset_limit * 16/9: + offset = (offset[0] + 20, offset[1]) return offset
\ No newline at end of file |