Spectate on other players during multiplayer using PUN 2 (Photon)

So here is the question. I have a PvEvP game. To put it simply, 2 players are playing on their own devices in a sudden death mode, where the first one to lose all lives loses the game.

I want players to see what the other player is doing in a small window on the top right.

I am using PUN 2 for my networking. Can you please suggest what should be done to achieve that?

You mean there are two players, and the small window shows the other player’s view or actions? This isn’t exactly spectating, which refers to one or more clients who aren’t playing, just watching (spectating) the match. Just saying. :wink:

In its simplest form you could simply attach a second camera to follow the other (remote) player and render that camera’s output to the small window. This does not require writing any additional networking code since it uses the client’s state, it just puts the focus of the second camera on the other player who may or may not be in the visible area of the local client’s camera.

How can I achieve that…Do I just attach a photon view to the second camera to send the information…Like how do I exactly send the camera information of the other player?

I can send basic data but how to send a video over the network?

You don‘t want to send (stream) a video, that would be overkill! Also in terms of bandwidth, players will not expect a game to consume as much network data as streaming video.

Assuming you already have the two player‘s positions synchronized you just need another (local!) camera to follow the remote player.

Ok, I’ll try that way.
Thanks