How to make player animations work on LAN

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By tartetatin27

I’ve set up an animation player and an animation tree for the player, along with the movement script. I was wondering how to make those animations work over the network? Here’s a snippet of the code

func _physics_process(delta):
if get_tree().has_network_peer():

	if is_network_master():
		var input_vector = Vector2.ZERO
		input_vector.x = Input.get_action_strength("ui_right") - Input.get_action_strength("ui_left")

		input_vector.y = Input.get_action_strength("ui_down") - Input.get_action_strength("ui_up")
		input_vector = cartesian_to_isometric(input_vector).normalized()
		if input_vector != Vector2.ZERO:
			velocity = input_vector
			velocity = velocity.move_toward(input_vector * MAX_SPEED, ACCELERATION)

			velocity = velocity.move_toward(Vector2.ZERO, FRICTION)