Manual Instantiation of Objects has problems in the photonView.ismine

Options
Hi everyone,

I've used Photon Network. Instantiate to spawn the player object but since we are now using asset bundles I've tried https://doc.photonengine.com/en-us/pun/current/manuals-and-demos/instantiation
as a reference. The problem is that other players instances is returning false when it try to find out if the photonview is theirs. Only the master client is returning true.

Will appreciate any feedback regarding this. Thanks!

Comments

  • Hi @rokugatsu,

    there are currently three topics which are more or less about the same topic I guess. This is confusing and extends the time we need to answer. Please try reducing the number threads you open if they are about the same topic.

    In one of the other topics you asked if the instantiated objects are handled as scene objects or 'normal' objects. This is related to the call of the AllocateViewID or AllocateSceneViewID. If you are using AllocateSceneViewID the object will be handled as a scene object and furthermore will remain, if the MasterClient leaves - the object will be passed to the new MasterClient, if there is one. If you use AllocateViewID instead, the object will be handled as a 'normal' object and furthermore will be removed when the related client leaves.

    To the question in this thread: Do other clients try to instantiate objects at all? If a client calls AllocateViewID, the returning ViewId (the one you will pass to the RPC) will be associated with his own ID and furthermore the owner should be set correctly. If only the MasterClient calls the RPC to instantiate other objects, it is correct behaviour that he is the owner of all created objects.
  • rokugatsu
    Options
    Hi @Christian_Simon I apologize for the duplicate posts. Will keep this in mind.
    Thanks for the response :)