The NetworkPlayer who owns this network view.
function OnNetworkInstantiate (info : NetworkMessageInfo) { var nView = GetComponent.<NetworkView>();
if (!nView.isMine) Debug.Log("New object instantiated by " + nView.owner); }
using UnityEngine; using System.Collections;
public class ExampleClass : MonoBehaviour { void OnNetworkInstantiate(NetworkMessageInfo info) { NetworkView nView = GetComponent<NetworkView>(); if (!nView.isMine) Debug.Log("New object instantiated by " + nView.owner); } }
Did you find this page useful? Please give it a rating: