- Home /
When my Character moves the other does - Multiplayer Photon
When I Move why does another player follow me - I know on their screen there actually not
using UnityEngine; using System.Collections;
public class NetworkManager : MonoBehaviour {
// Use this for initialization
void Start () {
PhotonNetwork.ConnectUsingSettings ("V.0.0.1");
}
void OnGUI () {
UnityEngine.GUILayout.Label ( PhotonNetwork.connectionStateDetailed.ToString() );
}
void OnJoinedLobby () {
PhotonNetwork.JoinRandomRoom ();
Debug.Log ("JOINEDLOBBY");
}
void OnPhotonRandomJoinFailed () {
Debug.Log ("CREATEDROOM");
PhotonNetwork.CreateRoom ( "MAIN" );
}
void OnJoinedRoom () {
Debug.Log ("JOINEDROOM");
PhotonNetwork.Instantiate ("CharacterController", Vector3.zero, Quaternion.identity, 0) ;
}
}
Thats my code in C# (CSharp)
Can you please link the code you are using for movement. To make this a little more clear are you saying that when you move Player A, Player B also moves but Player B is only moving on player A's client?
I have not done much work with Photon but it uses the same principles as the standard Unity Networking and I have some experience with that.
Thank you for the reply! :3 Yes, if I move as Person A Person B will move, yet I know Person B (Anyone on the net) Or anyone who joins after so
Person A Joins - He sees all of the players move with him Person B Joins - He sees all of the players move with him (Except from A) Person C Joins - He sees all of the players move with him (Except from A + B)
Yet I know They're not forced to move with him, it justs looks like that on the client.
Your answer
Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Pyramid 3d moel Please help 1 Answer
UnityEngine.Input.GetMouseButton(1)) issue 1 Answer
I made a better shader how do i fix[add _Shadow Strength]help???>Sorry that im asking for to much 1 Answer
Help In Making a SphereCast for 3D Tire! Working RayCast Script included! 0 Answers