- Home /
rpc concept
I have a game object that has a network view and a script with a static variable. I use an RPC function to change that static variable to true. However, it is not true for all players in the game, just me.
networkView.RPC("StartGame1", RPCMode.AllBuffered); // called with a gui button
@RPC function StartGame1() {
var temp : GameObject;
temp = gameObject.Find("GameFeatures");
temp.GetComponent(Features).StartGame = true;
}
How do I make it so that when this function is called, it is called on all players in the game?
Answer by tho121 · Jul 12, 2011 at 07:14 PM
bumping to top of pile
Please don't post comments as answers. To people looking at the questions list, it now looks as though you've received a solution and they're much less likely to give it a look.
Your answer
Follow this Question
Related Questions
Send GameObject active in network to all clients 2 Answers
Disconnect a player from a network 1 Answer
Network.Destroy(), Couldn't perform remo 0 Answers
RPC call not sending correct data 0 Answers
Empty RPC functions. 1 Answer