diff options
| author | the lemons <citrons@mondecitronne.com> | 2022-12-21 15:46:30 -0600 |
|---|---|---|
| committer | the lemons <citrons@mondecitronne.com> | 2022-12-21 17:45:51 -0600 |
| commit | a06622361d858c4d9c78c15323fc0d0e17e94110 (patch) | |
| tree | 52aa25c53874a4c597cf0cab0824c9ed9ccb7bcb /main.lua | |
| parent | 619c46c37731df55bd2f50b7bb126c016734796e (diff) | |
collision detection and correction
Diffstat (limited to 'main.lua')
| -rw-r--r-- | main.lua | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -68,7 +68,9 @@ function love.draw() end end -- draw all possibly visible objects - for o in world.iterate(cx1 - 20, cy1 - 20, cx2 + 20, cy2 + 20) do + for o in world.in_box( + cx1 - obj.max_size, cy1 - obj.max_size, + cx2 + obj.max_size, cy2 + obj.max_size) do set_color(1, 1, 1) o:draw() end |
