so click on your HScrollbar or VScrollbar node in your Scene tree, over on the top right side of godot you should see
Inspector Node History
click on Node
you should see under signals
scrolling()
and
value_changed(value:float)
scrolling() would be when the player grabs the HScrollbar and moves it around
value_changed(value:float) would be when the player stops moving it around and it sits on a value, that will be a float number
right click over value_changed(value:float) and click on the connect
"Connect" it to the node with your script that is best for you.
func _on_v_scroll_bar_value_changed(value: float) -> void:
pass # Replace with function body.
should show up with a nice green arrow pointing at a ]
you can then use that value:float for what you want to do like moving the robot in your game
perhaps something like
@onready
var Robot : AnimatableBody2D = $AnimatableBody2D
func _on_v_scroll_bar_value_changed(value: float) -> void:
Robot.position.x=value*10