about summary refs log tree commit diff stats
path: root/html/rogue/js/camera.js
diff options
context:
space:
mode:
Diffstat (limited to 'html/rogue/js/camera.js')
-rw-r--r--html/rogue/js/camera.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/html/rogue/js/camera.js b/html/rogue/js/camera.js
index c389b6e..aaeeea9 100644
--- a/html/rogue/js/camera.js
+++ b/html/rogue/js/camera.js
@@ -16,11 +16,11 @@ const Camera = {
         const centerX = state.canvas.width / 2;
         const centerY = state.canvas.height / 2;
         
-        // Calculate distance from center of screen
+        // Distance from center of the screen
         const deltaX = screenX - centerX;
         const deltaY = screenY - centerY;
         
-        // Only move camera if player is outside deadzone
+        // Only move the camera if the player is outside of the deadzone
         if (Math.abs(deltaX) > Config.camera.DEADZONE_X) {
             const adjustX = deltaX - (deltaX > 0 ? Config.camera.DEADZONE_X : -Config.camera.DEADZONE_X);
             this.x += adjustX * Config.camera.FOLLOW_SPEED;