Trying new stuff with the camera and grid. I want to be able to move a unit but there is a problem with the grid at the moment. I am now trying to implement a new way of handling the camera, maybe then I can move on to moving units...
This commit is contained in:
@@ -15,12 +15,14 @@ var _MovingMarker: Node2D = _MovingMarkerScene.instantiate()
|
||||
|
||||
# Called when the node enters the scene tree for the first time.
|
||||
func _ready() -> void:
|
||||
add_child(_MovingMarker)
|
||||
_MovingMarker.hide()
|
||||
|
||||
_createUnit(Vector2i(10,10))
|
||||
for unit in _Units:
|
||||
add_child(unit)
|
||||
# add_child(_MovingMarker)
|
||||
# _MovingMarker.hide()
|
||||
#
|
||||
# _createUnit(Vector2i(10,10))
|
||||
# for unit in _Units:
|
||||
# add_child(unit)
|
||||
|
||||
$CameraController.position = get_viewport().get_camera_2d().get_screen_center_position()
|
||||
pass
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user