- Home /
Question by
Anton Petrov · Nov 03, 2010 at 08:27 AM ·
networkingnetworktimerpc
How to send timestamp via RPC so it was relative to the receiver?
The fact is Network.time is peer-relative and makes sense only when used with NetworkMessageInfo.timestamp withing OnSerializeNetworkView() method.
But I want to use an RPC and not the auto-syncing via OnSerializeNetworkView(). How can I send timestamps via RPC so it was valid for receiving peer???
Thank you.
Comment
Best Answer
Answer by Anton Petrov · Nov 03, 2010 at 08:34 AM
OMG, there's internal parameter 'info : NetworkMessageInfo' appended to each RPC parameter list if you wish.
Like here:
@RPC
function PrintText (text : String, info : NetworkMessageInfo)
{
Debug.Log(text + " from " + info.sender);
}
Your answer
Follow this Question
Related Questions
Networking Error! 0 Answers
View ID AllocatedID: 50 not found during lookup. 0 Answers
Multiplayer issue - players view others as themselves with same material 1 Answer
RPC and inheritance 1 Answer