1. Which method out of the below is preferred to propagate data from peer to host in multiplayer and in what conditions each of them is used ?
A. Set Client input state "<variable>" to something and then use Multiplayer.PeerState (Associatedobject.peerid", "<variable>") sequence
Use that for anything latency-sensitive, which is generally the buttons the peer is pressing, i.e. as the name suggests, input states.
[quote:2rfc2qr0]B. Send message with peer data within the message
Anything not latency sensitive, like chat messages.
[quote:2rfc2qr0]C. Use Sync variable
Not an option, because that *only* sends data from the host to the peer. 'Sync' never sends anything from the peer to the host.
[quote:2rfc2qr0][re: is read for input] For me the confusion is whether this condition should be checked by host or by a peer?
By the peer, because only peers send their input. The condition is very simple. Imagine setting a global variable to true when 'On client update' triggers. The condition just checks if the global has been set. If you allow the player to move before then, it will simply cause an input prediction error, because the host is not yet aware of your movement. It's pretty minor though - even if an input prediction error occurs, it will be corrected a few moments later.
[quote:2rfc2qr0]Another confusion is for the "on client update", this is a trigger, but what triggers it?
It fires 30 times a second to test the inputs, because that's how often messages are sent to the host (not 60, because that would use double bandwidth for little benefit). The frequency should not be important though. The trigger basically means "time to check what the inputs are, because it's about to be sent to the host".