11 lines
286 B
GDScript
11 lines
286 B
GDScript
extends TextureRect
|
|
|
|
|
|
|
|
func _on_CameraController_limits_changed(lefttop: Vector2, bottomright: Vector2) -> void:
|
|
rect_position = lefttop
|
|
rect_position.x -= 64
|
|
rect_position.y -= 64
|
|
rect_size.x = abs(lefttop.x) + bottomright.x + 64
|
|
rect_size.y = abs(lefttop.y) + bottomright.y + 64
|