Many changes
Handle it
This commit is contained in:
parent
bf09402bc5
commit
214e0aa5e0
366 changed files with 24353 additions and 2096 deletions
17
components/scripts/free_camera_component.gd
Normal file
17
components/scripts/free_camera_component.gd
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
extends Node2D
|
||||
class_name FreeCameraComponent
|
||||
|
||||
@onready var camera: GameCamera = $GameCamera
|
||||
|
||||
func _ready() -> void:
|
||||
var map_size_x: int = Global.TILE_SIZE * (Global.ROOM_WIDTH * Global.GRID_WIDTH)
|
||||
var map_size_y: int = Global.TILE_SIZE * (Global.ROOM_HEIGHT * Global.GRID_HEIGHT)
|
||||
|
||||
Log.pr("Map size: ", map_size_x, map_size_y)
|
||||
|
||||
camera.set_limit(SIDE_LEFT, -100)
|
||||
camera.set_limit(SIDE_TOP, -100)
|
||||
camera.set_limit(SIDE_RIGHT, map_size_x + 100)
|
||||
camera.set_limit(SIDE_BOTTOM, map_size_y + 100)
|
||||
|
||||
pass
|
||||
Loading…
Add table
Add a link
Reference in a new issue