예제 #1
0
 private void RPC_GetPlayerComponents()
 {
     BH  = ChildPlayer.GetComponent <BallHandling>();
     BS  = ChildPlayer.GetComponent <BallSteal>();
     HBS = ChildPlayer.GetComponent <hoverBoardScript>();
     PC  = ChildPlayer.GetComponent <PlayerColor>();
     ChildPlayer.transform.SetParent(this.transform);
     cRotScript = ChildPlayer.GetComponentInChildren <CameraRotation>();
     cmm        = ChildPlayer.GetComponentInChildren <CameraModeMedium>();
 }
예제 #2
0
    private void SetPlayer(GameObject spawningObject)
    {
        Debug.Log("setting up player");
        PlayerColor PC = spawningObject.GetComponent <PlayerColor>();

        PC.LocalPlayer = LocalPlayer;
        PC.SetUpPlayer1(this);
        HBS = spawningObject.GetComponent <hoverBoardScript>();
        BH  = spawningObject.GetComponent <BallHandling>();
        BS  = spawningObject.GetComponent <BallSteal>();
        Debug.Log("finished setting up player");
    }