- Home /
Network Instiantiate Terrain (Voxel) issues C#
Hi thank you unity user and viewer!
So to get started I've created a voxel engine : however I got to the point of saying whats a voxel game without showing you're friends you're level .... I wanted to take a easy approach to this using serialization offcourse ... So the single player works fine you can serialize the chunk data and then offcourse deserialize it ...
The idea behind the multi-player would be to only off course, send the currently De-serialized data to the client....
So I was setting this up and got it working other then I had to switch some things for the cameras and boom I 'm starting to have major issues here ....
So I decided I probable y should Instantiate 2 terrains as before I was using a find game objects in scene .. and it was giving me issues .... So what I decided I could try to do is simply making a network view for the terrain : I'm guessing this is where i'am easily going wrong though however because the terrain is not a player ... and network view would be acting like it was anyway.....
I'm not sure .... so what happens is I have a fake loading of screen that waits untill all the chunk prefabs are generated then off course network instantiates the new player in a different group ....
So really where i'm really confused at is since I'm network instantiates the terrain manager as well .... and I have these boolean checks which generate the map ... So if i'am the server it turns these true ... Which works for the server it generates the map ....
basicly on Awake I have these booleans reset to false....
So I join in as the client and here is problem A the terrains boolean checks from the servers terrain reset back to false making my game unplayible to the server as now ..
This meaning I have a map loader inside the terrain ... that basiclly again checks if Im server then I can load my local map files deserialize these then send it off the other clients on function OnPlayerConnected
Any idea why these would reset the other network views boolean as well do I have to make this control group different it does not make sense to me though as they would need the same control group to send the rpc function .....
Oh and yes! I do have my sent rpc with the mode RPCMODE.Others
So its not sending to my self or anything ... its just saying im awake and all of my awake is the others awake as well which makes no sense since a there 2 seperate objects a b there two seperate network views...?!?!
Your answer
Follow this Question
Related Questions
Very Strange RPC error 1 Answer
RPC return value 1 Answer
Acess server stuff by the client 0 Answers
Photon (PUN) Type Serialization Error on RPC 2 Answers
Problem with networking 2 Answers