Quantcast
Channel: Questions in topic: "error"
Viewing all articles
Browse latest Browse all 7934

RPC Error function not found

$
0
0
Hello, I work on the server software for my game and have a problem now, where I just can't figure out, what's wrong. Maybe you can help me. It says that the function "SendDataToUser" can't be found in the server script. Server Code: function Start() { Network.InitializeServer(int.Parse(connections),int.Parse(serverPort),useNAT); } @RPC function ReceiveUserData(data : String, info : NetworkMessageInfo) { highscores.Add(data); SendDataToUser(info); console += "Received a new score."; } @RPC function SendDataToUser(info : NetworkMessageInfo) { var text : String = Array(highscores).Join(""); networkView.RPC("decodeWWW",RPCMode.All,text); } and the Client Code: function DownloadScore() { Network.Connect("127.0.0.1",20015); yield WaitForSeconds (2); networkView.RPC("SendDataToUser", RPCMode.Server); }

Viewing all articles
Browse latest Browse all 7934

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>