How to sync button pressed to the server?

Godot Version

4.3

Question

Hi, I’ve been recently trying to create a board game multiplayer, and I got the client to connect to the server with no problem.

Here’s the questions, I have a button on my game scene where if a player click’s said button they will be in a ready state, and if both player are in a ready state the game starts, but the problem is, only the Host button do as intended, meanwhile the client can click the button but there’s no output. I tried using the multiplayer synchronize node with no luck

Is there a way to solve this problem?

Thx.

Ps:
I’m connecting the client to the server via the Ip address of the host

do something like this

# client button
func _on_button_pressed():
   player_ready.rpc()

rpc("call_local", "reliable", "any_peer")
func player_ready():
    # set player state ready
    ...

There are other ways but this is the simplest.