Hi how would i stream the same map to all the player?
i use this line
Transform t = (Instantiate(entries*.prefab) as GameObject).transform;*
to place the map i have tried adding
PhotonNetwork.Instantiate
but it always says not enough arguments
Hi how would i stream the same map to all the player?
i use this line
Transform t = (Instantiate(entries*.prefab) as GameObject).transform;*
to place the map i have tried adding
PhotonNetwork.Instantiate
but it always says not enough arguments
Firstly, any network based prefabs, need to be located in a Resources folder. Secondly, you have to input the name of the Prefab you’re using instead of the actual prefab. Here’s my example.
public class Temp : MonoBehaviour
{
private Transform _myMap;
// Use this for initialization
void Start()
{
if (PhotonNetwork.isMasterClient)
{
_myMap = PhotonNetwork.InstantiateSceneObject("MyPrefab", Vector3.zero, Quaternion.identity, 0, null).transform;
}
}
}