tool
extends Resource
class_name SummerDayTrack # Don't mistake with SummerDaySceneTrack!


export(Resource) var blueprint
export(Array, Resource) var cells


func add_cell(at: int):
	var new_cell = blueprint._create_cell()
	cells.append(new_cell)


func get_current_cell():
	if cells:
		return cells[0] # This is just a placeholder.
	# TODO: make this return the currently shown cell.
	else:
		return null


func pass_global_input(event):
	var current_cell = get_current_cell()
	if current_cell:
		current_cell._handle_global_input(event)


func pass_local_input(event: InputEvent):
	var current_cell = get_current_cell()
	if current_cell:
		current_cell._pass_input(event)
