summaryrefslogtreecommitdiffstats
path: root/Camera.gd
diff options
context:
space:
mode:
Diffstat (limited to 'Camera.gd')
-rw-r--r--Camera.gd4
1 files changed, 2 insertions, 2 deletions
diff --git a/Camera.gd b/Camera.gd
index bb99330..694706e 100644
--- a/Camera.gd
+++ b/Camera.gd
@@ -8,9 +8,9 @@ var zoom_boundaries : Vector2
func _ready():
margin = Vector2(0, 0)
- #window = set within Main
-func on_configure(c : Vector2, ts : Vector2) -> void:
+func configure(w : Vector2, c : Vector2, ts : Vector2) -> void:
+ window = w
map_center = c
texture_size = ts
zoom_boundaries = Vector2(1.0, max((texture_size.x + margin.x) / window.x, (texture_size.y + margin.y) / window.y))