- Home /
Network Moving Help.
When i connect to my server I controll the other player and the other player controll me Help Please.
The code of player:
 function Start () {
                 
           if (!networkView.isMine) {
                GetComponent(CharacterController).enabled = false;
           }
           
           if (networkView.isMine) {
                GetComponent(CharacterController).enabled = true;
                }
and the camera:
 function Start () {
           if(!networkView.isMine) {
                
                GetComponent(AudioListener).enabled = false;
                
                GetComponent(Camera).enabled = false;
           }
 }
Learn how multiplayer works, then come back and answer the question yourself
ok so make a tutorial for me because i can't find a good tutorial.
You may find this tutorial useful, I know I did: http://cgcookie.com/unity/2011/12/20/introduction-to-networking-in-unity/
Considering I only started learning any kind of scripting in Unity a matter of weeks ago, this tutorial really did help me create the game I wanted along with other things I found posted online.
Answer by boxburn · Jun 05, 2013 at 10:01 AM
There are more components that need to be disabled (if you are using the standard First Person Controller they are Character Motor, FPS Input Controller, Mouse Look & Character Controller). You also need to put "" around the component you are trying to access such as:
 GetComponent("CharacterController").enabled = true;
Your answer
 
 
              koobas.hobune.stream
koobas.hobune.stream 
                       
                
                       
			     
			 
                