photonview is.mine
The whole answer can be found below.
Try Our
Documentation
Please check if you can find an answer in our extensive documentation on PUN.
Join Us
on Discord
Meet and talk to our staff and the entire Photon-Community via Discord.
Read More on
Stack Overflow
Find more information on Stack Overflow (for Circle members only).
photonview is.mine
Unai
2017-03-30 04:57:34
Hi,
I am looking for the script. Where should i use this in unity so all avatars dont run at the same time.
Using third person controll from standar assets.
Thanks
Comments
[Deleted User]
2017-04-03 08:54:00
Hi @Unai,
you should at least insert PhotonView.isMine condition wherever you have input. I currently don't know how ThirdPersonController is built, but you should check Update() and FixedUpdate() functions for input and surround this with if (PhotonView.isMine)
condition or add if (!PhotonView.isMine) { return; }
before the input handling.
If you still have problems you can check our Basics Tutorial which provides a good introduction on how to use PUN and its components.
hello. i have a problem. who get property isMine with true value and when it get this value? i thinked, that any photonView get it at photon.Instantiate time, but we can spawn also any things, that isn't player. How distributing values of isMine?
IsMine is usually derived from the ViewID (which includes who created the object). The creator is usually the controller, too.
Read the PUN Basics Tutorial and the docs, which dive into those topics. It's not useful to repeat this in a thread here.
Back to top