From d168903a3ac75107391c0734d2edda5030c00c15 Mon Sep 17 00:00:00 2001 From: uwee Date: Sun, 27 Jan 2019 21:11:11 -0500 Subject: [PATCH] Method parameters were changed in Mirror (#351) Updated to match current Mirror --- docs/Concepts/GameObjects/SpawnPlayerCustom.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/Concepts/GameObjects/SpawnPlayerCustom.md b/docs/Concepts/GameObjects/SpawnPlayerCustom.md index f68d934a0..f0c1b4edb 100644 --- a/docs/Concepts/GameObjects/SpawnPlayerCustom.md +++ b/docs/Concepts/GameObjects/SpawnPlayerCustom.md @@ -26,11 +26,11 @@ using Mirror; public class MyNetworkManager : NetworkManager { - public override void OnServerAddPlayer(NetworkConnection conn, short playerControllerId) + public override void OnServerAddPlayer(NetworkConnection conn) { GameObject player = (GameObject)Instantiate(playerPrefab, Vector3.zero, Quaternion.identity); player.GetComponent().color = Color.red; - NetworkServer.AddPlayerForConnection(conn, player, playerControllerId); + NetworkServer.AddPlayerForConnection(conn, player, conn.playerControllerId); } } ```