Quantcast
Channel: Multiplayer
Viewing all articles
Browse latest Browse all 16796

Create random Number on server and broadcast to all clients

$
0
0
I'm really having trouble wrapping my head around Unity Networking. I followed the basic tutorial and have two players that can move around. Now I want to add something different: Generate a random number on the server and broadcast it to all clients. I'm able to generate the number and broadcast it, though the numbers are different on both clients:

Player1:
- local Client: 50
- remote Client: 37

Player2:
-remote Client: 50
- local Client: 37

It seems to me that the number generation code...

Create random Number on server and broadcast to all clients

Viewing all articles
Browse latest Browse all 16796

Trending Articles



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