Ive noticed some buggs when i try to make a "channal" changeing script. It's 2 clients who are in the same channel and scene. then theres a script that looks like this:
public class changeChannel : MonoBehaviour {
void OnGUI(){
if(GUI
.Button(new Rect
(20,
20,
100,
40),
"1")){ joinChannel(1);
}
if(GUI
.Button(new Rect
(20,
80,
100,
40),
"2")){ joinChannel(2);
}
}
void joinChannel(int channelID){
TNManager.JoinChannel(channelID,null);
}
}
verry simple, i make the joinchannel level to null so you don't have to respawn at a new position everytime i join that channal, I wan't to make so everyone loads me in when i join the channel and the same thing goes for me, when i join the channel: load every objects in that channel. The reason why i dont wan't to load a level is becouse you should be able to walk
into zones and keep your current position while entering a new channel
What happens when i change the channel:
1. The player who presses change channel still have the old game objects "may be a reason for none level load.. I dunno".
2. THe player that pressed channel change dissapears for the rest of the players in the old channel.
3. The player that leaves the old channel and joins an empty can walk around and wont respawn(as wanted), but when the player enters the channel with players on it so will he respawn.
I'm using the script TNAutoCreate and then the player is inside it