Hello everyone, I want to create an object with Photon fusion Runner.Spawn, the script that will call this method is in a script derived from networkbehaviour and produced with Runner.Addbehaviour, but I get a null reference exception error in the runner.spawn function, I understand that the runner is not assigned, so is there any other way other than assigning it manually?
public class Card : NetworkBehaviour
{
arrowDrawer = Object.AddBehaviour<ArrowDrawer>();
}
public class ArrowDrawer : NetworkBehaviour
{
public void Initializer(PlayerRef player) // I can reference runner to Initializer but i m asking for other ways
{
Arrow = Runner.Spawn(PrefabManager.instance.ArrowDrawerPrefab, Vector3.zero, Quaternion.identity,player); // There is im taking Runner s not implemented error
}