renaming player to ownerPlayer (#1859)

This commit is contained in:
James Frowen 2020-05-08 00:04:57 +01:00 committed by GitHub
parent 2c40c71557
commit eed1ddc090
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1130,10 +1130,10 @@ static bool VerifyCanSpawn(GameObject obj)
/// <para>This is the same as calling NetworkIdentity.AssignClientAuthority on the spawned object.</para>
/// </summary>
/// <param name="obj">The object to spawn.</param>
/// <param name="player">The player object to set Client Authority to.</param>
public static void Spawn(GameObject obj, GameObject player)
/// <param name="ownerPlayer">The player object to set Client Authority to.</param>
public static void Spawn(GameObject obj, GameObject ownerPlayer)
{
NetworkIdentity identity = player.GetComponent<NetworkIdentity>();
NetworkIdentity identity = ownerPlayer.GetComponent<NetworkIdentity>();
if (identity == null)
{
Debug.LogError("Player object has no NetworkIdentity");