Networking with procedural tileset

New Member
Registered: 2016-05-22
Posts: 3


Hello! I'm working on a editable tile base game right now. At first I don't have any issues with syncing my tiles in all clients while using the oriented brush because the parent object has the sprite and network identity component on it. And once I tried to paint and NetworkServer.Spawn the new tile, it will just disable that old object and spawn a new object perfectly in all of my clients. But I noticed that I have some issues with the edge bleeding once I have a lot of tiles on screen.

So I tried to use tileset instead of the oriented brush. It did manage to fix the edge bleeding issue but there's a problem. For some reason my server can't send the modified tile to the newly connected clients. I think it's because tileset brushes handles sprite differently. Before for each tile I have one prefab that contains its sprite and network identity. Now, the tile system handle the sprite rendering and I can't locate it where it happens.

I tried doing [Command] and [ClientRpc] approach. In my command, it just calls the clientrpc function which is the one who will paint the tile. And I also tried with just one command function which will get the tile data of the painted tile and get the child of the gameobject of the tile data and networkserver.spawn it. All of this approach will sync it in all clients but once the user tries to disconnect and try to connect. The latter approach will managed to spawn the object (which you'll see on the scene objects) but the sprite of the tile is not updated.

Do you have any suggestion? I'm creating a harvest moon like game by the way.


Last edited by Pixillr (2016-05-23 04:15:23)