Hello, I just wanted to ask if it’s good way to instantiate an object on a local player that needs also to be seen by other players across the Network? It works but I want to know if it’s correct way or is there any cleaner sollution
private void Update()
{
if(Input.GetKeyDown(KeyCode.F))
{
if(isLocalPlayer)
{
CmdCreateObj();
}
}
}
[Command]
void CmdCreateObj()
{
RpcCreateAcross();
}
[ClientRpc]
void RpcCreateAcross()
{
GameObject obj = Instantiate(instantiating stuff);
}